'Abandon a given stack.
:param cnxt: RPC context.
:param stack_identity: Name of the stack you want to abandon.
:param abandon: Delete Heat stack but not physical resources.'

@context.request_context
def abandon_stack(self, cnxt, stack_identity, abandon=True):

    if (not cfg.CONF.enable_stack_abandon):
        raise exception.NotSupported(feature='Stack    Abandon')
    def _stack_abandon(stk, abandon):
        if abandon:
            LOG.info('abandoning    stack    %s', stk.name)
            stk.delete(abandon=abandon)
        else:
            LOG.info('exporting    stack    %s', stk.name)
    st = self._get_stack(cnxt, stack_identity)
    stack = parser.Stack.load(cnxt, stack=st)
    lock = stack_lock.StackLock(cnxt, stack.id, self.engine_id)
    with lock.thread_lock():
        stack_info = stack.prepare_abandon()
        self.thread_group_mgr.start_with_acquired_lock(stack, lock, _stack_abandon, stack, abandon)
        return stack_info
