public class JmsProducerClient extends AbstractJmsMeasurableClient
| Modifier and Type | Field and Description |
|---|---|
protected JmsProducerProperties |
client |
protected javax.jms.MessageProducer |
jmsProducer |
protected javax.jms.TextMessage |
jmsTextMessage |
throughputclientName, destCount, destIndex, factory, jmsConnection, jmsSession| Constructor and Description |
|---|
JmsProducerClient(javax.jms.ConnectionFactory factory) |
JmsProducerClient(JmsProducerProperties clientProps,
javax.jms.ConnectionFactory factory) |
| Modifier and Type | Method and Description |
|---|---|
protected java.lang.String |
buildText(java.lang.String text,
int size) |
javax.jms.MessageProducer |
createJmsProducer() |
javax.jms.MessageProducer |
createJmsProducer(javax.jms.Destination dest) |
javax.jms.TextMessage |
createJmsTextMessage() |
javax.jms.TextMessage |
createJmsTextMessage(int size) |
javax.jms.TextMessage |
createJmsTextMessage(java.lang.String text) |
JmsClientProperties |
getClient() |
javax.jms.MessageProducer |
getJmsProducer() |
javax.jms.TextMessage |
getJmsTextMessage() |
protected javax.jms.TextMessage |
loadJmsMessage()
loads the message to be sent from the specified TextFile
|
void |
sendCountBasedMessages(long messageCount) |
void |
sendMessages() |
void |
sendMessages(int destCount) |
void |
sendMessages(int destIndex,
int destCount) |
void |
sendTimeBasedMessages(long duration) |
void |
setClient(JmsClientProperties clientProps) |
protected void |
sleep() |
getThroughput, incThroughput, incThroughput, reset, setThroughputcommitTxIfNecessary, createCompositeDestination, createCompositeDestination, createDestination, createDestination, getClientName, getConnection, getDestCount, getDestIndex, getFactory, getSession, setClientName, setDestCount, setDestIndex, setFactoryclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetClientNameprotected JmsProducerProperties client
protected javax.jms.MessageProducer jmsProducer
protected javax.jms.TextMessage jmsTextMessage
public JmsProducerClient(javax.jms.ConnectionFactory factory)
public JmsProducerClient(JmsProducerProperties clientProps, javax.jms.ConnectionFactory factory)
public void sendMessages()
throws javax.jms.JMSException
javax.jms.JMSExceptionpublic void sendMessages(int destCount)
throws javax.jms.JMSException
javax.jms.JMSExceptionpublic void sendMessages(int destIndex,
int destCount)
throws javax.jms.JMSException
javax.jms.JMSExceptionpublic void sendCountBasedMessages(long messageCount)
throws javax.jms.JMSException
javax.jms.JMSExceptionpublic void sendTimeBasedMessages(long duration)
throws javax.jms.JMSException
javax.jms.JMSExceptionpublic javax.jms.MessageProducer createJmsProducer()
throws javax.jms.JMSException
javax.jms.JMSExceptionpublic javax.jms.MessageProducer createJmsProducer(javax.jms.Destination dest)
throws javax.jms.JMSException
javax.jms.JMSExceptionpublic javax.jms.MessageProducer getJmsProducer()
public javax.jms.TextMessage createJmsTextMessage()
throws javax.jms.JMSException
javax.jms.JMSExceptionpublic javax.jms.TextMessage createJmsTextMessage(int size)
throws javax.jms.JMSException
javax.jms.JMSExceptionpublic javax.jms.TextMessage createJmsTextMessage(java.lang.String text)
throws javax.jms.JMSException
javax.jms.JMSExceptionpublic javax.jms.TextMessage getJmsTextMessage()
public JmsClientProperties getClient()
getClient in class AbstractJmsClientpublic void setClient(JmsClientProperties clientProps)
setClient in class AbstractJmsClientprotected java.lang.String buildText(java.lang.String text,
int size)
protected void sleep()
protected javax.jms.TextMessage loadJmsMessage()
throws javax.jms.JMSException
javax.jms.JMSExceptionCopyright © 2005-2013 Red Hat, Inc.. All Rights Reserved.