-
Notifications
You must be signed in to change notification settings - Fork 10
/
Copy pathTODO
99 lines (57 loc) · 3.29 KB
/
TODO
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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
* Implement the replication mode:
$ s9s replication --change-master --slave=SLAVE:3306 --master=NEW_MASTER:3306
$ s9s replication --stop-slave --slave=SLAVE:3306
$ s9s replication --start-slave --slave=SLAVE:3306
$ s9s replication --rebuild-slave --slave=SLAVE:3306 --master=MASTER:3306
{ "command" : "start_replication_slave",
"job_data" :
{
"slave_address": "STRING" // the address of the replication slave ("host:port")
}
}
CmonHost
CmonArguments::hostFromArguments(
int defaultPortNum) const
{ "command" : "failover_replication_slave",
"job_data":
{
"master_address": "STRING",
"slave_address": "STRING"
}
* Implement repeating of jobs.
* Implement firewall listing and manipulating, maybe other things too:
https://github.com/severalnines/cloudlink-go/blob/develop/HTTP.md#firewall-module
o Adding command line options to create audit logging.
http://52.58.107.236/cmon-docs/current/cmonjobs.html#audit_logging
o Setting/adding groups fo users is not implemented.
o The --stat does not show '-' on the missing strings.
$ s9s/s9s user --stat kedz
kedz Name: kedz Owner: kedz/admins
ID: 3 Disabled: no
Fullname: Email:
Suspend: no Failed logins: 0
Groups: users
Created: -
Login: 2017-11-08T08:48:14.398Z
Failure: -
--- a/src/cmonrpcserver_p.cpp
+++ b/src/cmonrpcserver_p.cpp
@@ -674,6 +674,7 @@ CmonRpcServerPrivate::handleConnection (
//
if (restRequest.path.startsWith("/v2/subscribe_events"))
{
+ CmonString username = sessionStore.get(restRequest.sessionId, "authenticated-username");
cmon_main_loop_subscribe_events(socket, restRequest);
// the connection has been moved there, so return
return;
** Register Host - ProxySQL
s9s node --register --nodes="proxysql://10.10.10.15:6032?listen_port=6033" --cluster-id=214 --admin-password==pass --admin-user=user --monitor-user=user --monitor-password=pass
ProxySQL has one admin port (default 6032) and then one listening port (default 6033, set in the job as /job_data/listening_port) that is used by applications. The admin user and admin password also have default passwords. The monitor user and monitor password also have defaults.
** Register Host - HAProxy
s9s node --register --nodes="haproxy://10.10.10.15:9600?listen_port=6033?stats_socket=..." --cluster-id=214 --admin-password==pass --admin-user=user
HAProxy has one admin port (default 9600) and then one listening port (default depends on the database it loadbalances,, set in the job as /job_data/listening_port) that is used by applications. The admin user and admin password also have default passwords. The monitor user and monitor password also have defaults.
'stats_socket' has a default. In the job it is passed as /job_data/socket .
'listen_port' has a default. In the job it is passed as /job_data/listening_port.
** Register Host - Keepalived
s9s node --register --nodes="keepalived://10.10.10.15:112" --cluster-id=...
Keepalived, should not be much more to it...