JAC project
AOPSYS
CEDRIC & LIP6 labs

org.objectweb.jac.aspects.distribution
Interface DeploymentConf

All Known Implementing Classes:
DeploymentAC

public interface DeploymentConf

This aspect is configuration interface of the Deployment aspect.

Author:
Renaud Pawlak
See Also:
DeploymentAC, DeploymentRule

Method Summary
 void createAsynchronousStubsFor(String name, String serverHost, String hosts)
          This configuration method creates the stubs with an asynchronous type (org.objectweb.jac.core.dist.NonBlockingStubWrapper).
 void createStubsFor(String name, String serverHost, String hosts)
          This configuration method creates the stubs with the default type (org.objectweb.jac.core.dist.StubWrapper).
 void createTypedStubsFor(String name, String serverHost, String hosts, String stubType)
          This configuration method creates remote-access stubs for the object called name on all the client-hosts defined by the hosts expression.
 void deploy(String deploymentHost, String nameRegexp, String containerName)
          This configuration method creates a deployment rule that tells that the objects that match are deployed on a given remote container.
 void replicate(String deploymentHost, String nameRegexp, String contRegexp)
          This configuration method creates a deployment rule that replicates an original object on a set of containers.
 void setParametersPassingMode(MethodItem method, Boolean[] refs)
          Defines the passing mode of the parameters for a given method.
 void setTransient(ClassItem classItem, String fieldName)
          This configuration method sets a field to be transient.
 

Method Detail

deploy

public void deploy(String deploymentHost,
                   String nameRegexp,
                   String containerName)
This configuration method creates a deployment rule that tells that the objects that match are deployed on a given remote container.

Parameters:
deploymentHost - the host from where the objects are deployed
nameRegexp - all the objects for which the name will match this pattern will be deployed with this rule
containerName - the container that will hold the objects

replicate

public void replicate(String deploymentHost,
                      String nameRegexp,
                      String contRegexp)
This configuration method creates a deployment rule that replicates an original object on a set of containers.

Parameters:
deploymentHost - the host from where the objects are deployed
nameRegexp - all the objects for which the name will match this regular expression will be replicated
contRegexp - identifies the containers that will hold the replication group (one replica per container)

createTypedStubsFor

public void createTypedStubsFor(String name,
                                String serverHost,
                                String hosts,
                                String stubType)
This configuration method creates remote-access stubs for the object called name on all the client-hosts defined by the hosts expression.

Parameters:
name - the name of the object the stubs are created for
serverHost - the name of the container the server is located
hosts - an expression telling where the stubs are deployed
stubType - the type of the stub (a StubWrapper subclass)

createStubsFor

public void createStubsFor(String name,
                           String serverHost,
                           String hosts)
This configuration method creates the stubs with the default type (org.objectweb.jac.core.dist.StubWrapper).

Parameters:
name - the name of the object the stubs are created for
serverHost - the name of the container the server is located
hosts - an expression telling where the stubs are deployed

createAsynchronousStubsFor

public void createAsynchronousStubsFor(String name,
                                       String serverHost,
                                       String hosts)
This configuration method creates the stubs with an asynchronous type (org.objectweb.jac.core.dist.NonBlockingStubWrapper).

Parameters:
name - the name of the object the stubs are created for
serverHost - the name of the container the server is located
hosts - an expression telling where the stubs are deployed

setTransient

public void setTransient(ClassItem classItem,
                         String fieldName)
This configuration method sets a field to be transient.

Parameters:
classItem - the class item of the field
fieldName - the field name

setParametersPassingMode

public void setParametersPassingMode(MethodItem method,
                                     Boolean[] refs)
Defines the passing mode of the parameters for a given method.

When a method is fowarded to a remote host by a stub (wrapper), the parameters of this method can be passed by value (then the whole object is serialized on the local host and deserialized on the remote host) or by reference (then the object's state is not serialized and it is bounded to a remote object on the remote host).

Parameters:
method - the method that holds the parameters
refs - TRUE or FALSE for each parameter... by default, the parameters are passed by value

Contact JAC development team:
Renaud Pawlak
Lionel Seinturier
Laurent Martelli