You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Recently the nats-serveradded support for a more human-readable server name.
It would be nice to add support for it in the nats-operator.
As it stands now, the server identifier (e.g., NAICD2C2WZ62VH7QELNX6LLI6BBY34SL3MVD3FCJVMJCSOOBOZ7YZ7N3) appears in monitoring stacks like Prometheus. While unique, it is not friendly.
A possible implementation might chose an operator DSL attribute to control the name prefix of the server. For example, <prefix>-<server-number> ==> mycluster-1 for the first server. The prefix could default to the nats-cluster metadata name. Note that using just the nats-cluster metadata name might result in naming collisions when consolidating monitoring for multiple clusters, so allowing an explicit prefix would be "nice".
The nats-operator currently uses a single configuration secret that it maps to each server pod. I believe this makes the solution non-trivial.
The text was updated successfully, but these errors were encountered:
The problem with the shared config is that since JSON is used to marshal the config, then cannot use an environment variable to set the server name since it will be using quotes. The options are then:
Improve the config marshalling of the nats operator so that can have fields that are environment variables which are unquoted
Make nats-servers be able to set a name via the command line instead of via the config where $POD_NAME would be used
Change nats-server to use some environment variable as the server_name instead of config
Recently the
nats-server
added support for a more human-readable server name.It would be nice to add support for it in the
nats-operator
.As it stands now, the server identifier (e.g.,
NAICD2C2WZ62VH7QELNX6LLI6BBY34SL3MVD3FCJVMJCSOOBOZ7YZ7N3
) appears in monitoring stacks like Prometheus. While unique, it is not friendly.A possible implementation might chose an operator DSL attribute to control the name prefix of the server. For example,
<prefix>-<server-number>
==>mycluster-1
for the first server. The prefix could default to thenats-cluster
metadata name. Note that using just thenats-cluster
metadata name might result in naming collisions when consolidating monitoring for multiple clusters, so allowing an explicit prefix would be "nice".The
nats-operator
currently uses a single configuration secret that it maps to each server pod. I believe this makes the solution non-trivial.The text was updated successfully, but these errors were encountered: