Giter Club home page Giter Club logo

advanced-statefulset's People

Contributors

cofyc avatar csuzhangxc avatar kanshiori avatar yisaer avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

advanced-statefulset's Issues

add delete slots e2e tests

based on #13

  • scale in/out with delete slots [podManagementPolicy=OrderedReady]
  • scale in/out with delete slots [podManagementPolicy=Parallel]
  • scale up/down with delete slots [updateStrategy=RollingUpdate]
  • scale up/down with delete slots [updateStrategy=OnDelete]

expose delete slots status in StatefulSet status

Currently, we don't have any mechanism to know the status of delete slots. For example:

When replicas 3, delete slots[1] changes to replicas 3, delete slots[2]. We have no way to know when the scaling operation is done. Because we can't simply compare spec.replicas with status.replicas.

The workaround solution is listing the pods from the APIServer.

deleted slots not correctly recognized by asts while scale down replicas

Consider the following scenario:
I have a asts with .spec.replicas=6, the pod {0,2,4} are in zoneA, the pod {1,3,5} are in zoneB, say zoneA completely down at some time, so I try delete all pods in zoneA while scale down replicas to 3 since I don't want another 3 pods up in zoneB, use the command

kubectl patch asts --type merge -p='{"metadata":{"annotations":{"delete-slots":"[0,2,4]"}},"spec":{"replicas":3}}'

now asts only treates [0,2] as deleted and finally we got 3 alive pods {1,3,4} but the expect is {1,3,5}

pod 4 not recognized by asts controller for deleting because 4 is out range of [0, .spec.replicas=3) as the code shows:

// desired replica slots: [0, replicaCount) - [delete slots]
deleteSlots := helper.GetDeleteSlots(set)
_replicaCount, deleteSlots := helper.GetMaxReplicaCountAndDeleteSlots(*set.Spec.Replicas, deleteSlots)
replicaCount := int(_replicaCount)

can't import client

I wanna watch advanced-statefulset resource in k8s, but i can't import the client package. a error here is:
image

when comment advanced-statefulset go.mod, then run go mod tidy, the same error
image
image

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.