/** * Convenience method for deleting all rows from the specified tables. * <p>Use with caution outside of a transaction! * @param names the names of the tables from which to delete * @return the total number of rows deleted from all specified tables * @see JdbcTestUtils#deleteFromTables */ protected int deleteFromTables(String... names) { return JdbcTestUtils.deleteFromTables(this.jdbcTemplate, names); }
/** * Convenience method for deleting all rows from the specified tables. * <p>Use with caution outside of a transaction! * @param names the names of the tables from which to delete * @return the total number of rows deleted from all specified tables * @see JdbcTestUtils#deleteFromTables */ protected int deleteFromTables(String... names) { return JdbcTestUtils.deleteFromTables(this.jdbcTemplate, names); }
protected int deleteFromTables(String... names) { return JdbcTestUtils.deleteFromTables(this.jdbcTemplate, names); }
@Override protected JobExecutionDao getJobExecutionDao() { JdbcTestUtils.deleteFromTables(jdbcTemplate, "BATCH_JOB_EXECUTION_CONTEXT", "BATCH_STEP_EXECUTION_CONTEXT", "BATCH_STEP_EXECUTION", "BATCH_JOB_EXECUTION", "BATCH_JOB_EXECUTION_PARAMS", "BATCH_JOB_INSTANCE"); return jobExecutionDao; }
@Override protected JobInstanceDao getJobInstanceDao() { JdbcTestUtils.deleteFromTables(jdbcTemplate, "BATCH_JOB_EXECUTION_CONTEXT", "BATCH_STEP_EXECUTION_CONTEXT", "BATCH_STEP_EXECUTION", "BATCH_JOB_EXECUTION_PARAMS", "BATCH_JOB_EXECUTION", "BATCH_JOB_INSTANCE"); return jobInstanceDao; }
@Before public void clear() { JdbcTestUtils.deleteFromTables(jdbcTemplate, "PLAYER_SUMMARY", "GAMES", "PLAYERS"); }
@Before public void setUp() throws Exception { writer = new SkipWriterStub(dataSource); processor = new SkipProcessorStub(dataSource); factory = new FaultTolerantStepFactoryBean<>(); factory.setBeanName("stepName"); factory.setTransactionManager(transactionManager); factory.setJobRepository(repository); factory.setCommitInterval(3); factory.setSkipLimit(10); JdbcTestUtils.deleteFromTables(new JdbcTemplate(dataSource), "ERROR_LOG"); }
@Before public void setUp() throws Exception { writer = new SkipWriterStub(dataSource); processor = new SkipProcessorStub(dataSource); factory = new FaultTolerantStepFactoryBean<>(); factory.setBeanName("stepName"); factory.setTransactionManager(transactionManager); factory.setJobRepository(repository); factory.setCommitInterval(3); ThreadPoolTaskExecutor taskExecutor = new ThreadPoolTaskExecutor(); taskExecutor.setCorePoolSize(3); taskExecutor.setMaxPoolSize(6); taskExecutor.setQueueCapacity(0); taskExecutor.afterPropertiesSet(); factory.setTaskExecutor(taskExecutor); JdbcTestUtils.deleteFromTables(new JdbcTemplate(dataSource), "ERROR_LOG"); }
/** * Convenience method for deleting all rows from the specified tables. * <p>Use with caution outside of a transaction! * @param names the names of the tables from which to delete * @return the total number of rows deleted from all specified tables * @see JdbcTestUtils#deleteFromTables */ protected int deleteFromTables(String... names) { return JdbcTestUtils.deleteFromTables(this.jdbcTemplate, names); }
/** * Convenience method for deleting all rows from the specified tables. * <p>Use with caution outside of a transaction! * @param names the names of the tables from which to delete * @return the total number of rows deleted from all specified tables * @see JdbcTestUtils#deleteFromTables */ protected int deleteFromTables(String... names) { return JdbcTestUtils.deleteFromTables(this.jdbcTemplate, names); }
/** * Convenience method for deleting all rows from the specified tables. * <p>Use with caution outside of a transaction! * @param names the names of the tables from which to delete * @return the total number of rows deleted from all specified tables * @see JdbcTestUtils#deleteFromTables */ protected int deleteFromTables(String... names) { return JdbcTestUtils.deleteFromTables(this.jdbcTemplate, names); }
/** * Convenience method for deleting all rows from the specified tables. * <p>Use with caution outside of a transaction! * @param names the names of the tables from which to delete * @return the total number of rows deleted from all specified tables * @see JdbcTestUtils#deleteFromTables */ protected int deleteFromTables(String... names) { return JdbcTestUtils.deleteFromTables(this.jdbcTemplate, names); }
JdbcTestUtils.deleteFromTables(jdbcTemplate, list.get(0)); list.remove(0); JdbcTestUtils.deleteFromTables(jdbcTemplate, tableName);
@After public void cleanUp() { JdbcTestUtils.deleteFromTables(jdbcTemplate, "issue", "mention", "message", "user"); }