Improved error handling in Batch.
Implemented mailings.