I have written standalone application which is working in Windows Azure as startup task. I want to use some Web Role specific information in this application but when this application starts the web role is not ready yet. How to get web role specific information in my application which is already in service configuration?
I have written standalone application which is working in Windows Azure as startup task.
Share
With Windows Azure SDK 1.5 and above support to XPATH is included Service Configuration and Role Environment configuration so you can specify role specific settings or any other settings an ready then either at Startup task level or inside your Role code at run time. You can learn more about xpath here:
http://msdn.microsoft.com/en-us/library/windowsazure/hh404006.aspx
I have written a blog post to show how you can access Service Configuration settings in Windows Azure Startup Task:
http://blogs.msdn.com/b/avkashchauhan/archive/2011/11/09/how-to-access-service-configuration-settings-in-windows-azure-startup-task.aspx
So in your case when you can read those variables or settings in Startup task and pass as parameter to your standalone application and that will do for you.