public class Deployment extends Object
Modifier and Type | Class and Description |
---|---|
static class |
Deployment.Status |
Modifier and Type | Field and Description |
---|---|
protected ChangeSet |
changeSet |
protected ZonedDateTime |
end |
protected Lock |
lock |
protected Map<String,Object> |
params |
protected List<ProcessorExecution> |
processorExecutions |
protected ZonedDateTime |
start |
protected Deployment.Status |
status |
protected Target |
target |
Constructor and Description |
---|
Deployment(Target target) |
Deployment(Target target,
Map<String,Object> params) |
Modifier and Type | Method and Description |
---|---|
void |
addParam(String name,
Object value)
Adds a param that can be used by processors during the deployment.
|
void |
addProcessorExecution(ProcessorExecution status)
Adds a
ProcessorExecution to the list. |
void |
end(Deployment.Status status)
Ends the deployment with the specified status.
|
ChangeSet |
getChangeSet()
Returns the change set of the deployment.
|
Long |
getDuration()
Returns the duration of the deployment.
|
ZonedDateTime |
getEnd()
Returns the end date of the deployment.
|
Object |
getParam(String name)
Returns a param that can be used by processors during the deployment.
|
List<ProcessorExecution> |
getProcessorExecutions()
Returns the list of
ProcessorExecution s. |
ZonedDateTime |
getStart()
Returns the start date of the deployment.
|
Deployment.Status |
getStatus()
Returns the status of the deployment, either success or failure.
|
Target |
getTarget()
Returns the
Target being deployed. |
boolean |
isChangeSetEmpty()
Returns true if the change set is null or empty.
|
boolean |
isRunning()
Returns true if the deployment is still running.
|
void |
removeParam(String name)
Removes the specified param
|
void |
setChangeSet(ChangeSet changeSet)
Sets the change set of the deployment.
|
void |
start()
Starts the deployment.
|
String |
toString() |
protected Target target
protected volatile ZonedDateTime start
protected volatile ZonedDateTime end
protected volatile Deployment.Status status
protected volatile ChangeSet changeSet
protected List<ProcessorExecution> processorExecutions
protected Lock lock
public Deployment(Target target)
public ZonedDateTime getStart()
public ZonedDateTime getEnd()
public boolean isRunning()
public Long getDuration()
public Deployment.Status getStatus()
public ChangeSet getChangeSet()
public void setChangeSet(ChangeSet changeSet)
public boolean isChangeSetEmpty()
public void start()
public void end(Deployment.Status status)
public List<ProcessorExecution> getProcessorExecutions()
ProcessorExecution
s.public void addProcessorExecution(ProcessorExecution status)
ProcessorExecution
to the list.public void addParam(String name, Object value)
name
- the name of the paramvalue
- the value of the parampublic Object getParam(String name)
name
- the name of the parampublic void removeParam(String name)
name
- the name of the paramCopyright © 2021. All rights reserved.