uk.ac.soton.ecs.iam.grid.client.staterepos
Class JobConversationImpl

java.lang.Object
  extended by uk.ac.soton.ecs.iam.grid.client.staterepos.JobConversationImpl
All Implemented Interfaces:
Comparable<StorableInStateRepository>, Conversation, DestroyableConversation, JobConversation, StorableInStateRepository, JobResource, WSResourceLifetime, PolicyManagement, ResourceMetadata, Signallable

Deprecated. - see RemoteResourceProxy

@Deprecated
public class JobConversationImpl
extends Object
implements JobConversation

The default implementation of JobConversation.


Field Summary
 
Fields inherited from interface uk.ac.soton.ecs.iam.grid.comms.client.JobConversation
IO_TYPE_INPUT, IO_TYPE_METADATA, IO_TYPE_OUTPUT, JOB_RESOURCE_TYPE
 
Constructor Summary
JobConversationImpl(StateRepository repository, org.apache.axis.message.addressing.EndpointReferenceType EPR)
          Deprecated.  
 
Method Summary
 void addPolicyRule(PolicyRule rule)
          Deprecated. Add an access control rule to this resource's dynamic access control policy.
 void addStagersFromJSDL(JobDescription jsdlJobDesc)
          Deprecated. Add each input or output in status to our internal cache.
 void addStagersFromStatus(JobStatus status)
          Deprecated. Add each input or output in status to our internal cache.
 void cancelJob()
          Deprecated. Cancel a job that has been started.
 JobStatus checkJob()
          Deprecated. Check the current status of a job.
 int compareTo(StorableInStateRepository other)
          Deprecated.  
 void destroy()
          Deprecated.  
 void finish()
          Deprecated. Indicate that this conversation is no longer required.
 void finishJob()
          Deprecated. Finish the job conversation.
 List<String> getArguments()
          Deprecated.  
 String[] getAvailableSignals()
          Deprecated. List the signals which are available given the resource's current state.
 StorableInStateRepository[] getChildConversations()
          Deprecated. Returns an array of all conversations having this one as a parent.
 String getDescription()
          Deprecated. Returns a textual description of the object.
 org.apache.axis.message.addressing.EndpointReferenceType getEndpointRef()
          Deprecated. Return an EndpointReferenceType for this conversation.
 org.apache.axis.message.addressing.EndpointReferenceType getEPR()
          Deprecated. Get the EPR for this resource.
 DataConversation[] getInputs()
          Deprecated. Returns the job's input stagers, in order.
 Class getInterface()
          Deprecated. Returns the type of this object.
 String getJSDL()
          Deprecated. Retrieves the original JSDL Document used to create the job
 DataConversation[] getOutputs()
          Deprecated. Returns the job's output stagers, in order.
 URL getParentURL()
          Deprecated. Returns the URL of this object's parent.
 PolicyRule[] getPolicyRules()
          Deprecated. Get the access control rules in this resource's dynamic access control policy.
 StateRepository getRepository()
          Deprecated. Get the StateRepository holding this object.
 RemoteService getService()
          Deprecated. Return the conversation's RemoteService.
 URL getURL()
          Deprecated. Returns the globally unique identifier.
 String[] getValidRoles()
          Deprecated. List the roles the caller is permitted to see.
 DataConversation input(String name)
          Deprecated. Get the named input conversation.
 boolean isFinished()
          Deprecated. Returns true if the finish method has been called.
 void outOfDate()
          Deprecated. Used by the StateRepository if the server returns new resource with our ID.
 DataConversation output(String name)
          Deprecated. Get the named output conversation.
 void removePolicyRule(PolicyRule rule)
          Deprecated. Remove an access control rule from this resource's dynamic access control policy.
 void setArguments(List<String> arguments)
          Deprecated.  
 void setDescription(String description)
          Deprecated. Change the textual description, as returned by getDescription.
 void setLabel(String label)
          Deprecated. Change the resource's label.
 String signal(String signalName)
          Deprecated. Signal an event to the resource's PBAC process.
 void startJob(String[] args)
          Deprecated. - use submitJob(org.w3c.dom.Document, java.lang.String[]).
 boolean stillActive()
          Deprecated. Tests whether the job is running (or queued).
 boolean stillActive(JobStatus jobStatus)
          Deprecated. Like stillActive(), but takes the status returned by checkJob as input instead of performing checkJob operation itself.
 void submitJob(Document jobDescription, String[] args)
          Deprecated. 
 void submitJobJSDL()
          Deprecated. Submit the job (already defined by a JSDL document) to the queue, via the platform scripts.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JobConversationImpl

public JobConversationImpl(StateRepository repository,
                           org.apache.axis.message.addressing.EndpointReferenceType EPR)
                    throws ObjectAlreadyExists
Deprecated. 
Throws:
ObjectAlreadyExists
Method Detail

outOfDate

public void outOfDate()
Deprecated. 
Description copied from interface: Conversation
Used by the StateRepository if the server returns new resource with our ID.

Specified by:
outOfDate in interface Conversation

getChildConversations

public StorableInStateRepository[] getChildConversations()
Deprecated. 
Description copied from interface: Conversation
Returns an array of all conversations having this one as a parent.

Specified by:
getChildConversations in interface Conversation

finish

public void finish()
Deprecated. 
Description copied from interface: Conversation
Indicate that this conversation is no longer required. It will be removed from the StateRepository. No other methods on a Conversation can be called once finish() has been invoked.

Note that this does not close the conversation with the remote supplier. You should normally call a different method, such as WSResourceLifetime.destroy().

Specified by:
finish in interface Conversation

isFinished

public boolean isFinished()
Deprecated. 
Description copied from interface: Conversation
Returns true if the finish method has been called.

Specified by:
isFinished in interface Conversation

getURL

public URL getURL()
Deprecated. 
Description copied from interface: StorableInStateRepository
Returns the globally unique identifier. No two distinct objects may have the same URL, even if they have different types.

Specified by:
getURL in interface StorableInStateRepository

getParentURL

public URL getParentURL()
Deprecated. 
Description copied from interface: StorableInStateRepository
Returns the URL of this object's parent. Returns null if this is a top-level (service) object.

Specified by:
getParentURL in interface StorableInStateRepository

getEPR

public org.apache.axis.message.addressing.EndpointReferenceType getEPR()
Deprecated. 
Description copied from interface: ResourceMetadata
Get the EPR for this resource. The EPR gives the canonical endpoint for the service, and various meta-data items.

Specified by:
getEPR in interface ResourceMetadata
See Also:
the label set with {@link setLabel}, a unique type URI, the state of the resource, the resource which manages this one (e.g. an SLA manages a job), the resource which contains this one (e.g. a job service is the parent of a job)

getEndpointRef

public org.apache.axis.message.addressing.EndpointReferenceType getEndpointRef()
Deprecated. 
Description copied from interface: StorableInStateRepository
Return an EndpointReferenceType for this conversation. This contains both the endpoint address of the service, and the resource itself.

Specified by:
getEndpointRef in interface StorableInStateRepository

getRepository

public StateRepository getRepository()
Deprecated. 
Description copied from interface: StorableInStateRepository
Get the StateRepository holding this object.

Specified by:
getRepository in interface StorableInStateRepository

getDescription

public String getDescription()
Deprecated. 
Description copied from interface: StorableInStateRepository
Returns a textual description of the object. This can be presented to the user when choosing from a list, for example.

Specified by:
getDescription in interface StorableInStateRepository

setDescription

public void setDescription(String description)
Deprecated. 
Description copied from interface: StorableInStateRepository
Change the textual description, as returned by getDescription.

Specified by:
setDescription in interface StorableInStateRepository

compareTo

public int compareTo(StorableInStateRepository other)
Deprecated. 
Specified by:
compareTo in interface Comparable<StorableInStateRepository>

getInterface

public Class getInterface()
Deprecated. 
Description copied from interface: StorableInStateRepository
Returns the type of this object. When loading the object, a StateRepository locates a class implementing the interface and uses that for the object.

Specified by:
getInterface in interface StorableInStateRepository

startJob

@Deprecated
public void startJob(String[] args)
              throws RemoteException
Deprecated. - use submitJob(org.w3c.dom.Document, java.lang.String[]).

Specified by:
startJob in interface JobResource
Throws:
RemoteException

submitJob

@Deprecated
public void submitJob(Document jobDescription,
                                 String[] args)
               throws RemoteException
Deprecated. 

Specified by:
submitJob in interface JobResource
Parameters:
jobDescription - job constraints to be passed to the platform scripts
args - arguments to pass to the application
Throws:
RemoteException

submitJobJSDL

public void submitJobJSDL()
                   throws RemoteException
Deprecated. 
Description copied from interface: JobResource
Submit the job (already defined by a JSDL document) to the queue, via the platform scripts. All inputs must already have been uploaded before this is called. Job execution is controlled by the underlying resource manager.

Specified by:
submitJobJSDL in interface JobResource
Throws:
RemoteException

stillActive

public boolean stillActive()
                    throws RemoteException
Deprecated. 
Description copied from interface: JobConversation
Tests whether the job is running (or queued). This should be polled from time to time to discover when the job is complete. This is a convenience wrapper around the JobResource.checkJob() method.

Specified by:
stillActive in interface JobConversation
Returns:
true if polling should continue
Throws:
RemoteException

stillActive

public boolean stillActive(JobStatus jobStatus)
Deprecated. 
Description copied from interface: JobConversation
Like stillActive(), but takes the status returned by checkJob as input instead of performing checkJob operation itself.

Specified by:
stillActive in interface JobConversation

checkJob

public JobStatus checkJob()
                   throws RemoteException
Deprecated. 
Description copied from interface: JobResource
Check the current status of a job.

Specified by:
checkJob in interface JobResource
Returns:
The current status of the job
Throws:
RemoteException

addStagersFromStatus

public void addStagersFromStatus(JobStatus status)
Deprecated. 
Description copied from interface: JobConversation
Add each input or output in status to our internal cache. This saves having to call checkData() later to get them.

Specified by:
addStagersFromStatus in interface JobConversation

addStagersFromJSDL

public void addStagersFromJSDL(JobDescription jsdlJobDesc)
Deprecated. 
Description copied from interface: JobConversation
Add each input or output in status to our internal cache. This saves having to call checkData() later to get them.

Specified by:
addStagersFromJSDL in interface JobConversation

cancelJob

public void cancelJob()
               throws RemoteException
Deprecated. 
Description copied from interface: JobResource
Cancel a job that has been started.

Specified by:
cancelJob in interface JobResource
Throws:
RemoteException

finishJob

public void finishJob()
               throws RemoteException
Deprecated. 
Description copied from interface: JobResource
Finish the job conversation.

Specified by:
finishJob in interface JobResource
Throws:
RemoteException

getService

public RemoteService getService()
Deprecated. 
Description copied from interface: Conversation
Return the conversation's RemoteService.

Specified by:
getService in interface Conversation

getInputs

public DataConversation[] getInputs()
                             throws RemoteException
Deprecated. 
Description copied from interface: JobConversation
Returns the job's input stagers, in order. Upload data to these stagers before starting the job.

Specified by:
getInputs in interface JobConversation
Throws:
RemoteException

getOutputs

public DataConversation[] getOutputs()
                              throws RemoteException
Deprecated. 
Description copied from interface: JobConversation
Returns the job's output stagers, in order. Download data from these stagers once checkJob() returns a status of "job-terminated".

Specified by:
getOutputs in interface JobConversation
Throws:
RemoteException

input

public DataConversation input(String name)
                       throws RemoteException,
                              NoSuchConversation
Deprecated. 
Description copied from interface: JobConversation
Get the named input conversation. This may invoke checkJob() if the inputs are not currently known.

Specified by:
input in interface JobConversation
Returns:
the input stager with the given name
Throws:
NoSuchConversation - if no stager with this name is known
RemoteException

output

public DataConversation output(String name)
                        throws RemoteException,
                               NoSuchConversation
Deprecated. 
Description copied from interface: JobConversation
Get the named output conversation. This may invoke checkJob() if the outputs are not currently known.

Specified by:
output in interface JobConversation
Returns:
the output stager with the given name
Throws:
NoSuchConversation - if no stager with this name is known
RemoteException

getValidRoles

public String[] getValidRoles()
                       throws RemoteException
Deprecated. 
Description copied from interface: PolicyManagement
List the roles the caller is permitted to see. This is the list of roles whose rules are returned by PolicyManagement.getPolicyRules().

Specified by:
getValidRoles in interface PolicyManagement
Throws:
RemoteException
See Also:
PDP.getValidProcessRoles(java.lang.String)

addPolicyRule

public void addPolicyRule(PolicyRule rule)
                   throws RemoteException
Deprecated. 
Description copied from interface: PolicyManagement
Add an access control rule to this resource's dynamic access control policy.

Specified by:
addPolicyRule in interface PolicyManagement
Throws:
RemoteException
See Also:
PDP.addAccessControlRule(java.lang.String, uk.ac.soton.itinnovation.grid.types.MatchRule)

removePolicyRule

public void removePolicyRule(PolicyRule rule)
                      throws RemoteException
Deprecated. 
Description copied from interface: PolicyManagement
Remove an access control rule from this resource's dynamic access control policy.

Specified by:
removePolicyRule in interface PolicyManagement
Throws:
RemoteException
See Also:
PDP.removeAccessControlRule(java.lang.String, uk.ac.soton.itinnovation.grid.types.MatchRule)

getPolicyRules

public PolicyRule[] getPolicyRules()
                            throws RemoteException
Deprecated. 
Description copied from interface: PolicyManagement
Get the access control rules in this resource's dynamic access control policy. Rules are only returned for the roles the caller is permitted to see. Note: The rules are filtered to only include those for roles listed by PolicyManagement.getValidRoles().

Specified by:
getPolicyRules in interface PolicyManagement
Throws:
RemoteException
See Also:
PDP.getAccessControlRules(java.lang.String, java.lang.String)

setLabel

public void setLabel(String label)
              throws RemoteException
Deprecated. 
Description copied from interface: ResourceMetadata
Change the resource's label. Each resource is given a label by the client when it is created. This label is returned in the metadata from getResources, making it easier for other users to identify the resource.

Specified by:
setLabel in interface ResourceMetadata
Parameters:
label - the new label
Throws:
RemoteException

destroy

public void destroy()
             throws RemoteException
Deprecated. 
Specified by:
destroy in interface WSResourceLifetime
Throws:
RemoteException

signal

public String signal(String signalName)
              throws RemoteException
Deprecated. 
Description copied from interface: Signallable
Signal an event to the resource's PBAC process. The process state may be updated in response to this, according to the service policy.

Specified by:
signal in interface Signallable
Parameters:
signalName - the event causing the transition
Returns:
the new state of the resource
Throws:
RemoteException

getAvailableSignals

public String[] getAvailableSignals()
                             throws RemoteException
Deprecated. 
Description copied from interface: Signallable
List the signals which are available given the resource's current state.

Specified by:
getAvailableSignals in interface Signallable
Returns:
the list of possible signals
Throws:
RemoteException
See Also:
Signallable.signal(java.lang.String)

getArguments

public List<String> getArguments()
Deprecated. 

setArguments

public void setArguments(List<String> arguments)
Deprecated. 

getJSDL

public String getJSDL()
               throws RemoteException
Deprecated. 
Description copied from interface: JobResource
Retrieves the original JSDL Document used to create the job

Specified by:
getJSDL in interface JobResource
Throws:
RemoteException


Copyright © 2001-2007 University of Southampton IT Innovation Centre. All Rights Reserved.