-
Notifications
You must be signed in to change notification settings - Fork 3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[AppService] az functionapp create
: Use app insights connection string instead of instrumentation key
#27803
Conversation
️✔️AzureCLI-FullTest
|
️✔️AzureCLI-BreakingChangeTest
|
AppService |
@kamperiadis May I ask will the behavioral changes here cause breaking changes to the automation scripts of customers? |
@kaibocai Could you please help review the Function App related PR? |
@zhoxing-ms This is not a breaking change as using either app setting would work. These changes are made for this effort to migrate from the instrumentation key to the connection string. |
Okay, so this is just an internal logic modification and won't have any impact on the customers' script, right? |
Could you please resolve these CI issues? |
That is correct. |
…ing instead of instrumentation key (Azure#27803)
class FunctionAppWithAppInsightsConnString(ScenarioTest): | ||
def __init__(self, method_name, config_file=None, recording_name=None, recording_processors=None, replay_processors=None, recording_patches=None, replay_patches=None, random_config_dir=False): | ||
super().__init__(method_name, config_file, recording_name, recording_processors, replay_processors, recording_patches, replay_patches, random_config_dir) | ||
self.cmd('extension add -n application-insights') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
extension add -n
should not be here. It causes CI failure:
==================================== ERRORS ====================================
__________ ERROR collecting tests/latest/test_functionapp_commands.py __________
/usr/lib64/az/lib/python3.9/site-packages/azure/cli/command_modules/appservice/tests/latest/test_functionapp_commands.py:990: in __init__
self.cmd('extension add -n application-insights')
/usr/lib64/az/lib/python3.9/site-packages/azure/cli/testsdk/base.py:176: in cmd
return execute(self.cli_ctx, command, expect_failure=expect_failure).assert_with_checks(checks)
/usr/lib64/az/lib/python3.9/site-packages/azure/cli/testsdk/base.py:260: in __init__
raise AssertionError('The command failed. Exit code: {}'.format(self.exit_code))
E AssertionError: The command failed. Exit code: 1
__________ ERROR collecting tests/latest/test_functionapp_commands.py __________
/usr/lib64/az/lib/python3.9/site-packages/azure/cli/command_modules/appservice/tests/latest/test_functionapp_commands.py:1579: in __init__
self.cmd('extension add -n application-insights')
/usr/lib64/az/lib/python3.9/site-packages/azure/cli/testsdk/base.py:176: in cmd
return execute(self.cli_ctx, command, expect_failure=expect_failure).assert_with_checks(checks)
/usr/lib64/az/lib/python3.9/site-packages/azure/cli/testsdk/base.py:260: in __init__
raise AssertionError('The command failed. Exit code: {}'.format(self.exit_code))
E AssertionError: The command failed. Exit code: 1
__________ ERROR collecting tests/latest/test_functionapp_commands.py __________
/usr/lib64/az/lib/python3.9/site-packages/azure/cli/command_modules/appservice/tests/latest/test_functionapp_commands.py:1707: in __init__
self.cmd('extension add -n application-insights')
/usr/lib64/az/lib/python3.9/site-packages/azure/cli/testsdk/base.py:176: in cmd
return execute(self.cli_ctx, command, expect_failure=expect_failure).assert_with_checks(checks)
/usr/lib64/az/lib/python3.9/site-packages/azure/cli/testsdk/base.py:260: in __init__
raise AssertionError('The command failed. Exit code: {}'.format(self.exit_code))
E AssertionError: The command failed. Exit code: 1
---------- generated xml file: /azure_cli_test_result/appservice.xml -----------
=========================== short test summary info ============================
ERROR tests/latest/test_functionapp_commands.py::FunctionAppManagedEnvironment
ERROR tests/latest/test_functionapp_commands.py::FunctionAppWithAppInsightsConnString
ERROR tests/latest/test_functionapp_commands.py::FunctionappAppInsightsWorkspace
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@kamperiadis Could you please take a look at this issue?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@zhoxing-ms I've created this PR to solve this issue: #30636
Related command
az functionapp create
Description
Resolves #27607
Testing Guide
Create function app and check that app setting added is
APPLICATIONINSIGHTS_CONNECTION_STRING
instead ofAPPINSIGHTS_INSTRUMENTATION_KEY
This checklist is used to make sure that common guidelines for a pull request are followed.
The PR title and description has followed the guideline in Submitting Pull Requests.
I adhere to the Command Guidelines.
I adhere to the Error Handling Guidelines.