open-accelerators / mercury

Journey to open platform for digital bank modernization. A reference implementation of BIAN to start, providing documentation and artifacts of reusable source code.
Apache License 2.0
15 stars 9 forks source link

Updated crd names operator version to be compliant with operator hub #141

Closed tmihalac closed 2 years ago

tmihalac commented 2 years ago

Signed-off-by: Theodor Mihalache tmihalac@redhat.com

tmihalac commented 2 years ago

I can't find where is this a requirement

The validators they say to run were returning a warning that the version in the name should start with v

tmihalac commented 2 years ago

I can't find where is this a requirement

The validators they say to run were returning a warning that the version in the name should start with v

image

ruromero commented 2 years ago

I see, then I guess you have to address the rest of the warnings coming from the bundle validate and also update the workflow to use the operatorframework suite

↳ operator-sdk bundle validate ./bundle --select-optional suite=operatorframework
WARN[0000] Warning: Value : (mercury-operator.1.0.2) csv.metadata.Name mercury-operator.1.0.2 is not following the recommended naming convention: <operator-name>.v<semver> e.g. memcached-operator.v0.0.1 
WARN[0000] Warning: Value mercury-operator.1.0.2: unable to find the resource requests for the container: (mercury-operator). It is recommended to ensure the resource request for CPU and Memory. Be aware that for some clusters configurations it is required to specify requests or limits for those values. Otherwise, the system or quota may reject Pod creation. More info: https://master.sdk.operatorframework.io/docs/best-practices/managing-resources/ 
WARN[0000] Warning: Value mercury-operator.1.0.2: required CRD "kafkas.kafka.strimzi.io" has an empty description 
WARN[0000] Warning: Value mercury-operator.1.0.2: required CRD "kafkatopics.kafka.strimzi.io" has an empty description 
WARN[0000] Warning: Value mercury-operator.1.0.2: required CRD "kafkausers.kafka.strimzi.io" has an empty description 
WARN[0000] Warning: Value mercury-operator.1.0.2: required CRD "integrations.camel.apache.org" has an empty description 
tmihalac commented 2 years ago

I see, then I guess you have to address the rest of the warnings coming from the bundle validate and also update the workflow to use the operatorframework suite

↳ operator-sdk bundle validate ./bundle --select-optional suite=operatorframework
WARN[0000] Warning: Value : (mercury-operator.1.0.2) csv.metadata.Name mercury-operator.1.0.2 is not following the recommended naming convention: <operator-name>.v<semver> e.g. memcached-operator.v0.0.1 
WARN[0000] Warning: Value mercury-operator.1.0.2: unable to find the resource requests for the container: (mercury-operator). It is recommended to ensure the resource request for CPU and Memory. Be aware that for some clusters configurations it is required to specify requests or limits for those values. Otherwise, the system or quota may reject Pod creation. More info: https://master.sdk.operatorframework.io/docs/best-practices/managing-resources/ 
WARN[0000] Warning: Value mercury-operator.1.0.2: required CRD "kafkas.kafka.strimzi.io" has an empty description 
WARN[0000] Warning: Value mercury-operator.1.0.2: required CRD "kafkatopics.kafka.strimzi.io" has an empty description 
WARN[0000] Warning: Value mercury-operator.1.0.2: required CRD "kafkausers.kafka.strimzi.io" has an empty description 
WARN[0000] Warning: Value mercury-operator.1.0.2: required CRD "integrations.camel.apache.org" has an empty description 

image I am not sure what values to specify for these two warnings

ruromero commented 2 years ago

For minKubeVersion I'd put 1.19 which matches with OCP 4.6 and in 1.19 some of the features we depend on were introduced. We can try to validate the installation on that version to confirm it works.

For the application resources/limits try to see what the operator is usually consuming and put something a bit over these values

tmihalac commented 2 years ago

For minKubeVersion I'd put 1.19 which matches with OCP 4.6 and in 1.19 some of the features we depend on were introduced. We can try to validate the installation on that version to confirm it works.

For the application resources/limits try to see what the operator is usually consuming and put something a bit over these values

image This is a screenshot of the operator pod with one sd ideal, how much cpu and memory will suffice in your opinion ?

ruromero commented 2 years ago

My suggestion is to add this to the mercury-operator.csv.yaml

spec:
  MinKubeVersion: 1.19.0

And this to the operator.yaml

        resources:
          limits:
            memory: "64Mi"
            cpu: "100m"
          requests:
            memory: "64Mi"
            cpu: "100m"

Don't forget to re-generate the CSV and the catalog

ruromero commented 2 years ago

@tmihalac there should be only one commit on top of the main branch

sonarcloud[bot] commented 2 years ago

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication