From 0e55eedd7eb29b407c8dbaef2afd725307794d75 Mon Sep 17 00:00:00 2001 From: Victor Marinsky Date: Thu, 20 May 2021 16:37:01 -0400 Subject: [PATCH] Improve eventhub_consumer input documentation (#8731) --- plugins/inputs/eventhub_consumer/README.md | 11 +++++++++-- plugins/inputs/eventhub_consumer/eventhub_consumer.go | 11 +++++++++-- 2 files changed, 18 insertions(+), 4 deletions(-) diff --git a/plugins/inputs/eventhub_consumer/README.md b/plugins/inputs/eventhub_consumer/README.md index 06c43cf31..c0533b513 100644 --- a/plugins/inputs/eventhub_consumer/README.md +++ b/plugins/inputs/eventhub_consumer/README.md @@ -18,8 +18,6 @@ The main focus for development of this plugin is Azure IoT hub: ## This requires one of the following sets of environment variables to be set: ## ## 1) Expected Environment Variables: - ## - "EVENTHUB_NAMESPACE" - ## - "EVENTHUB_NAME" ## - "EVENTHUB_CONNECTION_STRING" ## ## 2) Expected Environment Variables: @@ -28,8 +26,17 @@ The main focus for development of this plugin is Azure IoT hub: ## - "EVENTHUB_KEY_NAME" ## - "EVENTHUB_KEY_VALUE" + ## 3) Expected Environment Variables: + ## - "EVENTHUB_NAMESPACE" + ## - "EVENTHUB_NAME" + ## - "AZURE_TENANT_ID" + ## - "AZURE_CLIENT_ID" + ## - "AZURE_CLIENT_SECRET" + ## Uncommenting the option below will create an Event Hub client based solely on the connection string. ## This can either be the associated environment variable or hard coded directly. + ## If this option is uncommented, environment variables will be ignored. + ## Connection string should contain EventHubName (EntityPath) # connection_string = "" ## Set persistence directory to a valid folder to use a file persister instead of an in-memory persister diff --git a/plugins/inputs/eventhub_consumer/eventhub_consumer.go b/plugins/inputs/eventhub_consumer/eventhub_consumer.go index da66872da..114a63350 100644 --- a/plugins/inputs/eventhub_consumer/eventhub_consumer.go +++ b/plugins/inputs/eventhub_consumer/eventhub_consumer.go @@ -69,8 +69,6 @@ func (*EventHub) SampleConfig() string { ## This requires one of the following sets of environment variables to be set: ## ## 1) Expected Environment Variables: - ## - "EVENTHUB_NAMESPACE" - ## - "EVENTHUB_NAME" ## - "EVENTHUB_CONNECTION_STRING" ## ## 2) Expected Environment Variables: @@ -79,8 +77,17 @@ func (*EventHub) SampleConfig() string { ## - "EVENTHUB_KEY_NAME" ## - "EVENTHUB_KEY_VALUE" + ## 3) Expected Environment Variables: + ## - "EVENTHUB_NAMESPACE" + ## - "EVENTHUB_NAME" + ## - "AZURE_TENANT_ID" + ## - "AZURE_CLIENT_ID" + ## - "AZURE_CLIENT_SECRET" + ## Uncommenting the option below will create an Event Hub client based solely on the connection string. ## This can either be the associated environment variable or hard coded directly. + ## If this option is uncommented, environment variables will be ignored. + ## Connection string should contain EventHubName (EntityPath) # connection_string = "" ## Set persistence directory to a valid folder to use a file persister instead of an in-memory persister