Terminate Workflow

At the end of the subscription lifecycle, the terminate workflow updates all OSS and BSS accordingly, and the @terminate_workflow decorator takes care of most of the necessary subscription administration.

@terminate_workflow("Terminate node",
initial_input_form=initial_input_form_generator)
def terminate_node() -> StepList:
    return (
        begin
        >> load_initial_state
        >> delete_node_from_ims
        >> deprovision_node_in_nrm
    )
  1. Show subscription details and ask user to confirm termination (initial_input_form)
  2. Necessary subscription administration (@terminate_workflow):
    1. Register terminate process for this subscription
    2. Set subscription ‘out of sync’ to prevent the start of other processes
  3. Get subscription and add information for following steps to the State (load_initial_state)
  4. Interact with OSS and/or BSS, in this example
    1. Delete node in IMS (delete_node_in ims)
    2. Deprovision node in NRM (deprovision_node_in_nrm)
  5. Necessary subscription administration (@terminate_workflow)
    1. Transition subscription to terminated
    2. Set subscription ‘in sync’

The initial input form for the terminate workflow is very simple, it only has to show the details of the subscription:

class TerminateForm(FormPage):
    subscription_id: DisplaySubscription = subscription_id