summaryrefslogtreecommitdiff
path: root/cpp/config/TestUtil.py
diff options
context:
space:
mode:
Diffstat (limited to 'cpp/config/TestUtil.py')
-rw-r--r--cpp/config/TestUtil.py16
1 files changed, 14 insertions, 2 deletions
diff --git a/cpp/config/TestUtil.py b/cpp/config/TestUtil.py
index 1c101f392cd..e55b39e2c17 100644
--- a/cpp/config/TestUtil.py
+++ b/cpp/config/TestUtil.py
@@ -33,6 +33,12 @@ compress = 0
threadPerConnection = 2
#
+# Set to 1 to disable the memory pool.
+#
+#disablePool=1
+disablePool=0
+
+#
# If you don't set "host" below, then the Ice library will try to find
# out the IP address of this host. For the Ice test suite, it's best
# to set the IP address explicitly to 127.0.0.1. This avoid problems
@@ -53,10 +59,10 @@ import sys, os, re, errno, getopt
from threading import Thread
def usage():
- print "usage: " + sys.argv[0] + " --debug --protocol protocol --compress --host host --threadPerConnection num"
+ print "usage: " + sys.argv[0] + " --debug --protocol protocol --compress --host host --threadPerConnection num --disablePool"
sys.exit(2)
try:
- opts, args = getopt.getopt(sys.argv[1:], "", ["debug", "protocol=", "compress", "host=", "threadPerConnection="])
+ opts, args = getopt.getopt(sys.argv[1:], "", ["debug", "protocol=", "compress", "host=", "threadPerConnection=", "disablePool"])
except getopt.GetoptError:
usage()
@@ -69,6 +75,8 @@ for o, a in opts:
compress = 1
if o == "--threadPerConnection":
threadPerConnection = a
+ if o == "--disablePool":
+ disablePool = 1
if o == "--host":
host = a
@@ -404,6 +412,10 @@ else:
commonServerOptions += " --Ice.ThreadPool.Server.Size=1 --Ice.ThreadPool.Server.SizeMax=3" + \
" --Ice.ThreadPool.Server.SizeWarn=0"
+if disablePool == 1:
+ commonClientOptions = " --Ice.MemoryPool=0 " + commonClientOptions
+ commonServerOptions = " --Ice.MemoryPool=0 " + commonServerOptions
+
clientOptions = clientProtocol + defaultHost + commonClientOptions
serverOptions = serverProtocol + defaultHost + commonServerOptions
clientServerOptions = clientServerProtocol + defaultHost + commonServerOptions