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

Use kubernetes Garbage Collection to simplify resource management #1612

Closed
godber opened this issue Jan 8, 2020 · 1 comment
Closed

Use kubernetes Garbage Collection to simplify resource management #1612

godber opened this issue Jan 8, 2020 · 1 comment
Assignees
Labels
k8s Applies to Teraslice in kubernetes cluster mode only. pkg/teraslice

Comments

@godber
Copy link
Member

godber commented Jan 8, 2020

Use k8s GC to make sure all of the k8s resources related to a job get cleaned up on job execution.

The role of the Kubernetes garbage collector is to delete certain objects that once had an owner, but no longer have an owner.

You can also specify relationships between owners and dependents by manually setting the ownerReference field.

Ref:

https://kubernetes.io/docs/concepts/workloads/controllers/garbage-collection/

@godber godber added the k8s Applies to Teraslice in kubernetes cluster mode only. label Jan 8, 2020
@godber godber self-assigned this Jan 8, 2020
@godber
Copy link
Member Author

godber commented Jan 9, 2020

Not sure if I should make a CRD that has all three of the as the owner of the job (sounds cleanest, but not sure what would be implied by creating a CRD and not doing anything else with it).

Alternatively I could use one of the existing resources as a parent and the others children.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
k8s Applies to Teraslice in kubernetes cluster mode only. pkg/teraslice
Projects
None yet
Development

No branches or pull requests

1 participant