pacemaker  2.1.9-49aab99839
Scalable High-Availability cluster resource manager
Data Structures | Enumerations | Functions
scheduler.h File Reference

Scheduler API. More...

#include <sys/types.h>
#include <libxml/tree.h>
#include <glib.h>
#include <crm/common/iso8601.h>
#include <crm/common/actions.h>
#include <crm/common/nodes.h>
#include <crm/common/resources.h>
#include <crm/common/roles.h>
#include <crm/common/rules.h>
#include <crm/common/scheduler_types.h>
#include <crm/common/tags.h>
#include <crm/common/tickets.h>
Include dependency graph for scheduler.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  pe_working_set_s
 

Enumerations

enum  pe_quorum_policy {
  pcmk_no_quorum_freeze, pcmk_no_quorum_stop, pcmk_no_quorum_ignore, pcmk_no_quorum_fence,
  pcmk_no_quorum_demote, no_quorum_freeze = pcmk_no_quorum_freeze, no_quorum_stop = pcmk_no_quorum_stop, no_quorum_ignore = pcmk_no_quorum_ignore,
  no_quorum_suicide = pcmk_no_quorum_fence, no_quorum_demote = pcmk_no_quorum_demote
}
 Possible responses to loss of quorum. More...
 
enum  pcmk_scheduler_flags {
  pcmk_sched_none = 0ULL, pcmk_sched_quorate = (1ULL << 0), pcmk_sched_symmetric_cluster = (1ULL << 1), pcmk_sched_in_maintenance = (1ULL << 3),
  pcmk_sched_fencing_enabled = (1ULL << 4), pcmk_sched_have_fencing = (1ULL << 5), pcmk_sched_enable_unfencing = (1ULL << 6), pcmk_sched_concurrent_fencing = (1ULL << 7),
  pcmk_sched_stop_removed_resources = (1ULL << 8), pcmk_sched_cancel_removed_actions = (1ULL << 9), pcmk_sched_stop_all = (1ULL << 10), pcmk_sched_start_failure_fatal = (1ULL << 12),
  pcmk_sched_remove_after_stop = (1ULL << 13), pcmk_sched_startup_fencing = (1ULL << 14), pcmk_sched_shutdown_lock = (1ULL << 15), pcmk_sched_probe_resources = (1ULL << 16),
  pcmk_sched_have_status = (1ULL << 17), pcmk_sched_have_remote_nodes = (1ULL << 18), pcmk_sched_location_only = (1ULL << 20), pcmk_sched_sanitized = (1ULL << 21),
  pcmk_sched_no_counts = (1ULL << 23), pcmk_sched_no_compat = (1ULL << 24), pcmk_sched_output_scores = (1ULL << 25), pcmk_sched_show_utilization = (1ULL << 26),
  pcmk_sched_validate_only = (1ULL << 27)
}
 

Functions

pcmk_node_tpcmk_get_dc (const pcmk_scheduler_t *scheduler)
 
enum pe_quorum_policy pcmk_get_no_quorum_policy (const pcmk_scheduler_t *scheduler)
 
int pcmk_set_scheduler_cib (pcmk_scheduler_t *scheduler, xmlNode *cib)
 
bool pcmk_has_quorum (const pcmk_scheduler_t *scheduler)
 
pcmk_node_tpcmk_find_node (const pcmk_scheduler_t *scheduler, const char *node_name)
 Find a node by name in scheduler data. More...
 

Variables

gboolean was_processing_error
 
gboolean was_processing_warning
 

Detailed Description

Scheduler API.

Definition in file scheduler.h.

Enumeration Type Documentation

◆ pcmk_scheduler_flags

Deprecated:
Do not use
Enumerator
pcmk_sched_none 
pcmk_sched_quorate 
Deprecated:
Call pcmk_has_quorum() to check quorum instead
pcmk_sched_symmetric_cluster 
pcmk_sched_in_maintenance 
pcmk_sched_fencing_enabled 
pcmk_sched_have_fencing 
Deprecated:
To indicate the cluster has a fencing resource, add either a fencing resource configuration or the have-watchdog cluster option to the input CIB
pcmk_sched_enable_unfencing 
pcmk_sched_concurrent_fencing 
pcmk_sched_stop_removed_resources 
pcmk_sched_cancel_removed_actions 
pcmk_sched_stop_all 
pcmk_sched_start_failure_fatal 
pcmk_sched_remove_after_stop 
pcmk_sched_startup_fencing 
pcmk_sched_shutdown_lock 
pcmk_sched_probe_resources 
pcmk_sched_have_status 
pcmk_sched_have_remote_nodes 
pcmk_sched_location_only 
pcmk_sched_sanitized 
pcmk_sched_no_counts 
pcmk_sched_no_compat 
pcmk_sched_output_scores 
pcmk_sched_show_utilization 
pcmk_sched_validate_only 

Definition at line 72 of file scheduler.h.

◆ pe_quorum_policy

Possible responses to loss of quorum.

Enumerator
pcmk_no_quorum_freeze 
pcmk_no_quorum_stop 
pcmk_no_quorum_ignore 
pcmk_no_quorum_fence 
pcmk_no_quorum_demote 
no_quorum_freeze 
Deprecated:
Use pcmk_no_quorum_freeze instead
no_quorum_stop 
Deprecated:
Use pcmk_no_quorum_stop instead
no_quorum_ignore 
Deprecated:
Use pcmk_no_quorum_ignore instead
no_quorum_suicide 
Deprecated:
Use pcmk_no_quorum_fence instead
no_quorum_demote 
Deprecated:
Use pcmk_no_quorum_demote instead

Definition at line 40 of file scheduler.h.

Function Documentation

◆ pcmk_find_node()

pcmk_node_t* pcmk_find_node ( const pcmk_scheduler_t scheduler,
const char *  node_name 
)

Find a node by name in scheduler data.

Parameters
[in]schedulerScheduler data
[in]node_nameName of node to find
Returns
Node from scheduler data that matches node_name if any, otherwise NULL

Definition at line 103 of file scheduler.c.

◆ pcmk_get_dc()

pcmk_node_t* pcmk_get_dc ( const pcmk_scheduler_t scheduler)

Definition at line 33 of file scheduler.c.

◆ pcmk_get_no_quorum_policy()

enum pe_quorum_policy pcmk_get_no_quorum_policy ( const pcmk_scheduler_t scheduler)

Definition at line 47 of file scheduler.c.

◆ pcmk_has_quorum()

bool pcmk_has_quorum ( const pcmk_scheduler_t scheduler)

Definition at line 85 of file scheduler.c.

◆ pcmk_set_scheduler_cib()

int pcmk_set_scheduler_cib ( pcmk_scheduler_t scheduler,
xmlNode *  cib 
)

Definition at line 67 of file scheduler.c.

Variable Documentation

◆ was_processing_error

gboolean was_processing_error
Deprecated:
Do not use

Definition at line 21 of file scheduler.c.

◆ was_processing_warning

gboolean was_processing_warning
Deprecated:
Do not use

Definition at line 22 of file scheduler.c.