Excellent post. Another technique for generating unique file names would be to rely on the database as the source of truth. Usually when you upload a file you also save a record in the database for that file. You can include the primary key value of the record in the file name to make it unique.
I have also seen UUIDs being used as file names which is more akin to your solution.
Excellent post. Another technique for generating unique file names would be to rely on the database as the source of truth. Usually when you upload a file you also save a record in the database for that file. You can include the primary key value of the record in the file name to make it unique.
I have also seen UUIDs being used as file names which is more akin to your solution.
These are also excellent solutions.