Redis Clusters need a different client, and is able to configure multiple addresses.
Although the previous client was working for some cluster scenarios we got a user reporting that it did not work for them:
{"level":"error","ts":1677378306.6000555,"logger":"ingest","caller":"ingest/ingest.go:125","msg":"Could not produce CloudEvent to broker","error":"could not produce CloudEvent to backend: MOVED 7265 10.0.10.255:6379","stacktrace":"github.com/triggermesh/brokers/pkg/ingest.(*Instance).cloudEventsHandler\n\t/workspace/pkg/ingest/ingest.go:125\nreflect.Value.call\n\t/usr/local/go/src/reflect/value.go:556\nreflect.Value.Call\n\t/usr/local/go/src/reflect/value.go:339\ngithub.com/cloudevents/sdk-go/v2/client.(*receiverFn).invoke\n\t/go/pkg/mod/github.com/cloudevents/sdk-go/v2@v2.13.0/client/receiver.go:91\ngithub.com/cloudevents/sdk-go/v2/client.(*receiveInvoker).Invoke.func2\n\t/go/pkg/mod/github.com/cloudevents/sdk-go/v2@v2.13.0/client/invoker.go:85\ngithub.com/cloudevents/sdk-go/v2/client.(*receiveInvoker).Invoke\n\t/go/pkg/mod/github.com/cloudevents/sdk-go/v2@v2.13.0/client/invoker.go:88\ngithub.com/cloudevents/sdk-go/v2/client.(*ceClient).StartReceiver.func2.1\n\t/go/pkg/mod/github.com/cloudevents/sdk-go/v2@v2.13.0/client/client.go:253\ngithub.com/cloudevents/sdk-go/v2/client.(*ceClient).StartReceiver.func2.2\n\t/go/pkg/mod/github.com/cloudevents/sdk-go/v2@v2.13.0/client/client.go:265"}
This PR adds the new client when a cluster address is used.
Redis Clusters need a different client, and is able to configure multiple addresses.
Although the previous client was working for some cluster scenarios we got a user reporting that it did not work for them:
This PR adds the new client when a cluster address is used.