[rt-users] race condition with scrips updating db?

Chris Haumesser ch at awry.ws
Mon Apr 14 16:38:34 EDT 2008


I'm using the ExtractCustomFieldValues extension to extract an email 
address out of the body of a message and set it as the requestor of the 

My template first removes the original requestor from the ticket, then 
adds the new address as a requestor.  In the RT history for the ticket, 
I see this work correctly.

My Extraction scrip has a description '00_extract_fields' and the 
autoreply scrip has a description '20_autoreply_on_create'.  The scrips 
appear to be firing in the proper order (00_extract_fields first, then 
20_autoreply_on_create).  Nevertheless, the outgoing email in the 
autoreply picks up the address of the first requestor.

My theory is that this is a race condition: the autoreply scrip is 
properly firing after the extract scrip, but the extract scrip hasn't 
finished updating the database by the time the autoreply scrip starts.

Is there a way to test this theory and fix the problem?



More information about the rt-users mailing list