Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

ACM-R currently doesn’t revert back the element properties to their previous values if migration fails. Also, if there are new elements added or an element removed in the migration request, those elements will be added/removed in the database before the migration is performed by the participant. This behavior should be improved with a rollback mechanism in the event of failure.

Scenario

Drawio
mVer2
zoom1
simple0

...

inComment

...

0

...

custContentId

...

98009883
pageId97977061

...

lbox

...

1
diagramDisplayNameUntitled Diagram-1737365907906.drawio

...

...

contentVer1
revision1
baseUrlhttps://lf-onap.atlassian.net/wiki
diagramNameUntitled Diagram-1737365907906.drawio
pCenter0
width534
links
tbstyle
height641

Implementation

ACM-R:

  • add support to store in/out properties as copy before trigger migrate/update

  • add new endpoint for rollback

  • add validation for rollback endpoint: rollback can be triggered when the instance is in DeployState as MIGRATING/UPDATING and StateChangeResult as FAILED

Participant-intermediary:

  • add rollback support

  • example of rollback method

Code Block
languagejava
    void rollback(CompositionElementDto compositionElement,
         InstanceElementDto instanceElement) throws PfModelException;

Note

  • Rollback is supposed to support only migration/update fail scenario.

  • Should rollback support stage?