persistence/jdbc/src/main/java/org/infinispan/persistence/jdbc/connectionfactory/HikariConnectionPool.java
// Load Hikari properties in priority of properties file specified in configuration then hikari.properties on the classpath
Load Hikari properties in priority of properties file specified in configuration then hikari.properties on the classpath
Load Hikari properties in priority of properties file specified in configuration then hikari . properties on the classpath
private Properties loadPropertiesFile(ClassLoader classLoader, PooledConnectionFactoryConfiguration poolConfig) {
      if (classLoader == null)
         return new Properties();
      FileLookup fileLookup = FileLookupFactory.newInstance();
      String propertyPath = poolConfig.propertyFile();
      InputStream is = null;
      try {
         if (propertyPath != null) {
            is = fileLookup.lookupFileStrict(propertyPath, classLoader);
         } else if (classLoader.getResource(HIKARI_PROPERTIES) != null) {
            is = fileLookup.lookupFileStrict(HIKARI_PROPERTIES, classLoader);
         }
         if (is != null) {
            Properties properties = new Properties();
            properties.load(is);
            return properties;
         }
      } catch (IOException e) {
         log.errorLoadingHikariCPProperties(PooledConnectionFactoryConfiguration.class.getName());
      }
      return new Properties();
   }
private Properties loadPropertiesFile ( ClassLoader classLoader , PooledConnectionFactoryConfiguration poolConfig ) { if ( classLoader == null ) return new Properties ( ) ; FileLookup fileLookup = FileLookupFactory . newInstance ( ) ; String propertyPath = poolConfig . propertyFile ( ) ; InputStream is = null ; try { if ( propertyPath != null ) { is = fileLookup . lookupFileStrict ( propertyPath , classLoader ) ; } else if ( classLoader . getResource ( HIKARI_PROPERTIES ) != null ) { is = fileLookup . lookupFileStrict ( HIKARI_PROPERTIES , classLoader ) ; } if ( is != null ) { Properties properties = new Properties ( ) ; properties . load ( is ) ; return properties ; } } catch ( IOException e ) { log . errorLoadingHikariCPProperties ( PooledConnectionFactoryConfiguration . class . getName ( ) ) ; } return new Properties ( ) ; }
Load Hikari properties in priority of properties file specified in configuration then hikari.properties on the classpath
Load Hikari properties in priority of properties file specified in configuration then hikari . properties on the classpath