scds_property_functions - A set of convenience functions to retrieve values of commonly used resource properties, resource group properties, resource type properties, and extension properties
cc [flags…] –I /usr/cluster/include file –L /usr/cluster/lib –l dsdev#include <rgm/libdsdev.h> return-value-type scds-get-property-name(scds_handle_t handle);
The Data Service Development Library (DSDL) provides a set of convenience functions to retrieve values of commonly used resource properties, resource group properties, resource type properties, and extension properties. Retrieve user-defined extension properties with scds_get_ext_property(3HA).
All convenience functions use the following conventions:
The functions take only the handle argument. The handle argument to be passed to the property retrieval function is returned by a prior call to scds_initialize(3HA).
Each function corresponds to a particular property.
The return value type of the function matches the type of the property value that the function retrieves.
These functions do not return errors because the return values have been precomputed in scds_initialize(3HA). For functions that return pointers, a NULL value is returned when an error condition is encountered, for example, when scds_initialize()was not previously called.
If a new value for a property has been specified in the command-line arguments that are passed to the calling program (argv[]), this new value is returned (in the case of the implementation of a Validate method). By this means, you can validate prospective new property values before they are actually set. Otherwise, these functions return the value that is retrieved from the RGM.
Some of these convenience functions return a pointer to memory belonging to the DSDL. Do not modify this memory. A call to scds_close(3HA) invalidates this pointer.
See the r_properties(7), rg_properties(7), and rt_properties(7) man pages for descriptions of standard properties. See the individual data service man pages for descriptions of extension properties.
See the scha_calls(3HA) man page and the scha_types.hheader file for information about the data types used by these functions, such as scha_prop_type_t, scha_extprop_value_t, scha_initnodes_flag_t, scha_str_array_t, scha_failover_mode_t, scha_switch_t, and scha_rsstatus_t.
These functions use the following naming conventions:
scds_get_rs_property-name
scds_get_rg_property-name
scds_get_rt_property-name
scds_get_ext_property-name
The function returns the value of a specific resource property. Some of the properties' values are explicitly set either in the RTR file or by a clresource(8CL) command. Others are determined dynamically by the RGM. The functions return data types that correspond to the requested property.
Each of the following resource dependencies query functions has a corresponding “Q” or “qualified” version:
scds_get_rs_resource_dependencies_Q
scds_get_rs_resource_dependencies_Q_offline_restart
scds_get_rs_resource_dependencies_Q_restart
scds_get_rs_resource_dependencies_Q_weak
The qualified version returns the scope, or qualifier, if any, that was declared for each resource dependency. The {LOCAL_NODE}, {ANY_NODE}, and {FROM_RG_AFFINITIES} qualifiers are described in the r_properties(7) man page.
int scds_get_rs_cheap_probe_interval(scds_handle_t handle)
scha_failover_mode_t scds_get_rs_failover_mode(scds_handle_t handle)
int scds_get_rs_monitor_stop_timeout(scds_handle_t handle)
scha_switch_t scds_get_rs_monitored_switch(scds_handle_t handle)
scha_str_array_t * scds_get_rs_network_resources_used(scds_handle_t handle)
scha_switch_t scds_get_rs_on_off_switch(scds_handle_t handle)
const scha_str_array_t * scds_get_rs_resource_dependencies(scds_handle_t handle)
const scha_str_array_t * scds_get_rs_resource_dependencies_Q(scds_handle_t handle)
const scha_str_array_t * scds_get_rs_resource_dependencies_offline_restart(scds_handle_t handle)
const scha_str_array_t * scds_get_rs_resource_dependencies_Q_offline_restart(scds_handle_t handle)
const scha_str_array_t * scds_get_rs_resource_dependencies_restart(scds_handle_t handle)
const scha_str_array_t * scds_get_rs_resource_dependencies_Q_restart(scds_handle_t handle)
const scha_str_array_t * scds_get_rs_resource_dependencies_weak(scds_handle_t handle)
const scha_str_array_t * scds_get_rs_resource_dependencies_Q_weak(scds_handle_t handle)
const char * scds_get_rs_resource_project_name(scds_handle_t handle)
int scds_get_rs_retry_count(scds_handle_t handle)
int scds_get_rs_retry_interval(scds_handle_t handle)
boolean scds_get_rs_scalable(scds_handle_t handle)
int scds_get_rs_start_timeout(scds_handle_t handle)
int scds_get_rs_stop_timeout(scds_handle_t handle)
int scds_get_rs_thorough_probe_interval(scds_handle_t handle)
The function returns the value of a specific resource group property. Some of the properties' values are explicitly set by a clresourcegroup(8CL) command. Others are determined dynamically by the RGM. The functions return data types appropriate for the requested property.
int scds_get_rg_desired_primaries(scds_handle_t handle)
const scha_str_array_t * scds_get_rg_global_resources_used(scds_handle_t handle)
boolean_t scds_get_rg_implicit_network_dependencies(scds_handle_t handle)
int scds_get_rg_maximum_primaries(scds_handle_t handle)
const scha_str_array_t * scds_get_rg_nodelist (scds_handle_t handle)
const char * scds_get_rg_pathprefix(scds_handle_t handle)
int scds_get_rg_pingpong_interval(scds_handle_t handle)
const scha_str_array_t * scds_get_rg_resource_list(scds_handle_t handle)
const scha_str_array_t * scds_get_rg_rg_affinities(scds_handle_t handle)
scha_rgmode_t scds_get_rg_rg_mode(scds_handle_t handle)
const char * scds_get_rg_rg_project_name(scds_handle_t handle)
int scds_get_rg_rg_slm_cpu_shares(scds_handle_t handle)
int scds_get_rg_rg_slm_pset_min(scds_handle_t handle)
const char * scds_get_rg_rg_slm_pset_type(scds_handle_t handle)
const char * scds_get_rg_rg_slm_type(scds_handle_t handle)
The function returns the value of a specific resource type property. Some of the properties' values are explicitly set either in the RTR file or by a clresourcetype(8CL) command. Others are determined dynamically by the RGM. The functions return data types appropriate for the requested property.
int scds_get_rt_api_version(scds_handle_t handle)
boolean_t scds_get_rt_failover(scds_handle_t handle)
scha_initnodes_flag_t scds_get_rt_init_nodes(scds_handle_t handle)
const scha_str_array_t * scds_get_rt_installed_nodes(scds_handle_t handle)
const char * scds_get_rt_rt_basedir(scds_handle_t handle)
const char * scds_get_rt_rt_version(scds_handle_t handle)
boolean_t scds_get_rt_single_instance(scds_handle_t handle)
const char * scds_get_rt_start_method(scds_handle_t handle)
const char * scds_get_rt_stop_method(scds_handle_t handle)
The function returns the value of a specific resource extension property. The properties' values are explicitly set either in the RTR file or by a clresource(8CL) command. The functions return data types appropriate for the requested property.
A resource type can define extension properties beyond the four listed here, but these four properties have convenience functions defined for them. You retrieve these properties with these convenience functions or with the scds_get_ext_property(3HA) function. You must use scds_get_ext_property() to retrieve extension properties other than these four.
scha_str_array_t * scds_get_ext_confdir_list(scds_handle_t handle)
int scds_get_ext_monitor_retry_count(scds_handle_t handle)
int scds_get_ext_monitor_retry_interval(scds_handle_t handle)
int scds_get_ext_probe_timeout(scds_handle_t handle)
The following parameter is supported for all the convenience functions:
The handle that is returned from scds_initialize(3HA).
The return value type of the function matches the type of the property value that the function retrieves.
These functions do not return errors because the return values have been precomputed in scds_initialize(3HA). For functions that return pointers, a NULL value is returned when an error condition is encountered, for example, when scds_initialize()was not previously called.
Include file
Library
See attributes(7) for descriptions of the following attributes:
|
scds_close(3HA), scds_get_ext_property(3HA), scds_get_port_list(3HA), scds_get_resource_group_name(3HA), scds_get_resource_name(3HA), scds_get_resource_type_name(3HA), scds_initialize(3HA), scha_calls(3HA), attributes(7), r_properties(7), rg_properties(7), rt_properties(7), clresource(8CL), clresourcegroup(8CL), and clresourcetype(8CL)