Skip to content

Conversation

gracewehner
Copy link

@gracewehner gracewehner commented Sep 9, 2025


This checklist is used to make sure that common guidelines for a pull request are followed.

Related command

az aks create/update --resource-group={resource_group} --name={name} --enable-azure-monitor-metrics --enable-opentelemetry-metrics [--opentelemetry-metrics-port <port>]
az aks create/update --resource-group={resource_group} --name={name} --disable-opentelemetry-metrics
az aks create/update --resource-group={resource_group} --name={name} -enable-opentelemetry-logs [--opentelemetry-logs-port <port>]
az aks create/update --resource-group={resource_group} --name={name} --disable-opentelemetry-logs

General Guidelines

  • Have you run azdev style <YOUR_EXT> locally? (pip install azdev required)
  • Have you run python scripts/ci/test_index.py -q locally? (pip install wheel==0.30.0 required)
  • My extension version conforms to the Extension version schema

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.json automatically.
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.

@Copilot Copilot AI review requested due to automatic review settings September 9, 2025 20:13
Copy link

azure-client-tools-bot-prd bot commented Sep 9, 2025

⚠️Azure CLI Extensions Breaking Change Test
⚠️aks-preview
rule cmd_name rule_message suggest_message
⚠️ 1006 - ParaAdd aks create cmd aks create added parameter disable_opentelemetry_logs
⚠️ 1006 - ParaAdd aks create cmd aks create added parameter disable_opentelemetry_metrics
⚠️ 1006 - ParaAdd aks create cmd aks create added parameter enable_opentelemetry_logs
⚠️ 1006 - ParaAdd aks create cmd aks create added parameter enable_opentelemetry_metrics
⚠️ 1006 - ParaAdd aks create cmd aks create added parameter opentelemetry_logs_port
⚠️ 1006 - ParaAdd aks create cmd aks create added parameter opentelemetry_metrics_port
⚠️ 1006 - ParaAdd aks update cmd aks update added parameter disable_opentelemetry_logs
⚠️ 1006 - ParaAdd aks update cmd aks update added parameter disable_opentelemetry_metrics
⚠️ 1006 - ParaAdd aks update cmd aks update added parameter enable_opentelemetry_logs
⚠️ 1006 - ParaAdd aks update cmd aks update added parameter enable_opentelemetry_metrics
⚠️ 1006 - ParaAdd aks update cmd aks update added parameter opentelemetry_logs_port
⚠️ 1006 - ParaAdd aks update cmd aks update added parameter opentelemetry_metrics_port

Copy link

Hi @gracewehner,
Please write the description of changes which can be perceived by customers into HISTORY.rst.
If you want to release a new extension version, please update the version in setup.py as well.

@yonzhan
Copy link
Collaborator

yonzhan commented Sep 9, 2025

Thank you for your contribution! We will review the pull request and get back to you soon.

Copy link

github-actions bot commented Sep 9, 2025

The git hooks are available for azure-cli and azure-cli-extensions repos. They could help you run required checks before creating the PR.

Please sync the latest code with latest dev branch (for azure-cli) or main branch (for azure-cli-extensions).
After that please run the following commands to enable git hooks:

pip install azdev --upgrade
azdev setup -c <your azure-cli repo path> -r <your azure-cli-extensions repo path>

Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds OpenTelemetry metrics and logs configuration support to the aks-preview extension. The changes enable users to configure OpenTelemetry endpoints with custom ports for both metrics and logs collection, requiring Azure Monitor as a prerequisite.

Key changes:

  • Added new CLI parameters for enabling/disabling OpenTelemetry metrics and logs
  • Implemented port validation and dependency checking
  • Extended managed cluster decorator to handle OpenTelemetry configuration

Reviewed Changes

Copilot reviewed 9 out of 9 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
setup.py Version bump to 18.0.0b37
test_validators.py Added comprehensive test coverage for OpenTelemetry validation functions
test_opentelemetry_integration.py New integration test file for end-to-end OpenTelemetry functionality
test_managed_cluster_decorator.py Added tests for OpenTelemetry parameter handling in decorators
managed_cluster_decorator.py Core implementation of OpenTelemetry configuration logic
custom.py Added OpenTelemetry parameters to function signatures
_validators.py Implemented validation functions for OpenTelemetry configurations
_params.py Added CLI parameter definitions and validation hooks
_help.py Added help documentation for new OpenTelemetry parameters

Copy link

github-actions bot commented Sep 9, 2025

@yonzhan
Copy link
Collaborator

yonzhan commented Sep 9, 2025

Please fix CI issues

@FumingZhang
Copy link
Member

/azp run

Copy link

Azure Pipelines successfully started running 2 pipeline(s).

Copy link
Member

@FumingZhang FumingZhang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

could you please add some scenario test cases to test_aks_commands.py to help verify your change?

@gracewehner
Copy link
Author

/azp run

Copy link

Commenter does not have sufficient privileges for PR 9149 in repo Azure/azure-cli-extensions

@FumingZhang
Copy link
Member

/azp run

Copy link

Azure Pipelines successfully started running 2 pipeline(s).

@github-actions github-actions bot added the release-version-block Updates do not qualify release version rules. NOTE: please do not edit it manually. label Sep 18, 2025
@github-actions github-actions bot removed the release-version-block Updates do not qualify release version rules. NOTE: please do not edit it manually. label Sep 18, 2025
)
return enable_opentelemetry_logs

def get_enable_opentelemetry_logs(self) -> bool:
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

logs_and_traces

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

keep consistent with profile, doc for traces

@FumingZhang
Copy link
Member

/azp run

Copy link

Azure Pipelines will not run the associated pipelines, because the pull request was updated after the run command was issued. Review the pull request again and issue a new run command.

@yonzhan
Copy link
Collaborator

yonzhan commented Sep 19, 2025

/azp run

Copy link

Azure Pipelines successfully started running 2 pipeline(s).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
AKS Auto-Assign Auto assign by bot
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants