azureazure-storageazure-keyvaultazureportalazure-configuration

Azure portal. What is the best practise way to store and make deal with not single line application settings


Could someone advise, what is the best way to work with big application configurations which look like xml/json data? These data contain diff information(mostly static, but rarely it can be changed), but all of these data don't have security value. For instance, it can be item options for an user control(like dropdown) in an application page or static data which is used as markup on the basis of which an web page creates a user control for page and so on.

I have several approaches for this:

  1. Key vault. As I can undestand, the main idea of this storage is to work with security data like connection string, passwords and so on. How about using it to work with bigger and wider settings? The big plus for me, that this way contains built-in cache functionality, but it doesn't look like best practise way for me.
  2. Storage account/Cosmos db - as far as I see, both of these ways are used similar and can be used for my target. The question is what is the most economic and productive way for me and will these ways better then the Key Vault way?

So, what is the most common solution for this target?

Thanks.


Solution

  • Hm, I think this answer realy depends on your requirements.

    First of all, you can store / update and retrieve a complex configuration object in Azure App Services using the appsettings.json.

    If you want to stick to files (xml / json) then you could use Azure Blob Storage.

    If you just want to store larger configurations in a NoSQL store you could consider using Azure Table Storage (be aware that a single entry in the Table storage can only contain 252 properties and has a size limit of 1 MiB).

    If you need to query your configuration by a configuration property (not by a key) or you think you will exceed the Azure Table Storage limits, then you could consider using CosmosDb