Uploaded image for project: 'bgpcep'
  1. bgpcep
  2. BGPCEP-550

bgp:show-stats Karaf CLI causes NPE

    XMLWordPrintable

Details

    • Bug
    • Status: Resolved
    • Resolution: Done
    • Bugzilla Migration
    • Bugzilla Migration
    • BGP
    • None
    • Operating System: All
      Platform: All

    • 6737

    Description

      Seen when controller has 2 peers, one connected, one not

      opendaylight-user@root>
      opendaylight-user@root>bgp:show-stats
      Attribute | Value
      ---------------------------------------------------------------------------------------------------------------------------------------------------------
      Object Name | org.opendaylight.controller:instanceName=example-bgp-peer-2,moduleFactoryName=bgp-peer,type=RuntimeBean
      HoldtimeCurrent | 180
      KeepaliveCurrent | 60
      SessionDuration | 0:00:39:10
      SessionState | UP
      MessagesStats.ErrorMsgsSent | 0
      MessagesStats.ErrorMsgsReceived | 0
      MessagesStats.KeepAliveMsgsSent | Counter32 [_value=37]
      MessagesStats.KeepAliveMsgsReceived | Counter32 [_value=38]
      MessagesStats.TotalMsgsSent | Counter32 [_value=39]
      MessagesStats.TotalMsgsReceived | Counter32 [_value=42]
      MessagesStats.UpdateMsgsSent | Counter32 [_value=0]
      MessagesStats.UpdateMsgsReceived | Counter32 [_value=4]
      PeerPreferences.AddPathCapability | false
      PeerPreferences.AS | AsNumber [_value=64496]
      PeerPreferences.BgpExtendedMessageCapability | false
      PeerPreferences.BgpId | Ipv4Address [_value=192.168.2.1]
      PeerPreferences.FourOctetAsCapability | true
      PeerPreferences.GrCapability | false
      PeerPreferences.Port | PortNumber [_value=34820]
      PeerPreferences.RouteRefreshCapability | true
      SpeakerPreferences.AddPathCapability | true
      SpeakerPreferences.AS | AsNumber [_value=64496]
      SpeakerPreferences.BgpExtendedMessageCapability | true
      SpeakerPreferences.BgpId | Ipv4Address [_value=10.18.162.90]
      SpeakerPreferences.FourOctetAsCapability | true
      SpeakerPreferences.GrCapability | false
      SpeakerPreferences.Port | PortNumber [_value=1790]
      SpeakerPreferences.RouteRefreshCapability | true
      Error executing command: java.lang.NullPointerException
      opendaylight-user@root>

      2016-09-16 22:14:56,888 | ERROR | l for user karaf | ShellUtil | 27 - org.apache.karaf.shell.console - 3.0.7 | Exception caught while executing command
      java.lang.NullPointerException
      at org.opendaylight.protocol.bgp.cli.utils.BgpCliUtils.displayAll(BgpCliUtils.java:40)
      at org.opendaylight.protocol.bgp.cli.ShowBGPStatsCommandProvider.onExecution(ShowBGPStatsCommandProvider.java:26)
      at org.opendaylight.protocol.bgp.cli.AbstractStatsCommandProvider.lambda$doExecute$0(AbstractStatsCommandProvider.java:33)
      at java.lang.Iterable.forEach(Iterable.java:75)[:1.8.0_72-internal]
      at org.opendaylight.protocol.bgp.cli.AbstractStatsCommandProvider.doExecute(AbstractStatsCommandProvider.java:32)
      at org.apache.karaf.shell.console.AbstractAction.execute(AbstractAction.java:33)[27:org.apache.karaf.shell.console:3.0.7]
      at org.apache.karaf.shell.console.OsgiCommandSupport.execute(OsgiCommandSupport.java:39)[27:org.apache.karaf.shell.console:3.0.7]
      at org.apache.karaf.shell.commands.basic.AbstractCommand.execute(AbstractCommand.java:33)[27:org.apache.karaf.shell.console:3.0.7]
      at Proxy68cf3053_ba0f_432d_a37c_2ad89a476d87.execute(Unknown Source)[:]
      at Proxy68cf3053_ba0f_432d_a37c_2ad89a476d87.execute(Unknown Source)[:]
      at org.apache.felix.gogo.runtime.CommandProxy.execute(CommandProxy.java:78)[27:org.apache.karaf.shell.console:3.0.7]
      at org.apache.felix.gogo.runtime.Closure.executeCmd(Closure.java:480)[27:org.apache.karaf.shell.console:3.0.7]
      at org.apache.felix.gogo.runtime.Closure.executeStatement(Closure.java:406)[27:org.apache.karaf.shell.console:3.0.7]
      at org.apache.felix.gogo.runtime.Pipe.run(Pipe.java:108)[27:org.apache.karaf.shell.console:3.0.7]
      at org.apache.felix.gogo.runtime.Closure.execute(Closure.java:182)[27:org.apache.karaf.shell.console:3.0.7]
      at org.apache.felix.gogo.runtime.Closure.execute(Closure.java:119)[27:org.apache.karaf.shell.console:3.0.7]
      at org.apache.felix.gogo.runtime.CommandSessionImpl.execute(CommandSessionImpl.java:94)
      at org.apache.karaf.shell.console.impl.jline.ConsoleImpl.run(ConsoleImpl.java:210)
      at org.apache.karaf.shell.console.impl.jline.LocalConsoleManager$2$1$1.run(LocalConsoleManager.java:109)
      at java.security.AccessController.doPrivileged(Native Method)[:1.8.0_72-internal]
      at org.apache.karaf.jaas.modules.JaasHelper.doAs(JaasHelper.java:57)[28:org.apache.karaf.jaas.modules:3.0.7]
      at org.apache.karaf.shell.console.impl.jline.LocalConsoleManager$2$1.run(LocalConsoleManager.java:102)[27:org.apache.karaf.shell.console:3.0.7]

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            ajayl.bro@gmail.com Ajay L
            ajayl.bro@gmail.com Ajay L
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: