org.gcube.common.vremanagement.deployer.impl.platforms
Class PlatformCall

java.lang.Object
  extended by org.gcube.common.vremanagement.deployer.impl.platforms.PlatformCall

public class PlatformCall
extends Object

An abstraction over a VirtualPlatform invocation

Author:
Manuele Simi (ISTI-CNR)

Constructor Summary
PlatformCall(org.gcube.vremanagement.virtualplatform.image.VirtualPlatform platform)
          Creates a new abstract call for the target platform
 
Method Summary
 void activate(DeployablePackage pack)
          Activates a package
 void activate(String name, String path)
          Activates a package given its name and application path
 void deactivate(String name, String path)
          Deactivates a package
 void deactivate(UndeployablePackage pack)
          Deactivates a package
 PlatformApplication deactivateAndUndeploy(UndeployablePackage pack)
           
 PlatformApplication deploy(DeployablePackage pack, List<File> files, List<String> endpoints)
          Deploys a package
 PlatformApplication deployAndActivate(DeployablePackage pack, List<File> files, List<String> endpoints)
          A wrapper around the #deploy(DeployablePackage) and activate(DeployablePackage) methods
 PlatformApplication undeploy(UndeployablePackage pack)
          Undeploys the package
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PlatformCall

public PlatformCall(org.gcube.vremanagement.virtualplatform.image.VirtualPlatform platform)
Creates a new abstract call for the target platform

Parameters:
platform - the platform to invoke in the objet's methods
Method Detail

deploy

public PlatformApplication deploy(DeployablePackage pack,
                                  List<File> files,
                                  List<String> endpoints)
                           throws Exception
Deploys a package

Parameters:
pack - the package to deploy
endpoints -
Returns:
Throws:
Exception

deployAndActivate

public PlatformApplication deployAndActivate(DeployablePackage pack,
                                             List<File> files,
                                             List<String> endpoints)
                                      throws Exception
A wrapper around the #deploy(DeployablePackage) and activate(DeployablePackage) methods

Parameters:
pack - the package to deploy and ativate
files - the list of files belonging the package
list - the endpoints as extracted from the package profile
Returns:
Throws:
Exception

activate

public void activate(DeployablePackage pack)
              throws Exception
Activates a package

Parameters:
pack - the package to activate
Throws:
Exception

activate

public void activate(String name,
                     String path)
              throws Exception
Activates a package given its name and application path

Parameters:
name - the package to activate
path - the path of the package to activate
Throws:
Exception

deactivate

public void deactivate(UndeployablePackage pack)
                throws Exception
Deactivates a package

Parameters:
pack - the package to deactivate
Throws:
Exception

deactivate

public void deactivate(String name,
                       String path)
                throws Exception
Deactivates a package

Parameters:
name - the name of the package to deactivate
path - the path of the package to deactivate
Throws:
Exception

undeploy

public PlatformApplication undeploy(UndeployablePackage pack)
                             throws Exception
Undeploys the package

Parameters:
pack - the package to undeploy
Returns:
Throws:
Exception

deactivateAndUndeploy

public PlatformApplication deactivateAndUndeploy(UndeployablePackage pack)
                                          throws Exception
Throws:
Exception


Copyright © 2012. All Rights Reserved.