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

Flags for envelope #844

Closed
SergeyKanzhelev opened this issue Jun 21, 2018 · 0 comments
Closed

Flags for envelope #844

SergeyKanzhelev opened this issue Jun 21, 2018 · 0 comments

Comments

@SergeyKanzhelev
Copy link
Contributor

C# API for https://github.com/Microsoft/ApplicationInsights-Home/issues/232

New field flags on envelope will be used to set transport level characteristics for events. First one will be an ability to instruct endpoint to drop IP address.

We are working on feature to enable collection of full IP addresses. There will be a setting to opt-out from this behavior for entire Application Insights resource. Flags will enable to hide IP address for a single event. This way one can configure per-tenant or per-feature IP address collection to satisfy privacy requirements for a given app better.

Proposed API

Set flags for individual item. Typically for events that should not contain any PII. Typical example will be to set it based on user setting. If user accepted collecting her IP address - this flag is not set. Otherwise - set the flag.

EventTelemetry t = new EventTelemetry("Secret message") { Flags = TelemetryContext.FlagDropIdentifiers };
client.TrackEvent(t);

Set flags for client. Typical use is to set flags on all events produced by specific client.

var client = new TelemetryClient();
client.Context.Flags |= TelemetryContext.FlagDropIdentifiers;
client.TrackEvent("secret message");
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants