[AKS] Rename OpenTelemetry ports and add gRPC support for metrics/logs - #10079
Draft
ChFlick wants to merge 7 commits into
Draft
[AKS] Rename OpenTelemetry ports and add gRPC support for metrics/logs#10079ChFlick wants to merge 7 commits into
ChFlick wants to merge 7 commits into
Conversation
❌Azure CLI Extensions Breaking Change Test
|
microsoft-github-policy-service
Bot
requested review from
FumingZhang,
yanzhudd and
yonzhan
July 6, 2026 16:23
Collaborator
|
AKS |
ChFlick
force-pushed
the
cbutz/aks-preview-otlp-grpc
branch
from
July 13, 2026 16:31
12eb037 to
81f1913
Compare
Member
|
/azp run |
|
Azure Pipelines: Successfully started running 2 pipeline(s). |
Member
|
/azp run |
|
Azure Pipelines: Successfully started running 2 pipeline(s). |
ChFlick
force-pushed
the
cbutz/aks-preview-otlp-grpc
branch
from
July 15, 2026 15:30
008c692 to
626a2f2
Compare
Member
|
/azp run |
|
Azure Pipelines: Successfully started running 2 pipeline(s). |
added 5 commits
July 17, 2026 11:54
…le flags with deprecated aliases Renames the OTLP CLI parameters on 'az aks create/update' to distinguish the HTTP/protobuf port and to align logs with logs-and-traces, keeping the old names working as deprecated aliases: - --opentelemetry-metrics-port -> --opentelemetry-metrics-port-http - --opentelemetry-logs-port -> --opentelemetry-logs-traces-port-http - --enable-opentelemetry-logs -> --enable-opentelemetry-logs-traces - --disable-opentelemetry-logs -> --disable-opentelemetry-logs-traces Each renamed option is registered as two arguments sharing one destination: the new name carries is_preview=True and the old name is a separate deprecated argument (deprecate_info). This avoids the knack crash from combining is_preview with an option-level c.deprecate (Deprecated has no __len__), and lets the new names show [Preview] while the old names show [Deprecated] and redirect. A validator merges any value supplied via a deprecated alias onto the current destination so downstream logic reads a single dest. Updates help text, validator/decorator error messages, and tests to the new names; migrates the live integration scenarios and fixes stale API field assertions (openTelemetryLogs.port -> openTelemetryLogsAndTraces.httpPort).
Adds --opentelemetry-metrics-port-grpc and --opentelemetry-logs-traces-port-grpc (preview) to 'az aks create/update', wiring the new grpc_port field on the appMonitoring OpenTelemetry profiles (API 2026-04-02-preview). - Validation: all four OTLP ports (metrics/logs x http/grpc) must be in 1..65535 and distinct; grpc ports follow the same enable/disable gating as the http ports. - Disable paths now clear both http_port and grpc_port, including when the parent Azure Monitor metrics/logs are disabled. - Adds unit, validator, and live integration coverage; bumps version to 21.0.0b8 and updates HISTORY.
… and metrics Adds --opentelemetry-*-port-grpc flags and grpcPort assertions to the live OpenTelemetry integration scenarios so gRPC is exercised symmetrically for both the metrics and logs/traces signals (previously only metrics-create asserted grpcPort). The comprehensive monitoring test also now asserts that disabling OpenTelemetry metrics/logs clears both httpPort and grpcPort.
…res header The AzureMonitorAppMonitoringPreview capability is gated by subscription feature registration, not by a per-request AKSHTTPCustomFeatures header. The resource provider now rejects that header with '(BadRequest) Parameter aksHTTPCustomFeatures is not allowed', causing every OpenTelemetry @live_only scenario to fail before reaching its assertions. Removes '--aks-custom-headers AKSHTTPCustomFeatures=Microsoft.ContainerService/AzureMonitorAppMonitoringPreview' from the six OpenTelemetry live tests. Verified live that create/update with the OTLP flags succeeds once the header is dropped (feature registered on the subscription). The recorded app-monitoring tests are left unchanged, as they replay a cassette that still contains the header.
ChFlick
force-pushed
the
cbutz/aks-preview-otlp-grpc
branch
from
July 17, 2026 10:57
626a2f2 to
5e5c6b1
Compare
Member
|
/azp run |
|
Azure Pipelines: Successfully started running 2 pipeline(s). |
Member
|
@ChFlick are you still working on this PR? |
Author
|
@FumingZhang yes I'm still working on this - I needed to wait for end-to-end testing to be available and I'm waiting for reviews from my team |
added 2 commits
July 28, 2026 15:43
The gate guarding ensure_azure_monitor_profile_prerequisites in update_azure_monitor_profile treated every OpenTelemetry parameter as metrics-related. Setting only an OTLP logs/traces port therefore ran the full Prometheus onboarding path, creating an Azure Monitor Workspace, DCE, DCR, DCRA, a Grafana link and recording rules. OpenTelemetry logs and traces ride the Container Insights pipeline and have no dependency on those artifacts, so restrict the gate to Azure Monitor metrics and OpenTelemetry metrics parameters only. Add five regression tests that assert on the prerequisites mock. The existing OpenTelemetry tests patch it purely to suppress network calls and never assert on it, which is why this went unnoticed. Three cover the logs/traces cases and two guard against over-correcting by verifying that metrics-only and mixed-signal commands still onboard exactly once.
Resolves the aks-preview version collision: main released 21.0.0b11
("Vendor new SDK and bump API version to 2026-05-02-preview") while this
branch was also using 21.0.0b11. Moved this branch's changelog entries to a
new 21.0.0b12 section and bumped setup.py accordingly.
Verified the newly vendored SDK still exposes http_port and grpc_port on
ManagedClusterAzureMonitorProfileAppMonitoringOpenTelemetryMetrics and
...OpenTelemetryLogsAndTraces (serialized as httpPort/grpcPort), so the
OpenTelemetry port work on this branch remains compatible.
Member
|
/azp run |
|
Azure Pipelines: Successfully started running 2 pipeline(s). |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
🤖 PR Validation — ❌ Action needed
❌Azure CLI Extensions Breaking Change Test
Testing notes:
azdev extension add aks-previewand confirmed it loads & verified new flags appear inaz aks update --helpwith correct [Preview] (new port/enable flags) and [Deprecated] (renamed old flags) decorationaz aks updateagainst a live cluster with--enable-opentelemetry-metrics --opentelemetry-metrics-port-http/-grpcand used--debugto confirm the payload includes the new grpcPort / httpPort fields underazureMonitorProfile.appMonitoring.openTelemetryMetrics--enable-opentelemetry-*flag isn't set / OTLP isn't already enabledThis checklist is used to make sure that common guidelines for a pull request are followed.
Related command
General Guidelines
azdev style <YOUR_EXT>locally? (pip install azdevrequired)python scripts/ci/test_index.py -qlocally? (azdevrequired; see.azure-pipelines/templates/azdev_setup.ymlfor the install command untilazdev==0.2.11b1is on PyPI)For new extensions:
About Extension Publish
There is a pipeline to automatically build, upload and publish extension wheels.
Once your pull request is merged into main branch, a new pull request will be created to update
src/index.jsonautomatically.You only need to update the version information in file setup.py and historical information in file HISTORY.rst in your PR but do not modify
src/index.json.