pulsar icon indicating copy to clipboard operation
pulsar copied to clipboard

[improve][broker] Use the Producer stats instead of msgOut in geo

Open nodece opened this issue 2 years ago • 0 comments

Motivation

In geo, the msgOut is inaccurate:

  1. When Entry is batch message, the org.apache.pulsar.common.stats.Rate#countAdder and org.apache.pulsar.common.stats.Rate#totalCountAdder increment only once.
  2. When the network fails, the org.apache.pulsar.common.stats.Rate#recordEvent(long) shouldn't be called, due to the message cannot be sent to the remote cluster.

Modifications

Use the Producer stats instead of msgOut in geo.

Verifying this change

Just to verify the msgRateOut and msgThroughputOut doesn't equal to 0.

Documentation

  • [ ] doc
  • [ ] doc-required
  • [x] doc-not-needed
  • [ ] doc-complete

Matching PR in forked repository

PR in forked repository:

nodece avatar Dec 18 '23 17:12 nodece