[JBoss jBPM] - Re: How to reassign from group to actor using CommandService
by gfargone
Here is some code I was trying:
// Get context.
InitialContext ic = new InitialContext();
// Find the command service bean.
rcs = (RemoteCommandServiceHome) ic.lookup("ejb/CommandServiceBean");
// Create a new process instance.
StartProcessInstanceCommand newProcessInstance = new StartProcessInstanceCommand();
newProcessInstance.setProcessName("CreateDevice");
newProcessInstance.setStartTransitionName("start");
newProcessInstance.setActorId("ffvnqb");
// Set process variables.
newProcessInstance.setVariables(varMap);
ProcessInstance procInst = (ProcessInstance) rcs.create().execute(newProcessInstance);
Long processId = procInst.getId();
System.out.println("Process Id: " + processId);
long taskInstanceId = 0;
// Get task list. Include task variables.
GetTaskListCommand taskListCommand = new GetTaskListCommand("admin",true);
List taskInstanceList = (List) rcs.create().execute(taskListCommand);
for (TaskInstance task : taskInstanceList) {
System.out.println("Task Name: " + task.getName());
System.out.println("Task Instance Id: " + task.getId());
System.out.println("Original Task Assignment: " + task.getActorId());
taskInstanceId = task.getId();
}
//
StartWorkOnTaskCommand startTaskCommand = new StartWorkOnTaskCommand(taskInstanceId, true);
rcs.create().execute(startTaskCommand);
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4222433#4222433
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4222433
15 years, 10 months
[Installation, Configuration & DEPLOYMENT] - Hot deployment of jar which isn't an EJB
by mikemil
I am encountering a problem trying to get a new copy of jar deployed.
Background: we have an administrative server that updates some encryption information, puts the data in a jar and delivers the jar thru JMS to our other servers. The recipient server receives the JMS msg and writes the file with a temporary name to our exploded ear folder. The problem occurs with our next step: we attempt to delete the existing jar and then rename the temporary named jar to the correct name. Both the delete and the rename fail - presumably because JBoss has those files loaded????
I tried just copying the new jar to the deploy/ folder like the documentation say (we are using 4.0.5 and 4.2.3) but nothing happens. The jar does not contain an EJB, just a flat file containing encryption keys. I am guessing that JBoss'd deployment scanner may see the file but doesn't really know where to deploy the jar to? We originally deploy the jar to the top level of our exploded ear folder structure but it is not references in the application.xml or anywhere.
This all works in Weblogic, maybe because we use the Staged approach.
Am I doing something wrong or is there a better approach to get a jar deployed to the correct folder???
Thanks,
Mike
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4222424#4222424
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4222424
15 years, 10 months