Interface HistoryLevel
-
- All Known Implementing Classes:
AbstractHistoryLevel,HistoryLevelActivity,HistoryLevelAudit,HistoryLevelFull,HistoryLevelNone
public interface HistoryLevelThe history level controls what kind of data is logged to the history database. More formally, it controls which history events are produced by the
HistoryEventProducer.Built-in history levels: The process engine provides a set of built-in history levels as default configuration. The built-in history levels are:
This class provides singleton instances of these history levels as constants.Custom history levels:In order to implement a custom history level, the following steps are necessary:
- Provide a custom implementation of this interface. Note: Make sure you choose unique values for
getName()andgetId() - Add an instance of the custom implementation through
ProcessEngineConfigurationImpl.setCustomHistoryLevels(java.util.List) - use the name of your history level (as returned by
getName()as value forProcessEngineConfiguration.setHistory(String)
- Since:
- 7.2
- Author:
- Daniel Meyer
-
-
Field Summary
Fields Modifier and Type Field Description static HistoryLevelHISTORY_LEVEL_ACTIVITYstatic HistoryLevelHISTORY_LEVEL_AUDITstatic HistoryLevelHISTORY_LEVEL_FULLstatic HistoryLevelHISTORY_LEVEL_NONE
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description intgetId()An unique id identifying the history level.java.lang.StringgetName()An unique name identifying the history level.booleanisHistoryEventProduced(HistoryEventType eventType, java.lang.Object entity)Returns true if a given history event should be produced.
-
-
-
Field Detail
-
HISTORY_LEVEL_NONE
static final HistoryLevel HISTORY_LEVEL_NONE
-
HISTORY_LEVEL_ACTIVITY
static final HistoryLevel HISTORY_LEVEL_ACTIVITY
-
HISTORY_LEVEL_AUDIT
static final HistoryLevel HISTORY_LEVEL_AUDIT
-
HISTORY_LEVEL_FULL
static final HistoryLevel HISTORY_LEVEL_FULL
-
-
Method Detail
-
getId
int getId()
An unique id identifying the history level. The id is used internally to uniquely identify the history level and also stored in the database.
-
getName
java.lang.String getName()
An unique name identifying the history level. The name of the history level can be used when configuring the process engine.
-
isHistoryEventProduced
boolean isHistoryEventProduced(HistoryEventType eventType, java.lang.Object entity)
Returns true if a given history event should be produced.- Parameters:
eventType- the type of the history event which is about to be producedentity- the runtime structure used to produce the history event. ExamplesExecutionEntity,TaskEntity,VariableInstanceEntity, ... If a 'null' value is provided, the implementation should return true if events of this type should be produced "in general".
-
-