You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Jul 12, 2023. It is now read-only.
Repository navigation
This repository was archived by the owner on Jul 12, 2023. It is now read-only.
Got request timeout from nodejs api after a long period of inactivity #1
I have connected to KMS using kurento-client through secure websocket. It worked as well. I left my node server running with this open connection for a night, - no communication happened and now in the morning i've tried to register a new pipeline.
Using: KMS 6.1.1 on a distant network
{ [Error: Request has timed out]
request: '{"jsonrpc":"2.0","method":"create","params":{"type":"MediaPipeline","sessionId":"1af516ae-068d-43ff-ac81-1d00ad3e083c"},"id":23}',
retry: [Function: retry] }
Error: Request has timed out
at /workspace/videochat/node_modules/kurento-client/lib/KurentoClient.js:332:24
at /workspace/videochat/node_modules/kurento-client/lib/KurentoClient.js:504:16
at callback2 (/workspace/videochat/node_modules/promisecallback/index.js:27:25)
at lib$es6$promise$$internal$$tryCatch (/workspace/videochat/node_modules/es6-promise/dist/es6-promise.js:331:16)
at lib$es6$promise$$internal$$invokeCallback (/workspace/videochat/node_modules/es6-promise/dist/es6-promise.js:343:17)
at /workspace/videochat/node_modules/es6-promise/dist/es6-promise.js:891:13
at lib$es6$promise$asap$$flush (/workspace/videochat/node_modules/es6-promise/dist/es6-promise.js:125:9)
at process._tickDomainCallback (node.js:381:11)
We are debugging this. I'll get back to you as soon as we have solid info, but basically once the connection is lost, we are not reconnecting if needed. This happens after a certain idle time. There are workarounds and things that could be done about it, but we have a library that should be reconnecting. It looks like it's not working as it should.
This still happen with kurento-client-js 6.2, somehow the connection die and reconnect not working so right now I have to capture the request timeout error and call client._re._connection.end() to force reconnection again.
I get the Error: Request has timed out. A quick hack to fix this would also be appreciated. @sainttail can you please share the fix that you mention in this thread?
Activity
jcaden commentedon Oct 14, 2015
Can to attach kms log please?
tgabi333 commentedon Oct 14, 2015
[removed links]
Thank you
jcaden commentedon Oct 14, 2015
This request didn't arrived to the server. There should be a problem with the reconnection of the websocket.
igracia commentedon Oct 14, 2015
@rbenitez Could you verify this, please? It seems like an issue in the KurentoClient in JavaScript. We should be reconnecting.
tgabi333 commentedon Oct 15, 2015
same happened today :(
jcaden commentedon Oct 15, 2015
I guess it will be happening until reconnection is fixed 😄
tgabi333 commentedon Oct 15, 2015
How can i help, in which repo?
igracia commentedon Oct 15, 2015
We are debugging this. I'll get back to you as soon as we have solid info, but basically once the connection is lost, we are not reconnecting if needed. This happens after a certain idle time. There are workarounds and things that could be done about it, but we have a library that should be reconnecting. It looks like it's not working as it should.
sainttail commentedon Nov 30, 2015
This still happen with kurento-client-js 6.2, somehow the connection die and reconnect not working so right now I have to capture the request timeout error and call client._re._connection.end() to force reconnection again.
igracia commentedon Nov 30, 2015
@rbenitez Did you have a chance to take a look at this?
rbenitez commentedon Nov 30, 2015
Hi @sainttail, please could you tell me which version are you using of kurento-client-js?
Thanks
sainttail commentedon Nov 30, 2015
@rbenitez I'm currently using kurento-client-js 6.2.0 which just release recently.
rbenitez commentedon Nov 30, 2015
Ok, I will investigate what's the problem. I will tell you something as soon as possible.
Best
igracia commentedon Dec 18, 2015
@rbenitez Do we have new info on this?
morokhovets commentedon Jan 25, 2016
@rbenitez @igracia Is there any progress?
Or are there any good hacks to work around this issue?
rbenitez commentedon Mar 6, 2016
We have implemented a ping/pong mechanism and we have reimplemented the reconnection way, please update kurento-client at master version.
Best.
dfernandezlop commentedon Mar 11, 2016
@rbenitez can we close the bug?
rbenitez commentedon Mar 11, 2016
Yes.
Thanks
dfernandezlop commentedon Mar 11, 2016
Ok, I'm closing the thread.
abhikandoi commentedon Dec 3, 2017
Hey guys I am still facing this issue. I am using kurento-media-server version
6.6.2:Here is the version output:
I am using the kurento-client version
6.6.0:I get the Error:
Request has timed out. A quick hack to fix this would also be appreciated.@sainttail can you please share the fix that you mention in this thread?