Coder Social home page Coder Social logo

Terminate services too? about kube-monkey HOT 5 CLOSED

asobti avatar asobti commented on August 16, 2024 1
Terminate services too?

from kube-monkey.

Comments (5)

asobti avatar asobti commented on August 16, 2024

That sounds fantastic. I would love to see that

from kube-monkey.

onelapahead avatar onelapahead commented on August 16, 2024

Awesome, thanks!

from kube-monkey.

Aergonus avatar Aergonus commented on August 16, 2024

I think destroying it is unnecessary for services. If you were to rename it, it wouldn't be able to resolve.

from kube-monkey.

onelapahead avatar onelapahead commented on August 16, 2024

I like the idea as that would be really simple, but I don't believe you can rename a Service since there isn't a way to update the hostname/URL simultaneously:

$ oc patch svc infinispan -p '{ "metadata": { "name": "infinispanx" } }'
Error from server (BadRequest): the name of the object (infinispanx) does not match the name on the URL (infinispan)
$ kubectl patch svc infinispan -p '{ "metadata": { "name": "infinispanx" } }'
Error from server (BadRequest): the name of the object (infinispanx) does not match the name on the URL (infinispan)

Also even if that was allowed, applications might not respect DNS TTL's, and so they could have the ClusterIP of the Service cached and still be able connect.

I was thinking of two ways of "terminating" the Service:

  1. Deleting the Service entirely, but saving a copy of its metadata and spec (and its Endpoint's if it doesn't have a selector i.e. for external IP Service's). Then after a random amount of time restoring the Service.
  2. Blackholing the Service through a NetworkPolicy for a random period of time. This would be simpler but it might not work for two reasons I can think of:
    i) NetworkPolicy's have to be enabled on OpenShift by an admin, so a dev can't just simply use kube-monkey right away for Service's
    ii) If NetworkPolicy's were already being used, there might be a rule allowing the app to connect to the Service which would trump the deny all policy

So I'm thinking about going with 1. With either solution, we can reuse kube-monkey/mtbf for the time between failure, and then I was think of kube-monkey/mtbr for "mean time before restoration". I believe those, and the kube-monkey/enabled label will be the only ones needed for Service's.

Thoughts?

from kube-monkey.

worldtiki avatar worldtiki commented on August 16, 2024

Closing as stale

Sorry @hfuss. If you still have interest in this please leave a comment.

from kube-monkey.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.