facebookarchive / contest

Run continuous and on-demand system testing for real and virtual hardware
MIT License
32 stars 15 forks source link

Fix race condition in docker-compose #302

Closed mimir-d closed 3 years ago

mimir-d commented 3 years ago

=========== BEFORE

# docker-compose up Creating network "contest_net" with the default driver Creating contest_mysql_1 ... done Creating contest_contest_1 ... done Attaching to contest_mysql_1, contest_contest_1 mysql_1 | 2021-09-25 15:35:44+00:00 [Note] [Entrypoint]: Entrypoint script for MySQL Server 8.0.26-1debian10 started. mysql_1 | 2021-09-25 15:35:44+00:00 [Note] [Entrypoint]: Initializing database files mysql_1 | 2021-09-25T15:35:44.929213Z 0 [Warning] [MY-010139] [Server] Changed limits: max_open_files: 1024 (requested 8161) mysql_1 | 2021-09-25T15:35:44.929221Z 0 [Warning] [MY-010142] [Server] Changed limits: table_open_cache: 431 (requested 4000) mysql_1 | 2021-09-25T15:35:44.929677Z 0 [System] [MY-013169] [Server] /usr/sbin/mysqld (mysqld 8.0.26) initializing of server in progress as process 23 mysql_1 | 2021-09-25T15:35:44.938728Z 1 [System] [MY-013576] [InnoDB] InnoDB initialization has started. mysql_1 | 2021-09-25T15:35:46.102116Z 1 [System] [MY-013577] [InnoDB] InnoDB initialization has ended. contest_1 | [2021-09-25T15:35:47.553Z I pluginregistry.go:63] Registering target manager csvfiletargetmanager contest_1 | [2021-09-25T15:35:47.553Z I pluginregistry.go:63] Registering target manager targetlist contest_1 | [2021-09-25T15:35:47.553Z I pluginregistry.go:76] Registering test fetcher literal contest_1 | [2021-09-25T15:35:47.553Z I pluginregistry.go:76] Registering test fetcher uri contest_1 | [2021-09-25T15:35:47.553Z I pluginregistry.go:89] Registering test step cmd contest_1 | [2021-09-25T15:35:47.553Z I pluginregistry.go:89] Registering test step sleep contest_1 | [2021-09-25T15:35:47.553Z I pluginregistry.go:89] Registering test step sshcmd contest_1 | [2021-09-25T15:35:47.553Z I pluginregistry.go:113] Registering reporter targetsuccess contest_1 | [2021-09-25T15:35:47.553Z I server.go:173] Using database URI for primary storage: contest:contest@tcp(dbstorage:3306)/contest_integ?parseTime=true contest_1 | [2021-09-25T15:35:47.554Z F server.go:176] Could not initialize database: unable to contact database: dial tcp 172.21.0.2:3306: connect: connection refused contest_1 | exit status 1 contest_contest_1 exited with code 1

========= AFTER

# docker-compose up Creating network "contest_net" with the default driver Creating contest_mysql_1 ... done Creating contest_contest_1 ... done Attaching to contest_mysql_1, contest_contest_1 mysql_1 | 2021-09-25 15:37:11+00:00 [Note] [Entrypoint]: Entrypoint script for MySQL Server 8.0.26-1debian10 started. mysql_1 | 2021-09-25 15:37:11+00:00 [Note] [Entrypoint]: Initializing database files mysql_1 | 2021-09-25T15:37:11.250106Z 0 [Warning] [MY-010139] [Server] Changed limits: max_open_files: 1024 (requested 8161) mysql_1 | 2021-09-25T15:37:11.250111Z 0 [Warning] [MY-010142] [Server] Changed limits: table_open_cache: 431 (requested 4000) mysql_1 | 2021-09-25T15:37:11.250491Z 0 [System] [MY-013169] [Server] /usr/sbin/mysqld (mysqld 8.0.26) initializing of server in progress as process 22 mysql_1 | 2021-09-25T15:37:11.257495Z 1 [System] [MY-013576] [InnoDB] InnoDB initialization has started. mysql_1 | 2021-09-25T15:37:11.729098Z 1 [System] [MY-013577] [InnoDB] InnoDB initialization has ended. mysql_1 | 2021-09-25T15:37:12.979729Z 0 [Warning] [MY-013746] [Server] A deprecated TLS version TLSv1 is enabled for channel mysql_main [...] contest_1 | [2021-09-25T15:37:28.703Z I server.go:173] Using database URI for primary storage: contest:contest@tcp(dbstorage:3306)/contest_integ?parseTime=true contest_1 | [2021-09-25T15:37:28.712Z I server.go:187] Storage version: 5 contest_1 | [2021-09-25T15:37:28.712Z I server.go:193] Using database URI for replica storage: contest:contest@tcp(dbstorage:3306)/contest_integ?parseTime=true contest_1 | [2021-09-25T15:37:28.714Z I server.go:207] Storage version: 5 contest_1 | [2021-09-25T15:37:28.714Z I server.go:235] Locker engine set to auto, using DBLocker contest_1 | [2021-09-25T15:37:28.715Z D storage.go:102] consistency model check: contest_1 | [2021-09-25T15:37:28.717Z I jobmanager.go:223] Found 0 zombie jobs for /a35868b6cb37 contest_1 | [2021-09-25T15:37:28.717Z D httplistener.go:253] Serving a listener contest_1 | [2021-09-25T15:37:28.717Z I httplistener.go:230] Started HTTP API listener on :8080

codecov[bot] commented 3 years ago

Codecov Report

Merging #302 (f9feaa8) into main (784d571) will not change coverage. The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##             main     #302   +/-   ##
=======================================
  Coverage   68.61%   68.61%           
=======================================
  Files         141      141           
  Lines        7991     7991           
=======================================
  Hits         5483     5483           
  Misses       1953     1953           
  Partials      555      555           
Flag Coverage Δ
e2e 50.29% <ø> (ø)
integration 59.69% <ø> (ø)
unittests 50.41% <ø> (+0.05%) :arrow_up:

Flags with carried forward coverage won't be shown. Click here to find out more.


Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 784d571...f9feaa8. Read the comment docs.

tfg13 commented 3 years ago

Do we also need this fix for the mariadb version of docker-compose?