lucene/client/ruby/solrb
Erik Hatcher 4c8747190b oops, broke a test, fixed when a field value does not respond to :each
git-svn-id: https://svn.apache.org/repos/asf/incubator/solr/trunk@496821 13f79535-47bb-0310-9956-ffa450edef68
2007-01-16 19:01:13 +00:00
..
examples/marc Add more MARC mappings. Add a -debug switch to dump documents to stdout instead of sending to Solr 2007-01-16 18:06:18 +00:00
lib oops, broke a test, fixed when a field value does not respond to :each 2007-01-16 19:01:13 +00:00
solr allow facets and text fields to be multi-valued 2007-01-16 18:05:11 +00:00
test Allow field hash to take an array for values 2007-01-16 17:50:55 +00:00
Changes sooner rather than later, tease the Solr DSL out from the web framework 2007-01-03 04:57:00 +00:00
README Adjust README with current API 2007-01-15 02:43:02 +00:00
Rakefile Cosmetic change to gem summary 2007-01-15 01:44:37 +00:00

README

solrb exposes the power of Solr as a Ruby  DSL (domain specific language).

  Visit the solrb wiki for more information: http://wiki.apache.org/solr/solrb

USAGE 

First launch Solr.

   cd solr
   java -jar start.jar

In a separate shell, launch irb -Ilib.

# Bring in the Solr library
  require 'solr'

# Set up a connection to Solr:

  connection = Solr::Connection.new 'http://localhost:8983/solr'

# To add a document:

  doc = Solr::Document.new :id => '529', :text => 'Solr Flare in Action'
  request = Solr::Request::AddDocument.new(doc)
  connection.send(request)
  
# Commit changes:

  connection.commit

# Search:

  request = Solr::Request::Standard.new :query => 'solr flare'
  connection.send(request)


INSTALLATION

First run the tests:

  rake
  
then build the gem:

  rake package

and install the versioned gem:

  gem install pkg/solr-x.x.x.gem 

LICENSE

This package is licensed using the Apache Software License 2.0.

<http://www.apache.org/licenses/LICENSE-2.0>