I have an indexed model called Article and I don\'t want solr to index unpublished articles.
class Article < ActiveRecord::Base searchable do text :
Be sure to index the published status.
class Article < ActiveRecord::Base searchable do text :title text :body boolean :is_published, :using => :published? end end
Then add a filter to your query
Sunspot.search(Article) do |search| search.with(:is_published, true) # ... end