Garbage collection is not happening in docker container level

Deployed the spring boot (v2.1.3) application in docker (20.10) as container and running load test to verify our application. Java version is 8; Docker Image: azul/zulu-openjdk-alpine:8-jre

Please find the stats before load test, at time of load test and after load test.

::: Before Load test

ID NAME CPU % MEM USAGE / LIMIT MEM % NET I/O BLOCK I/O
c-id CONTAINER_NAME 3.22% 583MiB / 31.36GiB 1.82% 24.6kB / 13.7kB 0B / 0B

:::at time of load test

ID NAME CPU % MEM USAGE / LIMIT MEM % NET I/O BLOCK I/O
c-id CONTAINER_NAME 0.14% 1.223GiB / 31.36GiB 3.90% 47.9MB / 675MB 0B / 65.5kB

:::after load test:::

ID NAME CPU % MEM USAGE / LIMIT MEM % NET I/O BLOCK I/O
c-id CONTAINER_NAME 0.09% 1.3GiB / 31.36GiB 4.15% 115MB / 675MB 0B / 8.77MB

Memory for the container is keep on increasing. its not all coming to normal even after completing the load test. ie. Garbage collection is not happening in docker container. (whereas garbage collection is happening when the same application deployed in Windows environment)

Are there any configuration to reduce the memory after load test.

Can anyone of you help me on that.

The “Tips & howTos” category is for sharing tips and howtos, not for questions. I would move the topic to a better category, but I am not sure how you use Docker. You added swarm and docker-compose to the tags. Do you run the containers on Swarm?

The image you mentioned is for Linux containers. Do you mean you tried the aplication without containers directly on Windows?