
public final class JdbcRepository extends AbstractPersistentRepository
| Modifier and Type | Field and Description |
|---|---|
static String |
DATASOURCE_JNDI_KEY |
static String |
DB_PASSWORD_KEY |
static String |
DB_PROPERTIES_KEY |
static String |
DB_PROPERTY_DELIM |
static String |
DB_TABLE_PREFIX_KEY |
static String |
DB_TABLE_SUFFIX_KEY |
static String |
DB_URL_KEY |
static String |
DB_USER_KEY |
static String |
DDL_FILE_NAME_KEY |
static String |
SQL_FILE_NAME_KEY |
| Constructor and Description |
|---|
JdbcRepository(DataSource dataSource)
Creates a new JDBC job repository.
|
JdbcRepository(DataSource dataSource,
Properties configProperties)
Creates a new JDBC job repository.
|
JdbcRepository(Properties configProperties) |
| Modifier and Type | Method and Description |
|---|---|
void |
addPartitionExecution(StepExecutionImpl enclosingStepExecution,
PartitionExecutionImpl partitionExecution) |
int |
countStepStartTimes(String stepName,
long jobInstanceId) |
static JdbcRepository |
create(Properties configProperties) |
void |
executeStatements(String statements,
String statementsResourcePath)
Executes a series of sql statements.
|
StepExecutionImpl |
findOriginalStepExecutionForRestart(String stepName,
JobExecutionImpl jobExecutionToRestart,
ClassLoader classLoader) |
JobExecutionImpl |
getJobExecution(long jobExecutionId) |
List<javax.batch.runtime.JobExecution> |
getJobExecutions(javax.batch.runtime.JobInstance jobInstance) |
JobInstanceImpl |
getJobInstance(long jobInstanceId) |
int |
getJobInstanceCount(String jobName) |
List<javax.batch.runtime.JobInstance> |
getJobInstances(String jobName) |
List<PartitionExecutionImpl> |
getPartitionExecutions(long stepExecutionId,
StepExecutionImpl stepExecution,
boolean notCompletedOnly,
ClassLoader classLoader) |
List<Long> |
getRunningExecutions(String jobName)
Gets the ids of running job executions belonging to a specific job.
|
void |
savePersistentData(javax.batch.runtime.JobExecution jobExecution,
AbstractStepExecution stepOrPartitionExecution) |
void |
updateJobExecution(JobExecutionImpl jobExecution,
boolean fullUpdate,
boolean saveJobParameters) |
void |
updateStepExecution(javax.batch.runtime.StepExecution stepExecution) |
createJobExecution, createJobInstance, getStepExecutions, removeJob, removeJobExecutions, removeJobInstanceaddJob, addStepExecution, createStepExecution, getJob, getJobNames, jobExistsclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitaddJob, addStepExecution, createStepExecution, getJob, getJobNames, jobExistspublic static final String DDL_FILE_NAME_KEY
public static final String SQL_FILE_NAME_KEY
public static final String DATASOURCE_JNDI_KEY
public static final String DB_URL_KEY
public static final String DB_USER_KEY
public static final String DB_PASSWORD_KEY
public static final String DB_PROPERTIES_KEY
public static final String DB_PROPERTY_DELIM
public static final String DB_TABLE_PREFIX_KEY
public static final String DB_TABLE_SUFFIX_KEY
public JdbcRepository(Properties configProperties)
public JdbcRepository(DataSource dataSource)
dataSource - the data source used to connect to the databasepublic JdbcRepository(DataSource dataSource, Properties configProperties)
dataSource - the data source used to connect to the databaseconfigProperties - the configuration properties to usepublic static JdbcRepository create(Properties configProperties)
public JobInstanceImpl getJobInstance(long jobInstanceId)
getJobInstance in interface JobRepositorygetJobInstance in class AbstractPersistentRepositorypublic int getJobInstanceCount(String jobName)
public void updateJobExecution(JobExecutionImpl jobExecution, boolean fullUpdate, boolean saveJobParameters)
updateJobExecution in interface JobRepositoryupdateJobExecution in class AbstractRepositorypublic JobExecutionImpl getJobExecution(long jobExecutionId)
getJobExecution in interface JobRepositorygetJobExecution in class AbstractPersistentRepositorypublic List<javax.batch.runtime.JobExecution> getJobExecutions(javax.batch.runtime.JobInstance jobInstance)
public List<Long> getRunningExecutions(String jobName)
JobRepositoryjobName - the name of the job, not nullAbstractJobOperator.getRunningExecutions(java.lang.String)public void updateStepExecution(javax.batch.runtime.StepExecution stepExecution)
public void savePersistentData(javax.batch.runtime.JobExecution jobExecution,
AbstractStepExecution stepOrPartitionExecution)
savePersistentData in interface JobRepositorysavePersistentData in class AbstractRepositorypublic void addPartitionExecution(StepExecutionImpl enclosingStepExecution, PartitionExecutionImpl partitionExecution)
addPartitionExecution in interface JobRepositoryaddPartitionExecution in class AbstractRepositorypublic StepExecutionImpl findOriginalStepExecutionForRestart(String stepName, JobExecutionImpl jobExecutionToRestart, ClassLoader classLoader)
findOriginalStepExecutionForRestart in interface JobRepositoryfindOriginalStepExecutionForRestart in class AbstractPersistentRepositorypublic List<PartitionExecutionImpl> getPartitionExecutions(long stepExecutionId, StepExecutionImpl stepExecution, boolean notCompletedOnly, ClassLoader classLoader)
getPartitionExecutions in interface JobRepositorygetPartitionExecutions in class AbstractRepositorypublic int countStepStartTimes(String stepName, long jobInstanceId)
public void executeStatements(String statements, String statementsResourcePath) throws SQLException
statements - sql statements as string separated with ; character; not null unless statementsResourcePath is present.statementsResourcePath - loadable resource path to obtain sql statements. Ignored when statements is present.SQLExceptionCopyright © 2018 JBoss by Red Hat. All rights reserved.