-
Notifications
You must be signed in to change notification settings - Fork 145
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow host:port to accept connection url format #16
Comments
This could be an interesting proposal. Anyway, I would like to think about it a little more. |
@ufoscout yes, trying to follow 12-factor application principles, I have configuration parameters, one per backing service, e.g.:
Keeping all configuration parameters for single backing service in one connection string seems practical as it can be handled as one item (one can argue, secrets shall be separated, but I would say the whole connection string could be considered a secret) And my need is to test (on TCP level) availability of those backing services using just these urls. This I do before starting actual dependent process/application. To keep implementation simple, I would require that the url must:
|
Currently the specification of host and port must be in form "{host}:{port}".
In many cases the url to check is already present in the system configuration in form of connection parameter, e.g.:
postgres://username:password@hostname:5432/database
.However, current implementation does not seem to accept such host and port specification.
Proposed solution:
:
/
or@
, take the last element/
, take the first element. Check that it includes only digits.There are very likely better options, I just wanted to express that to me it seems very acceptable to require explicit hostname and port presence to keep the implementation small and simple.
The text was updated successfully, but these errors were encountered: