microsoft / ApplicationInsights-dotnet

ApplicationInsights-dotnet
MIT License
565 stars 287 forks source link

Log4Net Appender cannot connect using ConnectionString #2709

Open dirthsj opened 1 year ago

dirthsj commented 1 year ago

Is your feature request related to a problem? I have an older .NET Framework application I am adding application insights to. However, when creating an ApplicationInsightsAppender instance I am only able to specify InstrumentationKey.

Describe the solution you'd like. I should be able to provide a ConnectionString instead of an InstrumentationKey

Describe alternatives you've considered. Using InstrumentationKey ingest until this is fixed.

Additional context. N/A

github-actions[bot] commented 1 year ago

This issue is stale because it has been open 300 days with no activity. Remove stale label or this will be closed in 7 days. Commenting will instruct the bot to automatically remove the label.

dirthsj commented 1 year ago

This issue is still present in the current release (2.21.0)

SierraNL commented 1 year ago

Microsoft is moving away from the instrumentation keys: https://learn.microsoft.com/en-us/azure/azure-monitor/app/migrate-from-instrumentation-keys-to-connection-strings

Besides that, you want to be able to use the complete TelemetryConfiguration object, if you need to use Managed Identities for instance.