public static function registerType(string $type, string $class): void
    {
        if (isset(static::$types[$type])) {
            throw new ConfigException("Can not register database type={$type} when it was already registered");
        }

        static::$types[$type] = $class;
    }