Error rendering Swagger API due null

Solution Verified - Updated -

Issue

I followed Design APIs to generate my camel project using the API designer on openshift env, then imported the project into CodeReady Studio, when I runned the camel project local and access http://localhost:8080/openapi.json, I met below error:

2020-01-10 06:39:38.121  WARN 1 --- [nio-8080-exec-2] o.a.camel.swagger.RestSwaggerProcessor   : Error rendering Swagger API due null

java.lang.NullPointerException: null
    at org.apache.camel.swagger.RestSwaggerSupport.renderResourceListing(RestSwaggerSupport.java:211) ~[camel-swagger-java-2.21.0.fuse-720050-redhat-00001.jar!/:2.21.0.fuse-720050-redhat-00001]
    at org.apache.camel.swagger.RestSwaggerProcessor.process(RestSwaggerProcessor.java:119) ~[camel-swagger-java-2.21.0.fuse-720050-redhat-00001.jar!/:2.21.0.fuse-720050-redhat-00001]
    at org.apache.camel.component.rest.RestApiProducer.process(RestApiProducer.java:36) [camel-core-2.21.0.fuse-720050-redhat-00001.jar!/:2.21.0.fuse-720050-redhat-00001]
    at org.apache.camel.util.AsyncProcessorConverterHelper$ProcessorToAsyncProcessorBridge.process(AsyncProcessorConverterHelper.java:61) [camel-core-2.21.0.fuse-720050-redhat-00001.jar!/:2.21.0.fuse-720050-redhat-00001]
    at org.apache.camel.processor.SendProcessor.process(SendProcessor.java:148) [camel-core-2.21.0.fuse-720050-redhat-00001.jar!/:2.21.0.fuse-720050-redhat-00001]
    at org.apache.camel.processor.RedeliveryErrorHandler.process(RedeliveryErrorHandler.java:548) [camel-core-2.21.0.fuse-720050-redhat-00001.jar!/:2.21.0.fuse-720050-redhat-00001]
    at org.apache.camel.processor.CamelInternalProcessor.process(CamelInternalProcessor.java:201) [camel-core-2.21.0.fuse-720050-redhat-00001.jar!/:2.21.0.fuse-720050-redhat-00001]
    at org.apache.camel.processor.CamelInternalProcessor.process(CamelInternalProcessor.java:201) [camel-core-2.21.0.fuse-720050-redhat-00001.jar!/:2.21.0.fuse-720050-redhat-00001]
    at org.apache.camel.processor.DelegateAsyncProcessor.process(DelegateAsyncProcessor.java:97) [camel-core-2.21.0.fuse-720050-redhat-00001.jar!/:2.21.0.fuse-720050-redhat-00001]
    at org.apache.camel.http.common.CamelServlet.doService(CamelServlet.java:214) [camel-http-common-2.21.0.fuse-720050-redhat-00001.jar!/:2.21.0.fuse-720050-redhat-00001]
    at org.apache.camel.http.common.CamelServlet.service(CamelServlet.java:80) [camel-http-common-2.21.0.fuse-720050-redhat-00001.jar!/:2.21.0.fuse-720050-redhat-00001]

Environment

  • Red Hat Fuse
    • 7.X

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.

Current Customers and Partners

Log in for full access

Log In