socket.io-stream icon indicating copy to clipboard operation
socket.io-stream copied to clipboard

XHR polling error

Open entcor opened this issue 10 years ago • 9 comments

Hi

I try use socket.io-stream for streaming socket.io requests! I have two nodejs servers connected by socket.io (v 1.0) and socket.io-client. All requests from first server by Express redirect by Socket.io chennel and anotwher side by Request (module) transit to first server by socket.io-stream. (request().pull(soi-stream))

f i use get or post queryes all ok but if i use xhr i have timeout on request().pull(soi-stream)

I can`t correct you code (all packed)

Thank you !

entcor avatar Jul 08 '14 01:07 entcor

Could you show me your code? I want to reproduce the issue.

nkzawa avatar Jul 08 '14 02:07 nkzawa

its really hardly (present code) try this link

https://docs.google.com/uc?authuser=0&id=0B-ZKZRQ2AMTZaHFEVHA1YjVNN3c&export=download

in map.jpg you can sea simple scheme

run s1,s2,s3 in browser open 127.0.0.1/test/1.html (it page will move from s3 node -> s2->s1 -> client) all ok but in this page used socket.io and i can't emit events through socket.io-stream tube :(

entcor avatar Jul 08 '14 12:07 entcor

And thank you ! :)

entcor avatar Jul 08 '14 12:07 entcor

@alnikitich sorry for late reply. I will check that on this weekend. thx!

nkzawa avatar Jul 10 '14 02:07 nkzawa

ok thx !

entcor avatar Jul 11 '14 11:07 entcor

@alnikitich I checked your code, but It was difficult to determine what the problem is actually because it has too many unrelated code to socket.io-stream. I'm sorry but could you make it simpler?

nkzawa avatar Jul 13 '14 16:07 nkzawa

@alnikitich Additionally, you can build unpacked version of socket.io-stream by using browserify. See README for that.

nkzawa avatar Jul 13 '14 16:07 nkzawa

At least, I noticed the following:

1.html

// client requests to '/newpath/socket.io'
var socket = io('http://127.0.0.1:7080', { 'path': '/newpath/socket.io' })

s1.js

// no setting for path option.
var ioserver = require('socket.io').listen(http_server);

This causes an error.

nkzawa avatar Jul 13 '14 17:07 nkzawa

it's not easy examlpe 1.html connecto to s3.js !!!! throught s1 & s2 s1 & s2 making socket.io-stream tube and s1 pack all requests to this tube

i try call s3.js socket.io throught another socket.io tube (s1-s2)

really hardly ....

:)

entcor avatar Jul 14 '14 05:07 entcor