Commit 78923b0 1 parent b39aceb commit 78923b0 Copy full SHA for 78923b0
File tree 2 files changed +14
-0
lines changed
operator/controllers/http
2 files changed +14
-0
lines changed Original file line number Diff line number Diff line change @@ -41,6 +41,17 @@ func (r *HTTPScaledObjectReconciler) createOrUpdateApplicationResources(
41
41
"Identified HTTPScaledObject creation signal" ),
42
42
)
43
43
44
+ // in some user scenario, we want to integrate http scaler with other
45
+ // scalers. when SkipScaledObjectCreation is set to true,
46
+ // reconciler will skip the KEDA core ScaledObjects creation.
47
+ // you can create your own so, and add http scaler as one of your triggers.
48
+ if baseConfig .SkipScaledObjectCreation {
49
+ logger .Info (
50
+ "Skip scaled objects creation with flag SkipScaledObjectCreation=true" ,
51
+ "HTTPScaledObject" , httpso .Name )
52
+ return nil
53
+ }
54
+
44
55
// create the KEDA core ScaledObjects (not the HTTP one) for
45
56
// the app deployment and the interceptor deployment.
46
57
// this needs to be submitted so that KEDA will scale both the app and
Original file line number Diff line number Diff line change @@ -29,6 +29,9 @@ type Base struct {
29
29
// The namespace the operator should watch. Leave blank to
30
30
// tell the operator to watch all namespaces.
31
31
WatchNamespace string `envconfig:"WATCH_NAMESPACE" default:""`
32
+ // Set to true when you want to create scaled object by your self
33
+ // operator will skip the so creation. default false
34
+ SkipScaledObjectCreation bool `envconfig:"SKIP_SCALED_OBJECT_CREATION" default:"false"`
32
35
}
33
36
34
37
func NewBaseFromEnv () (* Base , error ) {
You can’t perform that action at this time.
0 commit comments