Upgrading Alauda Distributed Tracing with Elasticsearch
Upgrading an Elasticsearch-backed deployment from v2.0 (Jaeger 2.16.0, Alauda Build of OpenTelemetry v2 Operator 0.147.0) to v2.1 (Jaeger 2.20.0, Operator 0.157.0) involves the following steps:
- Installing the Alauda Build of Jaeger v2 cluster plugin
- Upgrading the Alauda Build of OpenTelemetry v2 Operator
- Updating the OpenTelemetry Collector
- Updating the Elasticsearch index templates
- Updating the Alauda Build of Jaeger v2
Jaeger v2.20.0 rejects the legacy Elasticsearch rotation flags use_aliases and use_ilm. Update the image and the configuration of the Jaeger instance in a single patch (step 5), otherwise the new Pod exits at startup with invalid configuration: ... deprecated ES rotation flags ... are no longer supported. Because the new Pod never becomes ready, the previous Pod keeps serving traces, so a stalled rollout does not interrupt tracing.
This procedure keeps all trace data in place. No index, alias, or ILM policy is recreated, and existing indices remain readable.
Prerequisites
- An Alauda Distributed Tracing v2.0 deployment installed as described in Installing Alauda Distributed Tracing with Elasticsearch.
- The Alauda Build of Jaeger v2 cluster plugin and the Alauda Build of OpenTelemetry v2 Operator 0.157.0 are published to the platform.
- An active ACP CLI (
kubectl) session by a cluster administrator with thecluster-adminrole, for both the target cluster and theglobalcluster. - Review the Upgrade Notes for the behavior changes introduced by this release.
Setting environment variables
Run the following commands against the target cluster. The Elasticsearch endpoint and the index prefix are read back from the running Jaeger instance so that they always match the existing deployment:
TOC
Installing the Alauda Build of Jaeger v2 Cluster PluginInstalling via the web consoleInstalling via the CLIReading the image addressesUpgrading the Alauda Build of OpenTelemetry v2 OperatorUpgrading via the web consoleUpgrading via the CLIUpdating the OpenTelemetry Collector(Optional) Updating the Collector for Service Performance MonitoringUpdating the Elasticsearch Index TemplatesUpdating the Alauda Build of Jaeger v2(Optional) Updating Jaeger for Service Performance MonitoringVerificationInstalling the Alauda Build of Jaeger v2 Cluster Plugin
Starting with v2.1, the container images of the tracing components are delivered by the Alauda Build of Jaeger v2 cluster plugin instead of the Operator bundle. Installing the plugin synchronizes the images to the platform's built-in registry and creates the jaeger-cluster-plugin-manifest ConfigMap in the cpaas-system namespace of the target cluster. The remaining steps read the image addresses from that ConfigMap.
Installing via the web console
- In the platform management view, navigate to Administrator > Marketplace > Cluster Plugins.
- Select the cluster where the tracing components are deployed.
- Find Alauda Build of Jaeger v2 and click Install. The plugin requires no installation parameters.
Installing via the CLI
Cluster plugins are installed by creating a ModuleInfo resource in the global cluster, regardless of which cluster the plugin targets.
-
Run the following command in the
globalcluster to check the published plugin versions: -
Create a
ModuleInforesource in theglobalcluster. Replace<target-cluster>with the name of the cluster where the tracing components are deployed, and<plugin-version>with a version from the previous step: -
Verify the installation in the
globalcluster. The plugin is installed successfully when theSTATUScolumn showsRunning:NOTEThe platform assigns the resource a generated name, so query the
ModuleInfoby label rather than by the name used in the manifest.
Reading the image addresses
Run the following commands against the target cluster. The exported variables are used in the later steps:
Upgrading the Alauda Build of OpenTelemetry v2 Operator
The Operator is subscribed with the Manual approval strategy, so the upgrade must be approved explicitly. For general background on Operator upgrades, see Operator.
Upgrading via the web console
Choose one of the following methods:
- Batch upgrade: navigate to Platform Management > Cluster Management > Clusters > cluster > Functional Components, and upgrade Alauda Build of OpenTelemetry v2.
- Individual upgrade: navigate to Administrator > Marketplace > OperatorHub, open Alauda Build of OpenTelemetry v2, and approve the pending upgrade request.
Upgrading via the CLI
-
Confirm that the target version is available in the subscribed channel:
-
Approve the pending
InstallPlan: -
Wait until the new
ClusterServiceVersionreaches theSucceededphase:Example output
The Operator upgrade restarts the managed collectors. The otel Collector does not pin spec.image, so it immediately picks up the Collector version shipped with the new Operator, while the Jaeger instance stays on the image pinned in spec.image until step 5. The renamed component types remain available as deprecated aliases, so the Collector keeps running and only logs deprecation warnings until the next step.
Updating the OpenTelemetry Collector
The Operator reissues its admission webhook certificate during the upgrade. A patch applied in that window is rejected with failed calling webhook "mopentelemetrycollectorbeta.kb.io": ... x509: certificate signed by unknown authority. Wait a few seconds and apply it again.
Procedure
-
Create a file named
otel-upgrade-patch.yamlwith the following content:- The
otlpexporter type is renamed tootlp_grpc. Setting the old key tonullremoves it, and the new key recreates the exporter with the same endpoint. add_metric_suffixesis deprecated and silently ignored.translation_strategy: UnderscoreEscapingWithoutSuffixeskeeps the metric names free of Prometheus-style suffixes.- The
without_scope_info,without_type_suffix, andwithout_unitssettings of the Prometheus reader now default totrueand are dropped. Becausereadersis a list, the patch replaces it as a whole. The exposed metric names are unchanged.
- The
-
Render the patch with
envsubstand apply it: -
Wait for the Collector to restart, and confirm that it starts without deprecation warnings:
(Optional) Updating the Collector for Service Performance Monitoring
Rename the loadbalancing exporter that routes spans to the Jaeger tier. Apply this patch right after the previous one: in between, spans reach Jaeger through the direct exporter instead of being routed by service, which fragments the RED metrics if the Jaeger tier runs with more than one replica.
-
Create a file named
otel-spm-upgrade-patch.yamlwith the following content: -
Render the patch with
envsubstand apply it:
Updating the Elasticsearch Index Templates
Jaeger v2.20.0 writes additional span fields, such as scopeTags and references.traceState. Re-run the jaeger-es-rollover initialization with the new image so that the index templates are updated and the indices created by future rollovers carry the new mappings.
The initialization is idempotent: it overwrites the index templates, and skips indices and aliases that already exist. Existing data is not modified.
Procedure
-
Run the initialization Job:
-
Verify that the span index template now contains the new fields:
Updating the Alauda Build of Jaeger v2
Procedure
-
Update the OAuth2 Proxy sidecar image. Because
additionalContainersis a list that a merge patch would replace as a whole, this container is updated with a JSON patch of its own. The Jaeger container is still running the previous version at this point, so this restart is safe: -
Create a file named
jaeger-upgrade-patch.yamlwith the following content. The image and the configuration must be changed together, so both are part of the same patch:- The legacy rotation flags are rejected since Jaeger v2.20.0 and must be removed.
max_trace_durationwidens the query time range on both sides so that spans extending beyond the search window are still found. See Query Time Range.rotation.auto_rolloverreplacesuse_aliasesanduse_ilm. Its default alias names match the aliases created by thejaeger-es-rolloverinitialization, so no data, alias, or ILM policy has to change. Leaveauto_rollover.policy_nameempty, because the ILM policy reference is already embedded in the index templates. See Index Management Strategies.- The Operator parses
service.telemetry.resourceas a flat map of strings and silently discards the wholeservice.telemetrysection if it is not. Jaeger already reports its ownservice.nameandservice.version, so the block is removed rather than migrated. - As for the
otelCollector, thewithout_*settings now default totrueand are dropped by replacing thereaderslist.
-
Render the patch with
envsubst, apply it, and wait for Jaeger to restart:
(Optional) Updating Jaeger for Service Performance Monitoring
-
Create a file named
jaeger-spm-upgrade-patch.yamlwith the following content: -
Render the patch with
envsubst, apply it, and wait for Jaeger to restart:
This rename applies to the Jaeger distribution. A standalone OpenTelemetry Collector only registers span_metrics from Collector 0.152.0 onwards, so verify the Collector version before renaming the connector in a front Collector configuration.
Verification
-
Confirm the component versions and that all Pods are ready:
-
Confirm that Jaeger starts without deprecation warnings:
-
Generate sample traces and confirm that they are stored and queryable, as described in the Verification section of the installation procedure. If SPM is enabled, also open the Monitor tab in the Jaeger UI and confirm that RED metrics are shown for the generated service.