raminqaf opened a new pull request, #28283:
URL: https://github.com/apache/flink/pull/28283
## What is the purpose of the change
`TABLE_ARG_CALL` nodes always wrote `partitionKeys`, `orderKeys`, and
`orderDirections` into the compiled plan JSON, even when empty. Table
arguments without `PARTITION BY` and `ORDER BY`are common, so these empty
arrays bloat the plan for no benefit. This change omits the arrays when empty,
matching how `serializeCall` already skips empty operands.
## Brief change log
- `RexNodeJsonSerializer` skips `partitionKeys` / `orderKeys` /
`orderDirections` when they are empty.
- `RexNodeJsonDeserializer` treats the three fields as optional and defaults
them to empty arrays when absent, so plans written by older versions still
load.
- Regenerated the affected PTF / `TO_CHANGELOG` / `FROM_CHANGELOG` restore
plan files to drop the now-omitted arrays.
## Verifying this change
This change is already covered by existing tests, such as the
`stream-exec-process-table-function`, `TO_CHANGELOG`, and `FROM_CHANGELOG`
restore tests. They load the regenerated plans through the deserializer and
pass. The deserializer change keeps older plans that still contain the empty
arrays loadable, preserving backward compatibility.
## Does this pull request potentially affect one of the following parts:
- Dependencies (does it add or upgrade a dependency): no
- The public API, i.e., is any changed class annotated with
`@Public(Evolving)`: no
- The serializers: yes. The compiled-plan JSON format changes, but it is
backward compatible: the deserializer reads plans both with and without the
arrays.
- The runtime per-record code paths (performance sensitive): no
- Anything that affects deployment or recovery: JobManager (and its
components), Checkpointing, Kubernetes/Yarn, ZooKeeper: no
- The S3 file system connector: no
## Documentation
- Does this pull request introduce a new feature? no
- If yes, how is the feature documented? not applicable
---
##### Was generative AI tooling used to co-author this PR?
- [] Yes (please specify the tool below)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]