ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » Workflow Engines - IBM MQ Workflow & Business Process Choreographer » Terminate Process Instance Via XML

Post new topic  Reply to topic
 Terminate Process Instance Via XML « View previous topic :: View next topic » 
Author Message
jfplata
PostPosted: Mon May 19, 2003 8:08 am    Post subject: Terminate Process Instance Via XML Reply with quote

Newbie

Joined: 12 May 2003
Posts: 2

I am trying to terminate a process instance using the XML interface that Workflow provides. I am sending a ProcessInstanceTerminate message. My XML message looks like this:

<?xml version="1.0" standalone="yes"?>
<WfMessage>
<WfMessageHeader>
</WfMessageHeader>
<ProcessInstanceTerminate>
<ProcInstName>TEST</ProcInstName>
</ProcessInstanceTerminate>
</WfMessage>

I need to know if my request was successful or not. I thought that by using ProcessInstanceTerminate, workflow will send a reply back to the queue that you specified when you send the message however I haven't received any replies. I also specify <ResponseRequired>Yes</ResponseRequired> in the XML message but I still don't get a reply. I changed my application so it waits at least 30 seconds before checking the Reply to Queue but I just get a 2033 error (No more messages). Has anyone tried to terminate a process instance and received a reply back from Workflow?
_________________
Jorge Plata
IBM Certified Solutions Expert - MQSeries Workflow
Back to top
View user's profile Send private message
jmac
PostPosted: Mon May 19, 2003 8:35 am    Post subject: Reply with quote

Jedi Knight

Joined: 27 Jun 2001
Posts: 3081
Location: EmeriCon, LLC

I have done this successfully many times. I am not certain what could be wrong.

Can you give us more information. Re is queue defined? Does instance actually terminate?

What version of MQWF
_________________
John McDonald
RETIRED
Back to top
View user's profile Send private message Send e-mail Visit poster's website AIM Address Yahoo Messenger MSN Messenger
jfplata
PostPosted: Mon May 19, 2003 10:01 am    Post subject: Reply with quote

Newbie

Joined: 12 May 2003
Posts: 2

The instance is actually terminated but I don't receive any responses. As far as the reply to Queue, it is defined. I also have a program that Starts a process instance via XML and I specify a Reply to Queue and it works fine, I get a response. For the terminate process instance request I am using the same reply to queue (just for now). You said that you have done this many times, did you receive a response when the instance is terminated (obviously if you requested one)? And when the terminate instance failed did you receive a response?
_________________
Jorge Plata
IBM Certified Solutions Expert - MQSeries Workflow
Back to top
View user's profile Send private message
jmac
PostPosted: Mon May 19, 2003 10:24 am    Post subject: Reply with quote

Jedi Knight

Joined: 27 Jun 2001
Posts: 3081
Location: EmeriCon, LLC

Jorge:

I will run some samples later today...

Have you checked that you are setting the ReplyToQ/Qmgr in the MQ header?

I will post the results of my tests later today
_________________
John McDonald
RETIRED
Back to top
View user's profile Send private message Send e-mail Visit poster's website AIM Address Yahoo Messenger MSN Messenger
vennela
PostPosted: Mon May 19, 2003 12:42 pm    Post subject: Reply with quote

Jedi Knight

Joined: 11 Aug 2002
Posts: 4055
Location: Hyderabad, India

I did this for you John

I am getting the response back nice and clear. All I did is I changed the program in the repository.

Code:

      MessageInXMLFmt = MessageInXMLFmt + "   <ProcessInstanceTerminate>"  + "\n";
      MessageInXMLFmt = MessageInXMLFmt + "      <ProcInstName>CreditRequest</ProcInstName>"  + "\n";
      MessageInXMLFmt = MessageInXMLFmt + "   </ProcessInstanceTerminate>"  + "\n";


I got this response

Code:
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<!-- This document is generated by a MQSeries Workflow Version 3.4.0 server -->

<WfMessage>
  <WfMessageHeader>
    <ResponseRequired>No</ResponseRequired>
    <UserContext>I want this data back</UserContext>
  </WfMessageHeader>
  <ProcessInstanceTerminateResponse>
    <ProcessInstance>
      <ProcInstID>UAAAAAEACwAAAAAAAAAAAAAAAAABAAHAAAAAAAAAAAAAUA==</ProcInstID>
      <ProcInstName>UAAAAAEACwAAAAAAAAAAAAAAAAABAAHAAAAAAAAAAAAAUA==CreditReques
t</ProcInstName>
      <ProcInstTopLevelName>UAAAAAEACwAAAAAAAAAAAAAAAAABAAHAAAAAAAAAAAAAUA==Cred
itRequest</ProcInstTopLevelName>
      <ProcInstDescription>Credit request</ProcInstDescription>
      <ProcInstState>Deleted</ProcInstState>
      <LastStateChangeTime>2003-05-19 20:36:04.084000</LastStateChangeTime>
      <LastModificationTime>2003-05-19 20:36:04.084000</LastModificationTime>
      <ProcTemplID>UQAAAAEAAcAAAAAAAAAAAABR</ProcTemplID>
      <ProcTemplName>CreditRequest</ProcTemplName>
      <ProcTemplValidFromDate>2003-05-06 17:12:34.046000</ProcTemplValidFromDate
>
      <Icon>FMCBPRC</Icon>
    </ProcessInstance>
  </ProcessInstanceTerminateResponse>
</WfMessage>




Jorge:
If you have a chance you may look at the sample 'ProcessTemplateCreateAndStartInstance' in the repository on this site and make modifications and see if it helps.
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » Workflow Engines - IBM MQ Workflow & Business Process Choreographer » Terminate Process Instance Via XML
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.