Skip to content
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

TEZ-4250: Optimise TaskImpl::getCounters. #295

Merged
merged 4 commits into from
Jun 23, 2023

Conversation

ayushtkn
Copy link
Member

No description provided.

Change-Id: I7db4db3a4d2cb70f2e1d96fbaa2f853524fbce8a
@tez-yetus

This comment was marked as outdated.

@tez-yetus

This comment was marked as outdated.

@tez-yetus

This comment was marked as outdated.

ayushtkn added 2 commits June 21, 2023 14:59
Change-Id: Ibaa0d6891658e1f54da883f9cc6b91eaa601c0ed
Change-Id: I1e36574b5fde496f52c155ff420d7434e067274f
@tez-yetus

This comment was marked as outdated.

@tez-yetus
Copy link

💔 -1 overall

Vote Subsystem Runtime Comment
+0 🆗 reexec 0m 19s Docker mode activated.
_ Prechecks _
+1 💚 dupname 0m 1s No case conflicting files found.
+1 💚 @author 0m 0s The patch does not contain any @author tags.
-1 ❌ test4tests 0m 0s The patch doesn't appear to include any new or modified tests. Please justify why no new tests are needed for this patch. Also please list what manual steps were performed to verify this patch.
_ master Compile Tests _
+1 💚 mvninstall 12m 2s master passed
+1 💚 compile 0m 50s master passed with JDK Ubuntu-11.0.19+7-post-Ubuntu-0ubuntu122.04.1
+1 💚 compile 0m 42s master passed with JDK Private Build-1.8.0_362-8u372-gaus1-0ubuntu122.04-b09
+1 💚 checkstyle 0m 43s master passed
+1 💚 javadoc 0m 26s master passed with JDK Ubuntu-11.0.19+7-post-Ubuntu-0ubuntu122.04.1
+1 💚 javadoc 0m 23s master passed with JDK Private Build-1.8.0_362-8u372-gaus1-0ubuntu122.04-b09
+0 🆗 spotbugs 1m 35s Used deprecated FindBugs config; considering switching to SpotBugs.
+1 💚 findbugs 1m 33s master passed
_ Patch Compile Tests _
+1 💚 mvninstall 0m 29s the patch passed
+1 💚 compile 0m 34s the patch passed with JDK Ubuntu-11.0.19+7-post-Ubuntu-0ubuntu122.04.1
+1 💚 javac 0m 34s the patch passed
+1 💚 compile 0m 28s the patch passed with JDK Private Build-1.8.0_362-8u372-gaus1-0ubuntu122.04-b09
+1 💚 javac 0m 28s the patch passed
+1 💚 checkstyle 0m 24s tez-dag: The patch generated 0 new + 127 unchanged - 1 fixed = 127 total (was 128)
+1 💚 whitespace 0m 0s The patch has no whitespace issues.
+1 💚 javadoc 0m 11s the patch passed with JDK Ubuntu-11.0.19+7-post-Ubuntu-0ubuntu122.04.1
+1 💚 javadoc 0m 10s the patch passed with JDK Private Build-1.8.0_362-8u372-gaus1-0ubuntu122.04-b09
+1 💚 findbugs 1m 18s the patch passed
_ Other Tests _
+1 💚 unit 5m 16s tez-dag in the patch passed.
+1 💚 asflicense 0m 11s The patch does not generate ASF License warnings.
27m 14s
Subsystem Report/Notes
Docker ClientAPI=1.43 ServerAPI=1.43 base: https://ci-hadoop.apache.org/job/tez-multibranch/job/PR-295/5/artifact/out/Dockerfile
GITHUB PR #295
JIRA Issue TEZ-4250
Optional Tests dupname asflicense javac javadoc unit spotbugs findbugs checkstyle compile
uname Linux 8a4f0e695c1d 4.15.0-206-generic #217-Ubuntu SMP Fri Feb 3 19:10:13 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality personality/tez.sh
git revision master / d20f334
Default Java Private Build-1.8.0_362-8u372-gaus1-0ubuntu122.04-b09
Multi-JDK versions /usr/lib/jvm/java-11-openjdk-amd64:Ubuntu-11.0.19+7-post-Ubuntu-0ubuntu122.04.1 /usr/lib/jvm/java-8-openjdk-amd64:Private Build-1.8.0_362-8u372-gaus1-0ubuntu122.04-b09
Test Results https://ci-hadoop.apache.org/job/tez-multibranch/job/PR-295/5/testReport/
Max. process+thread count 219 (vs. ulimit of 5500)
modules C: tez-dag U: tez-dag
Console output https://ci-hadoop.apache.org/job/tez-multibranch/job/PR-295/5/console
versions git=2.34.1 maven=3.6.3 findbugs=3.0.1
Powered by Apache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@rbalamohan
Copy link
Contributor

LGTM. +1

readLock.lock();
try {
TaskAttempt bestAttempt = selectBestAttempt();
if (bestAttempt != null) {
counters.incrAllCounters(bestAttempt.getCounters());
if (bestAttempt != null && tezCounters != null) {
Copy link
Contributor

@abstractdog abstractdog Jun 23, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

tezCounters != null only if speculation is enabled due to the recent patch, would it make sense to use that condition here for better readability? I guess it would clarify that we only use "this.counter" and this whole stuff in case of speculation
also, we're returning a non-null counter anyway, would this be clearer as:

TezCounters taskCounters = (bestAttempt != null) ? bestAttempt.getCounters() : TaskAttemptImpl.EMPTY_COUNTERS;

if (isSpeculationEnabled){
  tezCounters.incrAllCounters(taskCounters); 
  return tezCounters;
}
return taskCounters;

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

@abstractdog
Copy link
Contributor

thanks for the review @rbalamohan
LGTM also, only a minor nit, let me know if it makes sense

Change-Id: I5f9fdc7b3e257b33d67cf1dd1fd2c4f0923a9541
@tez-yetus
Copy link

💔 -1 overall

Vote Subsystem Runtime Comment
+0 🆗 reexec 0m 18s Docker mode activated.
_ Prechecks _
+1 💚 dupname 0m 0s No case conflicting files found.
+1 💚 @author 0m 0s The patch does not contain any @author tags.
-1 ❌ test4tests 0m 0s The patch doesn't appear to include any new or modified tests. Please justify why no new tests are needed for this patch. Also please list what manual steps were performed to verify this patch.
_ master Compile Tests _
+1 💚 mvninstall 12m 50s master passed
+1 💚 compile 0m 46s master passed with JDK Ubuntu-11.0.19+7-post-Ubuntu-0ubuntu122.04.1
+1 💚 compile 0m 43s master passed with JDK Private Build-1.8.0_362-8u372-gaus1-0ubuntu122.04-b09
+1 💚 checkstyle 0m 48s master passed
+1 💚 javadoc 0m 36s master passed with JDK Ubuntu-11.0.19+7-post-Ubuntu-0ubuntu122.04.1
+1 💚 javadoc 0m 27s master passed with JDK Private Build-1.8.0_362-8u372-gaus1-0ubuntu122.04-b09
+0 🆗 spotbugs 1m 47s Used deprecated FindBugs config; considering switching to SpotBugs.
+1 💚 findbugs 1m 45s master passed
_ Patch Compile Tests _
+1 💚 mvninstall 0m 27s the patch passed
+1 💚 compile 0m 30s the patch passed with JDK Ubuntu-11.0.19+7-post-Ubuntu-0ubuntu122.04.1
+1 💚 javac 0m 30s the patch passed
+1 💚 compile 0m 27s the patch passed with JDK Private Build-1.8.0_362-8u372-gaus1-0ubuntu122.04-b09
+1 💚 javac 0m 27s the patch passed
+1 💚 checkstyle 0m 22s tez-dag: The patch generated 0 new + 127 unchanged - 1 fixed = 127 total (was 128)
+1 💚 whitespace 0m 0s The patch has no whitespace issues.
+1 💚 javadoc 0m 10s the patch passed with JDK Ubuntu-11.0.19+7-post-Ubuntu-0ubuntu122.04.1
+1 💚 javadoc 0m 10s the patch passed with JDK Private Build-1.8.0_362-8u372-gaus1-0ubuntu122.04-b09
+1 💚 findbugs 1m 10s the patch passed
_ Other Tests _
+1 💚 unit 5m 14s tez-dag in the patch passed.
+1 💚 asflicense 0m 16s The patch does not generate ASF License warnings.
28m 15s
Subsystem Report/Notes
Docker ClientAPI=1.43 ServerAPI=1.43 base: https://ci-hadoop.apache.org/job/tez-multibranch/job/PR-295/6/artifact/out/Dockerfile
GITHUB PR #295
JIRA Issue TEZ-4250
Optional Tests dupname asflicense javac javadoc unit spotbugs findbugs checkstyle compile
uname Linux aee43b4351c2 4.15.0-206-generic #217-Ubuntu SMP Fri Feb 3 19:10:13 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality personality/tez.sh
git revision master / d20f334
Default Java Private Build-1.8.0_362-8u372-gaus1-0ubuntu122.04-b09
Multi-JDK versions /usr/lib/jvm/java-11-openjdk-amd64:Ubuntu-11.0.19+7-post-Ubuntu-0ubuntu122.04.1 /usr/lib/jvm/java-8-openjdk-amd64:Private Build-1.8.0_362-8u372-gaus1-0ubuntu122.04-b09
Test Results https://ci-hadoop.apache.org/job/tez-multibranch/job/PR-295/6/testReport/
Max. process+thread count 229 (vs. ulimit of 5500)
modules C: tez-dag U: tez-dag
Console output https://ci-hadoop.apache.org/job/tez-multibranch/job/PR-295/6/console
versions git=2.34.1 maven=3.6.3 findbugs=3.0.1
Powered by Apache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@abstractdog abstractdog merged commit 9aeb17b into apache:master Jun 23, 2023
Sign up for free to 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.

4 participants