tripleoclient sets UpdateIdentifier to None on create

Bug #1596640 reported by Steven Hardy
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
tripleo
Fix Released
High
Steven Hardy

Bug Description

When doing initial deployment, UpdateIdentifier is set to None, this taken from openstack overcloud deploy --debug --templates

  parameter:defaults: .. u'UpdateIdentifier': None

This makes logical sense, but it's incompatible with the Heat parameters schema, where a nested template consuming this data must declare a type (e.g "string"), but then if a nested stack defines UpdateIdentifier and you try to create a stack you get this error:

2016-06-27 17:20:20 [overcloud]: CREATE_FAILED Resource CREATE failed: resources.ContrailControllerNodes: resources.Networks.resources.NetworkExtraConfig.Property error: resources[0].properties: Property UpdateIdentifier not assigned

This is actually a fairly clear error, but it's confusing from a template author's perspective, because it persists even when you provide a default inside your template parameter definition for UpdateIdentifier.

It appears this issue only manifests if you declare UpdateIdentifier in a nested template where it's not passed via a parent stack, which is probably why we don't hit this in CI etc.

The easiest fix is probably to just pass an empty string instead of None in the client.

Steven Hardy (shardy)
Changed in tripleo:
importance: Undecided → High
status: New → Triaged
milestone: none → newton-2
assignee: nobody → Steven Hardy (shardy)
Steven Hardy (shardy)
tags: added: mitaka-backport-potential
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to python-tripleoclient (master)

Fix proposed to branch: master
Review: https://review.openstack.org/334598

Changed in tripleo:
status: Triaged → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to python-tripleoclient (master)

Reviewed: https://review.openstack.org/334598
Committed: https://git.openstack.org/cgit/openstack/python-tripleoclient/commit/?id=8de04ea66cbd7a79d2e88651ebff7cd2b16235a6
Submitter: Jenkins
Branch: master

commit 8de04ea66cbd7a79d2e88651ebff7cd2b16235a6
Author: Steven Hardy <email address hidden>
Date: Mon Jun 27 18:53:13 2016 +0100

    Don't pass None via UpdateIdentifier

    On intial deployment, don't pass None, because this fails validation
    inside nested heat templates which reference this parameter via
    parameter_defaults. Instead remove the assignment of UpdateIdentifer
    and rely on the defaults specified in the heat templates.

    Change-Id: Ia748c00fad86f933117030ffa3e7d0f3044ff66b
    Closes-Bug: #1596640

Changed in tripleo:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix proposed to python-tripleoclient (master)

Related fix proposed to branch: master
Review: https://review.openstack.org/336526

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix merged to python-tripleoclient (master)

Reviewed: https://review.openstack.org/336526
Committed: https://git.openstack.org/cgit/openstack/python-tripleoclient/commit/?id=88548d8742cd00c8a5a0b3c371af7a5cff5d5df3
Submitter: Jenkins
Branch: master

commit 88548d8742cd00c8a5a0b3c371af7a5cff5d5df3
Author: Jiri Stransky <email address hidden>
Date: Fri Jul 1 13:48:45 2016 +0200

    Unset UpdateIdentifier on deploy

    We stopped clearing UpdateIdentifier because setting it to None caused
    issues with template validation. However, this introduced a regression
    with regards to minor updates.

    We do patch stack-updates, which means that the UpdateIdentifer can
    persist from previous runs. This can cause unwanted minor update on a
    normal stack-update or on a scale-up, if the UpdateIdentifier is not
    empty. We could prevent it on normal stack-update via some means,
    e.g. persisting the last known update identifier value on the nodes and
    comparing that with current value from the parameter. However, working
    around this issue on scale-up would probably be considerably harder. A
    good way forward seems to be to explicitly unset UpdateIdentifier as we
    did before, but do it in a way that doesn't cause validation problems.

    Change-Id: I7f6e3a65bb1f44a42cc532a537f1067bee168142
    Closes-Bug: #1598124
    Related-Bug: #1567385
    Related-Bug: #1596640

Revision history for this message
Doug Hellmann (doug-hellmann) wrote : Fix included in openstack/python-tripleoclient 5.0.0.0b2

This issue was fixed in the openstack/python-tripleoclient 5.0.0.0b2 development milestone.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.