Skip to content

Reduce bookmark scheduling backlog startup latency#7730

Open
sfmskywalker wants to merge 5 commits into
release/3.8.0from
codex/7470-parallel-bookmark-scheduling
Open

Reduce bookmark scheduling backlog startup latency#7730
sfmskywalker wants to merge 5 commits into
release/3.8.0from
codex/7470-parallel-bookmark-scheduling

Conversation

@sfmskywalker

Copy link
Copy Markdown
Member

Summary

This PR addresses the sequential scheduling bottleneck reported in #7470 for the release/3.8.0 branch.

DefaultBookmarkScheduler still awaits bookmark scheduling completion and preserves the existing public API/behavior, but it now schedules eligible bookmarks with bounded concurrency instead of awaiting each ScheduleAtAsync / ScheduleCronAsync call serially. The concurrency is capped at 16 operations to avoid turning large bookmark backlogs into unbounded scheduler pressure.

This is intentionally narrower than #7524: it does not make tenant activation fire-and-forget and does not move scheduling into a background worker.

Verification

  • dotnet test test/unit/Elsa.Scheduling.UnitTests/Elsa.Scheduling.UnitTests.csproj --filter FullyQualifiedName~DefaultBookmarkSchedulerTests

Risk

Residual startup blocking can still exist for very large backlogs because scheduling remains awaited. A dedicated background scheduling/recovery worker may still be the better long-term design if host readiness must be fully decoupled from schedule restoration.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant