Github user StephanEwen commented on a diff in the pull request: https://github.com/apache/flink/pull/3512#discussion_r106677799 --- Diff: flink-runtime/src/main/java/org/apache/flink/runtime/blob/BlobServer.java --- @@ -400,6 +418,47 @@ public void delete(BlobKey key) throws IOException { } /** + * Deletes the file associated with the given job and key if it exists in the local + * storage of the blob server. + * + * @param jobId JobID of the file in the blob store + * @param key String key of the file in the blob store + */ + @Override + public void delete(JobID jobId, String key) { + checkArgument(jobId != null, "Job id must not be null."); + checkArgument(key != null, "BLOB name must not be null."); + + final File localFile = BlobUtils.getStorageLocation(storageDir, jobId, key); + + if (localFile.exists()) { --- End diff -- From concurrency safety, it better to do `if (!delete && exists)`
--- 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 infrastruct...@apache.org or file a JIRA ticket with INFRA. ---