Replies: 1 comment
-
|
Same issue. Any solution for this? |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Description
I've just switched from Node 18 to Node 20 and i'm currently encountering a problem with a microservice deployed that does some multiple calls to another one using graphql-request. First call is working well but the other call raise the following error
Fetch something: request to http://myurl.svc.cluster.local:3002/internal-graphql failed, reason: socket hang upAfter some search it seems on node 20 and node 22 the default keep-alive value in createServer has been changed from false to true. It seems it cause error in graphql-request as the previous connection is not closed so we encounter the 'socket hang up' error.
I'm using graphql-request@6.1.0. Was not able yet to update to the last version due to esm compilation issues in typescript.
This error appears only when the microservice is deployed. In local all is working fine. I have fixed in another project by setting back the keep-alive option in createServer to false but for this particular it seems to have no effect.
Did someone encountered this issue and has a workaround?
Related Links
node-fetch issue
axios issue
socket hang up error
Beta Was this translation helpful? Give feedback.
All reactions