forgetting a trailing slash for cloudant dbUrl crashes with hard to decipher error #542
Open
Description
Currently, if you use a Cloudant backend along with a dbUrl
config that is missing a /
at the end, you'll end up with an error like this:
Error: getaddrinfo ENOTFOUND c38aeb6d-2e18-40ca-b7e9-404da06abd39-bluemix.cloudant.comhoodie-config c38aeb6d-2e18-40ca-b7e9-404da06abd39-bluemix.cloudant.comhoodie-config:443
The fix is ensuring the URL has a /
appended, and this appears to be caused by this "hack". In my case, it ended up making the db hostname <account>.cloudant.comhack
, which triggers the above DNS lookup error.
Possible solutions here include:
- detect a URL without a trailing
/
and throw an error - handle more gracefully by appending
/
when missing
Metadata
Assignees
Labels
No labels