Skip to content

Commit c44db7d

Browse files
committed
[SPARK-53187] Support SparkCluster event related metrics set
### What changes were proposed in this pull request? This PR adds SparkCluster as a supported type in metrics and therefore supports publishing execution metrics for it. ### Why are the changes needed? Operator by default publish metrics by resource type (SparkApplication) - by adding this support, we support the same set of counter and histogram for received event and timed execution ### Does this PR introduce _any_ user-facing change? More Metrics becomes available for SparkClusters ### How was this patch tested? From dev sandbox we can see metrics like ``` metrics_operator.sdk_sparkapplication_added_resource_event_Count{type="counters"} 9010 metrics_operator.sdk_sparkapplication_reconciliation_failed_Count{type="counters"} 9 metrics_operator.sdk_sparkapplication_reconciliation_finished_Count{type="counters"} 182841 metrics_operator.sdk_sparkapplication_reconciliation_retries_Count{type="counters"} 9 metrics_operator.sdk_sparkcluster_added_resource_event_Count{type="counters"} 9009 metrics_operator.sdk_sparkcluster_reconciliation_failed_Count{type="counters"} 0 metrics_operator.sdk_sparkcluster_reconciliation_finished_Count{type="counters"} 182821 metrics_operator.sdk_sparkcluster_reconciliation_retries_Count{type="counters"} 0 ``` ### Was this patch authored or co-authored using generative AI tooling? No Closes #295 from jiangzho/cluster_metrics. Authored-by: Zhou JIANG <[email protected]> Signed-off-by: Peter Toth <[email protected]>
1 parent cdd2790 commit c44db7d

File tree

1 file changed

+1
-0
lines changed
  • build-tools/helm/spark-kubernetes-operator/templates

1 file changed

+1
-0
lines changed

build-tools/helm/spark-kubernetes-operator/templates/_helpers.tpl

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -115,6 +115,7 @@ spark.kubernetes.operator.namespace={{ .Release.Namespace }}
115115
spark.kubernetes.operator.name={{- include "spark-operator.name" . }}
116116
spark.kubernetes.operator.dynamicConfig.enabled={{ .Values.operatorConfiguration.dynamicConfig.enable }}
117117
spark.kubernetes.operator.metrics.port={{ include "spark-operator.metricsPort" . }}
118+
spark.kubernetes.operator.health.probePort={{ include "spark-operator.probePort" . }}
118119
{{- if .Values.workloadResources.namespaces.overrideWatchedNamespaces }}
119120
spark.kubernetes.operator.watchedNamespaces={{ include "spark-operator.workloadNamespacesStr" . | trim }}
120121
{{- end }}

0 commit comments

Comments
 (0)