added more logging in S3