Package org.springframework.batch.admin.web

Examples of org.springframework.batch.admin.web.JobInfo


  }

  @Test
  public void testViewWithJobAndExecutions() throws Exception {
    model.put(BindingResult.MODEL_KEY_PREFIX + "launchRequest", errors);
    model.put("jobInfo", new JobInfo("foo", 1));
    model.put("jobInstances", Arrays.asList(new JobInstanceInfo(MetaDataInstanceFactory.createJobInstance("foo",
        123456789L), Arrays.asList(MetaDataInstanceFactory.createJobExecution()), TimeZone.getTimeZone("GMT"))));
    model.put("baseUrl", "http://localhost:8080/springsource");
    job.render(model, request, response);
    String content = response.getContentAsString();
View Full Code Here


    assertEquals("STARTING", wrapper.get("job.jobInstances['123456789'].lastJobExecutionStatus", String.class));
  }

  @Test
  public void testListViewWithJobs() throws Exception {
    model.put("jobs", Arrays.asList(new JobInfo("foo", 1, true), new JobInfo("bar", 2)));
    model.put("baseUrl", "http://localhost:8080/springsource");
    model.put("startJob", 11);
    model.put("endJob", 30);
    model.put("totalJobs", 100);
    model.put("nextJob", 31);
View Full Code Here

    assertEquals(5, wrapper.get("page", Map.class).size());
  }

  @Test
  public void testListViewWithJobsNoPages() throws Exception {
    model.put("jobs", Arrays.asList(new JobInfo("foo", 1, true), new JobInfo("bar", 2)));
    model.put("baseUrl", "http://localhost:8080/springsource");
    model.put("startJob", 11);
    model.put("endJob", 30);
    model.put("totalJobs", 100);
    jobs.render(model, request, response);
View Full Code Here

    try {
      String jobName = request.get("jobId");
      long jobInstanceId = Long.parseLong(request.get("jobInsId"));
      Collection<JobExecution> jobExecutions = jobService
          .getJobExecutionsForJobInstance(jobName, jobInstanceId);
      new JobInfo(jobName, jobExecutions.size() + 1);
      JobExecution jobExecution = jobExecutions.iterator().next();
      new JobExecutionInfo(jobExecution, TimeZone.getDefault());

      Long jobExecutionId = jobExecution.getId();
View Full Code Here

TOP

Related Classes of org.springframework.batch.admin.web.JobInfo

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.