Closed
Description
Bug description
JobRepository#getJobNames()
is not implemented by the only implementation of the interface, SimpleJobRepository
. The default method simply returns an empty list.
As of Spring Batch 5, this method is used by JobRepositoryTestUtils.removeJobExecutions()
, which became a no-op method, never removing any executions due to getJobNames()
never returning any job names.
Environment
Spring Batch 5.0.0-RC2
Steps to reproduce
- Run Job.
- Call
JobRepository.getJobNames()
.
Expected behavior
Names of jobs are returned.
Minimal Complete Reproducible example
demo1.zip
- Unzip
- Run
mvnw spring-boot:run
- The app runs a job named
job
and then queries both thebatch_job_instance
table and theJobRepository
for all job names. The query returnsjob
as expected, theJobRepository
returns nothing.