Code review comment: Fighting against the IDE, sure I will!

Code under review:
public AgroalDataSource doCreateDataSource(String dataSourceName) {
        if (!dataSourceSupport.entries.containsKey(dataSourceName)) {
            throw new IllegalArgumentException("No datasource named '" + dataSourceName + "' exists");
        }

        DataSourceJdbcBuildTimeConfig dataSourceJdbcBuildTimeConfig = getDataSourceJdbcBuildTimeConfig(dataSourceName);
        DataSourceRuntimeConfig dataSourceRuntimeConfig = getDataSourceRuntimeConfig(dataSourceName);
        DataSourceJdbcRuntimeConfig dataSourceJdbcRuntimeConfig = getDataSourceJdbcRuntimeConfig(dataSourceName);
        LegacyDataSourceJdbcBuildTimeConfig legacyDataSourceJdbcBuildTimeConfig = getLegacyDataSourceJdbcBuildTimeConfig(
                dataSourceName);
        LegacyDataSourceRuntimeConfig legacyDataSourceRuntimeConfig = getLegacyDataSourceRuntimeConfig(dataSourceName);
        LegacyDataSourceJdbcRuntimeConfig legacyDataSourceJdbcRuntimeConfig = getLegacyDataSourceJdbcRuntimeConfig(
                dataSourceName);

        DataSourceSupport.Entry matchingSupportEntry = dataSourceSupport.entries.get(dataSourceName);
        boolean isLegacy = matchingSupportEntry.isLegacy;
        if (!isLegacy) {
            if (!dataSourceJdbcRuntimeConfig.url.isPresent() && legacyDataSourceRuntimeConfig.url.isPresent()) {
                String errorMessage;
                if (DataSourceUtil.isDefault(dataSourceName)) {
                    errorMessage = "`quarkus.datasource.url` is deprecated and will be removed in a future version - it is " +
                            "recommended to switch to `quarkus.datasource.jdbc.url`. See https:
                } else {
                    errorMessage = "`quarkus.datasource." + dataSourceName
                            + ".url` is deprecated and will be removed in a future version - it is " +
                            "recommended to switch to `quarkus.datasource." + dataSourceName
                            + ".jdbc.url`. See https:
                }
                throw new ConfigurationException(errorMessage);
            }

            if (!dataSourceJdbcRuntimeConfig.url.isPresent()) {
                String errorMessage;
                if (DataSourceUtil.isDefault(dataSourceName)) {
                    errorMessage = "`quarkus.datasource.jdbc.url` has not been defined";
                } else {
                    errorMessage = "`quarkus.datasource.jdbc." + dataSourceName + ".url` has not been defined";
                }
                throw new ConfigurationException(errorMessage);
            }
        } else {
            if (!legacyDataSourceRuntimeConfig.url.isPresent()) {
                String errorMessage;
                if (DataSourceUtil.isDefault(dataSourceName)) {
                    errorMessage = "`quarkus.datasource.url` has not been defined";
                } else {
                    errorMessage = "`quarkus.datasource." + dataSourceName + ".url` has not been defined";
                }
                throw new ConfigurationException(errorMessage);
            }
        }

        
        loadDriversInTCCL();

        String resolvedDriverClass = matchingSupportEntry.resolvedDriverClass;
        Class<?> driver;
        try {
            driver = Class.forName(resolvedDriverClass, true, Thread.currentThread().getContextClassLoader());
        } catch (ClassNotFoundException e) {
            throw new RuntimeException(
                    "Unable to load the datasource driver " + resolvedDriverClass + " for datasource " + dataSourceName, e);
        }

        String resolvedDbKind = matchingSupportEntry.resolvedDbKind;
        InstanceHandle<AgroalConnectionConfigurer> agroalConnectionConfigurerHandle = Arc.container().instance(
                AgroalConnectionConfigurer.class,
                new JdbcDriverLiteral(resolvedDbKind));

        AgroalDataSourceConfigurationSupplier dataSourceConfiguration = new AgroalDataSourceConfigurationSupplier();

        
        if (!dataSourceJdbcRuntimeConfig.poolingEnabled) {
            dataSourceConfiguration.dataSourceImplementation(DataSourceImplementation.AGROAL_POOLLESS);
        }

        AgroalConnectionPoolConfigurationSupplier poolConfiguration = dataSourceConfiguration.connectionPoolConfiguration();
        AgroalConnectionFactoryConfigurationSupplier connectionFactoryConfiguration = poolConfiguration
                .connectionFactoryConfiguration();

        boolean mpMetricsPresent = dataSourceSupport.mpMetricsPresent;
        if (!isLegacy) {
            applyNewConfiguration(dataSourceConfiguration, poolConfiguration, connectionFactoryConfiguration, driver,
                    dataSourceJdbcBuildTimeConfig, dataSourceRuntimeConfig, dataSourceJdbcRuntimeConfig, mpMetricsPresent);
        } else {
            applyLegacyConfiguration(dataSourceConfiguration, poolConfiguration, connectionFactoryConfiguration, driver,
                    dataSourceRuntimeConfig, legacyDataSourceJdbcBuildTimeConfig, legacyDataSourceRuntimeConfig,
                    legacyDataSourceJdbcRuntimeConfig, mpMetricsPresent);
        }

        if (dataSourceSupport.disableSslSupport) {
            if (agroalConnectionConfigurerHandle.isAvailable()) {
                agroalConnectionConfigurerHandle.get().disableSslSupport(resolvedDbKind,
                        dataSourceConfiguration);
            } else {
                log.warnv("Agroal does not support disabling SSL for database kind: {0}",
                        resolvedDbKind);
            }
        }

        
        AgroalDataSourceConfiguration agroalConfiguration = dataSourceConfiguration.get();
        AgroalDataSource dataSource = new io.agroal.pool.DataSource(agroalConfiguration,
                new AgroalEventLoggingListener(
                        dataSourceName));
        log.debugv("Started datasource {0} connected to {1}", dataSourceName,
                agroalConfiguration.connectionPoolConfiguration().connectionFactoryConfiguration().jdbcUrl());

        
        Collection<AgroalPoolInterceptor> interceptorList = agroalPoolInterceptors
                .select(dataSourceName == null || DataSourceUtil.isDefault(dataSourceName)
                        ? Default.Literal.INSTANCE
                        : new DataSource.DataSourceLiteral(dataSourceName))
                .stream().collect(Collectors.toList());
        if (!interceptorList.isEmpty()) {
            dataSource.setPoolInterceptors(interceptorList);
        }

        return dataSource;
    }

Line commented on: dataSourceName));

Revised code:
public AgroalDataSource doCreateDataSource(String dataSourceName) {
        if (!dataSourceSupport.entries.containsKey(dataSourceName)) {
            throw new IllegalArgumentException("No datasource named '" + dataSourceName + "' exists");
        }

        DataSourceJdbcBuildTimeConfig dataSourceJdbcBuildTimeConfig = getDataSourceJdbcBuildTimeConfig(dataSourceName);
        DataSourceRuntimeConfig dataSourceRuntimeConfig = getDataSourceRuntimeConfig(dataSourceName);
        DataSourceJdbcRuntimeConfig dataSourceJdbcRuntimeConfig = getDataSourceJdbcRuntimeConfig(dataSourceName);
        LegacyDataSourceJdbcBuildTimeConfig legacyDataSourceJdbcBuildTimeConfig = getLegacyDataSourceJdbcBuildTimeConfig(
                dataSourceName);
        LegacyDataSourceRuntimeConfig legacyDataSourceRuntimeConfig = getLegacyDataSourceRuntimeConfig(dataSourceName);
        LegacyDataSourceJdbcRuntimeConfig legacyDataSourceJdbcRuntimeConfig = getLegacyDataSourceJdbcRuntimeConfig(
                dataSourceName);

        DataSourceSupport.Entry matchingSupportEntry = dataSourceSupport.entries.get(dataSourceName);
        boolean isLegacy = matchingSupportEntry.isLegacy;
        if (!isLegacy) {
            if (!dataSourceJdbcRuntimeConfig.url.isPresent()) {
                String errorMessage;
                if (!legacyDataSourceRuntimeConfig.url.isPresent()) {
                    
                    if (DataSourceUtil.isDefault(dataSourceName)) {
                        errorMessage = "quarkus.datasource.jdbc.url has not been defined";
                    } else {
                        errorMessage = "quarkus.datasource." + dataSourceName + ".jdbc.url has not been defined";
                    }
                } else {
                    
                    if (DataSourceUtil.isDefault(dataSourceName)) {
                        errorMessage = "Using legacy quarkus.datasource.url with a db-kind is not supported, please use "
                                + " quarkus.datasource.jdbc.url instead. See https:
                    } else {
                        errorMessage = "Using legacy quarkus.datasource." + dataSourceName
                                + ".url with a db-kind is not supported, please use "
                                + "quarkus.datasource." + dataSourceName + ".jdbc.url "
                                + "instead. See https:
                    }
                }
                throw new ConfigurationException(errorMessage);
            }
        } else {
            if (!legacyDataSourceRuntimeConfig.url.isPresent()) {
                String errorMessage;
                if (DataSourceUtil.isDefault(dataSourceName)) {
                    errorMessage = "quarkus.datasource.url has not been defined";
                } else {
                    errorMessage = "quarkus.datasource." + dataSourceName + ".url has not been defined";
                }
                throw new ConfigurationException(errorMessage);
            }
        }

        
        loadDriversInTCCL();

        String resolvedDriverClass = matchingSupportEntry.resolvedDriverClass;
        Class<?> driver;
        try {
            driver = Class.forName(resolvedDriverClass, true, Thread.currentThread().getContextClassLoader());
        } catch (ClassNotFoundException e) {
            throw new RuntimeException(
                    "Unable to load the datasource driver " + resolvedDriverClass + " for datasource " + dataSourceName, e);
        }

        String resolvedDbKind = matchingSupportEntry.resolvedDbKind;
        InstanceHandle<AgroalConnectionConfigurer> agroalConnectionConfigurerHandle = Arc.container().instance(
                AgroalConnectionConfigurer.class,
                new JdbcDriverLiteral(resolvedDbKind));

        AgroalDataSourceConfigurationSupplier dataSourceConfiguration = new AgroalDataSourceConfigurationSupplier();

        
        if (!dataSourceJdbcRuntimeConfig.poolingEnabled) {
            dataSourceConfiguration.dataSourceImplementation(DataSourceImplementation.AGROAL_POOLLESS);
        }

        AgroalConnectionPoolConfigurationSupplier poolConfiguration = dataSourceConfiguration.connectionPoolConfiguration();
        AgroalConnectionFactoryConfigurationSupplier connectionFactoryConfiguration = poolConfiguration
                .connectionFactoryConfiguration();

        boolean mpMetricsPresent = dataSourceSupport.mpMetricsPresent;
        if (!isLegacy) {
            applyNewConfiguration(dataSourceConfiguration, poolConfiguration, connectionFactoryConfiguration, driver,
                    dataSourceJdbcBuildTimeConfig, dataSourceRuntimeConfig, dataSourceJdbcRuntimeConfig, mpMetricsPresent);
        } else {
            applyLegacyConfiguration(dataSourceConfiguration, poolConfiguration, connectionFactoryConfiguration, driver,
                    dataSourceRuntimeConfig, legacyDataSourceJdbcBuildTimeConfig, legacyDataSourceRuntimeConfig,
                    legacyDataSourceJdbcRuntimeConfig, mpMetricsPresent);
        }

        if (dataSourceSupport.disableSslSupport) {
            if (agroalConnectionConfigurerHandle.isAvailable()) {
                agroalConnectionConfigurerHandle.get().disableSslSupport(resolvedDbKind,
                        dataSourceConfiguration);
            } else {
                log.warnv("Agroal does not support disabling SSL for database kind: {0}",
                        resolvedDbKind);
            }
        }

        
        AgroalDataSourceConfiguration agroalConfiguration = dataSourceConfiguration.get();
        AgroalDataSource dataSource = new io.agroal.pool.DataSource(agroalConfiguration,
                new AgroalEventLoggingListener(dataSourceName));
        log.debugv("Started datasource {0} connected to {1}", dataSourceName,
                agroalConfiguration.connectionPoolConfiguration().connectionFactoryConfiguration().jdbcUrl());

        
        Collection<AgroalPoolInterceptor> interceptorList = agroalPoolInterceptors
                .select(dataSourceName == null || DataSourceUtil.isDefault(dataSourceName)
                        ? Default.Literal.INSTANCE
                        : new DataSource.DataSourceLiteral(dataSourceName))
                .stream().collect(Collectors.toList());
        if (!interceptorList.isEmpty()) {
            dataSource.setPoolInterceptors(interceptorList);
        }

        return dataSource;
    }