HangfireIO / HangfireIO/Hangfire

In NextExecution multiple years added when year changes and next execution time is in past

Open
#2,178 2 comments 0 reactions 0 assignees View on GitHub
Dominant language
C#
Stars
10.1k
Forks
1.8k
Avg merge
1h 19m
Merged PRs (30d)
1

Description

E.g. i have next execution datetime is 15/03/2023, if i change my system date time and get hangfire recurring job it return next execution time 15/03/2028.
List recurringJobs = JobStorage.Current.GetConnection().GetRecurringJobs();

In some cases AddOrUpdate method add decades in next execution, the corn expression is very simple 0 12 26 2 SUN and hangfire calculates next execution date time 2034-02-26.

RecurringJob.AddOrUpdate("", cronExpression, TimeZoneInfo.Local);

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.