Uploaded image for project: 'JGroups'
  1. JGroups
  2. JGRP-1488

NPE in concurrent channel creation with shared transport

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved (View Workflow)
    • Priority: Major
    • Resolution: Done
    • Affects Version/s: 3.0.10
    • Fix Version/s: 3.0.11, 3.1
    • Labels:
      None

      Description

      The NPE below is caused by calling GET_LOCAL_ADDRESS on all up_prots in a shared transport. However, when we create a new JChannel, its protocol stack is added to up_prots before the top_prot (RSVP in the case below) is connected to ProtocolStack.
      SOLUTION: connect the top protocol to ProtocolStack before connecting all protocols to each other and adding the bottom prot to up_prots in TP.

      11:53:23,057 ERROR [org.jboss.msc.service.fail] (ChannelService lifecycle - 1) MSC00001: Failed to start service jboss.jgroups.channel.capedwarf: org.jboss.msc.service.StartException in service jboss.jgroups.channel.capedwarf: java.lang.NullPointerException
      at org.jboss.as.clustering.msc.AsynchronousService$1.run(AsynchronousService.java:68) [jboss-as-clustering-common-7.2.0.Alpha1-SNAPSHOT.jar:7.2.0.Alpha1-SNAPSHOT]
      at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) [classes.jar:1.6.0_33]
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) [classes.jar:1.6.0_33]
      at java.lang.Thread.run(Thread.java:680) [classes.jar:1.6.0_33]
      at org.jboss.threads.JBossThread.run(JBossThread.java:122) [jboss-threads-2.0.0.GA.jar:2.0.0.GA]
      Caused by: java.lang.NullPointerException
      at org.jgroups.protocols.RSVP.up(RSVP.java:192) [jgroups-3.0.9.Final.jar:3.0.9.Final]
      at org.jgroups.protocols.FRAG2.up(FRAG2.java:181) [jgroups-3.0.9.Final.jar:3.0.9.Final]
      at org.jgroups.protocols.FlowControl.up(FlowControl.java:418) [jgroups-3.0.9.Final.jar:3.0.9.Final]
      at org.jgroups.protocols.FlowControl.up(FlowControl.java:418) [jgroups-3.0.9.Final.jar:3.0.9.Final]
      at org.jgroups.protocols.pbcast.GMS.up(GMS.java:889) [jgroups-3.0.9.Final.jar:3.0.9.Final]
      at org.jgroups.protocols.pbcast.STABLE.up(STABLE.java:265) [jgroups-3.0.9.Final.jar:3.0.9.Final]
      at org.jgroups.protocols.UNICAST2.up(UNICAST2.java:383) [jgroups-3.0.9.Final.jar:3.0.9.Final]
      at org.jgroups.protocols.pbcast.NAKACK.up(NAKACK.java:602) [jgroups-3.0.9.Final.jar:3.0.9.Final]
      at org.jgroups.protocols.BARRIER.up(BARRIER.java:148) [jgroups-3.0.9.Final.jar:3.0.9.Final]
      at org.jgroups.protocols.VERIFY_SUSPECT.up(VERIFY_SUSPECT.java:143) [jgroups-3.0.9.Final.jar:3.0.9.Final]
      at org.jgroups.protocols.FD.up(FD.java:273) [jgroups-3.0.9.Final.jar:3.0.9.Final]
      at org.jgroups.protocols.FD_SOCK.up(FD_SOCK.java:288) [jgroups-3.0.9.Final.jar:3.0.9.Final]
      at org.jgroups.protocols.MERGE2.up(MERGE2.java:205) [jgroups-3.0.9.Final.jar:3.0.9.Final]
      at org.jgroups.protocols.Discovery.up(Discovery.java:499) [jgroups-3.0.9.Final.jar:3.0.9.Final]
      at org.jgroups.protocols.TP.fetchLocalAddresses(TP.java:1529) [jgroups-3.0.9.Final.jar:3.0.9.Final]
      at org.jgroups.protocols.TP.start(TP.java:939) [jgroups-3.0.9.Final.jar:3.0.9.Final]
      at org.jgroups.protocols.UDP.start(UDP.java:225) [jgroups-3.0.9.Final.jar:3.0.9.Final]
      at org.jgroups.stack.ProtocolStack.startStack(ProtocolStack.java:938) [jgroups-3.0.9.Final.jar:3.0.9.Final]
      at org.jgroups.JChannel.startStack(JChannel.java:841) [jgroups-3.0.9.Final.jar:3.0.9.Final]
      at org.jgroups.JChannel.connect(JChannel.java:277) [jgroups-3.0.9.Final.jar:3.0.9.Final]
      at org.jgroups.JChannel.connect(JChannel.java:261) [jgroups-3.0.9.Final.jar:3.0.9.Final]
      at org.jboss.as.clustering.jgroups.subsystem.ChannelService.start(ChannelService.java:44) [jboss-as-clustering-jgroups-7.2.0.Alpha1-SNAPSHOT.jar:7.2.0.Alpha1-SNAPSHOT]
      at org.jboss.as.clustering.msc.AsynchronousService$1.run(AsynchronousService.java:65) [jboss-as-clustering-common-7.2.0.Alpha1-SNAPSHOT.jar:7.2.0.Alpha1-SNAPSHOT]
      ... 4 more

        Attachments

          Activity

            People

            Assignee:
            belaban Bela Ban
            Reporter:
            belaban Bela Ban
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: