[rt-users] scrip writing info

2012-06-28 Thread Christian Loos

Hi ,

is there any difference between the to scrips:

scrip1
Condition: User defined
Action: User defined
Custom condition: my condition
Custom action preparation code: return 1;
Custom action cleanup code: my action


scrip2
Condition: On Transaction
Action: User defined
Custom action preparation code: my condition
Custom action cleanup code: my action


Both scrip's do the same but I want to know if they are may be handled 
internally different.


Thanks!

Chris

Christian Loos
Network Documentation  Fibre Management
_
NETCOLOGNE Gesellschaft für Telekommunikation mbH   
Am Coloneum 9 | 50829 Köln

Tel: 0221 -276 | Fax: 0221 -7276 | Mobil: 0177 276

www.netcologne.de

Geschäftsführer: 
Dr. Hans Konle (Sprecher)

Dipl.-Ing. Karl-Heinz Zankel
Vorsitzender des Aufsichtsrates:
Dr. Andreas Cerbe
HRB 25580, AG Köln


Diese Nachricht (inklusive aller Anhänge) ist vertraulich. Sollten Sie diese 
Nachricht versehentlich erhalten haben, bitten wir, den Absender (durch 
Antwort-E-Mail) hiervon unverzüglich zu informieren und die Nachricht zu 
löschen. Die E-Mail darf in diesem Fall weder vervielfältigt noch in anderer 
Weise verwendet werden.




Re: [rt-users] scrip writing info

2012-06-28 Thread Kevin Falcone
On Thu, Jun 28, 2012 at 04:13:57PM +0200, Christian Loos wrote:
 is there any difference between the to scrips:

Since On Transaction is applicable to any transaction type and just
does a 'return 1', they should be quite similar.  The only win is that
in the former one, your Action will never be prepared/committed if the
condition fails, so it's one less Action for RT to iterate through.
In the latter, since On Transaction is always true, RT always has to
load and Prepare your action to see if it should run.  It depends how
heavy the action is.

-kevin

 scrip1
 Condition: User defined
 Action: User defined
 Custom condition: my condition
 Custom action preparation code:   return 1;
 Custom action cleanup code: my action
 
 
 scrip2
 Condition: On Transaction
 Action: User defined
 Custom action preparation code: my condition
 Custom action cleanup code: my action


pgpdcCVVk697D.pgp
Description: PGP signature