Repository: apache/camel-k
Pull request #1587 (2020-07-01 16:01:43)

feat: Integration scale sub-resource works with HPA
**Release Note**
```release-note
feat: Integration scale sub-resource works with HPA
```



Patch:
diff --git a/addons/master/master.go b/addons/master/master.go
index a88d90ce5..e9ca949ce 100644
--- a/addons/master/master.go
+++ b/addons/master/master.go
@@ -109,7 +109,7 @@ func (t *masterTrait) Configure(e *trait.Environment) (bool, error) {
 		}
 
 		if t.LabelKey == nil {
-			val := "camel.apache.org/integration"
+			val := v1.IntegrationLabel
 			t.LabelKey = &val
 		}
 
diff --git a/deploy/crd-integration.yaml b/deploy/crd-integration.yaml
index 18d0e57f9..0366bde43 100644
--- a/deploy/crd-integration.yaml
+++ b/deploy/crd-integration.yaml
@@ -46,6 +46,7 @@ spec:
   scope: Namespaced
   subresources:
     scale:
+      labelSelectorPath: .status.selector
       specReplicasPath: .spec.replicas
       statusReplicasPath: .status.replicas
     status: {}
@@ -323,6 +324,8 @@ spec:
               type: string
             runtimeVersion:
               type: string
+            selector:
+              type: string
             version:
               type: string
           type: object
diff --git a/deploy/olm-catalog/camel-k-dev/1.1.0-snapshot/integrations.camel.apache.org.crd.yaml b/deploy/olm-catalog/camel-k-dev/1.1.0-snapshot/integrations.camel.apache.org.crd.yaml
index 18d0e57f9..0366bde43 100644
--- a/deploy/olm-catalog/camel-k-dev/1.1.0-snapshot/integrations.camel.apache.org.crd.yaml
+++ b/deploy/olm-catalog/camel-k-dev/1.1.0-snapshot/integrations.camel.apache.org.crd.yaml
@@ -46,6 +46,7 @@ spec:
   scope: Namespaced
   subresources:
     scale:
+      labelSelectorPath: .status.selector
       specReplicasPath: .spec.replicas
       statusReplicasPath: .status.replicas
     status: {}
@@ -323,6 +324,8 @@ spec:
               type: string
             runtimeVersion:
               type: string
+            selector:
+              type: string
             version:
               type: string
           type: object
diff --git a/deploy/resources.go b/deploy/resources.go
index 8909f036f..573461fe0 100644
--- a/deploy/resources.go
+++ b/deploy/resources.go
@@ -140,9 +140,9 @@ var assets = func() http.FileSystem {
 		"/crd-integration.yaml": &vfsgen۰CompressedFileInfo{
 			name:             "crd-integration.yaml",
 			modTime:          time.Time{},
-			uncompressedSize: 11558,
+			uncompressedSize: 11649,
 
-			compressedContent: []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xec\x5a\x4f\x73\xe2\x38\x16\xbf\xfb\x53\xbc\x0a\x87\x9e\xa9\x0a\xb0\x3d\x73\xd9\x62\x4f\x2c\x9d\xd4\xb2\x9d\x26\x29\xa0\x67\xaa\x8f\xc2\x7e\x18\x6d\x64\x49\x2b\xc9\x90\xec\xd6\x7e\xf7\xad\x27\xd9\xc6\x06\x9b\x10\xd2\x5d\x53\x35\x15\xdf\xb0\xa4\xf7\xe7\xf7\xfe\xea\x99\x1e\xf4\xbf\xdf\x13\xf5\xe0\x8e\xc7\x28\x2d\x26\xe0\x14\xb8\x0d\xc2\x58\xb3\x78\x83\xb0\x50\x6b\xb7\x63\x06\xe1\x56\xe5\x32\x61\x8e\x2b\x09\x3f\x8d\x17\xb7\x3f\x43\x2e\x13\x34\xa0\x24\x82\x32\x90\x29\x83\x51\x0f\x62\x25\x9d\xe1\xab\xdc\x29\x03\x22\x10\x04\x96\x1a\xc4\x0c\xa5\xb3\x03\x80\x05\xa2\xa7\x3e\xbb\x5f\x4e\x27\x37\xb0\xe6\x02\x21\xe1\x36\x1c\xc2\x04\x76\xdc\x6d\xa2\x1e\xb8\x0d\xb7\xb0\x53\xe6\x11\xd6\xca\x00\x4b\x12\x4e\x8c\x99\x00\x2e\xd7\xca\x64\x41\x0c\x83\x29\x33\x09\x97\x29\xc4\x4a\x3f\x1b\x9e\x6e\x1c\xa8\x9d\x44\x63\x37\x5c\x0f\xa2\x1e\x2c\x49\x8d\xc5\x6d\x29\x89\x0d\x64\x3d\x4f\xa7\xe0\x9b\xca\x0b\x1d\x6a\xea\x16\x28\x5c\xc3\x6f\x68\x2c\x31\xf9\x65\xf0\x97\xa8\x07\x3f\xd1\x96\xab\x62\xf1\xea\xe7\xbf\xc1\xb3\xca\x21\x63\xcf\x20\x95\x83\xdc\x62\x8d\x32\x3e\xc5\xa8\x1d\x70\x09\xb1\xca\xb4\xe0\x4c\xc6\xb8\x57\xab\xe2\x30\x00\x2f\x00\xd1\x50\x2b\xc7\xb8\x04\xe6\xd5\x00\xb5\xae\x6f\x03\xe6\xa2\x5e\xd4\x03\xff\x6c\x9c\xd3\xa3\xe1\x70\xb7\xdb\x0d\x98\x17\x77\xa0\x4c\x3a\x2c\xb5\x1b\xde\x4d\x27\x37\xb3\xc5\x4d\xdf\x8b\x1c\xf5\xe0\xab\x14\x68\x2d\x18\xfc\x77\xce\x0d\x26\xb0\x7a\x06\xa6\xb5\xe0\x31\x5b\x09\x04\xc1\x76\x64\x38\x6f\x1d\x6f\x74\x2e\x61\x67\xb8\xe3\x32\xbd\x06\x5b\x58\x3d\xea\x35\xac\xb3\x87\xab\x14\x8f\xdb\xc6\x06\x25\x81\x49\xb8\x1a\x2f\x60\xba\xb8\x82\xbf\x8f\x17\xd3\xc5\x75\xd4\x83\xdf\xa7\xcb\x7f\xdc\x7f\x5d\xc2\xef\xe3\xf9\x7c\x3c\x5b\x4e\x6f\x16\x70\x3f\x87\xc9\xfd\xec\xd3\x74\x39\xbd\x9f\x2d\xe0\xfe\x16\xc6\xb3\x6f\xf0\x79\x3a\xfb\x74\x0d\xc8\xdd\x06\x0d\xe0\x93\x36\x24\xbf\x32\xc0\x09\x48\x4c\xc8\xa6\xa5\x03\x95\x02\x90\x7f\xd0\x6f\xab\x31\xe6\x6b\x1e\x83\x60\x32\xcd\x59\x8a\x90\xaa\x2d\x1a\x49\xee\xa1\xd1\x64\xdc\x92\x39\x2d\x30\x99\x44\x3d\x10\x3c\xe3\xce\x7b\x91\x3d\x56\x8a\xd8\x7c\xcf\xd8\x8a\x98\xe6\x85\x3b\x8d\x80\x69\x8e\x4f\x0e\xa5\x97\x66\xf0\xf8\x57\x3b\xe0\x6a\xb8\xfd\xb8\x42\xc7\x3e\x46\x8f\x5c\x26\x23\x98\xe4\xd6\xa9\x6c\x8e\x56\xe5\x26\xc6\x4f\xb8\xe6\xd2\xbb\x7f\x94\xa1\x63\x09\x73\x6c\x14\x01\x48\x96\xe1\x08\xb8\x74\x98\x9a\xa0\xc8\x20\x66\x19\x8a\x9a\x67\x44\x00\x82\xad\x50\x58\xda\x0f\x64\xfb\x11\x5c\xf9\x4d\xfd\xc7\xab\x88\x00\xa3\x85\x7d\x70\x3d\x18\x22\x67\x26\x4a\xe4\x99\x2c\x0e\xf5\xe1\x9f\x8b\xfb\xd9\x03\x73\x9b\x11\x0c\xac\x63\x2e\xb7\x03\xbd\x61\x16\xa3\xe0\x92\x09\xda\xd8\x70\xed\xbc\x6e\x14\x6f\x35\x89\xa0\xbe\x31\xc8\xfb\x50\x7b\xe3\x9e\x35\x8e\x80\x7c\x47\xa6\x9d\xbc\x1e\xb9\x3b\x87\xd3\x7e\x5b\xe0\xf3\xb9\xfa\x7d\x16\x17\x83\x3e\x2c\x6c\x17\x2b\x99\x67\x2b\xca\x75\x6b\xd0\x2a\xb1\x0d\x4e\xf3\xe6\xd1\xc0\xce\x8b\x86\x26\x02\x48\x8d\xca\xf5\x08\x5a\x4c\x43\xc7\x0b\x90\x83\xd9\xa7\x7b\x7d\xfc\x5b\xc1\xad\xfb\x7c\xb8\x72\xc7\x6d\xd0\x4c\x8b\xdc\x30\xd1\xf4\x00\xbf\x60\x37\xca\xb8\xd9\x9e\x38\x69\x5c\xa0\x61\xb9\x4c\x73\xc1\x4c\xe3\x54\x04\x60\x63\x45\x52\xfb\x43\x9a\xc5\x98\xd0\xbb\x7c\x65\x0a\x0f\x2c\x08\xd9\x98\x09\x2c\x69\x92\xf7\x94\xaa\x97\x58\x6a\x8c\x0f\x91\x0c\xf8\x1e\x6e\x6c\x01\x3d\xbc\x1b\xc1\x7f\xff\x17\x01\x6c\x99\xe0\xa1\xd4\x04\x76\x4a\xa3\x1c\x3f\x4c\x7f\xfb\x75\x11\x6f\x30\x63\xa3\x36\x33\xd5\x30\xa2\xa4\x44\xe1\x1c\x76\x57\x19\xa2\x8e\x14\x8c\x1f\xa6\x05\x15\x6d\x94\x46\xe3\xf8\x1e\x2f\x0a\x95\x2a\x60\xab\x77\x07\xfc\x3e\x90\x40\x45\x8d\x48\x28\x44\x31\x30\xdd\x86\x77\x98\x80\x0d\xec\x7d\x3e\xe7\x94\x86\x29\x9d\xa1\x74\x7b\x0b\x97\x8f\x5a\x53\xd6\x54\xab\x7f\x61\xec\x06\xb0\x40\x43\x44\xc8\x90\xb9\x48\xa8\xa4\x6e\xd1\x38\x30\x18\xab\x54\xf2\xff\x54\x94\x6d\x59\xa9\x05\x73\x68\x5d\x83\xa2\x0f\x64\xaa\x97\x5b\x26\x72\xbc\xa6\xac\xe7\x4b\x8d\x41\xe2\x01\xb9\xac\x51\xf3\x5b\xec\x00\xbe\x28\x83\xbe\xbe\x8e\x7c\xa1\xb1\xa3\xe1\x30\xe5\xae\x4c\x51\xb1\xca\xb2\x5c\x72\xf7\x3c\xac\xd5\x78\x3b\x4c\x70\x8b\x62\x68\x79\xda\x67\x26\xde\x70\x87\xb1\xcb\x0d\x0e\x99\xe6\x7d\x2f\xb8\x0c\xa9\x29\x4b\x7a\x95\x37\x7d\xa8\x49\x7a\x14\x9d\x55\x38\x74\xe2\x4e\x21\x41\x16\x66\xc5\xb1\x20\xff\x1e\x5e\x7a\x45\xa8\xcc\x6f\x16\x4b\x28\x99\x7a\x13\x34\x31\xf7\x68\xef\x8f\xd9\x3d\xf0\x04\x14\x97\x6b\x5f\x14\xa8\xaa\x1b\x95\x79\x8a\x28\x13\xad\xb8\x74\xfe\x47\x2c\x38\xca\x26\xe8\x36\x5f\x65\xdc\x85\x82\x8b\xd6\x91\x7d\x06\x30\x61\x92\x7a\x84\x15\x42\xae\x13\xe6\x30\x19\xc0\x54\xc2\x84\xf2\xc1\x84\x51\x1b\xf0\x83\x61\x27\x84\x6d\x9f\x20\x7d\x19\xf8\x7a\x7d\x69\x6e\x0c\x68\x55\xaf\xcb\xda\xd1\x6a\xa1\x5a\x24\x2e\x34\xc6\x8d\xe8\x48\xd0\xfa\x56\x84\xc2\x1d\xc9\xef\x0f\x93\x5e\x77\x4c\xd2\x13\x2b\xb9\xe6\x69\x6e\x6a\xb9\xa1\xe6\xf3\x0e\x33\x7b\xf8\xf2\x40\xb6\x49\x9d\x80\x97\xae\xdf\x3f\x3a\xd1\xc5\xbd\x06\x48\xcb\xfb\x0e\x4c\xf7\x8f\xf7\xd3\x0b\x4e\x96\xfd\x5b\xdb\xd1\xbe\x3f\xda\xba\xe0\xd9\x1d\xad\xb4\x9a\xb3\xbe\xc4\x8c\x61\xcf\x8d\x95\x04\x35\xca\x04\x65\xdc\x02\x48\x07\xe6\x27\xf4\xe9\xe2\xb2\x16\x6a\x77\x2e\xf9\x86\x49\x6f\x85\xda\xf9\x7c\x20\x21\x97\xd6\x99\xdc\x87\x42\x72\x14\xe0\x94\x17\x58\x08\x3c\x7f\xa6\x05\x34\x2e\xe1\xdb\xf8\xcb\xdd\x90\x1a\x04\xf8\xb4\xb8\xfb\x1e\x7a\x3d\x72\x77\xa8\x40\x27\x15\x6d\x14\x5d\x21\x0e\xf7\x37\xdb\x11\xc3\xb8\x7b\x08\x1b\x6b\xd9\xcb\x77\x0b\xd6\x17\x1b\xda\x40\xd1\xc6\x1c\xd0\xbd\x0d\x25\xb5\xfb\xc9\x91\x2e\x47\x8d\x33\x97\xd6\x31\x21\x7c\x68\x0c\x79\x6b\x5c\x9e\x94\xbe\xac\xe7\x87\xe2\x87\x0b\x9b\xef\x39\x7e\xfd\xa5\x95\xd8\xbe\x5d\x6a\x50\x53\x96\x3b\x65\x7e\xa8\xd7\x1d\xb4\x38\x2f\xb2\x68\x98\xa2\xec\xd0\x2f\xcb\x23\x74\x3b\xa4\xfb\x4d\x4b\x26\xab\xcb\xbc\x52\x4a\x20\x3b\x34\x42\x20\x20\x1d\xca\x23\xef\x7a\x11\x8b\xda\xd9\xcf\xf8\xfc\x96\xe3\x73\x5c\x5f\x74\x3c\x53\xb9\x74\xbe\x19\xbc\xe4\xb4\xef\xbb\x2f\x39\xd8\x9d\xb9\x5b\xcd\xba\x7c\xd6\xd8\x66\xd6\x17\x39\x5d\x90\x63\x2d\x9a\x2d\x8f\x71\x1c\xc7\x04\xcd\xac\x45\xc3\x4e\x8e\x6f\x70\xe0\xc5\xbb\xfb\x5e\x72\xdc\x37\xd7\x31\x6a\xea\xc4\xce\xf0\xa7\x69\x6d\xbb\xcf\xc8\x4a\x97\xc3\xac\x84\xea\xd2\x9a\x53\xd3\x49\xa9\x58\x99\xb4\xbc\x23\x86\x0b\xe3\xe3\x60\xae\x72\x87\xf6\x4e\xb1\xe4\x20\x3f\xee\x9f\xdc\x4f\xb6\x14\x68\x83\x43\xad\xac\x23\xc3\xc5\x68\x6d\xe9\x19\xad\xc7\x3a\xdc\xe3\x2c\xfd\xbb\xdd\x38\x3c\xe5\x04\xe6\x0c\x6c\xee\xca\x61\xcd\x25\x71\x06\x20\x3c\x2e\xe7\xf0\xf1\x1b\x8b\x36\xa1\x86\x7f\x39\x6d\xbb\x0c\x79\x5f\x63\x77\x5c\x88\xe0\x12\xda\xa0\x0b\x57\x86\xe2\xd2\xc1\x1c\x98\x5c\x3a\x9e\xb5\x75\x68\x3f\x2a\xcf\x5d\x90\x7d\x42\xcb\x70\xc8\xab\x3e\x18\xea\xce\x04\x0d\x98\xc7\xa1\x3d\xf1\x19\x85\x82\x8c\x71\x19\x3c\xbb\xd1\xb8\xfb\xfb\x6e\x60\xfa\xea\xa4\x73\xa2\xff\x7f\x8d\xd4\x67\xe0\xf8\x02\x96\x67\x00\x7d\xb4\xd4\x7e\x97\x0a\x93\x8f\x73\x6e\x53\x7e\x67\xe3\x3e\xa5\x56\x54\x39\xde\x70\xa1\x62\x9a\xad\xb8\xe0\x6d\x28\x7d\xbf\x2e\x2b\x56\x32\x18\xe5\xa2\x2a\x55\xd3\x68\x52\x12\x2a\x76\xac\x0a\x18\x2a\xed\x59\xd5\xd1\xb5\xd8\x93\x1a\x62\x88\xd1\xf8\x69\xbb\xbf\xc9\x0f\x5e\xe9\x7f\x82\x59\xb7\x34\x4c\x5a\x2f\xc4\x92\x77\x05\xe8\x41\x8e\xb3\x0e\x28\x09\x94\x91\x50\xa8\xe0\x2a\x42\x98\x84\x21\x83\x92\x58\xb8\x43\x97\xc3\x2a\x60\x52\xb9\x0d\x9a\x63\xc9\xa1\xd6\x6a\x27\xcc\x61\xff\xd2\xbc\x43\x4a\x7e\xf5\xb3\x8a\x33\x15\x5c\xfa\x19\xd4\x5e\x49\x6e\x6b\x5a\xee\x98\xad\x26\x1f\x3f\x4e\xe6\x0c\xad\x3d\xaf\xe2\x8c\x61\x93\x67\x4c\x82\x41\x96\xf8\xef\x20\xc5\x51\xe0\x32\xe1\x31\xf3\xd7\xc4\x04\x1d\xe3\xc2\x02\x5b\xa9\xfc\x38\xee\x0b\x81\x36\x58\xb3\x60\xbb\x6a\x2f\x08\x6d\x90\xd9\xae\x34\x76\x04\x70\xd8\x5c\xdd\xda\x2a\x80\x3f\xd8\x02\xfb\xb7\xc9\x72\x9c\x85\x3a\x64\x29\x92\x50\x51\x37\x2b\x31\xae\xc3\x87\xc0\x35\x2c\x4d\x8e\xd7\x70\xcb\x84\xc5\x6b\xf8\x2a\x1f\xa5\xda\x5d\x26\xd1\x99\xdd\xba\xef\xd2\xd5\xba\xf1\x35\xa0\x92\xea\x02\xc6\xa7\xa7\x2d\x9d\xd1\xd9\x31\x88\xb9\xa0\x18\xbf\xcf\xb8\x0e\x9e\x3f\xcf\x8c\x2b\xe1\x29\xda\xf3\xc7\x41\x6b\xc6\x45\x6e\x4e\x8f\x83\x6e\xc3\x9e\x63\x13\x9f\x32\x70\x77\xe2\x79\xc1\x48\xb1\xda\xa2\x69\xbd\x73\xb5\x09\x35\x2f\xf6\xb7\x37\xf7\xa7\x3d\x90\xaa\xb5\xc3\x4c\x77\xdc\x0f\x4f\x4d\x8e\x0e\x08\x7c\x61\x4f\x6f\xa6\xd1\x5d\x08\xcf\xad\x5f\x67\x14\x83\xee\x08\x20\x57\x2f\x24\x39\xbd\xfa\x85\x3d\x75\x1a\xb5\xab\x8b\xed\x50\xed\x1c\xb5\x4e\xa8\xd4\xad\x4e\xbf\x70\xbf\xd6\x85\xe0\x30\x2d\x4b\x2d\x12\x74\xaa\x95\xa2\x44\x43\x0d\xc7\xfc\x7d\xba\xf7\x07\x8c\x47\xde\xa7\x7b\x87\x79\xbf\x72\xc8\xc5\xfb\xac\xee\xc2\xe3\xef\xb3\xba\xb7\xcd\x30\xde\x67\x75\x7f\x92\x59\x1d\xcf\x5a\xac\xd5\xc9\xe4\x55\x5f\x1f\x37\xcc\x9e\x6e\x36\x6b\x93\x18\xff\x47\xae\x63\x4f\xe8\x26\x2e\x98\xa3\x96\xe2\xfd\x5b\xe8\x25\xdf\x42\x83\x63\x3e\x18\xb5\xe5\x2d\x31\xd4\xac\x6f\xcd\xbd\xaf\x30\x51\xc1\xa5\xe5\x8f\x4f\x27\x8f\x6d\x5f\xb5\xbf\xc5\xe3\x0f\x5e\x95\xf4\x60\xfb\x71\xff\xab\xfa\x37\x62\xf8\xd3\x9d\x5f\x82\xe2\xbb\x19\x26\x23\x70\xa6\xba\x07\x5a\xa7\x0c\x85\x48\x78\xf7\xff\x00\x00\x00\xff\xff\x40\x3b\x1f\x46\x26\x2d\x00\x00"),
+			compressedContent: []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xec\x1a\x4d\x6f\xe3\xb8\xf5\xae\x5f\xf1\x10\x1f\x66\x17\x88\xed\xce\xee\xa5\x70\x4f\xae\x27\x41\xdd\xc9\x38\x81\xe5\xd9\xc5\x1c\x69\xe9\x59\x66\x43\x91\x2a\x49\xd9\x49\x8b\xfe\xf7\xe2\x91\x92\x2c\xc9\x92\xe3\x38\x33\x58\x60\x11\xdd\x2c\xbe\xef\x6f\x3e\x79\x00\xc3\xef\xf7\x04\x03\xb8\xe3\x11\x4a\x83\x31\x58\x05\x76\x8b\x30\xcd\x58\xb4\x45\x08\xd5\xc6\xee\x99\x46\xb8\x55\xb9\x8c\x99\xe5\x4a\xc2\x4f\xd3\xf0\xf6\x67\xc8\x65\x8c\x1a\x94\x44\x50\x1a\x52\xa5\x31\x18\x40\xa4\xa4\xd5\x7c\x9d\x5b\xa5\x41\x78\x82\xc0\x12\x8d\x98\xa2\xb4\x66\x04\x10\x22\x3a\xea\x8b\xfb\xd5\x7c\x76\x03\x1b\x2e\x10\x62\x6e\x3c\x12\xc6\xb0\xe7\x76\x1b\x0c\xc0\x6e\xb9\x81\xbd\xd2\x8f\xb0\x51\x1a\x58\x1c\x73\x62\xcc\x04\x70\xb9\x51\x3a\xf5\x62\x68\x4c\x98\x8e\xb9\x4c\x20\x52\xd9\xb3\xe6\xc9\xd6\x82\xda\x4b\xd4\x66\xcb\xb3\x51\x30\x80\x15\xa9\x11\xde\x96\x92\x18\x4f\xd6\xf1\xb4\x0a\xbe\xa9\xbc\xd0\xa1\xa6\x6e\x61\x85\x6b\xf8\x0d\xb5\x21\x26\xbf\x8c\xfe\x12\x0c\xe0\x27\x02\xb9\x2a\x0e\xaf\x7e\xfe\x1b\x3c\xab\x1c\x52\xf6\x0c\x52\x59\xc8\x0d\xd6\x28\xe3\x53\x84\x99\x05\x2e\x21\x52\x69\x26\x38\x93\x11\x1e\xd4\xaa\x38\x8c\xc0\x09\x40\x34\xd4\xda\x32\x2e\x81\x39\x35\x40\x6d\xea\x60\xc0\x6c\x30\x08\x06\xe0\x9e\xad\xb5\xd9\x64\x3c\xde\xef\xf7\x23\xe6\xc4\x1d\x29\x9d\x8c\x4b\xed\xc6\x77\xf3\xd9\xcd\x22\xbc\x19\x3a\x91\x83\x01\x7c\x95\x02\x8d\x01\x8d\xff\xce\xb9\xc6\x18\xd6\xcf\xc0\xb2\x4c\xf0\x88\xad\x05\x82\x60\x7b\x72\x9c\xf3\x8e\x73\x3a\x97\xb0\xd7\xdc\x72\x99\x5c\x83\x29\xbc\x1e\x0c\x1a\xde\x39\x98\xab\x14\x8f\x9b\x06\x80\x92\xc0\x24\x5c\x4d\x43\x98\x87\x57\xf0\xf7\x69\x38\x0f\xaf\x83\x01\xfc\x3e\x5f\xfd\xe3\xfe\xeb\x0a\x7e\x9f\x2e\x97\xd3\xc5\x6a\x7e\x13\xc2\xfd\x12\x66\xf7\x8b\x4f\xf3\xd5\xfc\x7e\x11\xc2\xfd\x2d\x4c\x17\xdf\xe0\xf3\x7c\xf1\xe9\x1a\x90\xdb\x2d\x6a\xc0\xa7\x4c\x93\xfc\x4a\x03\x27\x43\x62\x4c\x3e\x2d\x03\xa8\x14\x80\xe2\x83\x7e\x9b\x0c\x23\xbe\xe1\x11\x08\x26\x93\x9c\x25\x08\x89\xda\xa1\x96\x14\x1e\x19\xea\x94\x1b\x72\xa7\x01\x26\xe3\x60\x00\x82\xa7\xdc\xba\x28\x32\xc7\x4a\x11\x9b\xef\x99\x5b\x01\xcb\x78\x11\x4e\x13\x60\x19\xc7\x27\x8b\xd2\x49\x33\x7a\xfc\xab\x19\x71\x35\xde\x7d\x5c\xa3\x65\x1f\x83\x47\x2e\xe3\x09\xcc\x72\x63\x55\xba\x44\xa3\x72\x1d\xe1\x27\xdc\x70\xe9\xc2\x3f\x48\xd1\xb2\x98\x59\x36\x09\x00\x24\x4b\x71\x02\x5c\x5a\x4c\xb4\x57\x64\x14\xb1\x14\x45\x2d\x32\x02\x00\xc1\xd6\x28\x0c\xc1\x03\xf9\x7e\x02\x57\x0e\x68\xf8\x78\x15\x90\xc1\xe8\xe0\x90\x5c\x0f\x9a\xc8\xe9\x99\x12\x79\x2a\x0b\xa4\x21\xfc\x33\xbc\x5f\x3c\x30\xbb\x9d\xc0\xc8\x58\x66\x73\x33\xca\xb6\xcc\x60\xe0\x43\x32\x46\x13\x69\x9e\x59\xa7\x1b\xe5\x5b\x4d\x22\xa8\x03\x7a\x79\x1f\x6a\x6f\xec\x73\x86\x13\xa0\xd8\x91\x49\x2f\xaf\x47\x6e\xcf\xe1\x74\x00\xf3\x7c\x3e\x57\xbf\xcf\xe2\xa2\xd1\xa5\x85\xe9\x63\x25\xf3\x74\x4d\xb5\x6e\x03\x99\x8a\x4d\x83\xd3\xb2\x89\xea\xd9\x39\xd1\x50\x07\x00\x89\x56\x79\x36\x81\x0e\xd7\x10\x7a\x61\x64\xef\xf6\xf9\x41\x1f\xf7\x56\x70\x63\x3f\xb7\x4f\xee\xb8\xf1\x9a\x65\x22\xd7\x4c\x34\x23\xc0\x1d\x98\xad\xd2\x76\x71\x20\x4e\x1a\x17\xd6\x30\x5c\x26\xb9\x60\xba\x81\x15\x00\x98\x48\x91\xd4\x0e\x29\x63\x11\xc6\xf4\x2e\x5f\xeb\x22\x02\x0b\x42\x26\x62\x02\x4b\x9a\x2e\xb0\x42\x14\x18\x59\xa5\x9b\xc6\x34\xc5\xdb\x02\x92\xe2\xac\x34\x52\x09\x98\x61\xd4\xb6\xb9\x47\x6e\x03\x76\xb8\xc7\xbf\x9b\xc0\x7f\xff\x17\x00\xec\x98\xe0\xbe\x29\x79\xc1\x54\x86\x72\xfa\x30\xff\xed\xd7\x30\xda\x62\xca\x26\x5d\x0e\xad\x59\x93\xca\x17\x25\xbe\x87\xae\x6a\x49\xdd\xa6\x30\x7d\x98\x17\x54\x32\xad\x32\xd4\x96\x1f\x2c\x4b\x49\x55\xa5\x76\xf5\xae\xc5\xef\x03\x09\x54\x74\x93\x98\x92\x19\x3d\xd3\x9d\x7f\x87\x31\x18\xcf\xde\x55\x7e\x4e\x05\x9b\x0a\x1f\x4a\x7b\x88\x85\xf2\x51\x1b\xaa\xaf\x6a\xfd\x2f\x8c\xec\x08\x42\xd4\x44\x84\x5c\x9e\x8b\x98\x9a\xef\x0e\xb5\x05\x8d\x91\x4a\x24\xff\x4f\x45\xd9\x94\x3d\x5d\x30\x8b\xc6\x36\x28\xba\x94\xa7\xce\xba\x63\x22\xc7\x6b\xaa\x8f\xae\x29\x69\x24\x1e\x90\xcb\x1a\x35\x07\x62\x46\xf0\x45\x69\x74\x9d\x78\xe2\x5a\x92\x99\x8c\xc7\x09\xb7\x65\x31\x8b\x54\x9a\xe6\x92\xdb\xe7\x71\x6d\x1a\x30\xe3\x18\x77\x28\xc6\x86\x27\x43\xa6\xa3\x2d\xb7\x18\xd9\x5c\xe3\x98\x65\x7c\xe8\x04\x97\xbe\x88\xa5\xf1\xa0\x8a\xbb\x0f\x35\x49\x8f\xf2\xb8\x4a\x9c\x5e\xbb\x53\xf2\x90\x87\x59\x81\xe6\xe5\x3f\x98\x97\x5e\x91\x55\x96\x37\xe1\x0a\x4a\xa6\xce\x05\x4d\x9b\x3b\x6b\x1f\xd0\xcc\xc1\xf0\x64\x28\x2e\x37\xae\x7d\x50\xff\xd7\x2a\x75\x14\x51\xc6\x99\xe2\xd2\xba\x1f\x91\xe0\x28\x9b\x46\x37\xf9\x3a\xe5\xd6\xb7\x66\x34\x96\xfc\x33\x82\x19\x93\x34\x4d\xac\x11\xf2\x2c\x66\x16\xe3\x11\xcc\x25\xcc\xa8\x72\xcc\x18\x0d\x0c\x3f\xd8\xec\x64\x61\x33\x24\x93\xbe\x6c\xf8\x7a\x27\x6a\x02\x7a\x6b\x55\xaf\xcb\x2e\xd3\xe9\xa1\x5a\x26\x86\x19\x46\x8d\xec\x88\xd1\xb8\xa1\x85\xd2\x1d\x29\xee\xdb\xe5\xb1\x3f\x27\xe9\x89\x94\xdc\xf0\x24\xd7\xb5\xda\x50\x8b\x79\x8b\xa9\x69\xbf\x6c\xc9\x36\xab\x13\x70\xd2\x0d\x87\x47\x18\x7d\xdc\x6b\x06\xe9\x78\xdf\x63\xd3\xc3\xe3\xe2\xf4\x02\xcc\x72\xd2\xeb\x42\x1d\x3a\xd4\xce\x03\xc7\xee\xe8\xa4\xd3\x9d\xf5\x23\xa6\x35\x7b\x6e\x9c\xc4\x98\xa1\x8c\x51\x46\x1d\x06\xe9\xb1\xf9\x09\x7d\xfa\xb8\x6c\x84\xda\x9f\x4b\xbe\xe1\xd2\x5b\xa1\xf6\xae\x1e\x48\xc8\xa5\xb1\x3a\x77\xa9\x10\x1f\x25\x38\xd5\x05\xe6\x13\xcf\xe1\x74\x18\x8d\x4b\xf8\x36\xfd\x72\x37\xa6\x51\x02\x3e\x85\x77\xdf\x43\xaf\x47\x6e\xdb\x0a\xf4\x52\xc9\xb4\xa2\xcb\x46\x1b\xbe\x39\xb8\x68\xc6\xed\x83\x07\xac\x55\x2f\x37\x57\x18\xd7\x6c\x08\x80\xb2\x8d\x59\xa0\x1b\x1e\x4a\xba\x18\xc4\x47\xba\x1c\x8d\xd8\x5c\x1a\xcb\x84\x70\xa9\x31\xe6\x9d\x79\x79\x52\xfa\xb2\x9f\xb7\xc5\xf7\x57\x3b\x37\x9d\xfc\xfa\x4b\x27\xb1\xc3\x60\xd5\xa0\xa6\x0c\xb7\x4a\xff\xd0\xa8\x6b\x0d\x43\x2f\xb2\x68\xb8\xa2\x9c\xe5\x2f\xab\x23\x74\x8f\xa4\x9b\x50\x47\x25\xab\xcb\xbc\x56\x4a\x20\x6b\x3b\xc1\x13\x90\x16\xe5\x51\x74\xbd\x68\x8b\x1a\xee\x67\x7c\x7e\x0b\xfa\x12\x37\x17\xa1\xa7\x2a\x97\xd6\x0d\x83\x97\x60\xbb\x09\xfd\x12\xc4\xfe\xca\xdd\xe9\xd6\xd5\x73\x86\x5d\x6e\x7d\x91\xd3\x05\x35\xd6\xa0\xde\xf1\x08\xa7\x51\x44\xa6\x59\x74\x68\xd8\xcb\xf1\x0d\x01\x1c\xbe\x87\xef\x25\xe8\x6e\xb8\x8e\x30\xa3\x49\xec\x8c\x78\x9a\xd7\xc0\x5d\x45\x56\x59\xb9\xf6\x8a\xa9\x2f\x6d\x38\x0d\x9d\x54\x8a\x95\x4e\xca\xdb\xa4\xbf\x5a\x3e\x8e\x96\x2a\xb7\x68\xee\x14\x8b\x5b\xf5\xf1\xf0\xe4\x6e\x07\xa6\x20\xd3\x38\xce\x94\xb1\xe4\xb8\x08\x8d\x29\x23\xa3\x13\xad\x27\x3c\xce\xd2\xbf\x3f\x8c\xfd\x53\xee\x6a\xce\xb0\xcd\x5d\xb9\xd6\xb9\x24\xcf\x00\x84\xb3\xcb\x39\x7c\x1c\x60\x31\x26\xd4\xec\x5f\xee\xe5\x2e\xb3\xbc\xeb\xb1\x7b\x2e\x84\x0f\x89\x4c\xa3\xf5\x57\x86\xe2\xd2\xc1\x2c\xe8\x5c\x5a\x9e\x76\x4d\x68\x3f\xaa\xce\x5d\x50\x7d\xfc\xc8\xd0\xe6\x55\x5f\x21\xf5\x57\x82\x86\x99\xa7\x7e\x3c\x71\x15\x85\x92\x8c\x71\xe9\x23\xbb\x31\xb8\xbb\xfb\xae\x67\xfa\xea\xa2\x73\x62\xfe\x7f\x8d\xd4\x67\xd8\xf1\x05\x5b\x9e\x61\xe8\xa3\xa3\xee\xbb\x94\xdf\x7c\x9c\x73\x9b\x72\x90\x8d\xfb\x94\x5a\x53\xe7\x78\xc3\x85\x8a\x65\x6c\xcd\x05\xef\xb2\xd2\xf7\x9b\xb2\x22\x25\xbd\x53\x2e\xea\x52\x35\x8d\x66\x25\xa1\x02\x62\x5d\x98\xa1\xd2\x9e\x55\x13\x5d\x87\x3f\x69\x20\x86\x08\xb5\xdb\xcb\xbb\x9b\xfc\xe8\x95\xf1\x27\x98\xb1\x2b\xcd\xa4\x71\x42\xac\x78\x5f\x82\xb6\x6a\x9c\xb1\x40\x45\xa0\xcc\x84\x42\x05\x5b\x11\xc2\xd8\x2f\x19\x94\xc4\x22\x1c\xfa\x02\x56\x01\x93\xca\x6e\x51\x1f\x4b\x0e\xb5\x51\x3b\x66\x16\x87\x97\xd6\x1d\x52\xf2\xab\xdb\x55\x9c\xa9\xe0\xca\xed\xa0\x0e\x4a\x72\x53\xd3\x72\xcf\x4c\xb5\xf9\xf8\x71\x32\xa7\x68\xcc\x79\x1d\x67\x0a\xdb\x3c\x65\x12\x34\xb2\xd8\x7d\x31\x29\x50\x81\xcb\x98\x47\xcc\x5d\x13\x63\xb4\x8c\x0b\x03\x6c\xad\xf2\xe3\xbc\x2f\x04\xda\x62\xcd\x83\xdd\xaa\xbd\x20\xb4\x46\x66\xfa\xca\xd8\x91\x81\x3d\x70\x75\x6b\xab\x0c\xfc\xc1\x14\xb6\x7f\x9b\x2c\xc7\x55\xa8\x47\x96\xa2\x08\x15\x7d\xb3\x12\xe3\xda\x7f\x32\xdc\xc0\x4a\xe7\x78\x0d\xb7\x4c\x18\xbc\x86\xaf\xf2\x51\xaa\xfd\x65\x12\x9d\x39\xad\xbb\x29\x5d\x6d\x1a\xdf\x0d\x2a\xa9\x2e\x60\x7c\x7a\xdb\xd2\x9b\x9d\x3d\x8b\x98\x0b\x9a\xf1\xfb\x8e\xab\xf5\xfc\x79\x76\x5c\x31\x4f\xd0\x9c\xbf\x0e\xda\x30\x2e\x72\x7d\x7a\x1d\x74\xeb\x61\x8e\x5d\x7c\xca\xc1\xfd\x85\xe7\x05\x27\x45\x6a\x87\xba\xf3\xce\xd5\x25\xd4\xb2\x80\xef\x1e\xee\x4f\x47\x20\x75\x6b\x8b\x69\xd6\x73\x3f\x3c\xb5\x39\x6a\x11\xf8\xc2\x9e\xde\x4c\xa3\xbf\x11\x9e\xdb\xbf\xce\x68\x06\xfd\x19\x40\xa1\x5e\x48\x72\xfa\xf4\x0b\x7b\xea\x75\x6a\xdf\x14\xdb\xa3\xda\x39\x6a\x9d\x50\xa9\x5f\x9d\x61\x11\x7e\x9d\x07\x3e\x60\x3a\x8e\x3a\x24\xe8\x55\x2b\x41\x89\x9a\x06\x8e\xe5\xfb\x76\xef\x0f\x58\x8f\xbc\x6f\xf7\xda\x75\xbf\x0a\xc8\xf0\x7d\x57\x77\x21\xfa\xfb\xae\xee\x6d\x3b\x8c\xf7\x5d\xdd\x9f\x64\x57\xc7\xd3\x0e\x6f\xf5\x32\x79\xd5\xd7\xc7\x2d\x33\xa7\x87\xcd\xda\x26\xc6\xfd\xe5\xeb\x38\x12\xfa\x89\x0b\x66\x69\xa4\x78\xff\x16\x7a\xc9\xb7\x50\x1f\x98\x0f\x5a\xed\x78\x47\x0e\x35\xfb\x5b\x13\xf6\x15\x2e\x2a\xb8\x74\xfc\xf1\xe9\x24\x5a\xf9\xc7\xb0\xb3\x11\x76\xaf\x62\xd0\x91\x22\xad\x57\x25\x3d\xd8\x7d\x3c\xfc\xaa\xfe\xe8\xe8\xff\xcf\xe7\x8e\xa0\xf8\xd0\x86\xf1\x04\xac\xae\x2e\x8e\xc6\x2a\x4d\x39\xe5\xdf\xfd\x3f\x00\x00\xff\xff\xd4\x20\x19\xbf\x81\x2d\x00\x00"),
 		},
 		"/operator-deployment.yaml": &vfsgen۰CompressedFileInfo{
 			name:             "operator-deployment.yaml",
diff --git a/docs/modules/ROOT/pages/observability/monitoring.adoc b/docs/modules/ROOT/pages/observability/monitoring.adoc
index cb582a9ee..a3d7bf244 100644
--- a/docs/modules/ROOT/pages/observability/monitoring.adoc
+++ b/docs/modules/ROOT/pages/observability/monitoring.adoc
@@ -8,14 +8,14 @@ The https://github.com/coreos/prometheus-operator[Prometheus Operator] serves to
 [[prerequisites]]
 == Prerequisites
 
-To take fully advantage of the Camel K monitoring capabilities, it is recommended to have a Prometheus operator instance, that can be configured to integrate Camel K integrations.
+To take fully advantage of the Camel K monitoring capabilities, it is recommended to have a Prometheus Operator instance, that can be configured to integrate Camel K integrations.
 
 [[kubernetes]]
 === Kubernetes
 
 You can deploy the Prometheus operator by running:
 
-```
+```sh
 $ kubectl apply -f https://raw.githubusercontent.com/coreos/prometheus-operator/v0.38.0/bundle.yaml
 ```
 
@@ -23,7 +23,7 @@ WARNING: Beware this installs the operator in the `default` namespace. You must
 
 Then, you can create a `Prometheus` resource, that the operator will use as configuration to deploy a managed Prometheus instance:
 
-```
+```sh
 $ cat <<EOF | kubectl apply -f -
 apiVersion: monitoring.coreos.com/v1
 kind: Prometheus
@@ -44,7 +44,7 @@ You may also need to specify a ServiceAccount with the `serviceAccountName` fiel
 [[openshift]]
 === OpenShift
 
-Starting OpenShift 4.3, the Prometheus operator, that's already deployed as part of the monitoring stack, can be used to https://docs.openshift.com/container-platform/4.3/monitoring/monitoring-your-own-services.html[monitor application services].
+Starting OpenShift 4.3, the Prometheus Operator, that's already deployed as part of the monitoring stack, can be used to https://docs.openshift.com/container-platform/4.3/monitoring/monitoring-your-own-services.html[monitor application services].
 This needs to be enabled by following these instructions:
 
 . Check whether the `cluster-monitoring-config` ConfigMap object exists in the `openshift-monitoring` project:
@@ -74,43 +74,43 @@ data:
       enabled: true
 ----
 
-On OpenShift versions prior to 4.3, or if you do not want to change your cluster monitoring stack configuration, you can refer to the <<Kubernetes>> section in order to deploy a separate Prometheus operator instance.
+On OpenShift versions prior to 4.3, or if you do not want to change your cluster monitoring stack configuration, you can refer to the <<Kubernetes>> section in order to deploy a separate Prometheus Operator instance.
 
 [[instrumentation]]
 == Instrumentation
 
-The Prometheus trait automates the configuration of integration pods to expose a _metrics_ endpoint, that can be discovered and scrapped by a Prometheus server.
+The xref:traits/pages/prometheus.adoc[Prometheus trait] automates the configuration of integration pods to expose a _metrics_ endpoint, that can be discovered and scrapped by a Prometheus server.
 
 The Prometheus trait can be enabled when running an integration, e.g.:
 
-```
+```sh
 $ kamel run -t prometheus.enabled=true ...
 ```
 
 Alternatively, the Prometheus trait can be enabled globally once, by updating the integration platform, e.g.:
 
-```
+```sh
 $ kubectl patch ip camel-k --type=merge -p '{"spec":{"traits":{"prometheus":{"configuration":{"enabled":"true"}}}}}'
 ```
 
 The underlying instrumentation mechanism depends on the configured integration runtime.
 As a result, the set of registered metrics, as well as the naming convention they follow, also depends on it.
 
-=== Default Runtime
+=== Main
 
 When the default, a.k.a. _main_, runtime is configured for the integration, the https://github.com/prometheus/jmx_exporter[JMX exporter] is responsible for collecting and exposing metrics from JMX mBeans.
 
 A custom configuration for the JMX exporter can be used by setting the `prometheus.configmap` parameter from the Prometheus trait with the name of a ConfigMap containing a `prometheus-jmx-exporter.yaml` key, e.g.:
 
-```
+```sh
 $ kamel run -t prometheus.enabled=true -t prometheus.configmap=<jmx_exporter_config>...
 ```
 
 Otherwise, the Prometheus trait uses a default configuration.
 
-=== Quarkus Runtime
+=== Quarkus
 
-When the Quarkus runtime is configured for the integration, the https://camel.apache.org/camel-quarkus/latest/extensions/microprofile-metrics.html[Camel Quarkus MicroProfile Metrics extension] is responsible for collection and exposing metrics in the https://github.com/OpenObservability/OpenMetrics[OpenMetrics] text format.
+When the Quarkus runtime is configured for the integration, the https://camel.apache.org/camel-quarkus/latest/extensions/microprofile-metrics.html[Camel Quarkus MicroProfile Metrics extension] is responsible for collecting and exposing metrics in the https://github.com/OpenObservability/OpenMetrics[OpenMetrics] text format.
 
 The MicroProfile Metrics extension registers and exposes the following metrics out-of-the-box:
 
@@ -123,3 +123,85 @@ It is possible to extend this set of metrics by using either, or both:
 * The https://camel.apache.org/components/latest/microprofile-metrics-component.html[MicroProfile Metrics component]
 
 * The https://github.com/eclipse/microprofile-metrics/blob/master/spec/src/main/asciidoc/app-programming-model.adoc#annotations[MicroProfile Metrics annotations], in external dependencies
+
+=== Discovery
+
+The Prometheus trait automatically configures the resources necessary for the Prometheus Operator to reconcile, so that the managed Prometheus instance can scrape the integration _metrics_ endpoint.
+
+By default, the Prometheus trait creates a `ServiceMonitor` resource, with the `camel.apache.org/integration` label, which must match the `serviceMonitorSelector` field from the `Prometheus` resource.
+Additional labels can be specified with the `service-monitor-labels` parameter from the Prometheus trait, e.g.:
+
+```sh
+$ kamel run -t prometheus.service-monitor-labels="label_to_be_match_by=prometheus_selector" ...
+```
+
+The creation of the `ServiceMonitor` resource can be disabled using the `service-monitor` parameter, e.g.:
+
+```sh
+$ kamel run -t prometheus.service-monitor=false ...
+```
+
+More information can be found in the xref:traits/pages/prometheus.adoc[Prometheus trait] documentation.
+
+The Prometheus Operator https://github.com/coreos/prometheus-operator/blob/v0.38.0/Documentation/user-guides/getting-started.md#related-resources[getting started] guide documents the discovery mechanism, as well as the relationship between the operator resources.
+
+In case your integration metrics are not discovered, you may want to rely on https://github.com/coreos/prometheus-operator/blob/v0.38.0/Documentation/troubleshooting.md#troubleshooting-servicemonitor-changes[Troubleshooting `ServiceMonitor` changes].
+
+=== Alerting
+
+The Prometheus Operator declares the `AlertManager` resource that can be used to configure _Alertmanager_ instances, along with `Prometheus` instances.
+
+Assuming an `AlertManager` resource already exists in your cluster, you can register a `PrometheusRule` resource that is used by Prometheus to trigger alerts, e.g.:
+
+```sh
+$ cat <<EOF | kubectl apply -f -
+apiVersion: monitoring.coreos.com/v1
+kind: PrometheusRule
+metadata:
+  labels:
+    prometheus: example
+    role: alert-rules
+  name: prometheus-rules
+spec:
+  groups:
+  - name: camel-k.rules
+    rules:
+    - alert: CamelKAlert
+      expr: application_camel_context_exchanges_failed_total > 0
+EOF
+```
+
+More information can be found in the Prometheus Operator https://github.com/coreos/prometheus-operator/blob/v0.38.0/Documentation/user-guides/alerting.md[Alerting] user guide. You can also find more details in https://docs.openshift.com/container-platform/4.4/monitoring/monitoring-your-own-services.html#creating-alerting-rules_monitoring-your-own-services[Creating alerting rules] from the OpenShift documentation.
+
+=== Autoscaling
+
+Integration metrics can be exported for horizontal pod autoscaling (HPA), using the https://github.com/DirectXMan12/k8s-prometheus-adapter[custom metrics Prometheus adapter].
+If you have an OpenShift cluster, you can follow https://docs.openshift.com/container-platform/4.4/monitoring/exposing-custom-application-metrics-for-autoscaling.html[Exposing custom application metrics for autoscaling] to set it up.
+
+Assuming you have the Prometheus adapter up and running, you can create a `HorizontalPodAutoscaler` resource, e.g.:
+
+```sh
+$ cat <<EOF | kubectl apply -f -
+apiVersion: autoscaling/v2beta2
+kind: HorizontalPodAutoscaler
+metadata:
+  name: camel-k-autoscaler
+spec:
+  scaleTargetRef:
+    apiVersion: camel.apache.org/v1
+    kind: Integration
+    name: example
+  minReplicas: 1
+  maxReplicas: 10
+  metrics:
+  - type: Pods
+    pods:
+      metric:
+        name: application_camel_context_exchanges_inflight_count
+      target:
+        type: AverageValue
+        averageValue: 1k
+EOF
+```
+
+More information can be found in https://kubernetes.io/docs/tasks/run-application/horizontal-pod-autoscale/[Horizontal Pod Autoscaler] from the Kubernetes documentation.
diff --git a/helm/camel-k/crds/crd-integration.yaml b/helm/camel-k/crds/crd-integration.yaml
index 18d0e57f9..0366bde43 100644
--- a/helm/camel-k/crds/crd-integration.yaml
+++ b/helm/camel-k/crds/crd-integration.yaml
@@ -46,6 +46,7 @@ spec:
   scope: Namespaced
   subresources:
     scale:
+      labelSelectorPath: .status.selector
       specReplicasPath: .spec.replicas
       statusReplicasPath: .status.replicas
     status: {}
@@ -323,6 +324,8 @@ spec:
               type: string
             runtimeVersion:
               type: string
+            selector:
+              type: string
             version:
               type: string
           type: object
diff --git a/pkg/apis/camel/v1/integration_types.go b/pkg/apis/camel/v1/integration_types.go
index d32acba9e..9596eb25c 100644
--- a/pkg/apis/camel/v1/integration_types.go
+++ b/pkg/apis/camel/v1/integration_types.go
@@ -57,6 +57,7 @@ type IntegrationStatus struct {
 	Conditions         []IntegrationCondition `json:"conditions,omitempty"`
 	Version            string                 `json:"version,omitempty"`
 	Replicas           *int32                 `json:"replicas,omitempty"`
+	Selector           string                 `json:"selector,omitempty"`
 	Capabilities       []string               `json:"capabilities,omitempty"`
 }
 
@@ -65,7 +66,7 @@ type IntegrationStatus struct {
 // +genclient
 // +kubebuilder:resource:path=integrations,scope=Namespaced,shortName=it
 // +kubebuilder:subresource:status
-// +kubebuilder:subresource:scale:specpath=.spec.replicas,statuspath=.status.replicas
+// +kubebuilder:subresource:scale:specpath=.spec.replicas,statuspath=.status.replicas,selectorpath=.status.selector
 // +kubebuilder:printcolumn:name="Phase",type=string,JSONPath=`.status.phase`,description="The integration phase"
 // +kubebuilder:printcolumn:name="Kit",type=string,JSONPath=`.status.kit`,description="The integration kit"
 // +kubebuilder:printcolumn:name="Replicas",type=integer,JSONPath=`.status.replicas`,description="The number of pods"
diff --git a/pkg/apis/camel/v1/integration_types_support.go b/pkg/apis/camel/v1/integration_types_support.go
index d16394ca2..dd848f0be 100644
--- a/pkg/apis/camel/v1/integration_types_support.go
+++ b/pkg/apis/camel/v1/integration_types_support.go
@@ -25,6 +25,8 @@ import (
 	metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
 )
 
+const IntegrationLabel = "camel.apache.org/integration"
+
 // NewIntegration --
 func NewIntegration(namespace string, name string) Integration {
 	return Integration{
diff --git a/pkg/controller/integration/integration_controller.go b/pkg/controller/integration/integration_controller.go
index 96f4e1e00..8170a37b8 100644
--- a/pkg/controller/integration/integration_controller.go
+++ b/pkg/controller/integration/integration_controller.go
@@ -175,7 +175,7 @@ func add(mgr manager.Manager, r reconcile.Reconciler) error {
 			var requests []reconcile.Request
 
 			labels := rs.GetLabels()
-			integrationName, ok := labels["camel.apache.org/integration"]
+			integrationName, ok := labels[v1.IntegrationLabel]
 			if ok {
 				requests = append(requests, reconcile.Request{
 					NamespacedName: types.NamespacedName{
diff --git a/pkg/controller/integration/monitor.go b/pkg/controller/integration/monitor.go
index 4cea23e0f..2b55f59b3 100644
--- a/pkg/controller/integration/monitor.go
+++ b/pkg/controller/integration/monitor.go
@@ -58,7 +58,7 @@ func (action *monitorAction) Handle(ctx context.Context, integration *v1.Integra
 
 		integration.Status.Digest = hash
 		integration.Status.Phase = v1.IntegrationPhaseInitialization
-		if integration.Spec.Profile != v1.TraitProfile("") {
+		if integration.Spec.Profile != "" {
 			integration.Status.Profile = integration.Spec.Profile
 		}
 		integration.Status.Version = defaults.Version
@@ -72,12 +72,16 @@ func (action *monitorAction) Handle(ctx context.Context, integration *v1.Integra
 		return nil, err
 	}
 
+	// Enforce the scale sub-resource label selector
+	// It is used by the HPA that queries the scale sub-resource endpoint to list the pods owned by the integration
+	integration.Status.Selector = v1.IntegrationLabel + "=" + integration.Name
+
 	// Check replicas
 	replicaSets := &appsv1.ReplicaSetList{}
 	err = action.client.List(ctx, replicaSets,
 		k8sclient.InNamespace(integration.Namespace),
 		k8sclient.MatchingLabels{
-			"camel.apache.org/integration": integration.Name,
+			v1.IntegrationLabel: integration.Name,
 		})
 	if err != nil {
 		return nil, err
diff --git a/pkg/trait/affinity.go b/pkg/trait/affinity.go
index 3ab91b38b..5c65a4ada 100644
--- a/pkg/trait/affinity.go
+++ b/pkg/trait/affinity.go
@@ -162,7 +162,7 @@ func (t *affinityTrait) addPodAffinity(e *Environment, deployment *appsv1.Deploy
 
 	if t.PodAffinity {
 		labelSelectorRequirements = append(labelSelectorRequirements, metav1.LabelSelectorRequirement{
-			Key:      "camel.apache.org/integration",
+			Key:      v1.IntegrationLabel,
 			Operator: metav1.LabelSelectorOpIn,
 			Values: []string{
 				e.Integration.Name,
@@ -218,7 +218,7 @@ func (t *affinityTrait) addPodAntiAffinity(e *Environment, deployment *appsv1.De
 
 	if t.PodAntiAffinity {
 		labelSelectorRequirements = append(labelSelectorRequirements, metav1.LabelSelectorRequirement{
-			Key:      "camel.apache.org/integration",
+			Key:      v1.IntegrationLabel,
 			Operator: metav1.LabelSelectorOpIn,
 			Values: []string{
 				e.Integration.Name,
diff --git a/pkg/trait/cron.go b/pkg/trait/cron.go
index 3f740b1d6..fd7f26471 100644
--- a/pkg/trait/cron.go
+++ b/pkg/trait/cron.go
@@ -258,7 +258,7 @@ func (t *cronTrait) Apply(e *Environment) error {
 
 func (t *cronTrait) getCronJobFor(e *Environment) *v1beta1.CronJob {
 	labels := map[string]string{
-		"camel.apache.org/integration": e.Integration.Name,
+		v1.IntegrationLabel: e.Integration.Name,
 	}
 
 	annotations := make(map[string]string)
diff --git a/pkg/trait/deployment.go b/pkg/trait/deployment.go
index a56ec0688..f7a048b5f 100644
--- a/pkg/trait/deployment.go
+++ b/pkg/trait/deployment.go
@@ -155,7 +155,7 @@ func (t *deploymentTrait) getDeploymentFor(e *Environment) *appsv1.Deployment {
 			Name:      e.Integration.Name,
 			Namespace: e.Integration.Namespace,
 			Labels: map[string]string{
-				"camel.apache.org/integration": e.Integration.Name,
+				v1.IntegrationLabel: e.Integration.Name,
 			},
 			Annotations: annotations,
 		},
@@ -163,13 +163,13 @@ func (t *deploymentTrait) getDeploymentFor(e *Environment) *appsv1.Deployment {
 			Replicas: e.Integration.Spec.Replicas,
 			Selector: &metav1.LabelSelector{
 				MatchLabels: map[string]string{
-					"camel.apache.org/integration": e.Integration.Name,
+					v1.IntegrationLabel: e.Integration.Name,
 				},
 			},
 			Template: corev1.PodTemplateSpec{
 				ObjectMeta: metav1.ObjectMeta{
 					Labels: map[string]string{
-						"camel.apache.org/integration": e.Integration.Name,
+						v1.IntegrationLabel: e.Integration.Name,
 					},
 					Annotations: annotations,
 				},
diff --git a/pkg/trait/gc.go b/pkg/trait/gc.go
index 5823b1304..bcd3e43ca 100644
--- a/pkg/trait/gc.go
+++ b/pkg/trait/gc.go
@@ -114,7 +114,7 @@ func (t *garbageCollectorTrait) Apply(e *Environment) error {
 				// Label the resource with the current integration generation
 				labels["camel.apache.org/generation"] = generation
 				// Make sure the integration label is set
-				labels["camel.apache.org/integration"] = env.Integration.Name
+				labels[v1.IntegrationLabel] = env.Integration.Name
 				resource.SetLabels(labels)
 			})
 			return nil
@@ -125,7 +125,7 @@ func (t *garbageCollectorTrait) Apply(e *Environment) error {
 }
 
 func (t *garbageCollectorTrait) garbageCollectResources(e *Environment) {
-	integration, _ := labels.NewRequirement("camel.apache.org/integration", selection.Equals, []string{e.Integration.Name})
+	integration, _ := labels.NewRequirement(v1.IntegrationLabel, selection.Equals, []string{e.Integration.Name})
 	generation, err := labels.NewRequirement("camel.apache.org/generation", selection.LessThan, []string{strconv.FormatInt(e.Integration.GetGeneration(), 10)})
 	if err != nil {
 		t.L.ForIntegration(e.Integration).Errorf(err, "cannot determine generation requirement")
diff --git a/pkg/trait/knative_service.go b/pkg/trait/knative_service.go
index bea151337..ed84f5d68 100644
--- a/pkg/trait/knative_service.go
+++ b/pkg/trait/knative_service.go
@@ -262,7 +262,7 @@ func (t *knativeServiceTrait) ControllerStrategySelectorOrder() int {
 
 func (t *knativeServiceTrait) getServiceFor(e *Environment) *serving.Service {
 	labels := map[string]string{
-		"camel.apache.org/integration": e.Integration.Name,
+		v1.IntegrationLabel: e.Integration.Name,
 	}
 
 	annotations := make(map[string]string)
diff --git a/pkg/trait/openapi.go b/pkg/trait/openapi.go
index 43895d47a..99d94bc0e 100644
--- a/pkg/trait/openapi.go
+++ b/pkg/trait/openapi.go
@@ -257,7 +257,7 @@ func (t *openAPITrait) createNewOpenAPIConfigMap(e *Environment, resource v1.Res
 			Name:      generatedContentName,
 			Namespace: e.Integration.Namespace,
 			Labels: map[string]string{
-				"camel.apache.org/integration": e.Integration.Name,
+				v1.IntegrationLabel: e.Integration.Name,
 			},
 			Annotations: map[string]string{
 				"camel.apache.org/source.language":    string(v1.LanguageXML),
diff --git a/pkg/trait/prometheus.go b/pkg/trait/prometheus.go
index cffb4f4d7..ecee2a23b 100644
--- a/pkg/trait/prometheus.go
+++ b/pkg/trait/prometheus.go
@@ -222,7 +222,7 @@ func (t *prometheusTrait) getServiceMonitorFor(e *Environment) (*monitoringv1.Se
 	if err != nil {
 		return nil, err
 	}
-	labels["camel.apache.org/integration"] = e.Integration.Name
+	labels[v1.IntegrationLabel] = e.Integration.Name
 
 	smt := monitoringv1.ServiceMonitor{
 		TypeMeta: metav1.TypeMeta{
@@ -237,7 +237,7 @@ func (t *prometheusTrait) getServiceMonitorFor(e *Environment) (*monitoringv1.Se
 		Spec: monitoringv1.ServiceMonitorSpec{
 			Selector: metav1.LabelSelector{
 				MatchLabels: map[string]string{
-					"camel.apache.org/integration": e.Integration.Name,
+					v1.IntegrationLabel: e.Integration.Name,
 				},
 			},
 			Endpoints: []monitoringv1.Endpoint{
@@ -266,7 +266,7 @@ func (t *prometheusTrait) getJmxExporterConfigMapOrAdd(e *Environment) string {
 			Name:      defaultName,
 			Namespace: e.Integration.Namespace,
 			Labels: map[string]string{
-				"camel.apache.org/integration": e.Integration.Name,
+				v1.IntegrationLabel: e.Integration.Name,
 			},
 		},
 		Data: map[string]string{
diff --git a/pkg/trait/route.go b/pkg/trait/route.go
index 7a866b53a..996282366 100644
--- a/pkg/trait/route.go
+++ b/pkg/trait/route.go
@@ -127,7 +127,7 @@ func (t *routeTrait) Apply(e *Environment) error {
 			Name:      t.service.Name,
 			Namespace: t.service.Namespace,
 			Labels: map[string]string{
-				"camel.apache.org/integration": e.Integration.Name,
+				v1.IntegrationLabel: e.Integration.Name,
 			},
 		},
 		Spec: routev1.RouteSpec{
diff --git a/pkg/trait/service.go b/pkg/trait/service.go
index 8f31e3d94..30e3cf82e 100644
--- a/pkg/trait/service.go
+++ b/pkg/trait/service.go
@@ -135,13 +135,13 @@ func getServiceFor(e *Environment) *corev1.Service {
 			Name:      e.Integration.Name,
 			Namespace: e.Integration.Namespace,
 			Labels: map[string]string{
-				"camel.apache.org/integration": e.Integration.Name,
+				v1.IntegrationLabel: e.Integration.Name,
 			},
 		},
 		Spec: corev1.ServiceSpec{
 			Ports: []corev1.ServicePort{},
 			Selector: map[string]string{
-				"camel.apache.org/integration": e.Integration.Name,
+				v1.IntegrationLabel: e.Integration.Name,
 			},
 		},
 	}
diff --git a/pkg/trait/trait_types.go b/pkg/trait/trait_types.go
index 6352c7a77..eeeedd56e 100644
--- a/pkg/trait/trait_types.go
+++ b/pkg/trait/trait_types.go
@@ -355,7 +355,7 @@ func (e *Environment) ComputeApplicationProperties() *corev1.ConfigMap {
 				Name:      e.Integration.Name + "-application-properties",
 				Namespace: e.Integration.Namespace,
 				Labels: map[string]string{
-					"camel.apache.org/integration":     e.Integration.Name,
+					v1.IntegrationLabel:                e.Integration.Name,
 					"camel.apache.org/properties.type": "application",
 				},
 			},
@@ -393,7 +393,7 @@ func (e *Environment) ComputeConfigMaps() []runtime.Object {
 					Name:      e.Integration.Name + "-user-properties",
 					Namespace: e.Integration.Namespace,
 					Labels: map[string]string{
-						"camel.apache.org/integration":     e.Integration.Name,
+						v1.IntegrationLabel:                e.Integration.Name,
 						"camel.apache.org/properties.type": "user",
 					},
 				},
@@ -418,7 +418,7 @@ func (e *Environment) ComputeConfigMaps() []runtime.Object {
 				Name:      fmt.Sprintf("%s-source-%03d", e.Integration.Name, i),
 				Namespace: e.Integration.Namespace,
 				Labels: map[string]string{
-					"camel.apache.org/integration": e.Integration.Name,
+					v1.IntegrationLabel: e.Integration.Name,
 				},
 				Annotations: map[string]string{
 					"camel.apache.org/source.language":    string(s.InferLanguage()),
diff --git a/pkg/util/kubernetes/collection.go b/pkg/util/kubernetes/collection.go
index d4b6140e7..bbfb5d244 100644
--- a/pkg/util/kubernetes/collection.go
+++ b/pkg/util/kubernetes/collection.go
@@ -124,7 +124,7 @@ func (c *Collection) GetDeploymentForIntegration(integration *v1.Integration) *a
 	}
 
 	return c.GetDeployment(func(d *appsv1.Deployment) bool {
-		return d.ObjectMeta.Labels["camel.apache.org/integration"] == integration.Name
+		return d.ObjectMeta.Labels[v1.IntegrationLabel] == integration.Name
 	})
 }
 
@@ -208,7 +208,7 @@ func (c *Collection) GetUserServiceForIntegration(integration *v1.Integration) *
 	}
 	return c.GetService(func(s *corev1.Service) bool {
 		return s.ObjectMeta.Labels != nil &&
-			s.ObjectMeta.Labels["camel.apache.org/integration"] == integration.Name &&
+			s.ObjectMeta.Labels[v1.IntegrationLabel] == integration.Name &&
 			s.ObjectMeta.Labels["camel.apache.org/service.type"] == v1.ServiceTypeUser
 	})
 }
@@ -219,7 +219,7 @@ func (c *Collection) GetServiceForIntegration(integration *v1.Integration) *core
 		return nil
 	}
 	return c.GetService(func(s *corev1.Service) bool {
-		return s.ObjectMeta.Labels != nil && s.ObjectMeta.Labels["camel.apache.org/integration"] == integration.Name
+		return s.ObjectMeta.Labels != nil && s.ObjectMeta.Labels[v1.IntegrationLabel] == integration.Name
 	})
 }
 
diff --git a/pkg/util/kubernetes/conditions.go b/pkg/util/kubernetes/conditions.go
index bb8e3c43a..88e5465df 100644
--- a/pkg/util/kubernetes/conditions.go
+++ b/pkg/util/kubernetes/conditions.go
@@ -50,7 +50,7 @@ func MirrorReadyCondition(ctx context.Context, c client.Client, it *v1.Integrati
 func mirrorReadyConditionFromReplicaSet(ctx context.Context, c client.Client, it *v1.Integration) {
 	list := appsv1.ReplicaSetList{}
 	opts := runtimeclient.MatchingLabels{
-		"camel.apache.org/integration": it.Name,
+		v1.IntegrationLabel: it.Name,
 	}
 	if err := c.List(ctx, &list, opts, runtimeclient.InNamespace(it.Namespace)); err != nil {
 		setReadyConditionError(it, err)
diff --git a/pkg/util/kubernetes/log/util.go b/pkg/util/kubernetes/log/util.go
index bd72a9402..5539d1325 100644
--- a/pkg/util/kubernetes/log/util.go
+++ b/pkg/util/kubernetes/log/util.go
@@ -30,7 +30,7 @@ import (
 
 // Print prints integrations logs to the stdout
 func Print(ctx context.Context, client kubernetes.Interface, integration *v1.Integration, out io.Writer) error {
-	scraper := NewSelectorScraper(client, integration.Namespace, integration.Name, "camel.apache.org/integration="+integration.Name)
+	scraper := NewSelectorScraper(client, integration.Namespace, integration.Name, v1.IntegrationLabel+"="+integration.Name)
 	reader := scraper.Start(ctx)
 
 	if _, err := io.Copy(out, ioutil.NopCloser(reader)); err != nil {


Test patch:
diff --git a/addons/threescale/3scale_test.go b/addons/threescale/3scale_test.go
index ccdd126e5..149a4e8da 100644
--- a/addons/threescale/3scale_test.go
+++ b/addons/threescale/3scale_test.go
@@ -95,7 +95,7 @@ func createEnvironment(t *testing.T) (*corev1.Service, *trait.Environment) {
 	svc := corev1.Service{
 		ObjectMeta: metav1.ObjectMeta{
 			Labels: map[string]string{
-				"camel.apache.org/integration": "test",
+				v1.IntegrationLabel: "test",
 			},
 		},
 	}
diff --git a/e2e/support/test_support.go b/e2e/support/test_support.go
index 6454bd091..6f76abafa 100644
--- a/e2e/support/test_support.go
+++ b/e2e/support/test_support.go
@@ -257,7 +257,7 @@ func IntegrationPod(ns string, name string) func() *corev1.Pod {
 		err := TestClient.List(TestContext, &lst,
 			k8sclient.InNamespace(ns),
 			k8sclient.MatchingLabels{
-				"camel.apache.org/integration": name,
+				v1.IntegrationLabel: name,
 			})
 		if err != nil {
 			panic(err)
diff --git a/pkg/trait/affinity_test.go b/pkg/trait/affinity_test.go
index 506b2f351..18dcf7fc9 100644
--- a/pkg/trait/affinity_test.go
+++ b/pkg/trait/affinity_test.go
@@ -98,7 +98,7 @@ func TestApplyPodAntiAffinityLabelsDoesSucceed(t *testing.T) {
 	assert.ElementsMatch(t, [1]string{"value"}, userRequirement.Values)
 	assert.NotNil(t, podAntiAffinity.RequiredDuringSchedulingIgnoredDuringExecution[0].LabelSelector.MatchExpressions[1])
 	integrationRequirement := podAntiAffinity.RequiredDuringSchedulingIgnoredDuringExecution[0].LabelSelector.MatchExpressions[1]
-	assert.Equal(t, "camel.apache.org/integration", integrationRequirement.Key)
+	assert.Equal(t, v1.IntegrationLabel, integrationRequirement.Key)
 	assert.Equal(t, metav1.LabelSelectorOpIn, integrationRequirement.Operator)
 	assert.ElementsMatch(t, [1]string{"integration-name"}, integrationRequirement.Values)
 }
@@ -119,7 +119,7 @@ func TestApplyPodAffinityLabelsDoesSucceed(t *testing.T) {
 	assert.Equal(t, metav1.LabelSelectorOpDoesNotExist, userRequirement.Operator)
 	assert.NotNil(t, podAffinity.RequiredDuringSchedulingIgnoredDuringExecution[0].LabelSelector.MatchExpressions[1])
 	integrationRequirement := podAffinity.RequiredDuringSchedulingIgnoredDuringExecution[0].LabelSelector.MatchExpressions[1]
-	assert.Equal(t, "camel.apache.org/integration", integrationRequirement.Key)
+	assert.Equal(t, v1.IntegrationLabel, integrationRequirement.Key)
 	assert.Equal(t, metav1.LabelSelectorOpIn, integrationRequirement.Operator)
 	assert.ElementsMatch(t, [1]string{"integration-name"}, integrationRequirement.Values)
 }
diff --git a/pkg/trait/deployment_test.go b/pkg/trait/deployment_test.go
index 9798e723c..2d5a838c6 100644
--- a/pkg/trait/deployment_test.go
+++ b/pkg/trait/deployment_test.go
@@ -152,7 +152,7 @@ func createNominalDeploymentTest() (*deploymentTrait, *Environment) {
 			Name:      "integration-name",
 			Namespace: "namespace",
 			Labels: map[string]string{
-				"camel.apache.org/integration": "integration-name",
+				v1.IntegrationLabel: "integration-name",
 			},
 		},
 		Spec: appsv1.DeploymentSpec{
diff --git a/pkg/trait/ingress_test.go b/pkg/trait/ingress_test.go
index 390efac6f..4536d028f 100644
--- a/pkg/trait/ingress_test.go
+++ b/pkg/trait/ingress_test.go
@@ -181,14 +181,14 @@ func createNominalIngressTest() (*ingressTrait, *Environment) {
 					Name:      "service-name",
 					Namespace: "namespace",
 					Labels: map[string]string{
-						"camel.apache.org/integration":  "integration-name",
+						v1.IntegrationLabel:             "integration-name",
 						"camel.apache.org/service.type": v1.ServiceTypeUser,
 					},
 				},
 				Spec: corev1.ServiceSpec{
 					Ports: []corev1.ServicePort{},
 					Selector: map[string]string{
-						"camel.apache.org/integration": "integration-name",
+						v1.IntegrationLabel: "integration-name",
 					},
 				},
 			},
diff --git a/pkg/trait/prometheus_test.go b/pkg/trait/prometheus_test.go
index 6eb6db5d2..6fb6e9219 100644
--- a/pkg/trait/prometheus_test.go
+++ b/pkg/trait/prometheus_test.go
@@ -128,14 +128,14 @@ func TestApplyPrometheusTraitWithServiceDoesSucceed(t *testing.T) {
 				Name:      "service-name",
 				Namespace: "namespace",
 				Labels: map[string]string{
-					"camel.apache.org/integration":  "integration-name",
+					v1.IntegrationLabel:             "integration-name",
 					"camel.apache.org/service.type": v1.ServiceTypeUser,
 				},
 			},
 			Spec: corev1.ServiceSpec{
 				Ports: []corev1.ServicePort{},
 				Selector: map[string]string{
-					"camel.apache.org/integration": "integration-name",
+					v1.IntegrationLabel: "integration-name",
 				},
 			},
 		})
@@ -162,8 +162,8 @@ func TestPrometheusTraitGetServiceMonitor(t *testing.T) {
 	assert.Equal(t, "monitoring.coreos.com/v1", serviceMonitor.APIVersion)
 	assert.Equal(t, "integration-name", serviceMonitor.Name)
 	assert.Equal(t, "integration-namespace", serviceMonitor.Namespace)
-	assert.Equal(t, "integration-name", serviceMonitor.Labels["camel.apache.org/integration"])
-	assert.Equal(t, "integration-name", serviceMonitor.Spec.Selector.MatchLabels["camel.apache.org/integration"])
+	assert.Equal(t, "integration-name", serviceMonitor.Labels[v1.IntegrationLabel])
+	assert.Equal(t, "integration-name", serviceMonitor.Spec.Selector.MatchLabels[v1.IntegrationLabel])
 	assert.Len(t, serviceMonitor.Spec.Endpoints, 1)
 	assert.Equal(t, "prometheus", serviceMonitor.Spec.Endpoints[0].Port)
 }
diff --git a/pkg/trait/route_test.go b/pkg/trait/route_test.go
index bba96d27b..71fb0d64e 100644
--- a/pkg/trait/route_test.go
+++ b/pkg/trait/route_test.go
@@ -77,14 +77,14 @@ func createTestRouteEnvironment(t *testing.T, name string) *Environment {
 					Name:      name,
 					Namespace: "test-ns",
 					Labels: map[string]string{
-						"camel.apache.org/integration":  name,
+						v1.IntegrationLabel:             name,
 						"camel.apache.org/service.type": v1.ServiceTypeUser,
 					},
 				},
 				Spec: corev1.ServiceSpec{
 					Ports: []corev1.ServicePort{},
 					Selector: map[string]string{
-						"camel.apache.org/integration": name,
+						v1.IntegrationLabel: name,
 					},
 				},
 			},