Bug 2005917

Summary: Backport: Upgradeable=False conditions to 4.8 /settings/cluster page
Product: OpenShift Container Platform Reporter: Scott Dodson <sdodson>
Component: Management ConsoleAssignee: Jakub Hadvig <jhadvig>
Status: CLOSED ERRATA QA Contact: Yadan Pei <yapei>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 4.8CC: aos-bugs, jhadvig, jokerman, yapei
Target Milestone: ---   
Target Release: 4.8.z   
Hardware: Unspecified   
OS: Unspecified   
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: 2005493 Environment:
Last Closed: 2021-09-27 19:53:41 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Bug Depends On: 2005493    
Bug Blocks:    
Description Flags
Details page show not upgradable message
link to not upgradable clusteroperators none

Description Scott Dodson 2021-09-20 13:30:48 UTC
+++ This bug was initially created as a clone of Bug #2005493 +++

Please backport the improvements in CONSOLE-2152 to 4.8. At least specifically those to list out Upgradeable=False conditions on the /settings/cluster console page.

This will greatly improve the user experience as we add in an Admin Acknowledgement to 4.8.z which is implemented as an Upgradeable condition with a message directing the admin to review critical API removal documentation before acknowledging that by setting a configmap value.

--- Additional comment from Eric Paris on 2021-09-20 05:00:28 EDT ---

This bug sets Target Release equal to a z-stream but has no bug in the 'Depends On' field. As such this is not a valid bug state and the target release is being unset.

Any bug targeting 4.1.z must have a bug targeting 4.2 in 'Depends On.'
Similarly, any bug targeting 4.2.z must have a bug with Target Release of 4.3 in 'Depends On.'

Comment 1 Scott Dodson 2021-09-20 13:31:18 UTC
Hopefully this cloning of the bug appeases the eparis bug bot

Comment 2 Scott Dodson 2021-09-20 13:51:00 UTC
Patch manager, this is a feature backport which significantly improves the user experience around the admin acknowledgements which we intend to land in 4.8.z as a prerequisite to upgrading to 4.9. This makes Upgradeable=False conditions visible on the upgrade page so that the admin knows what they need to go resolve prior to attempting a minor version upgrade.

If you have any concerns about approving this please reach out to me.

Comment 5 Yadan Pei 2021-09-22 03:25:02 UTC
1. Create a ClusterOperator with Upgradeable=False
$ cat <<EOF >co.yaml 
apiVersion: config.openshift.io/v1
kind: ClusterOperator
  name: testing
spec: {}
$ oc apply -f co.yaml
$ oc proxy &
$ curl -k -XPATCH -H "Accept: application/json" -H "Content-Type: application/json-patch+json"
 -d '[{"op": "add", "path": "/status", "value": {"conditions": [{"lastTransitionTime": "2021-06-01T01:01:01Z",
 "type": "Upgradeable", "status": "False", "reason": "Testing", "message": "The whatsits are broken."}]}}]'
2. wait for ClusterVersion/version to reconcile the changes 
$ oc get clusterversions.config.openshift.io version -o yaml|grep Upgradeable -B5
  - lastTransitionTime: "2021-09-22T03:17:14Z"
    message: 'Cluster operator testing cannot be upgraded between minor versions:
      The whatsits are broken.'
    reason: Testing
    status: "False"
    type: Upgradeable

3. Check Cluster Settings Details page, warning message will be shown on the page with a link to the not upgradeable clusteroperators, see screenshot

Verified on 4.8.0-0.nightly-2021-09-21-191721

Comment 6 Yadan Pei 2021-09-22 03:26:25 UTC
Created attachment 1825169 [details]
Details page show not upgradable message

Comment 7 Yadan Pei 2021-09-22 03:29:42 UTC
Created attachment 1825170 [details]
link to not upgradable clusteroperators

Comment 10 errata-xmlrpc 2021-09-27 19:53:41 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 (OpenShift Container Platform 4.8.13 bug fix update), and where to find the updated
files, follow the link below.

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