Skip to content

Improvement for QuerydslPredicateOperationCustomizer#excludeUnlistedProperties #925

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

Closed
chrisupb opened this issue Nov 5, 2020 · 2 comments
Labels
bug Something isn't working

Comments

@chrisupb
Copy link
Contributor

chrisupb commented Nov 5, 2020

This relates to #866.
The fix in #866 removes all Querydsl properties which are explicitly whitelisted with:

bindings.including(XXXX);

The wanted behavior is: If excludeUnlistedProperties is true, add defined bindings AND ONLY whitelisted properties to the generated parameters list in OpenAPI.

Pullrequest follows...

chrisupb pushed a commit to chrisupb/springdoc-openapi that referenced this issue Nov 5, 2020
@chrisupb
Copy link
Contributor Author

chrisupb commented Nov 5, 2020

OK, I see test app19 fail because
bindings.bind(root.name).first(StringExpression::containsIgnoreCase);
is not on the whitelist.

What is the expected behavior here?

Really ONLY include fields on the whitelist and ignore additional bindings? Than the test case would change to

public void customize(QuerydslBindings bindings, QApplication root) {
bindings.excludeUnlistedProperties(true);
bindings.bind(root.name).first(StringExpression::containsIgnoreCase);
bindings.including(root.name);
bindings.including(root.icon);
}

Or always include all bindings bindings.bind() [QuerydslBindings.pathSpecs] no matter what is on the whitelist.

@bnasslahsen
Copy link
Collaborator

should be fixed by #934.

@bnasslahsen bnasslahsen added the bug Something isn't working label Jan 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants