I am using the following Maven dependencies and plugins
<dependency>
<groupId>io.springfox</groupId>
<artifactId>springfox-swagger2</artifactId>
<version>2.0.3-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>io.springfox</groupId>
<artifactId>springfox-spring-web</artifactId>
<version>2.0.3-SNAPSHOT</version>
</dependency>
<repository>
<id>jcenter-snapshots</id>
<name>jcenter</name>
<!-- <url>https://jcenter.bintray.com/</url> -->
<url>http://oss.jfrog.org/artifactory/oss-snapshot-local/</url>
</repository>
in beans.xml below is the bean definition is as follows:
<int:annotation-config/>
<context:annotation-config/>
<bean id="swagger2Config" class="springfox.documentation.swagger2.configuration.Swagger2DocumentationConfiguration"/>
<bean id="springConfig" class="com.example.SpringConfig"/>
I have referred to the following blog
I can not use the early access version mentioned in the blog as it is not available for download. I have changed the version to 2.0.3-SNAPSHOT and now I am seeing HttpMediaTypeNotAcceptableException exception. I was able to generate the WAR file and in logs I was able to see the resourcegroup that was created properly with Swagger when I tried to access it using http://localhost:8080/example/v2/api-docs the above mentioned exception was thrown.
Please help.