-
Notifications
You must be signed in to change notification settings - Fork 2.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #27925 from Sgitario/rr_ssl
Resteasy Rest Client: Fix truststore password issue with Vert.x
- Loading branch information
Showing
9 changed files
with
95 additions
and
8 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
15 changes: 15 additions & 0 deletions
15
...ive/src/main/java/io/quarkus/it/rest/client/main/selfsigned/ExternalSelfSignedClient.java
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
package io.quarkus.it.rest.client.main.selfsigned; | ||
|
||
import javax.ws.rs.GET; | ||
import javax.ws.rs.core.Response; | ||
|
||
import org.eclipse.microprofile.faulttolerance.Retry; | ||
import org.eclipse.microprofile.rest.client.inject.RegisterRestClient; | ||
|
||
@RegisterRestClient(baseUri = "https://self-signed.badssl.com/", configKey = "self-signed") | ||
public interface ExternalSelfSignedClient { | ||
|
||
@GET | ||
@Retry(delay = 1000) | ||
Response invoke(); | ||
} |
5 changes: 4 additions & 1 deletion
5
integration-tests/rest-client-reactive/src/main/resources/application.properties
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,7 @@ | ||
w-exception-mapper/mp-rest/url=${test.url} | ||
w-fault-tolerance/mp-rest/url=${test.url} | ||
io.quarkus.it.rest.client.main.ParamClient/mp-rest/url=${test.url} | ||
io.quarkus.it.rest.client.multipart.MultipartClient/mp-rest/url=${test.url} | ||
io.quarkus.it.rest.client.multipart.MultipartClient/mp-rest/url=${test.url} | ||
# HTTPS | ||
quarkus.rest-client.self-signed.trust-store=${self-signed.trust-store} | ||
quarkus.rest-client.self-signed.trust-store-password=${self-signed.trust-store-password} |
21 changes: 21 additions & 0 deletions
21
...active/src/test/java/io/quarkus/it/rest/client/selfsigned/ExternalSelfSignedTestCase.java
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
package io.quarkus.it.rest.client.selfsigned; | ||
|
||
import static io.restassured.RestAssured.when; | ||
import static org.hamcrest.Matchers.is; | ||
|
||
import org.junit.jupiter.api.Test; | ||
|
||
import io.quarkus.test.junit.QuarkusTest; | ||
|
||
@QuarkusTest | ||
public class ExternalSelfSignedTestCase { | ||
|
||
@Test | ||
public void should_accept_self_signed_certs() { | ||
when() | ||
.get("/self-signed") | ||
.then() | ||
.statusCode(200) | ||
.body(is("200")); | ||
} | ||
} |