本文整理汇总了Java中org.wso2.carbon.dataservices.task.ui.stub.xsd.DSTaskInfo类的典型用法代码示例。如果您正苦于以下问题:Java DSTaskInfo类的具体用法?Java DSTaskInfo怎么用?Java DSTaskInfo使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
DSTaskInfo类属于org.wso2.carbon.dataservices.task.ui.stub.xsd包,在下文中一共展示了DSTaskInfo类的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: scheduleTask
import org.wso2.carbon.dataservices.task.ui.stub.xsd.DSTaskInfo; //导入依赖的package包/类
public void scheduleTask(DSTaskInfo dsTaskInfo) throws RemoteException {
try {
dsTaskAdminStub.scheduleTask(dsTaskInfo);
} catch (RemoteException e) {
log.error("Unable to add new task", e);
throw new RemoteException("Unable to add new task", e);
}
}
示例2: rescheduleTask
import org.wso2.carbon.dataservices.task.ui.stub.xsd.DSTaskInfo; //导入依赖的package包/类
public boolean rescheduleTask(DSTaskInfo dsTaskInfo) throws RemoteException {
try {
return dsTaskAdminStub.rescheduleTask(dsTaskInfo);
} catch (RemoteException e) {
log.error("Unable to rescheduleTask", e);
throw new RemoteException("Unable to rescheduleTask", e);
}
}
示例3: addScheduleTask
import org.wso2.carbon.dataservices.task.ui.stub.xsd.DSTaskInfo; //导入依赖的package包/类
@Test(groups = "wso2.dss", dependsOnMethods = {"serviceInvocation"}, description = "schedule a task",
enabled = false)
public void addScheduleTask() throws RemoteException, InterruptedException {
dsTaskInfo = new DSTaskInfo();
String[] taskNames = dssTaskClient.getAllTaskNames();
empSalary = getEmployeeSalary(getEmployeeById(employeeId));
if (taskNames != null) {
for (String task : taskNames) {
if (scheduleTaskName.equals(task)) {
dssTaskClient.deleteTask(scheduleTaskName);
log.info(scheduleTaskName + " already in scheduled. schedule task deleted");
Thread.sleep(10000);
break;
}
}
}
dsTaskInfo.setName(scheduleTaskName);
dsTaskInfo.setServiceName(serviceName);
dsTaskInfo.setOperationName("incrementEmployeeSalary");
dsTaskInfo.setTaskInterval(taskInterval);
dsTaskInfo.setTaskCount(-1);
dssTaskClient.scheduleTask(dsTaskInfo);
log.info("task scheduled");
try {
Thread.sleep(2000);
} catch (InterruptedException ignore) {
}
}
示例4: addScheduleTask
import org.wso2.carbon.dataservices.task.ui.stub.xsd.DSTaskInfo; //导入依赖的package包/类
@Test(groups = "wso2.dss", dependsOnMethods = {"serviceInvocation"})
public void addScheduleTask() throws RemoteException {
DSTaskInfo dsTaskInfo = new DSTaskInfo();
String[] taskNames = dssTaskClient.getAllTaskNames();
if (taskNames != null) {
for (String task : taskNames) {
if (scheduleTaskName.equals(task)) {
dssTaskClient.deleteTask(scheduleTaskName);
log.info(scheduleTaskName + " already exists. scheduleTask deleted");
try {
Thread.sleep(10000);
} catch (InterruptedException e) {
log.error("InterruptedException :", e);
Assert.fail("InterruptedException :" + e);
}
break;
}
}
}
dsTaskInfo.setName(scheduleTaskName);
dsTaskInfo.setServiceName(serviceName);
dsTaskInfo.setOperationName("incrementEmployeeSalary");
dsTaskInfo.setTaskInterval(taskInterval);
dsTaskInfo.setTaskCount(4);
dssTaskClient.scheduleTask(dsTaskInfo);
log.info("Task Scheduled");
try {
Thread.sleep(1000);
} catch (InterruptedException ignore) {
}
}
示例5: addScheduleTask
import org.wso2.carbon.dataservices.task.ui.stub.xsd.DSTaskInfo; //导入依赖的package包/类
@Test(groups = "wso2.dss", dependsOnMethods = {"serviceInvocation"})
public void addScheduleTask() throws RemoteException {
DSTaskInfo dsTaskInfo = new DSTaskInfo();
String[] taskNames = dssTaskClient.getAllTaskNames();
if (taskNames != null) {
for (String task : taskNames) {
if (scheduleTaskName.equals(task)) {
dssTaskClient.deleteTask(scheduleTaskName);
log.info(scheduleTaskName + " already exists. scheduleTask deleted");
try {
Thread.sleep(10000);
} catch (InterruptedException e) {
log.error("InterruptedException :", e);
Assert.fail("InterruptedException :" + e);
}
break;
}
}
}
dsTaskInfo.setName(scheduleTaskName);
dsTaskInfo.setServiceName(serviceName);
dsTaskInfo.setOperationName("incrementEmployeeSalary");
dsTaskInfo.setTaskInterval(taskInterval);
dsTaskInfo.setTaskCount(9);
dssTaskClient.scheduleTask(dsTaskInfo);
log.info("Task Scheduled");
try {
Thread.sleep(1000);
} catch (InterruptedException ignore) {
}
}
示例6: getTaskInfo
import org.wso2.carbon.dataservices.task.ui.stub.xsd.DSTaskInfo; //导入依赖的package包/类
public DSTaskInfo getTaskInfo(String taskName) throws Exception {
return this.stub.getTaskInfo(taskName);
}
示例7: scheduleTask
import org.wso2.carbon.dataservices.task.ui.stub.xsd.DSTaskInfo; //导入依赖的package包/类
public void scheduleTask(DSTaskInfo dsTaskInfo) throws Exception {
this.stub.scheduleTask(dsTaskInfo);
}
示例8: rescheduleTask
import org.wso2.carbon.dataservices.task.ui.stub.xsd.DSTaskInfo; //导入依赖的package包/类
public boolean rescheduleTask(DSTaskInfo dsTaskInfo) throws Exception {
return this.stub.rescheduleTask(dsTaskInfo);
}