Emil Tin wrote:
> i'm considering patching my copy of ts so i would get get warnings
> (perhaps by email) instead of exceptions if the search daemon can't be
> reached when deleting/changing models.

This is how I handle sphinx connection errors. I have the following in
my application controller:

  rescue_from ThinkingSphinx::ConnectionError, :with => :sphinx_connection_error

  # method for handling the Sphinx daemon being unavailable. We don't
  # want to let it filter through to the default 500 page, as it isn't
  # a major issue, and can be easily fixed.
  def sphinx_connection_error
    ...
    <email code here>
    ...
    render :template => 'errors/sphinx_connection', :status => 500
  end

-- James Healy <jimmy-at-deefa-dot-com>  Mon, 20 Oct 2008 10:16:09 +1100

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Thinking Sphinx" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/thinking-sphinx?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to