Merged
Conversation
…into wangbill/schedule-poc
nytian
reviewed
Feb 26, 2025
Co-authored-by: Naiyuan Tian <110135109+nytian@users.noreply.github.com>
Co-authored-by: Naiyuan Tian <110135109+nytian@users.noreply.github.com>
Co-authored-by: Naiyuan Tian <110135109+nytian@users.noreply.github.com>
This reverts commit 65db0e2.
Member
Author
|
fyi branch for e2e tests https://github.com/microsoft/durabletask-dotnet/tree/wangbill/schedule-e2e-tests. i added 32 testcases all passing |
cgillum
reviewed
Feb 28, 2025
sebastianburckhardt
approved these changes
Feb 28, 2025
Member
sebastianburckhardt
left a comment
There was a problem hiding this comment.
LGTM.
(I did not review the tests)
changes are updated based on feedback, thanks
cgillum
reviewed
Mar 1, 2025
Member
cgillum
left a comment
There was a problem hiding this comment.
Added some comments. I'm particularly concerned about the possibility of null-ref exceptions in the Schedule.cs code. We're overriding the nullable reference types checks in ways that seem to open the door for lots of null-ref exceptions.
src/ScheduledTasks/Extension/DurableTaskClientBuilderExtensions.cs
Outdated
Show resolved
Hide resolved
src/ScheduledTasks/Extension/DurableTaskSchedulerWorkerExtensions.cs
Outdated
Show resolved
Hide resolved
cgillum
approved these changes
Mar 3, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Schedule Support for Durable Task Framework
Overview
This PR introduces comprehensive scheduling capabilities to the Durable Task Framework, enabling users to create and manage recurring task executions with fine-grained control over timing and execution parameters.
Key Features
Create, pause, resume, update, and delete scheduled tasks
Flexible schedule configuration with support for:
Custom intervals (minimum 1 second)
Start and end times
Immediate or delayed first execution
Custom orchestration instance IDs
Orchestration input parameters
ScheduleCreationOptions for initial setup with required parameters:
scheduleId: Unique identifier for the schedule
orchestrationName: Target orchestration to execute
interval: Time between executions
Optional parameters:
startAt: Custom start time
endAt: Schedule termination time
orchestrationInput: Input data for the orchestration
orchestrationInstanceId: Custom instance ID
startImmediatelyIfLate: Controls immediate execution behavior
Robust state transitions with validation
Schedule status tracking (Active, Paused, etc.)
Execution history tracking:
Last run time
Next scheduled run time
Execution token for operation validation
Clean and intuitive client API through ScheduledTaskClient
Async operations for all schedule management functions
Comprehensive error handling and logging
Support for cancellation tokens
Simple worker configuration through extension methods
Automatic registration of required components:
Schedule entity
Schedule operation orchestrator