Mailing list - Entries of 2005

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [qftestJUI] Setting the xmx and xms parameters in the qftest GUI

  • Subject: Re: [qftestJUI] Setting the xmx and xms parameters in the qftest GUI
  • From: Karlheinz Kellerer <Karlheinz.Kellerer@?.de>
  • Date: Tue, 15 Mar 2005 08:37:02 -0000

Hi Shlomit,

"Shlomit Becker" <Shlomit.Becker@?.com> writes:

>    Hi - when running the qftestJUI GUI is there a way for me to set the
>    java xmx and xms parameters? Is there a file to set this in?

for qftestJUI you can set those memory parameters via the commandline arguments
-J-Xmx and -J-Xms, e.g. -J-Xmx256m sets the max Java VM heap size to 256 MB.
In general you can pass arguments to the Java VM by using the -J prefix. This
is also described in chapter "Chapter 16  Command line arguments and exit
codes" in the technical reference.

If you want to set a memory size for the VM of the SUT, you can do this by
adding e.g. -Xmx128m to the program parameter list in the "Start Java SUT
client" node.

I also post a small jython script here, which may be helpful to check memory
settings and usage. It needs to be put in a server script node monitoring
qftestJUI's VM or in a SUT script node for the SUT VM.

from java.lang import Runtime

r = Runtime.getRuntime()
max = r.maxMemory() /1024
total = r.totalMemory() / 1024
free = r.freeMemory() / 1024
used = (total - free)
rc.logMessage("Memory max: %dkB" % max)
rc.logMessage("Memory total: %dkB" % total)
rc.logMessage("Memory usage: %dkB" % used)
print "Memory max: %dkB" % max
print "Memory total: %dkB" % total
print "Memory usage: %dkB" % used

Best regards,

Karlheinz Kellerer                     Karlheinz.Kellerer@?.de
Quality First Software GmbH