All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.arjuna.mwlabs.wst11.ba.participants.CleanupSynchronization Maven / Gradle / Ivy

The newest version!
/*
   Copyright The Narayana Authors
   SPDX-License-Identifier: Apache-2.0
 */



package com.arjuna.mwlabs.wst11.ba.participants;

import com.arjuna.mw.wstx.logging.wstxLogger;
import com.arjuna.mwlabs.wst11.ba.RegistrarImple;

import com.arjuna.mw.wscf.model.sagas.participants.*;

import com.arjuna.mw.wsas.exceptions.SystemException;

/**
 * @author Mark Little ([email protected])
 * @version $Id: CleanupSynchronization.java,v 1.3 2005/05/19 12:13:42 nmcl Exp $
 * @since 1.0.
 */

public class CleanupSynchronization implements Synchronization
{

	public CleanupSynchronization(String cleanupId, RegistrarImple theRegistrar)
	{
		_cleanupId = cleanupId;
		_theRegistrar = theRegistrar;
	}

	public void afterCompletion (int status) throws SystemException
	{
		try
		{
			_theRegistrar.disassociate(_cleanupId);
		}
		catch (Exception ex)
		{
			wstxLogger.i18NLogger.warn_unexpectedExcpetion(ex);

			throw new SystemException(ex.toString());
		}
	}

	private String _cleanupId;

	private RegistrarImple _theRegistrar;

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy