fix: fix global @explain not effective by Zhengcy05 · Pull Request #860 · APIJSON/APIJSON
Repository navigation
fix: fix global @explain not effective - #860
Merged
TommyLemon merged 1 commit into APIJSON:master from Zhengcy05:fix/fix-global-explain Jun 11, 2026
Merged
fix: fix global @explain not effective #860 TommyLemon merged 1 commit into APIJSON:master from Zhengcy05:fix/fix-global-explain
Conversation
Zhengcy05 commented Jun 11, 2026 · edited Loading
Copy link Copy Markdown
Contributor
Ⅰ. Describe what this PR did
This PR fixes the global @Explain propagation logic in AbstractObjectParser.
Previously, root-level @Explain was parsed correctly as a global option, but when the framework applied global defaults to table objects, it checked globalSchema instead of globalExplain before injecting KEY_EXPLAIN. As a result, global @Explain only worked when global @Schema was also present.
This change updates the condition to check the global explain flag itself, so root-level @Explain now works as documented without depending on @Schema .
Ⅱ. Does this pull request fix one issue?
fixes #851
Ⅲ. Why don't you add test cases (unit test/integration test)?
This repository currently does not have an existing test structure under APIJSONORM/src/test, and this PR keeps the change minimal and focused to a one-line bug fix.
The change was verified by compilation and by tracing the request parsing path against the reported issue scenario.
Ⅳ. Describe how to verify it
Run:
mvn -f APIJSONORM/pom.xml -DskipTests compile
Ⅴ. Special notes for reviews
This is a minimal fix that only corrects the propagation condition for global @Explain .
It does not change:
subquery behavior
object-level @Explain behavior
any SQL generation logic beyond the global default injection path
fix: fix global @Explain not effective
5789d66
TommyLemon
approved these changes
Jun 11, 2026
View reviewed changes
TommyLemon merged commit
461a5cf
into
APIJSON : master
Jun 11, 2026
1 check passed
TommyLemon commented Jun 11, 2026 · edited Loading
Copy link Copy Markdown
Member
|
@Zhengcy05 Thank you for your contribution~ However, this PR is too tiny to run the test cases. |