Tuning messaging performance for the default messaging provider

To help optimize performance, you can set tuning properties that control the performance of message-driven beans and other messaging applications.

About this task

To optimize the performance of messaging with the default messaging provider, you can use the administrative console to set various parameters. You can also set these parameters by using the wsadmin tool.

[z/OS]On z/OS®, the performance of messaging applications is affected by the number of servants, which can vary dynamically, and the distribution of work between servants. For more information about configuring and managing the number of servants and the distribution of work between servants, see Tuning the application serving environment.

Procedure

  • Monitor MDB thread pool size for the default messaging provider.

    You might experience a performance bottleneck if there are insufficient threads available for the message-driven beans. There is a trade-off between providing sufficient threads to maximize the throughput of messages and configuring too many threads, which can lead to CPU starvation of the threads in the application server. If you notice that the throughput for express nonpersistent, reliable nonpersistent, or reliable persistent messaging has fallen as a result of increasing the size of the SIBJMSRAThreadPool thread pool, then decrease the size of the thread pool and reassess the message throughput.

    1. View or change the number of threads in the default thread pool for an application server.
      By default, message-driven beans use the SIBJMSRAThreadPool thread pool.
      1. Click Servers > Server Types > WebSphere application servers > server_name > [Additional Properties] Thread Pools > SIBJMSRAThreadPool. By default the Minimum size value is set to 35 and the Maximum size value is set to 41.
      2. Change the Maximum size value, then click OK.
    2. Optional: Create your own thread pool.
      The default thread pool is also used by other WebSphere Application Server components, so you might want to define a separate thread pool for the message-driven beans. This reduces thread contention for the default thread pool.
      1. Click Servers -> Server Types -> WebSphere application servers -> server_name -> [Additional Properties] Thread Pools.
      2. Create a new thread pool.
      3. Create sufficient threads to support the maximum amount of concurrent work for the message-driven beans.
      4. Change the SIB JMS Resource Adapter to use the new thread pool:
        1. Click Resources -> Resource Adapters -> Resource adapters.
        2. If you cannot see any SIB JMS Resource Adapter instances in the list, expand Preferences and enable Show built-in resources.
        3. Select the SIB JMS Resource Adapter with the appropriate scope depending upon the scope of the connection factories.
        4. Add the name of the new thread pool in the Thread pool alias box.
        5. Click Apply .
    3. Save your changes to the master configuration.
  • Tune MDB performance with the default messaging provider.
    1. Click Resources -> JMS -> Activation specifications -> activation_specification_name.
    2. Set the maximum batch size for this activation specification.

      Delivering batches of messages to each MDB endpoint can improve performance, particularly when used with Acknowledge mode set to Duplicates-ok auto-acknowledge. However, if message ordering must be retained across failed deliveries, set this parameter to 1.

    3. Set the maximum number of concurrent endpoints for this activation specification.

      The maximum concurrent endpoints parameter controls the amount of concurrent work that can be processed by a message bean. The parameter is used with message-driven beans. Increasing the number of concurrent endpoints can improve performance but can increase the number of threads in use at one time. To benefit from a change in this parameter, there should be sufficient threads available in the MDB thread pool to support the concurrent work. However, if message ordering must be retained across failed deliveries, set this parameter to 1.

    4. Save your changes to the master configuration.
    For additional information about tuning the throttling of message-driven beans, including controlling the maximum number of instances of each message bean and the message batch size for serial delivery, see Configuring MDB or SCA throttling for the default messaging provider.
  • Change the maximum connections in a connection factory for the default messaging provider.

    The maximum connections parameter limits the number of local connections. The default is 10. This parameter should be set to a number equal to or greater than the number of threads (enterprise beans) concurrently sending messages.

    1. Click Resources -> JMS -> Topic connection factories -> factory_name > [Additional Properties] Connection pool properties.
    2. Enter the required value in the Maximum connections field.
    3. Click Apply.
    4. Save your changes to the master configuration.