-
Notifications
You must be signed in to change notification settings - Fork 439
Open
Description
Hi, I want to implement a rocketmq scaler in KEDA, which is intended to get the Lag by calculating the offset in the mq, but I don't find any exported API in the SDK for getting maxOffset, then I find this issue #1167 , and I found this API meet our need:
consumer/consumer.go
1000:func (dc *defaultConsumer) queryMaxOffset(mq *primitive.MessageQueue) (int64, error) {
1001- brokerAddr := dc.client.GetNameSrv().FindBrokerAddrByName(mq.BrokerName)
1002- if brokerAddr == "" {
1003- dc.client.GetNameSrv().UpdateTopicRouteInfo(mq.Topic)
1004- brokerAddr = dc.client.GetNameSrv().FindBrokerAddrByName(mq.BrokerName)
1005- }and I want to know is it ok to add API for getting maxOffset.
Metadata
Metadata
Assignees
Labels
No labels