T - the class that encapsulates the data for the profiling event context.S - the class of the source object from which the profiling event context is created.@Experimental
public interface ProfilingDataProducer<T extends ProfilingEventContext,S>
ProfilingEventContext.
A ProfilingDataProducer must be firstly registered via
ProfilingService.registerProfilingDataProducer(ProfilingEventType, ProfilingDataProducer) and then can be obtained via
ProfilingService.getProfilingDataProducer(ProfilingEventType). Once it is obtained, it can be used to emit profiling
data by invoking triggerProfilingEvent(ProfilingEventContext).
ProfilingService| Modifier and Type | Method and Description |
|---|---|
void |
triggerProfilingEvent(S sourceData,
Function<S,T> transformation)
Triggers a profiling event.
|
void |
triggerProfilingEvent(T profilerEventContext)
Triggers a profiling event.
|
void triggerProfilingEvent(T profilerEventContext)
profilerEventContext - the ProfilingEventContext for the emitted event.void triggerProfilingEvent(S sourceData, Function<S,T> transformation)
ProfilingEventContext is needed. It
may not need to produce nor generate the data. The ProfilingDataProducer implementation will be responsible to decide
this.sourceData - object to transform.transformation - transformation to apply to generate the ProfilingEventContext.Copyright © 2022 MuleSoft, Inc.. All rights reserved.