Sunday, August 30, 2009

Azure Logs

The convinient RoleManager.WriteToLog static method provides way to write event logs for your clouded application. In the reference:
http://msdn.microsoft.com/en-us/library/microsoft.servicehosting.serviceruntime.rolemanager.writetolog.aspx
you will find that the allowed values for "eventLogName" are:
Critical, Error, Warning, Information, Verbose

It's a good idea to have them handy :)

Here is a complete How-to guide for writing and reading logs:
http://blog.benday.com/archive/2008/11/07/23201.aspx

I will just add that there is a great tool at CodePlex: http://azurestorageexplorer.codeplex.com/
Which is visual storage explorer. Something that I missed is that account configuration requires restart of the application (at least for me). If you are going to wander how to configure your cloud storage - just enter your cloud storage account name (without http://, and without blob.core.windows.net, or queue.core.windows.net, etc.) and your primary or secondary key - it works with both keys.

No comments: