mirror of
https://github.com/GreptimeTeam/greptimedb.git
synced 2026-11-21 18:24:07 +00:00
test(promql): read the partition producer's node metrics from the plan's own set (#10501)
`test_remote_write_v2_histogram_avg_native_partitions` read the producer's per-partition `native.root.output_values` through `ExecutionPlan::metrics`. `FusedSeriesExec::metrics` drops node metrics on purpose - `is_node_metric` covers `native.root.*`, so the operator's set reports only its own figures - and the map stayed empty. The assertion then saw zero partitions where the statement asks for four. Read the plan's own set through `node_metric_set`, which is how the other node-metric assertions in this file already do it. Signed-off-by: discord9 <discord9@163.com>
This commit is contained in:
@@ -7386,7 +7386,7 @@ pub async fn test_remote_write_v2_histogram_avg_native_partitions(store_type: St
|
||||
.iter()
|
||||
.find(|node| !Arc::ptr_eq(node, consumer))
|
||||
.expect("the partial producer");
|
||||
let metrics = producer.metrics().expect("producer metrics");
|
||||
let metrics = node_metric_set(producer);
|
||||
let mut partitions: BTreeMap<usize, usize> = BTreeMap::new();
|
||||
for metric in metrics.iter() {
|
||||
if metric.value().name() == "native.root.output_values"
|
||||
|
||||
Reference in New Issue
Block a user