spdy-http2 / node-spdy

SPDY server on Node.js
2.81k stars 196 forks source link

Not working with Safari 8. #182

Closed nmn closed 9 years ago

nmn commented 9 years ago

I have a node server that uses Koa and SPDY. It works fine in Chrome, but it fails to return a response in Safari 8 (both OS X and iOS). If I just switch to https instead of spdy everything starts working fine.

Is this a problem with node-spdy or a bug in Safari? I can't seem to be able to find out. Any help would be great!

Thanks.

indutny commented 9 years ago

@naman34 may I ask you to post some test case for me?

Sorry for kind of silly question, but are you opening the url with https:// prefix? (I just seen many issues here from people who thought that SPDY doesn't need this).

indutny commented 9 years ago

Also, what node.js and node-spdy versions are you using?

nmn commented 9 years ago

I'm not sure what you mean by test case. Here's some code:

var spdy = require('https');
var fs = require('fs');
var options = {
    key: fs.readFileSync(__dirname + '/server.key'),
    cert: fs.readFileSync(__dirname + '/server.crt'),
    ca: fs.readFileSync(__dirname + '/server.csr')
};

/// app = koa() etc etc.

spdy.createServer(options, app.callback()).listen(443);

As for the https://, I was trying https to use the website. In fact, the app is also listening on port 80 via http, and that was always working. It was the https that was giving me a problem.

I tried the same code locally and I get the same error. Safari keeps waiting for a response forever, Chrome works fine.

In case you definitely need a live site to test this, I'll try to set it on another test server. But I have a very basic use case at the moment, so any test server with spdy tested with Safari 8 should be good enough.

netpoetica commented 9 years ago

@naman34 Is it possible you could run some of the examples in this repo at /examples and see if you can produce the same results with one of them? This way indutny will have full, runnable code to test.

Also, definitely post your node version and which version of this library you're using (run node -v for node version and your package.json should have the node-spdy version)

nmn commented 9 years ago

Oh. So sorry. I had forgotten to tell you the version I was using. I'm using the latest unstable node : v0.11.14 And I was using v1.29.0 of node-spdy

I realised a new release came out two days ago, and everything works fine now that I updated!

Thanks, and sorry for wasting your time. I had check just three days ago for new releases. :(