org.ow2.petals.jbi.management.task.deployment.deploy
Class RetrieveSAAndSUInstallRootsTask

java.lang.Object
  extended by org.ow2.petals.jbi.management.task.deployment.deploy.RetrieveSAAndSUInstallRootsTask
All Implemented Interfaces:
Task

public class RetrieveSAAndSUInstallRootsTask
extends java.lang.Object
implements Task

This task retrieves the SA install root and all SUs install roots
Inputs : Jbi
Outputs : SA install root URI, SU install roots Map
The task has got a non-robust approach : it stops at the first subtask failed
and have the undo capability.

Author:
ofabre - EBM Websourcing, Frederic Gardes - eBM Websourcing

Field Summary
protected  RepositoryService repositoryService
          Platform Component :: Repository Service
 
Constructor Summary
RetrieveSAAndSUInstallRootsTask(RepositoryService repositoryService)
           
 
Method Summary
 void execute(Context context)
          Launch the task with the given context.
protected  java.util.Map<java.lang.String,java.net.URL> retrieveSUInstallUrls(java.net.URL saInstallUrl, org.ow2.petals.jbi.descriptor.original.generated.Jbi descriptor)
          Retrieve all SU installation root URI
 void undo(Context context)
          Reverse the task in order to retrieve the environ state before execution of this task.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

repositoryService

protected RepositoryService repositoryService
Platform Component :: Repository Service

Constructor Detail

RetrieveSAAndSUInstallRootsTask

public RetrieveSAAndSUInstallRootsTask(RepositoryService repositoryService)
Method Detail

execute

public void execute(Context context)
             throws java.lang.Exception
Description copied from interface: Task
Launch the task with the given context. Task can modify information included in this context during execution.

Specified by:
execute in interface Task
Parameters:
context - the execution context handling input and output information
Throws:
java.lang.Exception - if an error occurs during Task processing

retrieveSUInstallUrls

protected java.util.Map<java.lang.String,java.net.URL> retrieveSUInstallUrls(java.net.URL saInstallUrl,
                                                                             org.ow2.petals.jbi.descriptor.original.generated.Jbi descriptor)
                                                                      throws java.net.MalformedURLException
Retrieve all SU installation root URI

Parameters:
descriptor - the service assembly descriptor
installationRoot - the SA installation root URI
Returns:
the service unit install roots Map
Throws:
java.net.MalformedURLException
org.ow2.petals.kernel.api.server.PetalsException

undo

public void undo(Context context)
          throws java.lang.Exception
Description copied from interface: Task
Reverse the task in order to retrieve the environ state before execution of this task.

Specified by:
undo in interface Task
Parameters:
context - the execution context handling input and output information
Throws:
java.lang.Exception - if an error occurs during Task unprocessing


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