Divij Vaidya created KAFKA-13929:
------------------------------------

             Summary: Replace File.createNewFile() with Files.createFile()
                 Key: KAFKA-13929
                 URL: https://issues.apache.org/jira/browse/KAFKA-13929
             Project: Kafka
          Issue Type: Sub-task
            Reporter: Divij Vaidya
            Assignee: Divij Vaidya


File.createNewFile() returns a boolean signifying whether the file creation was 
successful or not.

There are multiple places in the Kafka code base where we are not checking the 
value of the returned boolean. 

Replacing it with the Files.createFile() API will decrease the chances of 
inadvertent bugs in the code base since Files.createFile() API thrown 
exceptions when the creation is not successful.



--
This message was sent by Atlassian Jira
(v8.20.7#820007)

Reply via email to