From b14cdf8d7bf6b539c2af3e6891cd36955f8bc413 Mon Sep 17 00:00:00 2001 From: LewisKSaint Date: Tue, 30 Jul 2024 14:59:54 -0400 Subject: [PATCH 01/11] DATAGO-81623 | Fix for backwards compartibility for brokers 10.2 > and < 10.8 and docs update --- .github/workflows/build-test-dev.yml | 6 ++--- .github/workflows/prep-release.yml | 2 +- .github/workflows/vulncheck_periodic.yml | 6 ++--- Dockerfile | 4 ++-- Makefile | 2 +- ci/whitesource/whitesource-agent.config | 4 ++-- config/manager/kustomization.yaml | 2 +- controllers/controller_utils.go | 8 +++++++ controllers/statefulset.go | 29 +++++++++++++----------- deploy/deploy.yaml | 2 +- docs/EventBrokerOperatorUserGuide.md | 15 +++++++++--- version.go | 2 +- 12 files changed, 51 insertions(+), 31 deletions(-) diff --git a/.github/workflows/build-test-dev.yml b/.github/workflows/build-test-dev.yml index 8294510..e3b1cda 100644 --- a/.github/workflows/build-test-dev.yml +++ b/.github/workflows/build-test-dev.yml @@ -6,7 +6,7 @@ on: - main env: - VERSION: 1.1.0 + VERSION: 1.1.1 IMAGE_NAME: pubsubplus-eventbroker-operator VAULT_ADDR: ${{ secrets.VAULT_ADDR }} GCLOUD_PROJECT_ID_DEV: ${{ secrets.GCLOUD_PROJECT_ID }} @@ -122,7 +122,7 @@ jobs: secrets: | secret/data/development/gcp-gcr GCP_SERVICE_ACCOUNT | GCP_DEV_SERVICE_ACCOUNT env: - VERSION: 1.1.0 + VERSION: 1.1.1 IMAGE_NAME: pubsubplus-eventbroker-operator VAULT_ADDR: ${{ secrets.VAULT_ADDR }} GCLOUD_PROJECT_ID_DEV: ${{ secrets.GCLOUD_PROJECT_ID }} @@ -144,7 +144,7 @@ jobs: gcr.io/${{ env.GCLOUD_PROJECT_ID_DEV }}/${{ env.IMAGE_NAME }}:${{ env.VERSION }} push: true env: - VERSION: 1.1.0 + VERSION: 1.1.1 IMAGE_NAME: pubsubplus-eventbroker-operator VAULT_ADDR: ${{ secrets.VAULT_ADDR }} GCLOUD_PROJECT_ID_DEV: ${{ secrets.GCLOUD_PROJECT_ID }} diff --git a/.github/workflows/prep-release.yml b/.github/workflows/prep-release.yml index 819c2c6..0f980f9 100644 --- a/.github/workflows/prep-release.yml +++ b/.github/workflows/prep-release.yml @@ -4,7 +4,7 @@ on: release_tag: description: 'Release tag' required: true - default: '1.1.0' + default: '1.1.1' prep_internal_release: # Need to distinguish between internal and external releases # Internal release: Will use default internal location for created images (ghcr.io) and will tag and push operator candidate there diff --git a/.github/workflows/vulncheck_periodic.yml b/.github/workflows/vulncheck_periodic.yml index 4c41302..31079c9 100644 --- a/.github/workflows/vulncheck_periodic.yml +++ b/.github/workflows/vulncheck_periodic.yml @@ -4,7 +4,7 @@ on: - cron: '0 */ * * *' env: - VERSION: 1.1.0 + VERSION: 1.1.1 IMAGE_NAME: pubsubplus-eventbroker-operator VAULT_ADDR: ${{ secrets.VAULT_ADDR }} GCLOUD_PROJECT_ID_DEV: ${{ secrets.GCLOUD_PROJECT_ID }} @@ -65,7 +65,7 @@ jobs: secrets: | secret/data/development/gcp-gcr GCP_SERVICE_ACCOUNT | GCP_DEV_SERVICE_ACCOUNT env: - VERSION: 1.1.0 + VERSION: 1.1.1 IMAGE_NAME: pubsubplus-eventbroker-operator VAULT_ADDR: ${{ secrets.VAULT_ADDR }} GCLOUD_PROJECT_ID_DEV: ${{ secrets.GCLOUD_PROJECT_ID }} @@ -85,7 +85,7 @@ jobs: gcr.io/${{ env.GCLOUD_PROJECT_ID_DEV }}/${{ env.IMAGE_NAME }}:${{ env.VERSION }} push: true env: - VERSION: 1.1.0 + VERSION: 1.1.1 IMAGE_NAME: pubsubplus-eventbroker-operator VAULT_ADDR: ${{ secrets.VAULT_ADDR }} GCLOUD_PROJECT_ID_DEV: ${{ secrets.GCLOUD_PROJECT_ID }} diff --git a/Dockerfile b/Dockerfile index ec1cee5..cb0672d 100644 --- a/Dockerfile +++ b/Dockerfile @@ -23,8 +23,8 @@ FROM registry.access.redhat.com/ubi9/ubi-minimal:9.4-1134 LABEL name="solace/pubsubplus-eventbroker-operator" LABEL vendor="Solace Corporation" -LABEL version="1.1.0" -LABEL release="1.1.0" +LABEL version="1.1.1" +LABEL release="1.1.1" LABEL summary="Solace PubSub+ Event Broker Kubernetes Operator" LABEL description="The Solace PubSub+ Event Broker Kubernetes Operator deploys and manages the lifecycle of PubSub+ Event Brokers" diff --git a/Makefile b/Makefile index 3ddfe4a..f0b1af9 100644 --- a/Makefile +++ b/Makefile @@ -3,7 +3,7 @@ # To re-generate a bundle for another specific version without changing the standard setup, you can: # - use the VERSION as arg of the bundle target (e.g make bundle VERSION=0.0.2) # - use environment variables to overwrite this value (e.g export VERSION=0.0.2) -VERSION ?= 1.1.0 +VERSION ?= 1.1.1 # API_VERSION defines the API version for the PubSubPlusEventBroker CRD API_VERSION ?= v1beta1 diff --git a/ci/whitesource/whitesource-agent.config b/ci/whitesource/whitesource-agent.config index 2941dfd..a2d7476 100644 --- a/ci/whitesource/whitesource-agent.config +++ b/ci/whitesource/whitesource-agent.config @@ -41,11 +41,11 @@ go.modules.includeTestDependencies=true #userKey= projectName=pubsubplus-kubernetes-operator -projectVersion=v1.1.0 +projectVersion=v1.1.1 projectToken= productName=pubsubplus-kubernetes-operator -productVersion=v1.1.0 +productVersion=v1.1.1 productToken= updateType=OVERRIDE #requesterEmail=user@provider.com diff --git a/config/manager/kustomization.yaml b/config/manager/kustomization.yaml index aba9d59..813aa0d 100644 --- a/config/manager/kustomization.yaml +++ b/config/manager/kustomization.yaml @@ -11,4 +11,4 @@ kind: Kustomization images: - name: controller newName: ghcr.io/solacedev/pubsubplus-eventbroker-operator - newTag: 1.1.0 + newTag: 1.1.1 diff --git a/controllers/controller_utils.go b/controllers/controller_utils.go index fd05712..916904e 100644 --- a/controllers/controller_utils.go +++ b/controllers/controller_utils.go @@ -21,6 +21,7 @@ import ( "context" "embed" "encoding/gob" + "encoding/json" "fmt" eventbrokerv1beta1 "github.com/SolaceProducts/pubsubplus-operator/api/v1beta1" "hash/crc64" @@ -132,3 +133,10 @@ func hash(s any) string { crc64Table := crc64.MakeTable(crc64.ECMA) return strconv.FormatUint(crc64.Checksum(convertToByteArray(s), crc64Table), 16) } + +func parseScalingParameterWithUnKnownFieldsToMap(scalingParameter *eventbrokerv1beta1.SystemScaling) map[string]interface{} { + var scalingParamMap map[string]interface{} + marshalScalingParameter, _ := json.Marshal(scalingParameter) + json.Unmarshal(marshalScalingParameter, &scalingParamMap) + return scalingParamMap +} diff --git a/controllers/statefulset.go b/controllers/statefulset.go index f76259f..ddbd3fd 100644 --- a/controllers/statefulset.go +++ b/controllers/statefulset.go @@ -137,24 +137,29 @@ func (r *PubSubPlusEventBrokerReconciler) updateStatefulsetForEventBroker(sts *a maxConnections = (map[bool]int{true: DefaultDeveloperModeMaxConnections, false: DefaultMessagingNodeMaxConnections})[m.Spec.Developer] maxQueueMessages = (map[bool]int{true: DefaultDeveloperModeMaxQueueMessages, false: DefaultMessagingNodeMaxQueueMessages})[m.Spec.Developer] maxSpoolUsage = (map[bool]int{true: DefaultDeveloperModeMaxSpoolUsage, false: DefaultMessagingNodeMaxSpoolUsage})[m.Spec.Developer] + + scalingParamMap := parseScalingParameterWithUnKnownFieldsToMap(m.Spec.SystemScaling) // Overwrite for any values defined in spec.systemScaling if m.Spec.SystemScaling != nil && !m.Spec.Developer { - if m.Spec.SystemScaling.MessagingNodeCpu != "" { - cpuRequests = m.Spec.SystemScaling.MessagingNodeCpu + if messagingNodeCpu, ok := scalingParamMap["messagingNodeCpu"]; ok && messagingNodeCpu != "" { + cpuRequests = messagingNodeCpu.(string) cpuLimits = cpuRequests } - if m.Spec.SystemScaling.MessagingNodeMemory != "" { - memRequests = m.Spec.SystemScaling.MessagingNodeMemory + if messagingNodeMemory, ok := scalingParamMap["messagingNodeMemory"]; ok && messagingNodeMemory != "" { + memRequests = messagingNodeMemory.(string) memLimits = memRequests } - if m.Spec.SystemScaling.MaxConnections > 0 { - maxConnections = m.Spec.SystemScaling.MaxConnections + if maxConnectionsValue, ok := scalingParamMap["maxConnections"]; ok && maxConnectionsValue != "" { + maxConnectionsFloat := maxConnectionsValue.(float64) + maxConnections = int(maxConnectionsFloat) } - if m.Spec.SystemScaling.MaxQueueMessages > 0 { - maxQueueMessages = m.Spec.SystemScaling.MaxQueueMessages + if maxQueueMessagesValue, ok := scalingParamMap["maxQueueMessages"]; ok && maxQueueMessagesValue != "" { + maxQueueMessagesValueFloat := maxQueueMessagesValue.(float64) + maxQueueMessages = int(maxQueueMessagesValueFloat) } - if m.Spec.SystemScaling.MaxSpoolUsage > 0 { - maxSpoolUsage = m.Spec.SystemScaling.MaxSpoolUsage + if maxSpoolUsageValue, ok := scalingParamMap["maxSpoolUsage"]; ok && maxSpoolUsageValue != "" { + maxSpoolUsageValueFloat := maxSpoolUsageValue.(float64) + maxSpoolUsage = int(maxSpoolUsageValueFloat) } } } @@ -639,9 +644,7 @@ func (r *PubSubPlusEventBrokerReconciler) updateStatefulsetForEventBroker(sts *a //Set unknown scaling parameter values if m.Spec.SystemScaling != nil { var err error - var scalingParamMap map[string]interface{} - inrec, _ := json.Marshal(m.Spec.SystemScaling) - json.Unmarshal(inrec, &scalingParamMap) + scalingParamMap := parseScalingParameterWithUnKnownFieldsToMap(m.Spec.SystemScaling) allEnv := sts.Spec.Template.Spec.Containers[0].Env for key, val := range scalingParamMap { if strings.HasPrefix(strings.ToLower(key), scalingParameterPrefix) || strings.HasPrefix(strings.ToLower(key), scalingParameterSpoolPrefix) { diff --git a/deploy/deploy.yaml b/deploy/deploy.yaml index 6fe71fb..8f6c0b3 100644 --- a/deploy/deploy.yaml +++ b/deploy/deploy.yaml @@ -1931,7 +1931,7 @@ spec: env: - name: WATCH_NAMESPACE value: "" - image: docker.io/solace/pubsubplus-eventbroker-operator:1.1.0 + image: ghcr.io/solacedev/pubsubplus-eventbroker-operator:1.1.1 imagePullPolicy: Always livenessProbe: httpGet: diff --git a/docs/EventBrokerOperatorUserGuide.md b/docs/EventBrokerOperatorUserGuide.md index 7c53389..5551c3f 100644 --- a/docs/EventBrokerOperatorUserGuide.md +++ b/docs/EventBrokerOperatorUserGuide.md @@ -301,10 +301,21 @@ spec: messagingNodeCpu: "2" messagingNodeMemory: "4025Mi" ``` +or + +```yaml +spec: + systemScaling: + system_scaling_maxconnectioncount: 100 + system_scaling_maxqueuemessagecount: 100 + messagespool_maxspoolusage: 1000 + messagingNodeCpu: "2" + messagingNodeMemory: "4025Mi" +``` >Note: Beyond CPU and memory requirements, broker storage size (see [Storage](#storage) section) must also support the provided scaling. The calculator can be used to determine that as well. -Also note, that specifying `maxConnections`, `maxQueueMessages`, and `maxSpoolUsage` on initial deployment overwrites the broker’s default values. On the other hand, doing the same using upgrade on an existing deployment does not overwrite these values on brokers configuration, but it can be used to prepare (first step) for a manual scale up using CLI where these parameter changes would actually become effective (second step). +Also note, that specifying `maxConnections`, `maxQueueMessages`, and `maxSpoolUsage` on initial deployment overwrites the broker’s default values. On the other hand, doing the same using upgrade on an existing deployment does not overwrite these values on brokers configuration, but it can be used to prepare (first step) for a manual scale up using CLI where these parameter changes would actually become effective (second step). The Operator will use default configurations in situations where the scaling parameters are not provided or are not valid. >Note: The scaling parameters intentionally use a mix of *camelCase* and *snake_case* to maintain backward and forward compatibility with Solace PubSub+ Software Event Broker configurations. Make sure values are not duplicated for consistency. When using the [resource calculator](https://docs.solace.com/Admin-Ref/Resource-Calculator/pubsubplus-resource-calculator.html), ensure that the scaling parameters are in the correct format to match what the Solace PubSub+ Software Event Broker expects. If invalid scaling parameters are provided, the Operator will revert to default values. For the list of default values, please refer to this [link](/docs/EventBrokerOperatorParametersReference.md). @@ -1486,8 +1497,6 @@ A given version of the Operator has a dependency on the PubSubPlusEventBroker Cu You can use OLM to manage installing new versions of the Operator as they become available. The default install of the PubSub+ Event Broker Operator is set to perform automatic updates. This can be changed to `Manual` by editing the broker subscription in the `operators` namespace. -If the Operator has been installed directly from the command line then update `deploy.yaml` to the new operator image tag, run `kubectl apply -f `, and then validate the updated deployment. - #### Upgrade CRD and Operator OLM automatically manages the CRD and Operator updates. diff --git a/version.go b/version.go index 6aeb0eb..13d52fa 100644 --- a/version.go +++ b/version.go @@ -15,4 +15,4 @@ // limitations under the License. package main -const version = "1.1.0" +const version = "1.1.1" From 32646f752f13b6f5fc1a48d1d916398f2277cfc5 Mon Sep 17 00:00:00 2001 From: LewisKSaint Date: Tue, 30 Jul 2024 17:45:23 -0400 Subject: [PATCH 02/11] DATAGO-81623 | Fix for backwards compartibility for brokers 10.2 > and < 10.8 and docs update --- docs/EventBrokerOperatorUserGuide.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/EventBrokerOperatorUserGuide.md b/docs/EventBrokerOperatorUserGuide.md index 5551c3f..c082caf 100644 --- a/docs/EventBrokerOperatorUserGuide.md +++ b/docs/EventBrokerOperatorUserGuide.md @@ -315,7 +315,7 @@ spec: >Note: Beyond CPU and memory requirements, broker storage size (see [Storage](#storage) section) must also support the provided scaling. The calculator can be used to determine that as well. -Also note, that specifying `maxConnections`, `maxQueueMessages`, and `maxSpoolUsage` on initial deployment overwrites the broker’s default values. On the other hand, doing the same using upgrade on an existing deployment does not overwrite these values on brokers configuration, but it can be used to prepare (first step) for a manual scale up using CLI where these parameter changes would actually become effective (second step). The Operator will use default configurations in situations where the scaling parameters are not provided or are not valid. +Also note, that specifying `maxConnections`, `maxQueueMessages`, and `maxSpoolUsage` on initial deployment overwrites the broker’s default values. On the other hand, doing the same using upgrade on an existing deployment does not overwrite these values on brokers configuration, but it can be used to prepare (first step) for a manual scale up using CLI where these parameter changes would actually become effective (second step). The Operator will use default configurations in situations where the scaling parameters are not provided or are not valid. >Note: The scaling parameters intentionally use a mix of *camelCase* and *snake_case* to maintain backward and forward compatibility with Solace PubSub+ Software Event Broker configurations. Make sure values are not duplicated for consistency. When using the [resource calculator](https://docs.solace.com/Admin-Ref/Resource-Calculator/pubsubplus-resource-calculator.html), ensure that the scaling parameters are in the correct format to match what the Solace PubSub+ Software Event Broker expects. If invalid scaling parameters are provided, the Operator will revert to default values. For the list of default values, please refer to this [link](/docs/EventBrokerOperatorParametersReference.md). From 56a69ae945b6ebbc23dab4e4724a81fba870cb0c Mon Sep 17 00:00:00 2001 From: LewisKSaint Date: Wed, 31 Jul 2024 08:18:28 -0400 Subject: [PATCH 03/11] Fix vulnerabilities --- go.mod | 14 +++++++------- go.sum | 28 ++++++++++++++-------------- 2 files changed, 21 insertions(+), 21 deletions(-) diff --git a/go.mod b/go.mod index 099d9f6..4fa9421 100644 --- a/go.mod +++ b/go.mod @@ -5,8 +5,8 @@ go 1.21 require ( github.com/google/gnostic-models v0.6.8 // indirect github.com/matttproud/golang_protobuf_extensions/v2 v2.0.0 // indirect - github.com/onsi/ginkgo/v2 v2.14.0 - github.com/onsi/gomega v1.30.0 + github.com/onsi/ginkgo/v2 v2.17.1 + github.com/onsi/gomega v1.33.0 golang.org/x/exp v0.0.0-20220722155223-a9213eeb770e // indirect k8s.io/apimachinery v0.29.0 k8s.io/client-go v0.29.0 @@ -48,16 +48,16 @@ require ( github.com/spf13/pflag v1.0.5 // indirect go.uber.org/multierr v1.11.0 // indirect go.uber.org/zap v1.26.0 - golang.org/x/net v0.19.0 // indirect + golang.org/x/net v0.23.0 // indirect golang.org/x/oauth2 v0.12.0 // indirect - golang.org/x/sys v0.16.0 // indirect - golang.org/x/term v0.15.0 // indirect + golang.org/x/sys v0.18.0 // indirect + golang.org/x/term v0.18.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/time v0.3.0 // indirect - golang.org/x/tools v0.16.1 // indirect + golang.org/x/tools v0.17.0 // indirect gomodules.xyz/jsonpatch/v2 v2.4.0 // indirect google.golang.org/appengine v1.6.7 // indirect - google.golang.org/protobuf v1.31.0 // indirect + google.golang.org/protobuf v1.33.0 // indirect gopkg.in/inf.v0 v0.9.1 // indirect gopkg.in/yaml.v2 v2.4.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect diff --git a/go.sum b/go.sum index 4b1507d..7a741d6 100644 --- a/go.sum +++ b/go.sum @@ -78,10 +78,10 @@ github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9G github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk= github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 h1:C3w9PqII01/Oq1c1nUAm88MOHcQC9l5mIlSMApZMrHA= github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ= -github.com/onsi/ginkgo/v2 v2.14.0 h1:vSmGj2Z5YPb9JwCWT6z6ihcUvDhuXLc3sJiqd3jMKAY= -github.com/onsi/ginkgo/v2 v2.14.0/go.mod h1:JkUdW7JkN0V6rFvsHcJ478egV3XH9NxpD27Hal/PhZw= -github.com/onsi/gomega v1.30.0 h1:hvMK7xYz4D3HapigLTeGdId/NcfQx1VHMJc60ew99+8= -github.com/onsi/gomega v1.30.0/go.mod h1:9sxs+SwGrKI0+PWe4Fxa9tFQQBG5xSsSbMXOI8PPpoQ= +github.com/onsi/ginkgo/v2 v2.17.1 h1:V++EzdbhI4ZV4ev0UTIj0PzhzOcReJFyJaLjtSF55M8= +github.com/onsi/ginkgo/v2 v2.17.1/go.mod h1:llBI3WDLL9Z6taip6f33H76YcWtJv+7R3HigUjbIBOs= +github.com/onsi/gomega v1.33.0 h1:snPCflnZrpMsy94p4lXVEkHo12lmPnc3vY5XBbreexE= +github.com/onsi/gomega v1.33.0/go.mod h1:+925n5YtiFsLzzafLUHzVMBpvvRAzrydIBiSIxjX3wY= github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= @@ -128,8 +128,8 @@ golang.org/x/net v0.0.0-20190603091049-60506f45cf65/go.mod h1:HSz+uSET+XFnRR8LxR golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20200226121028-0de0cce0169b/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= -golang.org/x/net v0.19.0 h1:zTwKpTd2XuCqf8huc7Fo2iSy+4RHPd10s4KzeTnVr1c= -golang.org/x/net v0.19.0/go.mod h1:CfAk/cbD4CthTvqiEl8NpboMuiuOYsAr/7NOjZJtv1U= +golang.org/x/net v0.23.0 h1:7EYJ93RZ9vYSZAIb2x3lnuvqO5zneoD6IvWjuhfxjTs= +golang.org/x/net v0.23.0/go.mod h1:JKghWKKOSdJwpW2GEx0Ja7fmaKnMsbu+MWVZTokSYmg= golang.org/x/oauth2 v0.12.0 h1:smVPGxink+n1ZI5pkQa8y6fZT0RW0MgCO5bFpepy4B4= golang.org/x/oauth2 v0.12.0/go.mod h1:A74bZ3aGXgCY0qaIC9Ahg6Lglin4AMAco8cIv9baba4= golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= @@ -139,10 +139,10 @@ golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5h golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191204072324-ce4227a45e2e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.16.0 h1:xWw16ngr6ZMtmxDyKyIgsE93KNKz5HKmMa3b8ALHidU= -golang.org/x/sys v0.16.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= -golang.org/x/term v0.15.0 h1:y/Oo/a/q3IXu26lQgl04j/gjuBDOBlx7X6Om1j2CPW4= -golang.org/x/term v0.15.0/go.mod h1:BDl952bC7+uMoWR75FIrCDx79TPU9oHkTZ9yRbYOrX0= +golang.org/x/sys v0.18.0 h1:DBdB3niSjOA/O0blCZBqDefyWNYveAYMNF1Wum0DYQ4= +golang.org/x/sys v0.18.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/term v0.18.0 h1:FcHjZXDMxI8mM3nwhX9HlKop4C0YQvCVCdwYl2wOtE8= +golang.org/x/term v0.18.0/go.mod h1:ILwASektA3OnRv7amZ1xhE/KTR+u50pbXfZ03+6Nx58= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= @@ -154,8 +154,8 @@ golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGm golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20200619180055-7c47624df98f/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= -golang.org/x/tools v0.16.1 h1:TLyB3WofjdOEepBHAU20JdNC1Zbg87elYofWYAY5oZA= -golang.org/x/tools v0.16.1/go.mod h1:kYVVN6I1mBNoB1OX+noeBjbRk4IUEPa7JJ+TJMEooJ0= +golang.org/x/tools v0.17.0 h1:FvmRgNOcs3kOa+T20R1uhfP9F6HgG2mfxDv1vrx1Htc= +golang.org/x/tools v0.17.0/go.mod h1:xsh6VxdV005rRVaS6SSAf9oiAqljS7UZUacMZ8Bnsps= golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= @@ -166,8 +166,8 @@ google.golang.org/appengine v1.6.7 h1:FZR1q0exgwxzPzp/aF+VccGrSfxfPpkBqjIIEq3ru6 google.golang.org/appengine v1.6.7/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc= google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp09yW+WbY/TyQbw= google.golang.org/protobuf v1.26.0/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= -google.golang.org/protobuf v1.31.0 h1:g0LDEJHgrBl9N9r17Ru3sqWhkIx2NB67okBHPwC7hs8= -google.golang.org/protobuf v1.31.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= +google.golang.org/protobuf v1.33.0 h1:uNO2rsAINq/JlFpSdYEKIZ0uKD/R9cpdv0T+yoGwGmI= +google.golang.org/protobuf v1.33.0/go.mod h1:c6P6GXX6sHbq/GpV6MGZEdwhWPcYBgnhAHhKbcUYpos= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= From 9185bffbfaa6af8af03c4d3519a39422dad452a1 Mon Sep 17 00:00:00 2001 From: LewisKSaint Date: Wed, 31 Jul 2024 09:44:15 -0400 Subject: [PATCH 04/11] Fix vulnerabilities --- Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index cb0672d..0bd1001 100644 --- a/Dockerfile +++ b/Dockerfile @@ -19,7 +19,7 @@ RUN CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -a -o manager main.go # Use distroless as minimal base image to package the manager binary # Refer to https://github.com/GoogleContainerTools/distroless for more details -FROM registry.access.redhat.com/ubi9/ubi-minimal:9.4-1134 +FROM registry.access.redhat.com/ubi9/ubi-minimal:9.4-1194 LABEL name="solace/pubsubplus-eventbroker-operator" LABEL vendor="Solace Corporation" From 2c1a55c2943f58c0e3d7dbee26a3ad871fab5e33 Mon Sep 17 00:00:00 2001 From: LewisKSaint Date: Wed, 31 Jul 2024 09:58:19 -0400 Subject: [PATCH 05/11] Fix vulnerabilities --- .github/workflows/build-test-dev.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-test-dev.yml b/.github/workflows/build-test-dev.yml index e3b1cda..7497983 100644 --- a/.github/workflows/build-test-dev.yml +++ b/.github/workflows/build-test-dev.yml @@ -6,7 +6,7 @@ on: - main env: - VERSION: 1.1.1 + VERSION: 1.1.1-dev IMAGE_NAME: pubsubplus-eventbroker-operator VAULT_ADDR: ${{ secrets.VAULT_ADDR }} GCLOUD_PROJECT_ID_DEV: ${{ secrets.GCLOUD_PROJECT_ID }} From 8f9187e0de63617618faa97e07f15638359b3c98 Mon Sep 17 00:00:00 2001 From: LewisKSaint Date: Wed, 31 Jul 2024 10:10:42 -0400 Subject: [PATCH 06/11] Pipeline fix for prisma --- .github/workflows/build-test-dev.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build-test-dev.yml b/.github/workflows/build-test-dev.yml index 7497983..2b0dd4e 100644 --- a/.github/workflows/build-test-dev.yml +++ b/.github/workflows/build-test-dev.yml @@ -122,7 +122,7 @@ jobs: secrets: | secret/data/development/gcp-gcr GCP_SERVICE_ACCOUNT | GCP_DEV_SERVICE_ACCOUNT env: - VERSION: 1.1.1 + VERSION: ${{ env.VERSION }} IMAGE_NAME: pubsubplus-eventbroker-operator VAULT_ADDR: ${{ secrets.VAULT_ADDR }} GCLOUD_PROJECT_ID_DEV: ${{ secrets.GCLOUD_PROJECT_ID }} @@ -144,7 +144,7 @@ jobs: gcr.io/${{ env.GCLOUD_PROJECT_ID_DEV }}/${{ env.IMAGE_NAME }}:${{ env.VERSION }} push: true env: - VERSION: 1.1.1 + VERSION: ${{ env.VERSION }} IMAGE_NAME: pubsubplus-eventbroker-operator VAULT_ADDR: ${{ secrets.VAULT_ADDR }} GCLOUD_PROJECT_ID_DEV: ${{ secrets.GCLOUD_PROJECT_ID }} From 262c88304a156645948bb533e6e0aacb9cfdff99 Mon Sep 17 00:00:00 2001 From: LewisKSaint Date: Wed, 31 Jul 2024 11:20:06 -0400 Subject: [PATCH 07/11] DATAGO-81833 | pipeline fix for vulnerability scanning --- .github/workflows/build-test-dev.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build-test-dev.yml b/.github/workflows/build-test-dev.yml index 2b0dd4e..796674e 100644 --- a/.github/workflows/build-test-dev.yml +++ b/.github/workflows/build-test-dev.yml @@ -149,6 +149,8 @@ jobs: VAULT_ADDR: ${{ secrets.VAULT_ADDR }} GCLOUD_PROJECT_ID_DEV: ${{ secrets.GCLOUD_PROJECT_ID }} + - name: Build image and push GitHub Container Registry + run: make docker-push - name: Run Vulnerability PreCheck for Prisma uses: ./maas-build-actions/.github/actions/prisma-vulnerability-checker @@ -159,8 +161,6 @@ jobs: project_squad: "launchpad" prisma_jira_check: "False" - - name: Build image and push GitHub Container Registry - run: make docker-push - name: Run Whitesource Action uses: SolaceDev/Mend-Scan-GHA@v1.0.0 From bf0895464a663d960e9945d332a66a84dc09d77a Mon Sep 17 00:00:00 2001 From: LewisKSaint Date: Wed, 31 Jul 2024 11:37:03 -0400 Subject: [PATCH 08/11] DATAGO-81833 | pipeline fix for vulnerability scanning --- .github/workflows/build-test-dev.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-test-dev.yml b/.github/workflows/build-test-dev.yml index 796674e..272b49b 100644 --- a/.github/workflows/build-test-dev.yml +++ b/.github/workflows/build-test-dev.yml @@ -6,7 +6,7 @@ on: - main env: - VERSION: 1.1.1-dev + VERSION: 1.1.1 IMAGE_NAME: pubsubplus-eventbroker-operator VAULT_ADDR: ${{ secrets.VAULT_ADDR }} GCLOUD_PROJECT_ID_DEV: ${{ secrets.GCLOUD_PROJECT_ID }} From e98a5047899236985922422ba31bd3de082a92cb Mon Sep 17 00:00:00 2001 From: LewisKSaint Date: Wed, 31 Jul 2024 12:44:05 -0400 Subject: [PATCH 09/11] DATAGO-81833 | clean up for release --- deploy/deploy.yaml | 2 +- .../EventBrokerOperatorParametersReference.md | 41 +++++++++++++++++++ 2 files changed, 42 insertions(+), 1 deletion(-) diff --git a/deploy/deploy.yaml b/deploy/deploy.yaml index 8f6c0b3..88e6549 100644 --- a/deploy/deploy.yaml +++ b/deploy/deploy.yaml @@ -1931,7 +1931,7 @@ spec: env: - name: WATCH_NAMESPACE value: "" - image: ghcr.io/solacedev/pubsubplus-eventbroker-operator:1.1.1 + image: docker.io/solace/pubsubplus-eventbroker-operator:1.1.1 imagePullPolicy: Always livenessProbe: httpGet: diff --git a/docs/EventBrokerOperatorParametersReference.md b/docs/EventBrokerOperatorParametersReference.md index bca81a6..731e787 100644 --- a/docs/EventBrokerOperatorParametersReference.md +++ b/docs/EventBrokerOperatorParametersReference.md @@ -459,6 +459,13 @@ Monitoring specifies a Prometheus monitoring endpoint for the event broker Default: false
false + + extraEnvVars + []object + + List of extra environment variables to be added to the Prometheus Exporter container.
+ + false image object @@ -504,6 +511,40 @@ Monitoring specifies a Prometheus monitoring endpoint for the event broker +### PubSubPlusEventBroker.spec.monitoring.extraEnvVars[index] +[↩ Parent](#pubsubpluseventbrokerspecmonitoring) + + + +MonitoringExtraEnvVar defines environment variables to be added to the Prometheus Exporter container for Monitoring + + + + + + + + + + + + + + + + + + + + + +
NameTypeDescriptionRequired
namestring + Specifies the Name of an environment variable to be added to the Prometheus Exporter container for Monitoring
+
true
valuestring + Specifies the Value of an environment variable to be added to the Prometheus Exporter container for Monitoring
+
true
+ + ### PubSubPlusEventBroker.spec.monitoring.image [↩ Parent](#pubsubpluseventbrokerspecmonitoring) From dc300a43a36919cba5340194695f5897d773152d Mon Sep 17 00:00:00 2001 From: LewisKSaint Date: Wed, 31 Jul 2024 14:50:19 -0400 Subject: [PATCH 10/11] v1.1.1 Release --- ...lus-eventbroker-operator.clusterserviceversion.yaml | 10 +++++----- config/manager/kustomization.yaml | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/bundle/manifests/pubsubplus-eventbroker-operator.clusterserviceversion.yaml b/bundle/manifests/pubsubplus-eventbroker-operator.clusterserviceversion.yaml index 521715f..1a6e3c2 100644 --- a/bundle/manifests/pubsubplus-eventbroker-operator.clusterserviceversion.yaml +++ b/bundle/manifests/pubsubplus-eventbroker-operator.clusterserviceversion.yaml @@ -20,8 +20,8 @@ metadata: certified: "true" com.redhat.delivery.operator.bundle: "true" com.redhat.openshift.versions: v4.10 - containerImage: docker.io/solace/pubsubplus-eventbroker-operator:1.1.0 - createdAt: "2024-07-01T12:25:04Z" + containerImage: docker.io/solace/pubsubplus-eventbroker-operator:v1.1.1 + createdAt: "2024-07-31T18:47:51Z" description: The Solace PubSub+ Event Broker Operator deploys and manages the lifecycle of PubSub+ Event Brokers operators.openshift.io/valid-subscription: '[]' @@ -29,7 +29,7 @@ metadata: operators.operatorframework.io/project_layout: go.kubebuilder.io/v3 repository: https://github.com/SolaceProducts/pubsubplus-kubernetes-quickstart support: Solace Products - name: pubsubplus-eventbroker-operator.v1.1.0 + name: pubsubplus-eventbroker-operator.v1.1.1 namespace: placeholder spec: apiservicedefinitions: {} @@ -296,7 +296,7 @@ spec: valueFrom: fieldRef: fieldPath: metadata.annotations['olm.targetNamespaces'] - image: docker.io/solace/pubsubplus-eventbroker-operator:1.1.0 + image: docker.io/solace/pubsubplus-eventbroker-operator:1.1.1 imagePullPolicy: Always livenessProbe: httpGet: @@ -411,4 +411,4 @@ spec: provider: name: Solace Corporation url: www.solace.com - version: 1.1.0 + version: 1.1.1 diff --git a/config/manager/kustomization.yaml b/config/manager/kustomization.yaml index 813aa0d..f4307df 100644 --- a/config/manager/kustomization.yaml +++ b/config/manager/kustomization.yaml @@ -10,5 +10,5 @@ apiVersion: kustomize.config.k8s.io/v1beta1 kind: Kustomization images: - name: controller - newName: ghcr.io/solacedev/pubsubplus-eventbroker-operator + newName: docker.io/solace/pubsubplus-eventbroker-operator newTag: 1.1.1 From 05cda40965d13e7c0992633ddc19aff46a8315c5 Mon Sep 17 00:00:00 2001 From: LewisKSaint Date: Wed, 31 Jul 2024 14:53:12 -0400 Subject: [PATCH 11/11] v1.1.1 Release --- .../pubsubplus.solace.com_pubsubpluseventbrokers.yaml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/bundle/manifests/pubsubplus.solace.com_pubsubpluseventbrokers.yaml b/bundle/manifests/pubsubplus.solace.com_pubsubpluseventbrokers.yaml index 70b6fe3..30ad301 100644 --- a/bundle/manifests/pubsubplus.solace.com_pubsubpluseventbrokers.yaml +++ b/bundle/manifests/pubsubplus.solace.com_pubsubpluseventbrokers.yaml @@ -3,7 +3,8 @@ kind: CustomResourceDefinition metadata: annotations: controller-gen.kubebuilder.io/version: v0.14.0 - creationTimestamp: null + labels: + app.kubernetes.io/version: v1.1.1 name: pubsubpluseventbrokers.pubsubplus.solace.com spec: group: pubsubplus.solace.com