diff --git a/spring-batch-core/src/main/java/org/springframework/batch/core/explore/JobExplorer.java b/spring-batch-core/src/main/java/org/springframework/batch/core/explore/JobExplorer.java index 207d3c92d..b309ef44b 100644 --- a/spring-batch-core/src/main/java/org/springframework/batch/core/explore/JobExplorer.java +++ b/spring-batch-core/src/main/java/org/springframework/batch/core/explore/JobExplorer.java @@ -15,15 +15,15 @@ */ package org.springframework.batch.core.explore; -import java.util.List; -import java.util.Set; - import org.springframework.batch.core.JobExecution; import org.springframework.batch.core.JobInstance; import org.springframework.batch.core.StepExecution; import org.springframework.batch.core.launch.NoSuchJobException; import org.springframework.batch.item.ExecutionContext; +import java.util.List; +import java.util.Set; + /** * Entry point for browsing executions of running or historical jobs and steps. * Since the data may be re-hydrated from persistent storage, it may not contain @@ -118,7 +118,7 @@ public interface JobExplorer { * @param count * @return */ - List getJobInstancesByJobName(String jobName, int start, int count); + List findJobInstancesByJobName(String jobName, int start, int count); /** * Query the repository for the number of unique {@link JobInstance}s diff --git a/spring-batch-core/src/main/java/org/springframework/batch/core/explore/support/SimpleJobExplorer.java b/spring-batch-core/src/main/java/org/springframework/batch/core/explore/support/SimpleJobExplorer.java index eeef93f79..c16b8f7e2 100644 --- a/spring-batch-core/src/main/java/org/springframework/batch/core/explore/support/SimpleJobExplorer.java +++ b/spring-batch-core/src/main/java/org/springframework/batch/core/explore/support/SimpleJobExplorer.java @@ -16,9 +16,6 @@ package org.springframework.batch.core.explore.support; -import java.util.List; -import java.util.Set; - import org.springframework.batch.core.JobExecution; import org.springframework.batch.core.JobInstance; import org.springframework.batch.core.StepExecution; @@ -29,6 +26,9 @@ import org.springframework.batch.core.repository.dao.JobExecutionDao; import org.springframework.batch.core.repository.dao.JobInstanceDao; import org.springframework.batch.core.repository.dao.StepExecutionDao; +import java.util.List; +import java.util.Set; + /** * Implementation of {@link JobExplorer} using the injected DAOs. * @@ -210,7 +210,7 @@ public class SimpleJobExplorer implements JobExplorer { } @Override - public List getJobInstancesByJobName(String jobName, int start, int count) { + public List findJobInstancesByJobName(String jobName, int start, int count) { return jobInstanceDao.findJobInstancesByName(jobName, start, count); } } diff --git a/spring-batch-core/src/test/java/org/springframework/batch/core/launch/support/CommandLineJobRunnerTests.java b/spring-batch-core/src/test/java/org/springframework/batch/core/launch/support/CommandLineJobRunnerTests.java index 2061575dd..a4011a287 100644 --- a/spring-batch-core/src/test/java/org/springframework/batch/core/launch/support/CommandLineJobRunnerTests.java +++ b/spring-batch-core/src/test/java/org/springframework/batch/core/launch/support/CommandLineJobRunnerTests.java @@ -15,18 +15,6 @@ */ package org.springframework.batch.core.launch.support; -import static org.junit.Assert.assertEquals; -import static org.junit.Assert.assertTrue; - -import java.io.IOException; -import java.io.InputStream; -import java.util.ArrayList; -import java.util.Arrays; -import java.util.Date; -import java.util.List; -import java.util.Properties; -import java.util.Set; - import org.junit.After; import org.junit.Before; import org.junit.Test; @@ -47,6 +35,18 @@ import org.springframework.batch.core.repository.JobExecutionAlreadyRunningExcep import org.springframework.batch.core.step.JobRepositorySupport; import org.springframework.util.ClassUtils; +import java.io.IOException; +import java.io.InputStream; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.Date; +import java.util.List; +import java.util.Properties; +import java.util.Set; + +import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertTrue; + /** * @author Lucas Ward * @@ -487,7 +487,7 @@ public class CommandLineJobRunnerTests { } @Override - public List getJobInstancesByJobName(String jobName, int start, int count) { + public List findJobInstancesByJobName(String jobName, int start, int count) { throw new UnsupportedOperationException(); }