Adds support for the alternate postgres:// prefix in URLs. It's maybe
not the cleanest approach, but works. Hoping I can either get some
pointers on a more appropriate patch, or that we could use this in the
interim to unblock this use-case.
Signed-off-by: Jack Wink <57678801+mothershipper@users.noreply.github.com>
- Moves new dsn type to config.DSN. This will prevent circular dependencies.
- Change DSN.query to be url.Values. This allows the multi-target functionality to merge values without re-parsing the query string
- Change NewProbeCollector to use the new config.DSN type
- Add DSN.GetConnectionString to return a string formatted for the sql driver to use during connection
Signed-off-by: Joe Adams <github@joeadams.io>
The config module supports adding configuration to the exporter via a config file. This supports adding authentication details in a config file so that /probe requests can specify authentication for endpoints
Signed-off-by: Joe Adams <github@joeadams.io>