Skip to content

ServerTelemetryChannel does not respect what is passed via ApplicationInsights.config #1637

@cleberdantas

Description

@cleberdantas
<TelemetryChannel Type="Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.ServerTelemetryChannel, Microsoft.AI.ServerTelemetryChannel">
           <EndpointAddress>http://myendpoint/v2/track</EndpointAddress>
</TelemetryChannel>

Hi,
It seems like when we set via configuration file (ApplicationInsights.config) the EndpointAddress element that this is ignored by ServerTelemetryChannel class.

Bellow we can see that when the Initialize method is called the property is set with the value inside of configuration.EndpointContainer.Ingestion which is not the same source when loaded via configuration file:

this.EndpointAddress = new Uri(configuration.EndpointContainer.Ingestion, "v2/track").AbsoluteUri;

public string EndpointAddress
{
get { return this.TelemetrySerializer.EndpointAddress?.ToString(); }
set { this.TelemetrySerializer.EndpointAddress = new Uri(value); }
}

Is my understanding correct? Is it a problem? Is there a way fix it?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions