zaqar/marconi/bench
Sriram Madapusi Vasudevan 4c950f99e4 feat(benchmarking) : Producer-Consumer scenario
This patch adds the ability to benchmark Marconi. The benchmark tool
is a console script, and can be triggered using

$ marconi-bench-pc

The Benchmark tool fires up both a Producer Process and a Consumer
Process, while accepting CLI parameters for the number of processes,
number of workers and duration of test.

The Producer Process publishes messages to a given queue, while the
Consumer consumes the messages by claiming and deleting them.

Setup:

Benchmark dependencies need to be pip installed:

 pip install -r bench-requirements.txt

Export an environment variable called MESSAGES_PATH and set it to the
path of messages.json in marconi/bench

Note: This allows benchmarking with different set of messages rather
than those specified in messages.json

Usage:

$ marconi-bench-pc -p {No. Processes} -w {No. Workers} -t {No. Seconds}

Example:

$ marconi-bench-pc -p 2 -w 2 -t 4

Partially Implements: blueprint basic-benchmarking
Change-Id: I57ebe853554199490adba8b2a091423f399b0565
2014-07-16 10:37:12 -04:00
..
__init__.py feat(benchmarking) : Producer-Consumer scenario 2014-07-16 10:37:12 -04:00
cli_config.py feat(benchmarking) : Producer-Consumer scenario 2014-07-16 10:37:12 -04:00
conductor.py feat(benchmarking) : Producer-Consumer scenario 2014-07-16 10:37:12 -04:00
consumer.py feat(benchmarking) : Producer-Consumer scenario 2014-07-16 10:37:12 -04:00
messages.json feat(benchmarking) : Producer-Consumer scenario 2014-07-16 10:37:12 -04:00
producer.py feat(benchmarking) : Producer-Consumer scenario 2014-07-16 10:37:12 -04:00
README.rst feat(benchmarking) : Producer-Consumer scenario 2014-07-16 10:37:12 -04:00

Marconi Benchmarking

Structure

The Benchmark tool fires up both a Producer Process and a Consumer Process, while accepting CLI parameters for the number of processes, number of workers and duration of test.

The Producer Process publishes messages to a given queue, while the Consumer consumes the messages claiming and deleting them.

Need of the Benchmark

Marconi is a performance oriented API. Any changes made need to performance tested, and this tool helps by a being quick way to test that.

Setup

Benchmark dependencies need to be pip installed:

pip install -r bench-requirements.txt

Make sure you have a running instance of Marconi after following README for setting up Marconi running at port 8888:

Export an environment variable called MESSAGES_PATH and set it to the path of messages.json in marconi/bench

Note: This allows benchmarking with different set of messages rather than those specified in

messages.json

$ marconi-bench-pc -p {Number of Processes} -w {Number of Workers} -t {Duration in Seconds}