Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

java.lang.OutOfMemoryError: Java heap space on Maven build step with testcontainers

Jelena Bunčić
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
February 29, 2024

I have error java.lang.OutOfMemoryError: Java heap space, when step maven build run. I have testcontainer and use postgres image. Some tests pass but in one moment error is java.lang.OutOfMemoryError: Java heap space.
I try to set in definitions

services:
docker-with-large-memory:
memory: 5120
type: docker

and then in my step for build maven set

size: 2x
services:
- docker-with-large-memory

but it doesn't work. Can anybody now what i need to do?

1 answer

1 accepted

1 vote
Answer accepted
Nic Brough -Adaptavist-
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
February 29, 2024

Welcome to the Atlassian Community!

You will need to either increase the maximum size of the heap, or look into your build process to see what is consuming so much memory.

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
TAGS
AUG Leaders

Atlassian Community Events