Commands
EXPLAIN ANALYZE
Use the EXPLAIN ANALYZE
command to analyze the actual runtime performance of a streaming job.
As EXPLAIN
shows the execution plan of a query or job before execution, EXPLAIN ANALYZE
analyzes a running stream job, including table, materialized view, sink, or index, and collects runtime statistics to help identify performance bottlenecks.
EXPLAIN ANALYZE
is enabled by default. To disable it, set enable_explain_analyze_stats = false
under [streaming.developer]
.
Syntax
duration_secs
specifies the profiling duration in seconds.
Metrics
When you run EXPLAIN ANALYZE
, it returns a table showing runtime statistics for each operator involved in the execution.
Field name | Description |
---|---|
identity | The name and hierarchical structure of the operator (e.g., StreamHashJoin, MergeExecutor. |
actor_ids | The IDs of concurrent actors running this operator. |
output_rps | The number of records output per second (records per second). |
avg_output_pending_ratio | The average ratio of pending outputs in the buffer, indicating how quickly downstream operators are consuming data. |
Example
Sample output:
Related topics
- To check the execution plan for a new statement before it runs, see
EXPLAIN
. - To check the execution fragments of an existing streaming job, see
DESCRIBE FRAGMENTS
.