Catch serialization errors when writing status file
Occasionally, the status file can't be written. Error messages is as follows:
[Error] Error in Serialize(): The process cannot access the file 'C:\Tools\AutoTx\var\status.xml' because it is being used by another process.
Instead of logging an error directly, we could have a counter and have the service try to rewrite the status file as soon as that counter is above zero even if the status hasn't changed. Only if the counter is above a threshold (2?) an error should be logged (and therefore an email be triggered).