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

Support rewinding orchestrations #96

Merged
merged 9 commits into from
Jun 1, 2022
Merged

Conversation

Greybird
Copy link
Contributor

@Greybird Greybird commented May 28, 2022

Should fix #66.

I tried to mimic as much as possible the table storage implementation.
However, I'm pretty sure there is lot of room for improvement, so please don't hesitate to tell me where, and I'll try to enhance the proposal.

Known limitation:

  • SQL Server seems to have a 32 calls depths limit, so as the rewind stored procedure is recursive, rewinding failed activities or orchestrations above this depth will not work (it should however be possible to rewind orchestrations with higher depth first, then going up in the hierarchy).

@ghost
Copy link

ghost commented May 28, 2022

CLA assistant check
All CLA requirements met.

@cgillum
Copy link
Member

cgillum commented May 31, 2022

Thanks for this contribution! I did a quick scan of the changes and I don't have any issues with your approach. In the fullness of time, we're thinking of changing how we implement rewind to be storage provider-agnostic, but I think this implementation should be good enough for a preview-quality feature until we get around to a more generic overhaul.

Copy link
Member

@cgillum cgillum left a comment

Choose a reason for hiding this comment

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

Some initial thoughts:

src/DurableTask.SqlServer/Scripts/logic.sql Outdated Show resolved Hide resolved
src/DurableTask.SqlServer/Scripts/logic.sql Show resolved Hide resolved
src/DurableTask.SqlServer/Scripts/logic.sql Outdated Show resolved Hide resolved
src/DurableTask.SqlServer/Scripts/logic.sql Outdated Show resolved Hide resolved
src/DurableTask.SqlServer/Scripts/logic.sql Outdated Show resolved Hide resolved
@Greybird
Copy link
Contributor Author

I think I took care of your current comments.
Feel free to tell me if more is needed.

It's a great thing that Rewind is being worked on, to me it is a key feature of durable functions! Even better if it can be done in a storage-agnostic way!

@cgillum
Copy link
Member

cgillum commented Jun 1, 2022

In an effort to make some small changes to your PR, it seems I've accidentally also merged in the latest from the main branch. Sorry about the noise it's causing on this PR. I'm basically good with these changes and will just do a few manual tests before signing off and merging.

Copy link
Member

@cgillum cgillum left a comment

Choose a reason for hiding this comment

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

LGTM! Thanks again for this contribution!

@cgillum cgillum merged commit 1baa72e into microsoft:main Jun 1, 2022
@Greybird Greybird deleted the feature/rewind branch June 2, 2022 06:25
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.

Support Rewind
2 participants