Uploaded image for project: 'ONOS'
  1. ONOS
  2. ONOS-4558

NullPointerException for import

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Done
    • Affects Version/s: None
    • Fix Version/s: 1.6.0
    • Component/s: None
    • Environment:

      ONOS BUILD

    • Story Points:
      4

      Description

      module ospf {
      namespace "urn:cisco:params:xml:ns:yang:ospf";
      prefix ospf;
      import ietf-inet-types

      { prefix inet; }

      revision 2020-10-20;
      }

      Log:

      1st run:
      build success

      2nd run:
      [DEBUG] Configuring mojo 'org.onosproject:yangutils-maven-plugin:1.0.0-SNAPSHOT:yang2java' with basic configurator -->
      [DEBUG] (f) baseDir = /home/root1/onos/utils/test
      [DEBUG] (f) genFilesDir = src/main/java
      [DEBUG] (f) outputDirectory = /home/root1/onos/utils/test/target/classes
      [DEBUG] (f) project = MavenProject: org.onosproject:onlab-test:1.6.0-SNAPSHOT @ /home/root1/onos/utils/test/pom.xml
      [DEBUG] (f) yangFilesDir = src/main/yang
      [DEBUG] – end configuration –
      [INFO] ------------------------------------------------------------------------
      [INFO] BUILD FAILURE
      [INFO] ------------------------------------------------------------------------
      [INFO] Total time: 2.457 s
      [INFO] Finished at: 2016-05-18T12:39:37+05:30
      [INFO] Final Memory: 19M/313M
      [INFO] ------------------------------------------------------------------------
      [ERROR] Failed to execute goal org.onosproject:yangutils-maven-plugin:1.0.0-SNAPSHOT:yang2java (default) on project onlab-test: Execution default of goal org.onosproject:yangutils-maven-plugin:1.0.0-SNAPSHOT:yang2java failed. NullPointerException -> [Help 1]
      org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.onosproject:yangutils-maven-plugin:1.0.0-SNAPSHOT:yang2java (default) on project onlab-test: Execution default of goal org.onosproject:yangutils-maven-plugin:1.0.0-SNAPSHOT:yang2java failed.
      at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:224)
      at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
      at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
      at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:116)
      at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:80)
      at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:51)
      at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:128)
      at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:307)
      at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:193)
      at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:106)
      at org.apache.maven.cli.MavenCli.execute(MavenCli.java:862)
      at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:286)
      at org.apache.maven.cli.MavenCli.main(MavenCli.java:197)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      at java.lang.reflect.Method.invoke(Method.java:498)
      at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)
      at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)
      at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)
      at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)
      Caused by: org.apache.maven.plugin.PluginExecutionException: Execution default of goal org.onosproject:yangutils-maven-plugin:1.0.0-SNAPSHOT:yang2java failed.
      at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:145)
      at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:208)
      ... 20 more
      Caused by: java.lang.NullPointerException
      at org.onosproject.yangutils.translator.tojava.JavaCodeGeneratorUtil.freeRestResources(JavaCodeGeneratorUtil.java:168)
      at org.onosproject.yangutils.translator.tojava.JavaCodeGeneratorUtil.translatorErrorHandler(JavaCodeGeneratorUtil.java:219)
      at org.onosproject.yangutils.plugin.manager.YangUtilManager.execute(YangUtilManager.java:182)
      at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:134)
      ... 21 more
      [ERROR]
      [ERROR]
      [ERROR] For more information about the errors and possible solutions, please read the following articles:
      [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/PluginExecutionException
      root1@root1-HP-EliteBook-840-G2:~/onos/utils/test$

        Attachments

          Activity

            People

            Assignee:
            bsaraswal bharat saraswal
            Reporter:
            sathishmurugesan sathishkumar murugesan
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: