I'm using docker-compose to coordinate a swarm of docker containers -- among them, a database and web server.
When the webserver starts up it expects the database to be available to connect to. But it's not.
Docker documentation offers wait-for-it as a workaround -- but I'd rather do as they ultimately suggest:
The best solution is to perform this check in your application code, both at startup and whenever a connection is lost for any reason.
I can't, however, find any mention of this in sqlalchemy docs. Should I begin writing my own try/catch for this?