Welcome Guest | Login

Acts_as_ferret throwing app. error

in my test application
i used acts_as_ferret in my model

follow this step

1. my app is located in /home/<myusername>/test

2. i created a model call freelancer

  in freelancer.rb
  class Freelancer < ActiveRecord::Base
     acts_as_ferret :remote => true
  end

3. in environtment.rb i added
    require 'acts_as_ferret'    
  to hook the plugin   into Rails

4. I go to console --> ruby script/console production
  and then
  >> freelan = Freelancer.find_by_contents("xxx")

   It shows error
 
DRb::DRbConnError: druby://localhost:9010 - #<Errno::ETIMEDOUT: Connection timed out - connect(2)>
       from /usr/local/lib/ruby/1.8/drb/drb.rb:736:in `open'
       from /usr/local/lib/ruby/1.8/drb/drb.rb:729:in `each'
       from /usr/local/lib/ruby/1.8/drb/drb.rb:729:in `open'
       from /usr/local/lib/ruby/1.8/drb/drb.rb:1189:in `initialize'
       from /usr/local/lib/ruby/1.8/drb/drb.rb:1169:in `new'
       from /usr/local/lib/ruby/1.8/drb/drb.rb:1169:in `open'
       from /usr/local/lib/ruby/1.8/drb/drb.rb:1085:in `method_missing'
       from /usr/local/lib/ruby/1.8/drb/drb.rb:1103:in `with_friend'
       from /usr/local/lib/ruby/1.8/drb/drb.rb:1084:in `method_missing'
from /usr/local/lib/ruby/gems/1.8/gems/acts_as_ferret-0.4.3/lib/remote_index.rb:16:in `send'
       from /usr/local/lib/ruby/gems/1.8/gems/acts_as_ferret-0.4.3/lib/remote_index.rb:16:in `method_missing'
       from /usr/local/lib/ruby/gems/1.8/gems/acts_as_ferret-0.4.3/lib/act_methods.rb:189:in `acts_as_ferret'
       from /home/flinkon/test/app/models/freelancer.rb:3
       from /usr/local/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_require'
       from /usr/local/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `require'
       from /usr/local/lib/ruby/gems/1.8/gems/activesupport-2.0.2/lib/active_support/dependencies.rb:496:in `require'
       from /usr/local/lib/ruby/gems/1.8/gems/activesupport-2.0.2/lib/active_support/dependencies.rb:342:in `new_constants_in'
       from /usr/local/lib/ruby/gems/1.8/gems/activesupport-2.0.2/lib/active_support/dependencies.rb:496:in `require'
       from /usr/local/lib/ruby/gems/1.8/gems/activesupport-2.0.2/lib/active_support/dependencies.rb:104:in `require_or_load'
       from /usr/local/lib/ruby/gems/1.8/gems/activesupport-2.0.2/lib/active_support/dependencies.rb:248:in `load_missing_constant'
       from /usr/local/lib/ruby/gems/1.8/gems/activesupport-2.0.2/lib/active_support/dependencies.rb:453:in `const_missing'
       from /usr/local/lib/ruby/gems/1.8/gems/activesupport-2.0.2/lib/active_support/dependencies.rb:465:in `const_missing'
       from (irb):1>>
------



When I try to search anything I get a application failed to start error. Any idea whats wrong?
and how to fix it?

2008-05-02 04:23 PM

Hi Link,

>>3. in environtment.rb i added
   require 'acts_as_ferret'    
In your user/test/config/environmment.rb file, you have written require "ferret".  If you are using acts_as_ferret plugin. Please download the corresponding plugin and change the
[ require "ferret" ] statement into [ require "acts_as_ferret"]. Please verify the corresponding plugin is available to your application by executing the command require "acts_as_ferret" inside the irb.

From the logs given by you, I can see the port using is :9010 Please use the port assigned to your account with the exact domain name. You need to change this in config/ferret_server.yml file.

2008-05-02 06:28 PM

i have this same problem - except I've got the require 'acts_as_ferret' in my environment.rb. I suspect that my problem is the port/domain name specified in my ferret_server.yml. the last post you say 'Please use the port assigned to your account with the exact domain name'. i'm not sure what you mean by that-- i've tried setting the domain to be 127.0.0.1 with a port of 9009, but it doesnt work (exact same error as by the original poster).

2008-08-02 12:28 PM

Hi, you should use your assigned port to run daemons like mongrel or ferret in your account. You should be able to find the assigned port from your account center page. Since you only have 50 MB dedicated memory, you' re allowed to run only a single daemon in your account using the port.If you still have questions regarding the port, please contact support so they can give you the exact value.

2008-08-02 01:47 PM


Hello Guest! In order to post you must be an active client with us, please log in or sign up.