- All Implemented Interfaces:
- javax.jms.ExceptionListener
public class Sender
extends Client
A generic sender which sends a stream of messages
to a given address in a broker (host/port)
until told to stop by killing it.
It has a feedback loop to ensure it doesn't fill
up queues due to a slow consumer.
It doesn't check for correctness or measure anything
leaving those concerns to another entity.
However it prints a timestamp every x secs(-Dreport_frequency)
as checkpoint to figure out how far the test has progressed if
a failure occurred.
It also takes in an optional Error handler to
pass out any error in addition to writing them to std err.
This is intended more as building block to create
more complex test cases. However there is a main method
provided to use this standalone.
The following options are available and configurable
via jvm args.
msg_size (256)
msg_count (10) - # messages before waiting for feedback
sleep_time (1000 ms) - sleep time btw each iteration
report_frequency - how often a timestamp is printed
durable
transacted
tx_size - size of transaction batch in # msgs.