Skip to content

Backport of Do not add orphan nodes for deposed instances into v1.3#32675

Merged
alisdair merged 1 commit intov1.3from
backport/alisdair/do-not-add-orphan-nodes-for-deposed-instances/newly-apt-lionfish
Feb 13, 2023
Merged

Backport of Do not add orphan nodes for deposed instances into v1.3#32675
alisdair merged 1 commit intov1.3from
backport/alisdair/do-not-add-orphan-nodes-for-deposed-instances/newly-apt-lionfish

Conversation

@ghost
Copy link
Copy Markdown

@ghost ghost commented Feb 13, 2023

Backport

This PR is auto-generated from #32664 to be assessed for backporting due to the inclusion of the label 1.3-backport.

The below text is copied from the body of the original PR.


Resource instances with no current object in state should not have orphan nodes added to the graph, as deposed objects are handled separately. This was previously handled correctly for the non-expanded case, but expanded resources were missing the appropriate check for a current object.

Also update the comment in the non-expanded case to hopefully clarify that we're checking for the presence of a current object, not the absence of any deposed objects. An instance may have both a current object and zero or more deposed objects in some circumstances, and if so, we still want an orphan node to be added if the instance is not in configuration.

Fixes #32645 (probably; we don't have a full reproduction to validate this)

See also #32663, for another approach to a fix for the same reported issue.

Target Release

1.3.x

Since this also probably fixes the panic found in the above issue, it's worth considering for a future 1.3 release.

Draft CHANGELOG entry

BUG FIXES

  • Fix crash when planning to remove already-deposed resource instances.

@ghost ghost force-pushed the backport/alisdair/do-not-add-orphan-nodes-for-deposed-instances/newly-apt-lionfish branch from a46c4c7 to 93f907a Compare February 13, 2023 14:51
@ghost ghost requested a review from alisdair February 13, 2023 14:51
@ghost ghost force-pushed the backport/alisdair/do-not-add-orphan-nodes-for-deposed-instances/newly-apt-lionfish branch from 96cf071 to 5e2825b Compare February 13, 2023 14:51
@alisdair alisdair merged commit 143c66d into v1.3 Feb 13, 2023
@alisdair alisdair deleted the backport/alisdair/do-not-add-orphan-nodes-for-deposed-instances/newly-apt-lionfish branch February 13, 2023 15:01
@github-actions
Copy link
Copy Markdown
Contributor

Reminder for the merging maintainer: if this is a user-visible change, please update the changelog on the appropriate release branch.

@github-actions
Copy link
Copy Markdown
Contributor

I'm going to lock this pull request because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active contributions.
If you have found a problem that seems related to this change, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 16, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant