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

WIP adds Context support to manager in place of stop channels. #164

Closed
wants to merge 1 commit into from

Conversation

mhrivnak
Copy link
Contributor

This is backward-incompatible. The manager accepts Context instead of a stop
channel, which helps simplify cancellation workflow and is more in line with
the direction related projects are moving.

This pattern can be expanded in a similar way to controllers, the cache, and
so on if people like it.

fixes #103

This is backward-incompatible. The manager accepts Context instead of a stop
channel, which helps simplify cancellation workflow and is more in line with
the direction related projects are moving.

This pattern can be expanded in a similar way to controllers, the cache, and
so on if people like it.

fixes kubernetes-sigs#103
@k8s-ci-robot k8s-ci-robot added do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. labels Sep 28, 2018
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: mhrivnak
To fully approve this pull request, please assign additional approvers.
We suggest the following additional approver: directxman12

If they are not already assigned, you can assign the PR to them by writing /assign @directxman12 in a comment when ready.

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the size/L Denotes a PR that changes 100-499 lines, ignoring generated files. label Sep 28, 2018
@mhrivnak
Copy link
Contributor Author

@droot @DirectXMan12 @JoelSpeed see what you think of this approach, using a Context. If we're going to make a backward-incompatible change, this may be a good direction to go.

Copy link
Contributor

@DirectXMan12 DirectXMan12 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I like this pattern. Perhaps we can also have signals.SetupSignalHandler work more nicely with this?

@JoelSpeed
Copy link
Contributor

This makes sense to me and seems to solve the original problem :)

@droot
Copy link
Contributor

droot commented Oct 3, 2018

@mhrivnak Thanks for trying this approach. I like it :)

@droot
Copy link
Contributor

droot commented Feb 19, 2019

Closing this PR since the purpose of this PR was to get a feel for the context based solution, which we achieved. The original issue is solved using inner-stop-channel. Thanks @mhrivnak for the POC.

@droot droot closed this Feb 19, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Channel Source is borked due to stop channel injection
5 participants