-
Notifications
You must be signed in to change notification settings - Fork 988
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
Avoid buffer copies in RedisStateMachine
#2174
Conversation
Thanks a lot. Care to run the JMH benchmark |
After
Before
Summary: As the payload size in this benchmark is too small, it may not reflect the reality in production environment. This change will reduce memory pressure so it will also help GC and have bigger impact to the application. |
RedisStateMachine
Thank you for your contribution. That's merged and polished now. |
Hi @mp911de what's the expected date to release this change? This offers great performance improvement and we need them very much. |
Make sure that:
see also #2173
Here are some performance results
db.PIPELINE GET.requests - 10000
db.PIPELINE GET.size - 128
db.clients - 1
db.loop - 5
Loaded keys - 1918458
Connections Formed
PIPELINE GET Performance
Total Req - 1280000
P50 (ms) - 2.35
Avg (ms) - 2.6
P90 (ms) - 3.28
P95 (ms) - 3.81
P99 (ms) - 7.24
OPS - 49167
Time Taken (s) for loop 0 is - 26.95
PIPELINE GET Performance
Total Req - 1280000
P50 (ms) - 2.3
Avg (ms) - 2.84
P90 (ms) - 3.12
P95 (ms) - 3.56
P99 (ms) - 6.65
OPS - 45027
Time Taken (s) for loop 1 is - 29.26
PIPELINE GET Performance
Total Req - 1280000
P50 (ms) - 2.33
Avg (ms) - 2.52
P90 (ms) - 3.16
P95 (ms) - 3.55
P99 (ms) - 6.01
OPS - 50826
Time Taken (s) for loop 2 is - 25.97
PIPELINE GET Performance
Total Req - 1280000
P50 (ms) - 2.32
Avg (ms) - 2.49
P90 (ms) - 3.13
P95 (ms) - 3.47
P99 (ms) - 5.8
OPS - 51426
Time Taken (s) for loop 3 is - 25.65
PIPELINE GET Performance
Total Req - 1280000
P50 (ms) - 2.34
Avg (ms) - 2.54
P90 (ms) - 3.18
P95 (ms) - 3.65
P99 (ms) - 6.55
OPS - 50337
Time Taken (s) for loop 4 is - 26.2
db.PIPELINE GET.requests - 10000
db.PIPELINE GET.size - 128
db.clients - 1
db.loop - 5
Loaded keys - 1918458
Connections Formed
PIPELINE GET Performance
Total Req - 1280000
P50 (ms) - 1.81
Avg (ms) - 2.08
P90 (ms) - 2.55
P95 (ms) - 3.02
P99 (ms) - 6.02
OPS - 61661
Time Taken (s) for loop 0 is - 21.69
PIPELINE GET Performance
Total Req - 1280000
P50 (ms) - 1.76
Avg (ms) - 1.93
P90 (ms) - 2.24
P95 (ms) - 2.56
P99 (ms) - 4.48
OPS - 66164
Time Taken (s) for loop 1 is - 20.18
PIPELINE GET Performance
Total Req - 1280000
P50 (ms) - 1.77
Avg (ms) - 1.96
P90 (ms) - 2.28
P95 (ms) - 2.69
P99 (ms) - 5.2
OPS - 65170
Time Taken (s) for loop 2 is - 20.44
PIPELINE GET Performance
Total Req - 1280000
P50 (ms) - 1.75
Avg (ms) - 1.93
P90 (ms) - 2.22
P95 (ms) - 2.57
P99 (ms) - 5.09
OPS - 66303
Time Taken (s) for loop 3 is - 20.07
PIPELINE GET Performance
Total Req - 1280000
P50 (ms) - 1.77
Avg (ms) - 1.94
P90 (ms) - 2.25
P95 (ms) - 2.61
P99 (ms) - 4.81
OPS - 65856
Time Taken (s) for loop 4 is - 20.19