public class AsyncHistorySessionCommandContextCloseListener extends Object implements CommandContextCloseListener
HistoryJobEntity when the
CommandContext closes and adds them to the list of entities that will
be inserted to the database.
The reason why this is done at the very end, is because that way the historical data
can be optimized (some events cancel others, can be grouped, etc.)| Modifier and Type | Field and Description |
|---|---|
protected AsyncHistoryListener |
asyncHistoryListener |
protected AsyncHistorySession |
asyncHistorySession |
protected String |
dataFieldName |
protected String |
typeFieldName |
| Constructor and Description |
|---|
AsyncHistorySessionCommandContextCloseListener() |
AsyncHistorySessionCommandContextCloseListener(AsyncHistorySession asyncHistorySession,
AsyncHistoryListener asyncHistoryListener) |
| Modifier and Type | Method and Description |
|---|---|
void |
afterSessionsFlush(CommandContext commandContext) |
void |
closed(CommandContext commandContext) |
void |
closeFailure(CommandContext commandContext) |
void |
closing(CommandContext commandContext) |
protected void |
generateJson(JobServiceConfiguration jobServiceConfiguration,
Map<String,List<com.fasterxml.jackson.databind.node.ObjectNode>> jobData,
List<com.fasterxml.jackson.databind.node.ObjectNode> objectNodes,
String type) |
protected com.fasterxml.jackson.databind.node.ObjectNode |
generateJson(JobServiceConfiguration jobServiceConfiguration,
String type,
com.fasterxml.jackson.databind.node.ObjectNode historicData) |
AsyncHistoryListener |
getAsyncHistoryListener() |
AsyncHistorySession |
getAsyncHistorySession() |
String |
getDataFieldName() |
String |
getTypeFieldName() |
boolean |
multipleAllowed() |
Integer |
order() |
void |
setAsyncHistoryListener(AsyncHistoryListener asyncHistoryListener) |
void |
setAsyncHistorySession(AsyncHistorySession asyncHistorySession) |
void |
setDataFieldName(String dataFieldName) |
void |
setTypeFieldName(String typeFieldName) |
protected AsyncHistorySession asyncHistorySession
protected AsyncHistoryListener asyncHistoryListener
protected String typeFieldName
protected String dataFieldName
public AsyncHistorySessionCommandContextCloseListener()
public AsyncHistorySessionCommandContextCloseListener(AsyncHistorySession asyncHistorySession, AsyncHistoryListener asyncHistoryListener)
public void closing(CommandContext commandContext)
closing in interface CommandContextCloseListenerprotected void generateJson(JobServiceConfiguration jobServiceConfiguration, Map<String,List<com.fasterxml.jackson.databind.node.ObjectNode>> jobData, List<com.fasterxml.jackson.databind.node.ObjectNode> objectNodes, String type)
protected com.fasterxml.jackson.databind.node.ObjectNode generateJson(JobServiceConfiguration jobServiceConfiguration, String type, com.fasterxml.jackson.databind.node.ObjectNode historicData)
public void closed(CommandContext commandContext)
closed in interface CommandContextCloseListenerpublic void closeFailure(CommandContext commandContext)
closeFailure in interface CommandContextCloseListenerpublic void afterSessionsFlush(CommandContext commandContext)
afterSessionsFlush in interface CommandContextCloseListenerpublic Integer order()
order in interface CommandContextCloseListenerpublic boolean multipleAllowed()
multipleAllowed in interface CommandContextCloseListenerpublic AsyncHistorySession getAsyncHistorySession()
public void setAsyncHistorySession(AsyncHistorySession asyncHistorySession)
public AsyncHistoryListener getAsyncHistoryListener()
public void setAsyncHistoryListener(AsyncHistoryListener asyncHistoryListener)
public String getTypeFieldName()
public void setTypeFieldName(String typeFieldName)
public String getDataFieldName()
public void setDataFieldName(String dataFieldName)
Copyright © 2021 Flowable. All rights reserved.