Bug 2125728

Summary: Content view Promote always warns for 'Force promotion' even if correct path is followed.
Product: Red Hat Satellite Reporter: Avijit Roy <avroy>
Component: Content ViewsAssignee: Samir Jha <sajha>
Status: CLOSED ERRATA QA Contact: Sam Bible <sbible>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 6.11.1CC: iballou, msviriko, sajha, sbible, visawant
Target Milestone: 6.15.0Keywords: Triaged, UserExperience
Target Release: Unused   
Hardware: All   
OS: All   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2024-04-23 17:12:38 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Avijit Roy 2022-09-09 21:24:16 UTC
Description of problem:

Content View Promotion warns below message even if the correct promotion path is followed. 

Force promotion
Selected environment PREPROD is out of the environment path order. The recommended practice is to promote to the next environment in the path.

Version-Release number of selected component (if applicable):

6.11

How reproducible:
100%

Steps to Reproduce:

Scenario 1: 
~~~~~~~~~~

1. Create an environment path Library >> Test >> Preprod >> Prod.
2. Create a content view and publish (promote) to Library.
3. Promote Version:1 to Test.
4. Publish Version:2. 
5. Now Version:2 in Library and Version:1 in Test. 
6. If we try to Promote version:1 to Preprod it gives us the below warning. Though the Preprod Environment is in path. 

-----------
Force promotion
Selected environment PREPROD is out of the environment path order. The recommended practice is to promote to the next environment in the path.
-----------

7. But if we try again Promote Version:2 to Test it will not give us the error. 

Scenario:2
~~~~~~~~~~~

The above message is true when we do not follow the path at any time. Like below:

- Created a CV
- Initially, it is in the 'Library'
- Promoted directly to 'Preprod' [ Got the warning Selected environment PREPROD is out of the environment....]
- Now when I am trying to promote it to 'Prod' which is on the path I am getting the warning. 

Promotion path of the CV: Library  >>  Preprod  >> Prod
Actualt Environment Path of the CV: Library >> Test >> Preprod >> Prod.


Expected results:

The warning should only be applicable for Scenario 2. When we are already following the path Satellite should not give us a warning.

Comment 3 Maria Svirikova 2023-05-30 09:48:47 UTC
Scenario 1.
There shouldn't be a warning as the promotion is on the path (no warning for any of these steps 3, 6, 7)

Scenario 2.
Here we should get a warning just the first time (promotion from Library to Preprod) when we are skipping Test env.
When there is a promotion from Preprod to Prod, it's following the path again. There shouldn't be any warning.

RULE: If we skip any environment in the promotion path of one specific version - users will get a warning just in that case and within that specific version.

PATH: Library >> Test >> Preprod >> Prod - promoting Version 4

Library >> Test (none)
Library >> Preprod (warning)
Library >> Prod (warning)
Test >> Preprod (none)
Test >> Prod(warning)
Preprod >> Prod (none)

Comment 5 Samir Jha 2023-06-16 17:52:57 UTC
Created redmine issue https://projects.theforeman.org/issues/36515 from this bug

Comment 6 Bryan Kearney 2023-06-24 00:02:23 UTC
Moving this bug to POST for triage into Satellite since the upstream issue https://projects.theforeman.org/issues/36515 has been resolved.

Comment 8 Brad Buckingham 2023-10-30 11:29:29 UTC
Bulk setting Target Milestone = 6.15.0 where sat-6.15.0+ is set.

Comment 9 Sam Bible 2024-01-22 18:53:19 UTC
Verified on 6.15 - Snap 5

Steps to Verify:
1. Create a sequence of Lifecycle Environments: Library->Test->Preprod->Prod
2. Create a variety of CVs.
3. Test several different scenarios involving CV Promotion:
  - Publish a version of a CV, and promote it to Test
  - Publish a new version of this CV.
  - The first version should properly recognize that Preprod is in the right order, and not show a force promotion warning
  - This will, however, recognize that Prod is out of order, and warn us about a force promotion.
  - Publish a different CV, and attempt to promote it straight to Preprod. 
  - This should correctly warn us that this will be a force promotion.
 

Expected Results:
The above scenarios should appropriately show the Force Promotion warning, or not, as should be expected for the different scenarios.

Actual Results:
The above scenarios should appropriately show the Force Promotion warning, or not, as should be expected for the different scenarios.

Comment 12 errata-xmlrpc 2024-04-23 17:12:38 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 (Important: Satellite 6.15.0 release), 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/RHSA-2024:2010