1 /*
2 * Copyright 2008 The Kuali Foundation
3 *
4 * Licensed under the Educational Community License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.opensource.org/licenses/ecl2.php
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16 package org.kuali.ole.sys.service;
17
18
19 /**
20 * This class defines methods needed for batch to run successfully when there are dependencies on jobs that are run on external systems.
21 * Implementations of this interface are able to keep track of external job status and report it to the scheduler service.
22 *
23 */
24 public interface BatchModuleService {
25
26 /**
27 * This method returns whether a job is run on an external system.
28 *
29 * @param jobName a job name, such that calling {@link #isResponsibleForJob(String)} with this job name would return true
30 * @return whether this job runs from an external system
31 */
32 public boolean isExternalJob(String jobName);
33
34 /**
35 * This method returns the status of the given external job.
36 *
37 * @param jobName a job name, such that calling {@link #isResponsibleForJob(String)} with this job name would return true
38 * @return one of the status code constants defined in {@link org.kuali.ole.sys.batch.service.SchedulerService}
39 */
40 public String getExternalJobStatus(String jobName);
41
42 }