GraphQLWebClient does not pick up configuration properties when spring-boot-starter-hateoas is present
rnferreira opened this issue · 2 comments
rnferreira commented
Description
The injected WebClient in the GraphQLWebClient will not have the baseUrl property set if another class creates a WebClient bean (e.g. Spring Boot HATEOAS AutoConfiguration class). This prevents its usage as described in the README and forces the developer to manually create the aforementioned bean.
To Reproduce
Steps to reproduce the behaviour:
- Create a simple project that uses
org.springframework.boot:spring-boot-starter-hateoasandcom.graphql-java-kickstart:graphql-webclient-spring-boot-starter(v1.0.0). - Make the necessary adjustments to the
application.propertiesorapplication.yml. - Put a breakpoint on the
GraphQLWebClientbean creation (at the time of this writing, it is line 78). - Run the application in debug mode.
- Verify that the injected
WebClienthasbaseUrl=null.
Expected behaviour
GraphQLWebClient works as expected, irrespective of having other frameworks in play.
Desktop:
- OS: macOS BigSur 11.5
- Version 1.0.0
rnferreira commented
Sorry, my mistake. It was a configuration problem due to another dependency and not caused by HATEOAS.
ganezdragon commented
@rnferreira how was this fixed? we have the same problem.