milenkovicm commented on code in PR #21767:
URL: https://github.com/apache/datafusion/pull/21767#discussion_r3328312842
##########
datafusion/physical-plan/src/analyze.rs:
##########
@@ -48,34 +51,94 @@ pub struct AnalyzeExec {
metric_types: Vec<MetricType>,
/// Optional filter by semantic category (rows / bytes / timing).
metric_categories: Option<Vec<MetricCategory>>,
+ /// Output format for the rendered plan + metrics.
+ format: ExplainFormat,
/// The input plan (the plan being analyzed)
pub(crate) input: Arc<dyn ExecutionPlan>,
/// The output schema for RecordBatches of this exec node
schema: SchemaRef,
cache: Arc<PlanProperties>,
}
-impl AnalyzeExec {
- /// Create a new AnalyzeExec
+/// Builder for [`AnalyzeExec`].
+///
+/// Required: `verbose`, `show_statistics`, `input`, `schema`.
+/// Optional (all have sensible defaults):
+/// - `metric_types` — defaults to `[Summary, Dev]`
+/// - `metric_categories` — defaults to `None` (all categories)
+/// - `format` — defaults to [`ExplainFormat::Indent`]
+pub struct AnalyzeExecBuilder {
Review Comment:
do you need to capture this info, required and optional are captured with
builder constructor and other methods
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]