diff --git a/plugins/outputs/azure_data_explorer/azure_data_explorer.go b/plugins/outputs/azure_data_explorer/azure_data_explorer.go index c89e56f9ca6e8..53a6154b8a4de 100644 --- a/plugins/outputs/azure_data_explorer/azure_data_explorer.go +++ b/plugins/outputs/azure_data_explorer/azure_data_explorer.go @@ -38,6 +38,7 @@ type AzureDataExplorer struct { IngestionType string `toml:"ingestion_type"` serializer serializers.Serializer kustoClient *kusto.Client + AppName string metricIngestors map[string]ingest.Ingestor } @@ -60,7 +61,7 @@ func (*AzureDataExplorer) SampleConfig() string { func (adx *AzureDataExplorer) Connect() error { conn := kusto.NewConnectionStringBuilder(adx.Endpoint).WithDefaultAzureCredential() // Since init is called before connect, we can set the connector details here including the type. This will be used for telemetry and tracing. - conn.SetConnectorDetails("Telegraf", internal.ProductToken(), "", "", false, "") + conn.SetConnectorDetails("Telegraf", internal.ProductToken(), adx.AppName, "", false, "") client, err := kusto.New(conn) if err != nil { return err @@ -250,6 +251,7 @@ func init() { outputs.Add("azure_data_explorer", func() telegraf.Output { return &AzureDataExplorer{ Timeout: config.Duration(20 * time.Second), + AppName: "Kusto.Telegraf", CreateTables: true, } })