Questions tagged [azure-web-roles]

A Microsoft Azure Web Role is a Windows Server Compatible Virtual Machine (VM) with IIS enabled, along with scaffolding code that provides a launch point for your own code to run within the VM.

Web Roles and Worker Roles form the basis of the Azure Cloud Services PaaS offering, removing the need for developers to manage the platform on which their applications will run.

The primary difference between a Web Role and Worker Role is the enabling of IIS. Both Web Roles and Worker Roles may run the same code, though it's often useful to split code between different roles for scaling purposes.

Within Visual Studio, you'll also see a slightly different role template, but the 4 primary events/overrides are available in both:

  • OnStart()
  • Run()
  • Stopping()
  • OnStop()

Further: If apps need to be installed (or registry changes are needed), and those tasks need elevated privileges, there's the ability to run startup tasks, which execute prior to OnStart().

In either roles you can choose the type of operating system running by modifying the service configuration file (.cscfg). Possible options are:

  • osFamily 1: equivalent of Windows Server 2008 SP2 x64
  • osFamily 2: equivalent of Windows Server 2008 R2
  • osFamily 3: equivalent of Windows Server 2012
  • osFamily 4: equivalent of Windows Server 2012 R2

You can read more about service configuration schema here.

1139 questions
6
votes
1 answer

Which is the right function to call in a jsp page to verify the logged user is in role

I'm looking for the function to verify if the user logged belongs to a role. is maybe the following? pageContext.request.userPrincipal.roles How should I use it properly along with JSTL to test if the user belong to ADMIN group?
Mazzy
  • 13,354
  • 43
  • 126
  • 207
6
votes
1 answer

Chrome34 ignores cookies with domain ".cloudapp.net"

After a lot of debugging from our dev/test environments hosted as web roles in Azure, that suddenly stopped working with Chrome 34, we realize that Chrome was ignoring the set-cookie response that has cookies with domain name ".cloudapp.net" (the…
iamnicoj
  • 487
  • 7
  • 13
6
votes
2 answers

How can I allow other users to deploy to my Azure cloud services?

I created an empty Azure cloud service and I want to allow other developers to deploy to it. So far the only route I can see is adding the developers as Azure subscription administrators. I would rather give them more specific access to the cloud…
ghawkes
  • 63
  • 1
  • 3
6
votes
3 answers

How to Stop single Instance/VM of WebRole/WorkerRole

We have a VM say SampleVM depoyed & running on Azure Environment and on the same we have created 2 instances One is WebRole & other is WorkerRole running onto Slot staging. My prob is I am able to Start/Stop SampleVM through powershell command but…
user2881983
  • 71
  • 1
  • 3
6
votes
1 answer

"error: 19 - Physical connection is not usable" when I swap my Staging and Production deployments on Windows Azure

Every time I swap my deployments between Staging and Production, I got this kind of error : [Wed Oct 09 18:43:51.9519 +00:00 2013] [Error] [Zappiti.BaseApi] An error occurred while updating the entries. See the inner exception for …
Filimindji
  • 1,453
  • 1
  • 16
  • 23
6
votes
2 answers

Azure AutoScale Failure Notifications due to no metrics available

In the last few days we have started receiving a lot of emails from Azure saying the following Subject: [AUTOSCALE FAILED] - Autoscale task failed for service_name due to no metrics available Body of the message: Autoscale has not been able to…
JoeGeeky
  • 3,746
  • 6
  • 36
  • 53
6
votes
2 answers

Windows azure web role on local IIS

I am developing windows azure web role. Can I host the azure web role on my local IIS. If yes..what are the steps I need to follow ? Local Machine is currently running on windows server 2008 R2
usr021986
  • 3,421
  • 14
  • 53
  • 64
6
votes
1 answer

Swapping Azure Staging/Production environments with a SignalR Hub

I have a SignalR service running on an Azure Web Role. I'm interested in deploying a new version of the service, first to Staging and then to the Production deployment slot. My question is if I swap the two deployment slots while there are existing…
Jonathan Rauch
  • 693
  • 1
  • 8
  • 18
6
votes
2 answers

Unable to allocate the required address spaces

While deploying a new Web Role on Windows Azure i am getting this error: Unable to allocate the required address spaces for the deployment in a new or predefined subnet that is contained within the specified virtual network. I have searched for a…
Raimond Kuipers
  • 1,146
  • 10
  • 18
6
votes
2 answers

Deploying Multiple Web Roles and Worker Roles on a Single Azure Cloud Service

This may not be new, but I hope some one can put me on right track as its bit confusing during azure deployment. I'm in the process of planning for deployment on Azure. This is what I have A Public facing ASP.Net MVC app (web-role) + WCF Service…
SKBG
  • 71
  • 1
  • 1
  • 3
6
votes
1 answer

Compile MVC and Pre-Compile Views And Deploy Into Azure WebRole

So I have the following requirements: 1. Compile a large MVC app and pre-compile all of its views. 2. Run transforms for web.config 3. Package and publish for deployment into Azure Web Role I can do 1 with a modified proj file, 2 works if I us…
6
votes
1 answer

Client certificate authentication and CA certificate in Azure

I need to authenticate requests to Azure Cloud Service Web Role using client certificates. How to put the Certification Authority (CA) root certificate in a right trusted store? I tried to upload it in Management Portal and then defining it in…
alexey
  • 8,360
  • 14
  • 70
  • 102
6
votes
1 answer

Identify the associated w3wp process for a web role instance

I am working on monitoring the performance of an Azure service. There are currently two web role instances (for the same website) running - each with its own W3WP.exe (w3wp and w3wp#1) How can i find out which w3wp process belongs to which role…
6
votes
1 answer

Azure Cloud Service: two web roles sharing the same port

I would like to have a single Azure Cloud Service including two web applications. Both applications should have the same inbound port number (80) and differ in host headers only. Is it possible to configure these applications as different web roles?…
alexey
  • 8,360
  • 14
  • 70
  • 102
6
votes
3 answers

Background thread in Azure Web Role

It is possible to run a thread from the WebRole.cs OnStart() method in such a way that we are able to access it through aspx page to perform background work? I know that the correct way to do it would be to use a Worker Role but i wish to maintain…
ToinoBiclas
  • 262
  • 4
  • 13