Closed gsbelarus closed 9 months ago
@gsbelarus Thank you for pointing this out.
My interest in using the timestamp is not just for it to be unique. Rather, it has also to do with the temp files being sorted in chronological order as how they appear in a list, usually in an IDE. However, I do understand your point that if there are multiple calls made in an async way, they might all be processed at the same time essentially leading to files overlapping and that is not good.
So, I believe the best way to tackle this and preserve the chronological order is by having a global iterator for files that we increment the iterator and append to the file name after the timestamp, thereby preserving the chronological order.
Replace current time with UUID: