Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions .github/workflows/build_and_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -350,3 +350,16 @@ jobs:
| grep -q 'spark.kubernetes.operator.dynamicConfig.enabled=true'; then
echo "dynamicConfig enabled with enable=false"; exit 1
fi
- name: Validate the deprecated helm key warning
run: |
# `helm template` skips NOTES.txt, so the warning is only observable through an
# install. `--dry-run=client` renders it without reaching a cluster.
notes=$(helm install spark build-tools/helm/spark-kubernetes-operator --dry-run=client \
--set operatorDeployment.networkPolicy.enable=true \
--set operatorConfiguration.dynamicConfig.enable=true)
echo "$notes" | grep -q 'operatorDeployment.networkPolicy.enable is deprecated'
echo "$notes" | grep -q 'operatorConfiguration.dynamicConfig.enable is deprecated'
notes=$(helm install spark build-tools/helm/spark-kubernetes-operator --dry-run=client)
if echo "$notes" | grep -q 'is deprecated'; then
echo "Deprecation warning printed without a legacy key"; exit 1
fi
31 changes: 31 additions & 0 deletions build-tools/helm/spark-kubernetes-operator/templates/NOTES.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
{{- /*
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/ -}}
Apache Spark Kubernetes Operator {{ .Chart.AppVersion }} is installed.
{{- if hasKey (.Values.operatorDeployment.networkPolicy | default dict) "enable" }}

WARNING: operatorDeployment.networkPolicy.enable is deprecated, use
operatorDeployment.networkPolicy.enabled instead. The legacy key is still honored:
the NetworkPolicy is created when either key is true. It will be removed in chart
2.0.0, see SPARK-59533.
{{- end }}
{{- if hasKey (.Values.operatorConfiguration.dynamicConfig | default dict) "enable" }}

WARNING: operatorConfiguration.dynamicConfig.enable is deprecated, use
operatorConfiguration.dynamicConfig.enabled instead. The legacy key is still
honored: hot properties loading is enabled when either key is true. It will be
removed in chart 2.0.0, see SPARK-59533.
{{- end }}