public <C extends JdbiConfig<C>> C get(Class<C> configClass) {
        // we would computeIfAbsent if not for JDK-8062841 >:(
        final JdbiConfig<?> lookup = configs.get(configClass);
        if (lookup != null) {
            return configClass.cast(lookup);
        }
        C config = configClass.cast(configFactory(configClass).apply(this));
        return Optional.ofNullable(configClass.cast(configs.putIfAbsent(configClass, config))).orElse(config);
    }
Returns this registry's instance of the given config class. Creates an instance on-demand if this registry does
not have one of the given type yet.

@param configClass the config class type.
@param <C>         the config class type.
@return the given config class instance that belongs to this registry.
core/src/main/java/org/jdbi/v3/core/config/ConfigRegistry.java