java.lang.NullPointerException

JIRA | antony silvester | 3 months ago
  1. 0

    1] Test Code String xml = "<filter xmlns=\"ydt.filter-type\" type=\"subtree\"><network xmlns=\"urn:TBD:params:xml:ns:yang:nodes\"><name>My name</name><surname>My Surname</surname><isHappy>false</isHappy></network></filter>"; List<Object> yangModuleDecodedList = yangCodecHandler.decode(xml, YangProtocolEncodingFormat.XML_ENCODING); Please find the Attached Yang File Output : Exception: onos> exception-display java.lang.NullPointerException at org.onosproject.yms.app.yob.YobSingleInstanceLeafHandler.setObjectInParent(YobSingleInstanceLeafHandler.java:59) at org.onosproject.yms.app.yob.YobListener.exitYdtNode(YobListener.java:79) at org.onosproject.yms.app.yob.YobListener.exitYdtNode(YobListener.java:91) at org.onosproject.yms.app.ydt.DefaultYdtWalker.walkTree(DefaultYdtWalker.java:66) at org.onosproject.yms.app.ydt.DefaultYdtWalker.walk(DefaultYdtWalker.java:96) at org.onosproject.yms.app.yob.DefaultYobBuilder.getYangObject(DefaultYobBuilder.java:43) at org.onosproject.yms.app.ych.DefaultYangCodecHandler.getObjectList(DefaultYangCodecHandler.java:241) at org.onosproject.yms.app.ych.DefaultYangCodecHandler.decode(DefaultYangCodecHandler.java:199) at org.onosproject.ymstest.cli.YmsTestCommand.execute(YmsTestCommand.java:90) at org.onosproject.cli.AbstractShellCommand.doExecute(AbstractShellCommand.java:150) at org.apache.karaf.shell.console.AbstractAction.execute(AbstractAction.java:33)[27:org.apache.karaf.shell.console:3.0.5] at org.apache.karaf.shell.commands.basic.AbstractCommand.execute(AbstractCommand.java:33)[27:org.apache.karaf.shell.console:3.0.5] at Proxy2c8c95a2_4d2b_4472_930d_0a4e362aadfd.execute(Unknown Source)[:] at Proxy2c8c95a2_4d2b_4472_930d_0a4e362aadfd.execute(Unknown Source)[:] at org.apache.felix.gogo.runtime.CommandProxy.execute(CommandProxy.java:78)[27:org.apache.karaf.shell.console:3.0.5] at org.apache.felix.gogo.runtime.Closure.executeCmd(Closure.java:480)[27:org.apache.karaf.shell.console:3.0.5] at org.apache.felix.gogo.runtime.Closure.executeStatement(Closure.java:406)[27:org.apache.karaf.shell.console:3.0.5] at org.apache.felix.gogo.runtime.Pipe.run(Pipe.java:108)[27:org.apache.karaf.shell.console:3.0.5] at org.apache.felix.gogo.runtime.Closure.execute(Closure.java:182)[27:org.apache.karaf.shell.console:3.0.5] at org.apache.felix.gogo.runtime.Closure.execute(Closure.java:119)[27:org.apache.karaf.shell.console:3.0.5] 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_101] at org.apache.karaf.jaas.modules.JaasHelper.doAs(JaasHelper.java:57)[28:org.apache.karaf.jaas.modules:3.0.5] at org.apache.karaf.shell.console.impl.jline.LocalConsoleManager$2$1.run(LocalConsoleManager.java:102)[27:org.apache.karaf.shell.console:3.0.5] onos> *********************************** Module Having Problem : YobHandler.java createYangBuilderObject try { yangDefaultClass = Class.forName(qualifiedClassName); } catch (ClassNotFoundException e) { log.error("YOB: failed to load class for class " + className); } try { Confirmed by : Bharat

    JIRA | 3 months ago | antony silvester
    java.lang.NullPointerException
  2. 0

    Test Step : Send a invalid XML Test XML: String invalidXml = "<network xmlns=\"urn:TBD:params:xml:ns:yang:nodes\"><name>My name</name><surname>My Surname</surname><isHappy>false</isHappy></network></filter>"; List<Object> yangModuleDecodedList = yangCodecHandler.decode(invalidXml, YangProtocolEncodingFormat.XML_ENCODING); --- Output : Exception onos> exception-display java.lang.NullPointerException at org.onosproject.yms.app.ych.codecutils.YchYangDataTreeCodec.decodeProtocolDataToYdt(YchYangDataTreeCodec.java:187) at org.onosproject.yms.app.ych.DefaultYangCodecHandler.decode(DefaultYangCodecHandler.java:195) at org.onosproject.ymstest.cli.YmsTestCommand.execute(YmsTestCommand.java:90) at org.onosproject.cli.AbstractShellCommand.doExecute(AbstractShellCommand.java:150) at org.apache.karaf.shell.console.AbstractAction.execute(AbstractAction.java:33)[27:org.apache.karaf.shell.console:3.0.5] at org.apache.karaf.shell.commands.basic.AbstractCommand.execute(AbstractCommand.java:33)[27:org.apache.karaf.shell.console:3.0.5] at Proxy5204d04d_d874_45f6_a4b9_92aaf7f5cf24.execute(Unknown Source)[:] at Proxy5204d04d_d874_45f6_a4b9_92aaf7f5cf24.execute(Unknown Source)[:] at org.apache.felix.gogo.runtime.CommandProxy.execute(CommandProxy.java:78)[27:org.apache.karaf.shell.console:3.0.5] at org.apache.felix.gogo.runtime.Closure.executeCmd(Closure.java:480)[27:org.apache.karaf.shell.console:3.0.5] at org.apache.felix.gogo.runtime.Closure.executeStatement(Closure.java:406)[27:org.apache.karaf.shell.console:3.0.5] at org.apache.felix.gogo.runtime.Pipe.run(Pipe.java:108)[27:org.apache.karaf.shell.console:3.0.5] at org.apache.felix.gogo.runtime.Closure.execute(Closure.java:182)[27:org.apache.karaf.shell.console:3.0.5] at org.apache.felix.gogo.runtime.Closure.execute(Closure.java:119)[27:org.apache.karaf.shell.console:3.0.5] 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_101] at org.apache.karaf.jaas.modules.JaasHelper.doAs(JaasHelper.java:57)[28:org.apache.karaf.jaas.modules:3.0.5] at org.apache.karaf.shell.console.impl.jline.LocalConsoleManager$2$1.run(LocalConsoleManager.java:102)[27:org.apache.karaf.shell.console:3.0.5] onos> ************************************* Module Having problem : YchYangDataTreeCodec.java public YdtBuilder decodeProtocolDataToYdt(String protocolData, Object schemaRegistry) { YdtExtendedBuilder ydtExtendedBuilder = null; Document document = null; try { document = DocumentHelper.parseText(protocolData); } catch (DocumentException e) { // TODO } XmlWalker walker = new DefaultXmlCodecWalker(); XmlCodecListener listener = new XmlCodecListener(); findRootElement(document.getRootElement()); Confirmed By Shankar

    JIRA | 3 months ago | antony silvester
    java.lang.NullPointerException
  3. 0

    Android: Saving Map State in Google map

    Stack Overflow | 11 months ago | Junie Negentien
    java.lang.RuntimeException: Unable to resume activity {com.ourThesis.junieNegentien2015/com.ourThesis.junieNegentien2015.MainActivity}: java.lang.NullPointerException
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. java.lang.NullPointerException

      No message provided

      at org.onosproject.yms.app.yob.YobSingleInstanceLeafHandler.setObjectInParent()
    2. org.onosproject.yms
      DefaultYangCodecHandler.decode
      1. org.onosproject.yms.app.yob.YobSingleInstanceLeafHandler.setObjectInParent(YobSingleInstanceLeafHandler.java:59)
      2. org.onosproject.yms.app.yob.YobListener.exitYdtNode(YobListener.java:79)
      3. org.onosproject.yms.app.yob.YobListener.exitYdtNode(YobListener.java:91)
      4. org.onosproject.yms.app.ydt.DefaultYdtWalker.walkTree(DefaultYdtWalker.java:66)
      5. org.onosproject.yms.app.ydt.DefaultYdtWalker.walk(DefaultYdtWalker.java:96)
      6. org.onosproject.yms.app.yob.DefaultYobBuilder.getYangObject(DefaultYobBuilder.java:43)
      7. org.onosproject.yms.app.ych.DefaultYangCodecHandler.getObjectList(DefaultYangCodecHandler.java:241)
      8. org.onosproject.yms.app.ych.DefaultYangCodecHandler.decode(DefaultYangCodecHandler.java:199)
      8 frames
    3. org.onosproject.ymstest
      YmsTestCommand.execute
      1. org.onosproject.ymstest.cli.YmsTestCommand.execute(YmsTestCommand.java:90)
      1 frame
    4. org.onosproject.cli
      AbstractShellCommand.doExecute
      1. org.onosproject.cli.AbstractShellCommand.doExecute(AbstractShellCommand.java:150)
      1 frame
    5. Apache Karaf :: Shell :: Console
      AbstractCommand.execute
      1. org.apache.karaf.shell.console.AbstractAction.execute(AbstractAction.java:33)[27:org.apache.karaf.shell.console:3.0.5]
      2. org.apache.karaf.shell.commands.basic.AbstractCommand.execute(AbstractCommand.java:33)[27:org.apache.karaf.shell.console:3.0.5]
      2 frames
    6. Unknown
      Proxy2c8c95a2_4d2b_4472_930d_0a4e362aadfd.execute
      1. Proxy2c8c95a2_4d2b_4472_930d_0a4e362aadfd.execute(Unknown Source)[:]
      2. Proxy2c8c95a2_4d2b_4472_930d_0a4e362aadfd.execute(Unknown Source)[:]
      2 frames
    7. Apache Felix Gogo Runtime
      CommandSessionImpl.execute
      1. org.apache.felix.gogo.runtime.CommandProxy.execute(CommandProxy.java:78)[27:org.apache.karaf.shell.console:3.0.5]
      2. org.apache.felix.gogo.runtime.Closure.executeCmd(Closure.java:480)[27:org.apache.karaf.shell.console:3.0.5]
      3. org.apache.felix.gogo.runtime.Closure.executeStatement(Closure.java:406)[27:org.apache.karaf.shell.console:3.0.5]
      4. org.apache.felix.gogo.runtime.Pipe.run(Pipe.java:108)[27:org.apache.karaf.shell.console:3.0.5]
      5. org.apache.felix.gogo.runtime.Closure.execute(Closure.java:182)[27:org.apache.karaf.shell.console:3.0.5]
      6. org.apache.felix.gogo.runtime.Closure.execute(Closure.java:119)[27:org.apache.karaf.shell.console:3.0.5]
      7. org.apache.felix.gogo.runtime.CommandSessionImpl.execute(CommandSessionImpl.java:94)
      7 frames
    8. Apache Karaf :: Shell :: Console
      LocalConsoleManager$2$1$1.run
      1. org.apache.karaf.shell.console.impl.jline.ConsoleImpl.run(ConsoleImpl.java:210)
      2. org.apache.karaf.shell.console.impl.jline.LocalConsoleManager$2$1$1.run(LocalConsoleManager.java:109)
      2 frames
    9. Java RT
      AccessController.doPrivileged
      1. java.security.AccessController.doPrivileged(Native Method)[:1.8.0_101]
      1 frame
    10. Karaf
      JaasHelper.doAs
      1. org.apache.karaf.jaas.modules.JaasHelper.doAs(JaasHelper.java:57)[28:org.apache.karaf.jaas.modules:3.0.5]
      1 frame
    11. Apache Karaf :: Shell :: Console
      LocalConsoleManager$2$1.run
      1. org.apache.karaf.shell.console.impl.jline.LocalConsoleManager$2$1.run(LocalConsoleManager.java:102)[27:org.apache.karaf.shell.console:3.0.5]
      1 frame