Actions
Bug #13431
closedsample/drb/http0*.rb is not working.
Description
I tried to use drb over http with the sample code sample/drb/http0.rb*
I wrote the code as following.
server.rb
require 'drb/drb'
require_relative './http0serv'
class SampleObject
def test
"ACK!"
end
end
DRb.start_service("http://127.0.0.1:1234", SampleObject.new)
DRb.thread.join
client.rb
require 'drb/drb'
require_relative './http0'
remote = DRbObject.new_with_uri "http://127.0.0.1:1234"
puts remote.test
This results in the following.
/Users/youchan/.rbenv/versions/2.4.1/lib/ruby/2.4.0/net/protocol.rb:176:in `rbuf_fill': Net::ReadTimeout (Net::ReadTimeout)
from /Users/youchan/.rbenv/versions/2.4.1/lib/ruby/2.4.0/net/protocol.rb:154:in `readuntil'
from /Users/youchan/.rbenv/versions/2.4.1/lib/ruby/2.4.0/net/protocol.rb:164:in `readline'
from /Users/youchan/.rbenv/versions/2.4.1/lib/ruby/2.4.0/net/http/response.rb:40:in `read_status_line'
from /Users/youchan/.rbenv/versions/2.4.1/lib/ruby/2.4.0/net/http/response.rb:29:in `read_new'
from /Users/youchan/.rbenv/versions/2.4.1/lib/ruby/2.4.0/net/http.rb:1446:in `block in transport_request'
from /Users/youchan/.rbenv/versions/2.4.1/lib/ruby/2.4.0/net/http.rb:1443:in `catch'
from /Users/youchan/.rbenv/versions/2.4.1/lib/ruby/2.4.0/net/http.rb:1443:in `transport_request'
from /Users/youchan/.rbenv/versions/2.4.1/lib/ruby/2.4.0/net/http.rb:1416:in `request'
from /Users/youchan/.rbenv/versions/2.4.1/lib/ruby/2.4.0/net/http.rb:1409:in `block in request'
from /Users/youchan/.rbenv/versions/2.4.1/lib/ruby/2.4.0/net/http.rb:877:in `start'
from /Users/youchan/.rbenv/versions/2.4.1/lib/ruby/2.4.0/net/http.rb:1407:in `request'
from /Users/youchan/.rbenv/versions/2.4.1/lib/ruby/2.4.0/net/http.rb:1430:in `send_entity'
from /Users/youchan/.rbenv/versions/2.4.1/lib/ruby/2.4.0/net/http.rb:1218:in `post'
from /Users/youchan/Projects/tmp/drb_over_http/http0.rb:67:in `post'
from /Users/youchan/Projects/tmp/drb_over_http/http0.rb:54:in `send_request'
from /Users/youchan/.rbenv/versions/2.4.1/lib/ruby/2.4.0/drb/drb.rb:1253:in `send_message'
from /Users/youchan/.rbenv/versions/2.4.1/lib/ruby/2.4.0/drb/drb.rb:1142:in `block (2 levels) in method_missing'
from /Users/youchan/.rbenv/versions/2.4.1/lib/ruby/2.4.0/drb/drb.rb:1229:in `open'
from /Users/youchan/.rbenv/versions/2.4.1/lib/ruby/2.4.0/drb/drb.rb:1141:in `block in method_missing'
from /Users/youchan/.rbenv/versions/2.4.1/lib/ruby/2.4.0/drb/drb.rb:1160:in `with_friend'
from /Users/youchan/.rbenv/versions/2.4.1/lib/ruby/2.4.0/drb/drb.rb:1140:in `method_missing'
from client.rb:6:in `<main>'
Actions
Like0
Like0Like0Like0Like0