glassfish
  1. glassfish
  2. GLASSFISH-20697

If JMS connection factory setting is changed, all pooled connections are disconnected

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 4.0
    • Fix Version/s: 4.1
    • Component/s: jms
    • Labels:
      None
    • Environment:

      Windows 7
      Glassfish 4.0
      JDK 7

      Description

      When a JMS connection is created on Web or EJB container, connections are pooled in the JMS connection factory.

      If a JMS connection factory setting (ie, maximum pool size) is changed, all the pooled connections are disconnected.

      Conditions for reproducing bug:
      (1) Create a new connection using JMS connection factory on Web or EJB container. AND
      (2) Update following settings for the first time.

      • Initial and Minimum Pool Size
      • Maximum Pool Size
      • Pool Resize Quantity
      • Idle Timeout
      • Max Wait Time
      • On Any Failure
      • Transaction Support
      • Additional Properties

      Note that the connections are not disconnected when updating the JMS connection factory setting on second time or later while the server instance is running.

      Steps reproduce:
      1. Create a Connection Factory.
      asadmin create-jms-resource --restype javax.jms.Queue --property Name=PhysicalQueue jms/Queue
      asadmin create-jms-resource --restype javax.jms.ConnectionFactory jms/ConnectionFactory

      2. Set the Connection Pool Initial and Minimum Pool Size. This is set as 8 so that it is easier to find bug which causes disconnection in pool.
      asadmin set resources.connector-connection-pool.jms/ConnectionFactory-Connection-Pool.steady-pool-size=8

      3. Check the number of connections.
      imqcmd list cxn

      4. Deploy the test program.
      asadmin deploy cfdisconnected.war

      5. Open web browser and connect to the Servlet.
      http://localhost:8080/cfdisconnected/HelloWorld

      6. Check the number of connections.
      imqcmd list cxn
      There are 8 more connections compared with step 3.

      7. Change the Maximum Pool Size from default (250) to 16.
      asadmin set resources.connector-connection-pool.jms/ConnectionFactory-Connection-Pool.max-pool-size=16

      8. Check the number of connections.
      imqcmd list cxn
      The bug is found at the step. The 8 connections have been disconnected and not listed.
      Expected result is that the 8 connections are maintained.

        Activity

        tak09 created issue -
        David Zhao made changes -
        Field Original Value New Value
        Status Open [ 1 ] Resolved [ 5 ]
        Resolution Invalid [ 6 ]
        David Zhao made changes -
        Resolution Invalid [ 6 ]
        Status Resolved [ 5 ] Reopened [ 4 ]
        Jagadish made changes -
        Assignee David Zhao [ liang.x.zhao ] Jagadish [ jr158900 ]
        Jagadish made changes -
        Status Reopened [ 4 ] Resolved [ 5 ]
        Fix Version/s 4.0.1 [ 16061 ]
        Resolution Fixed [ 1 ]
        Romain Grécourt made changes -
        Fix Version/s 4.1 [ 16387 ]
        Fix Version/s 4.0.1 [ 16061 ]

          People

          • Assignee:
            Jagadish
            Reporter:
            tak09
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: