Bug 1799056

Summary: OCS operator should make use of suggested namespace and cluster monitoring annotations
Product: [Red Hat Storage] Red Hat OpenShift Container Storage Reporter: Samuel Padgett <spadgett>
Component: ocs-operatorAssignee: umanga <uchapaga>
Status: CLOSED ERRATA QA Contact: Ramakrishnan Periyasamy <rperiyas>
Severity: medium Docs Contact:
Priority: unspecified    
Version: unspecifiedCC: agreene, jarrpa, madam, ocs-bugs, sostapov, tmuthami, uchapaga
Target Milestone: ---   
Target Release: OCS 4.3.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-04-14 09:45:55 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
namespace-recommendation UI image none

Description Samuel Padgett 2020-02-06 14:37:41 UTC
In 4.4, OpenShift console added support for two ClusterServiceVersion annotations:

* operatorframework.io/suggested-namespace - console will suggest and create the suggested namespace for the operator
* operatorframework.io/cluster-monitoring=true - console will ask the user if they want to enable monitoring the operator and apply the label to the created namespace

Operators that require a specific namespace and need to enable monitoring should add these annotations to give the UI hints. This will avoid extra steps requiring users to create and label the namespace outside of the UI.

More details in this enhancement:

https://github.com/openshift/enhancements/blob/master/enhancements/olm/olm-managed-operator-metrics.md#fulfilling-namespace-and-rbac-requirements

Here is the console PR:

https://github.com/openshift/console/pull/3862

Comment 2 Alexander Greene 2020-02-10 15:00:37 UTC
The suggested namespace annotation and cluster monitoring annotation documentation can be found here [1].

[1] https://docs.google.com/document/d/1Mru7pqkpx2gmxMxK6AYOLVphWW0mzwZG-R8_HBVxLwI/edit

Comment 3 Jose A. Rivera 2020-02-25 15:09:15 UTC
This is amazingly useful! I'll ACK this for 4.3, since the technical change in minimal.

Comment 6 Jose A. Rivera 2020-03-04 15:37:07 UTC
PR merged, but not yet available in a downstream build.

Comment 7 Jose A. Rivera 2020-03-05 03:48:13 UTC
PR has made it into a downstream build, moving to ON_QA.

Comment 8 Michael Adam 2020-03-05 06:52:42 UTC
(In reply to Jose A. Rivera from comment #7)
> PR has made it into a downstream build, moving to ON_QA.

Build has not passed ci yet, afacict, so still MODIFIED.

Comment 10 Ramakrishnan Periyasamy 2020-03-11 12:05:10 UTC
Created attachment 1669245 [details]
namespace-recommendation UI image

Moving this bz to verified state.

Note: This namespace recommendation will be visible only in OCP 4.4, If we deploy cluster with OCP 4.3 then we will not get this feature.

Verified in Version:
$ oc get clusterversion
NAME      VERSION                             AVAILABLE   PROGRESSING   SINCE   STATUS
version   4.4.0-0.nightly-2020-03-10-194324   True        False         144m    Cluster version is 4.4.0-0.nightly-2020-03-10-194324
$ oc get csv -n openshift-storage
NAME                            DISPLAY                       VERSION        REPLACES   PHASE
lib-bucket-provisioner.v1.0.0   lib-bucket-provisioner        1.0.0                     Succeeded
ocs-operator.v4.3.0-372.ci      OpenShift Container Storage   4.3.0-372.ci              Succeeded

After deployment all the rook, CSI pods were up and running. Ceph cluster health is OK.

Please refer the attachment for the namespace recommendation from UI.

Comment 13 errata-xmlrpc 2020-04-14 09:45:55 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2020:1437