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

Optimize Continue As New And Solve Missed Raised Events #251

Merged
merged 8 commits into from
Jan 23, 2019

Conversation

adarsh1
Copy link
Contributor

@adarsh1 adarsh1 commented Jan 19, 2019

This PR aims to optimize ContinueAsNew so that an orchestration continues in memory in the dispatcher if it can instead of enqueueing a new task message.

With this Events Raised After a continueAsNew has been executed will also be collected and carried over to the next iteration of the orchestration. This a feature that can be opted out of by specifying SkipEventsOnContinuation as true in the OrchestrationService.

@adarsh1
Copy link
Contributor Author

adarsh1 commented Jan 19, 2019

@cgillum @simonporter

@cgillum
Copy link
Member

cgillum commented Jan 19, 2019

Note: this fixes Azure/azure-functions-durable-extension#67

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.

I'm super-excited to have this change! Relatively minor CR feedback.

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.

Looks great! Thanks for making these changes.

@adarsh1
Copy link
Contributor Author

adarsh1 commented Jan 22, 2019

Need to add one more change for the azurestorageprovider which is to also commit the old runtime state if it is instance store backed

@@ -13,8 +13,16 @@

namespace DurableTask.Core.Command
{

Copy link

Choose a reason for hiding this comment

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

nit: extra newline

continuedAsNew = false;
continuedAsNewMessage = null;

TraceHelper.TraceInstance(
TraceEventType.Verbose,
Copy link
Contributor

Choose a reason for hiding this comment

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

indenting

src/DurableTask.Core/IOrchestrationService.cs Outdated Show resolved Hide resolved
src/DurableTask.Core/TaskOrchestrationDispatcher.cs Outdated Show resolved Hide resolved
Copy link
Contributor

@simonporter simonporter left a comment

Choose a reason for hiding this comment

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

:shipit:

@cgillum cgillum merged commit d532814 into Azure:master Jan 23, 2019
shankarsama pushed a commit to shankarsama/durabletask that referenced this pull request Apr 27, 2021
* Optimize Continue As New And Solve Missed Events
* make skip events property driven
* Commit old state in case of an instance store backed tracking
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.

4 participants