Reputation: 3
I am building an asp.net Web App hosted with azure. I have decided to use file system to store images instead of in the database, with the image path's stored in the database. The images are added by users, and they can add a lot at once, up to 100.
My question is, what are the limits on file system storage of images? Currently, they are all just being stored in a single directory. Eventually there will be thousands (possibly hundreds of thousands) images in a single directory. Will this have a drastic effect on performance when these images are embedded in a page? None of the images are bigger than 1 mb. Would it be better practice to make sub-directories?
Upvotes: 0
Views: 2362
Reputation: 1105
I strongly recommand to use Azure Blob storage to store file which is the best way to store static content in Azure.
And, if you have to scale your application in the future (web farm, azure web app or whatever that has more than one VM instance), storing files on the server is not a best practice.
You can find some "best practices" about static content like images on this page: https://msdn.microsoft.com/en-us/library/dn589776.aspx
And the Azure Storage documentation that will help you to get started: https://azure.microsoft.com/en-us/documentation/services/storage/
Hope this helps,
Julien
Upvotes: 3