8000 Soft coordinator shutdown documentation by neunhoef · Pull Request #14356 · arangodb/arangodb · GitHub
[go: up one dir, main page]

Skip to content

Soft coordinator shutdown documentation #14356

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

Merged
merged 8 commits into from
Jul 5, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,35 @@

@RESTHEADER{DELETE /_admin/shutdown, Initiate shutdown sequence, RestShutdownHandler}

@RESTQUERYPARAMETERS

@RESTQUERYPARAM{soft,boolean,optional}
<small>Introduced in: v3.7.12, v3.8.1, v3.9.0</small>

If set to `true`, this initiates a soft shutdown. This is only available
on Coordinators. When issued, the Coordinator tracks a number of ongoing
operations, waits until all have finished, and then shuts itself down
normally. In the meantime, new operations of these types are no longer
accepted and a 503 response is sent instead. However, further requests
to finish the ongoing operations are allowed. This feature can be used
to make restart operations of Coordinators less intrusive for clients.

The following types of operations are tracked:

- AQL cursors (in particular streaming cursors)
- Transactions (in particular stream transactions)
- Pregel runs (conducted by this Coordinator)
- Ongoing asynchronous requests (using the `x-arango-async: store` HTTP header
- Finished asynchronous requests, whose result has not yet been
collected
- Queued low priority requests (most normal requests)
- Ongoing low priority requests

Note that the latter two are tracked but not prevented from being
started, to allow for finishing operations.

@RESTDESCRIPTION
This call initiates a clean shutdown sequence. Requ 8000 ires administrive privileges
This call initiates a clean shutdown sequence. Requires administrive privileges.

@RESTRETURNCODES

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@

@startDocuBlock get_api_shutdown
@brief query progress of soft shutdown process

@RESTHEADER{GET /_admin/shutdown, Query progress of soft shutdown process, RestGetShutdownHandler}

@RESTDESCRIPTION
<small>Introduced in: v3.7.12, v3.8.1, v3.9.0</small>

This call reports progress about a soft Coordinator shutdown (see
documentation of `DELETE /_admin/shutdown?soft=true`).
In this case, the following types of operations are tracked:

- AQL cursors (in particular streaming cursors)
- Transactions (in particular stream transactions)
- Pregel runs (conducted by this Coordinator)
- Ongoing asynchronous requests (using the `x-arango-async: store` HTTP header
- Finished asynchronous requests, whose result has not yet been
collected
- Queued low priority requests (most normal requests)
- Ongoing low priority requests

This API is only availa 9A13 ble on Coordinators.

@RESTRETURNCODES

@RESTRETURNCODE{200}
The response indicates the fact that a soft shutdown is ongoing and the
number of active operations of the various types. Once all numbers have gone
to 0, the flag `allClear` is set and the Coordinator shuts down automatically.

@RESTREPLYBODY{softShutdownOngoing,boolean,required,}
Whether a soft shutdown of the Coordinator is in progress.

@RESTREPLYBODY{AQLcursors,number,required,}
Number of AQL cursors that are still active.

@RESTREPLYBODY{transactions,number,required,}
Number of ongoing transactions.

@RESTREPLYBODY{pendingJobs,number,required,}
Number of ongoing asynchronous requests.

@RESTREPLYBODY{doneJobs,number,required,}
Number of finished asynchronous requests, whose result has not yet been collected.

@RESTREPLYBODY{pregelConductors,number,required,}
Number of ongoing Pregel jobs.

@RESTREPLYBODY{lowPrioOngoingRequests,number,required,}
Number of queued low priority requests.

@RESTREPLYBODY{lowPrioQueuedRequests,number,required,}
Number of ongoing low priority requests.

@RESTREPLYBODY{allClear,boolean,required,}
Whether all active operations finished.

@endDocuBlock
0