Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Schema Inspection shows unmapped fields for QueryDsl and QueryByExample auto registrations #970

Open
miller79 opened this issue May 16, 2024 · 1 comment
Assignees
Labels
type: bug A general bug
Milestone

Comments

@miller79
Copy link

I am using Spring Boot Parent 3.2.5 and a repository defined like the following:

@GraphQlRepository
public interface AssetRepository extends CrudRepository<Asset, Long>, QueryByExampleExecutor<Asset> {
}

I also have a graphqls schema that looks like the following:

type Query {
	assets(asset: AssetInput!): [Asset]
}

input AssetInput {
	assetuid: ID
	assetnum: String
}

type Asset {
	assetuid: ID
	assetnum: String
}

When I run the code, it works fine and returns results as expected. However the GraphQL schema inspection shows a log that shows this:

GraphQL schema inspection:
	Unmapped fields: {Query=[assets]}
	Unmapped registrations: {}
	Skipped types: []

If I register the data fetcher directly, the inspection does not show the error but from reading the docs and from monitoring the behavior, I would believe that it is configured appropriately and everything should be configured correctly. I'm not sure if this is a bug or an error on my part but wanted to create an issue here as I could not find similar issues.

Also the documentation doesn't have a really clear example of getting QBE working but with trial and error I came to this implementation so if my knowledge is incorrect please correct me.

@spring-projects-issues spring-projects-issues added the status: waiting-for-triage An issue we've not yet triaged label May 16, 2024
@rstoyanchev
Copy link
Contributor

Thanks for the report. It looks like the AutoRegistrationRuntimeWiringConfigurer performs deferred registrations through a WiringFactory rather than directly on RuntimeWiring.Builder, and as a result schema inspection is not aware of such auto-registered DataFetchers.

@rstoyanchev rstoyanchev added type: bug A general bug and removed status: waiting-for-triage An issue we've not yet triaged labels May 21, 2024
@rstoyanchev rstoyanchev added this to the 1.3 Backlog milestone May 21, 2024
@rstoyanchev rstoyanchev self-assigned this May 21, 2024
@rstoyanchev rstoyanchev changed the title Schema Inspection showing unmapped fields when using QBE for fields that appear to be mapped Schema Inspection shows unmapped fields for QueryDsl and QueryByExample auto registrations May 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: bug A general bug
Projects
None yet
Development

No branches or pull requests

3 participants