root/include/crm/crm_compat.h

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

INCLUDED FROM


DEFINITIONS

This source file includes following definitions.
  1. crm_action_str

   1 /*
   2  * Copyright 2004-2023 the Pacemaker project contributors
   3  *
   4  * The version control history for this file may have further details.
   5  *
   6  * This source code is licensed under the GNU Lesser General Public License
   7  * version 2.1 or later (LGPLv2.1+) WITHOUT ANY WARRANTY.
   8  */
   9 
  10 #ifndef PCMK__CRM_CRM_COMPAT__H
  11 #  define PCMK__CRM_CRM_COMPAT__H
  12 
  13 #include <strings.h>
  14 #include <glib.h>
  15 
  16 #include <crm/common/actions.h>
  17 
  18 #ifdef __cplusplus
  19 extern "C" {
  20 #endif
  21 
  22 /**
  23  * \file
  24  * \brief Deprecated Pacemaker utilities
  25  * \ingroup core
  26  * \deprecated Do not include this header directly. The utilities in this
  27  *             header, and the header itself, will be removed in a future
  28  *             release.
  29  */
  30 
  31 //! \deprecated Use '\0' instead
  32 #define EOS '\0'
  33 
  34 //! \deprecated This defined constant will be removed in a future release
  35 #define MAX_IPC_DELAY 120
  36 
  37 //! \deprecated Use PCMK_ACTION_STONITH instead
  38 #define CRM_OP_FENCE PCMK_ACTION_STONITH
  39 
  40 //! \deprecated This defined constant will be removed in a future release
  41 #define CRM_OP_LRM_QUERY "lrm_query"
  42 
  43 //! \deprecated Use PCMK_ACTION_CLONE_ONE_OR_MORE instead
  44 #define CRM_OP_RELAXED_CLONE PCMK_ACTION_CLONE_ONE_OR_MORE
  45 
  46 //! \deprecated Use PCMK_ACTION_ONE_OR_MORE instead
  47 #define CRM_OP_RELAXED_SET PCMK_ACTION_ONE_OR_MORE
  48 
  49 //! \deprecated This defined constant will be removed in a future release
  50 #define CRM_ATTR_RA_VERSION "#ra-version"
  51 
  52 //! \deprecated Use PCMK_ACTION_CANCEL instead
  53 #define CRMD_ACTION_CANCEL PCMK_ACTION_CANCEL
  54 
  55 //! \deprecated Use PCMK_ACTION_DELETE instead
  56 #define CRMD_ACTION_DELETE PCMK_ACTION_DELETE
  57 
  58 //! \deprecated Use PCMK_ACTION_DEMOTE instead
  59 #define CRMD_ACTION_DEMOTE PCMK_ACTION_DEMOTE
  60 
  61 //! \deprecated Use PCMK_ACTION_DEMOTED instead
  62 #define CRMD_ACTION_DEMOTED PCMK_ACTION_DEMOTED
  63 
  64 //! \deprecated Use PCMK_ACTION_META_DATA instead
  65 #define CRMD_ACTION_METADATA PCMK_ACTION_META_DATA
  66 
  67 //! \deprecated Use PCMK_ACTION_MIGRATE_TO instead
  68 #define CRMD_ACTION_MIGRATE PCMK_ACTION_MIGRATE_TO
  69 
  70 //! \deprecated Use PCMK_ACTION_MIGRATE_FROM instead
  71 #define CRMD_ACTION_MIGRATED PCMK_ACTION_MIGRATE_FROM
  72 
  73 //! \deprecated Use PCMK_ACTION_NOTIFIED instead
  74 #define CRMD_ACTION_NOTIFIED PCMK_ACTION_NOTIFIED
  75 
  76 //! \deprecated Use PCMK_ACTION_NOTIFY instead
  77 #define CRMD_ACTION_NOTIFY PCMK_ACTION_NOTIFY
  78 
  79 //! \deprecated Use PCMK_ACTION_PROMOTE instead
  80 #define CRMD_ACTION_PROMOTE PCMK_ACTION_PROMOTE
  81 
  82 //! \deprecated Use PCMK_ACTION_PROMOTED instead
  83 #define CRMD_ACTION_PROMOTED PCMK_ACTION_PROMOTED
  84 
  85 //! \deprecated Use PCMK_ACTION_RELOAD instead
  86 #define CRMD_ACTION_RELOAD PCMK_ACTION_RELOAD
  87 
  88 //! \deprecated Use PCMK_ACTION_RELOAD_AGENT instead
  89 #define CRMD_ACTION_RELOAD_AGENT PCMK_ACTION_RELOAD_AGENT
  90 
  91 //! \deprecated Use PCMK_ACTION_START instead
  92 #define CRMD_ACTION_START PCMK_ACTION_START
  93 
  94 //! \deprecated Use PCMK_ACTION_RUNNING instead
  95 #define CRMD_ACTION_STARTED PCMK_ACTION_RUNNING
  96 
  97 //! \deprecated Use PCMK_ACTION_MONITOR instead
  98 #define CRMD_ACTION_STATUS PCMK_ACTION_MONITOR
  99 
 100 //! \deprecated Use PCMK_ACTION_STOP instead
 101 #define CRMD_ACTION_STOP PCMK_ACTION_STOP
 102 
 103 //! \deprecated Use PCMK_ACTION_STOPPED instead
 104 #define CRMD_ACTION_STOPPED PCMK_ACTION_STOPPED
 105 
 106 //! \deprecated Do not use
 107 #define CRMD_METADATA_CALL_TIMEOUT PCMK_DEFAULT_METADATA_TIMEOUT_MS
 108 
 109 //! \deprecated Use PCMK_ACTION_CANCEL instead
 110 #define RSC_CANCEL PCMK_ACTION_CANCEL
 111 
 112 //! \deprecated Use PCMK_ACTION_DELETE instead
 113 #define RSC_DELETE PCMK_ACTION_DELETE
 114 
 115 //! \deprecated Use PCMK_ACTION_DEMOTE instead
 116 #define RSC_DEMOTE PCMK_ACTION_DEMOTE
 117 
 118 //! \deprecated Use PCMK_ACTION_DEMOTED instead
 119 #define RSC_DEMOTED PCMK_ACTION_DEMOTED
 120 
 121 //! \deprecated Use PCMK_ACTION_META_DATA instead
 122 #define RSC_METADATA PCMK_ACTION_META_DATA
 123 
 124 //! \deprecated Use PCMK_ACTION_MIGRATE_TO instead
 125 #define RSC_MIGRATE PCMK_ACTION_MIGRATE_TO
 126 
 127 //! \deprecated Use PCMK_ACTION_MIGRATE_FROM instead
 128 #define RSC_MIGRATED PCMK_ACTION_MIGRATE_FROM
 129 
 130 //! \deprecated Use PCMK_ACTION_NOTIFIED instead
 131 #define RSC_NOTIFIED PCMK_ACTION_NOTIFIED
 132 
 133 //! \deprecated Use PCMK_ACTION_NOTIFY instead
 134 #define RSC_NOTIFY PCMK_ACTION_NOTIFY
 135 
 136 //! \deprecated Use PCMK_ACTION_PROMOTE instead
 137 #define RSC_PROMOTE PCMK_ACTION_PROMOTE
 138 
 139 //! \deprecated Use PCMK_ACTION_PROMOTED instead
 140 #define RSC_PROMOTED PCMK_ACTION_PROMOTED
 141 
 142 //! \deprecated Use PCMK_ACTION_START instead
 143 #define RSC_START PCMK_ACTION_START
 144 
 145 //! \deprecated Use PCMK_ACTION_RUNNING instead
 146 #define RSC_STARTED PCMK_ACTION_RUNNING
 147 
 148 //! \deprecated Use PCMK_ACTION_MONITOR instead
 149 #define RSC_STATUS PCMK_ACTION_MONITOR
 150 
 151 //! \deprecated Use PCMK_ACTION_STOP instead
 152 #define RSC_STOP PCMK_ACTION_STOP
 153 
 154 //! \deprecated Use PCMK_ACTION_STOPPED instead
 155 #define RSC_STOPPED PCMK_ACTION_STOPPED
 156 
 157 //!@{
 158 //! \deprecated This macro will be removed in a future release
 159 
 160 #  ifndef __GNUC__
 161 #    define __builtin_expect(expr, result) (expr)
 162 #  endif
 163 
 164 #define __likely(expr) __builtin_expect(expr, 1)
 165 
 166 #define __unlikely(expr) __builtin_expect(expr, 0)
 167 
 168 // This ends the doxygen deprecation comment
 169 //!@}
 170 
 171 //! \deprecated Use GList * instead
 172 typedef GList *GListPtr;
 173 
 174 //! \deprecated Do not use
 175 static inline const char *
 176 crm_action_str(const char *task, guint interval_ms) {
     /* [previous][next][first][last][top][bottom][index][help] */
 177     if ((task != NULL) && (interval_ms == 0)
 178         && (strcasecmp(task, PCMK_ACTION_MONITOR) == 0)) {
 179         return "probe";
 180     }
 181     return task;
 182 }
 183 
 184 #ifdef __cplusplus
 185 }
 186 #endif
 187 
 188 #endif // PCMK__CRM_CRM_COMPAT__H

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