Skip to content
Merged
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
2 changes: 1 addition & 1 deletion chart/values.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -9511,7 +9511,7 @@
"tracesEnabled": {
"description": "Send Airflow traces to the OTel Collector. Sets `[traces] otel_on` in the rendered Airflow config and deploys the collector when either `tracesEnabled` or `metricsEnabled` is true.",
"type": "boolean",
"default": true
"default": false
},
"metricsEnabled": {
"description": "Send Airflow metrics to the OTel Collector. Sets `[metrics] otel_on` in the rendered Airflow config and forces `[metrics] statsd_on` to False because Airflow can only export metrics to one backend at a time.",
Expand Down
2 changes: 1 addition & 1 deletion chart/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3504,7 +3504,7 @@ statsd:
# OpenTelemetry Collector settings
otelCollector:
# Send Airflow traces to the OTel Collector (sets [traces] otel_on).
tracesEnabled: true
tracesEnabled: false

# Send Airflow metrics to the OTel Collector (sets [metrics] otel_on and disables statsd).
metricsEnabled: false
Expand Down
12 changes: 0 additions & 12 deletions helm-tests/tests/helm_tests/airflow_aux/test_airflow_common.py
Original file line number Diff line number Diff line change
Expand Up @@ -419,10 +419,6 @@ def test_should_disable_some_variables(self):
"AIRFLOW__CORE__FERNET_KEY",
"AIRFLOW_CONN_AIRFLOW_DB",
"AIRFLOW__CELERY__BROKER_URL",
"OTEL_SERVICE_NAME",
"OTEL_EXPORTER_OTLP_PROTOCOL",
"OTEL_TRACES_EXPORTER",
"OTEL_EXPORTER_OTLP_TRACES_ENDPOINT",
]
expected_vars_in_worker = ["DUMB_INIT_SETSID"] + expected_vars
for doc in docs:
Expand Down Expand Up @@ -453,10 +449,6 @@ def test_have_all_variables(self):
"AIRFLOW__API__SECRET_KEY",
"AIRFLOW__API_AUTH__JWT_SECRET",
"AIRFLOW__CELERY__BROKER_URL",
"OTEL_SERVICE_NAME",
"OTEL_EXPORTER_OTLP_PROTOCOL",
"OTEL_TRACES_EXPORTER",
"OTEL_EXPORTER_OTLP_TRACES_ENDPOINT",
]
expected_vars_no_jwt = [
"AIRFLOW_HOME",
Expand All @@ -465,10 +457,6 @@ def test_have_all_variables(self):
"AIRFLOW_CONN_AIRFLOW_DB",
"AIRFLOW__API__SECRET_KEY",
"AIRFLOW__CELERY__BROKER_URL",
"OTEL_SERVICE_NAME",
"OTEL_EXPORTER_OTLP_PROTOCOL",
"OTEL_TRACES_EXPORTER",
"OTEL_EXPORTER_OTLP_TRACES_ENDPOINT",
]
for doc in docs:
component = doc["metadata"]["labels"]["component"]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@
("ServiceAccount", "test-basic-airflow-redis"),
("ServiceAccount", "test-basic-airflow-scheduler"),
("ServiceAccount", "test-basic-airflow-statsd"),
("ServiceAccount", "test-basic-airflow-otel-collector"),
("ServiceAccount", "test-basic-airflow-triggerer"),
("ServiceAccount", "test-basic-airflow-worker"),
("Secret", "test-basic-airflow-metadata"),
Expand All @@ -43,21 +42,18 @@
("Secret", "test-basic-postgresql"),
("ConfigMap", "test-basic-airflow-config"),
("ConfigMap", "test-basic-airflow-statsd"),
("ConfigMap", "test-basic-airflow-otel-collector"),
("Role", "test-basic-airflow-pod-launcher-role"),
("Role", "test-basic-airflow-pod-log-reader-role"),
("RoleBinding", "test-basic-airflow-pod-launcher-rolebinding"),
("RoleBinding", "test-basic-airflow-pod-log-reader-rolebinding"),
("Service", "test-basic-airflow-redis"),
("Service", "test-basic-airflow-statsd"),
("Service", "test-basic-airflow-otel-collector"),
("Service", "test-basic-airflow-triggerer"),
("Service", "test-basic-airflow-worker"),
("Service", "test-basic-postgresql"),
("Service", "test-basic-postgresql-hl"),
("Deployment", "test-basic-airflow-scheduler"),
("Deployment", "test-basic-airflow-statsd"),
("Deployment", "test-basic-airflow-otel-collector"),
("StatefulSet", "test-basic-airflow-redis"),
("StatefulSet", "test-basic-airflow-worker"),
("StatefulSet", "test-basic-airflow-triggerer"),
Expand Down Expand Up @@ -134,7 +130,6 @@ def test_basic_deployments(self, version):
("ServiceAccount", "test-basic-redis"),
("ServiceAccount", "test-basic-scheduler"),
("ServiceAccount", "test-basic-statsd"),
("ServiceAccount", "test-basic-otel-collector"),
("ServiceAccount", "test-basic-triggerer"),
("ServiceAccount", "test-basic-worker"),
("Secret", "test-basic-metadata"),
Expand All @@ -144,7 +139,6 @@ def test_basic_deployments(self, version):
("Secret", "test-basic-redis-password"),
("ConfigMap", "test-basic-config"),
("ConfigMap", "test-basic-statsd"),
("ConfigMap", "test-basic-otel-collector"),
("Role", "test-basic-pod-launcher-role"),
("Role", "test-basic-pod-log-reader-role"),
("RoleBinding", "test-basic-pod-launcher-rolebinding"),
Expand All @@ -153,12 +147,10 @@ def test_basic_deployments(self, version):
("Service", "test-basic-postgresql"),
("Service", "test-basic-redis"),
("Service", "test-basic-statsd"),
("Service", "test-basic-otel-collector"),
("Service", "test-basic-triggerer"),
("Service", "test-basic-worker"),
("Deployment", "test-basic-scheduler"),
("Deployment", "test-basic-statsd"),
("Deployment", "test-basic-otel-collector"),
("StatefulSet", "test-basic-triggerer"),
("StatefulSet", "test-basic-postgresql"),
("StatefulSet", "test-basic-redis"),
Expand Down Expand Up @@ -340,6 +332,7 @@ def test_network_policies_are_valid(self, airflow_version, executor):
"executor": executor,
"flower": {"enabled": True},
"pgbouncer": {"enabled": True},
"otelCollector": {"tracesEnabled": True},
},
version=airflow_version,
),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ class TestOtelCollectorDeployment:
TEMPLATE_FILE = "templates/otel-collector/otel-collector-deployment.yaml"

def test_should_add_global_labels_to_metadata(self):
"""Test adding only .Values.labels to metadata.labels."""
docs = render_chart(
values={
"otelCollector": {"tracesEnabled": True},
Expand All @@ -39,7 +38,6 @@ def test_should_add_global_labels_to_metadata(self):
assert jmespath.search("metadata.labels", docs[0])["test_global_label"] == "test_global_label_value"

def test_should_add_global_labels_to_pod_template(self):
"""Test adding only .Values.labels to spec.template.metadata.labels."""
docs = render_chart(
values={
"otelCollector": {"tracesEnabled": True},
Expand All @@ -55,7 +53,6 @@ def test_should_add_global_labels_to_pod_template(self):
)

def test_should_add_component_specific_labels_to_pod_template(self):
"""Test adding only .Values.otelCollector.labels to spec.template.metadata.labels."""
docs = render_chart(
values={
"otelCollector": {
Expand All @@ -73,7 +70,6 @@ def test_should_add_component_specific_labels_to_pod_template(self):
)

def test_should_merge_global_and_component_specific_labels_in_pod_template(self):
"""Test adding both .Values.labels and .Values.otelCollector.labels to spec.template.metadata.labels."""
docs = render_chart(
values={
"otelCollector": {
Expand All @@ -97,7 +93,6 @@ def test_should_merge_global_and_component_specific_labels_in_pod_template(self)
)

def test_component_specific_labels_should_override_global_labels(self):
"""Test that component-specific labels take precedence over global labels with the same key."""
docs = render_chart(
values={
"otelCollector": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ class TestOtelCollectorNetworkPolicy:
TEMPLATE_FILE = "templates/otel-collector/otel-collector-networkpolicy.yaml"

def test_should_add_global_labels(self):
"""Test adding only .Values.labels."""
docs = render_chart(
values={
"otelCollector": {"tracesEnabled": True},
Expand All @@ -40,7 +39,6 @@ def test_should_add_global_labels(self):
assert jmespath.search("metadata.labels", docs[0])["test_global_label"] == "test_global_label_value"

def test_should_add_component_specific_labels(self):
"""Test adding only .Values.otelCollector.labels."""
docs = render_chart(
values={
"otelCollector": {
Expand All @@ -59,7 +57,6 @@ def test_should_add_component_specific_labels(self):
)

def test_should_merge_global_and_component_specific_labels(self):
"""Test adding both .Values.labels and .Values.otelCollector.labels."""
docs = render_chart(
values={
"otelCollector": {
Expand All @@ -81,7 +78,6 @@ def test_should_merge_global_and_component_specific_labels(self):
)

def test_component_specific_labels_should_override_global_labels(self):
"""Test that component-specific labels take precedence over global labels with the same key."""
docs = render_chart(
values={
"otelCollector": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ class TestOtelCollectorService:
TEMPLATE_FILE = "templates/otel-collector/otel-collector-service.yaml"

def test_should_add_global_labels(self):
"""Test adding only .Values.labels."""
docs = render_chart(
values={
"otelCollector": {"tracesEnabled": True},
Expand All @@ -39,7 +38,6 @@ def test_should_add_global_labels(self):
assert jmespath.search("metadata.labels", docs[0])["test_global_label"] == "test_global_label_value"

def test_should_add_component_specific_labels(self):
"""Test adding only .Values.otelCollector.labels."""
docs = render_chart(
values={
"otelCollector": {
Expand All @@ -57,7 +55,6 @@ def test_should_add_component_specific_labels(self):
)

def test_should_merge_global_and_component_specific_labels(self):
"""Test adding both .Values.labels and .Values.otelCollector.labels."""
docs = render_chart(
values={
"otelCollector": {
Expand All @@ -78,7 +75,6 @@ def test_should_merge_global_and_component_specific_labels(self):
)

def test_component_specific_labels_should_override_global_labels(self):
"""Test that component-specific labels take precedence over global labels with the same key."""
docs = render_chart(
values={
"otelCollector": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ class TestOtelCollectorServiceAccount:
TEMPLATE_FILE = "templates/otel-collector/otel-collector-serviceaccount.yaml"

def test_should_add_global_labels(self):
"""Test adding only .Values.labels."""
docs = render_chart(
values={
"otelCollector": {"tracesEnabled": True},
Expand All @@ -39,7 +38,6 @@ def test_should_add_global_labels(self):
assert jmespath.search("metadata.labels", docs[0])["test_global_label"] == "test_global_label_value"

def test_should_add_component_specific_labels(self):
"""Test adding only .Values.otelCollector.labels."""
docs = render_chart(
values={
"otelCollector": {
Expand All @@ -57,7 +55,6 @@ def test_should_add_component_specific_labels(self):
)

def test_should_merge_global_and_component_specific_labels(self):
"""Test adding both .Values.labels and .Values.otelCollector.labels."""
docs = render_chart(
values={
"otelCollector": {
Expand All @@ -78,7 +75,6 @@ def test_should_merge_global_and_component_specific_labels(self):
)

def test_component_specific_labels_should_override_global_labels(self):
"""Test that component-specific labels take precedence over global labels with the same key."""
docs = render_chart(
values={
"otelCollector": {
Expand Down
Loading
Loading