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

Function dump_node_capacity

lib/pengine/utils.c:227–246  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

225}
226
227void
228dump_node_capacity(int level, const char *comment, node_t * node)
229{
230 int len = 0;
231 char *dump_text = NULL;
232
233 len = strlen(comment) + strlen(": ") + strlen(node->details->uname) + strlen(" capacity:") + 1;
234 dump_text = calloc(1, len);
235 sprintf(dump_text, "%s: %s capacity:", comment, node->details->uname);
236
237 g_hash_table_foreach(node->details->utilization, append_dump_text, &dump_text);
238
239 if (level == 0) {
240 fprintf(stdout, "%s\n", dump_text);
241 } else {
242 crm_trace("%s", dump_text);
243 }
244
245 free(dump_text);
246}
247
248void
249dump_rsc_utilization(int level, const char *comment, resource_t * rsc, node_t * node)

Callers 1

stage5Function · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected