Amazon Web Services (AWS) JDBC Driver for MySQL
Get started now

Amazon Web Services (AWS) JDBC Driver for MySQL allows an application to take advantage of the features of clustered MySQL databases. It is based on and can be used as a drop-in compatible for the MySQL Connector/J driver, and is compatible with all MySQL deployments.

The AWS JDBC Driver for MySQL also supports fast failover for Amazon Aurora with MySQL compatibility. Support for additional features of clustered databases, including features of Amazon RDS for MySQL and on-premises MySQL deployments is planned.

HOW IT WORKS

Developers use software libraries, known as database connectivity drivers (or simply drivers), to connect applications to databases. A driver converts SQL queries in an application into a protocol language to communicate with the database and returns query results to the application. The AWS JDBC Driver for MySQL is optimally configured to enable applications to connect to and take advantage of the features of clustered MySQL database deployments.

Enabling Fast Failover for Amazon Aurora
In Amazon Aurora, failover is a mechanism by which the database automatically repairs the cluster status when a primary DB instance becomes unavailable. It achieves this by electing a database replica to become the new primary DB instance, so that the cluster can provide maximum availability to a primary read-write DB instance.

Before a replica instance can be elevated to the role of primary DB instance, the DNS record must be updated in order to properly direct the connection. This process can take up to several minutes. The AWS JDBC Driver for MySQL is designed to coordinate with this behavior in order to provide minimal downtime. It achieves this by maintaining a cache of the MySQL cluster topology and each instance's role (replica or primary DB instance). This topology is provided via a direct query to the MySQL database, providing a shortcut to bypass the delays caused by DNS resolution. With this knowledge, the AWS JDBC Driver for MySQL can more closely monitor the database cluster status so that a connection to the new primary DB instance can be established as quickly as possible.

How the AWS JDBC Driver for MySQL works

The figure above provides a simplified overview of how the AWS JDBC Driver for MySQL handles an Amazon Aurora failover. Learn more>>

BENEFITS
Seamless Deployment
The AWS JDBC Driver for MySQL is based on and is backward compatible with the MySQL Connector/J driver, so users can replace the driver with few changes to their applications.
Increased Application Availability
In the event of an Amazon Aurora primary DB failure, the AWS JDBC Driver for MySQL supports fast failover to a replica, resulting in minimal impact to application availability and user experience.
FAQ
What does drop-in compatible mean?
The AWS JDBC Driver for MySQL is compatible with all MySQL deployments, whether they are on-premises or in the cloud. It currently enables fast failover capabilities for Amazon Aurora with MySQL compatibility only. The driver is based on and is backward compatible with the MySQL Connector/J driver. Changes to the connection string is all that is needed. Support for additional features of clustered databases, including features of Amazon RDS for MySQL and on-premises MySQL deployments, is planned.
How do I use the AWS JDBC Driver for MySQL?
The AWS JDBC Driver for MySQL is drop-in compatible for the MySQL Connector/J driver. You can replace your existing driver with the AWS JDBC Driver for MySQL following the same steps used to update an existing driver. A change to the connection string is all that is needed; you'll find detailed installation and upgrade instructions here.
How do I see the project roadmap?
You can view the roadmap for the AWS JDBC Driver for MySQL here.
How can I get help or open issues?
You can get help or open issues related to the AWS JDBC Driver for MySQL on Github here.
Where do I contribute to the project?
You can learn more about contributing to the driver on GitHub here.
Can I create my own driver from this?
Yes! The driver is open source under the General Public License v2. This means you are free to modify the driver to fit your particular needs.