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

Put back support to produce in the old DecatonTaskRequest for migration #248

Merged
merged 1 commit into from
Jan 29, 2025

Conversation

kawamuray
Copy link
Contributor

Related to: https://github.com/line/decaton/pull/238/files

In https://github.com/line/decaton/pull/238/files and https://github.com/line/decaton/pull/238/files we dropped the DecatonTaskRequest w/ online migration procedure.

However, in the apps that uses both decaton-processor and decaton-client (i.e, DecatonClient), it is impossible to migrate the app to decaton 9 or above because it inherently upgrades decaton-client dep by transitive dep from decaton-processor first.
To address this situation I put back the option to let DecatonClient keep producing tasks in older version until all processor completes upgrade.

After this change the upgrade procedure will be:

  • Step1: Upgrade decaton-processors to 9.0.0 or higher with decaton.retry.task.in.legacy.format=true, decaton.legacy.parse.fallback.enabled=true. Also set produceInOldTaskRequest to true in DecatonClientBuilder if you're using the DecatonClient in the same app.
  • Step2: Upgrade decaton-clients to 9.0.0 or higher
  • Step3: After all decaton-processors are upgraded, set decaton.retry.task.in.legacy.format=false, Also set produceInOldTaskRequest to false in DecatonClientBuilder if you're using the DecatonClient in the same app.
  • Step4: Wait all old-format tasks and retry tasks are processed after Step3.
    • You can monitor topic's committed offset is caught-up and retry-topic's offset lag becomes 0.
  • Step5: Set decaton.legacy.parse.fallback.enabled=false

Copy link
Contributor

@ocadaruma ocadaruma left a comment

Choose a reason for hiding this comment

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

it inherently upgrades decaton-client dep by transitive dep from decaton-processor first

Nice catch. I overlooked this point.

LGTM

@kawamuray kawamuray merged commit 86f7448 into line:master Jan 29, 2025
5 checks passed
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