Class ProcessApplicationDeploymentBuilderImpl
- java.lang.Object
-
- org.camunda.bpm.engine.impl.repository.DeploymentBuilderImpl
-
- org.camunda.bpm.engine.impl.repository.ProcessApplicationDeploymentBuilderImpl
-
- All Implemented Interfaces:
Serializable
,DeploymentBuilder
,ProcessApplicationDeploymentBuilder
public class ProcessApplicationDeploymentBuilderImpl extends DeploymentBuilderImpl implements ProcessApplicationDeploymentBuilder
- Author:
- Daniel Meyer
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected boolean
isResumePreviousVersions
protected ProcessApplicationReference
processApplicationReference
protected String
resumePreviousVersionsBy
-
Fields inherited from class org.camunda.bpm.engine.impl.repository.DeploymentBuilderImpl
deployChangedOnly, deployment, deploymentResourcesById, deploymentResourcesByName, deployments, isDuplicateFilterEnabled, nameFromDeployment, processDefinitionsActivationDate, repositoryService
-
-
Constructor Summary
Constructors Constructor Description ProcessApplicationDeploymentBuilderImpl(RepositoryServiceImpl repositoryService, ProcessApplicationReference reference)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ProcessApplicationDeploymentBuilderImpl
activateProcessDefinitionsOn(Date date)
Sets the date on which the process definitions contained in this deployment will be activated.ProcessApplicationDeploymentBuilderImpl
addClasspathResource(String resource)
ProcessApplicationDeploymentBuilderImpl
addDeploymentResourceById(String deploymentId, String resourceId)
A given resource specified by id and deployment id will be added to the new deployment to re-deploy the given resource.ProcessApplicationDeploymentBuilderImpl
addDeploymentResourceByName(String deploymentId, String resourceName)
A given resource specified by name and deployment id will be added to the new deployment to re-deploy the given resource.ProcessApplicationDeploymentBuilderImpl
addDeploymentResources(String deploymentId)
All existing resources contained by the given deployment will be added to the new deployment to re-deploy them.ProcessApplicationDeploymentBuilderImpl
addDeploymentResourcesById(String deploymentId, List<String> resourceIds)
All given resources specified by id and deployment id will be added to the new deployment to re-deploy the given resource.ProcessApplicationDeploymentBuilderImpl
addDeploymentResourcesByName(String deploymentId, List<String> resourceNames)
All given resources specified by name and deployment id will be added to the new deployment to re-deploy the given resource.ProcessApplicationDeploymentBuilderImpl
addInputStream(String resourceName, InputStream inputStream)
ProcessApplicationDeploymentBuilderImpl
addModelInstance(String resourceName, BpmnModelInstance modelInstance)
Adds a BPMN model to the deployment.ProcessApplicationDeploymentBuilderImpl
addString(String resourceName, String text)
ProcessApplicationDeploymentBuilderImpl
addZipInputStream(ZipInputStream zipInputStream)
ProcessApplicationDeployment
deploy()
Deploys all provided sources to the process engine and returns the created deployment.ProcessApplicationDeploymentBuilderImpl
enableDuplicateFiltering()
If set, this deployment will be compared to any previous deployment.ProcessApplicationDeploymentBuilderImpl
enableDuplicateFiltering(boolean deployChangedOnly)
Check the resources for duplicates in the set of previous deployments with same deployment source.ProcessApplicationReference
getProcessApplicationReference()
String
getResumePreviousVersionsBy()
boolean
isResumePreviousVersions()
ProcessApplicationDeploymentBuilderImpl
name(String name)
Gives the deployment the given name.ProcessApplicationDeploymentBuilderImpl
nameFromDeployment(String deploymentId)
Sets the deployment id to retrieve the deployment name from it.ProcessApplicationDeploymentBuilder
resumePreviousVersions()
If this method is called, additional registrations will be created for previous versions of the deployment.ProcessApplicationDeploymentBuilder
resumePreviousVersionsBy(String resumePreviousVersionsBy)
This method defines on what additional registrations will be based.ProcessApplicationDeploymentBuilderImpl
source(String source)
Sets the source of a deployment.ProcessApplicationDeploymentBuilderImpl
tenantId(String tenantId)
Sets the tenant id of a deployment.-
Methods inherited from class org.camunda.bpm.engine.impl.repository.DeploymentBuilderImpl
addBytes, addModelInstance, addModelInstance, deployWithResult, getDeployment, getDeploymentResourcesById, getDeploymentResourcesByName, getDeployments, getNameFromDeployment, getProcessDefinitionsActivationDate, getResourceNames, isDeployChangedOnly, isDuplicateFilterEnabled
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.camunda.bpm.engine.repository.DeploymentBuilder
addModelInstance, addModelInstance, deployWithResult, getResourceNames
-
-
-
-
Field Detail
-
processApplicationReference
protected final ProcessApplicationReference processApplicationReference
-
isResumePreviousVersions
protected boolean isResumePreviousVersions
-
resumePreviousVersionsBy
protected String resumePreviousVersionsBy
-
-
Constructor Detail
-
ProcessApplicationDeploymentBuilderImpl
public ProcessApplicationDeploymentBuilderImpl(RepositoryServiceImpl repositoryService, ProcessApplicationReference reference)
-
-
Method Detail
-
resumePreviousVersions
public ProcessApplicationDeploymentBuilder resumePreviousVersions()
Description copied from interface:ProcessApplicationDeploymentBuilder
If this method is called, additional registrations will be created for previous versions of the deployment.
- Specified by:
resumePreviousVersions
in interfaceProcessApplicationDeploymentBuilder
-
resumePreviousVersionsBy
public ProcessApplicationDeploymentBuilder resumePreviousVersionsBy(String resumePreviousVersionsBy)
Description copied from interface:ProcessApplicationDeploymentBuilder
This method defines on what additional registrations will be based. The value will only be recognized ifProcessApplicationDeploymentBuilder.resumePreviousVersions()
is set.- Specified by:
resumePreviousVersionsBy
in interfaceProcessApplicationDeploymentBuilder
- See Also:
ResumePreviousBy
,ProcessApplicationDeploymentBuilder.resumePreviousVersions()
-
deploy
public ProcessApplicationDeployment deploy()
Description copied from interface:DeploymentBuilder
Deploys all provided sources to the process engine and returns the created deployment.
The returned
Deployment
instance has no information about the definitions, which are deployed with that deployment. To access this information you can use theDeploymentBuilder.deployWithResult()
method. This method will return an instance ofDeploymentWithDefinitions
, which contains the information about the successful deployed definitions.- Specified by:
deploy
in interfaceDeploymentBuilder
- Specified by:
deploy
in interfaceProcessApplicationDeploymentBuilder
- Overrides:
deploy
in classDeploymentBuilderImpl
- Returns:
- the created deployment
-
activateProcessDefinitionsOn
public ProcessApplicationDeploymentBuilderImpl activateProcessDefinitionsOn(Date date)
Description copied from interface:DeploymentBuilder
Sets the date on which the process definitions contained in this deployment will be activated. This means that all process definitions will be deployed as usual, but they will be suspended from the start until the given activation date.- Specified by:
activateProcessDefinitionsOn
in interfaceDeploymentBuilder
- Specified by:
activateProcessDefinitionsOn
in interfaceProcessApplicationDeploymentBuilder
- Overrides:
activateProcessDefinitionsOn
in classDeploymentBuilderImpl
-
addInputStream
public ProcessApplicationDeploymentBuilderImpl addInputStream(String resourceName, InputStream inputStream)
- Specified by:
addInputStream
in interfaceDeploymentBuilder
- Specified by:
addInputStream
in interfaceProcessApplicationDeploymentBuilder
- Overrides:
addInputStream
in classDeploymentBuilderImpl
-
addClasspathResource
public ProcessApplicationDeploymentBuilderImpl addClasspathResource(String resource)
- Specified by:
addClasspathResource
in interfaceDeploymentBuilder
- Specified by:
addClasspathResource
in interfaceProcessApplicationDeploymentBuilder
- Overrides:
addClasspathResource
in classDeploymentBuilderImpl
-
addString
public ProcessApplicationDeploymentBuilderImpl addString(String resourceName, String text)
- Specified by:
addString
in interfaceDeploymentBuilder
- Specified by:
addString
in interfaceProcessApplicationDeploymentBuilder
- Overrides:
addString
in classDeploymentBuilderImpl
-
addModelInstance
public ProcessApplicationDeploymentBuilderImpl addModelInstance(String resourceName, BpmnModelInstance modelInstance)
Description copied from interface:DeploymentBuilder
Adds a BPMN model to the deployment.- Specified by:
addModelInstance
in interfaceDeploymentBuilder
- Specified by:
addModelInstance
in interfaceProcessApplicationDeploymentBuilder
- Overrides:
addModelInstance
in classDeploymentBuilderImpl
- Parameters:
resourceName
- resource name. See suffix requirements for resource names: {@see DeploymentBuilder}.modelInstance
- model instance- Returns:
-
addZipInputStream
public ProcessApplicationDeploymentBuilderImpl addZipInputStream(ZipInputStream zipInputStream)
- Specified by:
addZipInputStream
in interfaceDeploymentBuilder
- Specified by:
addZipInputStream
in interfaceProcessApplicationDeploymentBuilder
- Overrides:
addZipInputStream
in classDeploymentBuilderImpl
-
name
public ProcessApplicationDeploymentBuilderImpl name(String name)
Description copied from interface:DeploymentBuilder
Gives the deployment the given name.- Specified by:
name
in interfaceDeploymentBuilder
- Specified by:
name
in interfaceProcessApplicationDeploymentBuilder
- Overrides:
name
in classDeploymentBuilderImpl
-
tenantId
public ProcessApplicationDeploymentBuilderImpl tenantId(String tenantId)
Description copied from interface:DeploymentBuilder
Sets the tenant id of a deployment.- Specified by:
tenantId
in interfaceDeploymentBuilder
- Overrides:
tenantId
in classDeploymentBuilderImpl
-
nameFromDeployment
public ProcessApplicationDeploymentBuilderImpl nameFromDeployment(String deploymentId)
Description copied from interface:DeploymentBuilder
Sets the deployment id to retrieve the deployment name from it.- Specified by:
nameFromDeployment
in interfaceDeploymentBuilder
- Specified by:
nameFromDeployment
in interfaceProcessApplicationDeploymentBuilder
- Overrides:
nameFromDeployment
in classDeploymentBuilderImpl
-
source
public ProcessApplicationDeploymentBuilderImpl source(String source)
Description copied from interface:DeploymentBuilder
Sets the source of a deployment.
Furthermore if duplicate check of deployment resources is enabled (by calling
DeploymentBuilder.enableDuplicateFiltering(boolean)
) then only previous deployments with the same given source are considered to perform the duplicate check.- Specified by:
source
in interfaceDeploymentBuilder
- Specified by:
source
in interfaceProcessApplicationDeploymentBuilder
- Overrides:
source
in classDeploymentBuilderImpl
-
enableDuplicateFiltering
public ProcessApplicationDeploymentBuilderImpl enableDuplicateFiltering()
Description copied from interface:DeploymentBuilder
If set, this deployment will be compared to any previous deployment. This means that every (non-generated) resource will be compared with the provided resources of this deployment. If any resource of this deployment is different to the existing resources, all resources are re-deployed.
Deprecated: use
DeploymentBuilder.enableDuplicateFiltering(boolean)
- Specified by:
enableDuplicateFiltering
in interfaceDeploymentBuilder
- Specified by:
enableDuplicateFiltering
in interfaceProcessApplicationDeploymentBuilder
- Overrides:
enableDuplicateFiltering
in classDeploymentBuilderImpl
-
enableDuplicateFiltering
public ProcessApplicationDeploymentBuilderImpl enableDuplicateFiltering(boolean deployChangedOnly)
Description copied from interface:DeploymentBuilder
Check the resources for duplicates in the set of previous deployments with same deployment source. If no resources have changed in this deployment, its contained resources are not deployed at all. For further configuration, use the parameterdeployChangedOnly
.- Specified by:
enableDuplicateFiltering
in interfaceDeploymentBuilder
- Specified by:
enableDuplicateFiltering
in interfaceProcessApplicationDeploymentBuilder
- Overrides:
enableDuplicateFiltering
in classDeploymentBuilderImpl
- Parameters:
deployChangedOnly
- determines whether only those resources should be deployed that have changed from the previous versions of the deployment. If false, all of the resources are re-deployed if any resource differs.
-
addDeploymentResources
public ProcessApplicationDeploymentBuilderImpl addDeploymentResources(String deploymentId)
Description copied from interface:DeploymentBuilder
All existing resources contained by the given deployment will be added to the new deployment to re-deploy them.- Specified by:
addDeploymentResources
in interfaceDeploymentBuilder
- Specified by:
addDeploymentResources
in interfaceProcessApplicationDeploymentBuilder
- Overrides:
addDeploymentResources
in classDeploymentBuilderImpl
-
addDeploymentResourceById
public ProcessApplicationDeploymentBuilderImpl addDeploymentResourceById(String deploymentId, String resourceId)
Description copied from interface:DeploymentBuilder
A given resource specified by id and deployment id will be added to the new deployment to re-deploy the given resource.- Specified by:
addDeploymentResourceById
in interfaceDeploymentBuilder
- Specified by:
addDeploymentResourceById
in interfaceProcessApplicationDeploymentBuilder
- Overrides:
addDeploymentResourceById
in classDeploymentBuilderImpl
-
addDeploymentResourcesById
public ProcessApplicationDeploymentBuilderImpl addDeploymentResourcesById(String deploymentId, List<String> resourceIds)
Description copied from interface:DeploymentBuilder
All given resources specified by id and deployment id will be added to the new deployment to re-deploy the given resource.- Specified by:
addDeploymentResourcesById
in interfaceDeploymentBuilder
- Specified by:
addDeploymentResourcesById
in interfaceProcessApplicationDeploymentBuilder
- Overrides:
addDeploymentResourcesById
in classDeploymentBuilderImpl
-
addDeploymentResourceByName
public ProcessApplicationDeploymentBuilderImpl addDeploymentResourceByName(String deploymentId, String resourceName)
Description copied from interface:DeploymentBuilder
A given resource specified by name and deployment id will be added to the new deployment to re-deploy the given resource.- Specified by:
addDeploymentResourceByName
in interfaceDeploymentBuilder
- Specified by:
addDeploymentResourceByName
in interfaceProcessApplicationDeploymentBuilder
- Overrides:
addDeploymentResourceByName
in classDeploymentBuilderImpl
-
addDeploymentResourcesByName
public ProcessApplicationDeploymentBuilderImpl addDeploymentResourcesByName(String deploymentId, List<String> resourceNames)
Description copied from interface:DeploymentBuilder
All given resources specified by name and deployment id will be added to the new deployment to re-deploy the given resource.- Specified by:
addDeploymentResourcesByName
in interfaceDeploymentBuilder
- Specified by:
addDeploymentResourcesByName
in interfaceProcessApplicationDeploymentBuilder
- Overrides:
addDeploymentResourcesByName
in classDeploymentBuilderImpl
-
isResumePreviousVersions
public boolean isResumePreviousVersions()
-
getProcessApplicationReference
public ProcessApplicationReference getProcessApplicationReference()
-
getResumePreviousVersionsBy
public String getResumePreviousVersionsBy()
-
-