You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@kudu.apache.org by "Andrew Wong (Code Review)" <ge...@cloudera.org> on 2020/12/11 18:55:39 UTC
[kudu-CR] KUDU-2612: allow participant ops to detect idempotent calls
Andrew Wong has uploaded this change for review. ( http://gerrit.cloudera.org:8080/16860
Change subject: KUDU-2612: allow participant ops to detect idempotent calls
......................................................................
KUDU-2612: allow participant ops to detect idempotent calls
Previously, we could return TXN_ILLEGAL_STATE error if we tried to start
a transaction but one was already present, we tried to begin committing
but it the commit was already in progress, etc. However, it seems like
it will be more robust behavior to be able to detect such cases, where
the requested mutation is already applied. This patch does this by
sending back a new TXN_OP_ALREADY_APPLIED error code for such calls.
While it would be nice to return an OK response with the participant op,
it seems non-trivial to exit out of an in-flight op with a success.
Change-Id: If82d3d1aad6737dd4f9f234b122b8c15d65a6604
---
M src/kudu/integration-tests/txn_participant-itest.cc
M src/kudu/tablet/ops/participant_op.cc
M src/kudu/tablet/ops/write_op.cc
M src/kudu/tablet/tablet_metadata.cc
M src/kudu/tablet/tablet_metadata.h
M src/kudu/tablet/txn_participant-test.cc
M src/kudu/tablet/txn_participant.cc
M src/kudu/tablet/txn_participant.h
M src/kudu/tserver/tserver.proto
9 files changed, 186 insertions(+), 114 deletions(-)
git pull ssh://gerrit.cloudera.org:29418/kudu refs/changes/60/16860/1
--
To view, visit http://gerrit.cloudera.org:8080/16860
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: If82d3d1aad6737dd4f9f234b122b8c15d65a6604
Gerrit-Change-Number: 16860
Gerrit-PatchSet: 1
Gerrit-Owner: Andrew Wong <aw...@cloudera.com>
[kudu-CR] KUDU-2612: allow participant ops to detect idempotent calls
Posted by "Alexey Serbin (Code Review)" <ge...@cloudera.org>.
Alexey Serbin has posted comments on this change. ( http://gerrit.cloudera.org:8080/16860 )
Change subject: KUDU-2612: allow participant ops to detect idempotent calls
......................................................................
Patch Set 4: Code-Review+2
(2 comments)
http://gerrit.cloudera.org:8080/#/c/16860/4/src/kudu/tablet/txn_participant.h
File src/kudu/tablet/txn_participant.h:
http://gerrit.cloudera.org:8080/#/c/16860/4/src/kudu/tablet/txn_participant.h@46
PS4, Line 46: int8_t
nit: it would be nice to add a comment why this is necessary; is this just to have exact size because this will be persisted as part of metadata?
http://gerrit.cloudera.org:8080/#/c/16860/4/src/kudu/tablet/txn_participant.h@251
PS4, Line 251: expected_metadata_state
nit: maybe, for clarity use
expected_metadata_state != kNone
?
--
To view, visit http://gerrit.cloudera.org:8080/16860
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: If82d3d1aad6737dd4f9f234b122b8c15d65a6604
Gerrit-Change-Number: 16860
Gerrit-PatchSet: 4
Gerrit-Owner: Andrew Wong <aw...@cloudera.com>
Gerrit-Reviewer: Alexey Serbin <as...@cloudera.com>
Gerrit-Reviewer: Andrew Wong <aw...@cloudera.com>
Gerrit-Reviewer: Hao Hao <ha...@cloudera.com>
Gerrit-Reviewer: Kudu Jenkins (120)
Gerrit-Reviewer: Tidy Bot (241)
Gerrit-Comment-Date: Sat, 12 Dec 2020 05:15:53 +0000
Gerrit-HasComments: Yes
[kudu-CR] KUDU-2612: allow participant ops to detect idempotent calls
Posted by "Andrew Wong (Code Review)" <ge...@cloudera.org>.
Andrew Wong has submitted this change and it was merged. ( http://gerrit.cloudera.org:8080/16860 )
Change subject: KUDU-2612: allow participant ops to detect idempotent calls
......................................................................
KUDU-2612: allow participant ops to detect idempotent calls
Previously, we could return TXN_ILLEGAL_STATE error if we tried to start
a transaction but one was already present, we tried to begin committing
but it the commit was already in progress, etc. However, it seems like
it will be more robust behavior to be able to detect such cases, where
the requested mutation is already applied. This patch does this by
sending back a new TXN_OP_ALREADY_APPLIED error code for such calls.
While it would be nice to return an OK response with the participant op,
it seems non-trivial to exit out of an in-flight op with a success.
Change-Id: If82d3d1aad6737dd4f9f234b122b8c15d65a6604
Reviewed-on: http://gerrit.cloudera.org:8080/16860
Reviewed-by: Alexey Serbin <as...@cloudera.com>
Tested-by: Kudu Jenkins
---
M src/kudu/integration-tests/txn_participant-itest.cc
M src/kudu/tablet/ops/participant_op.cc
M src/kudu/tablet/ops/write_op.cc
M src/kudu/tablet/ops/write_op.h
M src/kudu/tablet/tablet_metadata.cc
M src/kudu/tablet/tablet_metadata.h
M src/kudu/tablet/txn_participant-test.cc
M src/kudu/tablet/txn_participant.cc
M src/kudu/tablet/txn_participant.h
M src/kudu/tserver/tserver.proto
10 files changed, 217 insertions(+), 133 deletions(-)
Approvals:
Alexey Serbin: Looks good to me, approved
Kudu Jenkins: Verified
--
To view, visit http://gerrit.cloudera.org:8080/16860
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: If82d3d1aad6737dd4f9f234b122b8c15d65a6604
Gerrit-Change-Number: 16860
Gerrit-PatchSet: 6
Gerrit-Owner: Andrew Wong <aw...@cloudera.com>
Gerrit-Reviewer: Alexey Serbin <as...@cloudera.com>
Gerrit-Reviewer: Andrew Wong <aw...@cloudera.com>
Gerrit-Reviewer: Hao Hao <ha...@cloudera.com>
Gerrit-Reviewer: Kudu Jenkins (120)
Gerrit-Reviewer: Tidy Bot (241)
[kudu-CR] KUDU-2612: allow participant ops to detect idempotent calls
Posted by "Andrew Wong (Code Review)" <ge...@cloudera.org>.
Andrew Wong has posted comments on this change. ( http://gerrit.cloudera.org:8080/16860 )
Change subject: KUDU-2612: allow participant ops to detect idempotent calls
......................................................................
Patch Set 2: Verified+1
Flaky test failure is unrelated
--
To view, visit http://gerrit.cloudera.org:8080/16860
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: If82d3d1aad6737dd4f9f234b122b8c15d65a6604
Gerrit-Change-Number: 16860
Gerrit-PatchSet: 2
Gerrit-Owner: Andrew Wong <aw...@cloudera.com>
Gerrit-Reviewer: Alexey Serbin <as...@cloudera.com>
Gerrit-Reviewer: Andrew Wong <aw...@cloudera.com>
Gerrit-Reviewer: Hao Hao <ha...@cloudera.com>
Gerrit-Reviewer: Kudu Jenkins (120)
Gerrit-Reviewer: Tidy Bot (241)
Gerrit-Comment-Date: Sat, 12 Dec 2020 02:27:31 +0000
Gerrit-HasComments: No
[kudu-CR] KUDU-2612: allow participant ops to detect idempotent calls
Posted by "Andrew Wong (Code Review)" <ge...@cloudera.org>.
Andrew Wong has removed a vote on this change.
Change subject: KUDU-2612: allow participant ops to detect idempotent calls
......................................................................
Removed Verified-1 by Kudu Jenkins (120)
--
To view, visit http://gerrit.cloudera.org:8080/16860
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: deleteVote
Gerrit-Change-Id: If82d3d1aad6737dd4f9f234b122b8c15d65a6604
Gerrit-Change-Number: 16860
Gerrit-PatchSet: 2
Gerrit-Owner: Andrew Wong <aw...@cloudera.com>
Gerrit-Reviewer: Kudu Jenkins (120)
Gerrit-Reviewer: Tidy Bot (241)
[kudu-CR] KUDU-2612: allow participant ops to detect idempotent calls
Posted by "Andrew Wong (Code Review)" <ge...@cloudera.org>.
Hello Tidy Bot, Alexey Serbin, Kudu Jenkins, Hao Hao,
I'd like you to reexamine a change. Please visit
http://gerrit.cloudera.org:8080/16860
to look at the new patch set (#4).
Change subject: KUDU-2612: allow participant ops to detect idempotent calls
......................................................................
KUDU-2612: allow participant ops to detect idempotent calls
Previously, we could return TXN_ILLEGAL_STATE error if we tried to start
a transaction but one was already present, we tried to begin committing
but it the commit was already in progress, etc. However, it seems like
it will be more robust behavior to be able to detect such cases, where
the requested mutation is already applied. This patch does this by
sending back a new TXN_OP_ALREADY_APPLIED error code for such calls.
While it would be nice to return an OK response with the participant op,
it seems non-trivial to exit out of an in-flight op with a success.
Change-Id: If82d3d1aad6737dd4f9f234b122b8c15d65a6604
---
M src/kudu/integration-tests/txn_participant-itest.cc
M src/kudu/tablet/ops/participant_op.cc
M src/kudu/tablet/ops/write_op.cc
M src/kudu/tablet/ops/write_op.h
M src/kudu/tablet/tablet_metadata.cc
M src/kudu/tablet/tablet_metadata.h
M src/kudu/tablet/txn_participant-test.cc
M src/kudu/tablet/txn_participant.cc
M src/kudu/tablet/txn_participant.h
M src/kudu/tserver/tserver.proto
10 files changed, 215 insertions(+), 133 deletions(-)
git pull ssh://gerrit.cloudera.org:29418/kudu refs/changes/60/16860/4
--
To view, visit http://gerrit.cloudera.org:8080/16860
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: If82d3d1aad6737dd4f9f234b122b8c15d65a6604
Gerrit-Change-Number: 16860
Gerrit-PatchSet: 4
Gerrit-Owner: Andrew Wong <aw...@cloudera.com>
Gerrit-Reviewer: Alexey Serbin <as...@cloudera.com>
Gerrit-Reviewer: Andrew Wong <aw...@cloudera.com>
Gerrit-Reviewer: Hao Hao <ha...@cloudera.com>
Gerrit-Reviewer: Kudu Jenkins (120)
Gerrit-Reviewer: Tidy Bot (241)
[kudu-CR] KUDU-2612: allow participant ops to detect idempotent calls
Posted by "Andrew Wong (Code Review)" <ge...@cloudera.org>.
Hello Tidy Bot, Alexey Serbin, Kudu Jenkins, Hao Hao,
I'd like you to reexamine a change. Please visit
http://gerrit.cloudera.org:8080/16860
to look at the new patch set (#3).
Change subject: KUDU-2612: allow participant ops to detect idempotent calls
......................................................................
KUDU-2612: allow participant ops to detect idempotent calls
Previously, we could return TXN_ILLEGAL_STATE error if we tried to start
a transaction but one was already present, we tried to begin committing
but it the commit was already in progress, etc. However, it seems like
it will be more robust behavior to be able to detect such cases, where
the requested mutation is already applied. This patch does this by
sending back a new TXN_OP_ALREADY_APPLIED error code for such calls.
While it would be nice to return an OK response with the participant op,
it seems non-trivial to exit out of an in-flight op with a success.
Change-Id: If82d3d1aad6737dd4f9f234b122b8c15d65a6604
---
M src/kudu/integration-tests/txn_participant-itest.cc
M src/kudu/tablet/ops/participant_op.cc
M src/kudu/tablet/ops/write_op.cc
M src/kudu/tablet/ops/write_op.h
M src/kudu/tablet/tablet_metadata.cc
M src/kudu/tablet/tablet_metadata.h
M src/kudu/tablet/txn_participant-test.cc
M src/kudu/tablet/txn_participant.cc
M src/kudu/tablet/txn_participant.h
M src/kudu/tserver/tserver.proto
10 files changed, 213 insertions(+), 133 deletions(-)
git pull ssh://gerrit.cloudera.org:29418/kudu refs/changes/60/16860/3
--
To view, visit http://gerrit.cloudera.org:8080/16860
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: If82d3d1aad6737dd4f9f234b122b8c15d65a6604
Gerrit-Change-Number: 16860
Gerrit-PatchSet: 3
Gerrit-Owner: Andrew Wong <aw...@cloudera.com>
Gerrit-Reviewer: Alexey Serbin <as...@cloudera.com>
Gerrit-Reviewer: Andrew Wong <aw...@cloudera.com>
Gerrit-Reviewer: Hao Hao <ha...@cloudera.com>
Gerrit-Reviewer: Kudu Jenkins (120)
Gerrit-Reviewer: Tidy Bot (241)
[kudu-CR] KUDU-2612: allow participant ops to detect idempotent calls
Posted by "Andrew Wong (Code Review)" <ge...@cloudera.org>.
Andrew Wong has posted comments on this change. ( http://gerrit.cloudera.org:8080/16860 )
Change subject: KUDU-2612: allow participant ops to detect idempotent calls
......................................................................
Patch Set 5:
(2 comments)
http://gerrit.cloudera.org:8080/#/c/16860/4/src/kudu/tablet/txn_participant.h
File src/kudu/tablet/txn_participant.h:
http://gerrit.cloudera.org:8080/#/c/16860/4/src/kudu/tablet/txn_participant.h@46
PS4, Line 46: ne the
> nit: it would be nice to add a comment why this is necessary; is this just
Ah sure. We need to specify a type so we can forward declare this enum.
http://gerrit.cloudera.org:8080/#/c/16860/4/src/kudu/tablet/txn_participant.h@251
PS4, Line 251: te meta_state;
> nit: maybe, for clarity use
Doh! Done
--
To view, visit http://gerrit.cloudera.org:8080/16860
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: If82d3d1aad6737dd4f9f234b122b8c15d65a6604
Gerrit-Change-Number: 16860
Gerrit-PatchSet: 5
Gerrit-Owner: Andrew Wong <aw...@cloudera.com>
Gerrit-Reviewer: Alexey Serbin <as...@cloudera.com>
Gerrit-Reviewer: Andrew Wong <aw...@cloudera.com>
Gerrit-Reviewer: Hao Hao <ha...@cloudera.com>
Gerrit-Reviewer: Kudu Jenkins (120)
Gerrit-Reviewer: Tidy Bot (241)
Gerrit-Comment-Date: Sat, 12 Dec 2020 05:42:09 +0000
Gerrit-HasComments: Yes
[kudu-CR] KUDU-2612: allow participant ops to detect idempotent calls
Posted by "Andrew Wong (Code Review)" <ge...@cloudera.org>.
Andrew Wong has posted comments on this change. ( http://gerrit.cloudera.org:8080/16860 )
Change subject: KUDU-2612: allow participant ops to detect idempotent calls
......................................................................
Patch Set 3:
(4 comments)
http://gerrit.cloudera.org:8080/#/c/16860/2/src/kudu/tablet/txn_participant.h
File src/kudu/tablet/txn_participant.h:
http://gerrit.cloudera.org:8080/#/c/16860/2/src/kudu/tablet/txn_participant.h@a78
PS2, Line 78:
:
:
:
:
:
:
:
:
:
> nit: why not to move this out of the class once TxnState enum is no longer
Done
http://gerrit.cloudera.org:8080/#/c/16860/2/src/kudu/tablet/txn_participant.h@47
PS2, Line 47: l state;
> nit: Is this just to avoid casting to an integer while printing? Otherwise
Done
http://gerrit.cloudera.org:8080/#/c/16860/2/src/kudu/tablet/txn_participant.h@243
PS2, Line 243: er::T
> nit: drop ?
Done
http://gerrit.cloudera.org:8080/#/c/16860/2/src/kudu/tablet/txn_participant.h@249
PS2, Line 249: if (expected_metadata_s
> nit: might it be simpler to introduce an extra kNoState entry for TxnState
Done
--
To view, visit http://gerrit.cloudera.org:8080/16860
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: If82d3d1aad6737dd4f9f234b122b8c15d65a6604
Gerrit-Change-Number: 16860
Gerrit-PatchSet: 3
Gerrit-Owner: Andrew Wong <aw...@cloudera.com>
Gerrit-Reviewer: Alexey Serbin <as...@cloudera.com>
Gerrit-Reviewer: Andrew Wong <aw...@cloudera.com>
Gerrit-Reviewer: Hao Hao <ha...@cloudera.com>
Gerrit-Reviewer: Kudu Jenkins (120)
Gerrit-Reviewer: Tidy Bot (241)
Gerrit-Comment-Date: Sat, 12 Dec 2020 04:34:24 +0000
Gerrit-HasComments: Yes
[kudu-CR] KUDU-2612: allow participant ops to detect idempotent calls
Posted by "Andrew Wong (Code Review)" <ge...@cloudera.org>.
Hello Tidy Bot, Kudu Jenkins,
I'd like you to reexamine a change. Please visit
http://gerrit.cloudera.org:8080/16860
to look at the new patch set (#2).
Change subject: KUDU-2612: allow participant ops to detect idempotent calls
......................................................................
KUDU-2612: allow participant ops to detect idempotent calls
Previously, we could return TXN_ILLEGAL_STATE error if we tried to start
a transaction but one was already present, we tried to begin committing
but it the commit was already in progress, etc. However, it seems like
it will be more robust behavior to be able to detect such cases, where
the requested mutation is already applied. This patch does this by
sending back a new TXN_OP_ALREADY_APPLIED error code for such calls.
While it would be nice to return an OK response with the participant op,
it seems non-trivial to exit out of an in-flight op with a success.
Change-Id: If82d3d1aad6737dd4f9f234b122b8c15d65a6604
---
M src/kudu/integration-tests/txn_participant-itest.cc
M src/kudu/tablet/ops/participant_op.cc
M src/kudu/tablet/ops/write_op.cc
M src/kudu/tablet/ops/write_op.h
M src/kudu/tablet/tablet_metadata.cc
M src/kudu/tablet/tablet_metadata.h
M src/kudu/tablet/txn_participant-test.cc
M src/kudu/tablet/txn_participant.cc
M src/kudu/tablet/txn_participant.h
M src/kudu/tserver/tserver.proto
10 files changed, 192 insertions(+), 117 deletions(-)
git pull ssh://gerrit.cloudera.org:29418/kudu refs/changes/60/16860/2
--
To view, visit http://gerrit.cloudera.org:8080/16860
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: If82d3d1aad6737dd4f9f234b122b8c15d65a6604
Gerrit-Change-Number: 16860
Gerrit-PatchSet: 2
Gerrit-Owner: Andrew Wong <aw...@cloudera.com>
Gerrit-Reviewer: Kudu Jenkins (120)
Gerrit-Reviewer: Tidy Bot (241)
[kudu-CR] KUDU-2612: allow participant ops to detect idempotent calls
Posted by "Alexey Serbin (Code Review)" <ge...@cloudera.org>.
Alexey Serbin has posted comments on this change. ( http://gerrit.cloudera.org:8080/16860 )
Change subject: KUDU-2612: allow participant ops to detect idempotent calls
......................................................................
Patch Set 5: Code-Review+2
--
To view, visit http://gerrit.cloudera.org:8080/16860
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: If82d3d1aad6737dd4f9f234b122b8c15d65a6604
Gerrit-Change-Number: 16860
Gerrit-PatchSet: 5
Gerrit-Owner: Andrew Wong <aw...@cloudera.com>
Gerrit-Reviewer: Alexey Serbin <as...@cloudera.com>
Gerrit-Reviewer: Andrew Wong <aw...@cloudera.com>
Gerrit-Reviewer: Hao Hao <ha...@cloudera.com>
Gerrit-Reviewer: Kudu Jenkins (120)
Gerrit-Reviewer: Tidy Bot (241)
Gerrit-Comment-Date: Sat, 12 Dec 2020 06:05:21 +0000
Gerrit-HasComments: No
[kudu-CR] KUDU-2612: allow participant ops to detect idempotent calls
Posted by "Andrew Wong (Code Review)" <ge...@cloudera.org>.
Hello Tidy Bot, Alexey Serbin, Kudu Jenkins, Hao Hao,
I'd like you to reexamine a change. Please visit
http://gerrit.cloudera.org:8080/16860
to look at the new patch set (#5).
Change subject: KUDU-2612: allow participant ops to detect idempotent calls
......................................................................
KUDU-2612: allow participant ops to detect idempotent calls
Previously, we could return TXN_ILLEGAL_STATE error if we tried to start
a transaction but one was already present, we tried to begin committing
but it the commit was already in progress, etc. However, it seems like
it will be more robust behavior to be able to detect such cases, where
the requested mutation is already applied. This patch does this by
sending back a new TXN_OP_ALREADY_APPLIED error code for such calls.
While it would be nice to return an OK response with the participant op,
it seems non-trivial to exit out of an in-flight op with a success.
Change-Id: If82d3d1aad6737dd4f9f234b122b8c15d65a6604
---
M src/kudu/integration-tests/txn_participant-itest.cc
M src/kudu/tablet/ops/participant_op.cc
M src/kudu/tablet/ops/write_op.cc
M src/kudu/tablet/ops/write_op.h
M src/kudu/tablet/tablet_metadata.cc
M src/kudu/tablet/tablet_metadata.h
M src/kudu/tablet/txn_participant-test.cc
M src/kudu/tablet/txn_participant.cc
M src/kudu/tablet/txn_participant.h
M src/kudu/tserver/tserver.proto
10 files changed, 217 insertions(+), 133 deletions(-)
git pull ssh://gerrit.cloudera.org:29418/kudu refs/changes/60/16860/5
--
To view, visit http://gerrit.cloudera.org:8080/16860
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: If82d3d1aad6737dd4f9f234b122b8c15d65a6604
Gerrit-Change-Number: 16860
Gerrit-PatchSet: 5
Gerrit-Owner: Andrew Wong <aw...@cloudera.com>
Gerrit-Reviewer: Alexey Serbin <as...@cloudera.com>
Gerrit-Reviewer: Andrew Wong <aw...@cloudera.com>
Gerrit-Reviewer: Hao Hao <ha...@cloudera.com>
Gerrit-Reviewer: Kudu Jenkins (120)
Gerrit-Reviewer: Tidy Bot (241)
[kudu-CR] KUDU-2612: allow participant ops to detect idempotent calls
Posted by "Alexey Serbin (Code Review)" <ge...@cloudera.org>.
Alexey Serbin has posted comments on this change. ( http://gerrit.cloudera.org:8080/16860 )
Change subject: KUDU-2612: allow participant ops to detect idempotent calls
......................................................................
Patch Set 2: Code-Review+2
(4 comments)
LGTM, just a few nits.
http://gerrit.cloudera.org:8080/#/c/16860/2/src/kudu/tablet/txn_participant.h
File src/kudu/tablet/txn_participant.h:
http://gerrit.cloudera.org:8080/#/c/16860/2/src/kudu/tablet/txn_participant.h@a78
PS2, Line 78:
:
:
:
:
:
:
:
:
:
nit: why not to move this out of the class once TxnState enum is no longer here?
http://gerrit.cloudera.org:8080/#/c/16860/2/src/kudu/tablet/txn_participant.h@47
PS2, Line 47: : int16_t
nit: Is this just to avoid casting to an integer while printing? Otherwise, it would be nice to add a comment explaining why it's necessary to have this as 16-bit even if 8 bit is more than enough.
http://gerrit.cloudera.org:8080/#/c/16860/2/src/kudu/tablet/txn_participant.h@243
PS2, Line 243: while
nit: drop ?
http://gerrit.cloudera.org:8080/#/c/16860/2/src/kudu/tablet/txn_participant.h@249
PS2, Line 249: boost::optional<TxnState>
nit: might it be simpler to introduce an extra kNoState entry for TxnState and use it instead of boost::optional here?
--
To view, visit http://gerrit.cloudera.org:8080/16860
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: If82d3d1aad6737dd4f9f234b122b8c15d65a6604
Gerrit-Change-Number: 16860
Gerrit-PatchSet: 2
Gerrit-Owner: Andrew Wong <aw...@cloudera.com>
Gerrit-Reviewer: Alexey Serbin <as...@cloudera.com>
Gerrit-Reviewer: Andrew Wong <aw...@cloudera.com>
Gerrit-Reviewer: Hao Hao <ha...@cloudera.com>
Gerrit-Reviewer: Kudu Jenkins (120)
Gerrit-Reviewer: Tidy Bot (241)
Gerrit-Comment-Date: Sat, 12 Dec 2020 02:54:29 +0000
Gerrit-HasComments: Yes