Connecting to the Azure Storage service
In an Azure cloud service, the storage account name and access key are stored in the service configuration file. By convention, the account name and access key for data access are provided in a setting named DataConnectionString
. The account name and access key needed for Azure Diagnostics must be provided in a setting named Microsoft.WindowsAzure.Plugins.Diagnostics.ConnectionString
.
Tip
The DataConnectionString
setting must be declared in the ConfigurationSettings
section of the service definition file. However, unlike other settings, the connection string setting for Azure Diagnostics is implicitly defined when the Diagnostics module is specified in the Imports
section of the service definition file. Consequently, it must not be specified in the ConfigurationSettings
section.
A best practice is to use different storage accounts for application data and diagnostic data. This reduces the possibility of application data access being throttled by competition...