Class DefaultHistoryRemovalTimeProvider
java.lang.Object
org.camunda.bpm.engine.impl.history.DefaultHistoryRemovalTimeProvider
- All Implemented Interfaces:
HistoryRemovalTimeProvider
- Author:
- Tassilo Weidner
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncalculateRemovalTime(HistoricBatchEntity historicBatch) Calculates the removal time of historic batches.calculateRemovalTime(HistoricDecisionInstanceEntity historicRootDecisionInstance, DecisionDefinition decisionDefinition) Calculates the removal time of historic entities related to decisions.calculateRemovalTime(HistoricProcessInstanceEventEntity historicRootProcessInstance, ProcessDefinition processDefinition) Calculates the removal time of historic entities related to processes.static DatedetermineRemovalTime(Date initTime, Integer timeToLive) protected IntegergetTTLByBatchOperation(String batchOperation) protected booleanisBatchEnded(HistoricBatchEntity historicBatch) protected booleanisBatchRunning(HistoricBatchEntity historicBatch) protected booleanisProcessInstanceEnded(HistoricProcessInstanceEventEntity historicProcessInstance) protected booleanisProcessInstanceRunning(HistoricProcessInstanceEventEntity historicProcessInstance)
-
Constructor Details
-
DefaultHistoryRemovalTimeProvider
public DefaultHistoryRemovalTimeProvider()
-
-
Method Details
-
calculateRemovalTime
public Date calculateRemovalTime(HistoricProcessInstanceEventEntity historicRootProcessInstance, ProcessDefinition processDefinition) Description copied from interface:HistoryRemovalTimeProviderCalculates the removal time of historic entities related to processes. START: the removal time is set for each historic entity separately on occurrence (creation).HistoricScopeInstanceEvent.getEndTime()isnullEND: the removal time is updated simultaneously for all historic entities which belong to the root process instance when it ends.HistoricScopeInstanceEvent.getEndTime()is notnull- Specified by:
calculateRemovalTimein interfaceHistoryRemovalTimeProvider- Parameters:
historicRootProcessInstance- which is either in state running or endedprocessDefinition- of the historic root process instance- Returns:
- the removal time for historic process instances
-
calculateRemovalTime
public Date calculateRemovalTime(HistoricDecisionInstanceEntity historicRootDecisionInstance, DecisionDefinition decisionDefinition) Description copied from interface:HistoryRemovalTimeProviderCalculates the removal time of historic entities related to decisions.- Specified by:
calculateRemovalTimein interfaceHistoryRemovalTimeProviderdecisionDefinition- of the historic root decision instance- Returns:
- the removal time for historic decision instances
-
calculateRemovalTime
Description copied from interface:HistoryRemovalTimeProviderCalculates the removal time of historic batches. START: the removal time is set for the historic batch entity on start.HistoricBatchEntity.getEndTime()isnullEND: the removal time is set for the historic batch entity on end.HistoricBatchEntity.getEndTime()is notnull- Specified by:
calculateRemovalTimein interfaceHistoryRemovalTimeProvider- Parameters:
historicBatch- which is either in state running or ended- Returns:
- the removal time of historic entities
-
isBatchRunning
-
isBatchEnded
-
getTTLByBatchOperation
-
isProcessInstanceRunning
protected boolean isProcessInstanceRunning(HistoricProcessInstanceEventEntity historicProcessInstance) -
isProcessInstanceEnded
protected boolean isProcessInstanceEnded(HistoricProcessInstanceEventEntity historicProcessInstance) -
determineRemovalTime
-