David Yahalom posted on redgate Hub about innovative combination of Amazon Aurora, serverless Lambda and Simple Que Service to strecth MySQL beyond native capabilities.
Most commercial database systems are ‘monolithic’ and integrate a great deal of advanced functionality and capabilities directly into the database itself. As one example, both Microsoft and Oracle provide an asynchronous messaging/queuing mechanism that is part of the database engine.
When your run your MySQL databases as an Aurora MySQL cluster in Amazon Web Services, you also have access to the full set of powerful AWS ecosystem services and solutions which you can leverage where native database functionality is missing.
The article provide clear instructions how:
- Create an Amazon SQS Queue that will be used to store messages as JSON payloads
- Configure IAM Role and create a cluster parameter group
- Create a Lambda function which will use the SQS API to send and receive messages from Amazon SQS
- Invoke the Amazon Lambda function from within an Aurora MySQL Cluster using mysql.lambda_async
This is just one example of how you can extend the core functionality of MySQL by leveraging additional cloud-native components provided by AWS. You will also get screen grabs from AWS admin interface and sample code to implement everything above. Fantastic read!
[Read More]