https://trino.io/docs/current/develop/client-protocol.html#overview-of-query-processing
If the client request returns an HTTP 502, 503, or 504, that means there was an intermittent problem processing request and the client should try again in 50-100 ms. Trino does not generate those codes by itself, but those can be generated by load balancers in front of Trino.
Checklist
[x] Code compiles correctly
[ ] Created tests which fail without the change (if possible)
[x] All tests passing
[ ] Extended the README / documentation, if necessary
Purpose
Retry GET against 502, 504 responses.
Overview
According to the trino client protocol, it should also retry for 502 and 504. (https://github.com/treasure-data/trino-client-ruby/issues/128)
Checklist