How you can implement finally block in flow services ?
Answers were Sorted based on User's Feedback
Answer / vijay
Sequence{Main Block}[EXIT ON: SUCCESS]
Sequence{Try Block}[EXIT ON: FAILURE]
Sequence{Catch Block}[EXIT ON: DONE]
Sequence{Finally Block}[EXIT ON: DONE]// executes all the statements obviously (catch block in flow service is similar to finally block in java)
Is This Answer Correct ? | 22 Yes | 2 No |
Answer / haranadha reddy
Build your flow service like this:
Sequence{Main Block}[EXIT ON: SUCCESS]
Sequence{Try Block}[EXIT ON: FAILURE]
Sequence{catch Block}[EXIT ON: DONE]
Sequence{finally Block}[EXIT ON: FAILURE]
Thanks
Is This Answer Correct ? | 29 Yes | 10 No |
Answer / viay
Easy way to remember SFD(EXIT ON: SUCCESS,EXIT ON: FAILURE
EXIT ON: DONE)
Sequence{Main Block}[EXIT ON: SUCCESS]
Sequence{Try Block}[EXIT ON: FAILURE]
Sequence{Catch Block}[EXIT ON: DONE]
Sequence{Finally Block}[EXIT ON: FAILURE]
Is This Answer Correct ? | 9 Yes | 4 No |
Answer / a.v raviteja
Hi,
It depends on how you want it. There is no definite answer.
Case 1: If you want your flow to go Finally only when Catch fails:
Sequence{main}[EXIT ON: SUCCESS]
Sequence{try}[EXIT ON: FAILURE]
Sequence{catch}[EXIT ON: FAILURE]
Sequence{finally}[EXIT ON: DONE]
Case 2: If you want Finally to execute in all cases:
Sequence{main}[EXIT ON: SUCCESS]
Sequence{try}[EXIT ON: FAILURE]
Sequence{catch}[EXIT ON: DONE]
Sequence{finally}[EXIT ON: DONE]
Is This Answer Correct ? | 2 Yes | 0 No |
Answer / nanaji
Build your flow service like this:
Sequence{Main Block}[EXIT ON: SUCCESS]
Sequence{Try Block}[EXIT ON: FAILURE]
Sequence{Catch Block}[EXIT ON: DONE]
Sequence{Finally Block}[EXIT ON: FAILURE]
Is This Answer Correct ? | 6 Yes | 5 No |
Answer / sri
Sequence{Main Block}[EXIT ON: DONE]
Sequence{Try Block}[EXIT ON: SUCCESS]
Sequence{Catch Block}[EXIT ON:FAILURE ]
Sequence{Finally Block}[EXIT ON: DONE]
We need finally block to be executed in both failure and
success Scenario's
so,Main block and finally block should be DONE
We dont want Catch block to be executed in Success Scenario
So It should be False.
Is This Answer Correct ? | 1 Yes | 5 No |
Answer / ajitabh kumar sharma
Build your flow service like this:
Sequence{main}[EXIT ON: DONE]
Sequence{Try/Catch}[EXIT ON: SUCCESS]
Sequence{try}[EXIT ON: FAILURE]
Sequence{catch}[EXIT ON: FAILURE]
Sequence{finally}[EXIT ON: FAILURE]
I am sorry but the previous answer was incorrect. I have
tested this answer and this works as expected. Basically the
sequences are used to control the flow control behavior of
their inherent sequences.
Is This Answer Correct ? | 4 Yes | 27 No |
Answer / ajitabh kumar sharma
Build your flow service like this:
Sequence{main}[EXIT ON: DONE]
Sequence{try}[EXIT ON: FAILURE]
Sequence{catch}[EXIT ON: FAILURE]
Sequence{finally}[EXIT ON: FAILURE]
Is This Answer Correct ? | 4 Yes | 35 No |
What Are Input and Output Parameters?
how to debug a flowservice in webmethods
Hi I am using Wenmethods 7.1 since many years. I am on Webmethods project. Today my Boss asked me about CLSRIM (Webmethods service, when one server is down, automatically another will take over. Can you please throw some light on above ? OR from where can I get some help ? IT IS URGENT...... Komalika
use of finally block in exception handling in webmethods
How to Move Flow Steps?
what is difference between groups and ACL groups
Difference between custom sql ,dynamic sql ? when we use custom sql,when we use dynamic sql?
What are Structural transformations ?
Should we archive derived files?
what is meant by "Block time out" and "Expire time out " in jdbc adapter configuration
In JMS can we publish a document to multiple brokers ? If Possible ,how can we achieve that ?
in which scenario we will use no tx,in which scenarion we use local tx?