Skip to content

Conversation

@anujmodi2021
Copy link
Contributor

Description of PR

This PR fixes the Unchecked Cast Error/Warning thrown at javac step of yetus checks on PR.
Jira ticket: https://issues.apache.org/jira/browse/HADOOP-18690

Fix is to deterministically type cast the return type of the function.
Since there is only one return type possible for the function, there is no need to type cast it.

}

public static Token<? extends TokenIdentifier> toToken(final Map<?, ?> m)
public static Token<DelegationTokenIdentifier> toToken(final Map<?, ?> m)
Copy link
Contributor Author

@anujmodi2021 anujmodi2021 Apr 5, 2023

Choose a reason for hiding this comment

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

The only possible return type from this function (apart from null) is "Token<DelegationTokenIdentifier>". Therefore it seems safe to deterministically define the return type instead of generic return type here. This will solve the Unchecked Cast Error.

@hadoop-yetus
Copy link

💔 -1 overall

Vote Subsystem Runtime Logfile Comment
+0 🆗 reexec 0m 42s Docker mode activated.
_ Prechecks _
+1 💚 dupname 0m 0s No case conflicting files found.
+0 🆗 codespell 0m 0s codespell was not available.
+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.
_ branch-3.3.4 Compile Tests _
+1 💚 mvninstall 37m 52s branch-3.3.4 passed
+1 💚 compile 0m 37s branch-3.3.4 passed
+1 💚 checkstyle 0m 30s branch-3.3.4 passed
+1 💚 mvnsite 0m 40s branch-3.3.4 passed
+1 💚 javadoc 0m 35s branch-3.3.4 passed
+1 💚 spotbugs 1m 17s branch-3.3.4 passed
+1 💚 shadedclient 24m 49s branch has no errors when building and testing our client artifacts.
_ Patch Compile Tests _
+1 💚 mvninstall 0m 33s the patch passed
+1 💚 compile 0m 28s the patch passed
-1 ❌ javac 0m 28s /results-compile-javac-hadoop-tools_hadoop-azure.txt hadoop-tools_hadoop-azure generated 1 new + 18 unchanged - 1 fixed = 19 total (was 19)
+1 💚 blanks 0m 0s The patch has no blanks issues.
+1 💚 checkstyle 0m 18s the patch passed
+1 💚 mvnsite 0m 30s the patch passed
+1 💚 javadoc 0m 22s the patch passed
+1 💚 spotbugs 1m 8s the patch passed
+1 💚 shadedclient 23m 47s patch has no errors when building and testing our client artifacts.
_ Other Tests _
+1 💚 unit 1m 56s hadoop-azure in the patch passed.
+1 💚 asflicense 0m 38s The patch does not generate ASF License warnings.
98m 17s
Subsystem Report/Notes
Docker ClientAPI=1.42 ServerAPI=1.42 base: https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-5535/1/artifact/out/Dockerfile
GITHUB PR #5535
JIRA Issue HADOOP-18690
Optional Tests dupname asflicense compile javac javadoc mvninstall mvnsite unit shadedclient spotbugs checkstyle codespell
uname Linux b642ee76a61f 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 dev-support/bin/hadoop.sh
git revision branch-3.3.4 / 1ddc911
Default Java Private Build-1.8.0_362-8u362-ga-0ubuntu1~18.04.1-b09
Test Results https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-5535/1/testReport/
Max. process+thread count 540 (vs. ulimit of 5500)
modules C: hadoop-tools/hadoop-azure U: hadoop-tools/hadoop-azure
Console output https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-5535/1/console
versions git=2.17.1 maven=3.6.0 spotbugs=4.2.2
Powered by Apache Yetus 0.14.0-SNAPSHOT https://yetus.apache.org

This message was automatically generated.

@hadoop-yetus
Copy link

💔 -1 overall

Vote Subsystem Runtime Logfile Comment
+0 🆗 reexec 1m 0s Docker mode activated.
_ Prechecks _
+1 💚 dupname 0m 1s No case conflicting files found.
+0 🆗 codespell 0m 0s codespell was not available.
+1 💚 @author 0m 0s The patch does not contain any @author tags.
+1 💚 test4tests 0m 0s The patch appears to include 1 new or modified test files.
_ branch-3.3.4 Compile Tests _
+1 💚 mvninstall 39m 17s branch-3.3.4 passed
+1 💚 compile 0m 32s branch-3.3.4 passed
+1 💚 checkstyle 0m 27s branch-3.3.4 passed
+1 💚 mvnsite 0m 38s branch-3.3.4 passed
+1 💚 javadoc 0m 29s branch-3.3.4 passed
+1 💚 spotbugs 1m 18s branch-3.3.4 passed
+1 💚 shadedclient 27m 22s branch has no errors when building and testing our client artifacts.
_ Patch Compile Tests _
+1 💚 mvninstall 0m 32s the patch passed
+1 💚 compile 0m 30s the patch passed
-1 ❌ javac 0m 30s /results-compile-javac-hadoop-tools_hadoop-azure.txt hadoop-tools_hadoop-azure generated 2 new + 17 unchanged - 2 fixed = 19 total (was 19)
+1 💚 blanks 0m 0s The patch has no blanks issues.
+1 💚 checkstyle 0m 17s the patch passed
+1 💚 mvnsite 0m 33s the patch passed
+1 💚 javadoc 0m 20s the patch passed
+1 💚 spotbugs 1m 17s the patch passed
+1 💚 shadedclient 26m 44s patch has no errors when building and testing our client artifacts.
_ Other Tests _
+1 💚 unit 2m 6s hadoop-azure in the patch passed.
+1 💚 asflicense 0m 32s The patch does not generate ASF License warnings.
104m 34s
Subsystem Report/Notes
Docker ClientAPI=1.42 ServerAPI=1.42 base: https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-5535/2/artifact/out/Dockerfile
GITHUB PR #5535
JIRA Issue HADOOP-18690
Optional Tests dupname asflicense compile javac javadoc mvninstall mvnsite unit shadedclient spotbugs checkstyle codespell
uname Linux ead33f932db0 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 dev-support/bin/hadoop.sh
git revision branch-3.3.4 / 2744731
Default Java Private Build-1.8.0_362-8u362-ga-0ubuntu1~18.04.1-b09
Test Results https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-5535/2/testReport/
Max. process+thread count 518 (vs. ulimit of 5500)
modules C: hadoop-tools/hadoop-azure U: hadoop-tools/hadoop-azure
Console output https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-5535/2/console
versions git=2.17.1 maven=3.6.0 spotbugs=4.2.2
Powered by Apache Yetus 0.14.0-SNAPSHOT https://yetus.apache.org

This message was automatically generated.

@ayushtkn
Copy link
Member

3.3..4 branch is released. No changes accepted for this branch. Closing

@ayushtkn ayushtkn closed this Apr 19, 2023
@anujmodi2021 anujmodi2021 deleted the branch-3.3.4_dev branch March 1, 2024 08:26
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