Bug 1031034 - (heat-bp-support-retry-with-idempotency) [RFE][heat]: Support API retry function with Idempotency in creating/updating a stack
[RFE][heat]: Support API retry function with Idempotency in creating/updating...
Product: Red Hat OpenStack
Classification: Red Hat
Component: openstack-heat (Show other bugs)
Unspecified Unspecified
high Severity unspecified
: ---
: ---
Assigned To: Steve Baker
Amit Ugol
upstream_milestone_none upstream_stat...
: FutureFeature
Depends On:
Blocks: 1031047
  Show dependency treegraph
Reported: 2013-11-15 09:04 EST by Stephen Gordon
Modified: 2016-05-04 17:19 EDT (History)
5 users (show)

See Also:
Fixed In Version:
Doc Type: Enhancement
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2016-05-04 17:19:30 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Stephen Gordon 2013-11-15 09:04:59 EST
Cloned from launchpad blueprint https://blueprints.launchpad.net/heat/+spec/support-retry-with-idempotency.


Currently Heat doesn't have a retry function in creating/updating a stack.
In case of API request failure, Heat would change stack status to "XXX_FAILURE" .
(Or start rollback process if the rollback flag was true.)

However, I think there are some circumstances/scenarios where retry is appropriate.
(i.e. 503 response or timeout due to server failover)

On the other hand, however, a retry function may result in creating duplicate resources when Heat couldn't get response from nova and other APIs.
In order to avoid this, I believe leveraging idempotency that is discussed in nova could be a solution.


Our idea for implementing a retry function to Heat is:
Heat to retry POST requests with a ClientToken header to avoid creating duplicate resources, until it reaches a retry limit.
Heat to retry PUT/GET requests until it gets 2xx response or it reaches a retry limit. ClientTokens are not used in this case.
Heat to retry DELETE requests until it gets 2xx response or 404 response or it reaches a retry limit. ClientTokens are not used in this case.

Some of pythonclients have retry functions, but they cannot be utilized because Heat has to judge the necessity of retry by itself.

Specification URL (additional information):

Comment 2 Zane Bitter 2016-05-04 17:19:30 EDT
We have retries, but idempotency relies on changes to the Nova API which never landed. Closing this bug as there's no prospect of it happening upstream any time soon.

Note You need to log in before you can comment on or make changes to this bug.