Hello!
I have a problem when some HTTP requests fail before even sending them. The backend is handled on AWS lambda, communicating with API gateway via http requests.
The error log:
LogHttp: Warning: 0000025BEFAD2B00: SeekCallback: Failed to seek to Offset=0, Origin=0 seek disabled
LogHttp: Warning: 0000025BEFAD2B00: invalid HTTP response code received. URL: https://*/dev/handshake, HTTP code: 0, content length: 0, actual payload size: 0
LogHttp: Warning: 0000025BEFAD2B00: request failed, libcurl error: 56 (Failure when receiving data from the peer)
LogHttp: Warning: 0000025BEFAD2B00: libcurl info message cache 0 (Found bundle for host *.execute-api.eu-central-1.amazonaws.com: 0x25b01007070 [can pipeline])
LogHttp: Warning: 0000025BEFAD2B00: libcurl info message cache 1 (Re-using existing connection! (#1) with host *.execute-api.eu-central-1.amazonaws.com)
LogHttp: Warning: 0000025BEFAD2B00: libcurl info message cache 2 (Connected to .execute-api.eu-central-1.amazonaws.com (3.124.111.125) port 443 (#1))
LogHttp: Warning: 0000025BEFAD2B00: libcurl info message cache 3 (We are completely uploaded and fine)
LogHttp: Warning: 0000025BEFAD2B00: libcurl info message cache 4 (OpenSSL SSL_read: SSL_ERROR_SYSCALL, errno 10054)
LogHttp: Warning: 0000025BEFAD2B00: libcurl info message cache 5 (Connection died, retrying a fresh connect)
LogHttp: Warning: 0000025BEFAD2B00: libcurl info message cache 6 (Closing connection 1)
LogHttp: Warning: 0000025BEFAD2B00: libcurl info message cache 7 (Issue another request to this URL: 'https:///dev/handshake’)
LogHttp: Warning: 0000025BEFAD2B00: libcurl info message cache 8 (Found bundle for host *.execute-api.eu-central-1.amazonaws.com: 0x25b01007070 [can pipeline])
LogHttp: Warning: 0000025BEFAD2B00: libcurl info message cache 9 (Re-using existing connection! (#3) with host *.execute-api.eu-central-1.amazonaws.com)
LogHttp: Warning: 0000025BEFAD2B00: libcurl info message cache 10 (Connected to *.execute-api.eu-central-1.amazonaws.com (18.185.225.109) port 443 (#3))
LogHttp: Warning: 0000025BEFAD2B00: libcurl info message cache 11 (We are completely uploaded and fine)
LogHttp: Warning: 0000025BEFAD2B00: libcurl info message cache 12 (OpenSSL SSL_read: SSL_ERROR_SYSCALL, errno 10054)
LogHttp: Warning: 0000025BEFAD2B00: libcurl info message cache 13 (Connection died, retrying a fresh connect)
LogHttp: Warning: 0000025BEFAD2B00: libcurl info message cache 14 (seek callback returned error 2)
LogHttp: Warning: 0000025BEFAD2B00: libcurl info message cache 15 (Closing connection 3)
What I found out (may be wrong), what is happening is that the game sends a lot of http requests, some of them opens new connections, some of them reuses old one. If one connection is not used for a while, it gets closed. When the game tries to send a new requests, it finds out that the connection died alread → error.
In UE4 4.26 (or was it in .25?) version, they implemented rewind if the send is failed, it can rewind and send again, which is great. Now when it finds a dead connection, it gets a new connection, rewinds the data, and sends it again. It is great, unless it finds a dead connection again the second time. What I’ve gathered, UE4 CURL implementation uses 16 connections, so if one connection can die, so can 2, the chance to find 2 dead connections in sequence is not that small, and somehow it is written in the curl implementation that it can only rewind the data once (no idea why, I don’t think the Seek function should decide how many times a packet can be retried…).
I’m not proficient on CURL implementation, not sure why the connections die, or why does the engine tries to use dead connections, also not sure if it’s a problem on AWS end, or unreal implementation, or usage.
The problem appears for every user (different setups, different networks), the game is available only on PC, if it matters.
Can anyone help me please?