juggernaut icon indicating copy to clipboard operation
juggernaut copied to clipboard

http://localhost:8080 Not responding

Open metzlar opened this issue 11 years ago • 14 comments

Hi, I am not very familiar with Node but I downloaded the latest Node pkg (0.10) from the nodejs.org website (I'm on OSX 10.6.8) and installed it and followed the juggernaut installation instructions. Redis is running fine and this is the output from the juggernaut command:

path.existsSync is now called `fs.existsSync`.
    info  - socket.io started

Anyway, now when I try to connect to http://localhost:8080/ or http://localhost:8080/application.js the connection seems to time out/fails after some minutes - so there seems to be something listening on 8080 but I do not get any response.

I tried running juggernaut thru sudo, on different ports and directly thru ./server.js but I just can not get it to work. Any thoughts? Thanks

metzlar avatar May 07 '13 16:05 metzlar

Do you get any messages from juggernaut on connecting?

Cane you please post the output form the command "netstat -pan | grep node" and "netstat -pan | grep 8080" if the Server are running?

xedp3x avatar May 07 '13 17:05 xedp3x

I installed socket.io to fool around with it. This did not solve the problem with juggernaut but I am getting more output now:

$ juggernaut
    path.existsSync is now called `fs.existsSync`.
       info  - socket.io started
       debug - client authorized
       info  - handshake authorized 847919531562013476
       debug - client authorized
       info  - handshake authorized 1946779245526333349
       etc...

The output from netstat is:

$ netstat -anp tcp | grep node
    no output...

$ netstat -an | grep node
    Address          Type   Recv-Q Send-Q            Inode  etc...

$ netstat -an | grep 8080
    tcp4       0      0  *.8080                 *.*                    LISTEN

metzlar avatar May 08 '13 00:05 metzlar

Actually the output client authorized and handshake authorized were from a javascript I wrote earlier and still had open in my browser. I guess juggernaut seems to be connectable by a socket from socket.io but somehow I still can not connect to http://localhost:8080/application.js or any url at localhost:8080.

metzlar avatar May 08 '13 00:05 metzlar

I have exactly the same problem. I get the same output and get a timeout after certain minutes. Any progress on this issue?

malagant avatar May 13 '13 09:05 malagant

Same here

analla avatar Jun 22 '13 05:06 analla

same... plz

zengjing avatar Jul 01 '13 03:07 zengjing

same here

s-block avatar Jul 21 '13 20:07 s-block

Juggernaut is deprecated. Use Server Sent events [1]. If you want a high abstraction I've written a Sinatra pubsub extension. [2]

[1] - http://blog.alexmaccaw.com/killing-a-library [2] - https://github.com/maccman/sinatra-pubsub

On Sun, Jul 21, 2013 at 1:46 PM, Josh [email protected] wrote:

same here

— Reply to this email directly or view it on GitHubhttps://github.com/maccman/juggernaut/issues/135#issuecomment-21316731 .

maccman avatar Jul 22 '13 01:07 maccman

If anyone else has this problem, install an older version of node. You can use https://github.com/creationix/nvm, juggernaut seems to be working on node v0.6.21-pre.

fuzzmonkey avatar Jul 24 '13 22:07 fuzzmonkey

@maccman One problem with that "high abstraction", not only your implementation but all of them, is that Rack doesn't really support it. So in Sinatra, Rails and everything else I've seen, there's no way to do it that's portable across app servers.

For instance, yours supports "Evented" servers -- I'm assuming that's Thin and Puma. But no Unicorn, Racer, WEBrick, etc., nor most JRuby servers.

That's a common problem with all the SSE stuff. Again, Rails has basically the same problem. You can support non-evented servers, sort of, but the same code doesn't work. Rails also makes development mode very painful for SSE because of threading/reloading problems -- MRI doesn't support thread-safe code reloading, so Rails won't do multiple threads with code reloading, and SSE requires multiple threads currently (and forever?).

With that said, we now have websocket support in basically all the latest browsers. So they're not a bad choice any more. Better than SSE, probably, at this point -- less browser support, but much less painful framework support.

noahgibbs avatar Sep 10 '13 04:09 noahgibbs

@fuzzmonkey - Thanks, that worked for me. I was on node v0.10.21 ... after installing v0.6.21 through nvm, I launched http://localhost:8080 and saw the Juggernaut Hello World page instantly. Thanks again!

hgosalia avatar Jan 20 '14 20:01 hgosalia

@hgosalia i'd suggest switching to maintained project. You should check out http://faye.jcoglan.com.

fuzzmonkey avatar Jan 27 '14 13:01 fuzzmonkey

I found that I needed specify an old version for the node. And that I must use engines instead engine.

alexandre-mbm avatar Mar 11 '15 11:03 alexandre-mbm

I was a bit reluctant at first, but the switch to Faye really was quite easy. The Railscast of Faye is still quite current, and the hardest part was writing a utility method that posted messages to the Faye server from (in my case) a Rails controller. It'd be wise to implement the incoming message security mentioned in the Railscast also.

brendon avatar Aug 12 '15 03:08 brendon