HADOOP-19951. Remove use of jetty-util-ajax and use jackson instead - #8654
Conversation
ajfabbri
left a comment
There was a problem hiding this comment.
LGTM except I had a couple of questions.
|
💔 -1 overall
This message was automatically generated. |
|
💔 -1 overall
This message was automatically generated. |
72979b1 to
181f550
Compare
|
💔 -1 overall
This message was automatically generated. |
|
💔 -1 overall
This message was automatically generated. |
|
💔 -1 overall
This message was automatically generated. |
|
💔 -1 overall
This message was automatically generated. |
|
💔 -1 overall
This message was automatically generated. |
|
💔 -1 overall
This message was automatically generated. |
|
💔 -1 overall
This message was automatically generated. |
|
💔 -1 overall
This message was automatically generated. |
|
There now appears to be just one test class failing and I think this is unrelated to this PR: |
| @Override | ||
| public int hashCode() {return toShort();} | ||
|
|
||
| @JsonValue // For Jackson serialization, use the toString() to represent this object as JSON. |
There was a problem hiding this comment.
It's exposing the Jackson API from the Hadoop API, I'm not sure this is a good choice ...
pan3793
left a comment
There was a problem hiding this comment.
@pjfanning thanks for your effort, I go through the non-test code and pom.xml changes, almost LGTM, but I think we should not add com.fasterxml.jackson.annotation.* to Hadoop public API, and I believe it can be replaced with a caller-side static method or something else that easy to implement.
jackson-annotations is a non-optional dependency of jackson-databind - a heavily used lib in Hadoop This jackson-annotations is already in the Hadoop ecosystem. This PR does not add the dependency. Jackson-Databind is heavily dependent on annotations generally. https://github.com/search?q=repo%3Aapache%2Fhadoop+com.fasterxml.jackson.annotation&type=code |
692f1e0 to
d284887
Compare
I agree that this is not a change that we should look to backport. |
|
Another finding: Same-class issue still open: |
|
@pan3793 I'd prefer to keep the jackson changes in most places but this RBFMetrics use case feels like it might be best off being fixed by going back to the Jetty JSON behaviour. I could inline a cut down version of the jetty 9.4 class. I know it's a big enough class but it looks manageable enough. I could revert some of the Jackson related changes in the hadoop-hdfs-rbf module. |
| * Object --> string (dubious!) | ||
| * </pre> | ||
| */ | ||
| public class JSON { |
There was a problem hiding this comment.
can we narrow it to package level? or @Private
| hadoop-hdfs-project/hadoop-hdfs/src/main/webapps/static/nvd3-1.8.5.* (css and js files) | ||
|
|
||
|
|
||
| Apache Software Foundation License 2.0 and Eclipse Public License 1.0 Dual Licensed |
There was a problem hiding this comment.
for dual/multi licensed project, I think we can just choose one instead of listing all
|
|
|
LGTM, only minor issues |
|
💔 -1 overall
This message was automatically generated. |
|
💔 -1 overall
This message was automatically generated. |
|
💔 -1 overall
This message was automatically generated. |
| @@ -0,0 +1,287 @@ | |||
| // | |||
| // ======================================================================== | |||
There was a problem hiding this comment.
oh, it should be added to the RAT excluded list
|
thanks, merged to trunk |
|
💔 -1 overall
This message was automatically generated. |
…pache#8654) Authored-by: PJ Fanning <fanningpj@apache.org> Reviewed-by: Aaron Fabbri <fabbri@apache.org> Signed-off-by: Cheng Pan <chengpan@apache.org>
JSON.java was added to hadoop-hdfs-rbf by HADOOP-19951 (apache#8654) carrying its upstream Jetty EPL/Apache dual-license header, which apache-rat does not recognise as an ASF header. The asflicense check therefore reports one warning on every pull request targeting trunk, not just this one. Exclude the file via apache-rat-plugin the same way other vendored sources are excluded elsewhere in the project. This commit is separable from the HADOOP-19973 fix and can be dropped if it is preferred to address the breakage under its own JIRA.
Description of PR
HADOOP-19951
Contains content generated by Claude / Xiaomi Mimo.
How was this patch tested?
CI build
For code changes:
LICENSE,LICENSE-binary,NOTICE-binaryfiles?AI Tooling
If an AI tool was used:
where is the name of the AI tool used.
https://www.apache.org/legal/generative-tooling.html