Closed msdotnetclr closed 11 months ago
@msdotnetclr Thanks for your feedback! We will investigate and update as appropriate.
@msdotnetclr I've delegated this to @mssaperla, a content author, to review and share their valuable insights.
Thanks for providing feedback that helps improve our documentation. We've created an internal work item (DOC-11128) to address your feedback. The timeline for resolution varies based on resourcing.
The example code results in Event Hubs authentication failure if access key name and the secret name are different.
The following line retrieves the name of the access key (shared access policy):
Then the example proceeds to get the actual access key value from the secret scope:
Then EH_CONN_SHARED_ACCESS_KEY_NAME is referenced in the connection string below:
This only works when the name of the secret is exactly the same as the name of the Shared Access Policy, but if the two names are different, authentication will fail due to an invalid SharedAccessKeyName value in the connection string.
A new spark conf option like "iot.ingestion.eh.accessKeySecretName" is needed to store the name of the secret, keep "iot.ingestion.eh.accessKeyName" to store the actual Shared Access Policy name. Then you can use both to construct the connection string correctly.
I submitted an issue (and a companion PR) for a similar issue in the dlt-meta library maintained by Databricks Labs.
Document Details
⚠ Do not edit this section. It is required for learn.microsoft.com ➟ GitHub issue linking.