pat / ts-delayed-delta

Manage delta indexes via Delayed Job for Thinking Sphinx
http://ts.freelancing-gods.com
MIT License
73 stars 33 forks source link

ActiveRecord::ConnectionNotEstablished with TS #12

Closed fmalamitsas closed 13 years ago

fmalamitsas commented 13 years ago

Hello,

I'm working on a new project using last version of Thinking Sphinx, which works pretty well. But I've planned to use delayed delta as well with the ts-delayed-delta gem and I got the following exception when I try to lauch a rake task or the rails server.

ActiveRecord::ConnectionNotEstablished (ActiveRecord::ConnectionNotEstablished)

Here is the full gist : https://gist.github.com/956698

I'm using:

gem 'thinking-sphinx',
  :git     => 'git://github.com/freelancing-god/thinking-sphinx.git',
  :branch  => 'rails3'
gem 'ts-delayed-delta', '1.1.2',
  :require => 'thinking_sphinx/deltas/delayed_delta'
gem 'delayed_job', "~> 2.1.4"

Am I wrong with my gem versions or is it a bug ?

Many thanks

pat commented 13 years ago

First thing I'm thinking - Delayed Delta is probably expecting Delayed Job to already be set up - try putting delayed_job in your Gemfile above the other two gems.

fmalamitsas commented 13 years ago

Unfortunately I've already tried this, same result with :

gem 'delayed_job', "~> 2.1.4" gem 'thinking-sphinx', :git => 'git://github.com/freelancing-god/thinking-sphinx.git', :branch => 'rails3' gem 'ts-delayed-delta', '1.1.2', :require => 'thinking_sphinx/deltas/delayed_delta'

pat commented 13 years ago

Hmm, okay. I'll investigate further - hopefully later tonight once I've got client work out of the way.

fmalamitsas commented 13 years ago

Hi Pat, it seems to be due to another gem (attribute-normalizer) which was required before TS & ts-delayed delta in my Gemfile. Putting it after fixed the problem.

I close the issue.