Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Won't Fix
-
None
-
None
-
None
-
Moderate
Description
Hi,
We are trying to create a swagger ui for apache cxf services and
<host>:<port>/swagger.json gives me json response. But when I try http://localhost:<port>/api-docs/?url=/swagger.json I keep getting 404.
http://localhost:<port>/api-docs?url=swagger.json
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-rs-service-description-swagger</artifactId>
<version>3.1.11</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.webjars/swagger-ui -->
<dependency>
<groupId>org.webjars</groupId>
<artifactId>swagger-ui</artifactId>
<version>3.5.0</version>
</dependency>
<bean id="swagger2Feature" class="org.apache.cxf.jaxrs.swagger.Swagger2Feature">
<!-- customize some of the properties -->
<bean id="jsonProvider" class="com.fasterxml.jackson.jaxrs.json.JacksonJsonProvider" />
</bean>
<jaxrs:server id="" address=">
<jaxrs:serviceBeans>
<ref bean="" />
</jaxrs:serviceBeans>
<jaxrs:providers>
<ref bean="jsonProvider" />
</jaxrs:providers>
<jaxrs:features>
<ref bean="swagger2Feature" />
</jaxrs:features>
</jaxrs:server>