org.ow2.petals.communication.topology
Interface TopologyService

All Known Implementing Classes:
TopologyServiceImpl

public interface TopologyService

Since:
Petals 2.0
Author:
Roland NAUDIN - eBMWebSourcing, chamerling

Method Summary
 void addContainerConfiguration(ContainerConfiguration addedContainer)
          Add the given container to the topology
 void addSubdomainConfiguration(SubDomainConfiguration addedSubdomain)
          Add a subdomain to the local topology.
 ContainerConfiguration getContainerConfiguration(java.lang.String containerName)
          Get the container configuration of the given container name.
 java.util.Set<ContainerConfiguration> getContainersConfiguration(ContainerConfiguration.ContainerState state)
          Get all the containers where the state is the same than the given one.
 java.util.Set<ContainerConfiguration> getContainersConfigurationsForLocalSubdomain()
           
 DomainConfiguration getDomainConfiguration()
          Get the domain configuration.
 java.util.Set<SubDomainConfiguration> getSubDomainsConfiguration()
          Get all the sub-domain configurations.
 boolean hasValidLocalContainerDynamicTopologyConfiguration()
           
 boolean isContainerStarted(java.lang.String containerName)
          Test if the container is started.
 void registerLocalContainerOnMaster()
           
 void removeContainerConfiguration(ContainerConfiguration removedContainer)
          Remove container configuration.
 void removeSubdomainConfiguration(java.lang.String removedSubdomainName)
          Remove subdomain configuration.
 void setContainerState(java.lang.String containerName, ContainerConfiguration.ContainerState state)
          Set the given state to the give container.
 void updateTopology()
          Update the local view of the topology.
 void validateDynamicTopology()
          Validate the dynamic topology.
 

Method Detail

hasValidLocalContainerDynamicTopologyConfiguration

boolean hasValidLocalContainerDynamicTopologyConfiguration()

addContainerConfiguration

void addContainerConfiguration(ContainerConfiguration addedContainer)
                               throws org.ow2.petals.kernel.api.server.PetalsException
Add the given container to the topology

Parameters:
addedContainer - the container to add to the current topology
Throws:
org.ow2.petals.kernel.api.server.PetalsException - Failed to add the container to the current topology

addSubdomainConfiguration

void addSubdomainConfiguration(SubDomainConfiguration addedSubdomain)
                               throws org.ow2.petals.kernel.api.server.PetalsException
Add a subdomain to the local topology.

Parameters:
addedSubdomain -
Throws:
org.ow2.petals.kernel.api.server.PetalsException

getContainerConfiguration

ContainerConfiguration getContainerConfiguration(java.lang.String containerName)
Get the container configuration of the given container name.

Parameters:
containerName - The name of the targeted container
Returns:
The container configuration

getContainersConfiguration

java.util.Set<ContainerConfiguration> getContainersConfiguration(ContainerConfiguration.ContainerState state)
Get all the containers where the state is the same than the given one. If the state is null, get all the containers...

Parameters:
object -
Returns:

getContainersConfigurationsForLocalSubdomain

java.util.Set<ContainerConfiguration> getContainersConfigurationsForLocalSubdomain()

getDomainConfiguration

DomainConfiguration getDomainConfiguration()
Get the domain configuration.

Returns:
the domain configuration

getSubDomainsConfiguration

java.util.Set<SubDomainConfiguration> getSubDomainsConfiguration()
Get all the sub-domain configurations.

Returns:
a set of ContainerConfiguration

isContainerStarted

boolean isContainerStarted(java.lang.String containerName)
Test if the container is started.

Parameters:
containerName -
Returns:

registerLocalContainerOnMaster

void registerLocalContainerOnMaster()
                                    throws org.ow2.petals.kernel.api.server.PetalsException
Throws:
org.ow2.petals.kernel.api.server.PetalsException

removeContainerConfiguration

void removeContainerConfiguration(ContainerConfiguration removedContainer)
                                  throws ConfigurationException
Remove container configuration.

Parameters:
removedContainer -
Throws:
ConfigurationException

removeSubdomainConfiguration

void removeSubdomainConfiguration(java.lang.String removedSubdomainName)
                                  throws ConfigurationException
Remove subdomain configuration.

Parameters:
removedSubdomain -
Throws:
ConfigurationException

setContainerState

void setContainerState(java.lang.String containerName,
                       ContainerConfiguration.ContainerState state)
Set the given state to the give container.

Parameters:
containerName -
state - The ontainerConfiguration.ContainerState

updateTopology

void updateTopology()
                    throws org.ow2.petals.kernel.api.server.PetalsException
Update the local view of the topology.

Throws:
org.ow2.petals.kernel.api.server.PetalsException

validateDynamicTopology

void validateDynamicTopology()
                             throws ConfigurationException
Validate the dynamic topology.

Throws:
ConfigurationException


Copyright © 2005-2011 Petals Link (EBM Websourcing). All Rights Reserved.