I have a worker role that I would like to get diagnoistics feedback on... after adding the appropriate connection string to the ServiceConfiguration.cscfg and the following code:
//DiagnosticMonitor.Start("DiagnosticsConnectionString");
DiagnosticMonitorConfiguration diagConfig = DiagnosticMonitor.GetDefaultInitialConfiguration();
diagConfig.WindowsEventLog.DataSources.Add("Application!*");
diagConfig.WindowsEventLog.ScheduledTransferPeriod = System.TimeSpan.FromMinutes(5.0);
diagConfig.Logs.ScheduledTransferPeriod = System.TimeSpan.FromMinutes(5.0);
Microsoft.WindowsAzure.Diagnostics.DiagnosticMonitor.Start("DiagnosticsConnectionString", diagConfig);
CrashDumps.EnableCollection(true);
When I call "System.Diagnostics.Trace.TraceInformation("test log") I expect to be able to find the record in the WADLogsTable of the target Azure Storage Account. Howver, the table doesn't exist- how is it created? None of the documentation I've read covers this.
Thanks in advance,
You'll want to set a log level filter, like:
diagConfig.Logs.ScheduledTransferLogLevelFilter = LogLevel.Information;
I have a more detailed answer here.
Note that occasionally, in the simulation environment, the tables don't get created immediately.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With