-
- char cat_bw_used_type[INSTR_DEFAULT_STR_SIZE];
- snprintf (cat_bw_used_type, INSTR_DEFAULT_STR_SIZE, "%s-%s", surf_action->category, link_type);
-
- DEBUG5("CAT LINK [%f - %f] %s %s %f", now, now+delta, resource, cat_bw_used_type, value);
- TRACE_surf_resource_utilization_event(smx_action, now, delta, cat_bw_used_type,
- resource, value);
+ //variable of this category starts by 'b', because we have a link here
+ char category_type[INSTR_DEFAULT_STR_SIZE];
+ snprintf (category_type, INSTR_DEFAULT_STR_SIZE, "b%s", surf_action->category);
+ XBT_DEBUG("CAT LINK [%f - %f] %s %s %f", now, now+delta, resource, category_type, value);
+ container_t container = getContainerByName (resource);
+ type_t type = getVariableType(category_type, NULL, container->type);
+ TRACE_surf_resource_utilization_event(smx_action, now, delta, type->name, container->name, value);