Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upMySQL container started message is misleading #2878
Comments
|
@bsideup I could take it |
|
I am not really sure what behaviour got observed in this issue. If the Since you were able to run exec commands against the container after startup, it seems startup wait strategy was successful and the container started successfully. Or am I misunderstanding anything here? |
|
Can we close this issue? |


Hi,
Very regularly we see that the MySQL container fails to start under the default 2mn timeout (120s). We've even increased that to 4mn and still fails (I've now increased it to 15mn to see what happens).
Anyway the point is that TC tries issue a SQL query to verify it's started during the defined timeout and if it doesn't succeed it just says that the DB is started, with:
What happens here is:
Container is started (JDBC URL: jdbc:mysql://172.17.0.1:37489/xwiki)andContainer mysql:8.0 started in PT4M9.07S, which is not correct. The DB container logs show it's not started yet.ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock'I find it misleading to consider it's started if the SQL hasn't worked. At least the message should be different in this case, something like "Failed to verify that MySQL was started during ... seconds and couldn't. It's possible it's not started.".
The alternative is to throw an exception, i.e. to not go further if it's not started within the timeout.
WDYT?