400 (Unknown SID) on Heroku

119 views
Skip to first unread message

aslak hellesoy

unread,
Nov 7, 2013, 6:57:56 AM11/7/13
to sha...@googlegroups.com
Hi everyone,

My app uses ShareJS v0.7.0-alpha9 with browserchannel 1.0.8. Everything works smoothly when the server runs locally.
On Heroku collaborative editing just barely works. It's sluggish and lossy.

Looking in the browser console I see a lot of this:

GET https://__mydomain__.com/channel/bind?OSID=0uxhj8ua&OAID=1&VER=8&RID=rpc&SID=0mz0dgax&CI=0&AID=1&TYPE=xmlhttp&zx=auzp29u91ps9&t=1 400 (Unknown SID) bcsocket-uncompressed.js:1818
GET https://__mydomain__.com/channel/bind?OSID=0mz0dgax&OAID=1&VER=8&RID=rpc&SID=bgebgka1&CI=0&AID=1&TYPE=xmlhttp&zx=b8ww70hzr50w&t=1 400 (Unknown SID) bcsocket-uncompressed.js:1818

I'm guessing this is Heroku clipping the browserchannel connection because they don't like long lived HTTP connections. Am I right in assuming that?

It also seems to me that browserchannel fails to reconnect, but I'm not sure why. Does anyone know what's causing the 400 (Unknown SID) error?

Any help working around this would be greatly appreciated.

Thanks!

Aslak

aslak hellesoy

unread,
Nov 7, 2013, 11:15:55 AM11/7/13
to sha...@googlegroups.com
I found out what the problem is. Browserchannel in a load-balanced setup only works if sessions are sticky (and they are not on Heroku).

It would probably work if browserchannel processes could use used a shared session store such as redis.

I have create a ticket in browserchannel: https://github.com/josephg/node-browserchannel/issues/32

Thoughts?
Aslak

Joseph Gentle

unread,
Nov 7, 2013, 2:47:58 PM11/7/13
to sha...@googlegroups.com
I've replied in the issue.
> --
> You received this message because you are subscribed to the Google Groups
> "ShareJS" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to sharejs+u...@googlegroups.com.
> For more options, visit https://groups.google.com/groups/opt_out.
Reply all
Reply to author
Forward
0 new messages