Java – cannot reserve heap space
•
Java
I am using soap UI 5.0 0 open source I'm running soapUI testcases through ant to get JUnit reports
build. XML file:
<project basedir="." default="testreport" name="FCMRestAPIAutomation">
<target name="SoapUI">
<exec dir="." executable="C:\Program Files (x86)\SmartBear\SoapUI-5.0.0\bin\testrunner.bat">
<arg line="-r -j -o -f 'C:\Users\sn3020722\Desktop\Notification\New folder' -sFirstLoginTest 'C:\Users\sn3020722\Desktop\Notification\New folder\FCM Project.xml'"></arg>
</exec>
</target>
<target name="testreport" depends="SoapUI">
<junitreport todir="C:\Users\sn3020722\Desktop\Notification\New folder\API">
<fileset dir="C:\Users\sn3020722\Desktop\Notification\New folder\API">
<include name="TEST-*.xml"/>
</fileset>
<report format="frames" todir="C:\Users\sn3020722\Desktop\Notification\New folder\reports\html">
</report>
</junitreport>
</target>
</project>
Error at command prompt:
SoapUI:
[exec] Error: Could not create the Java Virtual Machine.
[exec] Error occurred during initialization of VMError: A fatal exception h
as occurred. Program will exit.
[exec]
[exec] Could not reserve enough space for object heap
[exec] Result: 1
testreport:
[junitreport] Processing C:\Users\sn3020722\Desktop\Notification\New folder\API\TESTS-TestSuites.xml to C:\Users\sn3020722\AppData\Local\Temp\null913190532
[junitreport] Loading stylesheet jar:file:/D:/eclipse/plugins/org.apache.ant_1.8
.3.v201301120609/lib/ant-junit.jar!/org/apache/tools/ant/taskdefs/optional/junit
/xsl/junit-frames.xsl
[junitreport] Transform time: 312ms
[junitreport] Deleting: C:\Users\sn20722\AppData\Local\Temp\null913190532
I added the following to the system environment variable
_JAVA_OPTIONS: -Xmx2048MB
But I still face other problems. SoapUI itself is not opened in the allocated space Any suggestions to solve the space problem?
Solution
SoapUI 5.0.0 for windows was downloaded 0 package, I found in the file testunner Bat has the configuration in line 31:
set JAVA_OPTS=-Xms128m -Xmx1024m -Dsoapui.properties=soapui.properties "-Dsoapui.home=%sOAPUI_HOME%\"
As you can see, the maximum memory parameter is set to 1024m (- xmx1024m) You can change it to 2048 meters in your file and try again
The content of this article comes from the network collection of netizens. It is used as a learning reference. The copyright belongs to the original author.
THE END
二维码
