org.jboss.jms.server.destination
Class DestinationServiceSupport

java.lang.Object
  extended by ServiceMBeanSupport
      extended by org.jboss.jms.server.destination.DestinationServiceSupport
All Implemented Interfaces:
DestinationMBean
Direct Known Subclasses:
QueueService, TopicService

public abstract class DestinationServiceSupport
extends ServiceMBeanSupport
implements DestinationMBean

The base of a JBoss Messaging destination service. Both deployed or programatically created destinations will eventually get one of these.

Version:
$Revision: 3149 $ $Id: DestinationServiceSupport.java 3149 2007-09-27 20:29:57Z clebert.suconic@jboss.com $
Author:
Ovidiu Feodorov, Tim Fox, Alex Fu

Field Summary
protected  ManagedDestination destination
           
protected  int nodeId
           
protected  ServerPeer serverPeer
           
protected  boolean started
           
 
Constructor Summary
DestinationServiceSupport()
           
DestinationServiceSupport(boolean createdProgrammatically)
           
 
Method Summary
 javax.management.ObjectName getDLQ()
           
 int getDownCacheSize()
          Get write-cache size
 javax.management.ObjectName getExpiryQueue()
           
 int getFullSize()
          Get in-memory message limit
 MessagingComponent getInstance()
           
 java.lang.String getJNDIName()
           
 int getMaxDeliveryAttempts()
           
 int getMaxSize()
           
 int getMessageCounterHistoryDayLimit()
           
 java.lang.String getName()
           
 int getPageSize()
          Get paging size
 long getRedeliveryDelay()
           
 org.w3c.dom.Element getSecurityConfig()
           
 javax.management.ObjectName getServerPeer()
           
 boolean isClustered()
           
 boolean isCreatedProgrammatically()
           
protected abstract  boolean isQueue()
           
protected  java.lang.String listMessageCounterAsHTML(MessageCounter[] counters)
          List message counters as HTML table
protected  java.lang.String listMessageCounterHistoryAsHTML(MessageCounter[] counters)
          List destination message counter history as HTML table
abstract  void removeAllMessages()
           
 void setClustered(boolean clustered)
           
 void setDLQ(javax.management.ObjectName on)
           
 void setDownCacheSize(int downCacheSize)
          Set write-cache size when destination is stopped.
 void setExpiryQueue(javax.management.ObjectName on)
           
 void setFullSize(int fullSize)
          Set in-memory message limit when destination is stopped.
 void setJNDIName(java.lang.String jndiName)
           
 void setMaxDeliveryAttempts(int maxDeliveryAttempts)
           
 void setMaxSize(int maxSize)
           
 void setMessageCounterHistoryDayLimit(int limit)
           
 void setPageSize(int pageSize)
          Set paging size when destination is stopped.
 void setRedeliveryDelay(long delay)
           
 void setSecurityConfig(org.w3c.dom.Element securityConfig)
           
 void setServerPeer(javax.management.ObjectName on)
           
 void startService()
           
 void stopService()
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

started

protected boolean started

destination

protected ManagedDestination destination

serverPeer

protected ServerPeer serverPeer

nodeId

protected int nodeId
Constructor Detail

DestinationServiceSupport

public DestinationServiceSupport(boolean createdProgrammatically)

DestinationServiceSupport

public DestinationServiceSupport()
Method Detail

getInstance

public MessagingComponent getInstance()

startService

public void startService()
                  throws java.lang.Exception
Throws:
java.lang.Exception

stopService

public void stopService()
                 throws java.lang.Exception
Throws:
java.lang.Exception

getName

public java.lang.String getName()
Specified by:
getName in interface DestinationMBean

getJNDIName

public java.lang.String getJNDIName()
Specified by:
getJNDIName in interface DestinationMBean

setJNDIName

public void setJNDIName(java.lang.String jndiName)
                 throws java.lang.Exception
Specified by:
setJNDIName in interface DestinationMBean
Throws:
java.lang.Exception

setServerPeer

public void setServerPeer(javax.management.ObjectName on)
Specified by:
setServerPeer in interface DestinationMBean

getServerPeer

public javax.management.ObjectName getServerPeer()
Specified by:
getServerPeer in interface DestinationMBean

setDLQ

public void setDLQ(javax.management.ObjectName on)
            throws java.lang.Exception
Specified by:
setDLQ in interface DestinationMBean
Throws:
java.lang.Exception

getDLQ

public javax.management.ObjectName getDLQ()
Specified by:
getDLQ in interface DestinationMBean

setExpiryQueue

public void setExpiryQueue(javax.management.ObjectName on)
                    throws java.lang.Exception
Specified by:
setExpiryQueue in interface DestinationMBean
Throws:
java.lang.Exception

getExpiryQueue

public javax.management.ObjectName getExpiryQueue()
Specified by:
getExpiryQueue in interface DestinationMBean

getRedeliveryDelay

public long getRedeliveryDelay()
Specified by:
getRedeliveryDelay in interface DestinationMBean

setRedeliveryDelay

public void setRedeliveryDelay(long delay)
Specified by:
setRedeliveryDelay in interface DestinationMBean

getMaxSize

public int getMaxSize()
Specified by:
getMaxSize in interface DestinationMBean

setMaxSize

public void setMaxSize(int maxSize)
                throws java.lang.Exception
Specified by:
setMaxSize in interface DestinationMBean
Throws:
java.lang.Exception

getSecurityConfig

public org.w3c.dom.Element getSecurityConfig()
Specified by:
getSecurityConfig in interface DestinationMBean

setSecurityConfig

public void setSecurityConfig(org.w3c.dom.Element securityConfig)
                       throws java.lang.Exception
Specified by:
setSecurityConfig in interface DestinationMBean
Throws:
java.lang.Exception

getFullSize

public int getFullSize()
Get in-memory message limit

Specified by:
getFullSize in interface DestinationMBean
Returns:
message limit

setFullSize

public void setFullSize(int fullSize)
Set in-memory message limit when destination is stopped.

Specified by:
setFullSize in interface DestinationMBean
Parameters:
fullSize - the message limit

getPageSize

public int getPageSize()
Get paging size

Specified by:
getPageSize in interface DestinationMBean
Returns:
paging size

setPageSize

public void setPageSize(int pageSize)
Set paging size when destination is stopped.

Specified by:
setPageSize in interface DestinationMBean
Parameters:
pageSize - the paging size

getDownCacheSize

public int getDownCacheSize()
Get write-cache size

Specified by:
getDownCacheSize in interface DestinationMBean
Returns:
cache size

setDownCacheSize

public void setDownCacheSize(int downCacheSize)
Set write-cache size when destination is stopped.

Specified by:
setDownCacheSize in interface DestinationMBean
Parameters:
downCacheSize - the cache size

isClustered

public boolean isClustered()
Specified by:
isClustered in interface DestinationMBean

setClustered

public void setClustered(boolean clustered)
Specified by:
setClustered in interface DestinationMBean

isCreatedProgrammatically

public boolean isCreatedProgrammatically()
Specified by:
isCreatedProgrammatically in interface DestinationMBean

getMessageCounterHistoryDayLimit

public int getMessageCounterHistoryDayLimit()
Specified by:
getMessageCounterHistoryDayLimit in interface DestinationMBean

setMessageCounterHistoryDayLimit

public void setMessageCounterHistoryDayLimit(int limit)
                                      throws java.lang.Exception
Specified by:
setMessageCounterHistoryDayLimit in interface DestinationMBean
Throws:
java.lang.Exception

getMaxDeliveryAttempts

public int getMaxDeliveryAttempts()
Specified by:
getMaxDeliveryAttempts in interface DestinationMBean

setMaxDeliveryAttempts

public void setMaxDeliveryAttempts(int maxDeliveryAttempts)
Specified by:
setMaxDeliveryAttempts in interface DestinationMBean

removeAllMessages

public abstract void removeAllMessages()
                                throws java.lang.Exception
Specified by:
removeAllMessages in interface DestinationMBean
Throws:
java.lang.Exception

toString

public java.lang.String toString()

listMessageCounterAsHTML

protected java.lang.String listMessageCounterAsHTML(MessageCounter[] counters)
List message counters as HTML table

Returns:
String

listMessageCounterHistoryAsHTML

protected java.lang.String listMessageCounterHistoryAsHTML(MessageCounter[] counters)
List destination message counter history as HTML table

Returns:
String

isQueue

protected abstract boolean isQueue()


Copyright © 2006 JBoss Inc. All Rights Reserved.