Added mail notifications and worked out how to handle output files in
the job manager