MCPcopy Create free account
hub / github.com/ClusterLabs/pacemaker / build_active_RAs

Function build_active_RAs

crmd/lrm.c:748–773  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

746}
747
748gboolean
749build_active_RAs(xmlNode * rsc_list)
750{
751 GHashTableIter iter;
752 rsc_history_t *entry = NULL;
753
754 g_hash_table_iter_init(&iter, resource_history);
755 while (g_hash_table_iter_next(&iter, NULL, (void **)&entry)) {
756
757 GList *gIter = NULL;
758 xmlNode *xml_rsc = create_xml_node(rsc_list, XML_LRM_TAG_RESOURCE);
759
760 crm_xml_add(xml_rsc, XML_ATTR_ID, entry->id);
761 crm_xml_add(xml_rsc, XML_ATTR_TYPE, entry->rsc.type);
762 crm_xml_add(xml_rsc, XML_AGENT_ATTR_CLASS, entry->rsc.class);
763 crm_xml_add(xml_rsc, XML_AGENT_ATTR_PROVIDER, entry->rsc.provider);
764
765 build_operation_update(xml_rsc, &(entry->rsc), entry->last, __FUNCTION__);
766 build_operation_update(xml_rsc, &(entry->rsc), entry->failed, __FUNCTION__);
767 for (gIter = entry->recurring_op_list; gIter != NULL; gIter = gIter->next) {
768 build_operation_update(xml_rsc, &(entry->rsc), gIter->data, __FUNCTION__);
769 }
770 }
771
772 return FALSE;
773}
774
775xmlNode *
776do_lrm_query(gboolean is_replace)

Callers 1

do_lrm_queryFunction · 0.85

Calls 5

g_hash_table_iter_initFunction · 0.85
g_hash_table_iter_nextFunction · 0.85
create_xml_nodeFunction · 0.85
crm_xml_addFunction · 0.85
build_operation_updateFunction · 0.85

Tested by

no test coverage detected