org.objectweb.perseus.distribution.api

Interface DistResControllerService

Known Implementing Classes:
JGroupsControllerService

public interface DistResControllerService

Copyright (C) 2003-2004 - France Telecom R&D This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA Release: 1.0 Authors: Olivier Lobry (olivier.lobry@rd.francetelecom.com)

Method Summary

void
copyCoordinationFrom(Object resId, Serializable nodeId)
Replicates the coordination of a resource from a remote node to the local one.
Vector
getCoordinators(Object resId)
Serializable
getNodeId()
Returns the id of the local node which can be sent in messages as it is serializable.
void
migrateCoordinationFrom(Object resId, Serializable nodeId)
Migrates the coordination of a resource from a remote node to the local one.

Method Details

copyCoordinationFrom

public void copyCoordinationFrom(Object resId,
                                 Serializable nodeId)
            throws NotCoordinatorException,
                   AlreadyCoordinatorException
Replicates the coordination of a resource from a remote node to the local one. This operation do preserve the guaranteed order of message delivery, so that the replication must be completely transparent to users and coordinators.

Parameters:
resId - the id of the related resource
nodeId - the id of the node from which the coordination is to be replicated

Throws:
NotCoordinatorException - if the designated node is not a coordinator
AlreadyCoordinatorException - if the local node is already a coordinator


getCoordinators

public Vector getCoordinators(Object resId)


getNodeId

public Serializable getNodeId()
Returns the id of the local node which can be sent in messages as it is serializable.

Returns:
the id of the local node


migrateCoordinationFrom

public void migrateCoordinationFrom(Object resId,
                                    Serializable nodeId)
            throws NotCoordinatorException,
                   AlreadyCoordinatorException
Migrates the coordination of a resource from a remote node to the local one. This operation do preserve the guaranteed order of message delivery, so that the migration must be completely transparent to users and coordinators.

Parameters:
resId - the id of the related resource
nodeId - id of the node from which the coordination is to be moved

Throws:
NotCoordinatorException - if the designated node is not a coord.
AlreadyCoordinatorException - if the local node is already a coordinator


Copyright © 2000-2002 France Telecom S.A., INRIA, IMAG-LSR All Rights Reserved.