LibraryLink ToToggle FramesPrintFeedback

Listener Containers

Both the generic consumer endpoint and the SOAP consumer endpoint use Spring listener containers to handle incoming messages. The listener container handles the details of receiving messages from the destination, participating in transactions, and controlling the threads used to dispatch messages to the endpoint.

FUSE ESB's JMS consumer endpoints support three types of listener containers:

By default, consumer endpoints use the default listener container. If you want to configure the an endpoint to use a different listener container, you specify that using the endpoint's listenerType attribute. Table 3.1 lists the values for the listenerType attribute.


Example 3.4 shows configuration for SOAP consumer that uses the simple listener container.


There are several ways of tuning the performance of a generic consumer endpoint or a SOAP consumer endpoint. They are all controlled by the listener container used by the endpoint.

Table 3.2 describes the attributes used to tune endpoint performance.


Example 3.5 shows an example of a generic consumer that allows consumer level message caching and only tries once to receive a message.


The server session listener container uses the JMS ServerSessionPool SPI to tune an endpoint's performance. In order for the listener container to function,k it uses a ServerSessionFactory object. By default, the FUSE ESB JMS BC uses the Spring framework's SimpleServerSessionFactory object. This server session factory creates a new JMS ServerSession object with a new JMS session everytime it is called.

You can configure the endpoint to use a different server session factory using the serverSessionFactory attribute. This attribute provides a reference to the bean configuring the ServerSessionFactory object.

[Note]Note

You can also explicitly configure the endpoint's ServerSessionFactory object by adding a serverSessionFactory child element to the endpoint's configuration. This element would wrap the ServerSessionFactory object's configuration bean.

Example 3.6 shows an example of configuring an endpoint to use the Spring framework's CommonsPoolServerSessionFactory object as a session factory.