Closed Zerpet closed 1 year ago
Requires some manual QA before merging.
@Gsantomaggio @lukebakken could we introduce this in a patch release? Arguably it doesn't add new functionality, but a slight change in behaviour.
Patch coverage: 57.74%
and project coverage change: -0.20%
:warning:
Comparison is base (
c9f7563
) 92.86% compared to head (3624282
) 92.66%.:exclamation: Current head 3624282 differs from pull request most recent head 049343f. Consider uploading reports for the commit 049343f to get more accurate results
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
Looks good to me, should we do #305 (comment) ?
I don't think we should mark the test to be skipped. In my commit, the test is marked "maybe skip", and it will always run, at least to the point where the SkipException
is thrown.
Allow me to do manual QA for a couple hours before we consider merging.
Rebased branched on top of main
. We should be good to merge after CI passes.
Fixes #296
It is common to have a local instance of RabbitMQ running locally, either via a local rabbit (e.g. installed from source), or inside a container (e.g. Docker or local Kubernetes). In both cases, our client may not work without providing an address resolver, or without changing the advertised host/port in rabbit via an env variable. Specifically, our clients won't work if the client can't resolve the hostname of the local machine.
For exampe, a laptop may have a hostname mylaptop.some-company.com. Rabbit won't be impacted as long as it works in a single-node configuration. However, the client smart features to locate the stream leaders and replicas will get "confused" because it can't resolve the hostname.
This commit changes the smart layer, so that it won't try to locate the stream replicas if the client is connected to localhost. Instead, it will force the producer/consumer connections to be localhost, and it will assume that stream replicas/leader are in localhost. This is true for single-node rabbits in local development environments. The smart feature to locate leader/replicas remains unchanged for non-local connections.