Skip to content

HBASE-28771 Refactor AsyncRequestFutureImpl.isActionComplete to support non replica actions - #6143

Closed
droudnitsky wants to merge 1 commit into
apache:branch-2from
droudnitsky:branch-2-HBASE-27781-assert
Closed

HBASE-28771 Refactor AsyncRequestFutureImpl.isActionComplete to support non replica actions#6143
droudnitsky wants to merge 1 commit into
apache:branch-2from
droudnitsky:branch-2-HBASE-27781-assert

Conversation

@droudnitsky

@droudnitskydroudnitsky commented Aug 7, 2024

Copy link
Copy Markdown
Contributor

There is an example of the change being used in PR #6144.

Since isActionComplete currently only has one caller that depends on the replica action check we can move the replica action check to the caller method instead of having the check be inside isActionComplete.

The case of AsyncRequestFutureImpl without result tracking/null results:
The function does not support a AsyncRequestFutureImpl with null results (neither before nor after my proposed changes). I don't currently see a way to reliably check for action completion from within AsyncRequestFutureImpl for the null results case (I don't know how common this case is in practice, but it is accommodated for across AsyncRequestFutureImpl, and I test that path with Table.batch(List<Row>, null)). My understanding of that code is that in the null results case one cannot readily tell whether a given action has completed from within AsyncRequestFutureImpl because:

  • In the case of action success we just decrement action counter when calling setResult.
  • In the case of action failure the failure is tracked in BatchErrors, but BatchErrors does not track the action index for the failed action, only the Row, so even if we wanted to check whether for a given action an error was added to BatchErrors, we couldn't because of the way that Row equality is currently implemented - we can have two different actions in a batch with the same rows that are considered Row equal (e.g two gets for the same rowkey, but with different column family + column qualifiers specified, are considered equal).

If my understanding of AsyncRequestFutureImpl is flawed and/or there is a reliable way to do this check with null results, I would greatly appreciate the feedback.

The only current existing caller of this method will never hit the null results case because it only checks replica gets which will always have non-null results, and the proposed additional use of this method in PR #6144 currently will also only call the method in the non-null results case, so my proposal here is to just not support the null results case and throw IllegalStateException if one does try to call isActionComplete without checking that results exist.

@Apache-HBase

Copy link
Copy Markdown

🎊 +1 overall

VoteSubsystemRuntimeLogfileComment
+0 🆗reexec0m 39sDocker mode activated.
-0 ⚠️yetus0m 5sUnprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --author-ignore-list --blanks-eol-ignore-file --blanks-tabs-ignore-file --quick-hadoopcheck
_ Prechecks _
_ branch-2 Compile Tests _
+1 💚mvninstall2m 35sbranch-2 passed
+1 💚compile0m 21sbranch-2 passed
+1 💚javadoc0m 20sbranch-2 passed
+1 💚shadedjars4m 56sbranch has no errors when building our shaded downstream artifacts.
_ Patch Compile Tests _
+1 💚mvninstall2m 29sthe patch passed
+1 💚compile0m 21sthe patch passed
+1 💚javac0m 21sthe patch passed
+1 💚javadoc0m 18sthe patch passed
+1 💚shadedjars4m 54spatch has no errors when building our shaded downstream artifacts.
_ Other Tests _
+1 💚unit8m 12shbase-client in the patch passed.
26m 10s
SubsystemReport/Notes
DockerClientAPI=1.46 ServerAPI=1.46 base: https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6143/1/artifact/yetus-jdk8-hadoop2-check/output/Dockerfile
GITHUB PR#6143
Optional Testsjavac javadoc unit compile shadedjars
unameLinux cca2a605d6c5 5.4.0-177-generic #197-Ubuntu SMP Thu Mar 28 22:45:47 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personalitydev-support/hbase-personality.sh
git revisionbranch-2 / 150fa2b
Default JavaTemurin-1.8.0_412-b08
Test Resultshttps://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6143/1/testReport/
Max. process+thread count347 (vs. ulimit of 30000)
modulesC: hbase-client U: hbase-client
Console outputhttps://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6143/1/console
versionsgit=2.34.1 maven=3.9.8
Powered byApache Yetus 0.15.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase

Copy link
Copy Markdown

💔 -1 overall

VoteSubsystemRuntimeLogfileComment
+0 🆗reexec0m 21sDocker mode activated.
_ Prechecks _
+1 💚dupname0m 0sNo case conflicting files found.
+0 🆗codespell0m 0scodespell was not available.
+0 🆗detsecrets0m 0sdetect-secrets was not available.
+1 💚@author0m 0sThe patch does not contain any @author tags.
+1 💚hbaseanti0m 0sPatch does not have any anti-patterns.
_ branch-2 Compile Tests _
+1 💚mvninstall3m 2sbranch-2 passed
+1 💚compile0m 52sbranch-2 passed
+1 💚checkstyle0m 20sbranch-2 passed
+1 💚spotbugs0m 55sbranch-2 passed
+1 💚spotless0m 46sbranch has no errors when running spotless:check.
_ Patch Compile Tests _
+1 💚mvninstall2m 57sthe patch passed
+1 💚compile0m 51sthe patch passed
+1 💚javac0m 51sthe patch passed
+1 💚blanks0m 0sThe patch has no blanks issues.
-0 ⚠️checkstyle0m 19s/results-checkstyle-hbase-client.txthbase-client: The patch generated 1 new + 11 unchanged - 1 fixed = 12 total (was 12)
+1 💚spotbugs1m 0sthe patch passed
+1 💚hadoopcheck15m 20sPatch does not cause any errors with Hadoop 2.10.2 or 3.3.6 3.4.0.
-1 ❌spotless0m 21spatch has 23 errors when running spotless:check, run spotless:apply to fix.
_ Other Tests _
+1 💚asflicense0m 12sThe patch does not generate ASF License warnings.
28m 42s
SubsystemReport/Notes
DockerClientAPI=1.46 ServerAPI=1.46 base: https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6143/1/artifact/yetus-general-check/output/Dockerfile
GITHUB PR#6143
Optional Testsdupname asflicense javac spotbugs checkstyle codespell detsecrets compile hadoopcheck hbaseanti spotless
unameLinux 2593638861a4 5.4.0-182-generic #202-Ubuntu SMP Fri Apr 26 12:29:36 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personalitydev-support/hbase-personality.sh
git revisionbranch-2 / 150fa2b
Default JavaEclipse Adoptium-11.0.23+9
spotlesshttps://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6143/1/artifact/yetus-general-check/output/patch-spotless.txt
Max. process+thread count79 (vs. ulimit of 30000)
modulesC: hbase-client U: hbase-client
Console outputhttps://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6143/1/console
versionsgit=2.34.1 maven=3.9.8 spotbugs=4.7.3
Powered byApache Yetus 0.15.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase

Copy link
Copy Markdown

🎊 +1 overall

VoteSubsystemRuntimeLogfileComment
+0 🆗reexec0m 44sDocker mode activated.
-0 ⚠️yetus0m 5sUnprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --author-ignore-list --blanks-eol-ignore-file --blanks-tabs-ignore-file --quick-hadoopcheck
_ Prechecks _
_ branch-2 Compile Tests _
+1 💚mvninstall3m 14sbranch-2 passed
+1 💚compile0m 23sbranch-2 passed
+1 💚javadoc0m 20sbranch-2 passed
+1 💚shadedjars5m 57sbranch has no errors when building our shaded downstream artifacts.
_ Patch Compile Tests _
+1 💚mvninstall3m 0sthe patch passed
+1 💚compile0m 23sthe patch passed
+1 💚javac0m 23sthe patch passed
+1 💚javadoc0m 19sthe patch passed
+1 💚shadedjars5m 52spatch has no errors when building our shaded downstream artifacts.
_ Other Tests _
+1 💚unit8m 15shbase-client in the patch passed.
29m 39s
SubsystemReport/Notes
DockerClientAPI=1.43 ServerAPI=1.43 base: https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6143/1/artifact/yetus-jdk17-hadoop3-check/output/Dockerfile
GITHUB PR#6143
Optional Testsjavac javadoc unit compile shadedjars
unameLinux 86c7ac934ac3 5.4.0-1103-aws #111~18.04.1-Ubuntu SMP Tue May 23 20:04:10 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personalitydev-support/hbase-personality.sh
git revisionbranch-2 / 150fa2b
Default JavaEclipse Adoptium-17.0.11+9
Test Resultshttps://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6143/1/testReport/
Max. process+thread count386 (vs. ulimit of 30000)
modulesC: hbase-client U: hbase-client
Console outputhttps://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6143/1/console
versionsgit=2.34.1 maven=3.9.8
Powered byApache Yetus 0.15.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase

Copy link
Copy Markdown

🎊 +1 overall

VoteSubsystemRuntimeLogfileComment
+0 🆗reexec0m 41sDocker mode activated.
-0 ⚠️yetus0m 5sUnprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --author-ignore-list --blanks-eol-ignore-file --blanks-tabs-ignore-file --quick-hadoopcheck
_ Prechecks _
_ branch-2 Compile Tests _
+1 💚mvninstall3m 22sbranch-2 passed
+1 💚compile0m 21sbranch-2 passed
+1 💚javadoc0m 19sbranch-2 passed
+1 💚shadedjars6m 13sbranch has no errors when building our shaded downstream artifacts.
_ Patch Compile Tests _
+1 💚mvninstall3m 13sthe patch passed
+1 💚compile0m 20sthe patch passed
+1 💚javac0m 20sthe patch passed
+1 💚javadoc0m 18sthe patch passed
+1 💚shadedjars6m 9spatch has no errors when building our shaded downstream artifacts.
_ Other Tests _
+1 💚unit8m 21shbase-client in the patch passed.
30m 24s
SubsystemReport/Notes
DockerClientAPI=1.43 ServerAPI=1.43 base: https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6143/1/artifact/yetus-jdk11-hadoop3-check/output/Dockerfile
GITHUB PR#6143
Optional Testsjavac javadoc unit compile shadedjars
unameLinux 0221582f8979 5.4.0-1103-aws #111~18.04.1-Ubuntu SMP Tue May 23 20:04:10 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personalitydev-support/hbase-personality.sh
git revisionbranch-2 / 150fa2b
Default JavaEclipse Adoptium-11.0.23+9
Test Resultshttps://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6143/1/testReport/
Max. process+thread count379 (vs. ulimit of 30000)
modulesC: hbase-client U: hbase-client
Console outputhttps://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6143/1/console
versionsgit=2.34.1 maven=3.9.8
Powered byApache Yetus 0.15.0 https://yetus.apache.org

This message was automatically generated.

@droudnitsky
droudnitskyforce-pushed the branch-2-HBASE-27781-assert branch from 150fa2b to 0ec2a58CompareAugust 8, 2024 01:48
@Apache-HBase

Copy link
Copy Markdown

🎊 +1 overall

VoteSubsystemRuntimeLogfileComment
+0 🆗reexec0m 41sDocker mode activated.
-0 ⚠️yetus0m 4sUnprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --author-ignore-list --blanks-eol-ignore-file --blanks-tabs-ignore-file --quick-hadoopcheck
_ Prechecks _
_ branch-2 Compile Tests _
+1 💚mvninstall2m 27sbranch-2 passed
+1 💚compile0m 21sbranch-2 passed
+1 💚javadoc0m 18sbranch-2 passed
+1 💚shadedjars4m 56sbranch has no errors when building our shaded downstream artifacts.
_ Patch Compile Tests _
+1 💚mvninstall2m 35sthe patch passed
+1 💚compile0m 20sthe patch passed
+1 💚javac0m 20sthe patch passed
+1 💚javadoc0m 18sthe patch passed
+1 💚shadedjars4m 55spatch has no errors when building our shaded downstream artifacts.
_ Other Tests _
+1 💚unit8m 16shbase-client in the patch passed.
26m 10s
SubsystemReport/Notes
DockerClientAPI=1.46 ServerAPI=1.46 base: https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6143/2/artifact/yetus-jdk8-hadoop2-check/output/Dockerfile
GITHUB PR#6143
Optional Testsjavac javadoc unit compile shadedjars
unameLinux 6b4cd5f1fbd2 5.4.0-177-generic #197-Ubuntu SMP Thu Mar 28 22:45:47 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personalitydev-support/hbase-personality.sh
git revisionbranch-2 / 0ec2a58
Default JavaTemurin-1.8.0_412-b08
Test Resultshttps://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6143/2/testReport/
Max. process+thread count345 (vs. ulimit of 30000)
modulesC: hbase-client U: hbase-client
Console outputhttps://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6143/2/console
versionsgit=2.34.1 maven=3.9.8
Powered byApache Yetus 0.15.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase

Copy link
Copy Markdown

🎊 +1 overall

VoteSubsystemRuntimeLogfileComment
+0 🆗reexec0m 39sDocker mode activated.
-0 ⚠️yetus0m 4sUnprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --author-ignore-list --blanks-eol-ignore-file --blanks-tabs-ignore-file --quick-hadoopcheck
_ Prechecks _
_ branch-2 Compile Tests _
+1 💚mvninstall3m 0sbranch-2 passed
+1 💚compile0m 21sbranch-2 passed
+1 💚javadoc0m 18sbranch-2 passed
+1 💚shadedjars5m 34sbranch has no errors when building our shaded downstream artifacts.
_ Patch Compile Tests _
+1 💚mvninstall2m 50sthe patch passed
+1 💚compile0m 22sthe patch passed
+1 💚javac0m 22sthe patch passed
+1 💚javadoc0m 18sthe patch passed
+1 💚shadedjars5m 55spatch has no errors when building our shaded downstream artifacts.
_ Other Tests _
+1 💚unit8m 42shbase-client in the patch passed.
29m 9s
SubsystemReport/Notes
DockerClientAPI=1.43 ServerAPI=1.43 base: https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6143/2/artifact/yetus-jdk17-hadoop3-check/output/Dockerfile
GITHUB PR#6143
Optional Testsjavac javadoc unit compile shadedjars
unameLinux 74e760fbd0b4 5.4.0-1103-aws #111~18.04.1-Ubuntu SMP Tue May 23 20:04:10 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personalitydev-support/hbase-personality.sh
git revisionbranch-2 / 0ec2a58
Default JavaEclipse Adoptium-17.0.11+9
Test Resultshttps://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6143/2/testReport/
Max. process+thread count369 (vs. ulimit of 30000)
modulesC: hbase-client U: hbase-client
Console outputhttps://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6143/2/console
versionsgit=2.34.1 maven=3.9.8
Powered byApache Yetus 0.15.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase

Copy link
Copy Markdown

🎊 +1 overall

VoteSubsystemRuntimeLogfileComment
+0 🆗reexec0m 40sDocker mode activated.
-0 ⚠️yetus0m 5sUnprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --author-ignore-list --blanks-eol-ignore-file --blanks-tabs-ignore-file --quick-hadoopcheck
_ Prechecks _
_ branch-2 Compile Tests _
+1 💚mvninstall3m 19sbranch-2 passed
+1 💚compile0m 21sbranch-2 passed
+1 💚javadoc0m 19sbranch-2 passed
+1 💚shadedjars6m 12sbranch has no errors when building our shaded downstream artifacts.
_ Patch Compile Tests _
+1 💚mvninstall3m 10sthe patch passed
+1 💚compile0m 22sthe patch passed
+1 💚javac0m 22sthe patch passed
+1 💚javadoc0m 18sthe patch passed
+1 💚shadedjars6m 8spatch has no errors when building our shaded downstream artifacts.
_ Other Tests _
+1 💚unit8m 25shbase-client in the patch passed.
30m 15s
SubsystemReport/Notes
DockerClientAPI=1.43 ServerAPI=1.43 base: https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6143/2/artifact/yetus-jdk11-hadoop3-check/output/Dockerfile
GITHUB PR#6143
Optional Testsjavac javadoc unit compile shadedjars
unameLinux 522978b1fec1 5.4.0-1103-aws #111~18.04.1-Ubuntu SMP Tue May 23 20:04:10 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personalitydev-support/hbase-personality.sh
git revisionbranch-2 / 0ec2a58
Default JavaEclipse Adoptium-11.0.23+9
Test Resultshttps://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6143/2/testReport/
Max. process+thread count390 (vs. ulimit of 30000)
modulesC: hbase-client U: hbase-client
Console outputhttps://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6143/2/console
versionsgit=2.34.1 maven=3.9.8
Powered byApache Yetus 0.15.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase

Copy link
Copy Markdown

🎊 +1 overall

VoteSubsystemRuntimeLogfileComment
+0 🆗reexec0m 22sDocker mode activated.
_ Prechecks _
+1 💚dupname0m 0sNo case conflicting files found.
+0 🆗codespell0m 1scodespell was not available.
+0 🆗detsecrets0m 1sdetect-secrets was not available.
+1 💚@author0m 0sThe patch does not contain any @author tags.
+1 💚hbaseanti0m 0sPatch does not have any anti-patterns.
_ branch-2 Compile Tests _
+1 💚mvninstall3m 33sbranch-2 passed
+1 💚compile0m 54sbranch-2 passed
+1 💚checkstyle0m 23sbranch-2 passed
+1 💚spotbugs1m 5sbranch-2 passed
+1 💚spotless0m 55sbranch has no errors when running spotless:check.
_ Patch Compile Tests _
+1 💚mvninstall3m 44sthe patch passed
+1 💚compile1m 4sthe patch passed
+1 💚javac1m 4sthe patch passed
+1 💚blanks0m 0sThe patch has no blanks issues.
+1 💚checkstyle0m 25shbase-client: The patch generated 0 new + 11 unchanged - 1 fixed = 11 total (was 12)
+1 💚spotbugs1m 10sthe patch passed
+1 💚hadoopcheck15m 44sPatch does not cause any errors with Hadoop 2.10.2 or 3.3.6 3.4.0.
+1 💚spotless0m 46spatch has no errors when running spotless:check.
_ Other Tests _
+1 💚asflicense0m 10sThe patch does not generate ASF License warnings.
31m 50s
SubsystemReport/Notes
DockerClientAPI=1.46 ServerAPI=1.46 base: https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6143/2/artifact/yetus-general-check/output/Dockerfile
GITHUB PR#6143
Optional Testsdupname asflicense javac spotbugs checkstyle codespell detsecrets compile hadoopcheck hbaseanti spotless
unameLinux d3896bc46500 5.4.0-182-generic #202-Ubuntu SMP Fri Apr 26 12:29:36 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personalitydev-support/hbase-personality.sh
git revisionbranch-2 / 0ec2a58
Default JavaEclipse Adoptium-11.0.23+9
Max. process+thread count79 (vs. ulimit of 30000)
modulesC: hbase-client U: hbase-client
Console outputhttps://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6143/2/console
versionsgit=2.34.1 maven=3.9.8 spotbugs=4.7.3
Powered byApache Yetus 0.15.0 https://yetus.apache.org

This message was automatically generated.

Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

@droudnitsky@Apache-HBase