mirror of https://gitee.com/bigwinds/arangodb
attempt to improve replication UI in edge cases (#10125)
This commit is contained in:
parent
2201381da9
commit
7893f178a0
|
@ -451,9 +451,13 @@ authRouter.get('/replication/mode', function (req, res) {
|
|||
let mode = 0;
|
||||
let role = null;
|
||||
// active failover
|
||||
if (endpoints.statusCode === 200 && endpoints.json.endpoints.length) {
|
||||
if (endpoints.statusCode === 200) {
|
||||
mode = 3;
|
||||
role = 'leader';
|
||||
} else if (endpoints.statusCode === 503) {
|
||||
// 503 will be returned in case there is a leadership challenge ongoing
|
||||
mode = 3;
|
||||
// role unknown
|
||||
} else {
|
||||
// check if global applier (ga) is running
|
||||
// if that is true, this node is replicating from another arangodb instance
|
||||
|
|
Loading…
Reference in New Issue