Class QuartzConnectionProvider

  • All Implemented Interfaces:
    org.quartz.utils.ConnectionProvider

    public class QuartzConnectionProvider
    extends java.lang.Object
    implements org.quartz.utils.ConnectionProvider
    This is a hack to let Quartz access datasource beans from SprigContext Quartz support custom connection providers but not non primitive parameters for them
    • Constructor Detail

      • QuartzConnectionProvider

        public QuartzConnectionProvider()
    • Method Detail

      • setXaDataSource

        public void setXaDataSource​(boolean isXaDataSource)
        this is called by quartz (given by the configuration)
        Parameters:
        isXaDataSource - true if the datasource returned by this configuration provider should be the xa datasource
      • getConnection

        public java.sql.Connection getConnection()
                                          throws java.sql.SQLException
        Specified by:
        getConnection in interface org.quartz.utils.ConnectionProvider
        Throws:
        java.sql.SQLException
      • shutdown

        public void shutdown()
                      throws java.sql.SQLException
        Specified by:
        shutdown in interface org.quartz.utils.ConnectionProvider
        Throws:
        java.sql.SQLException
      • initialize

        public void initialize()
                        throws java.sql.SQLException
        Specified by:
        initialize in interface org.quartz.utils.ConnectionProvider
        Throws:
        java.sql.SQLException