-
Notifications
You must be signed in to change notification settings - Fork 3.7k
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
release-23.2: changefeedccl: Correctly handle stable CDC query functions #117577
base: release-23.2
Are you sure you want to change the base?
Conversation
Custom CDC query functions rely on having "annotations" configured. Prior to this change, these annotations were configured when the CDC query was being evaluated (for each event). However, CDC query also needs to be evaluated when e.g. the changefeed is being created. In this case, the correct annotations were not configured, resulting in failure to create changefeed that use stable, custom CDC function. At this point, there is only one such function: `changefeed_creation_time`. This PR refactors and cleans up how semantic and evalution contexts are configured. This now happens in a single place -- namely the `withPlanner` helper so that correct information is configured at all times. Fixes #115245 Release note (enterprise change): Fix CDC query to correctly handle `changefeed_creation_time()` function.
cbe6330
to
316db9d
Compare
Thanks for opening a backport. Please check the backport criteria before merging:
If your backport adds new functionality, please ensure that the following additional criteria are satisfied:
Also, please add a brief release justification to the body of your PR to justify this |
Reminder: it has been 3 weeks please merge or close your backport! |
Yevgeniy Miretskiy seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account. You have signed the CLA already but the status is still pending? Let us recheck it. |
Reminder: it has been 3 weeks please merge or close your backport! |
Backport 1/1 commits from #117520 on behalf of @miretskiy.
/cc @cockroachdb/release
Custom CDC query functions rely on having "annotations" configured. Prior to this change, these annotations were configured when the CDC query was being evaluated (for each event). However, CDC query also needs to be evaluated when e.g. the changefeed is being created. In this case, the correct annotations were not configured, resulting in failure to create changefeed that use stable, custom CDC function. At this point, there is only one such function:
changefeed_creation_time
.This PR refactors and cleans up how semantic and evalution contexts are configured. This now happens in a single place -- namely the
withPlanner
helper so that correct information is configured at all times.Fixes #115245
Release note (enterprise change): Fix CDC query to correctly handle
changefeed_creation_time()
function.Release justification: