refactor s3 and data adapter to s3 and s3data adapter