Uploaded image for project: 'AMQ Broker'
  1. AMQ Broker
  2. ENTMQBR-2598

Broker throws NullPointerException and fail to start when address.txt is blank

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • Major
    • AMQ 7.4.0.GA
    • AMQ 7.3.0.GA, AMQ 7.2.4.GA
    • broker-core
    • None

    Description

      When address.txt under paging directory is empty(How this happens is still unknown)

      The broker throws NullPointerException and fails to start.

      2019-06-20 10:31:55,155 ERROR [org.apache.activemq.artemis.core.server] AMQ224000: Failure in initialisation: java.lang.NullPointerException
      	at org.apache.activemq.artemis.api.core.SimpleString.<init>(SimpleString.java:84) [artemis-commons-2.6.3.redhat-00020.jar:2.6.3.redhat-00020]
      	at org.apache.activemq.artemis.core.paging.impl.PagingStoreFactoryNIO.reloadStores(PagingStoreFactoryNIO.java:220) [artemis-server-2.6.3.redhat-00020.jar:2.6.3.redhat-00020]
      	at org.apache.activemq.artemis.core.paging.impl.PagingManagerImpl.reloadStores(PagingManagerImpl.java:304) [artemis-server-2.6.3.redhat-00020.jar:2.6.3.redhat-00020]
      	at org.apache.activemq.artemis.core.paging.impl.PagingManagerImpl.start(PagingManagerImpl.java:408) [artemis-server-2.6.3.redhat-00020.jar:2.6.3.redhat-00020]
      	at org.apache.activemq.artemis.core.server.impl.ActiveMQServerImpl.initialisePart1(ActiveMQServerImpl.java:2351) [artemis-server-2.6.3.redhat-00020.jar:2.6.3.redhat-00020]
      	at org.apache.activemq.artemis.core.server.impl.LiveOnlyActivation.run(LiveOnlyActivation.java:64) [artemis-server-2.6.3.redhat-00020.jar:2.6.3.redhat-00020]
      	at org.apache.activemq.artemis.core.server.impl.ActiveMQServerImpl.internalStart(ActiveMQServerImpl.java:544) [artemis-server-2.6.3.redhat-00020.jar:2.6.3.redhat-00020]
      	at org.apache.activemq.artemis.core.server.impl.ActiveMQServerImpl.start(ActiveMQServerImpl.java:481) [artemis-server-2.6.3.redhat-00020.jar:2.6.3.redhat-00020]
      	at org.apache.activemq.artemis.integration.FileBroker.start(FileBroker.java:111) [artemis-cli-2.6.3.redhat-00020.jar:2.6.3.redhat-00020]
      	at org.apache.activemq.artemis.cli.commands.Run.execute(Run.java:85) [artemis-cli-2.6.3.redhat-00020.jar:2.6.3.redhat-00020]
      	at org.apache.activemq.artemis.cli.Artemis.internalExecute(Artemis.java:149) [artemis-cli-2.6.3.redhat-00020.jar:2.6.3.redhat-00020]
      	at org.apache.activemq.artemis.cli.Artemis.execute(Artemis.java:97) [artemis-cli-2.6.3.redhat-00020.jar:2.6.3.redhat-00020]
      	at org.apache.activemq.artemis.cli.Artemis.execute(Artemis.java:124) [artemis-cli-2.6.3.redhat-00020.jar:2.6.3.redhat-00020]
      	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [rt.jar:1.8.0_45]
      	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) [rt.jar:1.8.0_45]
      	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) [rt.jar:1.8.0_45]
      	at java.lang.reflect.Method.invoke(Method.java:497) [rt.jar:1.8.0_45]
      	at org.apache.activemq.artemis.boot.Artemis.execute(Artemis.java:129) [artemis-boot.jar:2.6.3.redhat-00020]
      	at org.apache.activemq.artemis.boot.Artemis.main(Artemis.java:49) [artemis-boot.jar:2.6.3.redhat-00020]
      

      Instead of throwing a NullPointerException broker should try to handle blank address.txt and recover the messages.

      Attachments

        Activity

          People

            rhn-support-jbertram Justin Bertram
            rhn-support-shsingh Shailendra Singh
            Mikhail Krutov Mikhail Krutov
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: