root/lib/services/services_private.h

/* [previous][next][first][last][top][bottom][index][help] */

INCLUDED FROM


   1 /*
   2  * Copyright 2010-2018 Red Hat, Inc.
   3  *
   4  * This source code is licensed under the GNU Lesser General Public License
   5  * version 2.1 or later (LGPLv2.1+) WITHOUT ANY WARRANTY.
   6  */
   7 
   8 #ifndef SERVICES_PRIVATE__H
   9 #  define SERVICES_PRIVATE__H
  10 
  11 #  include <glib.h>
  12 #  include "crm/services.h"
  13 
  14 #if SUPPORT_DBUS
  15 #  include <dbus/dbus.h>
  16 #endif
  17 
  18 #define MAX_ARGC        255
  19 struct svc_action_private_s {
  20     char *exec;
  21     char *args[MAX_ARGC];
  22 
  23     uid_t uid;
  24     gid_t gid;
  25 
  26     guint repeat_timer;
  27     void (*callback) (svc_action_t * op);
  28     void (*fork_callback) (svc_action_t * op);
  29 
  30     int stderr_fd;
  31     mainloop_io_t *stderr_gsource;
  32 
  33     int stdout_fd;
  34     mainloop_io_t *stdout_gsource;
  35 
  36     int stdin_fd;
  37 #if SUPPORT_DBUS
  38     DBusPendingCall* pending;
  39     unsigned timerid;
  40 #endif
  41 };
  42 
  43 G_GNUC_INTERNAL
  44 GList *services_os_get_directory_list(const char *root, gboolean files, gboolean executable);
  45 
  46 G_GNUC_INTERNAL
  47 gboolean services_os_action_execute(svc_action_t * op);
  48 
  49 G_GNUC_INTERNAL
  50 GList *resources_os_list_ocf_providers(void);
  51 
  52 G_GNUC_INTERNAL
  53 GList *resources_os_list_ocf_agents(const char *provider);
  54 
  55 G_GNUC_INTERNAL
  56 gboolean services__ocf_agent_exists(const char *provider, const char *agent);
  57 
  58 G_GNUC_INTERNAL
  59 gboolean cancel_recurring_action(svc_action_t * op);
  60 
  61 G_GNUC_INTERNAL
  62 gboolean recurring_action_timer(gpointer data);
  63 
  64 G_GNUC_INTERNAL
  65 gboolean operation_finalize(svc_action_t * op);
  66 
  67 G_GNUC_INTERNAL
  68 void services_add_inflight_op(svc_action_t *op);
  69 
  70 G_GNUC_INTERNAL
  71 void services_untrack_op(svc_action_t *op);
  72 
  73 G_GNUC_INTERNAL
  74 gboolean is_op_blocked(const char *rsc);
  75 
  76 #if SUPPORT_DBUS
  77 G_GNUC_INTERNAL
  78 void services_set_op_pending(svc_action_t *op, DBusPendingCall *pending);
  79 #endif
  80 
  81 #endif  /* SERVICES_PRIVATE__H */

/* [previous][next][first][last][top][bottom][index][help] */