-
Notifications
You must be signed in to change notification settings - Fork 366
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
INDY-1836: add test of req drop when replica does not order. #1042
INDY-1836: add test of req drop when replica does not order. #1042
Conversation
Also added a new counter unordered_by_replicas_num for req_state to check how many replicas have not yet ordered particular request. Signed-off-by: Sergey Shilov <sergey.shilov@dsr-company.com>
Can one of the admins verify this patch? |
@@ -81,6 +82,15 @@ def forwarded(self, req: Request) -> bool: | |||
""" | |||
return self[req.key].forwarded | |||
|
|||
def ordered_by_replica(self, request_key): |
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 think this also needs to be called in the following cases:
_clear_request_for_txn
clear_requests_and_fix_last_ordered
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.
Done.
@@ -81,6 +82,15 @@ def forwarded(self, req: Request) -> bool: | |||
""" | |||
return self[req.key].forwarded | |||
|
|||
def ordered_by_replica(self, request_key): |
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.
Please add/extend tests for this new method
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.
Done.
@@ -81,6 +82,15 @@ def forwarded(self, req: Request) -> bool: | |||
""" | |||
return self[req.key].forwarded | |||
|
|||
def ordered_by_replica(self, request_key): |
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.
Should we call this mark_as_ordered
to be aligned with mark_as_executed
and mark_as_forwarded
?
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 is a manipulation with a counter, so such renaming is not fully correct semantically.
Signed-off-by: Sergey Shilov <sergey.shilov@dsr-company.com>
Also added a new counter unordered_by_replicas_num for req_state
to check how many replicas have not yet ordered particular
request.
Signed-off-by: Sergey Shilov sergey.shilov@dsr-company.com