- Solution1): Routing Configuration has a "Delay Processing" in 8.51 Tools which takes rounded numbers whose minimum is one Min. In Real time one minute time is too much. But however this dealy Processing Configuration value can not used if the Service Operation Processing needs to be conditionally controlled.
- Solution 2: a) Make sure that Service configuration routing delay processing value is blank. b)Function TimeCapsule (http://peoplesofttechworld.blogspot.com/2011/03/codebits1.html) can be used in Handler Code Just in case Service Operation Delay processing needs to be controlled.
Wednesday, March 23, 2011
PeopleCode Help Bits 2
How to delay the Service Operation?
Wednesday, March 9, 2011
PeopleCode Help Bits 1
/*--PeopleCode Function: To make the thread wait for given time---*/
A) Function TimeCapsule(&sec As number) Returns boolean;
&nNum = 0;
&nNum1 = 0;
&WaitTill = AddToDateTime(%Datetime, 0, 0, 0, 0, 0, &seconds);
While &WaitTill > %Datetime
&nNum = &nNum + 1;
If &Condition Then
Return True;
Else
&nNum1 = &nNum1 + 1;
End-If;
End-While;
Return False;
End-Function;
B) This is equal to &jCls = GetJavaClass("java.lang.Thread").sleep(10);
Q) What is the difference between A) and B) ?
Ans: A) can be used to control the thread for a given time and exit after required condition is met where as B) can not be managed to exit before given time based on the condition result.
A) Function TimeCapsule(&sec As number) Returns boolean;
&nNum = 0;
&nNum1 = 0;
&WaitTill = AddToDateTime(%Datetime, 0, 0, 0, 0, 0, &seconds);
While &WaitTill > %Datetime
&nNum = &nNum + 1;
If &Condition Then
Return True;
Else
&nNum1 = &nNum1 + 1;
End-If;
End-While;
Return False;
End-Function;
B) This is equal to &jCls = GetJavaClass("java.lang.Thread").sleep(10);
Q) What is the difference between A) and B) ?
Ans: A) can be used to control the thread for a given time and exit after required condition is met where as B) can not be managed to exit before given time based on the condition result.
Subscribe to:
Posts (Atom)