Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

Associating to stream ID value is not being sent when passed as an option in SynStream#create #5

inkel opened this Issue Oct 8, 2011 · 4 comments


None yet
3 participants

inkel commented Oct 8, 2011

I've been playing with some very basic examples trying to figure out how to do Server Push and I've come with a working solution, though probably imperfect, but I've found an issue while trying to create a SYN_STREAM from the server associated with the request stream ID.

Checking the events tab in Chrome's about:net-internals I saw that the client was sending SPDY_SESSION_SEND_RST_STREAM and carefully looking found that associated_to_stream_id wasn't being sent by the server.

I tried passing the default value in SynStream.new and SynStream#create with no luck, until I realize that it was a property, so I proceed to instantiate the SynStream and then passing the request stream ID to SynStream#associated_to_stream_id=.

It's likely that I did something wrong, but if you perhaps could try it and check that is working that'd be great.

I hope this helps.


igrigorik commented Oct 14, 2011

Hmm, that's a gotcha.. You're right, reviewing the code, the build method instantiates the header with the options, but because associated_to_stream_id is not part of that, it doesn't get picked up.

Probably worth a refactor / revisit to address this. Wonder if as part of build we can call .delete on the opts hash and then apply the rest of the fields after we call build.

inkel commented Oct 14, 2011

I truly cannot say anything about that, but I think a refactor it's necessary so associating to another stream uses the same interface when building SynStream.

I'd also wonder if it's possible that create already calls to_binary_s on the returned value, because I saw that, at least in my tests, I never use the actual value returned by create but instead calling EventMachine#send_data with the result binary string.


authorNari commented Jan 25, 2013

I think this issue has fixed with 91f61f4 :)


igrigorik commented Jan 25, 2013

Indeed! Thanks @authorNari. :)

@igrigorik igrigorik closed this Jan 25, 2013

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