Skip to content

opt-in error record config #416

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

Merged
merged 2 commits into from
Apr 26, 2024
Merged

Conversation

VeryEarly
Copy link
Contributor

@VeryEarly VeryEarly commented Apr 11, 2024

This pull request primarily focuses on the transition from using DisableErrorRecordsPersistence to EnableErrorRecordsPersistence in the ConfigKeysForCommon class and the ShouldRecordDebugMessages method. The changes are made to improve the code's readability and to make the feature opt-in rather than opt-out.

Key changes include:

  • src/Authentication.Abstractions/Models/ConfigKeysForCommon.cs: Removed the DisableErrorRecordsPersistence constant from the ConfigKeysForCommon class. The EnableErrorRecordsPersistence constant is now being used instead. This change is made to switch from an opt-out to an opt-in system for error record persistence.

  • src/Common/AzurePSCmdlet.cs: Modified the ShouldRecordDebugMessages method to use the EnableErrorRecordsPersistence constant instead of the DisableErrorRecordsPersistence constant. This change aligns with the modification in ConfigKeysForCommon and ensures consistency across the codebase.

@VeryEarly VeryEarly marked this pull request as draft April 11, 2024 07:26
@VeryEarly VeryEarly self-assigned this Apr 11, 2024
@VeryEarly VeryEarly marked this pull request as ready for review April 25, 2024 02:22
Copy link
Contributor

@BethanyZhou BethanyZhou left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Member

@isra-fel isra-fel left a comment

Choose a reason for hiding this comment

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

This won't be a breaking change since the config is only read in Az.Accounts. But we need to be coutious next time when we deprecate configs.

@VeryEarly VeryEarly merged commit 2fc315f into Azure:main Apr 26, 2024
2 checks passed
@VeryEarly VeryEarly deleted the yabo/errorrecord-optin branch April 26, 2024 06:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants