Class StreamIntrospectionD2Writer
java.lang.Object
org.nuxeo.ecm.core.io.marshallers.d2.AbstractD2Writer<StreamIntrospection>
org.nuxeo.ecm.core.bulk.introspection.StreamIntrospectionD2Writer
- All Implemented Interfaces:
Marshaller<StreamIntrospection>,Writer<StreamIntrospection>
@Setup(mode=SINGLETON,
priority=2000)
public class StreamIntrospectionD2Writer
extends AbstractD2Writer<StreamIntrospection>
Converts stream introspection data to D2 diagram format.
- Since:
- 2025.12
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected static final Stringstatic final Stringstatic final Stringprotected static final StreamIntrospectionToStreamFlattenMetricsFields inherited from class org.nuxeo.ecm.core.io.marshallers.d2.AbstractD2Writer
ctx -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected List<org.apache.commons.lang3.tuple.Pair<StreamIntrospection.ProcessorComputation,StreamIntrospection.ProcessorMetadata>> collectComputations(StreamIntrospection streamIntrospection, StreamFlattenMetrics streamMetrics) protected StringgetBatchInfo(StreamIntrospection.ProcessorComputation computation) protected StringgetComputationMetrics(String host, StreamIntrospection.ProcessorComputation computation, StreamFlattenMetrics streamMetrics) protected longgetStreamEnd(StreamFlattenMetrics metrics, String name) protected StringgetTimerAsJson(String title, StreamFlattenMetrics.ComputationMetric computationMetric, StreamIntrospection.TimerMetric timerMetric) protected booleanshouldExcludeByInactivity(String name, String host, StreamFlattenMetrics metrics) Checks if a computation should be excluded based on inactivity filter.protected booleanshouldExcludeByPattern(String name) Checks if a name (stream or computation) should be excluded based on patterns.protected booleanshouldExcludeStreamByInactivity(String streamName, StreamFlattenMetrics metrics) Checks if a stream should be excluded based on inactivity filter.protected voidwrite(StreamIntrospection.ProcessorComputation computation, StreamIntrospection.ProcessorMetadata metadata, StreamFlattenMetrics streamMetrics, D2Printer d2Printer) protected voidwrite(StreamIntrospection.ProcessorStreamConsumerTopology topology, StreamIntrospection.ProcessorMetadata metadata, StreamFlattenMetrics streamMetrics, D2Printer d2Printer) protected voidwrite(StreamIntrospection.ProcessorStreamProducerTopology topology, StreamIntrospection.ProcessorMetadata metadata, D2Printer d2Printer) protected voidwrite(StreamIntrospection entity, D2Printer d2Printer) Methods inherited from class org.nuxeo.ecm.core.io.marshallers.d2.AbstractD2Writer
accept, getD2Printer, write
-
Field Details
-
PARAMETER_EXCLUDE_FILTER
- Since:
- 2025.12
- See Also:
-
PARAMETER_EXCLUDE_INACTIVE
- Since:
- 2025.12
- See Also:
-
TO_STREAM_FLATTEN_METRICS
-
D2_HEADER_TEMPLATE
- See Also:
-
-
Constructor Details
-
StreamIntrospectionD2Writer
public StreamIntrospectionD2Writer()
-
-
Method Details
-
write
- Specified by:
writein classAbstractD2Writer<StreamIntrospection>- Throws:
IOException
-
write
protected void write(StreamIntrospection.ProcessorStreamConsumerTopology topology, StreamIntrospection.ProcessorMetadata metadata, StreamFlattenMetrics streamMetrics, D2Printer d2Printer) throws IOException - Throws:
IOException
-
write
protected void write(StreamIntrospection.ProcessorStreamProducerTopology topology, StreamIntrospection.ProcessorMetadata metadata, D2Printer d2Printer) throws IOException - Throws:
IOException
-
shouldExcludeByPattern
Checks if a name (stream or computation) should be excluded based on patterns. -
shouldExcludeByInactivity
Checks if a computation should be excluded based on inactivity filter. -
shouldExcludeStreamByInactivity
Checks if a stream should be excluded based on inactivity filter. -
getStreamEnd
-
getComputationMetrics
protected String getComputationMetrics(String host, StreamIntrospection.ProcessorComputation computation, StreamFlattenMetrics streamMetrics) -
getTimerAsJson
protected String getTimerAsJson(String title, StreamFlattenMetrics.ComputationMetric computationMetric, StreamIntrospection.TimerMetric timerMetric) -
getBatchInfo
-
collectComputations
protected List<org.apache.commons.lang3.tuple.Pair<StreamIntrospection.ProcessorComputation,StreamIntrospection.ProcessorMetadata>> collectComputations(StreamIntrospection streamIntrospection, StreamFlattenMetrics streamMetrics) -
write
protected void write(StreamIntrospection.ProcessorComputation computation, StreamIntrospection.ProcessorMetadata metadata, StreamFlattenMetrics streamMetrics, D2Printer d2Printer)
-