Skip to content
Permalink
Browse files
allow to build a JobOperator from a ServicesManager instance + removi…
…ng last parts of permissions
  • Loading branch information
rmannibucau committed Sep 7, 2016
1 parent decf930 commit a69bd3849473063cbebfa606a2aa1e1a2e44bb70
Showing 1 changed file with 5 additions and 14 deletions.
@@ -92,26 +92,13 @@ public class JobOperatorImpl implements JobOperator {
}
}

enum Permissions {
START("start");

private final String name;

Permissions(final String permName) {
name = permName;
}
}

public static final String JBATCH_ADMIN = "admin";

private final BatchKernelService kernelService;
private final PersistenceManagerService persistenceManagerService;
private final JobXMLLoaderService xmlLoaderService;
private final JobStatusManagerService statusManagerService;
private final JobExecutionCallbackService callbackService;

public JobOperatorImpl() {
final ServicesManager servicesManager = ServicesManager.find();
protected JobOperatorImpl(final ServicesManager servicesManager) {
try {
kernelService = servicesManager.service(BatchKernelService.class);
persistenceManagerService = servicesManager.service(PersistenceManagerService.class);
@@ -124,6 +111,10 @@ public JobOperatorImpl() {
}
}

public JobOperatorImpl() {
this(ServicesManager.find());
}

@Override
public long start(final String jobXMLName, final Properties jobParameters) throws JobStartException, JobSecurityException {
/*

0 comments on commit a69bd38

Please sign in to comment.