Service Definition File

The Service Definition File is an XML file based on the Azure Service Definition Schema and it describes the components of the Cloud Service.

A basic template of a Service Definition File looks like this:

<ServiceDefinition name="<service-name>" topologyChangeDiscovery="<change-type>" xmlns="http://schemas.microsoft.com/ServiceHosting/2008/10/ServiceDefinition" upgradeDomainCount="<number-of-upgrade-domains>" schemaVersion=" <version>"> 
<LoadBalancerProbes>
</LoadBalancerProbes>
<WebRole ...>
</WebRole>
<WorkerRole ...>
</WorkerRole>
<NetworkTrafficRules>
</NetworkTrafficRules>
</ServiceDefinition>

Overall, we find five elements in the Azure Services Definition Schema. The root element (that is, top level element) is <ServiceDefinition> with the mandatory attribute name and the three optional attributes topologyChangeDiscovery, schemaVersion, and upgradeDomainCount.

The following are additional elements that you will find:

  • <LoadBalancerProbes>: Defined in the Azure load balancer probe schema
  • <WebRole>: Defined in the Azure WebRole scheme
  • <WorkerRole>: Defined in the Azure WorkerRole scheme
  • <NetworkTrafficRules>: Defined in the Azure network traffic rules scheme

While the use of LoadBalancerProbes and NetworkTrafficRules is optional, the elements WebRole or WorkerRole must be filled to at least one of them.

Now we will look at the four elements in detail.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.188.152.157