Spring.NET 1.3.0 RC1 for .NET 2.0 API Reference

SimpleMessageListenerContainer Members

SimpleMessageListenerContainer overview

Public Static (Shared) Fields

DEFAULT_MAX_RECOVERY_TIME The total time connection recovery will be attempted.
DEFAULT_RECOVERY_INTERVAL The default recovery time interval between connection reconnection attempts

Public Instance Constructors

SimpleMessageListenerContainer Constructor Initializes a new instance of the SimpleMessageListenerContainer class.

Public Instance Properties

AcceptMessagesWhileStopping (inherited from AbstractMessageListenerContainer) Gets or sets a value indicating whether to accept messages while the listener container is in the process of stopping.
Active (inherited from AbstractListenerContainer) Gets a value indicating whether this container is currently active, that is, whether it has been set up but not shut down yet.
AutoStartup (inherited from AbstractListenerContainer) Set whether to automatically start the listener after initialization. Default is "true"; set this to "false" to allow for manual startup.
ClientId (inherited from AbstractListenerContainer) Gets or sets the client id for a shared Connection created and used by this container.
ConcurrentConsumers Specify the number of concurrent consumers to create. Default is 1.
ConnectionFactory (inherited from EmsAccessor) Gets or sets the connection factory to use for obtaining EMS Connections.
Destination (inherited from AbstractMessageListenerContainer) Gets or sets the destination to receive messages from. Will be
null
if the configured destination is not an actual Destination type; c.f. DestinationName when the destination is a String.
DestinationName (inherited from AbstractMessageListenerContainer) Gets or sets the name of the destination to receive messages from. Will be
null
if the configured destination is not a string type; c.f. Destination when it is an actual Destination object.
DestinationResolver (inherited from EmsDestinationAccessor) Gets or sets the destination resolver that is to be used to resolve Destination references for this accessor.
DurableSubscriptionName (inherited from AbstractMessageListenerContainer) Gets or sets the name of the durable subscription to create.
ExceptionListener (inherited from AbstractMessageListenerContainer) Gets or sets the exception listener to notify in case of a EMSException thrown by the registered message listener or the invocation infrastructure.
ExposeListenerSession (inherited from AbstractMessageListenerContainer) Gets or sets a value indicating whether to expose listener session to a registered ISessionAwareMessageListener as well as to EmsTemplate calls.
IsRunning (inherited from AbstractListenerContainer) Gets a value indicating whether this container is currently running, that is, whether it has been started and not stopped yet.
MaxRecoveryTime Sets the max recovery time to try reconnection attempts. The default is 10 minutes.
MessageListener (inherited from AbstractMessageListenerContainer) Gets or sets the message listener to register.
MessageSelector (inherited from AbstractMessageListenerContainer) Gets or sets the message selector.
ObjectName (inherited from AbstractListenerContainer) Set the name of the object in the object factory that created this object.
PubSubDomain (inherited from EmsDestinationAccessor) Gets or sets a value indicating whether Publish/Subscribe domain (Topics) is used. Otherwise, the Point-to-Point domain (Queues) is used.
PubSubNoLocal Gets or sets a value indicating whether to inhibit the delivery of messages published by its own connection. Default is "false".
RecoveryInterval Sets the time interval between connection recovery attempts. The default is 5 seconds.
SessionAcknowledgeMode (inherited from EmsAccessor) Gets or sets the session acknowledge mode for EMS Sessions including whether or not the session is transacted
SessionTransacted (inherited from EmsAccessor) Set the transaction mode that is used when creating a EMS Session. Default is "false".
SubscriptionDurable (inherited from AbstractMessageListenerContainer) Gets or sets a value indicating whether the subscription is durable.

Public Instance Methods

AfterPropertiesSet (inherited from AbstractListenerContainer) Call base class method, then ValidateConfiguration and then Initialize
Dispose (inherited from AbstractListenerContainer) Calls Shutdown when the application context destroys the container instance.
Equals (inherited from Object)Determines whether the specified Object is equal to the current Object.
ExecuteListener (inherited from AbstractMessageListenerContainer) Executes the specified listener, committing or rolling back the transaction afterwards (if necessary).
GetHashCode (inherited from Object)Serves as a hash function for a particular type. GetHashCode is suitable for use in hashing algorithms and data structures like a hash table.
GetType (inherited from Object)Gets the Type of the current instance.
Initialize (inherited from AbstractListenerContainer) Initializes this container. Creates a Connection, starts the Connection (if the property AutoStartup hasn't been turned off), and calls DoInitialize.
OnExceptionIExceptionListener implementation, invoked by the EMS provider in case of connection failures. Re-initializes this listener container's shared connection and its sessions and consumers.
ResolveDestinationName (inherited from EmsDestinationAccessor) Resolves the given destination name to a EMS destination.
Shutdown (inherited from AbstractListenerContainer) Stop the shared connection, call DoShutdown, and close this container.
Start (inherited from AbstractListenerContainer) Starts this container.
Stop (inherited from AbstractListenerContainer) Stops this container.
ToString (inherited from Object)Returns a String that represents the current Object.

Protected Instance Fields

lifecycleMonitor (inherited from AbstractListenerContainer) The monitor object to lock on when performing operations that update the lifecycle of the container.
sharedConnectionMonitor (inherited from AbstractListenerContainer) The monitor object to lock on when performing operations on the connection.

Protected Instance Properties

RunningAllowed (inherited from AbstractListenerContainer) Gets a value indicating whether this container's listeners are generally allowed to run.
SharedConnection (inherited from AbstractListenerContainer) Gets the shared connection maintained by this container. Available after initialization.
SharedConnectionEnabled Always use a shared EMS connection

Protected Instance Methods

CheckMessageListener (inherited from AbstractMessageListenerContainer) Checks the message listener, throwing an exception if it does not correspond to a supported listener type. By default, only a standard JMS MessageListener object or a Spring ISessionAwareMessageListener object will be accepted.
CommitIfNecessary (inherited from AbstractMessageListenerContainer) Perform a commit or message acknowledgement, as appropriate
CreateConnection (inherited from EmsAccessor) Creates the connection via the ConnectionFactory.
CreateConsumer Creates a MessageConsumer for the given Session and Destination.
CreateSession (inherited from EmsAccessor) Creates the session for the given Connection
CreateSharedConnection (inherited from AbstractListenerContainer) Creates the shared connection for this container.
DoExecuteListener (inherited from AbstractMessageListenerContainer) Executes the specified listener, committing or rolling back the transaction afterwards (if necessary).
DoInitialize Creates the specified number of concurrent consumers, in the form of a JMS Session plus associated MessageConsumer
DoInvokeListener (inherited from AbstractMessageListenerContainer)Overloaded. Invoke the specified listener as Spring ISessionAwareMessageListener, exposing a new EMS Session (potentially with its own transaction) to the listener if demanded.
DoShutdown Close the message consumers and sessions.
DoStart Re-initializes this container's EMS message consumers, if not initialized already.
DoStop (inherited from AbstractListenerContainer) Notify all invoker tasks and stop the shared Connection, if any.
EstablishSharedConnection (inherited from AbstractListenerContainer) Establishes a shared Connection for this container.
Finalize (inherited from Object)Allows an Object to attempt to free resources and perform other cleanup operations before the Object is reclaimed by garbage collection.
HandleListenerException (inherited from AbstractMessageListenerContainer) Handle the given exception that arose during listener execution.
InitializeConsumers Initialize the Sessions and MessageConsumers for this container.
InvokeExceptionListener (inherited from AbstractMessageListenerContainer) Invokes the registered exception listener, if any.
InvokeListener (inherited from AbstractMessageListenerContainer) Invokes the specified listener: either as standard EMS MessageListener or (preferably) as Spring ISessionAwareMessageListener.
IsClientAcknowledge (inherited from EmsAccessor) Returns whether the Session is in client acknowledgement mode.
IsSessionLocallyTransacted (inherited from AbstractMessageListenerContainer) Determines whether the given Session is locally transacted, that is, whether its transaction is managed by this listener container's Session handling and not by an external transaction coordinator.
MemberwiseClone (inherited from Object)Creates a shallow copy of the current Object.
PrepareSharedConnection Registers this listener container as EMS ExceptionListener on the shared connection.
RefreshConnectionUntilSuccessful Refresh the underlying Connection, not returning before an attempt has been successful. Called in case of a shared Connection as well as without shared Connection, so either needs to operate on the shared Connection or on a temporary Connection that just gets established for validation purposes.
RefreshSharedConnection (inherited from AbstractListenerContainer) Refreshes the shared connection that this container holds.
RollbackIfNecessary (inherited from AbstractMessageListenerContainer) Perform a rollback, if appropriate.
RollbackOnExceptionIfNecessary (inherited from AbstractMessageListenerContainer) Perform a rollback, handling rollback excepitons properly.
SleepInBetweenRecoveryAttempts The amount of time to sleep in between recovery attempts.
StartSharedConnection (inherited from AbstractListenerContainer) Starts the shared connection.
StopSharedConnection (inherited from AbstractListenerContainer) Stops the shared connection.
ValidateConfiguration Call base class for valdation and then check that if the subscription is durable that the number of concurrent consumers is equal to one.

See Also

SimpleMessageListenerContainer Class | Spring.Messaging.Ems.Listener Namespace