When trying to annotate a Spring Data Repository interface w/ @GraphQLAPI, e.g...
@RepositoryRestResource
@GraphQLApi
public interface ZipCodeInfoRepository extends JpaRepository<ZipCodeInfo, String>, QuerydslPredicateExecutor<ZipCodeInfo>, QuerydslBinderCustomizer<QZipCodeInfo> {
@GraphQLQuery(name = "zipcodeInfo")
default Optional<ZipCodeInfo> zipcodeInfo(@GraphQLArgument(name="zip") @NonNull String zip) {
return findById(zip);
}
}
...we get the following:
Factory method 'graphQLSchemaGenerator' threw exception with message: The registered object is of generic type org.springframework.data.jpa.repository.support.SimpleJpaRepository. Provide the full type explicitly when registering the bean. For details and solutions see https://github.com/leangen/graphql-spqr/wiki/Errors#generic-top-level-singletons
I don't see a way w/ the spring-boot-starter to add operations to the GraphQLSchemaGenerator. This seems like a pretty straightforward use case, so I feel like I must be missing something?
When trying to annotate a Spring Data Repository interface w/ @GraphQLAPI, e.g...
...we get the following:
I don't see a way w/ the spring-boot-starter to add operations to the GraphQLSchemaGenerator. This seems like a pretty straightforward use case, so I feel like I must be missing something?