Skip to content

Commit 8245b23

Browse files
author
Shlomi Noach
authored
Merge pull request #689 from ClareCat/update_docs_throttle_http_flags
Update docs to include info about throttle-HTTP and some undocumented flags
2 parents 034d9e4 + 9e6b7ff commit 8245b23

File tree

2 files changed

+24
-0
lines changed

2 files changed

+24
-0
lines changed

doc/command-line-flags.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,10 @@ This is somewhat similar to a Nagios `n`-times test, where `n` in our case is al
6969

7070
Optional. Default is `safe`. See more discussion in [`cut-over`](cut-over.md)
7171

72+
### cut-over-lock-timeout-seconds
73+
74+
Default `3`. Max number of seconds to hold locks on tables while attempting to cut-over (retry attempted when lock exceeds timeout).
75+
7276
### discard-foreign-keys
7377

7478
**Danger**: this flag will _silently_ discard any foreign keys existing on your table.
@@ -107,6 +111,10 @@ While the ongoing estimated number of rows is still heuristic, it's almost exact
107111

108112
Without this parameter, migration is a _noop_: testing table creation and validity of migration, but not touching data.
109113

114+
### force-table-names
115+
116+
Table name prefix to be used on the temporary tables.
117+
110118
### gcp
111119

112120
Add this flag when executing on a 1st generation Google Cloud Platform (GCP).
@@ -125,6 +133,10 @@ We think `gh-ost` should not take chances or make assumptions about the user's t
125133

126134
See [`initially-drop-ghost-table`](#initially-drop-ghost-table)
127135

136+
### initially-drop-socket-file
137+
138+
Default False. Should `gh-ost` forcibly delete an existing socket file. Be careful: this might drop the socket file of a running migration!
139+
128140
### max-lag-millis
129141

130142
On a replication topology, this is perhaps the most important migration throttling factor: the maximum lag allowed for migration to work. If lag exceeds this value, migration throttles.
@@ -169,6 +181,10 @@ See [`approve-renamed-columns`](#approve-renamed-columns)
169181

170182
Issue the migration on a replica; do not modify data on master. Useful for validating, testing and benchmarking. See [`testing-on-replica`](testing-on-replica.md)
171183

184+
### test-on-replica-skip-replica-stop
185+
186+
Default `False`. When `--test-on-replica` is enabled, do not issue commands stop replication (requires `--test-on-replica`).
187+
172188
### throttle-control-replicas
173189

174190
Provide a command delimited list of replicas; `gh-ost` will throttle when any of the given replicas lag beyond [`--max-lag-millis`](#max-lag-millis). The list can be queried and updated dynamically via [interactive commands](interactive-commands.md)

doc/throttle.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,14 @@ Note that you may dynamically change both `--max-lag-millis` and the `throttle-c
4646

4747
An example query could be: `--throttle-query="select hour(now()) between 8 and 17"` which implies throttling auto-starts `8:00am` and migration auto-resumes at `18:00pm`.
4848

49+
#### HTTP Throttle
50+
51+
The `--throttle-http` flag allows for throttling via HTTP. Every 100ms `gh-ost` issues a `HEAD` request to the provided URL. If the response status code is not `200` throttling will kick in until a `200` response status code is returned.
52+
53+
If no URL is provided or the URL provided doesn't contain the scheme then the HTTP check will be disabled. For example `--throttle-http="http://1.2.3.4:6789/throttle"` will enable the HTTP check/throttling, but `--throttle-http="1.2.3.4:6789/throttle"` will not.
54+
55+
The URL can be queried and updated dynamically via [interactive interface](interactive-commands.md).
56+
4957
#### Manual control
5058

5159
In addition to the above, you are able to take control and throttle the operation any time you like.

0 commit comments

Comments
 (0)