Open mfreeman451 opened 1 month ago
@mfreeman451 This is not a retry connection, but a subscription issue with Kafka where when it is trying to subscribe to the topic, the consumer group ID is not provided, and it throws the error that you mentioned.
I think we should look for a solution where the subscription cannot start until the pubsub is connected and ready.
Describe the bug While attempting to run all of the go tests in this project from my personal machine, which I understand probably doesn't have the proper test environment, I noticed the pubsub tests attempting to make a connection to the pubsub in an endless loop.
I think we should consider implementing some kind of exponential retry/backoff strategy here and consider returning an error.
To Reproduce Steps to reproduce the behavior, if applicable:
The code is
go test -v ./...
{"level":"ERROR","time":"2024-10-18T15:18:45.425787-05:00","message":"error in subscription for topic products: consumer group id not provided","gofrVersion":"dev"} {"level":"ERROR","time":"2024-10-18T15:18:45.425809-05:00","message":"cannot subscribe as consumer_id is not provided in configs","gofrVersion":"dev"} {"level":"ERROR","time":"2024-10-18T15:18:45.425798-05:00","message":"error in subscription for topic order-logs: consumer group id not provided","gofrVersion":"dev"} {"level":"ERROR","time":"2024-10-18T15:18:45.42582-05:00","message":"cannot subscribe as consumer_id is not provided in configs","gofrVersion":"dev"} {"level":"ERROR","time":"2024-10-18T15:18:45.425826-05:00","message":"error while reading from topic order-logs, err: consumer group id not provided","gofrVersion":"dev"} {"level":"ERROR","time":"2024-10-18T15:18:45.42583-05:00","message":"error in subscription for topic order-logs: consumer group id not provided","gofrVersion":"dev"} {"level":"ERROR","time":"2024-10-18T15:18:45.425815-05:00","message":"error while reading from topic products, err: consumer group id not provided","gofrVersion":"dev"}