Pipeline.Streaming.PerformanceAnalyzer (PipelineEx v0.1.1)

View Source

Analyzes streaming performance and provides optimization recommendations.

This module hooks into the streaming pipeline to collect detailed metrics and identify bottlenecks or optimization opportunities.

Summary

Functions

Analyze all completed streams and generate recommendations.

Compare streaming vs non-streaming performance.

Complete a stream and move it to completed list.

Get performance report for all streams.

Identify bottlenecks in streaming performance.

Start a new performance analyzer.

Record a message in an active stream.

Types

t()

@type t() :: %Pipeline.Streaming.PerformanceAnalyzer{
  active_streams: map(),
  completed_streams: [Pipeline.Monitoring.StreamingMetrics.t()],
  performance_issues: [map()],
  recommendations: [String.t()]
}

Functions

analyze(analyzer)

@spec analyze(t()) :: t()

Analyze all completed streams and generate recommendations.

compare_modes(streaming_results, sync_results)

@spec compare_modes([Pipeline.Monitoring.StreamingMetrics.t()], [map()]) :: map()

Compare streaming vs non-streaming performance.

complete_stream(analyzer, stream_id)

@spec complete_stream(t(), String.t()) :: t()

Complete a stream and move it to completed list.

get_report(analyzer)

@spec get_report(t()) :: map()

Get performance report for all streams.

identify_bottlenecks(analyzer)

@spec identify_bottlenecks(t()) :: [map()]

Identify bottlenecks in streaming performance.

new()

@spec new() :: t()

Start a new performance analyzer.

record_message(analyzer, stream_id, message)

@spec record_message(t(), String.t(), map()) :: t()

Record a message in an active stream.

start_stream(analyzer, stream_id, handler_type)

@spec start_stream(t(), String.t(), atom()) :: t()

Start tracking a new stream.