Author |
Message
|
saurabh |
Posted: Sun Jul 31, 2005 10:37 pm Post subject: Failing Object: PEA |
|
|
Novice
Joined: 29 Jul 2005 Posts: 11 Location: Delhi, India
|
When invoking java activity implementation from my custom java client, i get the following error:
com.ibm.workflow.api.FmcException:
FMC38009E MQSeries Workflow API Error :
API Return Code : 13
Error Origin : e:\v350\src\fmcjccon.cxx, line 1254
Error Message : FMC00013E Communication error - Failing Action: GET, Reason Code: 13, Failing Object: PEA.
Nested Exception : None
activity implementation code snippet:
Agent agent = new Agent();
agent.setLocator(Agent.LOC_LOCATOR);
agent.setName("MQWFAgent");
service = agent.locate("","");
Thread.sleep(20000);
System.out.println("Logon service: "+service);
System.out.println("programExecutionAgentStartUp");
ExecutionAgent eAgent = agent.getExecutionAgent();
System.out.println("Logon successful");
ReadOnlyContainer incntr=eAgent.inContainer();
ReadWriteContainer outcntr= eAgent.outContainer();
ContainerElement[] leaves = new ContainerElement[200];
leaves=outcntr.allLeaves();
outcntr.setLong(leaves[0].fullName(),0);
calling client code snippet:
service.programExecutionAgentStartUp();
startItem.start();
service.programExecutionAgentShutDown(); |
|
Back to top |
|
 |
jmac |
Posted: Mon Aug 01, 2005 5:22 am Post subject: |
|
|
 Jedi Knight
Joined: 27 Jun 2001 Posts: 3081 Location: EmeriCon, LLC
|
Code: |
ExecutionAgent eAgent = agent.getExecutionAgent(); |
The above should be the ExecutionService, not ExecutionAgent. ExecutionAgent is only used in the program that is started. _________________ John McDonald
RETIRED |
|
Back to top |
|
 |
saurabh |
Posted: Mon Aug 01, 2005 7:54 am Post subject: |
|
|
Novice
Joined: 29 Jul 2005 Posts: 11 Location: Delhi, India
|
I'm sorry i dint get u, can u please elaborate.....the Programming Doc gives a sample activity implementation as follows:
try { // general try clause for whole example
Agent agent = new Agent();
agent.setLocator(Agent.LOC_LOCATOR);
agent.setName("LOCAL");
ExecutionService service = agent.locate("","");
System.out.println();
/************************************************************************/ /* First we cope with the activity’s INPUT container: */ /* - get the container */ /* - get the leaves of the container */ /* - display the member values */ /************************************************************************/ /*----- Get Input Container --------------------------------------------*/
ReadOnlyContainer inctnr;
ExecutionAgent eAgent = agent.getExecutionAgent();
inctnr = eAgent.inContainer();
out.write("\nReceived input container ’" + inctnr.type() + "’\n"); System.out.println("\nReceived input container ’" + inctnr.type() + "’\n");
/*----- Get Leave Count ------------------------------------------------*/
int ulLeafCount = inctnr.allLeafCount();
out.write("Input container AllLeafCount() = " + ulLeafCount + "\n");
that is what i've done too, and if i use ExecutionService instead of ExecutionAgent, then what wud be the method to get the incontainer and outcontainer?
Thanks for the help |
|
Back to top |
|
 |
jmac |
Posted: Mon Aug 01, 2005 8:06 am Post subject: |
|
|
 Jedi Knight
Joined: 27 Jun 2001 Posts: 3081 Location: EmeriCon, LLC
|
Sorry... I looked at your code backwards....
The code in your original post is fine....
Who are you logging on in your client code? It should be one of the users assigned to run the activity.... If that is what you are doing, then I don't see what the problem is. Can you run this activity implementation from the "fat client"? _________________ John McDonald
RETIRED |
|
Back to top |
|
 |
jmac |
Posted: Mon Aug 01, 2005 8:29 am Post subject: |
|
|
 Jedi Knight
Joined: 27 Jun 2001 Posts: 3081 Location: EmeriCon, LLC
|
Forgot one thing. If you are running 3.6 and using the Native Java API, the PEA is not fully supported... please consult the doc for complete info. _________________ John McDonald
RETIRED |
|
Back to top |
|
 |
saurabh |
Posted: Mon Aug 01, 2005 9:51 am Post subject: |
|
|
Novice
Joined: 29 Jul 2005 Posts: 11 Location: Delhi, India
|
I'm using Workflow 3.5 with native java API.
I was using the normal WF API earlier, but it dint work well, when using JBoss as the application server to launch my custom WF client. Thus i had to shift to Java Native API. The workflow client works fine otherwise, and the activity implementation also works well when invoked from the WF runtime client.
But when the same activity implementation is invoked from my custom java client, i get a communication error with failing object as the PEA. Please suggest a workaround for this problem, i shall be obliged.
Note: I've started the PEA from the custom client properly, and i'm trying to start a workitem which is authorised to that user. And yes i'm able to run this activity from the workflow runtime client. The activity is a manual activity so i dont see the usage of UPES in this context, i hope i'm right. Please suggest a way out.
Thanks
Last edited by saurabh on Mon Aug 01, 2005 9:56 am; edited 1 time in total |
|
Back to top |
|
 |
jmac |
Posted: Mon Aug 01, 2005 9:55 am Post subject: |
|
|
 Jedi Knight
Joined: 27 Jun 2001 Posts: 3081 Location: EmeriCon, LLC
|
I would suggest that you look at all of the restrictions around using the Native Java API and a PEA. I have no experience with this, as I simply do not use PEAs anymore. _________________ John McDonald
RETIRED |
|
Back to top |
|
 |
saurabh |
Posted: Mon Aug 01, 2005 9:58 am Post subject: |
|
|
Novice
Joined: 29 Jul 2005 Posts: 11 Location: Delhi, India
|
Is using UPES a workaround in this case....? Please suggest a solution....Thanks alot |
|
Back to top |
|
 |
saurabh |
Posted: Mon Aug 01, 2005 10:02 am Post subject: |
|
|
Novice
Joined: 29 Jul 2005 Posts: 11 Location: Delhi, India
|
After debugging, what i come to know is that the exception occurs when it enconters the code:
ReadOnlyContainer inctr=eAgent.incontainer();
where eAgent is the ExecutionAgent |
|
Back to top |
|
 |
jmac |
Posted: Mon Aug 01, 2005 10:05 am Post subject: |
|
|
 Jedi Knight
Joined: 27 Jun 2001 Posts: 3081 Location: EmeriCon, LLC
|
saurabh wrote: |
Is using UPES a workaround in this case....? Please suggest a solution....Thanks alot |
Since a UPES does not require a PEA I would say yes... However, it appears to me that you really need to understand a little better what you are doing with MQWF. _________________ John McDonald
RETIRED |
|
Back to top |
|
 |
saurabh |
Posted: Mon Aug 01, 2005 10:12 am Post subject: |
|
|
Novice
Joined: 29 Jul 2005 Posts: 11 Location: Delhi, India
|
jmac wrote: |
However, it appears to me that you really need to understand a little better what you are doing with MQWF. |
Agreed..... ) |
|
Back to top |
|
 |
|