add s3/email logging