Ask a question
Analysis of file storage strategy
If you would like to ask in the servers store a lot of files uploaded by a user, can adopt what strategy? To guarantee a certain rationality and performance
For example: one of my idea is: according to upload files in the database of ID after the four (or more, less) hash to first level, and then according to the four hash for two layers, each layer of about 1000 folder, in the third layer folder will limit the number of files. The.
Thought is probably the way！
What about this hierarchical strategy?
Or have any good strategy, please tell the reasons~~~
November 12, 2016 - 12:23 AM
The first layer is a directory with the last three, the 4~6 second directory, so the two layer directory every 1000 at the most, the underlying directory follow one's own inclination, if can also to the 1000 words, you will support the 1000000000 documents.
With the top four has no meaning, because the four little change, with the hash has no meaning, ID should already be digital, right?
November 17, 2016 - 12:33 AM
More than 10,000 Technical Questions Answered on Programering!
Ask A Question
code for alphabet indexer
How to get banned users in listbox with muc c#
Direct write to HardDisk, WriteFile returns 5 access denied error
Android For school project
Need Detailed view of the following URl