Search in sources :

Example 1 with TracingRootType

use of com.evolveum.midpoint.xml.ns._public.common.common_3.TracingRootType in project midpoint by Evolveum.

the class ItemProcessingMonitor method startTracing.

private void startTracing(@NotNull ActivityTracingDefinitionType tracingDefinition) {
    tracingDefinitionUsed = tracingDefinition;
    // This is on debug level because we may start tracing "just for sure" (with low overhead)
    // and write trace only if after-condition is true.
    LOGGER.debug("Starting tracing for object number {}", activityRun.getItemsProcessed());
    TracingProfileType configuredProfile = tracingDefinition.getTracingProfile();
    List<TracingRootType> configuredPoints = tracingDefinition.getTracingPoint();
    TracingProfileType profile = configuredProfile != null ? configuredProfile : activityRun.getBeans().tracer.getDefaultProfile();
    Collection<TracingRootType> points = !configuredPoints.isEmpty() ? configuredPoints : List.of(TracingRootType.ACTIVITY_ITEM_PROCESSING);
    points.forEach(workerTask::addTracingRequest);
    workerTask.setTracingProfile(profile);
}
Also used : TracingProfileType(com.evolveum.midpoint.xml.ns._public.common.common_3.TracingProfileType) TracingRootType(com.evolveum.midpoint.xml.ns._public.common.common_3.TracingRootType)

Aggregations

TracingProfileType (com.evolveum.midpoint.xml.ns._public.common.common_3.TracingProfileType)1 TracingRootType (com.evolveum.midpoint.xml.ns._public.common.common_3.TracingRootType)1