spring-cloud-contract icon indicating copy to clipboard operation
spring-cloud-contract copied to clipboard

Change com.github.tomakehurst:wiremock-jre8-standalone coordinates to allow migration to version 3.0.0+

Open helpermethod opened this issue 2 years ago • 10 comments

With Wiremock 3.0.0, groupId and artifactId have changed from

com.github.tomakehurst:wiremock-jre8-standalone

to

org.wiremock:wiremock-standalone

By adapting the coordinates, you should still get automated dependency updates.

I can provide a PR if applicable.

helpermethod avatar Sep 01 '23 07:09 helpermethod

Hey, have the packages changed too? Cause if they did that's a breaking change.

marcingrzejszczak avatar Sep 01 '23 08:09 marcingrzejszczak

At least not yet, though some APIs have been deprecated

https://github.com/wiremock/wiremock/tree/master/src/main/java/com/github/tomakehurst/wiremock

helpermethod avatar Sep 01 '23 08:09 helpermethod

Ah, but a few classes have been moved, like

https://github.com/wiremock/wiremock/tree/master/src/main/java/com/github/tomakehurst/wiremock/extension/ResponseTemplateTransformer.java

to

https://github.com/wiremock/wiremock/tree/master/src/main/java/com/github/tomakehurst/wiremock/extension/responsetemplating/ResponseTemplateTransformer.java

And the instantiation of ResponseTemplateTransformer changed

https://github.com/wiremock/wiremock/issues/2349

helpermethod avatar Sep 01 '23 08:09 helpermethod

I see. I'll have to think about it but actually we could theoretically support both versions. These are 2 separate jars, we can have 2 different conditionals on classes etc. Do we know if the stub JSON produced by WireMock 3 is compatible with WireMock 2 ?

marcingrzejszczak avatar Sep 01 '23 08:09 marcingrzejszczak

According to the docs the JSON output/API should be the same.

helpermethod avatar Sep 01 '23 18:09 helpermethod

Doesn't spring-cloud-contract package Wiremock? So upgrading to the lastest version should be transparent to the user, right?

helpermethod avatar Sep 04 '23 07:09 helpermethod

We're in touch with @oleg-nenashev to add support for WireMock 3. We'll keep everyone posted in this issue

marcingrzejszczak avatar Sep 05 '23 16:09 marcingrzejszczak

The upgrade is expected to be mostly transparent, but we need to do some integration testing. The update is unlikely to be just a dependency groupId and artifactId change, we have quite a lot of API changes

oleg-nenashev avatar Sep 05 '23 19:09 oleg-nenashev

I just want to pass by to mention that CVE-2023-44487 is currently impacting the 2.x version (even if it is not exploitable given that this is a test dependency) .

See https://blog.cloudflare.com/technical-breakdown-http2-rapid-reset-ddos-attack/

yeikel avatar Nov 20 '23 15:11 yeikel

The upgrade is expected to be mostly transparent, but we need to do some integration testing. The update is unlikely to be just a dependency groupId and artifactId change, we have quite a lot of API changes

Just wondering, is the way forward still dependent on some new integration tests on the wiremock side? I'm also happy to contribute to get this moving.

nhomble avatar Jul 23 '24 16:07 nhomble