EOFError end of file error with publish_to under ssl #49

Closed
cctalbott opened this Issue Mar 28, 2012 · 1 comment

Comments

Projects
None yet
1 participant

Keep getting EOFError end of file error with publish_to when running under ssl. Acts kind of like the private_pub_token/secret_token is getting garbled somewhere when using ssl.

Returns success when running curl statement something like this:
curl https://domain.com:4443/faye -d 'message={"channel":"/the/channel", "data":"hello", "ext":{"private_pub_token":"secret_token"}'

PrivatePub.publish_to("/the/channel", "hello") Fails in browser and rails console seemingly no matter what tweaks I've made to it and the server over the past couple days.

Faye is backed with thin and server is ubuntu linux with rails running on nginx + unicorn.

Here's the the lines pertaining to private_pub from the error response:
from /usr/local/rvm/gems/ruby-1.9.3-p125/gems/private_pub-1.0.1/lib/private_pub.rb:34:in publish_message
from /usr/local/rvm/gems/ruby-1.9.3-p125/gems/private_pub-1.0.1/lib/private_pub.rb:28:in publish_to
which are:
line 34 publish_message(message(channel, data))
line 28 url = URI.parse(config[:server])

Got it working as advertised. Added require 'net/https' and require 'uri' to lib/private_pub. Think it's the uri require that got it going.

@cctalbott cctalbott closed this Mar 29, 2012

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment