pacemaker  2.1.2-ada5c3b36
Scalable High-Availability cluster resource manager
Macros | Functions
pcmki_sched_utils.h File Reference
#include <stdbool.h>
#include <glib.h>
#include <crm/lrmd.h>
#include <crm/cib.h>
#include <crm/pengine/pe_types.h>
#include <crm/pengine/internal.h>
#include <pcmki/pcmki_scheduler.h>
#include <pcmki/pcmki_transition.h>
#include <pacemaker.h>
Include dependency graph for pcmki_sched_utils.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define LOAD_STOPPED   "load_stopped"
 

Functions

pcmk__colocation_tinvert_constraint (pcmk__colocation_t *constraint)
 
pe__location_tcopy_constraint (pe__location_t *constraint)
 
GHashTable * pcmk__copy_node_table (GHashTable *nodes)
 
GList * pcmk__copy_node_list (const GList *list, bool reset)
 
GList * sort_nodes_by_weight (GList *nodes, pe_node_t *active_node, pe_working_set_t *data_set)
 
gboolean can_run_resources (const pe_node_t *node)
 
gboolean native_assign_node (pe_resource_t *rsc, pe_node_t *chosen, gboolean force)
 
void native_deallocate (pe_resource_t *rsc)
 
void log_action (unsigned int log_level, const char *pre_text, pe_action_t *action, gboolean details)
 
gboolean can_run_any (GHashTable *nodes)
 
pe_resource_tfind_compatible_child (pe_resource_t *local_child, pe_resource_t *rsc, enum rsc_role_e filter, gboolean current, pe_working_set_t *data_set)
 
pe_resource_tfind_compatible_child_by_node (pe_resource_t *local_child, pe_node_t *local_node, pe_resource_t *rsc, enum rsc_role_e filter, gboolean current)
 
gboolean is_child_compatible (pe_resource_t *child_rsc, pe_node_t *local_node, enum rsc_role_e filter, gboolean current)
 
bool assign_node (pe_resource_t *rsc, pe_node_t *node, gboolean force)
 
enum pe_action_flags summary_action_flags (pe_action_t *action, GList *children, pe_node_t *node)
 
enum action_tasks clone_child_action (pe_action_t *action)
 
int copies_per_node (pe_resource_t *rsc)
 
int compare_capacity (const pe_node_t *node1, const pe_node_t *node2)
 
void calculate_utilization (GHashTable *current_utilization, GHashTable *utilization, gboolean plus)
 
void process_utilization (pe_resource_t *rsc, pe_node_t **prefer, pe_working_set_t *data_set)
 
pe_action_tcreate_pseudo_resource_op (pe_resource_t *rsc, const char *task, bool optional, bool runnable, pe_working_set_t *data_set)
 
pe_action_tpe_cancel_op (pe_resource_t *rsc, const char *name, guint interval_ms, pe_node_t *node, pe_working_set_t *data_set)
 
pe_action_tsched_shutdown_op (pe_node_t *node, pe_working_set_t *data_set)
 
xmlNode * pcmk__create_history_xml (xmlNode *parent, lrmd_event_data_t *event, const char *caller_version, int target_rc, const char *node, const char *origin, int level)
 
void modify_configuration (pe_working_set_t *data_set, cib_t *cib, pcmk_injections_t *injections)
 
enum transition_status run_simulation (pe_working_set_t *data_set, cib_t *cib, GList *op_fail_list)
 
pcmk__output_tpcmk__new_logger (void)
 
bool pcmk__threshold_reached (pe_resource_t *rsc, pe_node_t *node, pe_working_set_t *data_set, pe_resource_t **failed)
 

Macro Definition Documentation

◆ LOAD_STOPPED

#define LOAD_STOPPED   "load_stopped"

Definition at line 70 of file pcmki_sched_utils.h.

Function Documentation

◆ assign_node()

bool assign_node ( pe_resource_t rsc,
pe_node_t node,
gboolean  force 
)

Definition at line 1005 of file pcmk_sched_clone.c.

◆ calculate_utilization()

void calculate_utilization ( GHashTable *  current_utilization,
GHashTable *  utilization,
gboolean  plus 
)

Definition at line 124 of file pcmk_sched_utilization.c.

◆ can_run_any()

gboolean can_run_any ( GHashTable *  nodes)

Definition at line 407 of file pcmk_sched_utils.c.

◆ can_run_resources()

gboolean can_run_resources ( const pe_node_t node)

Definition at line 20 of file pcmk_sched_utils.c.

◆ clone_child_action()

enum action_tasks clone_child_action ( pe_action_t action)

Definition at line 1214 of file pcmk_sched_clone.c.

◆ compare_capacity()

int compare_capacity ( const pe_node_t node1,
const pe_node_t node2 
)

Definition at line 83 of file pcmk_sched_utilization.c.

◆ copies_per_node()

int copies_per_node ( pe_resource_t rsc)

Definition at line 423 of file pcmk_sched_bundle.c.

◆ copy_constraint()

pe__location_t* copy_constraint ( pe__location_t constraint)

◆ create_pseudo_resource_op()

pe_action_t* create_pseudo_resource_op ( pe_resource_t rsc,
const char *  task,
bool  optional,
bool  runnable,
pe_working_set_t data_set 
)

Definition at line 427 of file pcmk_sched_utils.c.

◆ find_compatible_child()

pe_resource_t* find_compatible_child ( pe_resource_t local_child,
pe_resource_t rsc,
enum rsc_role_e  filter,
gboolean  current,
pe_working_set_t data_set 
)

Definition at line 1059 of file pcmk_sched_clone.c.

◆ find_compatible_child_by_node()

pe_resource_t* find_compatible_child_by_node ( pe_resource_t local_child,
pe_node_t local_node,
pe_resource_t rsc,
enum rsc_role_e  filter,
gboolean  current 
)

Definition at line 581 of file pcmk_sched_bundle.c.

◆ invert_constraint()

pcmk__colocation_t* invert_constraint ( pcmk__colocation_t constraint)

◆ is_child_compatible()

gboolean is_child_compatible ( pe_resource_t child_rsc,
pe_node_t local_node,
enum rsc_role_e  filter,
gboolean  current 
)

Definition at line 1029 of file pcmk_sched_clone.c.

◆ log_action()

void log_action ( unsigned int  log_level,
const char *  pre_text,
pe_action_t action,
gboolean  details 
)

Definition at line 309 of file pcmk_sched_utils.c.

◆ modify_configuration()

void modify_configuration ( pe_working_set_t data_set,
cib_t cib,
pcmk_injections_t injections 
)

Definition at line 392 of file pcmk_sched_transition.c.

◆ native_assign_node()

gboolean native_assign_node ( pe_resource_t rsc,
pe_node_t chosen,
gboolean  force 
)

Definition at line 226 of file pcmk_sched_utils.c.

◆ native_deallocate()

void native_deallocate ( pe_resource_t rsc)

Definition at line 208 of file pcmk_sched_utils.c.

◆ pcmk__copy_node_list()

GList* pcmk__copy_node_list ( const GList *  list,
bool  reset 
)

Definition at line 81 of file pcmk_sched_utils.c.

◆ pcmk__copy_node_table()

GHashTable* pcmk__copy_node_table ( GHashTable *  nodes)

Definition at line 51 of file pcmk_sched_utils.c.

◆ pcmk__create_history_xml()

xmlNode* pcmk__create_history_xml ( xmlNode *  parent,
lrmd_event_data_t event,
const char *  caller_version,
int  target_rc,
const char *  node,
const char *  origin,
int  level 
)

Definition at line 560 of file pcmk_sched_utils.c.

◆ pcmk__new_logger()

pcmk__output_t* pcmk__new_logger ( void  )

Definition at line 721 of file pcmk_sched_utils.c.

◆ pcmk__threshold_reached()

bool pcmk__threshold_reached ( pe_resource_t rsc,
pe_node_t node,
pe_working_set_t data_set,
pe_resource_t **  failed 
)

Definition at line 757 of file pcmk_sched_utils.c.

◆ pe_cancel_op()

pe_action_t* pe_cancel_op ( pe_resource_t rsc,
const char *  name,
guint  interval_ms,
pe_node_t node,
pe_working_set_t data_set 
)

Definition at line 452 of file pcmk_sched_utils.c.

◆ process_utilization()

void process_utilization ( pe_resource_t rsc,
pe_node_t **  prefer,
pe_working_set_t data_set 
)

Definition at line 275 of file pcmk_sched_utilization.c.

◆ run_simulation()

enum transition_status run_simulation ( pe_working_set_t data_set,
cib_t cib,
GList *  op_fail_list 
)

Definition at line 796 of file pcmk_sched_transition.c.

◆ sched_shutdown_op()

pe_action_t* sched_shutdown_op ( pe_node_t node,
pe_working_set_t data_set 
)

Definition at line 487 of file pcmk_sched_utils.c.

◆ sort_nodes_by_weight()

GList* sort_nodes_by_weight ( GList *  nodes,
pe_node_t active_node,
pe_working_set_t data_set 
)

Definition at line 199 of file pcmk_sched_utils.c.

◆ summary_action_flags()

enum pe_action_flags summary_action_flags ( pe_action_t action,
GList *  children,
pe_node_t node 
)

Definition at line 1258 of file pcmk_sched_clone.c.