code: public static void configureNamingStrategy(final String datasourceName, final Object strategy) throws ClassNotFoundException, InstantiationException, IllegalAccessException {
          Class<?> namingStrategyClass = null;
          NamingStrategy namingStrategy;
          if (strategy instanceof Class<?>) {
              namingStrategyClass = (Class<?>)strategy;
          }
          else if (strategy instanceof CharSequence) {
              namingStrategyClass = Thread.currentThread().getContextClassLoader().loadClass(strategy.toString());
          }
  
          if (namingStrategyClass == null) {
              namingStrategy = (NamingStrategy)strategy;
          }
          else {
              namingStrategy = (NamingStrategy)namingStrategyClass.newInstance();
          }
  
          NAMING_STRATEGIES.put(datasourceName, namingStrategy);
      }
docs: Override the default naming strategy given a Class or a full class name,
  or an instance of a NamingStrategy.
  
  @param datasourceName the datasource name
  @param strategy  the class, name, or instance
  @throws ClassNotFoundException When the class was not found for specified strategy
  @throws InstantiationException When an error occurred instantiating the strategy
  @throws IllegalAccessException When an error occurred instantiating the strategy