@Override
    public HadoopConf buildHadoopConfWithReadOnlyConfig(ReadonlyConfig readonlyConfig) {
        Configuration configuration = loadHiveBaseHadoopConfig(readonlyConfig);
        Config config = fillBucket(readonlyConfig, configuration);
        config =
                config.withValue(
                        S3ConfigOptions.S3A_AWS_CREDENTIALS_PROVIDER.key(),
                        ConfigValueFactory.fromAnyRef(
                                configuration.get(
                                        S3ConfigOptions.S3A_AWS_CREDENTIALS_PROVIDER.key())));
        config =
                config.withValue(
                        S3ConfigOptions.FS_S3A_ENDPOINT.key(),
                        ConfigValueFactory.fromAnyRef(
                                configuration.get(S3ConfigOptions.FS_S3A_ENDPOINT.key())));
        HadoopConf hadoopConf =
                HiveOnS3Conf.buildWithReadOnlyConfig(ReadonlyConfig.fromConfig(config));
        Map<String, String> propsWithPrefix = configuration.getPropsWithPrefix(StringUtils.EMPTY);
        hadoopConf.setExtraOptions(propsWithPrefix);
        return hadoopConf;
    }
@Test
    void fillBucketInHadoopConfPath() throws URISyntaxException {
        URL resource = S3StorageTest.class.getResource("/s3");
        String filePath = Paths.get(resource.toURI()).toString();
        HashMap<String, Object> map = new HashMap<>();
        map.put("hive.hadoop.conf-path", filePath);
        map.putAll(S3A.toMap());
        ReadonlyConfig readonlyConfig = ReadonlyConfig.fromMap(map);
        S3Storage s3Storage = new S3Storage();
        HadoopConf hadoopConf = s3Storage.buildHadoopConfWithReadOnlyConfig(readonlyConfig);
        assertHadoopConfForS3a(hadoopConf);
    }