Im using multer to upload FormData
to server,file binary alongside some text/objects.
Problem arises with files above 4~5gbs where post request is in pending state and than after a while it returns with POST http://localhost:5000/upload net::ERR_CONNECTION_RESET
What i've done is that i made middleware that does req.setTimeout
that solution didnt work,i went and tried req.connection.setTimout
same result. Afterwards with these attempts i just tested by putting globally server.timeout
to some high amount,same thing.
After this failed attempt i went ahead i tried adding connect-timeout
middleware library to the upload endpoint but no change.
After all these tries i then went ahead and asked chatGPT aswell that could be the possible issue with these timeouts and it gave me 2 different answers,1st answer was that connection_reset could be client "disconnecting" or closing connection,so i went ahead and added high number timeout
to axios
method im using to make a post request and that didnt help either. I'm wondering if there's maybe socket
object that handles this closing/opening of connections but again i tried req.connection
timeout and it did nothing.
Any help would be appreciated if anyone ever came accross this problem.