-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Closed
Description
Summary
There is an explicit // TODO
comment in JpqlQueryBuilder.java
regarding the parenthesis handling logic. The current implementation includes logic to prevent duplicate parentheses, but it could be improved for better readability and maintainability.
Motivation
- The code section marked with a
TODO
comment is a clear entry point for open-source contributions. - Improving the parenthesis handling logic can reduce code complexity and enhance the readability of JPQL query building.
- Addressing this
TODO
will make future maintenance easier and lower the barrier for other contributors.
Current Behavior
- The logic to prevent duplicate parentheses is somewhat ad-hoc and could lead to confusing or sub-optimal query generation.
- The existing code relies on manual checks that can be refactored for clarity.
Suggested Improvement
- Refactor the parenthesis handling logic to make it more explicit and robust.
- Add unit tests to verify that duplicate parentheses are no longer generated in any edge cases.
- Clean up the code to remove the
TODO
comment and document the improved behavior.
Impact
- Improved code readability and maintainability in the JPQL query builder.
- Reduced risk of bugs related to query string generation.
- Lower entry barrier for new contributors.
Metadata
Metadata
Assignees
Labels
type: taskA general taskA general task