public class JdbcExecutionContextDao extends AbstractJdbcBatchMetadataDao implements ExecutionContextDao
ExecutionContext
.
Stores execution context data related to both Step and Job using
a different table for each.DEFAULT_EXIT_MESSAGE_LENGTH, DEFAULT_TABLE_PREFIX
Constructor and Description |
---|
JdbcExecutionContextDao() |
Modifier and Type | Method and Description |
---|---|
void |
afterPropertiesSet() |
ExecutionContext |
getExecutionContext(JobExecution jobExecution) |
ExecutionContext |
getExecutionContext(StepExecution stepExecution) |
void |
saveExecutionContext(JobExecution jobExecution)
Persist the execution context associated with the given jobExecution,
persistent entry for the context should not exist yet.
|
void |
saveExecutionContext(StepExecution stepExecution)
Persist the execution context associated with the given stepExecution,
persistent entry for the context should not exist yet.
|
void |
saveExecutionContexts(java.util.Collection<StepExecution> stepExecutions)
Persist the execution context associated with each stepExecution in a given collection,
persistent entry for the context should not exist yet.
|
void |
setLobHandler(org.springframework.jdbc.support.lob.LobHandler lobHandler) |
void |
setSerializer(ExecutionContextSerializer serializer)
Setter for
Serializer implementation |
void |
setShortContextLength(int shortContextLength)
The maximum size that an execution context can have and still be stored
completely in short form in the column
SHORT_CONTEXT . |
void |
updateExecutionContext(JobExecution jobExecution)
Persist the updates of execution context associated with the given
jobExecution.
|
void |
updateExecutionContext(StepExecution stepExecution)
Persist the updates of execution context associated with the given
stepExecution.
|
getClobTypeToUse, getJdbcTemplate, getQuery, getTablePrefix, setClobTypeToUse, setJdbcTemplate, setTablePrefix
public void setSerializer(ExecutionContextSerializer serializer)
Serializer
implementationserializer
- public void setShortContextLength(int shortContextLength)
SHORT_CONTEXT
.
Anything longer than this will overflow into large-object storage, and
the first part only will be retained in the short form for readability.
Default value is 2500. Clients using multi-bytes charsets on the database
server may need to reduce this value to as little as half the value of
the column size.shortContextLength
- public ExecutionContext getExecutionContext(JobExecution jobExecution)
getExecutionContext
in interface ExecutionContextDao
public ExecutionContext getExecutionContext(StepExecution stepExecution)
getExecutionContext
in interface ExecutionContextDao
public void updateExecutionContext(JobExecution jobExecution)
ExecutionContextDao
updateExecutionContext
in interface ExecutionContextDao
public void updateExecutionContext(StepExecution stepExecution)
ExecutionContextDao
updateExecutionContext
in interface ExecutionContextDao
public void saveExecutionContext(JobExecution jobExecution)
ExecutionContextDao
saveExecutionContext
in interface ExecutionContextDao
public void saveExecutionContext(StepExecution stepExecution)
ExecutionContextDao
saveExecutionContext
in interface ExecutionContextDao
public void saveExecutionContexts(java.util.Collection<StepExecution> stepExecutions)
ExecutionContextDao
saveExecutionContexts
in interface ExecutionContextDao
public void setLobHandler(org.springframework.jdbc.support.lob.LobHandler lobHandler)
public void afterPropertiesSet() throws java.lang.Exception
afterPropertiesSet
in interface org.springframework.beans.factory.InitializingBean
afterPropertiesSet
in class AbstractJdbcBatchMetadataDao
java.lang.Exception