Q37. Service Configuration and service definition files?
As soon as you create a cloud service application, two files ‘Service definition and Service configuration’ are created. These files are available in the solution explorer.
If we open ServiceDefinition.csdef you will see the code listing as shown below. The first element ServiceDefinition provides a name for the service. The Windows Azure Fabric Controller defines a contract for the cloud service using this name. The service definition file is deployed for every instance of the cloud service. Each instance is informed of each setting that exists in the file ServiceDefinition.csdef.
The next element in the ServiceDefinition file is the WebRole element and the name of the Web Role Project is mentioned. The InputEndpoint helps the Fabric controller to configure ports and protocols for the service. For the web role, the protocol is http and port is 80. The ConfigurationSettings element contains names of the settings and not the values.
The settings which exist in the service definition file can only be set with values in the service configuration file, which means if settings do not exist in the service definition file, we cannot assign values in the service configuration file.
The below Figure is the service configuration file and values of the settings can be seen here. The service configuration file includes number of instances for each role and SSL certificates associated with the service.
If we open ServiceDefinition.csdef you will see the code listing as shown below. The first element ServiceDefinition provides a name for the service. The Windows Azure Fabric Controller defines a contract for the cloud service using this name. The service definition file is deployed for every instance of the cloud service. Each instance is informed of each setting that exists in the file ServiceDefinition.csdef.

The next element in the ServiceDefinition file is the WebRole element and the name of the Web Role Project is mentioned. The InputEndpoint helps the Fabric controller to configure ports and protocols for the service. For the web role, the protocol is http and port is 80. The ConfigurationSettings element contains names of the settings and not the values.
The settings which exist in the service definition file can only be set with values in the service configuration file, which means if settings do not exist in the service definition file, we cannot assign values in the service configuration file.
The below Figure is the service configuration file and values of the settings can be seen here. The service configuration file includes number of instances for each role and SSL certificates associated with the service.

See More Questions and Answers on - Azure Cloud Services (cont..)
- creating a parallel processing application in windows azure?
- Creating a scalable web application with background processing in Azure?
- How does fabric controller place and manage role instances of an application across fault domains?
- What is a local storage and how to configure local storage resources?
- What are compute emulator and storage emulator?
- How do we setup the development environment for Azure applications?
- What is Azure storage?
- What are the benefits of scalable storage service?
- Why Azure cloud applications need consistent, durable, and scalable storage service?