summaryrefslogtreecommitdiff
path: root/src/commands/sentinel-simulate-failure.json
blob: 5031d44ae4f36820ca8de6b5071651cf9b65e086 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
{
    "SIMULATE-FAILURE": {
        "summary": "Simulates failover scenarios.",
        "group": "sentinel",
        "since": "3.2.0",
        "arity": -3,
        "container": "SENTINEL",
        "function": "sentinelCommand",
        "command_flags": [
            "ADMIN",
            "SENTINEL",
            "ONLY_SENTINEL"
        ],
        "reply_schema": {
            "oneOf": [
                {
                    "description": "The simulated flag was set.",
                    "const": "OK"
                },
                {
                    "description": "Supported simulates flags. Returned in case `HELP` was used.",
                    "type": "array",
                    "items": {
                        "type": "string"
                    }
                }
            ]
        },
        "arguments": [
            {
                "name": "mode",
                "type": "oneof",
                "optional":true,
                "multiple":true,
                "arguments": [
                    {
                        "name": "crash-after-election",
                        "type": "pure-token"
                    },
                    {
                        "name": "crash-after-promotion",
                        "type": "pure-token"
                    },
                    {
                        "name": "help",
                        "type": "pure-token"
                    }
                ]
            }            
        ]
    }
}