[ZEPPELIN-6240] Use generics in CommandArgs constructor to improve type safety#4971
Merged
Reamer merged 1 commit intoJul 16, 2025
Merged
Conversation
Member
|
Could you update the PR title from ZEPPELIN-6225 to ZEPPELIN-6240? |
Member
|
Please update the Jira link in the PR description. |
Contributor
Author
|
Thanks for the review ! I just updated title & Jira link. |
Contributor
|
Please change the JIRA Link in your description to https://issues.apache.org/jira/browse/ZEPPELIN-6240 |
Reamer
approved these changes
Jul 16, 2025
asf-gitbox-commits
pushed a commit
that referenced
this pull request
Jul 16, 2025
…pe safety ### What is this PR for? As <at>ParkGyeongTae mentioned, in the file zeppelin/file/src/main/java/org/apache/zeppelin/file/FileInterpreter.java, the variables args and flags were originally created using raw types: ``` args = new ArrayList(); flags = new HashSet(); ``` To resolve compiler warnings and ensure proper type checking, I updated the code to use generic types with diamond operators (<>) like this: ``` args = new ArrayList<String>(); flags = new HashSet<String>(); ``` ### What type of PR is it? Refactoring ### Todos * [x] - Use generics in CommandArgs constructor ### What is the Jira issue? * Open an issue on [Jira](https://issues.apache.org/jira/browse/ZEPPELIN-6240) ### How should this be tested? * Strongly recommended: add automated unit tests for any new or changed behavior * Outline any manual steps to test the PR here. ### Screenshots (if appropriate) ### Questions: * Does the license files need to update? - No * Is there breaking changes for older versions? - No * Does this needs documentation? - No Closes #4971 from hyunw9/feat/Use-generics-in-CommandArgs-constructor. Signed-off-by: Philipp Dallig <philipp.dallig@gmail.com> (cherry picked from commit 91f091e) Signed-off-by: Philipp Dallig <philipp.dallig@gmail.com>
Contributor
|
Merged into master and branch-0.12 |
Contributor
Author
|
Happy to handle this request @Reamer! I will take the issue and update it to ASF Jira 👍 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What is this PR for?
As @ParkGyeongTae mentioned,
in the file zeppelin/file/src/main/java/org/apache/zeppelin/file/FileInterpreter.java,
the variables args and flags were originally created using raw types:
To resolve compiler warnings and ensure proper type checking,
I updated the code to use generic types with diamond operators (<>) like this:
What type of PR is it?
Refactoring
Todos
What is the Jira issue?
How should this be tested?
Screenshots (if appropriate)
Questions: