public EnvironmentVariableAWSRegion()
{
string regionName = Environment.GetEnvironmentVariable(ENVIRONMENT_VARIABLE_REGION);
if (string.IsNullOrEmpty(regionName))
{
throw new InvalidOperationException(string.Format(CultureInfo.InvariantCulture,
"The environment variable {0} was not set with AWS region data.", ENVIRONMENT_VARIABLE_REGION));
}
SetRegionFromName(regionName);
var logger = Logger.GetLogger(typeof(EnvironmentVariableAWSRegion));
logger.InfoFormat("Region found using environment variable.");
}
}