MXS-1441 Add switchover and switchover_timeout config vars

Tentative documentation.

With the 'switchover' config variable the switchover functionality
can be enabled. If enabled a REST API endpoint will appear, using
which that switchover can be initiated.

Switchover can only be performed when MaxScale is in active mode
and failover will be disabled for the duration of the switchover.
Only if the switchover succeeds, will failover be enabled again.

Might be easier to expose that REST API always and only change
the behaviour when calling it, instead of making it appear and
re-appear.
This commit is contained in:
Johan Wikman
2017-09-28 11:30:20 +03:00
parent d4fd34cecd
commit ff467e218a
3 changed files with 49 additions and 2 deletions

View File

@ -65,6 +65,8 @@ typedef struct
bool allow_external_slaves; /**< Whether to allow usage of external slave servers */
bool failover; /**< If master failover is enabled */
uint32_t failover_timeout; /**< Timeout in seconds for the master failover */
bool switchover; /**< If master switchover is enabled */
uint32_t switchover_timeout; /**< Timeout in seconds for the master switchover */
MXS_MONITOR* monitor;
} MYSQL_MONITOR;