BEA Systems, Inc.

WebLogic Server 6.1 API Reference

weblogic.management.configuration
Interface JMSConnectionFactoryMBean


public interface JMSConnectionFactoryMBean
extends DeploymentMBean, JMSConstants

This bean represents a JMS connection factory.

Author:
Copyright © 2001 BEA Systems, Inc. All Rights Reserved.

Fields inherited from class weblogic.management.configuration.DeploymentMBean
DEFAULT_ORDER, MAX_ORDER, MIN_ORDER
 
Fields inherited from class weblogic.management.configuration.JMSConstants
ACKNOWLEDGE_ALL, ACKNOWLEDGE_MODE_AUTO, ACKNOWLEDGE_MODE_CLIENT, ACKNOWLEDGE_MODE_DUPS_OK, ACKNOWLEDGE_MODE_NONE, ACKNOWLEDGE_ONE, ACKNOWLEDGE_PREVIOUS, DESTINATION_TYPE_QUEUE, DESTINATION_TYPE_TOPIC, ENABLED_DEFAULT, ENABLED_FALSE, ENABLED_TRUE, KEEP_NEW, KEEP_OLD, KEY_DIRECTION_ASCENDING, KEY_DIRECTION_DESCENDING, KEY_TYPE_BOOLEAN, KEY_TYPE_BYTE, KEY_TYPE_DOUBLE, KEY_TYPE_FLOAT, KEY_TYPE_INT, KEY_TYPE_LONG, KEY_TYPE_SHORT, KEY_TYPE_STRING, NO_DELIVERY, NON_PERSISTENT, PERSISTENT, PRIORITY_DEFAULT, PRIORITY_MAXIMUM, PRIORITY_MINIMUM, STORE_ENABLED_DEFAULT, STORE_ENABLED_FALSE, STORE_ENABLED_TRUE, STORE_TYPE_FILE, STORE_TYPE_JDBC, TRANSACTION_MODE_51, TRANSACTION_MODE_NONE, TRANSACTION_MODE_XA
 
Method Summary
 java.lang.String getAcknowledgePolicy()
          Return the value of the acknowledgePolicy attribute for the connection factory.
 boolean getAllowCloseInOnMessage()
          Return the value of the allowCloseInOnMessage attribute for the connection factory.
 java.lang.String getClientId()
          Return the client ID for a durable subscriber that uses this ConnectionFactory.
 java.lang.String getDefaultDeliveryMode()
          Return the value of the defaultDeliveryMode attribute for the connection factory.
 int getDefaultPriority()
          Return the defaultPriority attribute for the connection factory.
 long getDefaultRedeliveryDelay()
          A redelivery delay defines the delay in milliseconds before rolled back or recovered messages are redelivered.
 long getDefaultTimeToDeliver()
          A time-to-deliver defines the delay in milliseconds between when a message is produced and when it is made visible on its destination.
 long getDefaultTimeToLive()
          Return the value of the defaultTimeToLive attribute for the connection factory.
 java.lang.String getJNDIName()
          Return the JNDI name of the JMS ConnectionFactory.
 int getMessagesMaximum()
          Return the value of the messagesMaximum attribute for the connection factory.
 java.lang.String getOverrunPolicy()
          Return the value of the overrunPolicy attribute for the connection factory.
 long getTransactionTimeout()
          Return the value of the transactionTimeout attribute for the connection factory.
 boolean isUserTransactionsEnabled()
          Return the value of the userTransactionsEnabled This value indicates whether or not a connection factory creates sessions that are JTA aware.
 boolean isXAConnectionFactoryEnabled()
          Return the value of the XAConnectionFactoryEnabled attribute for the connection factory.
 void setAcknowledgePolicy(java.lang.String policy)
          Set the value of the acknowldegePolicy attribute for the connection factory.
 void setAllowCloseInOnMessage(boolean allowCloseInOnMessage)
          Set the value of the allowCloseInOnMessage attribute for the connection factory.
 void setClientId(java.lang.String id)
          Set the client ID for a durable subscriber that uses this ConnectionFactory.
 void setDefaultDeliveryMode(java.lang.String defaultDeliveryMode)
          Set the value of the defaultDeliveryMode attribute for the connection factory.
 void setDefaultPriority(int defaultPriority)
          Set the value of the defaultPriority attribute for the connection factory.
 void setDefaultRedeliveryDelay(long defaultRedeliveryDelay)
          A redelivery delay defines the delay in milliseconds before rolled back or recovered messages are redelivered.
 void setDefaultTimeToDeliver(long timeToDeliver)
          A time-to-deliver defines the delay in milliseconds between when a message is produced and when it is made visible on its destination.
 void setDefaultTimeToLive(long defaultTimeToLive)
          Set the value of the defaultTimeToLive attribute for the connection factory.
 void setJNDIName(java.lang.String name)
          Set the JNDI name of the JMS ConnectionFactory.
 void setMessagesMaximum(int messagesMaximum)
          Set the value of the messagesMaximum attribute for the connection factory.
 void setOverrunPolicy(java.lang.String policy)
          Set the value of the overrunPolicy attribute for the connection factory.
 void setTransactionTimeout(long transactionTimeout)
          Set the value of the transactionTimeout attribute for the connection factory.
 void setUserTransactionsEnabled(boolean userTransactionsEnabled)
          Set the value of the userTransactionsEnabled attribute for the connection factory.
 void setXAConnectionFactoryEnabled(boolean XAConnectionFactoryEnabled)
          Set the value of the XAConnectionFactoryEnabled attribute for the connection factory.
 
Methods inherited from interface weblogic.management.configuration.DeploymentMBean
addTarget, getDeploymentOrder, getTargets, removeTarget, setDeploymentOrder, setTargets
 
Methods inherited from interface weblogic.management.configuration.ConfigurationMBean
getNotes, setNotes, setPersistenceEnabled
 
Methods inherited from interface weblogic.management.WebLogicMBean
getMBeanInfo, getName, getObjectName, getParent, getType, isCachingDisabled, isRegistered, setName, setParent
 
Methods inherited from interface javax.management.DynamicMBean
getAttribute, getAttributes, invoke, setAttribute, setAttributes
 
Methods inherited from interface javax.management.MBeanRegistration
postDeregister, postRegister, preDeregister, preRegister
 
Methods inherited from interface javax.management.NotificationBroadcaster
addNotificationListener, getNotificationInfo, removeNotificationListener
 

Method Detail

getJNDIName

public java.lang.String getJNDIName()
Return the JNDI name of the JMS ConnectionFactory. This is the name that is assigned to and used to look up the connection factory within the JNDI namespace.

Old Property: weblogic.jms.ConnectionFactoryName

setJNDIName

public void setJNDIName(java.lang.String name)
                 throws javax.management.InvalidAttributeValueException
Set the JNDI name of the JMS ConnectionFactory. This is the name that is assigned to and used to look up the connection factory within the JNDI namespace.

Legal Value: (value != null) && (value.trim().length() > 0)

getClientId

public java.lang.String getClientId()
Return the client ID for a durable subscriber that uses this ConnectionFactory.

Old Property: weblogic.jms.ConnectionFactoryArgs

setClientId

public void setClientId(java.lang.String id)
                 throws javax.management.InvalidAttributeValueException
Set the client ID for a durable subscriber that uses this ConnectionFactory.

A dynamic MBean attribute

getDefaultPriority

public int getDefaultPriority()
Return the defaultPriority attribute for the connection factory. All messages with a priority of -1 that are produced on a connection created with this factory will receive this value.


setDefaultPriority

public void setDefaultPriority(int defaultPriority)
                        throws javax.management.InvalidAttributeValueException
Set the value of the defaultPriority attribute for the connection factory. All messages with a priority of -1 that are produced on a connection created with this factory will receive this value. This attribute is dynamic. It can be changed at any time. However, changing the value does not affect existing connections. It only affects new connections made with this connection factory.

A dynamic MBean attribute
Default Value: PRIORITY_DEFAULT
Legal Minimum Value: PRIORITY_MINIMUM
Legal Maximum Value: PRIORITY_MAXIMUM

getDefaultTimeToDeliver

public long getDefaultTimeToDeliver()
A time-to-deliver defines the delay in milliseconds between when a message is produced and when it is made visible on its destination. This method sets the value of the defaultTimeToDeliver attribute for the connection factory. All messages produced by a producer created with this factory that have a timeToDeliver of -1 will use this value.


setDefaultTimeToDeliver

public void setDefaultTimeToDeliver(long timeToDeliver)
                             throws javax.management.InvalidAttributeValueException
A time-to-deliver defines the delay in milliseconds between when a message is produced and when it is made visible on its destination. This method sets the value of the defaultTimeToDeliver attribute for the connection factory. All messages produced by a producer created with this factory that have a timeToDeliver of -1 will use this value. This attribute is dynamic. It can be changed at any time. However, changing the value does not affect existing connections. It only affects new connections made with this connection factory.

A dynamic MBean attribute
Default Value: 0
Legal Minimum Value: 0
Legal Maximum Value: java.lang.Long.MAX_VALUE

getDefaultTimeToLive

public long getDefaultTimeToLive()
Return the value of the defaultTimeToLive attribute for the connection factory. All messages with a timeToLive of -1 that are produced on a connection created with this factory will receive this value expressed in milliseconds.


setDefaultTimeToLive

public void setDefaultTimeToLive(long defaultTimeToLive)
                          throws javax.management.InvalidAttributeValueException
Set the value of the defaultTimeToLive attribute for the connection factory. All messages with a timeToLive of -1 that are produced on a connection created with this factory will receive this value expressed in milliseconds. This attribute is dynamic. It can be changed at any time. However, changing the value does not affect existing connections. It only affects new connections made with this connection factory.

A dynamic MBean attribute
Default Value: 0
Legal Minimum Value: 0
Legal Maximum Value: java.lang.Long.MAX_VALUE

getDefaultDeliveryMode

public java.lang.String getDefaultDeliveryMode()
Return the value of the defaultDeliveryMode attribute for the connection factory. All messages with a deliveryMode of null that are produced on a connection created with this factory will receive this value.

Old Property: weblogic.jms.ConnectionFactoryArgs

setDefaultDeliveryMode

public void setDefaultDeliveryMode(java.lang.String defaultDeliveryMode)
                            throws javax.management.InvalidAttributeValueException
Set the value of the defaultDeliveryMode attribute for the connection factory. All messages with a deliveryMode of null that are produced on a connection created with this factory will receive this value. This attribute is dynamic. It can be changed at any time. However, changing the value does not affect existing connections. It only affects new connections made with this connection factory.

A dynamic MBean attribute
Default Value: PERSISTENT
Legal Values: PERSISTENT,NON_PERSISTENT

getDefaultRedeliveryDelay

public long getDefaultRedeliveryDelay()
A redelivery delay defines the delay in milliseconds before rolled back or recovered messages are redelivered. This method returns the value of the defaultRedeliveryDelay attribute for the connection factory. All messages consumed by a consumer created with this factory that have a redeliveryDelay of -1 will use this value.


setDefaultRedeliveryDelay

public void setDefaultRedeliveryDelay(long defaultRedeliveryDelay)
                               throws javax.management.InvalidAttributeValueException
A redelivery delay defines the delay in milliseconds before rolled back or recovered messages are redelivered. This method sets the value of the defaultRedeliveryDelay attribute for the connection factory. All messages consumed by a consumer created with this factory that have a redeliveryDelay of -1 will use this value. This attribute is dynamic. It can be changed at any time. However, changing the value does not affect existing connections. It only affects new connections made with this connection factory.

A dynamic MBean attribute
Default Value: 0
Legal Minimum Value: 0
Legal Maximum Value: java.lang.Long.MAX_VALUE

getTransactionTimeout

public long getTransactionTimeout()
Return the value of the transactionTimeout attribute for the connection factory. All transactions on connections created with this connection factory will have this timeout value expressed in seconds.

Old Property: weblogic.jms.ConnectionFactoryArgs

setTransactionTimeout

public void setTransactionTimeout(long transactionTimeout)
                           throws javax.management.InvalidAttributeValueException
Set the value of the transactionTimeout attribute for the connection factory. All transactions on connections created with this connection factory will have this timeout value expressed in seconds. This attribute is dynamic. it can be changed at any time. However, changing the value does not affect existing connections. It only affects new connections made with this connection factory.

A dynamic MBean attribute
Default Value: 3600
Legal Minimum Value: 0
Legal Maximum Value: java.lang.Integer.MAX_VALUE

isUserTransactionsEnabled

public boolean isUserTransactionsEnabled()
Return the value of the userTransactionsEnabled This value indicates whether or not a connection factory creates sessions that are JTA aware. If true, the associated message producers and message consumers look into the running thread for a transaction context. Otherwise, the current JTA transaction will be ignored. attribute for the connection factory.

Old Property: weblogic.jms.ConnectionFactoryArgs

setUserTransactionsEnabled

public void setUserTransactionsEnabled(boolean userTransactionsEnabled)
                                throws javax.management.InvalidAttributeValueException
Set the value of the userTransactionsEnabled attribute for the connection factory. This value indicates whether or not a connection factory creates sessions that are JTA aware. If set to true, the associated message producers and message consumers look into the running thread for a transaction context. Otherwise, the current JTA transaction will be ignored.

A dynamic MBean attribute
Default Value: false

getAllowCloseInOnMessage

public boolean getAllowCloseInOnMessage()
Return the value of the allowCloseInOnMessage attribute for the connection factory. If set to true, it means you can call stop and close from onMessage without hanging. If set to false, it will cause stop and close to hang if called from onMessage.

Old Property: weblogic.jms.ConnectionFactoryArgs

setAllowCloseInOnMessage

public void setAllowCloseInOnMessage(boolean allowCloseInOnMessage)
                              throws javax.management.InvalidAttributeValueException
Set the value of the allowCloseInOnMessage attribute for the connection factory. Setting this to true means you can call stop and close from onMessage without hanging. Setting this to false will cause stop and close to hang if called from onMessage.

A dynamic MBean attribute
Default Value: false

getMessagesMaximum

public int getMessagesMaximum()
Return the value of the messagesMaximum attribute for the connection factory. This is the maximum number of messages that may exist for an asynchronous session and that have not yet been passed to the message listener. A value of -1 indicates that there is no limit on the number of messages. In this case, however, the limit is set to the amount of remaining virtual memory. When the number of messages reaches the Messages Maximum value: For multicast sessions, new messages are discarded according the policy specified by the Overrun Policy attribute and a DataOverrunException is thrown. For non-multicast sessions, new messages are flow-controlled, or retained on the server until the application can accommodate the messages. For multicast sessions, when a connection is stopped, messages will continue to be delivered, but only until the Messages Maximum value is reached. Once this value is reached, messages will be discarded based on the Overrun policy


setMessagesMaximum

public void setMessagesMaximum(int messagesMaximum)
                        throws javax.management.InvalidAttributeValueException
Set the value of the messagesMaximum attribute for the connection factory. This is the maximum number of messages that may exist for an asynchronous session and that have not yet been passed to the message listener. A value of -1 indicates that there is no limit on the number of messages. In this case, however, the limit is set to the amount of remaining virtual memory. When the number of messages reaches the Messages Maximum value: For multicast sessions, new messages are discarded according the policy specified by the Overrun Policy attribute and a DataOverrunException is thrown. For non-multicast sessions, new messages are flow-controlled, or retained on the server until the application can accommodate the messages. For multicast sessions, when a connection is stopped, messages will continue to be delivered, but only until the Messages Maximum value is reached. Once this value is reached, messages will be discarded based on the Overrun policy This attribute is dynamic. It can be changed at any time. However, changing the value does not affect existing connections. It only affects new connections made with this connection factory.

A dynamic MBean attribute
Default Value: 10
Legal Minimum Value: -1
Legal Maximum Value: java.lang.Integer.MAX_VALUE

getOverrunPolicy

public java.lang.String getOverrunPolicy()
Return the value of the overrunPolicy attribute for the connection factory. This applies to multicast messages. When the number of outstanding messages reaches the Messages Maximum attribute value, messages are discarded based on the specified policy. If set to KeepNew, the most recent messages are given priority over the oldest messages, and the oldest messages are discarded, as needed. If set to KeepOld, the oldest messages are given priority over the most recent messages, and the most recent messages are discarded, as needed. Message age is defined by the order of receipt, not by the JMSTimestamp value.


setOverrunPolicy

public void setOverrunPolicy(java.lang.String policy)
                      throws javax.management.InvalidAttributeValueException
Set the value of the overrunPolicy attribute for the connection factory. This applies to multicast messages. When the number of outstanding messages reaches the Messages Maximum attribute value, messages are discarded based on the specified policy. If set to KeepNew, the most recent messages are given priority over the oldest messages, and the oldest messages are discarded, as needed. If set to KeepOld, the oldest messages are given priority over the most recent messages, and the most recent messages are discarded, as needed. This attribute is dynamic. it can be changed at any time. However, changing the value does not affect existing connections. It only affects new connections made with this connection factory. KEEP_OLD KEEP_NEW

A dynamic MBean attribute
Default Value: weblogic.management.configuration.JMSConstants.KEEP_OLD
Legal Values: weblogic.management.configuration.JMSConstants.KEEP_OLD,weblogic.management.configuration.JMSConstants.KEEP_NEW

isXAConnectionFactoryEnabled

public boolean isXAConnectionFactoryEnabled()
Return the value of the XAConnectionFactoryEnabled attribute for the connection factory. If true, an XAConnection Factory will be returned instead of a ConnectionFactory.


setXAConnectionFactoryEnabled

public void setXAConnectionFactoryEnabled(boolean XAConnectionFactoryEnabled)
                                   throws javax.management.InvalidAttributeValueException
Set the value of the XAConnectionFactoryEnabled attribute for the connection factory. If true, an XAConnection Factory will be returned instead of a ConnectionFactory.

Default Value: false
Legal Value: ( (value && ((weblogic.management.configuration.JMSConnectionFactoryMBean)self).isUserTransactionsEnabled()) || !value )

getAcknowledgePolicy

public java.lang.String getAcknowledgePolicy()
Return the value of the acknowledgePolicy attribute for the connection factory. This attribute works around a change in the JMS specification. Specifically, the specification allowed users to acknowledge all messages before and including the message geing acknowledged. The specification was changed so that acknowledging any message acknowledges all messages ever received (even those received after the message being acknowledge). An acknowledge policy of ACKNOWLEDGE_PREVIOUS retains the old behavior (acknowledge all message up to and including the message being acknowledged). An acknowledge policy of ACKNOWLEDGE_ALL yields the new behavior, where all messages received by the given session are acknowledged regardless of which message is being used to effect the acknowledge.


setAcknowledgePolicy

public void setAcknowledgePolicy(java.lang.String policy)
                          throws javax.management.InvalidAttributeValueException
Set the value of the acknowldegePolicy attribute for the connection factory. This attribute works around a change in the JMS specification. Specifically, the specification allowed users to acknowledge all messages before and including the message geing acknowledged. The specification was changed so that acknowledging any message acknowledges all messages ever received (even those received after the message being acknowledge). Setting the acknowledge policy to ACKNOWLEDGE_PREVIOUS retains the old behavior (acknowledge all message up to and including the message being acknowledged). Setting the acknowledge policy to ACKNOWLEDGE_ALL yields the new behavior, where all messages received by the given session are acknowledged regardless of which message is being used to effect the acknowledge.

A dynamic MBean attribute
Default Value: weblogic.management.configuration.JMSConstants.ACKNOWLEDGE_ALL
Legal Values: weblogic.management.configuration.JMSConstants.ACKNOWLEDGE_ALL,weblogic.management.configuration.JMSConstants.ACKNOWLEDGE_PREVIOUS

Documentation is available at
http://download.oracle.com/docs/cd/E13222_01/wls/docs61

WebLogic classes and methods that do not appear in this reference are not public and are not supported.