1
2
3
4
5
6
7
8
9
10 #ifndef PACEMAKER_EXECD__H
11 # define PACEMAKER_EXECD__H
12
13 # include <glib.h>
14 # include <crm/common/ipc_internal.h>
15 # include <crm/lrmd.h>
16 # include <crm/stonith-ng.h>
17
18 # ifdef HAVE_GNUTLS_GNUTLS_H
19 # include <gnutls/gnutls.h>
20 # endif
21
22 extern GHashTable *rsc_list;
23
24 typedef struct lrmd_rsc_s {
25 char *rsc_id;
26 char *class;
27 char *provider;
28 char *type;
29
30 int call_opts;
31
32
33
34
35 void *active;
36
37
38
39 GList *pending_ops;
40
41
42 GList *recurring_ops;
43
44
45
46
47
48
49
50
51 pcmk__action_result_t fence_probe_result;
52
53 crm_trigger_t *work;
54 } lrmd_rsc_t;
55
56 # ifdef HAVE_GNUTLS_GNUTLS_H
57
58 int lrmd_init_remote_tls_server(void);
59 void execd_stop_tls_server(void);
60 # endif
61
62 int lrmd_server_send_reply(pcmk__client_t *client, uint32_t id, xmlNode *reply);
63
64 int lrmd_server_send_notify(pcmk__client_t *client, xmlNode *msg);
65
66 void notify_of_new_client(pcmk__client_t *new_client);
67
68 void process_lrmd_message(pcmk__client_t *client, uint32_t id,
69 xmlNode *request);
70
71 void free_rsc(gpointer data);
72
73 void handle_shutdown_ack(void);
74
75 void handle_shutdown_nack(void);
76
77 void lrmd_client_destroy(pcmk__client_t *client);
78
79 void client_disconnect_cleanup(const char *client_id);
80
81
82
83
84
85 stonith_t *get_stonith_connection(void);
86
87
88
89
90
91
92 void stonith_connection_failed(void);
93
94 #ifdef PCMK__COMPILE_REMOTE
95 void ipc_proxy_init(void);
96 void ipc_proxy_cleanup(void);
97 void ipc_proxy_add_provider(pcmk__client_t *client);
98 void ipc_proxy_remove_provider(pcmk__client_t *client);
99 void ipc_proxy_forward_client(pcmk__client_t *client, xmlNode *xml);
100 pcmk__client_t *ipc_proxy_get_provider(void);
101 int ipc_proxy_shutdown_req(pcmk__client_t *ipc_proxy);
102 void remoted_spawn_pidone(int argc, char **argv, char **envp);
103 #endif
104
105 int process_lrmd_alert_exec(pcmk__client_t *client, uint32_t id,
106 xmlNode *request);
107 void lrmd_drain_alerts(GMainLoop *mloop);
108 void execd_exit_if_shutting_down(void);
109
110 #endif