Bug 1596338

Summary: [RFE] Automate - Expose max_retries override at instance level
Product: Red Hat CloudForms Management Engine Reporter: Fabien Dupont <fdupont>
Component: UI - OPSAssignee: Harpreet Kataria <hkataria>
Status: CLOSED CURRENTRELEASE QA Contact: Yadnyawalk Tale <ytale>
Severity: medium Docs Contact:
Priority: high    
Version: 5.9.0CC: cpelland, fdupont, hkataria, jprause, lavenel, mpovolny, obarenbo, simaishi, smallamp
Target Milestone: GAKeywords: FutureFeature, TestOnly, ZStream
Target Release: 5.10.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: 5.10.0.0 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
: 1598528 (view as bug list) Environment:
Last Closed: 2019-02-11 13:58:47 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: CFME Core Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1598528    
Attachments:
Description Flags
automate.log none

Description Fabien Dupont 2018-06-28 16:12:41 UTC
When one creates a state machine, the maximum number of retries for a state is set at the class level. However, a use case of state machines is to create generic state machines where the state name is 'StateX' and URI is specified only at the instance level, not the class. In this case, to stay generic, one is tempted to set the maximum number of retries to a very high number for each state, to cover whatever situation at the instance level.

Allowing to override the maximum number of retries at the instance level would help creating generic state machine classes (scaffolds) with no maximum retries set, and then let the instance specify the maximum retries based on the actual URI.

According to @mkanoor, the max_retries can already be set at the instance level in the backend code, but the UI currently doesn't support it. So I create this issue to politely ask for someone to add this in th Classic UI.

Comment 7 Yadnyawalk Tale 2018-08-08 10:55:16 UTC
Created attachment 1474269 [details]
automate.log

Fixed! I can confirm max_retries is at instance level in StateMachines UI.
Rechecked it by executing state machine via simulation.

1. Created domain and class
2. Created `meth1` method and `meth1_instance` instance in class
(domain attached)
3. Created state machine, added instance there and pointed value to `meth1_instance`
4. Added max_retries value as 3 in instance and 2 in class
5. In simulation, used `Call_Instance` with namespace, class and instance with Attribute/Value Pairs.

After submiting request we got three retries, which was what we were expected.
(automation.log attached)

Found features works very well, great work folks!
Verified on: 5.10.0.6.20180725145922_d299ff5 

Thanks!