Retrieves the value of a setting in the service configuration file.
public:
utility::string_t GetConfigurationSettingValue(
utility::string_t configurationSettingName
)
configurationSettingName
Type: utility::string_t
The name of the configuration setting.
Type: utility::string_t
A String that contains the value of the configuration setting.
GetConfigurationSettingValue is used to retrieve values for configuration settings defined in the project’s cscfg file, the cluster config and the cluster manifest.
For example, the value of a Setting element could be retrieved from the following .cscfg file by specifying the value of its name attribute as the configurationSettingName arument. In this example, specifying titleId as the configurationSettingName argument would return 12345.
<xml version="1.0" encoding="utf-8"?>
<ServiceConfiguration serviceName="Cloud.Gaming" xmlns="http://schemas.microsoft.com/ServiceHosting/2008/10/ServiceConfiguration" osFamily="2" osVersion="*" schemaVersion="2012-05.1.7">
<Role name="Cloud.Gaming.Bootstrap">
<Instances count="1" />
<ConfigurationSettings>
<Setting name="Microsoft.WindowsAzure.Plugins.Diagnostics.ConnectionString" value="UseDevelopmentStorage=true" />
<Setting name="titleId" value="12345" />
<Setting name="clusterId" value="00000000-0000-0000-0000-000000000000" />
<Setting name="gsmsBaseUrl" value="http://127.0.0.1:8187" />
<Setting name="vortexBaseUrl" value="http://127.0.0.1:8187" />
<Setting name="xblGameServerCertificateThumbprint" value="2a62da7c2ac9af4c5c082a5a7d00890c0593baeb" />
</ConfigurationSettings>
<Certificates>
<Certificate name="XblGameServerCertificate" thumbprint="0000000000000000000000000000000000000000" thumbprintAlgorithm="sha1" />
</Certificates>
</Role>
</ServiceConfiguration>
Header: Declared in RoleEnvironment.h.
Library: Use GSDK110.lib (VS 2012) or GSDK100.lib (VS 2010).