Skip to content

Commit 9a5db23

Browse files
jansupolsenivam
authored andcommitted
JPMS in e2e-server
Signed-off-by: jansupol <[email protected]>
1 parent 3f8c32a commit 9a5db23

File tree

109 files changed

+1397
-323
lines changed

Some content is hidden

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

109 files changed

+1397
-323
lines changed

connectors/helidon-connector/pom.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -178,6 +178,7 @@
178178
<configuration>
179179
<instructions>
180180
<Multi-Release>true</Multi-Release>
181+
<Automatic-Module-Name>org.glassfish.jersey.helidon.connector</Automatic-Module-Name>
181182
</instructions>
182183
</configuration>
183184
</plugin>

connectors/jdk-connector/src/main/java/module-info.java

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,10 +27,18 @@
2727

2828
exports org.glassfish.jersey.jdk.connector;
2929
exports org.glassfish.jersey.jdk.connector.internal to
30+
org.glassfish.jersey.core.client,
3031
org.glassfish.hk2.locator,
31-
org.glassfish.hk2.utilities;
32+
org.glassfish.hk2.utilities,
33+
weld.core.impl;
3234
exports org.glassfish.jersey.jdk.connector.internal.l10n;
3335

3436
opens org.glassfish.jersey.jdk.connector;
37+
opens org.glassfish.jersey.jdk.connector.internal to
38+
org.glassfish.jersey.core.client,
39+
org.glassfish.hk2.locator,
40+
org.glassfish.hk2.utilities,
41+
weld.core.impl;
42+
3543
opens org.glassfish.jersey.jdk.connector.internal.l10n;
3644
}

connectors/jetty-http2-connector/src/test/java/module-info.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2023 Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 2023, 2025 Oracle and/or its affiliates. All rights reserved.
33
*
44
* This program and the accompanying materials are made available under the
55
* terms of the Eclipse Public License v. 2.0, which is available at
@@ -30,6 +30,7 @@
3030
requires org.glassfish.jersey.core.client;
3131
requires org.glassfish.jersey.core.server;
3232
requires org.glassfish.jersey.jetty.connector;
33+
requires org.glassfish.jersey.media.json.jackson;
3334

3435
requires org.junit.jupiter.api;
3536
requires org.hamcrest;

connectors/jnh-connector/src/test/java/module-info.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@
4141
requires org.glassfish.jersey.core.client;
4242
requires org.glassfish.jersey.core.server;
4343
requires org.glassfish.jersey.jnh.connector;
44+
requires org.glassfish.jersey.media.json.jackson;
4445

4546
exports org.glassfish.jersey.jnh.connector.test;
4647
opens org.glassfish.jersey.jnh.connector.test;

connectors/jnh-connector/src/test/java/org/glassfish/jersey/jnh/connector/test/AbstractJavaConnectorTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ public void asyncPostWithTimeout(@QueryParam("timeout") @DefaultValue("10") Long
8989
asyncResponse.setTimeout(timeoutSeconds, TimeUnit.SECONDS);
9090
CompletableFuture.runAsync(() -> {
9191
try {
92-
Thread.sleep(3000);
92+
Thread.sleep(2000);
9393
} catch (InterruptedException e) {
9494
Thread.currentThread().interrupt();
9595
throw new RuntimeException(e);

containers/grizzly2-http/src/main/java/org/glassfish/jersey/grizzly2/httpserver/GrizzlyHttpContainer.java

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2010, 2024 Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 2010, 2025 Oracle and/or its affiliates. All rights reserved.
33
*
44
* This program and the accompanying materials are made available under the
55
* terms of the Eclipse Public License v. 2.0, which is available at
@@ -118,9 +118,11 @@ public GrizzlyResponseReferencingFactory(final Provider<Ref<Response>> reference
118118
* Note that since Grizzly {@code Request} class is not proxiable as it does not expose an empty constructor,
119119
* the injection of Grizzly request instance into singleton JAX-RS and Jersey providers is only supported via
120120
* {@link jakarta.inject.Provider injection provider}.
121+
* <p/>
122+
* Note that since Jersey 4, Grizzly {@code Response} is also supported via
123+
* {@link jakarta.inject.Provider injection provider} only for the java module reasons.
121124
*/
122125
static class GrizzlyBinder extends InternalBinder {
123-
124126
@Override
125127
protected void configure() {
126128
bindFactory(GrizzlyRequestReferencingFactory.class).to(Request.class)
@@ -131,7 +133,7 @@ protected void configure() {
131133
.id(InjectionIds.GRIZZLY_REQUEST.id());
132134

133135
bindFactory(GrizzlyResponseReferencingFactory.class).to(Response.class)
134-
.proxy(true).proxyForSameScope(false).in(RequestScoped.class)
136+
.proxy(false).in(RequestScoped.class)
135137
.id(InjectionIds.GRIZZLY_RESPONSE_REFERENCING_FACTORY.id());
136138
bindFactory(ReferencingFactory.<Response>referenceFactory()).to(new GenericType<Ref<Response>>() {})
137139
.in(RequestScoped.class)

containers/helidon/pom.xml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,16 @@
9191
<artifactId>build-helper-maven-plugin</artifactId>
9292
<inherited>true</inherited>
9393
</plugin>
94+
<plugin>
95+
<groupId>org.apache.felix</groupId>
96+
<artifactId>maven-bundle-plugin</artifactId>
97+
<inherited>true</inherited>
98+
<configuration>
99+
<instructions>
100+
<Automatic-Module-Name>org.glassfish.jersey.container.helidon</Automatic-Module-Name>
101+
</instructions>
102+
</configuration>
103+
</plugin>
94104
</plugins>
95105

96106
<resources>

containers/jersey-servlet/src/main/java/module-info.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,11 @@
3434
exports org.glassfish.jersey.servlet;
3535

3636
opens org.glassfish.jersey.servlet;
37+
opens org.glassfish.jersey.servlet.async;
38+
opens org.glassfish.jersey.servlet.init;
39+
opens org.glassfish.jersey.servlet.internal.spi;
3740
opens org.glassfish.jersey.servlet.internal.l10n;
41+
opens org.glassfish.jersey.servlet.spi;
3842

3943
uses org.glassfish.jersey.servlet.spi.AsyncContextDelegate;
4044
uses org.glassfish.jersey.servlet.spi.AsyncContextDelegateProvider;

containers/jersey-servlet/src/main/java/org/glassfish/jersey/servlet/WebComponent.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
import jakarta.ws.rs.core.SecurityContext;
3636
import org.glassfish.jersey.innate.inject.InjectionIds;
3737
import org.glassfish.jersey.innate.inject.InternalBinder;
38-
import org.glassfish.jersey.innate.inject.ServiceFinderBinder;
38+
import org.glassfish.jersey.internal.ServiceFinderBinder;
3939
import org.glassfish.jersey.innate.io.InputStreamWrapper;
4040
import org.glassfish.jersey.internal.inject.InjectionManager;
4141
import org.glassfish.jersey.internal.inject.Providers;

core-client/pom.xml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,6 @@
3939
--add-exports org.glassfish.jersey.core.common/org.glassfish.jersey.innate.virtual=ALL-UNNAMED
4040
--add-exports org.glassfish.jersey.core.common/org.glassfish.jersey.innate.io=ALL-UNNAMED
4141
--add-exports org.glassfish.jersey.core.common/org.glassfish.jersey.innate.inject=ALL-UNNAMED
42-
--add-modules=ALL-MODULE-PATH
4342
</surefire.coverage.argline>
4443
</properties>
4544

0 commit comments

Comments
 (0)