Skip to content

Commit eb52efc

Browse files
committed
HADOOP-15984. Update jersey from 1.19 to 2.x.
1 parent c9e9bce commit eb52efc

File tree

295 files changed

+13062
-10674
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

295 files changed

+13062
-10674
lines changed

dev-support/Jenkinsfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ pipeline {
5555
environment {
5656
YETUS='yetus'
5757
// Branch or tag name. Yetus release tags are 'rel/X.Y.Z'
58-
YETUS_VERSION='rel/0.14.0'
58+
YETUS_VERSION='a7d29a6a72750a0c5c39512f33945e773e69303e'
5959
}
6060

6161
parameters {
@@ -71,7 +71,7 @@ pipeline {
7171
checkout([
7272
$class: 'GitSCM',
7373
branches: [[name: "${env.YETUS_VERSION}"]],
74-
userRemoteConfigs: [[ url: 'https://github.com/apache/yetus.git']]]
74+
userRemoteConfigs: [[ url: 'https://github.com/ayushtkn/yetus.git']]]
7575
)
7676
}
7777
}

hadoop-client-modules/hadoop-client-check-invariants/pom.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,7 @@
8888
<exclude>ch.qos.reload4j:reload4j</exclude>
8989
<!-- Leave javax annotations we need exposed -->
9090
<exclude>com.google.code.findbugs:jsr305</exclude>
91+
<exclude>jakarta.annotation:jakarta.annotation-api</exclude>
9192
<!-- Leave bouncycastle unshaded because it's signed with a special Oracle certificate so it can be a custom JCE security provider -->
9293
<exclude>org.bouncycastle:*</exclude>
9394
<!-- Leave snappy that includes native methods which cannot be relocated. -->

hadoop-client-modules/hadoop-client-check-invariants/src/test/resources/ensure-jars-have-correct-contents.sh

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,11 @@ allowed_expr+="|^krb5_udp-template.conf$"
7171
allowed_expr+="|^jetty-dir.css$"
7272
# Snappy java is native library. We cannot relocate it to under org/apache/hadoop.
7373
allowed_expr+="|^org/xerial/"
74-
74+
# Comes from jersey, not sure if relocatable.
75+
allowed_expr+="|^jersey"
76+
# Comes from jakarta, not sure if relocatable.
77+
allowed_expr+="|^javax"
78+
allowed_expr+="|^javassist"
7579
allowed_expr+=")"
7680
declare -i bad_artifacts=0
7781
declare -a bad_contents

hadoop-client-modules/hadoop-client-integration-tests/pom.xml

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -86,14 +86,8 @@
8686
<scope>test</scope>
8787
</dependency>
8888
<dependency>
89-
<groupId>javax.xml.bind</groupId>
90-
<artifactId>jaxb-api</artifactId>
91-
<scope>test</scope>
92-
</dependency>
93-
<dependency>
94-
<groupId>javax.activation</groupId>
95-
<artifactId>activation</artifactId>
96-
<version>1.1.1</version>
89+
<groupId>jakarta.xml.bind</groupId>
90+
<artifactId>jakarta.xml.bind-api</artifactId>
9791
<scope>test</scope>
9892
</dependency>
9993
</dependencies>

hadoop-client-modules/hadoop-client-minicluster/pom.xml

Lines changed: 34 additions & 87 deletions
Original file line numberDiff line numberDiff line change
@@ -340,6 +340,10 @@
340340
<groupId>org.ow2.asm</groupId>
341341
<artifactId>asm-commons</artifactId>
342342
</exclusion>
343+
<exclusion>
344+
<groupId>org.ow2.asm</groupId>
345+
<artifactId>asm-commons</artifactId>
346+
</exclusion>
343347
</exclusions>
344348
</dependency>
345349
<!-- Add optional runtime dependency on the in-development timeline server module
@@ -411,72 +415,20 @@
411415
<!-- Skip commons-logging:commons-logging-api because it looks like nothing actually included it -->
412416
<!-- Skip jetty-util because it's in client -->
413417
<dependency>
414-
<groupId>com.sun.jersey</groupId>
415-
<artifactId>jersey-core</artifactId>
418+
<groupId>org.glassfish.jersey.core</groupId>
419+
<artifactId>jersey-common</artifactId>
416420
<optional>true</optional>
417-
<exclusions>
418-
<exclusion>
419-
<groupId>javax.ws.rs</groupId>
420-
<artifactId>jsr311-api</artifactId>
421-
</exclusion>
422-
</exclusions>
423421
</dependency>
424422
<dependency>
425-
<groupId>com.sun.jersey</groupId>
426-
<artifactId>jersey-client</artifactId>
423+
<groupId>org.glassfish.jersey.core</groupId>
424+
<artifactId>jersey-client</artifactId>
427425
<optional>true</optional>
428426
</dependency>
429427
<dependency>
430-
<groupId>com.github.pjfanning</groupId>
431-
<artifactId>jersey-json</artifactId>
432-
<optional>true</optional>
433-
<exclusions>
434-
<exclusion>
435-
<groupId>com.fasterxml.jackson.core</groupId>
436-
<artifactId>jackson-core</artifactId>
437-
</exclusion>
438-
<exclusion>
439-
<groupId>com.fasterxml.jackson.core</groupId>
440-
<artifactId>jackson-databind</artifactId>
441-
</exclusion>
442-
<exclusion>
443-
<groupId>com.fasterxml.jackson.jaxrs</groupId>
444-
<artifactId>jackson-jaxrs-json-provider</artifactId>
445-
</exclusion>
446-
<exclusion>
447-
<groupId>javax.xml.bind</groupId>
448-
<artifactId>jaxb-api</artifactId>
449-
</exclusion>
450-
<exclusion>
451-
<groupId>org.codehaus.jettison</groupId>
452-
<artifactId>jettison</artifactId>
453-
</exclusion>
454-
</exclusions>
455-
</dependency>
456-
<dependency>
457-
<groupId>com.sun.jersey</groupId>
428+
<groupId>org.glassfish.jersey.core</groupId>
458429
<artifactId>jersey-server</artifactId>
459430
<optional>true</optional>
460431
</dependency>
461-
<dependency>
462-
<groupId>com.sun.jersey</groupId>
463-
<artifactId>jersey-servlet</artifactId>
464-
<optional>true</optional>
465-
<exclusions>
466-
<exclusion>
467-
<groupId>javax.servlet</groupId>
468-
<artifactId>servlet-api</artifactId>
469-
</exclusion>
470-
<exclusion>
471-
<groupId>javax.enterprise</groupId>
472-
<artifactId>cdi-api</artifactId>
473-
</exclusion>
474-
<exclusion>
475-
<groupId>ch.qos.cal10n</groupId>
476-
<artifactId>cal10n-api</artifactId>
477-
</exclusion>
478-
</exclusions>
479-
</dependency>
480432
<!-- skip org.apache.avro:avro-ipc because it doesn't look like hadoop-common actually uses it -->
481433
<dependency>
482434
<groupId>net.sf.kosmosfs</groupId>
@@ -620,23 +572,16 @@
620572
</exclusions>
621573
</dependency>
622574
<dependency>
623-
<groupId>com.sun.jersey.jersey-test-framework</groupId>
624-
<artifactId>jersey-test-framework-grizzly2</artifactId>
575+
<groupId>org.glassfish.jersey.test-framework</groupId>
576+
<artifactId>jersey-test-framework-core</artifactId>
625577
<optional>true</optional>
626-
<exclusions>
627-
<!-- excluding because client already has the tomcat version -->
628-
<exclusion>
629-
<groupId>org.glassfish</groupId>
630-
<artifactId>javax.servlet</artifactId>
631-
</exclusion>
632-
</exclusions>
633578
</dependency>
634-
<!-- skipping jersey-server because it's above -->
635579
<dependency>
636-
<groupId>com.sun.jersey.contribs</groupId>
637-
<artifactId>jersey-guice</artifactId>
580+
<groupId>org.glassfish.jersey.test-framework.providers</groupId>
581+
<artifactId>jersey-test-framework-provider-grizzly2</artifactId>
638582
<optional>true</optional>
639583
</dependency>
584+
<!-- skipping jersey-server because it's above -->
640585
<!-- skipping guice-servlet because it's above -->
641586
<!-- skipping avro because it is in client via hadoop-common -->
642587
<!-- skipping jersey-core because it's above -->
@@ -705,6 +650,25 @@
705650
<exclude>org.bouncycastle:*</exclude>
706651
<!-- Leave snappy that includes native methods which cannot be relocated. -->
707652
<exclude>org.xerial.snappy:*</exclude>
653+
<exclude>org.glassfish.jersey.test-framework:*</exclude>
654+
<exclude>org.glassfish.jersey.media:*</exclude>
655+
<exclude>org.glassfish.jersey.containers:*</exclude>
656+
<exclude>org.glassfish.jersey.test-framework.providers:*</exclude>
657+
<exclude>org.glassfish.hk2:*</exclude>
658+
<exclude>org.glassfish.jersey.inject:*</exclude>
659+
<exclude>org.glassfish.grizzly:*</exclude>
660+
<exclude>org.glassfish.jersey.core:*</exclude>
661+
<exclude>org.glassfish.jersey.jettison:*</exclude>
662+
<exclude>org.glassfish.hk2.external:*</exclude>
663+
<exclude>jakarta.ws.rs:*</exclude>
664+
<exclude>jakarta.annotation:*</exclude>
665+
<exclude>jakarta.validation:*</exclude>
666+
<exclude>jakarta.servlet:*</exclude>
667+
<exclude>javax.annotation:*</exclude>
668+
<exclude>org.hamcrest:*</exclude>
669+
<exclude>org.glassfish.jaxb:*</exclude>
670+
<exclude>aopalliance:*</exclude>
671+
<exclude>javassist:*</exclude>
708672
</excludes>
709673
</artifactSet>
710674
<filters>
@@ -725,24 +689,6 @@
725689
<!-- Since runtime has classes for these jars, we exclude them.
726690
We still want the java services api files, since those were excluded in runtime
727691
-->
728-
<filter>
729-
<artifact>com.sun.jersey:jersey-client</artifact>
730-
<excludes>
731-
<exclude>**/*.class</exclude>
732-
</excludes>
733-
</filter>
734-
<filter>
735-
<artifact>com.sun.jersey:jersey-core</artifact>
736-
<excludes>
737-
<exclude>**/*.class</exclude>
738-
</excludes>
739-
</filter>
740-
<filter>
741-
<artifact>com.sun.jersey:jersey-servlet</artifact>
742-
<excludes>
743-
<exclude>**/*.class</exclude>
744-
</excludes>
745-
</filter>
746692
<filter>
747693
<artifact>org.apache.hadoop:hadoop-mapreduce-client-jobclient:*</artifact>
748694
<excludes>
@@ -756,6 +702,7 @@
756702
<excludes>
757703
<exclude>META-INF/versions/9/module-info.class</exclude>
758704
<exclude>META-INF/versions/11/module-info.class</exclude>
705+
<exclude>META-INF/versions/9/javax/xml/bind/ModuleUtil.class</exclude>
759706
</excludes>
760707
</filter>
761708

hadoop-client-modules/hadoop-client-runtime/pom.xml

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@
5858
<dependency>
5959
<groupId>org.apache.hadoop</groupId>
6060
<artifactId>hadoop-client-api</artifactId>
61-
<scope>runtime</scope>
61+
<scope>compile</scope>
6262
</dependency>
6363
<!-- This is the api's compile dependency, but we don't want it to be compile dependency here too. -->
6464
<dependency>
@@ -99,6 +99,7 @@
9999
<artifactId>jsr305</artifactId>
100100
<scope>runtime</scope>
101101
</dependency>
102+
102103
<!-- Move log4j to optional, since it is needed for some pieces folks might not use:
103104
* one of the three custom log4j appenders we have
104105
-->
@@ -159,6 +160,7 @@
159160
<exclude>org.xerial.snappy:*</exclude>
160161
<!-- leave out kotlin classes -->
161162
<exclude>org.jetbrains.kotlin:*</exclude>
163+
<exclude>javassist:*</exclude>
162164
</excludes>
163165
</artifactSet>
164166
<filters>
@@ -184,13 +186,6 @@
184186
<exclude>org/apache/jasper/compiler/Localizer.class</exclude>
185187
</excludes>
186188
</filter>
187-
<!-- We rely on jersey for our web interfaces. We want to use its java services stuff only internal to jersey -->
188-
<filter>
189-
<artifact>com.sun.jersey:*</artifact>
190-
<excludes>
191-
<exclude>META-INF/services/javax.*</exclude>
192-
</excludes>
193-
</filter>
194189
<filter>
195190
<!-- skip french localization -->
196191
<artifact>org.apache.commons:commons-math3</artifact>
@@ -246,6 +241,7 @@
246241
<exclude>META-INF/versions/9/module-info.class</exclude>
247242
<exclude>META-INF/versions/11/module-info.class</exclude>
248243
<exclude>META-INF/versions/21/module-info.class</exclude>
244+
<exclude>META-INF/versions/9/javax/xml/bind/ModuleUtil.class</exclude>
249245
</excludes>
250246
</filter>
251247

0 commit comments

Comments
 (0)