The problem is the backend here, nginx does not do a retry on its own as that would be blocking a worker, you might be able to do a retry via cosockets (Lua) as thats not blocking. Or create more backends and load balance them.
In short the backend can't handle what nginx is passing on.
In short the backend can't handle what nginx is passing on.