You can upload the ScheduleTask and JavaTask jar in OIM from your custom java applications. Here is the example of the same. similarly you also download, update and delete jar files from OIM database.
public void uploadJar() throws PlatformServiceException{
PlatformUtilsService platformUtilsService = (PlatformUtilsService) oimClient.getService(PlatformUtilsService.class);
JarElement jarElement = new JarElement();
jarElement.setName("abcd.jar");
jarElement.setPath("/tmp/abcd.jar");
jarElement.setType("ScheduleTask");
Set jarElementSet = new HashSet();
jarElementSet.add(jarElement);
platformUtilsService.uploadJars(jarElementSet );
System.out.println("Finish uploading jar" );
}
public void uploadJar() throws PlatformServiceException{
PlatformUtilsService platformUtilsService = (PlatformUtilsService) oimClient.getService(PlatformUtilsService.class);
JarElement jarElement = new JarElement();
jarElement.setName("abcd.jar");
jarElement.setPath("/tmp/abcd.jar");
jarElement.setType("ScheduleTask");
Set jarElementSet = new HashSet();
jarElementSet.add(jarElement);
platformUtilsService.uploadJars(jarElementSet );
System.out.println("Finish uploading jar" );
}
No comments:
Post a Comment