Harnoor7 commented on code in PR #14503: URL: https://github.com/apache/pinot/pull/14503#discussion_r1858232713
########## pinot-controller/src/main/java/org/apache/pinot/controller/api/resources/ControllerFilePathProvider.java: ########## @@ -126,14 +128,38 @@ public URI getDataDirURI() { } public File getFileUploadTempDir() { + if (!Files.exists(_fileUploadTempDir.toPath())) { Review Comment: Added method to FileUtils. ########## pinot-controller/src/test/java/org/apache/pinot/controller/api/resources/PinotSegmentUploadDownloadRestletResourceTest.java: ########## @@ -56,20 +66,27 @@ public class PinotSegmentUploadDownloadRestletResourceTest { private static final String TABLE_NAME = "table_abc"; private static final String SEGMENT_NAME = "segment_xyz"; + private static final String HOST = "localhost"; + private static final String PORT = "12345"; + private static final File DATA_DIR = + new File(FileUtils.getTempDirectory(), "PinotSegmentUploadDownloadRestletResourceTest"); + private static final File LOCAL_TEMP_DIR = new File(DATA_DIR, "localTemp"); private PinotSegmentUploadDownloadRestletResource _resource = new PinotSegmentUploadDownloadRestletResource(); private File _encryptedFile; private File _decryptedFile; private File _tempDir; @BeforeMethod - public void setUp() throws IOException { + public void setUp() + throws IOException { _tempDir = new File(FileUtils.getTempDirectory(), "test-" + UUID.randomUUID()); FileUtils.forceMkdir(_tempDir); } @AfterMethod - public void tearDown() throws IOException { + public void tearDown() + throws IOException { Review Comment: done -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org For additional commands, e-mail: commits-h...@pinot.apache.org