![]() |
pacemaker 3.0.1-16e74fc4da
Scalable High-Availability cluster resource manager
|
#include <stdint.h>#include <stdbool.h>#include <sys/types.h>#include <glib.h>#include <libxml/tree.h>#include <libxml/xmlstring.h>#include <qb/qbipcc.h>#include <crm/common/ipc.h>#include <crm/common/iso8601.h>#include <crm/common/logging.h>#include <crm/common/mainloop.h>#include <crm/common/output_internal.h>#include <crm/common/results.h>#include <crm/common/rules.h>#include <crm/common/xml_internal.h>
Go to the source code of this file.
Data Structures | |
| struct | pcmk__deleted_xml_s |
| struct | xml_node_private_s |
| struct | xml_doc_private_s |
| struct | pcmk__ipc_methods_s |
| struct | pcmk_ipc_api_s |
| struct | pcmk__ipc_header_s |
| struct | pcmk__schema_version_t |
| struct | pcmk__schema_t |
Macros | |
| #define | PCMK__BUFFER_SIZE 4096 |
| #define | PCMK__XML_DOC_PRIVATE_MAGIC 0x81726354UL |
| #define | PCMK__XML_NODE_PRIVATE_MAGIC 0x54637281UL |
| #define | PCMK__XML_ENTITY_AMP "&" |
| #define | PCMK__XML_ENTITY_GT ">" |
| #define | PCMK__XML_ENTITY_LT "<" |
| #define | PCMK__XML_ENTITY_QUOT """ |
| #define | pcmk__set_xml_flags(xml_priv, flags_to_set) |
| #define | pcmk__clear_xml_flags(xml_priv, flags_to_clear) |
| #define | PCMK__IPC_VERSION 1 |
| #define | PCMK__CONTROLD_API_MAJOR "1" |
| #define | PCMK__CONTROLD_API_MINOR "0" |
| #define | PCMK__XML_PREFIX_CREATED "++" |
| XML is newly created. | |
| #define | PCMK__XML_PREFIX_DELETED "--" |
| XML has been deleted. | |
| #define | PCMK__XML_PREFIX_MODIFIED "+ " |
| XML has been modified. | |
| #define | PCMK__XML_PREFIX_MOVED "+~" |
| XML has been moved. | |
| #define | PCMK__PW_BUFFER_LEN 500 |
Typedefs | |
| typedef struct pcmk__deleted_xml_s | pcmk__deleted_xml_t |
| typedef struct xml_node_private_s | xml_node_private_t |
| typedef struct xml_doc_private_s | xml_doc_private_t |
| typedef struct pcmk__ipc_methods_s | pcmk__ipc_methods_t |
| typedef struct pcmk__ipc_header_s | pcmk__ipc_header_t |
Functions | |
| G_GNUC_INTERNAL const char * | pcmk__xml_element_type_text (xmlElementType type) |
| G_GNUC_INTERNAL bool | pcmk__xml_reset_node_flags (xmlNode *xml, void *user_data) |
| G_GNUC_INTERNAL void | pcmk__xml_set_parent_flags (xmlNode *xml, uint64_t flags) |
| G_GNUC_INTERNAL void | pcmk__xml_new_private_data (xmlNode *xml) |
| G_GNUC_INTERNAL void | pcmk__xml_free_private_data (xmlNode *xml) |
| G_GNUC_INTERNAL void | pcmk__xml_free_node (xmlNode *xml) |
| G_GNUC_INTERNAL xmlDoc * | pcmk__xml_new_doc (void) |
| G_GNUC_INTERNAL int | pcmk__xml_position (const xmlNode *xml, enum pcmk__xml_flags ignore_if_set) |
| G_GNUC_INTERNAL bool | pcmk__xc_matches (const xmlNode *comment1, const xmlNode *comment2) |
| G_GNUC_INTERNAL void | pcmk__xc_update (xmlNode *parent, xmlNode *target, xmlNode *update) |
| G_GNUC_INTERNAL void | pcmk__free_acls (GList *acls) |
| G_GNUC_INTERNAL void | pcmk__unpack_acl (xmlNode *source, xmlNode *target, const char *user) |
| G_GNUC_INTERNAL bool | pcmk__is_user_in_group (const char *user, const char *group) |
| G_GNUC_INTERNAL void | pcmk__apply_acl (xmlNode *xml) |
| G_GNUC_INTERNAL void | pcmk__apply_creation_acl (xmlNode *xml, bool check_top) |
| G_GNUC_INTERNAL int | pcmk__xa_remove (xmlAttr *attr, bool force) |
| G_GNUC_INTERNAL void | pcmk__mark_xml_attr_dirty (xmlAttr *a) |
| G_GNUC_INTERNAL bool | pcmk__xa_filterable (const char *name) |
| G_GNUC_INTERNAL void | pcmk__log_xmllib_err (void *ctx, const char *fmt,...) G_GNUC_PRINTF(2 |
| G_GNUC_INTERNAL void G_GNUC_INTERNAL void | pcmk__mark_xml_node_dirty (xmlNode *xml) |
| G_GNUC_INTERNAL bool | pcmk__marked_as_deleted (xmlAttrPtr a, void *user_data) |
| G_GNUC_INTERNAL void | pcmk__dump_xml_attr (const xmlAttr *attr, GString *buffer) |
| G_GNUC_INTERNAL int | pcmk__xe_set_score (xmlNode *target, const char *name, const char *value) |
| G_GNUC_INTERNAL bool | pcmk__xml_is_name_start_char (const char *utf8, int *len) |
| G_GNUC_INTERNAL bool | pcmk__xml_is_name_char (const char *utf8, int *len) |
| G_GNUC_INTERNAL const char * | pcmk__time_component_attr (enum pcmk__time_component component) |
| G_GNUC_INTERNAL int | pcmk__add_time_from_xml (crm_time_t *t, enum pcmk__time_component component, const xmlNode *xml) |
| G_GNUC_INTERNAL void | pcmk__set_time_if_earlier (crm_time_t *target, const crm_time_t *source) |
| G_GNUC_INTERNAL int | pcmk__send_ipc_request (pcmk_ipc_api_t *api, const xmlNode *request) |
| G_GNUC_INTERNAL void | pcmk__call_ipc_callback (pcmk_ipc_api_t *api, enum pcmk_ipc_event event_type, crm_exit_t status, void *event_data) |
| G_GNUC_INTERNAL bool | pcmk__valid_ipc_header (const pcmk__ipc_header_t *header) |
| G_GNUC_INTERNAL pcmk__ipc_methods_t * | pcmk__attrd_api_methods (void) |
| G_GNUC_INTERNAL pcmk__ipc_methods_t * | pcmk__controld_api_methods (void) |
| G_GNUC_INTERNAL pcmk__ipc_methods_t * | pcmk__pacemakerd_api_methods (void) |
| G_GNUC_INTERNAL pcmk__ipc_methods_t * | pcmk__schedulerd_api_methods (void) |
| G_GNUC_INTERNAL int | pcmk__bare_output_new (pcmk__output_t **out, const char *fmt_name, const char *filename, char **argv) |
| G_GNUC_INTERNAL void | pcmk__register_option_messages (pcmk__output_t *out) |
| G_GNUC_INTERNAL void | pcmk__register_patchset_messages (pcmk__output_t *out) |
| G_GNUC_INTERNAL bool | pcmk__output_text_get_fancy (pcmk__output_t *out) |
| G_GNUC_INTERNAL enum pcmk__comparison | pcmk__parse_comparison (const char *op) |
| G_GNUC_INTERNAL enum pcmk__type | pcmk__parse_type (const char *type, enum pcmk__comparison op, const char *value1, const char *value2) |
| G_GNUC_INTERNAL enum pcmk__reference_source | pcmk__parse_source (const char *source) |
| G_GNUC_INTERNAL int | pcmk__cmp_by_type (const char *value1, const char *value2, enum pcmk__type type) |
| G_GNUC_INTERNAL int | pcmk__unpack_duration (const xmlNode *duration, const crm_time_t *start, crm_time_t **end) |
| G_GNUC_INTERNAL int | pcmk__evaluate_date_spec (const xmlNode *date_spec, const crm_time_t *now) |
| G_GNUC_INTERNAL int | pcmk__evaluate_attr_expression (const xmlNode *expression, const pcmk_rule_input_t *rule_input) |
| G_GNUC_INTERNAL int | pcmk__evaluate_rsc_expression (const xmlNode *expr, const pcmk_rule_input_t *rule_input) |
| G_GNUC_INTERNAL int | pcmk__evaluate_op_expression (const xmlNode *expr, const pcmk_rule_input_t *rule_input) |
| G_GNUC_INTERNAL GList * | pcmk__find_x_0_schema (void) |
| #define PCMK__BUFFER_SIZE 4096 |
Definition at line 40 of file crmcommon_private.h.
| #define pcmk__clear_xml_flags | ( | xml_priv, | |
| flags_to_clear ) |
Definition at line 109 of file crmcommon_private.h.
| #define PCMK__CONTROLD_API_MAJOR "1" |
Definition at line 224 of file crmcommon_private.h.
| #define PCMK__CONTROLD_API_MINOR "0" |
Definition at line 225 of file crmcommon_private.h.
| #define PCMK__IPC_VERSION 1 |
Definition at line 222 of file crmcommon_private.h.
| #define PCMK__PW_BUFFER_LEN 500 |
Definition at line 442 of file crmcommon_private.h.
| #define pcmk__set_xml_flags | ( | xml_priv, | |
| flags_to_set ) |
Definition at line 103 of file crmcommon_private.h.
| #define PCMK__XML_DOC_PRIVATE_MAGIC 0x81726354UL |
Definition at line 94 of file crmcommon_private.h.
| #define PCMK__XML_ENTITY_AMP "&" |
Definition at line 98 of file crmcommon_private.h.
| #define PCMK__XML_ENTITY_GT ">" |
Definition at line 99 of file crmcommon_private.h.
| #define PCMK__XML_ENTITY_LT "<" |
Definition at line 100 of file crmcommon_private.h.
| #define PCMK__XML_ENTITY_QUOT """ |
Definition at line 101 of file crmcommon_private.h.
| #define PCMK__XML_NODE_PRIVATE_MAGIC 0x54637281UL |
Definition at line 95 of file crmcommon_private.h.
| #define PCMK__XML_PREFIX_CREATED "++" |
XML is newly created.
Definition at line 344 of file crmcommon_private.h.
| #define PCMK__XML_PREFIX_DELETED "--" |
XML has been deleted.
Definition at line 347 of file crmcommon_private.h.
| #define PCMK__XML_PREFIX_MODIFIED "+ " |
XML has been modified.
Definition at line 350 of file crmcommon_private.h.
| #define PCMK__XML_PREFIX_MOVED "+~" |
XML has been moved.
Definition at line 353 of file crmcommon_private.h.
| typedef struct pcmk__deleted_xml_s pcmk__deleted_xml_t |
| typedef struct pcmk__ipc_header_s pcmk__ipc_header_t |
| typedef struct pcmk__ipc_methods_s pcmk__ipc_methods_t |
| typedef struct xml_doc_private_s xml_doc_private_t |
| typedef struct xml_node_private_s xml_node_private_t |
| enum pcmk__comparison |
Definition at line 376 of file crmcommon_private.h.
| Enumerator | |
|---|---|
| pcmk__source_unknown | |
| pcmk__source_literal | |
| pcmk__source_instance_attrs | |
| pcmk__source_meta_attrs | |
Definition at line 398 of file crmcommon_private.h.
| Enumerator | |
|---|---|
| pcmk__schema_validator_none | |
| pcmk__schema_validator_rng | |
Definition at line 452 of file crmcommon_private.h.
| enum pcmk__time_component |
| Enumerator | |
|---|---|
| pcmk__time_unknown | |
| pcmk__time_years | |
| pcmk__time_months | |
| pcmk__time_weeks | |
| pcmk__time_days | |
| pcmk__time_hours | |
| pcmk__time_minutes | |
| pcmk__time_seconds | |
Definition at line 196 of file crmcommon_private.h.
| enum pcmk__type |
| Enumerator | |
|---|---|
| pcmk__type_unknown | |
| pcmk__type_string | |
| pcmk__type_integer | |
| pcmk__type_number | |
| pcmk__type_version | |
Definition at line 389 of file crmcommon_private.h.
| G_GNUC_INTERNAL int pcmk__add_time_from_xml | ( | crm_time_t * | t, |
| enum pcmk__time_component | component, | ||
| const xmlNode * | xml ) |
| G_GNUC_INTERNAL void pcmk__apply_creation_acl | ( | xmlNode * | xml, |
| bool | check_top ) |
| G_GNUC_INTERNAL pcmk__ipc_methods_t * pcmk__attrd_api_methods | ( | void | ) |
Definition at line 116 of file ipc_attrd.c.
| G_GNUC_INTERNAL int pcmk__bare_output_new | ( | pcmk__output_t ** | out, |
| const char * | fmt_name, | ||
| const char * | filename, | ||
| char ** | argv ) |
| G_GNUC_INTERNAL void pcmk__call_ipc_callback | ( | pcmk_ipc_api_t * | api, |
| enum pcmk_ipc_event | event_type, | ||
| crm_exit_t | status, | ||
| void * | event_data ) |
Definition at line 144 of file ipc_client.c.
| G_GNUC_INTERNAL int pcmk__cmp_by_type | ( | const char * | value1, |
| const char * | value2, | ||
| enum pcmk__type | type ) |
| G_GNUC_INTERNAL pcmk__ipc_methods_t * pcmk__controld_api_methods | ( | void | ) |
Definition at line 299 of file ipc_controld.c.
| G_GNUC_INTERNAL void pcmk__dump_xml_attr | ( | const xmlAttr * | attr, |
| GString * | buffer ) |
Definition at line 108 of file xml_attr.c.
| G_GNUC_INTERNAL int pcmk__evaluate_attr_expression | ( | const xmlNode * | expression, |
| const pcmk_rule_input_t * | rule_input ) |
| G_GNUC_INTERNAL int pcmk__evaluate_date_spec | ( | const xmlNode * | date_spec, |
| const crm_time_t * | now ) |
| G_GNUC_INTERNAL int pcmk__evaluate_op_expression | ( | const xmlNode * | expr, |
| const pcmk_rule_input_t * | rule_input ) |
| G_GNUC_INTERNAL int pcmk__evaluate_rsc_expression | ( | const xmlNode * | expr, |
| const pcmk_rule_input_t * | rule_input ) |
| G_GNUC_INTERNAL bool pcmk__is_user_in_group | ( | const char * | user, |
| const char * | group ) |
| G_GNUC_INTERNAL void pcmk__log_xmllib_err | ( | void * | ctx, |
| const char * | fmt, | ||
| ... ) |
| G_GNUC_INTERNAL void pcmk__mark_xml_attr_dirty | ( | xmlAttr * | a | ) |
Definition at line 77 of file xml_attr.c.
| G_GNUC_INTERNAL void G_GNUC_INTERNAL void pcmk__mark_xml_node_dirty | ( | xmlNode * | xml | ) |
| G_GNUC_INTERNAL bool pcmk__marked_as_deleted | ( | xmlAttrPtr | a, |
| void * | user_data ) |
Definition at line 89 of file xml_attr.c.
| G_GNUC_INTERNAL bool pcmk__output_text_get_fancy | ( | pcmk__output_t * | out | ) |
Definition at line 361 of file output_text.c.
| G_GNUC_INTERNAL pcmk__ipc_methods_t * pcmk__pacemakerd_api_methods | ( | void | ) |
Definition at line 282 of file ipc_pacemakerd.c.
| G_GNUC_INTERNAL enum pcmk__comparison pcmk__parse_comparison | ( | const char * | op | ) |
| G_GNUC_INTERNAL enum pcmk__reference_source pcmk__parse_source | ( | const char * | source | ) |
| G_GNUC_INTERNAL enum pcmk__type pcmk__parse_type | ( | const char * | type, |
| enum pcmk__comparison | op, | ||
| const char * | value1, | ||
| const char * | value2 ) |
| G_GNUC_INTERNAL void pcmk__register_option_messages | ( | pcmk__output_t * | out | ) |
Definition at line 491 of file options_display.c.
| G_GNUC_INTERNAL void pcmk__register_patchset_messages | ( | pcmk__output_t * | out | ) |
Definition at line 324 of file patchset_display.c.
| G_GNUC_INTERNAL pcmk__ipc_methods_t * pcmk__schedulerd_api_methods | ( | void | ) |
Definition at line 141 of file ipc_schedulerd.c.
| G_GNUC_INTERNAL int pcmk__send_ipc_request | ( | pcmk_ipc_api_t * | api, |
| const xmlNode * | request ) |
Definition at line 684 of file ipc_client.c.
| G_GNUC_INTERNAL void pcmk__set_time_if_earlier | ( | crm_time_t * | target, |
| const crm_time_t * | source ) |
| G_GNUC_INTERNAL const char * pcmk__time_component_attr | ( | enum pcmk__time_component | component | ) |
| G_GNUC_INTERNAL void pcmk__unpack_acl | ( | xmlNode * | source, |
| xmlNode * | target, | ||
| const char * | user ) |
| G_GNUC_INTERNAL int pcmk__unpack_duration | ( | const xmlNode * | duration, |
| const crm_time_t * | start, | ||
| crm_time_t ** | end ) |
| G_GNUC_INTERNAL bool pcmk__valid_ipc_header | ( | const pcmk__ipc_header_t * | header | ) |
Definition at line 45 of file ipc_common.c.
| G_GNUC_INTERNAL bool pcmk__xa_filterable | ( | const char * | name | ) |
| G_GNUC_INTERNAL int pcmk__xa_remove | ( | xmlAttr * | attr, |
| bool | force ) |
Definition at line 45 of file xml_attr.c.
| G_GNUC_INTERNAL bool pcmk__xc_matches | ( | const xmlNode * | comment1, |
| const xmlNode * | comment2 ) |
Definition at line 54 of file xml_comment.c.
| G_GNUC_INTERNAL void pcmk__xc_update | ( | xmlNode * | parent, |
| xmlNode * | target, | ||
| xmlNode * | update ) |
Definition at line 104 of file xml_comment.c.
| G_GNUC_INTERNAL int pcmk__xe_set_score | ( | xmlNode * | target, |
| const char * | name, | ||
| const char * | value ) |
Definition at line 172 of file xml_element.c.
| G_GNUC_INTERNAL const char * pcmk__xml_element_type_text | ( | xmlElementType | type | ) |
| G_GNUC_INTERNAL void pcmk__xml_free_private_data | ( | xmlNode * | xml | ) |
| G_GNUC_INTERNAL bool pcmk__xml_is_name_char | ( | const char * | utf8, |
| int * | len ) |
| G_GNUC_INTERNAL bool pcmk__xml_is_name_start_char | ( | const char * | utf8, |
| int * | len ) |
| G_GNUC_INTERNAL void pcmk__xml_new_private_data | ( | xmlNode * | xml | ) |
| G_GNUC_INTERNAL int pcmk__xml_position | ( | const xmlNode * | xml, |
| enum pcmk__xml_flags | ignore_if_set ) |
| G_GNUC_INTERNAL bool pcmk__xml_reset_node_flags | ( | xmlNode * | xml, |
| void * | user_data ) |