Feign will execute any default methods on an interface rather than initiating any HTTP call.
This conflicts with the interface generated by the swagger-codegen-maven-plugin
which always
come with a default method on Java 8.
useBeanValidation
is set to false in the pom.xml
yet the dependency is required.
To demonstrate this issue, remove the validation-api
dependency and run mvn clean compile
.
The generated ClientConfiguration
class always contains imports for
org.springframework.cloud.security
and org.springframework.security.oauth2
, even though
they aren't used in the class. To see the issue, remove the line **/ClientConfiguration.java
from the .swagger-codegen-ignore
file and run mvn clean compile
.