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

Make UseNCronJobAsync() mandatory when startup jobs have been defined #136

Merged
merged 1 commit into from
Nov 5, 2024

Conversation

nulltoken
Copy link
Collaborator

Pull request description

Follow up to #121 (comment)

Slight enhancement to control of startup jobs.

The lib will now throw on startup only when:

  • Startup jobs have been defined
  • UseNCronJobAsync hasn't been invoked

No change at the doc level were required as no wording was hinting to UseNCronJobAsync being optional.

This should prevent some misconfiguration at the user level.

PR meta checklist

  • Pull request is targeted at main branch for code
  • Pull request is linked to all related issues, if any.

Code PR specific checklist

  • My code follows the code style of this project and AspNetCore coding guidelines.
  • My change requires a change to the documentation.
    • I have updated the documentation accordingly.
  • I have updated the appropriate sub section in the CHANGELOG.md.
  • I have added, updated or removed tests to according to my changes.
    • All tests passed.

@nulltoken nulltoken requested a review from linkdotnet November 5, 2024 06:06
Copy link

codecov bot commented Nov 5, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Files with missing lines Coverage Δ
src/NCronJob/NCronJobExtensions.cs 97.29% <ø> (ø)
src/NCronJob/Scheduler/QueueWorker.cs 70.58% <100.00%> (+2.54%) ⬆️

@nulltoken nulltoken force-pushed the ntk/fail_when_startup_jobs branch from 97f7348 to 8879281 Compare November 5, 2024 07:21
@nulltoken nulltoken force-pushed the ntk/fail_when_startup_jobs branch from 8879281 to 679a271 Compare November 5, 2024 07:28
@nulltoken nulltoken mentioned this pull request Nov 5, 2024
Merged
@nulltoken nulltoken merged commit f000402 into NCronJob-Dev:v4 Nov 5, 2024
4 checks passed
@nulltoken nulltoken deleted the ntk/fail_when_startup_jobs branch November 5, 2024 21:09
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.

2 participants