Skip to content

Commit

Permalink
merge of the actual master into 3.x branch
Browse files Browse the repository at this point in the history
  • Loading branch information
senivam authored Mar 29, 2023
2 parents eda8122 + 785d032 commit b6cda06
Show file tree
Hide file tree
Showing 411 changed files with 764 additions and 510 deletions.
2 changes: 1 addition & 1 deletion archetypes/jersey-example-java8-webapp/pom.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2015, 2022 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2015, 2023 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0, which is available at
Expand Down
2 changes: 1 addition & 1 deletion archetypes/jersey-heroku-webapp/pom.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2013, 2022 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2013, 2023 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0, which is available at
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -101,12 +101,19 @@
<war>\${project.build.directory}/\${project.build.finalName}.war</war>
</configuration>
</plugin>
<plugin>
<!-- Surefire support for JUnit-5 -->
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>${surefire.mvn.plugin.version}</version>
</plugin>
</plugins>
</build>

<properties>
<jersey.version>${project.version}</jersey.version>
<jetty.version>11.0.14</jetty.version>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<jetty.version>11.0.0.beta3</jetty.version>
<surefire.mvn.plugin.version>3.0.0-M7</surefire.mvn.plugin.version>
</properties>
</project>
2 changes: 1 addition & 1 deletion archetypes/jersey-quickstart-grizzly2/pom.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2010, 2022 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2010, 2023 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0, which is available at
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,12 +72,19 @@
<mainClass>\${package}.Main</mainClass>
</configuration>
</plugin>
<plugin>
<!-- Surefire support for JUnit-5 -->
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>${surefire.mvn.plugin.version}</version>
</plugin>
</plugins>
</build>

<properties>
<jersey.version>${project.version}</jersey.version>
<junit-jupiter.version>5.9.1</junit-jupiter.version>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<surefire.mvn.plugin.version>3.0.0-M7</surefire.mvn.plugin.version>
</properties>
</project>
2 changes: 1 addition & 1 deletion archetypes/jersey-quickstart-webapp/pom.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2010, 2022 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2010, 2023 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0, which is available at
Expand Down
2 changes: 1 addition & 1 deletion archetypes/pom.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2010, 2022 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2010, 2023 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0, which is available at
Expand Down
2 changes: 1 addition & 1 deletion bom/pom.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2013, 2022 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2013, 2023 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0, which is available at
Expand Down
2 changes: 1 addition & 1 deletion bundles/examples/pom.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2013, 2022 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2013, 2023 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0, which is available at
Expand Down
2 changes: 1 addition & 1 deletion bundles/jaxrs-ri/pom.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2012, 2022 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2012, 2023 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0, which is available at
Expand Down
2 changes: 1 addition & 1 deletion bundles/pom.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2012, 2022 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2012, 2023 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0, which is available at
Expand Down
2 changes: 1 addition & 1 deletion connectors/apache5-connector/pom.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0"?>
<!--
Copyright (c) 2022 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2022, 2023 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0, which is available at
Expand Down
2 changes: 1 addition & 1 deletion connectors/grizzly-connector/pom.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0"?>
<!--
Copyright (c) 2011, 2022 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2011, 2023 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0, which is available at
Expand Down
2 changes: 1 addition & 1 deletion connectors/helidon-connector/pom.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2020, 2022 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2020, 2023 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0, which is available at
Expand Down
2 changes: 1 addition & 1 deletion connectors/jdk-connector/pom.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0"?>
<!--
Copyright (c) 2011, 2022 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2011, 2023 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0, which is available at
Expand Down
2 changes: 1 addition & 1 deletion connectors/jetty-connector/pom.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0"?>
<!--
Copyright (c) 2011, 2022 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2011, 2023 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0, which is available at
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2013, 2022 Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2013, 2023 Oracle and/or its affiliates. All rights reserved.
*
* This program and the accompanying materials are made available under the
* terms of the Eclipse Public License v. 2.0, which is available at
Expand Down Expand Up @@ -159,7 +159,7 @@ class JettyConnector implements Connector {
}
if (httpClient == null) {
final SSLContext sslContext = jaxrsClient.getSslContext();
final SslContextFactory.Client sslContextFactory = new SslContextFactory.Client();
final SslContextFactory.Client sslContextFactory = new SslContextFactory.Client(false);
sslContextFactory.setSslContext(sslContext);
final ClientConnector connector = new ClientConnector();
connector.setSslContextFactory(sslContextFactory);
Expand All @@ -170,8 +170,12 @@ class JettyConnector implements Connector {

Boolean enableHostnameVerification = (Boolean) config.getProperties()
.get(JettyClientProperties.ENABLE_SSL_HOSTNAME_VERIFICATION);
if (enableHostnameVerification != null && enableHostnameVerification) {
client.getSslContextFactory().setEndpointIdentificationAlgorithm("https");
if (enableHostnameVerification != null) {
final String verificationAlgorithm = enableHostnameVerification ? "HTTPS" : null;
client.getSslContextFactory().setEndpointIdentificationAlgorithm(verificationAlgorithm);
}
if (jaxrsClient.getHostnameVerifier() != null) {
client.getSslContextFactory().setHostnameVerifier(jaxrsClient.getHostnameVerifier());
}

final Object connectTimeout = config.getProperties().get(ClientProperties.CONNECT_TIMEOUT);
Expand Down
2 changes: 1 addition & 1 deletion connectors/netty-connector/pom.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0"?>
<!--
Copyright (c) 2016, 2022 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2016, 2023 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0, which is available at
Expand Down
2 changes: 1 addition & 1 deletion connectors/pom.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2011, 2022 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2011, 2023 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0, which is available at
Expand Down
2 changes: 1 addition & 1 deletion containers/glassfish/jersey-gf-ejb/pom.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2012, 2022 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2012, 2023 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0, which is available at
Expand Down
2 changes: 1 addition & 1 deletion containers/glassfish/pom.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2012, 2022 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2012, 2023 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0, which is available at
Expand Down
2 changes: 1 addition & 1 deletion containers/grizzly2-http/pom.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2011, 2022 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2011, 2023 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0, which is available at
Expand Down
2 changes: 1 addition & 1 deletion containers/grizzly2-servlet/pom.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2012, 2022 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2012, 2023 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0, which is available at
Expand Down
2 changes: 1 addition & 1 deletion containers/jdk-http/pom.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2010, 2022 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2010, 2023 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0, which is available at
Expand Down
2 changes: 1 addition & 1 deletion containers/jersey-servlet-core/pom.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2012, 2022 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2012, 2023 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0, which is available at
Expand Down
2 changes: 1 addition & 1 deletion containers/jersey-servlet/pom.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2012, 2022 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2012, 2023 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0, which is available at
Expand Down
2 changes: 1 addition & 1 deletion containers/jetty-http/pom.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2013, 2022 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2013, 2023 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0, which is available at
Expand Down
2 changes: 1 addition & 1 deletion containers/jetty-servlet/pom.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2012, 2022 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2012, 2023 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0, which is available at
Expand Down
2 changes: 1 addition & 1 deletion containers/netty-http/pom.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2016, 2022 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2016, 2023 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0, which is available at
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2016, 2020 Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2016, 2023 Oracle and/or its affiliates. All rights reserved.
*
* This program and the accompanying materials are made available under the
* terms of the Eclipse Public License v. 2.0, which is available at
Expand Down Expand Up @@ -105,7 +105,7 @@ public synchronized OutputStream writeResponseStatusAndHeaders(long contentLengt

if (contentLength == -1) {
HttpUtil.setTransferEncodingChunked(response, true);
} else {
} else if (req.method() != HttpMethod.HEAD || !response.headers().contains(HttpHeaderNames.CONTENT_LENGTH)) {
response.headers().set(HttpHeaderNames.CONTENT_LENGTH, contentLength);
}

Expand Down
2 changes: 1 addition & 1 deletion containers/pom.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2011, 2022 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2011, 2023 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0, which is available at
Expand Down
2 changes: 1 addition & 1 deletion containers/simple-http/pom.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2011, 2022 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2011, 2023 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0, which is available at
Expand Down
2 changes: 1 addition & 1 deletion core-client/pom.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2011, 2022 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2011, 2023 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0, which is available at
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
import jakarta.ws.rs.ConstrainedTo;
import jakarta.ws.rs.RuntimeType;
import jakarta.ws.rs.WebApplicationException;
import jakarta.ws.rs.core.Context;
import jakarta.ws.rs.core.MediaType;
import jakarta.ws.rs.core.MultivaluedMap;
import jakarta.ws.rs.ext.MessageBodyReader;
Expand All @@ -47,8 +48,8 @@ class ChunkedInputReader implements MessageBodyReader<ChunkedInput> {
private final Provider<PropertiesDelegate> propertiesDelegateProvider;

@Inject
public ChunkedInputReader(Provider<MessageBodyWorkers> messageBodyWorkers,
Provider<PropertiesDelegate> propertiesDelegateProvider) {
public ChunkedInputReader(@Context Provider<MessageBodyWorkers> messageBodyWorkers,
@Context Provider<PropertiesDelegate> propertiesDelegateProvider) {
this.messageBodyWorkers = messageBodyWorkers;
this.propertiesDelegateProvider = propertiesDelegateProvider;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@

import jakarta.ws.rs.client.ClientRequestContext;
import jakarta.ws.rs.client.ClientRequestFilter;
import jakarta.ws.rs.core.Context;
import jakarta.ws.rs.core.HttpHeaders;

import jakarta.inject.Inject;
Expand Down Expand Up @@ -54,7 +55,7 @@ public final class EncodingFilter implements ClientRequestFilter {
private volatile List<Object> supportedEncodings = null;

@Inject
public EncodingFilter(InjectionManager injectionManager) {
public EncodingFilter(@Context InjectionManager injectionManager) {
this.injectionManager = injectionManager;
}

Expand Down
Loading

0 comments on commit b6cda06

Please sign in to comment.