Hi everyone, I am running wiremock in playback mod...
# help
r
Hi everyone, I am running wiremock in playback mode where I use the data ( mappings and __files ) which I recorded by running wiremock in recording mode. When my wiremock instance is running in playback mode with recorded data I am noticing that after sometime my wiremock instance ( pod ) throws Java OOM exception. I tried increasing the memory but it only delays the outcome but doesn't stop it. Here are some settings ( image: wiremock/wiremock:3.3.1, JAVA_TOOL_OPTIONS: "-XX:+UseContainerSupport -Xms1g -Xmx8g", WIREMOCK_DISABLE_REQUEST_JOURNAL: "true" etc etc. ). Any idea what I may be missing or how to fix this issue of Java OOM?
l
How long are you running your container for out of interest ? Would it be possible to list all the option you are using when starting WireMock. disabling the request journal is a good idea for long lived containers but would be good to know what the
etc etc
part is. Also, is there any reason why you are using version
3.3.1
and not the latest?
Also, looking at your settings, where are you getting the
WIREMOCK_DISABLE_REQUEST_JOURNAL: "true"
part from ? I am not sure I have seen that before. Perhaps it might be worth trying
WIREMOCK_OPTIONS
instead. This is documented on the Running in Docker page
r
Hi @Lee Turner thanks for your response. I can try Latest also but I am quite sure I will see the same behavior. I have used some other version also and that also ended up with Java OOM after a while. I am seeing this after 30 to 40 minutes. WIREMOCK_DISABLE_REQUEST_JOURNAL I probably picked from google search or chat gpt but looks like it doesn't do anything
l
If you are not pinned to
3.3.1
for any particular reason, might as well use the latest
3.13.1
or even one of the
4.x
beta releases if you want to be on the cutting edge šŸ™‚ In terms of
WIREMOCK_DISABLE_REQUEST_JOURNAL
I think you are correct in that it doesn't do anything so I would drop that. It sounds like something AI would come up with šŸ™‚ I would move to configuring it as per the Docker page on the OSS docs site - https://wiremock.org/docs/standalone/docker/ The options you want to try out are: •
--no-request-journal
•
--disable-request-logging
•
--max-template-cache-entries <some low number>
•
--async-response-enabled
You can find all of these options and how to use them detailed on this page - https://wiremock.org/docs/standalone/java-jar/
r
Ok, thanks. I will try with these options over the weekend and let you know if it still doesn't fix the issue. Appreciate your help and guidance
šŸ‘ 1