It doesn’t look like SunSpot has a builtin optimize command.
Here’s one way you can do it:
Sunspot.session.session.send(:connection).update RSolr::Message::Generator.new.build { |b| b.optimize }
Anyone know of a simpler one?
|
|||||
|
It doesn’t look like SunSpot has a builtin optimize command. Anyone know of a simpler one? Github’s excellent analysis of the extant background jobs runners and introduction to Resque If RubyMine isn’t recognizing cucumber features, ensure the following: Cucumber gem is attached to project: RM | Settings | Ruby SDK and Gems | Attach gems. Use http://github.com/gumayunov/custom-err-msg/tree/master This can be a pain to find so here is the quick access version: Sometimes you wish to convert one STI class to another, e.g. promote User to Administrator. Note however that this does not change the type attribute of the instance, so you still have an additional step to do if you want this [...] Yehuda Katz talked about Rails 3 If you have two models associated in some way, it is usual to add a validates_presence_of validator to ensure that the models are connected before saving. However, be aware that there are two ways of doing this with different performance ramifications: class BlogEntry < ActiveRecord::Base During validation, Validates_presence_of :blog causes ActiveRecord [...] The other thing I can never remember off the top of my head: 1 Tidbit from RailsCast 132: 1 |
|||||
|
Copyright © 2010 Sam Pierson's Blog - All Rights Reserved |
|||||