Skip to content
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

App Configuration provider: add telemetry schme #38933

Merged

Conversation

ivywei0125
Copy link
Contributor

Description

Telemetry schema

{
    "telemetry": {
        "enabled": true,
        "metadata": {
            "key": "value",
            "key2": "value2"
        }
    }
}

Metadata is represented by a dictionary of string keys and string values. When telemetry is enabled, need to add FeatureFlagId, FeatureFlagReference, and ETag. These 3 properties are agreed upon with Split.io used to trace feature flag.

  • FeatureFlagId – an ID for each feature flag based on the key and label that is then hashed with SHA 256 and encoded to base64 URL.
    b64_url(SHA256(utf8_bytes(“${featureFlag.key}\n${featureFlag.label}”))).Replace('+', '-').Replace('/', '_').TrimEnd('=')
  • FeatureFlagReference – a URL used to trace back from a feature flag to a specific app configuration store it came from.
    ${endpoint}kv/${featureFlag.key}?label=${featureFlag.label}
  • ETag – The ETag returned as part of the configuration setting for a feature flag.

@github-actions github-actions bot added the azure-spring All azure-spring related issues label Feb 25, 2024
@azure-sdk
Copy link
Collaborator

API change check

API changes are not detected in this pull request.

@@ -58,6 +62,10 @@ public class AppConfigurationFeatureManagementPropertySourceTest {

private static final String KEY_FILTER = "/foo/";

private static final String TEST_E_TAG = "4f6dd610dd5e4deebc7fbaef685fb903";

private static final String TEST_ENDPOINT = "https://test.azconfig.io";
Copy link
Member

Choose a reason for hiding this comment

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

NIT: We have a TestConstants class with stuff like this in it.

@ivywei0125 ivywei0125 merged commit 6d51cf7 into Azure:feature/spring-boot-3 Mar 12, 2024
19 checks passed
@ivywei0125 ivywei0125 deleted the yuwe/provider-schema-support branch March 12, 2024 10:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
azure-spring All azure-spring related issues
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants