You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Prior to this commit, we were ignoring errors in the `migrate` function,
which meant that we would still call `Migration::commit` even if `f`
returned an Err. We would still see warnings and such later in the logs
because the error would get returned from `migrate` and then caught
elsewhere in the code, but calling `commit` would still cause some side
effects to happen that shouldn't.
This could cause strange effects, such as nodes being created in domains
but never registered in the controller as part of the graph. I'm not
sure whether this caused any problems in the past (other than leaking
resources) but it started causing snapshotting failures for certain
invalid queries after the merging of...
72f191c17 (dataflow: Fix replication offsets in memory state, 2022-12-01)
...because domains would attempt to return replication offsets for these
orphaned nodes, which would confuse the controller since it would have
no record of these nodes in its state.
To fix this, we immediately return an error if `f` fails in `migrate`,
thus skipping the call to `commit`.
This commit also contains a replicators test that reproduces the
problem prior to this fix, but which now passes with the fix in place.
Release-Note-Core: Fixed a bug that could cause snapshotting and
replication to stall forever after encountering certain types of
errors while loading a view from the upstream database.
Co-authored-by: Griffin Smith <[email protected]>
Fixes: ENG-2190
Change-Id: I3ac529de0d0be702172913225440d5f58f23bacf
Reviewed-on: https://gerrit.readyset.name/c/readyset/+/4013
Reviewed-by: Griffin Smith <[email protected]>
Tested-by: Buildkite CI
0 commit comments