eclipse / microprofile-rest-client

MicroProfile Rest Client
Apache License 2.0
143 stars 72 forks source link

Jakarta EE 9.1 alignment #316

Closed Emily-Jiang closed 2 years ago

Emily-Jiang commented 3 years ago

For each spec, the following updates need to happen, refer this doc for instructions:

Emily-Jiang commented 3 years ago

@andymc12 I saw your PR, which does not use the parent pom. One of the goals is to move to parent pom.xml to control the plugins. Will you be able to adopt the parent pom.xml? I don't think updating checkstyle is show stopper though. We have to do it at one point. Now it's a good time, I think.

jansupol commented 3 years ago

Update all javax to jakarta for all java files import javax. needs to be updated to jakarta.: find . -type f -name '*.java' -exec sed -i '' s/javax./jakarta./ {} +

Not done yet, for instance:

andymc12 commented 3 years ago

Hi @jansupol,

Are these non-changes causing you problems? The reason I ask is that they were intentionally left at javax because they are used as part of the mocked server framework that tests the MP Rest Client implementation. The WireMock server implementation is built on Jetty, which (afaik) does not yet have a EE9 / Servlet 5 implementation.

We should be fine to use an EE8 server implementation to verify that MP Rest Client requests are properly formed. That said, I'm in favor of upgrading our test dependencies as soon as an EE9 version is available. HTH

rdebusscher commented 3 years ago

Jetty 11 uses Jakarta namespace and Servlet 5.0 https://www.eclipse.org/jetty/download.php. So there is no need to stay on older versions.

andymc12 commented 3 years ago

AFAICT, the latest versions of WireMock still use Jetty 9.X. I haven't tried it myself, but I think if we upgrade to Jetty 11, we'll break WireMock. I don't have the cycles to test this out before we want to release MP Rest Client 3.0, but @rdebusscher or @jansupol, I'd take a PR if you want to verify that it works. Thanks.

rdebusscher commented 3 years ago

Correct. Sorry, I was a bit too fast in replying that Jetty 11 could be used as the restricting factor is WireMock.

jansupol commented 3 years ago

The Wiremock depends just on the Jetty API, which is the same for Jetty 9 and Jetty 11. I can provide a PR for the WireMock to use Jetty 11. Jetty 11, however, requires JDK 11 and it does not work on JDK 8. @andymc12 What's the minimum JDK for MP Rest Client 3.0?

andymc12 commented 3 years ago

Hi @jansupol - thanks for the offer, but I checked with @Emily-Jiang on the JDK levels. It sounds like we need to still support Java 8 with MP 5.0 / Rest Client 3.0. Or rather, implementors must be allowed to pass the TCK on Java 8. I think that we might need to defer this until the next release.