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

Provide a graceful way of stopping IJobWorker instances #39

Open
bobcat1506 opened this issue Oct 17, 2019 · 2 comments
Open

Provide a graceful way of stopping IJobWorker instances #39

bobcat1506 opened this issue Oct 17, 2019 · 2 comments
Assignees

Comments

@bobcat1506
Copy link
Contributor

Describe the solution you'd like
Provide a graceful way of stopping IJobWorker instances such as a StopAsync() method.

@ChrisKujawa
Copy link
Collaborator

ChrisKujawa commented Nov 5, 2019

So instead of the Dispose method you would like to have a method which returns a Task? Currently the Dispose is kind of async it just cancels the CancellationTokenSource which then eventually will cancel the running threads.

@ChrisKujawa
Copy link
Collaborator

IAsyncDisposable is available for .net core 3 + https://docs.microsoft.com/de-de/dotnet/api/system.iasyncdisposable?view=net-5.0

As long we want to support core 2.1, we can't implement this interface.

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

No branches or pull requests

2 participants