This is not happening in Record and playback mode (proxy request to the destination). It fails before hitting stub.
t
Tom
08/12/2023, 2:53 PM
Hi @Jackie chen thanks for flagging this. It looks like this is probably a bug, so please could you raise an issue in GitHub with the repro steps?
j
Jackie chen
08/12/2023, 10:25 PM
@Tom I have raised the issue in the GitHub wit the repro steps https://github.com/wiremock/wiremock/issues/2313. Could you please also fix this bug in wiremock-jre 2.33.2? as i have been using java 8. Thank you.
t
Tom
08/14/2023, 10:32 AM
Thanks for raising this @Jackie chen. Unfortunately we’re not doing any more releases of 2.x now as we can’t update a number of key dependencies due to their being Java 11+, and consequently we get a flurry of security scanner/CVE errors sent our way if we attempt it.
There is now a Testcontainers (Docker) edition of WireMock 3.x which will work with Java 8, so it might be worth trying this out once we’ve shipped the fix.
j
Jackie chen
08/14/2023, 10:45 AM
Hi @Tom i am using wiremock-jre8 2.33.2 in my maven springboot project, which is compatible with Java 8. is there a way to include WireMock 3.x in my maven project that is still compatible with Java 8?
t
Tom
08/14/2023, 11:12 AM
Not by directly adding it to your dependencies, but you can do it by running the WireMock 3.x server via Testcontainers (which at the moment does still support Java 😎.
j
Jackie chen
08/14/2023, 12:02 PM
@Tom i got it. is there a workaround on this issue? i tried using StubRequestFilter to change the non-utf8 encoding parameter but the exception is still thrown, i would like it to match stub data somehow.