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

take two: relax ErrJournalNotFound only when writing recovered ACKs #358

Merged
merged 4 commits into from
Dec 13, 2023

Conversation

jgraettinger
Copy link
Contributor

@jgraettinger jgraettinger commented Dec 13, 2023

  • Revert prior commit.
  • Make ErrJournalNotFound a terminal error for AppendService, because it's essentially never recoverable and should be retried at a higher level.
  • Have client.Appender handle insufficient journal brokers, as this is a retry-able case that happens.
  • Update consumer to relax the writes of recovered ACK intents. Log a missing journal but allow the session to proceed.

This change is Reviewable

Currently, AppendService will loop forever waiting for an appended
journal to spring (back) into existence if it's not found.

Instead, immediately fail the AsyncAppend and all of its dependents.

This is desirable because journal deletions are often asynchronous and
race deployed shards, and there's not much that can be done aside from
failing and handling the error at a higher level.
This happens when a journal is new and the topology is converging.
It shouldn't result in a terminal Append failure.
It's not uncommon for recovered ACKs to contain journals which have
since been deleted. When this happens, log a warning and otherwise
discard the ACK intent.

Do this only for recovered intents: writen ACKs of the current session
must still exist.
Copy link
Contributor

@psFried psFried left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@jgraettinger jgraettinger merged commit 7985348 into master Dec 13, 2023
1 check passed
@jgraettinger jgraettinger deleted the johnny/append-missing branch December 13, 2023 20:36
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