Search code examples
azureazure-diagnostics

Do Azure Diagnostics run in Azure staging slot?


When collecting Azure diagnostic data, does the staging slot also send diagnostic data to the WadPerformanceCounters Table?

If so, how can I turn this off? Or how can I differentiate between staging/production when reading the diagnostics.

I don't want to display data about our website assuming it's all production when in fact part of it is the staging slot.


Solution

  • Yes - Windows Azure diagnostics runs in the Production and Staging slots. The only real difference between these two slots is the DNS name.

    As for enabling diagnostics, there is a good starting point at http://msdn.microsoft.com/en-us/library/gg433048.aspx. This provides links to a lot of info on Windows Azure diagnostics.

    I don't believe there is a way in the diagnostics table data (WadPerformanceCountersTable, for example) to distinguish between Production and Staging slots. You might be able to filter based off the RowKey value, which I believe contains the deploymentID and that would be different between Production and Staging.

    You could also use a different storage account for Production and Staging slots. It'd be a fairly quick update of the .cscfg that could be done at run time.