Class DataSourceService

  • All Implemented Interfaces:
    Supplier<io.agroal.api.AgroalDataSource>, org.jboss.msc.Service, org.jboss.msc.service.Service<io.agroal.api.AgroalDataSource>, org.jboss.msc.value.Value<io.agroal.api.AgroalDataSource>

    public class DataSourceService
    extends Object
    implements org.jboss.msc.service.Service<io.agroal.api.AgroalDataSource>, Supplier<io.agroal.api.AgroalDataSource>
    Defines an extension to provide DataSources based on the Agroal project
    Author:
    Luis Barreiro
    • Constructor Detail

      • DataSourceService

        public DataSourceService​(String dataSourceName,
                                 String jndiName,
                                 boolean jta,
                                 boolean connectable,
                                 boolean xa,
                                 io.agroal.api.configuration.supplier.AgroalDataSourceConfigurationSupplier dataSourceConfiguration)
    • Method Detail

      • start

        public void start​(org.jboss.msc.service.StartContext context)
                   throws org.jboss.msc.service.StartException
        Specified by:
        start in interface org.jboss.msc.Service
        Specified by:
        start in interface org.jboss.msc.service.Service<io.agroal.api.AgroalDataSource>
        Throws:
        org.jboss.msc.service.StartException
      • stop

        public void stop​(org.jboss.msc.service.StopContext context)
        Specified by:
        stop in interface org.jboss.msc.Service
        Specified by:
        stop in interface org.jboss.msc.service.Service<io.agroal.api.AgroalDataSource>
      • get

        public io.agroal.api.AgroalDataSource get()
        Specified by:
        get in interface Supplier<io.agroal.api.AgroalDataSource>
      • getDriverInjector

        public org.jboss.msc.value.InjectedValue<Class> getDriverInjector()
      • getAuthenticationContextInjector

        public org.jboss.msc.value.InjectedValue<org.wildfly.security.auth.client.AuthenticationContext> getAuthenticationContextInjector()
      • getCredentialSourceSupplierInjector

        public org.jboss.msc.value.InjectedValue<org.wildfly.common.function.ExceptionSupplier<org.wildfly.security.credential.source.CredentialSource,​Exception>> getCredentialSourceSupplierInjector()