Github user arina-ielchiieva commented on a diff in the pull request:
    --- Diff: exec/java-exec/src/test/java/org/apache/drill/ 
    @@ -639,14 +644,18 @@ protected static void 
copyDirectoryIntoTempSpace(String resourcesDir, String des
        * @param srcFileOnClassPath the source path of metadata cache file, 
which should be replaced
        * @param destFolderInTmp  the parent folder name of the metadata cache 
        * @param metaFileName the name of metadata cache file depending on the 
type of the metadata
    +   * @param customStringReplacement custom string to replace the 
"CUSTOM_REPLACED" target string in metadata file
        * @throws IOException if a create or write errors occur
    -  protected static void 
copyMetaDataCacheToTempReplacingInternalPaths(String srcFileOnClassPath, String 
    -      String metaFileName) throws IOException {
    +  protected static void copyMetaDataCacheToTempWithReplacements(String 
    +      String destFolderInTmp, String metaFileName, String 
customStringReplacement) throws IOException {
         String metadataFileContents = getFile(srcFileOnClassPath);
         Path rootMeta = new Path(dfsTestTmpSchemaLocation, destFolderInTmp);
         Path newMetaCache = new Path(rootMeta, metaFileName);
         FSDataOutputStream outSteam = fs.create(newMetaCache);
    +    if (customStringReplacement != null) {
    +      metadataFileContents = 
    +    }
    --- End diff --
    Please use try-with-resources to ensure that stream will be closed in any 

If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at or file a JIRA ticket
with INFRA.

Reply via email to