-
Notifications
You must be signed in to change notification settings - Fork 3.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[fix] Key_Shared mode consumption latency when low traffic #23340
Conversation
@poorbarcode Please add the following content to your PR description and select a checkbox:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The previous solution was burning CPU in a tight loop. Instead of disabling this, the values can be made 100x smaller.
pulsar-broker-common/src/main/java/org/apache/pulsar/broker/ServiceConfiguration.java
Outdated
Show resolved
Hide resolved
pulsar-broker-common/src/main/java/org/apache/pulsar/broker/ServiceConfiguration.java
Outdated
Show resolved
Hide resolved
…nning loops are avoided
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM with values 1ms initial / 10ms max
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #23340 +/- ##
============================================
+ Coverage 73.57% 74.52% +0.95%
- Complexity 32624 34431 +1807
============================================
Files 1877 1934 +57
Lines 139502 144981 +5479
Branches 15299 15839 +540
============================================
+ Hits 102638 108049 +5411
+ Misses 28908 28658 -250
- Partials 7956 8274 +318
Flags with carried forward coverage won't be shown. Click here to find out more.
|
Co-authored-by: Lari Hotari <lhotari@apache.org> (cherry picked from commit 4ce0c75)
Co-authored-by: Lari Hotari <lhotari@apache.org> (cherry picked from commit 4ce0c75)
Motivation
Without #23226 and #23284, the consumption latency is low, but the consumption latency increases to
1s
when the traffic is low.Consumption latency after an upgrade(3 topics).
histogram_quantile(0.98, sum-by (le, topic) (rate (Message_duration_eventstate_ inbound_latencymin_bucket {kubernetes_namespace-"$(env)"} [$__rate_interval])))
Root cause
Modifications
Change the feature's introduced by #23226 default values to 1ms initial / 10ms max.
Documentation
doc
doc-required
doc-not-needed
doc-complete
Matching PR in forked repository
PR in forked repository: x