Tabla de Contenidos

Experiencias con Apache Solr

La motivación para encarar esto justo hoy viene de: Faceted, Work-Centric Moving Image Discovery Interface Demonstration. A eso se suma una vieja curiosidad por saber algo sobre Solr, dado su uso en aplicaciones como VuFind y Kochief (ex Fac-Back-OPAC).

Tutorial

2010-10-19. Voy a seguir los pasos del Solr tutorial para conocer algo sobre este software.

Descarga: http://www.apache.org/dyn/closer.cgi/lucene/solr/http://apache.mesi.com.ar//lucene/solr/1.4.1/

http://apache.mesi.com.ar//lucene/solr/1.4.1/apache-solr-1.4.1.tgz

Getting Started

$ cd ~/software/A/apache-solr-1.4.1/example/
$ java -jar start.jar
2010-10-19 14:54:27.400::INFO:  Logging to STDERR via org.mortbay.log.StdErrLog
2010-10-19 14:54:27.925::INFO:  jetty-6.1.3

...

Oct 19, 2010 2:54:31 PM org.apache.solr.core.SolrCore registerSearcher
INFO: [] Registered new searcher Searcher@ff8c74 main
2010-10-19 14:54:31.936::INFO:  Started SocketConnector @ 0.0.0.0:8983

Para verificar que el servidor está andando accedo a:

  http://localhost:8983/solr/admin/

Indexing Data

Abro otra terminal.

cd ~/software/A/apache-solr-1.4.1/example/exampledocs
$ java -jar post.jar solr.xml monitor.xml
SimplePostTool: version 1.2
SimplePostTool: WARNING: Make sure your XML documents are encoded in UTF-8, other encodings are not currently supported
SimplePostTool: POSTing files to http://localhost:8983/solr/update..
SimplePostTool: POSTing file solr.xml
SimplePostTool: POSTing file monitor.xml
SimplePostTool: COMMITting Solr index changes..
$ java -jar post.jar *.xml
SimplePostTool: version 1.2
SimplePostTool: WARNING: Make sure your XML documents are encoded in UTF-8, other encodings are not currently supported
SimplePostTool: POSTing files to http://localhost:8983/solr/update..
SimplePostTool: POSTing file hd.xml
SimplePostTool: POSTing file ipod_other.xml
SimplePostTool: POSTing file ipod_video.xml
SimplePostTool: POSTing file mem.xml
SimplePostTool: POSTing file monitor2.xml
SimplePostTool: POSTing file monitor.xml
SimplePostTool: POSTing file mp500.xml
SimplePostTool: POSTing file payload.xml
SimplePostTool: POSTing file sd500.xml
SimplePostTool: POSTing file solr.xml
SimplePostTool: POSTing file utf8-example.xml
SimplePostTool: POSTing file vidcard.xml
SimplePostTool: COMMITting Solr index changes..

Deleting Data

$ java -Ddata=args -Dcommit=no -jar post.jar "<delete><id>SP2514N</id></delete>"
SimplePostTool: version 1.2
SimplePostTool: WARNING: Make sure your XML documents are encoded in UTF-8, other encodings are not currently supported
SimplePostTool: POSTing args to http://localhost:8983/solr/update..
$ java -jar post.jar
SimplePostTool: version 1.2
SimplePostTool: WARNING: Make sure your XML documents are encoded in UTF-8, other encodings are not currently supported
SimplePostTool: COMMITting Solr index changes..
$ java -Ddata=args -jar post.jar "<delete><query>name:DDR</query></delete>"
SimplePostTool: version 1.2
SimplePostTool: WARNING: Make sure your XML documents are encoded in UTF-8, other encodings are not currently supported
SimplePostTool: POSTing args to http://localhost:8983/solr/update..
SimplePostTool: COMMITting Solr index changes..
java -jar post.jar *.xml

Documentos

Interfaces Solr/Python

Interfaces Solr/Django