Skip to content
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

DataflowError decoding fallback to the legacy format #21865

Merged
merged 1 commit into from
Sep 21, 2023

Conversation

teskje
Copy link
Contributor

@teskje teskje commented Sep 21, 2023

In #21510 we introduced a change to the DataflowError protos that wasn't backward compatible. This made Mz panic on some persisted DataflowErrors because it was unable to decode them anymore.

This PR fixes the DataflowError (and SourceData) decoding by falling back to *Legacy proto versions in case decoding with the new versions fails.

Motivation

  • This PR fixes a previously unreported bug.

Clusters running Mz version 0.69 are not able to read DataflowErrors persisted by earlier versions. Instead they panic with "decoding failed" errors.

Checklist

  • This PR has adequate test coverage / QA involvement has been duly considered.
  • This PR has an associated up-to-date design doc, is a design doc (template), or is sufficiently small to not require a design.
  • If this PR evolves an existing $T ⇔ Proto$T mapping (possibly in a backwards-incompatible way), then it is tagged with a T-proto label.
  • If this PR will require changes to cloud orchestration or tests, there is a companion cloud PR to account for those changes that is tagged with the release-blocker label (example).
  • This PR includes the following user-facing behavior changes:
    • N/A

@teskje teskje changed the title DataflowError backward compat DataflowError decoding fallback to the legacy format Sep 21, 2023
@teskje teskje marked this pull request as ready for review September 21, 2023 12:28
@teskje teskje requested a review from a team September 21, 2023 12:28
In MaterializeInc#21510 we introduced a change to the `DataflowError` protos that
wasn't backward compatible. This made Mz panic on some persisted
`DataflowError`s because it was unable to decode them anymore.

This commit fixes the `DataflowError` (and `SourceData`) decoding by
falling back to `*Legacy` proto versions in case decoding with the new
versions fails.
@teskje teskje merged commit 781bd3a into MaterializeInc:main Sep 21, 2023
@teskje teskje deleted the dataflowerror-fix branch September 21, 2023 13:55
@sentry-io
Copy link

sentry-io bot commented Sep 21, 2023

Sentry issue: DATABASE-BACKEND-2YB

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants