Package ubic.gemma.core.job
Class TaskCommand
- java.lang.Object
-
- ubic.gemma.core.job.TaskCommand
-
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
ArrayDesignProbeMapTaskCommand,ArrayDesignRepeatScanTaskCommand,BioAssayOutlierProcessingTaskCommand,CharacteristicUpdateCommand,CoexSearchTaskCommand,DifferentialExpressionAnalysisTaskCommand,DifferentialExpressionSearchTaskCommand,DiffExMetaAnalyzerTaskCommand,ExpressionExperimentDataFetchCommand,ExpressionExperimentLoadTaskCommand,ExpressionExperimentReportTaskCommand,IndexerTaskCommand,LinkAnalysisTaskCommand,PreprocessTaskCommand,SimpleExpressionExperimentMetaData,SvdTaskCommand,TwoChannelMissingValueTaskCommand,UpdateEEDetailsCommand,UpdatePubMedCommand
public class TaskCommand extends Object implements Serializable
This command class is used to allow communication of parameters for a task between a client and task running service, which might be on a different computer. This class can be used directly, or extended to create a command object to pass parameters for a specific task. See for exampleExpressionExperimentLoadTaskCommand. A entityId field is provided as a convenience for the case when a primary key is all that is really needed.- Author:
- keshav
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static intMAX_QUEUING_MINUTESHow long we will queue a task before giving up and cancelling it (default value)static intMAX_RUNTIME_MINUTES
-
Constructor Summary
Constructors Constructor Description TaskCommand()TaskCommand(Long entityId)Convenience constructor for case where all the job needs to know is the id.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description LonggetEntityId()IntegergetMaxQueueMinutes()intgetMaxRuntime()BooleangetPersistJobDetails()org.springframework.security.core.context.SecurityContextgetSecurityContext()StringgetSubmitter()Class<?>getTaskClass()StringgetTaskId()booleanisEmailAlert()voidsetEmailAlert(boolean emailAlert)voidsetEntityId(Long entityId)voidsetMaxQueueMinutes(Integer maxQueueMinutes)How long we will allow this task to be queued before giving up.voidsetMaxRuntime(int maxRuntime)voidsetPersistJobDetails(Boolean persistJobDetails)voidsetTaskId(String taskId)
-
-
-
Field Detail
-
MAX_RUNTIME_MINUTES
public static final int MAX_RUNTIME_MINUTES
- See Also:
- Constant Field Values
-
MAX_QUEUING_MINUTES
public static final int MAX_QUEUING_MINUTES
How long we will queue a task before giving up and cancelling it (default value)- See Also:
- Constant Field Values
-
-
Constructor Detail
-
TaskCommand
public TaskCommand()
-
TaskCommand
public TaskCommand(Long entityId)
Convenience constructor for case where all the job needs to know is the id.- Parameters:
entityId- entity id
-
-
Method Detail
-
getEntityId
public Long getEntityId()
-
setEntityId
public void setEntityId(Long entityId)
-
getMaxQueueMinutes
public Integer getMaxQueueMinutes()
-
setMaxQueueMinutes
public void setMaxQueueMinutes(Integer maxQueueMinutes)
How long we will allow this task to be queued before giving up. Default = TaskRunningService.MAX_QUEUING_MINUTES- Parameters:
maxQueueMinutes- max queue minutes
-
getMaxRuntime
public int getMaxRuntime()
- Returns:
- the maxRuntime in minutes
-
setMaxRuntime
public void setMaxRuntime(int maxRuntime)
- Parameters:
maxRuntime- the maxRuntime to set (in minutes) before we bail. Default is MAX_RUNTIME_MINUTES
-
getPersistJobDetails
public Boolean getPersistJobDetails()
- Returns:
- the persistJobDetails
-
setPersistJobDetails
public void setPersistJobDetails(Boolean persistJobDetails)
- Parameters:
persistJobDetails- the persistJobDetails to set
-
getSecurityContext
public org.springframework.security.core.context.SecurityContext getSecurityContext()
-
getSubmitter
public String getSubmitter()
- Returns:
- the submitter
-
getTaskClass
public Class<?> getTaskClass()
-
getTaskId
public String getTaskId()
-
setTaskId
public void setTaskId(String taskId)
- Parameters:
taskId- task id
-
isEmailAlert
public boolean isEmailAlert()
-
setEmailAlert
public void setEmailAlert(boolean emailAlert)
-
-