josephholsten / rets4r

Bringing RETS to ruby
MIT License
52 stars 28 forks source link

Requester Should Recover From Timeout #12

Open josephholsten opened 13 years ago

josephholsten commented 13 years ago

We need more logging to find out the right way to recover here. We should learn how long it has been trying to make the request, at least.

From this issue in hoptoad: http://mobicentric.hoptoadapp.com/errors/2052652

Error Message: Errno::ETIMEDOUT: Connection timed out - connect(2)

Where: /usr/ruby1.8.7/lib/ruby/1.8/net/http.rb, line 560

Backtrace Summary:

/usr/ruby1.8.7/lib/ruby/1.8/net/http.rb:560:in `initialize'
/usr/ruby1.8.7/lib/ruby/1.8/net/http.rb:560:in `open'
/usr/ruby1.8.7/lib/ruby/1.8/net/http.rb:560:in `connect'
/usr/ruby1.8.7/lib/ruby/1.8/timeout.rb:53:in `timeout'
/usr/ruby1.8.7/lib/ruby/1.8/timeout.rb:93:in `timeout'
/usr/ruby1.8.7/lib/ruby/1.8/net/http.rb:560:in `connect'
/usr/ruby1.8.7/lib/ruby/1.8/net/http.rb:553:in `do_start'
/usr/ruby1.8.7/lib/ruby/1.8/net/http.rb:542:in `start'
.bundle/gems/ruby/1.8/bundler/gems/rets4r-1ef13955a443/lib/rets4r/client/requester.rb:77:in `request'
.bundle/gems/ruby/1.8/bundler/gems/rets4r-1ef13955a443/lib/rets4r/client.rb:461:in `request'
.bundle/gems/ruby/1.8/bundler/gems/rets4r-1ef13955a443/lib/rets4r/client.rb:205:in `login'
lib/rets_service/search_response.rb:43:in `each'
lib/job/photo_sync/two_pass_strategy.rb:28:in `map'
lib/job/photo_sync/two_pass_strategy.rb:28:in `remove_orphaned_photos'
lib/job/photo_sync/two_pass_strategy.rb:10:in `sync_photos'
lib/job/photo_sync.rb:7:in `perform_without_newrelic_transaction_trace'
(eval):3:in `perform'
jDeppen commented 12 years ago

Any news on this? Can we extend the default timeout or is that on the MLS side? How do you recommend we recover from this error. Thanks