Class MySqlDelegateDriver


  • public final class MySqlDelegateDriver
    extends org.threadly.db.aurora.DelegateAuroraDriver
    Driver for creating connections to a given delegate implementation. This ultimately deals with creating a URL that is suited for that driver and then using it to establish the connection.
    • Constructor Summary

      Constructors 
      Constructor Description
      MySqlDelegateDriver()
      Construct a new delegate driver for the mysql driver com.mysql.cj.jdbc.Driver.
      MySqlDelegateDriver​(java.sql.Driver delegateDriver)
      Construct a new delegate driver for the mysql driver com.mysql.cj.jdbc.Driver.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.String getDriverName()  
      boolean isMasterServer​(org.threadly.db.aurora.AuroraServer server, java.sql.Connection serverConnection)  
      • Methods inherited from class org.threadly.db.aurora.DelegateAuroraDriver

        connect, driverForArcUrl, getAnyDelegateDriver, getArcPrefix, getDriver, getStatusConnectURLParams
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • MySqlDelegateDriver

        public MySqlDelegateDriver()
                            throws java.sql.SQLException
        Construct a new delegate driver for the mysql driver com.mysql.cj.jdbc.Driver.
        Throws:
        java.sql.SQLException - Thrown if the mysql driver throws an exception on construction
      • MySqlDelegateDriver

        public MySqlDelegateDriver​(java.sql.Driver delegateDriver)
        Construct a new delegate driver for the mysql driver com.mysql.cj.jdbc.Driver.
        Parameters:
        delegateDriver - Driver to use
    • Method Detail

      • getDriverName

        public java.lang.String getDriverName()
        Specified by:
        getDriverName in class org.threadly.db.aurora.DelegateAuroraDriver
      • isMasterServer

        public boolean isMasterServer​(org.threadly.db.aurora.AuroraServer server,
                                      java.sql.Connection serverConnection)
                               throws org.threadly.db.aurora.DelegateAuroraDriver.IllegalDriverStateException,
                                      java.sql.SQLException
        Specified by:
        isMasterServer in class org.threadly.db.aurora.DelegateAuroraDriver
        Throws:
        org.threadly.db.aurora.DelegateAuroraDriver.IllegalDriverStateException
        java.sql.SQLException