TIBCO Enterprise Message Service
Version 4.3.0

com.tibco.tibjms.admin
Class DestinationInfo

java.lang.Object
  extended bycom.tibco.tibjms.admin.DestinationInfo
Direct Known Subclasses:
QueueInfo, TopicInfo

public abstract class DestinationInfo
extends java.lang.Object

This abstract class contains methods common to both QueueInfo and TopicInfo. It represents a Topic or Queue known to the server. Destinations fall into three categories: static, dynamic, and temporary.
Static destinations are explicitly configured and appear in the configuration files on the server.
Dynamic destinations are created dynamically by EMS clients or routed servers. Dynamic destinations cannot be modified.
Temporary destinations are defined by the JMS specification. Temporary destinations cannot be modified.
TopicInfo or QueueInfo objects received via TibjmsAdmin.getTopic() or TibjmsAdmin.getQueue() methods do not contain the statistical data about the destination. In order to obtain statistical information about destinations use TibjmsAdmin.getTopicsStatistics() or TibjmsAdmin.getQueuesStatistics().


Field Summary
static int ALL_TYPE
          Type indicating a topic or queue.
static byte MSG_TRACE_BASIC
          Indicates that message sequence number and message ID will be traced.
static byte MSG_TRACE_DETAIL
          Indicates that the message body will be traced in addition to the message sequnce number and message ID, .
static byte MSG_TRACE_NONE
          Indicates that messages will not be traced.
static int OVERFLOW_DEFAULT
          Indicates that the destination has no specific overflow policy set.
static int OVERFLOW_DISCARD_OLD
          Indicates that if maxmsgs or maxbytes are exceeded for the queue then when new messages arrive, old messages will be discarded.
static int QUEUE_TYPE
          Type indicating a queue.
static int TOPIC_TYPE
          Type indicating a topic.
 
Method Summary
 void addImportTransport(java.lang.String transportName)
          Add a new import transport to the list of transports this destination imports messages from.
 boolean areBridgeTargetsInherited()
          Determines if the list of targets was inherited from a parent destination or whether it was set on the destination directly.
 boolean areImportTransportsInherited()
          Determines if the list of transports this destination imports messages from was inherited from a parent destination or whether it was set on the destination directly.
 BridgeTarget[] getBridgeTargets()
          Get the target destinations that this destination bridges to.
 int getConsumerCount()
          Get the number of consumers for this destination.
 java.lang.String getDescription()
          Get the description of this destination.
 long getExpiryOverride()
          Get the expiry override for this destination.
 long getFlowControlMaxBytes()
          Get the volume of pending messages (in bytes) at which flow control is enabled for this destination.
 java.lang.String[] getImportTransports()
          Get the names of the transports that this destination imports messages from.
 StatData getInboundStatistics()
          Get inbound statistics for this destination.
 java.lang.String[] getJNDINames()
          Get the array of JNDI names for this destination.
 long getMaxBytes()
          Get the maximum number of message bytes that the server will store for pending messages bound for this destination.
 long getMaxMsgs()
          Get the maximum number of messages that the server will store for pending messages bound for this destination.
 byte getMsgTrace()
          Indicates whether message tracing is enabled for this destination and, if it is enabled, what is to be traced.
 java.lang.String getName()
          Get the name of this destination.
 StatData getOutboundStatistics()
          Get outbound statistics for this destination.
 int getOverflowPolicy()
          Get the overflow policy for this destination.
 long getPendingMessageCount()
          Get the total number of pending messages for this destination.
 long getPendingMessageSize()
          Get the total size for all pending messages for this destination.
 boolean isCMImported()
          Deprecated. As of EMS Version 3.1.0, please view TIBCO Rendezvous imports using getImportTransports.
 boolean isCMImportedInherited()
          Deprecated. As of EMS Version 3.1.0, please view TIBCO Rendezvous import inheritance using areImportTransportsInherited.
 boolean isExpiryOverrideInherited()
          Determine if the expiry override property was inheritied from a parent destination or set directly for this destination.
 boolean isFailsafe()
          Determine if this destination is failsafe.
 boolean isFailsafeInherited()
          Determine if the failsafe property was inheritied from a parent destination or set directly for this destination.
 boolean isFlowControlMaxBytesInherited()
          Determine if the flowControlMaxBytes property was inheritied from a parent destination or set directly for this destination.
 boolean isGlobal()
          Determine if this destination is global.
 boolean isGlobalInherited()
          Determine if the global property was inheritied from a parent destination or set directly for this destination.
 boolean isImported()
          Deprecated. As of EMS Version 3.1.0, please view TIBCO Rendezvous imports using getImportTransports.
 boolean isImportedInherited()
          Deprecated. As of EMS Version 3.1.0, please view TIBCO Rendezvous import inheritance using areImportTransportsInherited.
 boolean isMaxBytesInherited()
          Determine if the maxBytes property was inheritied from a parent destination or set directly for this destination.
 boolean isMaxMsgsInherited()
          Determine if the maxMsgs property was inheritied from a parent destination or set directly for this destination.
 boolean isMsgTraceInherited()
          Determine if the message trace property was inheritied from a parent destination or set directly for this destination.
 boolean isOverflowPolicyInherited()
          Determine if the overflow property was inheritied from a parent destination or set directly for this destination.
 boolean isSecure()
          Determine if this destination is secure.
 boolean isSecureInherited()
          Determine if the secure property was inheritied from a parent destination or set directly for this destination.
 boolean isSenderName()
          Indicates whether or not the sender_name property is set on this destionation.
 boolean isSenderNameEnforced()
          Indicates whether or not the sender_name_enforced property is set on this destination.
 boolean isSenderNameEnforcedInherited()
          Indicates whether or not the sender_name_enforced is inherited.
 boolean isSenderNameInherited()
          Indicates whether or not the sender_name property is inherited.
 boolean isStatic()
          Determine if this destination is static.
 boolean isTemporary()
          Determine if this destination is temporary.
 void removeImportTransport(java.lang.String transportName)
          Remove an import transport from the list of transports this destination imports messages from.
 void setCMImported(boolean imported)
          Deprecated. As of EMS Version 3.1.0, please configure TIBCO Rendezvous imports using addImportTransport.
 void setDescription(java.lang.String description)
          Set the description of this destination.
 void setExpiryOverride(long expiry)
          Set the expiry override for this destination.
 void setFailsafe(boolean failsafe)
          Set the failsafe property of this destination.
 void setFlowControlMaxBytes(long fcBytes)
          Set the volume of pending messages (in bytes) at which flow control will be enabled for this destination.
 void setGlobal(boolean global)
          Set the global property of this destination.
 void setImported(boolean imported)
          Deprecated. As of EMS Version 3.1.0, please configure TIBCO Rendezvous imports using addImportTransport.
 void setMaxBytes(long maxBytes)
          Set the maximum number of message bytes that the server will store for pending messages bound for this destination.
 void setMaxMsgs(long maxMsgs)
          Set the maximum number of messages that the server will store for pending messages bound for this destination.
 void setMsgTrace(byte trace)
          Set the level of message tracing for this destination.
 void setOverflowPolicy(int overflow)
          Set the overflow policy for this destination.
 void setSecure(boolean secure)
          Set the secure property of this destination.
 void setSenderName(boolean senderName)
          Set sender_name property.
 void setSenderNameEnforced(boolean senderNameEnforced)
          Set sender_name_enforced property.
 java.lang.String statString()
          Helper method that generates the statistical information in the form of a string.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ALL_TYPE

public static final int ALL_TYPE
Type indicating a topic or queue.

See Also:
Constant Field Values

QUEUE_TYPE

public static final int QUEUE_TYPE
Type indicating a queue.

See Also:
Constant Field Values

TOPIC_TYPE

public static final int TOPIC_TYPE
Type indicating a topic.

See Also:
Constant Field Values

MSG_TRACE_NONE

public static final byte MSG_TRACE_NONE
Indicates that messages will not be traced.

See Also:
Constant Field Values

MSG_TRACE_BASIC

public static final byte MSG_TRACE_BASIC
Indicates that message sequence number and message ID will be traced.

See Also:
Constant Field Values

MSG_TRACE_DETAIL

public static final byte MSG_TRACE_DETAIL
Indicates that the message body will be traced in addition to the message sequnce number and message ID, .

See Also:
Constant Field Values

OVERFLOW_DEFAULT

public static final int OVERFLOW_DEFAULT
Indicates that the destination has no specific overflow policy set. For queues this means that producers will receive an error if they try to send a message to a queue that has reached either its maxbytes limit or its maxmsgs limit. For topics, if a subscriber has exceeded their maxbytes limit of their maxmsgs limit then new messages will not be delivered to that subscriber but no error will be returned to the sender.

Since:
Version 4.3.0
See Also:
Constant Field Values

OVERFLOW_DISCARD_OLD

public static final int OVERFLOW_DISCARD_OLD
Indicates that if maxmsgs or maxbytes are exceeded for the queue then when new messages arrive, old messages will be discarded. This is not currently supported for topics.

Since:
Version 4.3.0
See Also:
Constant Field Values
Method Detail

getJNDINames

public java.lang.String[] getJNDINames()
Get the array of JNDI names for this destination.

Returns:
the array of JNDI names for this destination or null if no JNDI names assigned to this destination.

getName

public java.lang.String getName()
Get the name of this destination.

Returns:
the name of this destination.

getDescription

public java.lang.String getDescription()
Get the description of this destination.

Returns:
the description of this destination.

setDescription

public void setDescription(java.lang.String description)
Set the description of this destination.

Parameters:
description - the description for this destination.

isFailsafe

public boolean isFailsafe()
Determine if this destination is failsafe.

Returns:
true if this destination is failsafe.

setFailsafe

public void setFailsafe(boolean failsafe)
Set the failsafe property of this destination.

Parameters:
failsafe - true if this destination should be failsafe.

isFailsafeInherited

public boolean isFailsafeInherited()
Determine if the failsafe property was inheritied from a parent destination or set directly for this destination.

Returns:
true if the failsafe property was inherited.

isSecure

public boolean isSecure()
Determine if this destination is secure.

Returns:
true if this destination is secure.

setSecure

public void setSecure(boolean secure)
Set the secure property of this destination.

Parameters:
secure - true if this destination should be secure.

isSecureInherited

public boolean isSecureInherited()
Determine if the secure property was inheritied from a parent destination or set directly for this destination.

Returns:
true if the secure property was inherited.

isGlobal

public boolean isGlobal()
Determine if this destination is global.

Returns:
true if this destination is global.

setGlobal

public void setGlobal(boolean global)
Set the global property of this destination.

Parameters:
global - true if this destination should be global.

isGlobalInherited

public boolean isGlobalInherited()
Determine if the global property was inheritied from a parent destination or set directly for this destination.

Returns:
true if the global property was inherited.

isImported

public boolean isImported()
Deprecated. As of EMS Version 3.1.0, please view TIBCO Rendezvous imports using getImportTransports.

Determine if this destination is imported from Tibco Rendezvous.

Returns:
true if this destination is imported from Tibco Rendezvous.

setImported

public void setImported(boolean imported)
Deprecated. As of EMS Version 3.1.0, please configure TIBCO Rendezvous imports using addImportTransport.

Set the tibrv_import property of this destination.

Parameters:
imported - true if this destination should be imported.

isImportedInherited

public boolean isImportedInherited()
Deprecated. As of EMS Version 3.1.0, please view TIBCO Rendezvous import inheritance using areImportTransportsInherited.

Determine if the tibrv_import property was inheritied from a parent destination or set directly for this destination.

Returns:
true if the tibrv_import property was inherited.

isCMImported

public boolean isCMImported()
Deprecated. As of EMS Version 3.1.0, please view TIBCO Rendezvous imports using getImportTransports.

Determine if this destination is imported from Tibco RVCM.

Returns:
true if this destination is imported from Tibco RVCM.

setCMImported

public void setCMImported(boolean imported)
Deprecated. As of EMS Version 3.1.0, please configure TIBCO Rendezvous imports using addImportTransport.

Set the tibrvcm_import property of this destination.

Parameters:
imported - true if this destination should be imported from RVCM.

getImportTransports

public java.lang.String[] getImportTransports()
Get the names of the transports that this destination imports messages from.

Returns:
array of transport names.

areImportTransportsInherited

public boolean areImportTransportsInherited()
Determines if the list of transports this destination imports messages from was inherited from a parent destination or whether it was set on the destination directly.

Returns:
true if transport list inherited from parent, false otherwise.

addImportTransport

public void addImportTransport(java.lang.String transportName)
                        throws TibjmsAdminInvalidNameException
Add a new import transport to the list of transports this destination imports messages from. If the current list of transports has been inherited from a parent destination then adding a transport will stop the inheritance and the inherited transports will all be removed from the list and replaced with the new one. From then on areImportTransportsInherited will indicate that the transports are no longer inherited and future calls to addImportTransport will simply add new transports to the list.

Parameters:
transportName - the name of the transport.
Throws:
TibjmsAdminInvalidNameException - if transportName is not a legal transport name

removeImportTransport

public void removeImportTransport(java.lang.String transportName)
                           throws TibjmsAdminInvalidNameException,
                                  TibjmsAdminException
Remove an import transport from the list of transports this destination imports messages from. The removal of a transport from the list if the transports are inherited from a parent destination is not permitted and results in an exception.

Parameters:
transportName - the name of the transport.
Throws:
TibjmsAdminInvalidNameException - if transportName is not a legal transport name
TibjmsAdminException - if import transports are inherited

getBridgeTargets

public BridgeTarget[] getBridgeTargets()
Get the target destinations that this destination bridges to.

Returns:
array of BridgeTarget objects.

areBridgeTargetsInherited

public boolean areBridgeTargetsInherited()
Determines if the list of targets was inherited from a parent destination or whether it was set on the destination directly.

Returns:
true if targets inherited from parent, false otherwise.

isSenderName

public boolean isSenderName()
Indicates whether or not the sender_name property is set on this destionation.

Returns:
true if sender_name property is set on this destionation, false otherwise.

setSenderName

public void setSenderName(boolean senderName)
Set sender_name property.

Parameters:
senderName - name of sender.

isSenderNameInherited

public boolean isSenderNameInherited()
Indicates whether or not the sender_name property is inherited.

Returns:
true if sender_name property is inherited, false otherwise.

isSenderNameEnforced

public boolean isSenderNameEnforced()
Indicates whether or not the sender_name_enforced property is set on this destination.

Returns:
true if sender_name_enforced property is set on this destionation, false otherwise.

setSenderNameEnforced

public void setSenderNameEnforced(boolean senderNameEnforced)
Set sender_name_enforced property.

Parameters:
senderNameEnforced - true if the property is to be set, false otherwise.

isSenderNameEnforcedInherited

public boolean isSenderNameEnforcedInherited()
Indicates whether or not the sender_name_enforced is inherited.

Returns:
true if sender_name_enforced property is inherited, false otherwise.

isCMImportedInherited

public boolean isCMImportedInherited()
Deprecated. As of EMS Version 3.1.0, please view TIBCO Rendezvous import inheritance using areImportTransportsInherited.

Determine if the tibrvcm_import property was inheritied from a parent destination or set directly for this destination.

Returns:
true if the tibrvcm_import property was inherited.

getMaxBytes

public long getMaxBytes()
Get the maximum number of message bytes that the server will store for pending messages bound for this destination.

Returns:
the maximum number of message bytes that the server will store for pending messages bound for this destination.

setMaxBytes

public void setMaxBytes(long maxBytes)
Set the maximum number of message bytes that the server will store for pending messages bound for this destination.

Parameters:
maxBytes - the maximum number of message bytes the server should store bound for this destination.

isMaxBytesInherited

public boolean isMaxBytesInherited()
Determine if the maxBytes property was inheritied from a parent destination or set directly for this destination.

Returns:
true if the maxBytes property was inherited.

getMaxMsgs

public long getMaxMsgs()
Get the maximum number of messages that the server will store for pending messages bound for this destination. Not currently supported for topics.

Returns:
the maximum number of messages that the server will store for pending messages bound for this destination. If the destination is a topic zero will be returned.
Since:
Version 4.3.0 (queues only)

setMaxMsgs

public void setMaxMsgs(long maxMsgs)
Set the maximum number of messages that the server will store for pending messages bound for this destination. Not currently supported for topics.

Parameters:
maxMsgs - the maximum number of messages the server should store bound for this destination. If the destination is a topic, the method will have no effect.
Since:
Version 4.3.0 (queues only)

isMaxMsgsInherited

public boolean isMaxMsgsInherited()
Determine if the maxMsgs property was inheritied from a parent destination or set directly for this destination. Not currently supported for topics.

Returns:
true if the maxMsgs property was inherited. If the destination is a topic the method will return false.
Since:
Version 4.3.0 (queues only)

getOverflowPolicy

public int getOverflowPolicy()
Get the overflow policy for this destination. Possible values are OVERFLOW_DEFAULT or OVERFLOW_DISCARD_OLD. Not currently supported for topics.

Returns:
the overflow policy for this destination. If the destination is a topic the method will return OVERFLOW_DEFAULT.
Since:
Version 4.3.0 (queues only)

setOverflowPolicy

public void setOverflowPolicy(int overflow)
                       throws java.lang.IllegalArgumentException,
                              TibjmsAdminException
Set the overflow policy for this destination. Allowable values are OVERFLOW_DEFAULT and OVERFLOW_DISCARD_OLD. Not currently supported for topics.

Parameters:
overflow - the overflow policy for this destination. If the destination is a topic the method will have no effect.
Throws:
java.lang.IllegalArgumentException - if overflow is invalid.
TibjmsAdminException
Since:
Version 4.3.0 (queues only)

isOverflowPolicyInherited

public boolean isOverflowPolicyInherited()
Determine if the overflow property was inheritied from a parent destination or set directly for this destination. Not currently supported for topics.

Returns:
true if the overflow property was inherited. If the destination is a topic the method will return false.
Since:
Version 4.3.0 (queues only)

getMsgTrace

public byte getMsgTrace()
Indicates whether message tracing is enabled for this destination and, if it is enabled, what is to be traced.

Returns:
a byte representing the level of message tracing for this destination.

setMsgTrace

public void setMsgTrace(byte trace)
                 throws java.lang.IllegalArgumentException
Set the level of message tracing for this destination.

Parameters:
trace - a byte representing the desired level of message tracing for this destination.
Throws:
java.lang.IllegalArgumentException - if trace is invalid.

isMsgTraceInherited

public boolean isMsgTraceInherited()
Determine if the message trace property was inheritied from a parent destination or set directly for this destination.

Returns:
true if the trace property was inherited, false otherwise.

getFlowControlMaxBytes

public long getFlowControlMaxBytes()
Get the volume of pending messages (in bytes) at which flow control is enabled for this destination.

Returns:
the volume of pending messages (in bytes) that the server will store for this destination before enabling flow control. A return value of zero indicates that flow control will never be enabled.

setFlowControlMaxBytes

public void setFlowControlMaxBytes(long fcBytes)
Set the volume of pending messages (in bytes) at which flow control will be enabled for this destination.

Parameters:
fcBytes - the volume of messages (in bytes) that the server should store for this destination before enabling flow control. Set the value to zero to cancel the current value.

isFlowControlMaxBytesInherited

public boolean isFlowControlMaxBytesInherited()
Determine if the flowControlMaxBytes property was inheritied from a parent destination or set directly for this destination.

Returns:
true if the flowControlMaxBytes property was inherited.

isStatic

public boolean isStatic()
Determine if this destination is static. A destination is static if it is explicitly configured on the server. Temporary destinations and destinations created by the client without being configured on the server are not static. Only static destinations can be modified. Attempts to modify dynamic and temporary destinations will throw an exception.

Returns:
true if this destination is static.

isTemporary

public boolean isTemporary()
Determine if this destination is temporary.

Returns:
true if this destination is temporary.

getPendingMessageCount

public long getPendingMessageCount()
Get the total number of pending messages for this destination.

Returns:
the total number of pending messages for this destination.

getPendingMessageSize

public long getPendingMessageSize()
Get the total size for all pending messages for this destination.

Returns:
the total size for all pending messages for this destination.

getConsumerCount

public int getConsumerCount()
Get the number of consumers for this destination.

Returns:
the number of consumers for this destination.

getInboundStatistics

public StatData getInboundStatistics()
Get inbound statistics for this destination. Inbound statistics refers to all messages sent into this destination by EMS clients and routed server.

Returns:
the inbound statistics for this destination

getOutboundStatistics

public StatData getOutboundStatistics()
Get outbound statistics for this destination. Outbound statistics refers to all messages sent by the server to consumers on this destination and to other routed server.

Returns:
the outbound statistics for this destination.

getExpiryOverride

public long getExpiryOverride()
Get the expiry override for this destination. When this property is set to a non-zero value for a destination, and the server delivers a message to it, the server replaces the producer expiration value with this value.

Returns:
the expiration time in milliseconds.
Since:
Version 4.2

setExpiryOverride

public void setExpiryOverride(long expiry)
Set the expiry override for this destination. When this property is set to a non-zero value for a destination, and the server delivers a message to it, the server replaces the producer expiration value with this value.

Parameters:
expiry - the expiration time in milliseconds.
Since:
Version 4.2

isExpiryOverrideInherited

public boolean isExpiryOverrideInherited()
Determine if the expiry override property was inheritied from a parent destination or set directly for this destination.

Returns:
true if the expiry override property was inherited.
Since:
Version 4.2

statString

public java.lang.String statString()
Helper method that generates the statistical information in the form of a string.

Returns:
String representation of statistical information.

TIBCO Enterprise Message Service
Version 4.3.0

Copyright © TIBCO Software Inc. All rights reserved