|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.logicblaze.lingo.jms.impl.OneWayRequestor
org.logicblaze.lingo.jms.impl.SingleThreadedRequestor
org.logicblaze.lingo.jms.impl.MultiplexingRequestor
A Requestor
which will use a single producer, consumer
and temporary topic for resource efficiency, but will use correlation
IDs on each message and response to ensure that each threads requests
can occur synchronously.
Constructor Summary | |
MultiplexingRequestor(Session session,
JmsProducer producer,
Destination serverDestination)
|
|
MultiplexingRequestor(Session session,
JmsProducer producer,
Destination serverDestination,
Destination clientDestination)
|
Method Summary | |
protected JMSException |
createJMSException(Exception e)
|
protected void |
doSend(Destination destination,
Message message,
long timeout)
|
static Requestor |
newInstance(ConnectionFactory connectionFactory,
Destination serverDestination)
|
static Requestor |
newInstance(ConnectionFactory connectionFactory,
Destination serverDestination,
Destination clientDestination)
|
void |
onMessage(Message message)
Processes inbound responses from requests |
Message |
receive(long timeout)
Receives a message waiting for a maximum timeout if the timeout value is > 0 ir waiting forever if the timeout is < 0 or not waiting at all if the timeout is zero |
void |
registerHandler(String correlationID,
ReplyHandler handler)
|
Message |
request(Destination destination,
Message message)
Sends a request and waits for a reply. |
Message |
request(Destination destination,
Message message,
long timeout)
Sends a request and waits for a reply up to a maximum timeout. |
Methods inherited from class org.logicblaze.lingo.jms.impl.SingleThreadedRequestor |
close, createTemporaryDestination, getReceiver, populateHeaders |
Methods inherited from class org.logicblaze.lingo.jms.impl.OneWayRequestor |
createCorrelationID, getDeliveryMode, getPriority, getSession, getTimeToLive, nextCounter, oneWay, oneWay, setDeliveryMode, setPriority, setTimeToLive |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public MultiplexingRequestor(Session session, JmsProducer producer, Destination serverDestination, Destination clientDestination) throws JMSException
public MultiplexingRequestor(Session session, JmsProducer producer, Destination serverDestination) throws JMSException
Method Detail |
public static Requestor newInstance(ConnectionFactory connectionFactory, Destination serverDestination) throws JMSException
JMSException
public static Requestor newInstance(ConnectionFactory connectionFactory, Destination serverDestination, Destination clientDestination) throws JMSException
JMSException
public void registerHandler(String correlationID, ReplyHandler handler)
public Message request(Destination destination, Message message) throws JMSException
Requestor
JMSReplyTo
destination, and only one reply per request
is expected.
request
in interface Requestor
request
in class SingleThreadedRequestor
JMSException
public Message request(Destination destination, Message message, long timeout) throws JMSException
Requestor
JMSReplyTo
destination, and only one reply per request
is expected.
request
in interface Requestor
request
in class SingleThreadedRequestor
JMSException
public void onMessage(Message message)
onMessage
in interface MessageListener
public Message receive(long timeout) throws JMSException
Requestor
receive
in interface Requestor
receive
in class SingleThreadedRequestor
JMSException
protected void doSend(Destination destination, Message message, long timeout) throws JMSException
doSend
in class OneWayRequestor
JMSException
protected JMSException createJMSException(Exception e)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |