Open jage opened 5 years ago
Sure, I agree.
I prefer _SERVERS
, as RABBITMQ_URL
exists, which is the full connection string.
We should probably include the port number in the list of servers, and use make use of :addresses
in Bunny. (We use :hosts
now.)
I think this commit was our first used of RABBITMQ_NN_HOST
, 17 Jun 2015. Bunny added :addresses
Jul 30, 2015. :)
We should probably include the port number in the list of servers, and use make use of
:addresses
in Bunny. (We use:hosts
now.)
I need this for https://github.com/twingly/imse/pull/56. GitHub Actions assign ports randomly to services: https://github.com/actions/example-services/blob/dfd84e0637dda63c0359a07a7161fbfd2a6da738/.github/workflows/postgres-service.yml#L52-L54
Oh, we have this: https://github.com/twingly/twingly-amqp#customize-options. I will try it.
Seems to work
Currently we're using the following scheme for multiple servers, a new variable per server:
RABBITMQ_01_HOST
RABBITMQ_02_HOST
But for a lot of other servers we use:
MEMCACHIER_SERVERS
KESTREL_SERVERS
So the question is, what do we prefer?
I'm leaning towards using
_SERVERS
or_URLS
with a comma-separated list, that seems to be a general consensus among other gems.I think using fewer variables could be positive during maintenance, as in it's easier to change a variable than make sure it's removed (Consul KV, Heroku config etc).