Forum Discussion

newMonk's avatar
newMonk
Occasional Contributor
9 years ago

java.lang.OutOfMemoryError: Java heap space error?

Hi,

How do i solve java.lang.OutOfMemoryError: Java heap space error? . I have tried increasing the JVM Launch Configuration too. Thanks.

  • fredsvar's avatar
    fredsvar
    SmartBear Alumni (Retired)

    Hi, 

     

    Are you running a 32-bit or 64-bit application? And on which platform (Mac, Windows, Linux)? 


    newMonk wrote:

    I have tried increasing the JVM Launch Configuration too. 


    Also, it would be helpful if you could paste the changes you have done here. 

     

    Regards, 

     

    Fredrik

    ps.

    There are some good pointers here: http://readyapi.smartbear.com/soapui/working/improving_memory_usage and on the pages linked from there.

    • NewAutoTester's avatar
      NewAutoTester
      Contributor

      Hi,

      I still get the java.lang.OutOfMemoryError: Java heap space even after updating JVM Options. 

      export _JAVA_OPTIONS="-Xms4096m -Xmx4096m -XX:NewSize=256m -XX:MaxNewSize=356m -XX:PermSize=256m -XX:MaxPermSize=356m"

       

      ERROR:

      Scenario Outline: Check for xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
      Given Prepare a transaction request for "xxxxxxxxxxxxxxxx" with setup user role as "xxxxxxxxx" transaction # StepDefinition.prepare_Transaction_Request(String,String)
      java.lang.OutOfMemoryError
      at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
      at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
      at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
      at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
      at java.util.concurrent.ForkJoinTask.getThrowableException(ForkJoinTask.java:598)
      at java.util.concurrent.ForkJoinTask.reportException(ForkJoinTask.java:677)
      at java.util.concurrent.ForkJoinTask.invoke(ForkJoinTask.java:735)
      at java.util.stream.ForEachOps$ForEachOp.evaluateParallel(ForEachOps.java:158)
      at java.util.stream.ForEachOps$ForEachOp$OfRef.evaluateParallel(ForEachOps.java:174)
      at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:233)
      at java.util.stream.ReferencePipeline.forEachOrdered(ReferencePipeline.java:423)
      at java.util.stream.ReferencePipeline$Head.forEachOrdered(ReferencePipeline.java:593)
      at com.eviware.soapui.impl.support.loadsave.CompositeProjects.c(CompositeProjects.java:498)
      at com.eviware.soapui.impl.support.loadsave.CompositeProjects.loadCompositeProjectFile(CompositeProjects.java:199)
      at com.eviware.soapui.impl.support.wsdl.UrlWsdlLoaderPro.a(UrlWsdlLoaderPro.java:35)
      at com.eviware.soapui.impl.support.wsdl.UrlWsdlLoaderPro.handleFile(UrlWsdlLoaderPro.java:27)
      at com.eviware.soapui.impl.wsdl.support.wsdl.UrlClientLoader.load(UrlClientLoader.java:149)
      at com.eviware.soapui.impl.wsdl.support.wsdl.UrlClientLoader.load(UrlClientLoader.java:127)
      at com.eviware.soapui.impl.wsdl.support.wsdl.UrlClientLoader.load(UrlClientLoader.java:118)
      at com.eviware.soapui.impl.wsdl.WsdlProjectPro.b(WsdlProjectPro.java:629)
      at com.eviware.soapui.impl.wsdl.WsdlProjectPro.loadProject(WsdlProjectPro.java:421)
      at com.eviware.soapui.impl.wsdl.WsdlProject.<init>(WsdlProject.java:314)
      at com.eviware.soapui.impl.wsdl.WsdlProject.<init>(WsdlProject.java:293)
      at com.eviware.soapui.impl.wsdl.WsdlProject.<init>(WsdlProject.java:288)
      at com.eviware.soapui.impl.wsdl.WsdlProjectPro.<init>(WsdlProjectPro.java:208)
      at com.stepDefinition.prepare_Transaction_Request(StepDefinition.java:76)
      at ?.Given Prepare a transaction request for "xxxxxxxxxxxxxxxx" with setup user role as "xxxxxxxxx" transaction(xxxxxxxxx.feature:20)
      Caused by: java.lang.OutOfMemoryError: Java heap space

       

      Could you please help.