ParyshevSergey opened a new pull request, #29544: URL: https://github.com/apache/flink/pull/29544
## What is the purpose of the change Fixes [FLINK-40898](https://issues.apache.org/jira/browse/FLINK-40898). With TRY_RESOLVE, queries containing non-deterministic filters such as NOW() or CURRENT_TIMESTAMP are incorrectly rejected when the optimizer pushes the filter into ChangelogNormalize. With IGNORE, the analyzer reports a misleading warning. ChangelogNormalize evaluates the filter on incoming inserts and updates and emits retractions from the previously accepted row in state. It does not reevaluate the filter for those retractions, so this determinism check is unnecessary. ## Brief change log - Remove the filter determinism check for ChangelogNormalize while preserving propagation of determinism requirements to its input. - Update plan tests for NOW() and CURRENT_TIMESTAMP to cover TRY_RESOLVE and IGNORE, including the absence of misleading plan advice. - Add a semantic regression test covering accepted updates, rejected updates, and deletes with a non-deterministic UDF. - Add a control test ensuring that an unsafe non-deterministic filter on a retract source is still rejected. ## Verifying this change The regression cases reproduced the rejection before the fix and pass with the fix. Passed 218 tests across: - NonDeterministicUpdateAnalyzerTest - ChangelogNormalizeSemanticTests - NonDeterministicDagTest - PushCalcPastChangelogNormalizeRuleTest Also passed 4 existing filter-condition test cases across ProcTimeDeduplicateKeepLastRowFunctionTest and ProcTimeMiniBatchDeduplicateKeepLastRowFunctionTest. Spotless and Checkstyle passed. Full `./mvnw clean verify` has not been run. ## 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: no - 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? - [X] Yes (please specify the tool below) Generated-by: OpenAI Codex (GPT-6 Astra) -- 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]
