-
Notifications
You must be signed in to change notification settings - Fork 880
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
Support reference model for workloads #676
Comments
The challenge of doing something like this: spec:
workloadRef:
apiVersion: apps/v1
kind: Deployment
name: demo1 is that the rollout-controller has no control over how the underlying ReplicaSet/Pods are created, and thus it cannot control things such as:
FWIW, Flagger does take the reference model approach. Its Canary CRD references a Deployment object. However, in order for Flagger to control scale of the canary vs. stable, it needs to make a "shadow copy" of the Deployment object and related objects (e.g. HPA), so that it can adjust the scale and labels appropriately. In flagger, the referenced Deployment object is mostly used as a pod template definition, since the shadow copy is the eventual deployment that ultimately serves traffic to users at a steady state. The referenced object is used during updates, but it is eventually scaled to 0 at a steady state. If there was a way to use a reference model without resorting to creating shadow copies of the original object, I would support this model. |
@jessesuen The motivation is indeed to we are trying to enable other system to manage workload by itself, for example create and manage workload revisions. In CloneSet, it generates revision labels to group old/new pods during upgrade. Another example is ContainerizedWorkload in OAM, it generates So the solution in my mind could be introduce a standard contract between external workload controller and rollout controller. |
We're investigating a way to do a reference model due to the following motivations:
However, the way we are thinking this will work, probably won't work the way you expect based on the previous comment. Our thought is to reference an object containing a PodTemplateSpec (e.g. a Deployment, PodTemplate), and monitor the referenced object as simply a configuration object holding the definition of the pod template. However, a Rollout will still create and own the ReplicaSets (like it does currently) apiVersion: argoproj.io/v1alpha1
kind: Rollout
metadata:
name: rollout-bluegreen
spec:
workloadRef:
apiVersion: apps/v1
kind: Deployment
name: demo
replicas: 5
strategy:
blueGreen:
activeService: rollout-bluegreen-active
previewService: rollout-bluegreen-preview
autoPromotionEnabled: false In the above example, the |
Yeah, I can get the motivation of your new proposal (i.e. treating user's Deployment as a "UI"). And yes, it can not solve the problem that we need to rollout the custom workloads like CloneSet etc. I'd assume it could address some folks' concerns (i.e. they can not use Deployment. |
Signed-off-by: Alexander Matyushentsev <[email protected]>
Signed-off-by: Alexander Matyushentsev <[email protected]>
Signed-off-by: Alexander Matyushentsev <[email protected]>
Signed-off-by: Alexander Matyushentsev <[email protected]>
Signed-off-by: Alexander Matyushentsev <[email protected]>
Signed-off-by: Alexander Matyushentsev <[email protected]>
Signed-off-by: Alexander Matyushentsev <[email protected]>
Signed-off-by: Alexander Matyushentsev <[email protected]>
Signed-off-by: Alexander Matyushentsev <[email protected]>
Signed-off-by: Alexander Matyushentsev <[email protected]>
Signed-off-by: Alexander Matyushentsev <[email protected]>
Signed-off-by: Alexander Matyushentsev <[email protected]>
Signed-off-by: Alexander Matyushentsev <[email protected]>
Signed-off-by: Alexander Matyushentsev <[email protected]>
Signed-off-by: Alexander Matyushentsev <[email protected]>
Signed-off-by: Alexander Matyushentsev <[email protected]>
Signed-off-by: Alexander Matyushentsev <[email protected]>
Signed-off-by: Alexander Matyushentsev <[email protected]>
Signed-off-by: Alexander Matyushentsev <[email protected]>
Signed-off-by: Alexander Matyushentsev <[email protected]>
Signed-off-by: Alexander Matyushentsev <[email protected]>
Signed-off-by: Alexander Matyushentsev <[email protected]>
Signed-off-by: Alexander Matyushentsev <[email protected]>
Signed-off-by: Alexander Matyushentsev <[email protected]>
Signed-off-by: Alexander Matyushentsev <[email protected]>
Signed-off-by: Alexander Matyushentsev <[email protected]>
Signed-off-by: Alexander Matyushentsev <[email protected]>
Signed-off-by: Alexander Matyushentsev <[email protected]>
Signed-off-by: Alexander Matyushentsev <[email protected]>
* feat: support reference model for workloads (#676) Signed-off-by: Alexander Matyushentsev <[email protected]>
Summary
What change needs making?
Consider change the embedded mode to reference mode, so we could have more flexibility on workload side.
Use Cases
To support we use Deployment or our own stateless workload (like CloneSet).
Message from the maintainers:
Impacted by this bug? Give it a 👍. We prioritize the issues with the most 👍.
The text was updated successfully, but these errors were encountered: