initial version with S3 support