-
Notifications
You must be signed in to change notification settings - Fork 312
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
feat(dup): support shell set fail_mode and collector duplication ops #520
Conversation
This comment has been minimized.
This comment has been minimized.
Co-Authored-By: Yingchun Lai <405403881@qq.com>
|
||
if (rpc_code == dsn::apps::RPC_RRDB_RRDB_DUPLICATE) { | ||
// ignore if it is a DUPLICATE | ||
continue; |
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.
I just can't understand your updates in this function, could you please explain to me?
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.
Sure. I left a comment here. It was a bug. DUPLICATE can not participate in duplication like other normal writes. Because duplication is designed to be a directed edge flowing from master to slave. Forwarding will unintentionally add edges in this topology.
@@ -87,6 +90,9 @@ class info_collector | |||
::dsn::perf_counter_wrapper check_and_set_qps; | |||
::dsn::perf_counter_wrapper check_and_mutate_qps; | |||
::dsn::perf_counter_wrapper scan_qps; | |||
::dsn::perf_counter_wrapper duplicate_qps; |
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.
Rename to dup_qps
? so the three metrics have the same pefix to identify.
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.
It's not trivial because on replica side the perf-counter called replica*app.pegasus*duplicate_qps@<pid>
. Therefore on the collector side, it must follow the same name.
What problem does this PR solve?
set_dup_fail_mode
. See the following shell example for details.New perf-counters
collector*app.pegasus*app.stat.duplicate_qps#<app_name>
collector*app.pegasus*app.stat.dup_shipped_ops#<app_name>
collector*app.pegasus*app.stat.dup_failed_shipping_ops#<app_name>
Check List
Tests
"onebox2" is the remote cluster to duplicate. To test whether the perf-counters work, we use pegasus-YCSB to load writes to the local onebox.
On the receiver side (onebox2), the data duplicating it handles displayed like this:
Related changes