How to start, stop and resume a Cloud service using the ClickHouse API and cURL
Question
How can a ClickHouse Cloud service be started, stopped and resumed using API endpoints?Answer
- To wake up/resume a Cloud service from an idle state, you can ping the instance:
- To stop a Cloud service, use the
/stateendpoint along with thestopcommand. The syntax looks like:
2e2124ca-c5ac-459d-a6f2-abc123549d2a service:
- To start the service again, use the
startcommand:
Here are the various states that a service can be in:
A Cloud service that is “idle” is considered started, so a
start command will not resume/wake it up. Use the ping endpoint shown in Step 1 to wake up a service.