0

I have a little problem with my Jenkins heap. I am now running with the number of tests out of memory. At the moment it tells me, that the Jenkins have a heap space of 485MB but I would like to increase it to 1GB or 2GB. I have already tried to increase the heap of my Jenkins by adding the following in the Jenkins file:

environment {
        MAVEN_OPTS = '-Xmx2048m -XX:MaxPermSize=2048m'
    }

and also in the pom.xml I added the following to the Surefire plugin:

<groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-surefire-plugin</artifactId>
            <version>2.22.1</version>
            <configuration>
                <argLine>-Xmx2048m</argLine>
                <argLine>-XX:MaxPermSize=2048m</argLine>
            </configuration>

Locally it tells me that the heap has been increased by the value entered, but when I run the tests on the jenkins, the heap size has not increased.

Am I missing something or doing something wrong?

EDIT: Local it works fine but on the Jenkins the error occurs.

Gregor
  • 239
  • 1
  • 2
  • 10

0 Answers0