Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

process-compose gets stuck on quit if clickhouse init db fails #361

Open
conscious-puppet opened this issue Oct 12, 2024 · 2 comments · May be fixed by #385
Open

process-compose gets stuck on quit if clickhouse init db fails #361

conscious-puppet opened this issue Oct 12, 2024 · 2 comments · May be fixed by #385
Labels
bug Something isn't working

Comments

@conscious-puppet
Copy link
Contributor

process-compose gets stuck on quit if the the clickhouse init db service fails. we need to manually kill the clickhouse process.

the issue can be reproduced by using a malformed initial db dump with the clickhouse service.

asciicast

@shivaraj-bh
Copy link
Member

Here’s the culprit:

clickhouse-server --config-file=${clickhouseConfig} &
sleep 5s
echo "Clickhouse server started."
${setupInitialDatabases}
echo "Clickhouse db setting is done."
kill %1

During init the server starts and because the schema files have errors, and exits with non-zero exit-code, the script stops before killing the server.

@shivaraj-bh
Copy link
Member

shivaraj-bh commented Oct 27, 2024

The easiest fix is to run the shell script without breaking on errors in any intermediate command.

But, I would like to see if we can just avoid starting the clickhouse-server in the init script, by just waiting for the server process to start and then init the schemas.

pinging @roman-bodavskiy to see if you have any opinion on this as you worked on this in #91

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants