Support SessionPool for API version 202502-02-preview#8793
Support SessionPool for API version 202502-02-preview#8793yitaopan wants to merge 2 commits intoAzure:mainfrom
Conversation
|
Validation for Breaking Change Starting...
Thanks for your contribution! |
|
Hi @yitaopan, |
|
Thank you for your contribution! We will review the pull request and get back to you soon. |
|
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). pip install azdev --upgrade
azdev setup -c <your azure-cli repo path> -r <your azure-cli-extensions repo path>
|
CodeGen Tools Feedback CollectionThank you for using our CodeGen tool. We value your feedback, and we would like to know how we can improve our product. Please take a few minutes to fill our codegen survey |
There was a problem hiding this comment.
Pull Request Overview
This PR adds support for the new session pool lifecycleConfiguration schema under API version 2025-02-02-preview, updates test validations accordingly, and wires up the new API version in the SDK client.
- Refactored dynamicPoolConfiguration to nest executionType and cooldown under lifecycleConfiguration
- Enhanced tests to assert lifecycleConfiguration fields and added SubnetPreparer decorators
- Updated SessionPoolPreviewClient to use the literal
"2025-02-02-preview"version
Reviewed Changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| src/containerapp/azext_containerapp/tests/latest/test_containerapp_sessionpool.py | Added lifecycleConfiguration JMESPath checks and SubnetPreparer; updated test signatures |
| src/containerapp/azext_containerapp/containerapp_sessionpool_decorator.py | Refactored set_up_dynamic_configuration to build a lifecycleConfiguration object |
| src/containerapp/azext_containerapp/_clients.py | Switched SessionPoolPreviewClient.api_version to "2025-02-02-preview" |
Comments suppressed due to low confidence (2)
src/containerapp/azext_containerapp/containerapp_sessionpool_decorator.py:484
- There are two methods named
set_up_dynamic_configurationin this class; the second definition overrides the first, likely dropping needed config. Rename or consolidate them to preserve both behaviors.
def set_up_dynamic_configuration(self):
src/containerapp/azext_containerapp/tests/latest/test_containerapp_sessionpool.py:142
- Duplicate @ResourceGroupPreparer decorator on
test_containerapp_sessionpool_registry_updatewill cause the test signature to receiveresource_grouptwice and break. Remove the redundant decorator.
@ResourceGroupPreparer()
|
Hi @yitaopan
|
This 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? (pip install wheel==0.30.0required)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.