azure-event-hubs-go
azure-event-hubs-go copied to clipboard
Failing to specify an 'entityPath' in a connection string results in an unintuitive error
If you specify a connection string that does not have an EntityPath=<event hub name key/value you get this error:
*Error{Condition: amqp:internal-error, Description: The service was unable to process the request; please retry the operation.
Which doesn't really tell you what you've done wrong. We can do a cursory check on the string to make sure that EntityPath is specified to avoid surfacing this error.
In other track 2 libraries we actually allow a second form where you can specify a broker-level connection string and then the eventhub is a separate parameter. This could be a nicer way to fix this.
(referenced in this StackOverflow question: https://stackoverflow.com/questions/68331725/eventhub-golang-client-error-amqpinternal-error/68354113#68354113)
Definitely beneficial to fix that in the client, but would be more impactful to fix that in the service.