org.granite.gravity.adapters
Class JMSServiceAdapter

java.lang.Object
  extended by org.granite.gravity.adapters.ServiceAdapter
      extended by org.granite.gravity.adapters.JMSServiceAdapter
Direct Known Subclasses:
ActiveMQServiceAdapter

public class JMSServiceAdapter
extends ServiceAdapter

Author:
William DRAI

Field Summary
protected  int acknowledgeMode
           
static int DEFAULT_FAILOVER_RETRY_COUNT
           
static long DEFAULT_FAILOVER_RETRY_INTERVAL
           
protected  int deliveryMode
           
protected  String destinationName
           
protected  int failoverRetryCount
           
protected  long failoverRetryInterval
           
protected  Map<String,JMSClient> jmsClients
           
protected  ConnectionFactory jmsConnectionFactory
           
protected  Destination jmsDestination
           
protected  int messagePriority
           
protected  boolean noLocal
           
protected  boolean sessionSelector
           
protected  boolean textMessages
           
protected  boolean transactedSessions
           
 
Constructor Summary
JMSServiceAdapter()
           
 
Method Summary
 void configure(XMap adapterProperties, XMap destinationProperties)
           
protected  Destination getConsumerDestination(String topic)
           
protected  Destination getProducerDestination(String topic)
           
 Object invoke(Channel fromClient, AsyncMessage message)
           
 Object manage(Channel fromChannel, CommandMessage message)
           
 void start()
           
 void stop()
           
 
Methods inherited from class org.granite.gravity.adapters.ServiceAdapter
getAdapterState, getDestination, getGravity, getId, getSecurityPolicy, setAdapterState, setDestination, setGravity, setId, setSecurityPolicy
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DEFAULT_FAILOVER_RETRY_INTERVAL

public static final long DEFAULT_FAILOVER_RETRY_INTERVAL
See Also:
Constant Field Values

DEFAULT_FAILOVER_RETRY_COUNT

public static final int DEFAULT_FAILOVER_RETRY_COUNT
See Also:
Constant Field Values

jmsConnectionFactory

protected ConnectionFactory jmsConnectionFactory

jmsDestination

protected Destination jmsDestination

jmsClients

protected Map<String,JMSClient> jmsClients

destinationName

protected String destinationName

textMessages

protected boolean textMessages

transactedSessions

protected boolean transactedSessions

acknowledgeMode

protected int acknowledgeMode

messagePriority

protected int messagePriority

deliveryMode

protected int deliveryMode

noLocal

protected boolean noLocal

sessionSelector

protected boolean sessionSelector

failoverRetryInterval

protected long failoverRetryInterval

failoverRetryCount

protected int failoverRetryCount
Constructor Detail

JMSServiceAdapter

public JMSServiceAdapter()
Method Detail

configure

public void configure(XMap adapterProperties,
                      XMap destinationProperties)
               throws ServiceException
Overrides:
configure in class ServiceAdapter
Throws:
ServiceException

getProducerDestination

protected Destination getProducerDestination(String topic)

getConsumerDestination

protected Destination getConsumerDestination(String topic)

start

public void start()
           throws ServiceException
Overrides:
start in class ServiceAdapter
Throws:
ServiceException

stop

public void stop()
          throws ServiceException
Overrides:
stop in class ServiceAdapter
Throws:
ServiceException

invoke

public Object invoke(Channel fromClient,
                     AsyncMessage message)
Specified by:
invoke in class ServiceAdapter

manage

public Object manage(Channel fromChannel,
                     CommandMessage message)
Specified by:
manage in class ServiceAdapter