[rt-users] scrip writing info

Kevin Falcone falcone at bestpractical.com
Thu Jun 28 12:47:59 EDT 2012


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"
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 195 bytes
Desc: not available
URL: <http://lists.bestpractical.com/pipermail/rt-users/attachments/20120628/c152bdd2/attachment.sig>


More information about the rt-users mailing list