Posted On: Oct 31, 2023
Amazon S3 Object Lambda now integrates with Amazon Athena, allowing you to automatically modify S3 data as it is being queried. With S3 Object Lambda, you can add your own code to S3 GET, HEAD, and LIST API requests to modify data as it is returned to your application. For example, you can use a Lambda function to automatically mask sensitive data columns when running queries in Amazon Athena. When you use S3 Object Lambda with Amazon Athena, you can more easily customize your data for different applications, without having to maintain multiple derivative copies of source data in Amazon S3.
To get started, create an S3 Object Lambda Access Point for your S3 bucket, and then use the alias as the source location when creating an Amazon Athena table instead of specifying an S3 bucket. This will automatically invoke your Lambda function when you run a query in Amazon Athena.
Aliases for S3 Object Lambda Access Points are available to use with Amazon Athena in all AWS Regions, excluding the AWS GovCloud (US) Regions. You can use S3 Object Lambda through the AWS Management Console, AWS Command Line Interface (CLI), Application Programming Interface (API), or AWS Software Development Kit (SDK) client. For pricing information, please visit the Amazon S3 pricing page. To learn more about S3 Object Lambda, visit the product detail page, or the S3 user guide.