crm_debug_2("Input %d optional", wrapper->action->id);
crm_debug_2("Input (%d) %s optional", wrapper->action->id, wrapper->action->uuid);
graph_element_from_action(action_t *action, pe_working_set_t *data_set){	int last_action = -1;	char *syn_id = NULL;	crm_data_t * syn = NULL;	crm_data_t * set = NULL;	crm_data_t * in  = NULL;	crm_data_t * input = NULL;	crm_data_t * xml_action = NULL;	if(action == NULL) {		pe_err("Cannot dump NULL action");		return;	} else if(action->optional) {		crm_debug_5("action %d was optional", action->id);		return;	} else if(action->pseudo == FALSE && action->runnable == FALSE) {		crm_debug_5("action %d was not runnable", action->id);		return;	} else if(action->dumped) {		crm_debug_5("action %d was already dumped", action->id);		return;	} else if(action->pseudo		  || safe_str_eq(action->task,  CRM_OP_FENCE)		  || safe_str_eq(action->task,  CRM_OP_SHUTDOWN)) {		/* skip the next two checks */			} else if(action->rsc != NULL && action->rsc->is_managed == FALSE) {		pe_warn("action %d was for an unmanaged resource (%s)",			action->id, action->rsc->id);		return;			} else {		if(action->node == NULL) {			pe_err("action %d was not allocated", action->id);			log_action(LOG_DEBUG, "Unallocated action", action, FALSE);			return;					} else if(action->node->details->online == FALSE) {			pe_err("action %d was scheduled for offline node", action->id);			log_action(LOG_DEBUG, "Action for offline node", action, FALSE);			return;		}	}		action->dumped = TRUE;		syn = create_xml_node(data_set->graph, "synapse");	set = create_xml_node(syn, "action_set");	in  = create_xml_node(syn, "inputs");	syn_id = crm_itoa(data_set->num_synapse);	crm_xml_add(syn, XML_ATTR_ID, syn_id);	crm_free(syn_id);	data_set->num_synapse++;		xml_action = action2xml(action, FALSE);	add_node_copy(set, xml_action);	free_xml(xml_action);	action->actions_before = g_list_sort(		action->actions_before, sort_action_id);		slist_iter(wrapper,action_wrapper_t,action->actions_before,lpc,		   if(last_action == wrapper->action->id) {			   crm_debug_2("Input %d duplicated",				       wrapper->action->id);			   continue;			   		   } else if(wrapper->action->optional == TRUE) {			   crm_debug_2("Input %d optional",				       wrapper->action->id);			   continue;		   }		   CRM_DEV_ASSERT(last_action < wrapper->action->id);		   last_action = wrapper->action->id;		   input = create_xml_node(in, "trigger");		   		   xml_action = action2xml(wrapper->action, TRUE);		   add_node_copy(input, xml_action);		   free_xml(xml_action);		   		);}