title: Com Smoketurner dropwizard-swagger with dropwizard 1.1.4 throws Null Pointer Exception at specFilter class
body: <p>I am trying to upgrade DropWizard version from <code>0.9.2</code> to <code>1.1.4</code>, and in turn change the  <code>com.smoketurner dropwizard-swagger 1.1.1-1</code> which downloads dependencies:</p>
  
  <pre><code>io\swagger\swagger-jersey2-jaxrs\1.5.15\swagger-jersey2-jaxrs-1.5.15.jar
  io\swagger\swagger-jaxrs\1.5.15\swagger-jaxrs-1.5.15.jar
  io\swagger\swagger-core\1.5.15\swagger-core-1.5.15.jar
  io\swagger\swagger-models\1.5.15\swagger-models-1.5.15.jar
  io\swagger\swagger-annotations\1.5.15\swagger-annotations-1.5.15.jar
  </code></pre>
  
  <p>My application uses Spring framework for operations. On Hitting the swagger screen it shows 500 error with following exception - </p>
  
  <pre><code>27-Sep-2017 14:16:31:514 | ERROR | dw-50 - GET /swagger.json | i.d.j.e.LoggingExceptionMapper | Error handling a request: 94c37d34407485e8
      ! java.lang.NullPointerException: null
      ! at io.swagger.core.filter.SpecFilter.filter(SpecFilter.java:47)
      ! at io.swagger.jaxrs.listing.BaseApiListingResource.process(BaseApiListingResource.java:130)
      ! at io.swagger.jaxrs.listing.BaseApiListingResource.getListingJsonResponse(BaseApiListingResource.java:167)
      ! at io.swagger.jaxrs.listing.ApiListingResource.getListing(ApiListingResource.java:33)
      ! 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.glassfish.jersey.server.model.internal.ResourceMethodInvocationHandlerFactory$1.invoke(ResourceMethodInvocationHandlerFactory.java:81)
      ! at org.glassfish.jersey.server.model.internal.AbstractJavaResourceMethodDispatcher$1.run(AbstractJavaResourceMethodDispatcher.java:144)
      ! at org.glassfish.jersey.server.model.internal.AbstractJavaResourceMethodDispatcher.invoke(AbstractJavaResourceMethodDispatcher.java:161)
      ! at org.glassfish.jersey.server.model.internal.JavaResourceMethodDispatcherProvider$ResponseOutInvoker.doDispatch(JavaResourceMethodDispatcherProvider.java:160)
      ! at org.glassfish.jersey.server.model.internal.AbstractJavaResourceMethodDispatcher.dispatch(AbstractJavaResourceMethodDispatcher.java:99)
      ! at org.glassfish.jersey.server.model.ResourceMethodInvoker.invoke(ResourceMethodInvoker.java:389)
      ! at org.glassfish.jersey.server.model.ResourceMethodInvoker.apply(ResourceMethodInvoker.java:347)
      ! at org.glassfish.jersey.server.model.ResourceMethodInvoker.apply(ResourceMethodInvoker.java:102)
      ! at org.glassfish.jersey.server.ServerRuntime$2.run(ServerRuntime.java:326)
      ! at org.glassfish.jersey.internal.Errors$1.call(Errors.java:271)
      ! at org.glassfish.jersey.internal.Errors$1.call(Errors.java:267)
      ! at org.glassfish.jersey.internal.Errors.process(Errors.java:315)
      ! at org.glassfish.jersey.internal.Errors.process(Errors.java:297)
      ! at org.glassfish.jersey.internal.Errors.process(Errors.java:267)
      ! at org.glassfish.jersey.process.internal.RequestScope.runInScope(RequestScope.java:317)
      ! at org.glassfish.jersey.server.ServerRuntime.process(ServerRuntime.java:305)
      ! at org.glassfish.jersey.server.ApplicationHandler.handle(ApplicationHandler.java:1154)
      ! at org.glassfish.jersey.servlet.WebComponent.serviceImpl(WebComponent.java:473)
      ! at org.glassfish.jersey.servlet.WebComponent.service(WebComponent.java:427)
      ! at org.glassfish.jersey.servlet.ServletContainer.service(ServletContainer.java:388)
      ! at org.glassfish.jersey.servlet.ServletContainer.service(ServletContainer.java:341)
      ! at org.glassfish.jersey.servlet.ServletContainer.service(ServletContainer.java:228)
  </code></pre>
  
  <p>Sample dropwizard-swagger application works absolutely fine, however when integrated in my application does not show up. The endpoints when tried through Postman  etc. work fine. </p>
  
  <p>Please help. </p>