diff options
| author | Gordon Sim <gsim@apache.org> | 2013-02-15 13:34:19 +0000 |
|---|---|---|
| committer | Gordon Sim <gsim@apache.org> | 2013-02-15 13:34:19 +0000 |
| commit | f86294741548e5fec917ab235acce21366953934 (patch) | |
| tree | b84def7f3022e7fee4db01707450162d7577c294 /qpid/cpp/src/tests/qpid-cpp-benchmark | |
| parent | 2a58bdd35cd961b7650ee6c9446b5b1a42179131 (diff) | |
| download | qpid-python-f86294741548e5fec917ab235acce21366953934.tar.gz | |
QPID-4116: Allow the path to qpid-send and qpid-receive programs to be specified; patch from Pavel Moravec.
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk@1446578 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'qpid/cpp/src/tests/qpid-cpp-benchmark')
| -rwxr-xr-x | qpid/cpp/src/tests/qpid-cpp-benchmark | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/qpid/cpp/src/tests/qpid-cpp-benchmark b/qpid/cpp/src/tests/qpid-cpp-benchmark index d5ad5191ca..9ac6a10883 100755 --- a/qpid/cpp/src/tests/qpid-cpp-benchmark +++ b/qpid/cpp/src/tests/qpid-cpp-benchmark @@ -18,7 +18,7 @@ # under the License. # -import optparse, time, qpid.messaging, re +import optparse, time, qpid.messaging, re, os from threading import Thread from subprocess import Popen, PIPE, STDOUT @@ -77,6 +77,10 @@ op.add_option("--no-delete", default=False, action="store_true", help="Don't delete the test queues.") op.add_option("--fill-drain", default=False, action="store_true", help="First fill the queues, then drain them") +op.add_option("--qpid-send-path", default="", type="str", metavar="PATH", + help="path to qpid-send binary") +op.add_option("--qpid-receive-path", default="", type="str", metavar="PATH", + help="path to qpid-receive binary") single_quote_re = re.compile("'") def posix_quote(string): @@ -115,7 +119,7 @@ def start_receive(queue, index, opts, ready_queue, broker, host): messages = msg_total/opts.receivers; if (index < msg_total%opts.receivers): messages += 1 if (messages == 0): return None - command = ["qpid-receive", + command = [os.path.join(opts.qpid_receive_path, "qpid-receive"), "-b", broker, "-a", address, "-m", str(messages), @@ -138,7 +142,7 @@ def start_receive(queue, index, opts, ready_queue, broker, host): def start_send(queue, opts, broker, host): address="%s;{%s}"%(queue,",".join(opts.send_option + ["create:always"])) - command = ["qpid-send", + command = [os.path.join(opts.qpid_send_path, "qpid-send"), "-b", broker, "-a", address, "--messages", str(opts.messages), |
