mirror of
https://github.com/fluxcd/flagger.git
synced 2026-04-15 06:57:34 +00:00
update primary scaler query handling to consider mutliple triggers
Signed-off-by: Sanskar Jaiswal <sanskar.jaiswal@weave.works>
This commit is contained in:
@@ -425,10 +425,10 @@ type AutoscalerRefernce struct {
|
||||
// Name of the scaler
|
||||
Name string `json:"name"`
|
||||
|
||||
// PrimaryScalerQuery is the query to use for the primary scaler, if
|
||||
// Flagger generates one.
|
||||
// PrimaryScalerQueries maps a unique id to a query for the primary
|
||||
// scaler, if a scaler supports scaling using queries.
|
||||
// +optional
|
||||
PrimaryScalerQuery string `json:"primaryScalerQuery"`
|
||||
PrimaryScalerQueries map[string]string `json:"primaryScalerQueries"`
|
||||
}
|
||||
|
||||
// CustomMetadata holds labels and annotations to set on generated objects.
|
||||
|
||||
@@ -154,6 +154,13 @@ func (in *AlertProviderStatus) DeepCopy() *AlertProviderStatus {
|
||||
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||
func (in *AutoscalerRefernce) DeepCopyInto(out *AutoscalerRefernce) {
|
||||
*out = *in
|
||||
if in.PrimaryScalerQueries != nil {
|
||||
in, out := &in.PrimaryScalerQueries, &out.PrimaryScalerQueries
|
||||
*out = make(map[string]string, len(*in))
|
||||
for key, val := range *in {
|
||||
(*out)[key] = val
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
@@ -439,7 +446,7 @@ func (in *CanarySpec) DeepCopyInto(out *CanarySpec) {
|
||||
if in.AutoscalerRef != nil {
|
||||
in, out := &in.AutoscalerRef, &out.AutoscalerRef
|
||||
*out = new(AutoscalerRefernce)
|
||||
**out = **in
|
||||
(*in).DeepCopyInto(*out)
|
||||
}
|
||||
if in.IngressRef != nil {
|
||||
in, out := &in.IngressRef, &out.IngressRef
|
||||
|
||||
Reference in New Issue
Block a user