I need a function (through solr ruby) for ruby that will allow us to clear everything

regards,
Sg..

Geetha wrote:
Thank you Erik..

Should I write the below code in rake task /lib/tasks/solr.rake?

I am newbie to ruby.


Erik Hatcher wrote:

On Apr 24, 2009, at 1:54 AM, sagi4 wrote:
Can i get the rake task for clearing the index of solr, I mean "rake
index::rebuild", It would be very helpful and also to avoid the delete id by
manually.

How do you currently build your index?

But making a Rake task to do perform Solr operations is generally pretty trivial. In Ruby (after gem install solr-ruby):

   require 'solr'
   solr = Solr::Connection.new("http://localhost:8983/solr";)
   solr.optimize  # for example

    Erik








--

Best Regards,
** *Geetha S *| System and Software Engineer
email: gee...@angleritech.com <mailto:gee...@angleritech.com>

*
*


*
*Visit us at **Internet World, UK** (**28th-30th Apr 2009**)*
*Click here for FREE TICKETS:** *http://www.angleritech.com/company/latest-technology-news-events.html
*



*ANGLER Technologies India - Your Offshore Development Partner -- An ISO 9001 Company*

Contact us for your high quality Software Outsourcing <http://www.angleritech.com/offshore/outsourced_product_development.html>, E-Business Products <http://www.angleritech.com/ebusiness/index.html> and Design Solutions <http://www.angleritech.com/design/index.html>

/* */

web         :    www.angleritech.com <http://www.angleritech.com/>
tel           :    +91 422 2312707, 2313938
fax           :    +91 422 2313936
address   :*    *1144 Trichy Road, Coimbatore, 641045, India

offices <http://www.angleritech.com/contact/index.html>_ _ : India | USA | UK | Canada | Europe | UAE | South Africa | Singapore | Hong Kong

* *

*Disclaimer: *The information in the email, files and communication are strictly confidential and meant for the intended recipients. It may contain proprietary information. If you are not an intended recipient; any form of disclosure, copyright, distribution and any other means of use of information is unauthorised and subject to legal implications. We do not accept any liability for the transmission of incomplete, delayed communication and recipients must check this email and any attachments for the presence of viruses before downloading them.





Reply via email to