Application Server 3  4  5 and 6
  1. Application Server 3 4 5 and 6
  2. JBAS-6783

NPE when setting 'messageCounterHistoryDayLimit' prop on JMS Topics

    Details

    • Similar Issues:
      Show 10 results 

      Description

      Setting the "MessageCounterHistoryDayLimit" in a topic deployment descriptor triggers an NPE:

      <attribute name="MessageCounterHistoryDayLimit">10</attribute>

      Caused by: java.lang.NullPointerException
      at org.jboss.jms.server.destination.ManagedTopic.getMessageCounters(ManagedTopic.java:159)
      at org.jboss.jms.server.destination.ManagedTopic.setMessageCounterHistoryDayLimit(ManagedTopic.java:191)

      Also See https://jira.jboss.org/jira/browse/JBAS-6721?focusedCommentId=12460246#action_12460246 .

      The problem is that the property is only expected to be set at runtime, AFTER the topic has started:

      Collection queues = serverPeer.getPostOfficeInstance().getQueuesForCondition(new JMSCondition(false, name), true);

        Gliffy Diagrams

          Issue Links

            Activity

            Hide
            Jason Greene added a comment -

            There will not be a 5.1.1, moving to 5.2 for now

            Show
            Jason Greene added a comment - There will not be a 5.1.1, moving to 5.2 for now
            Hide
            Jason Greene added a comment -

            The fix should be to change the setMessageCounterHistoryDayLimit to not update the counters if they don't exist yet (serverPeer doesn't exist yet)

            Show
            Jason Greene added a comment - The fix should be to change the setMessageCounterHistoryDayLimit to not update the counters if they don't exist yet (serverPeer doesn't exist yet)
            Hide
            Yong Hao Gao added a comment -

            fixed

            Show
            Yong Hao Gao added a comment - fixed

              People

              • Assignee:
                Yong Hao Gao
                Reporter:
                Charles Crouch
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Development