C# Класс Microsoft.WindowsAzure.Commands.Utilities.CloudService.CloudServiceClient

Наследование: ICloudServiceClient
Показать файл Открыть проект Примеры использования класса

Private Properties

Свойство Тип Описание
AddCertificates void
CloudServiceClient Common.System
CloudServiceClient Common.System
CreateDeployment void
CreatePublishContext PublishContext
DeleteDeploymentIfExists void
DeployPackage DeploymentGetResponse
DeploymentExists bool
GetCloudService HostedServiceGetDetailedResponse
GetCloudServiceName string
GetCurrentDirectory string
GetCurrentServiceProject CloudServiceProject
GetDeploymentId string
GetSlot DeploymentSlot
PrepareCloudServicePackagesRuntime void
SetCloudServiceState void
SetupStorageService void
TranslateException void
UpdateCacheWorkerRolesCloudConfiguration void
UpgradeDeployment void
UploadCertificate void
UploadPackage System.Uri
UploadPackageIfNeeded System.Uri
VerifyDeployment void
VerifyDeploymentExists void
WriteToStream void
WriteVerbose void
WriteVerboseWithTimestamp void
WriteWarning void

Открытые методы

Метод Описание
CheckHostedServiceNameAvailability ( string name ) : bool

Checks if the given hosted service name is available to be created

CheckStorageServiceAvailability ( string name ) : bool

Checks if the given storage service name is available to be created

CloudServiceClient ( AzureSMProfile profile, AzureSubscription subscription, string currentLocation = null, Action debugStream = null, Action verboseStream = null, Action warningStream = null ) : Common.System

Creates new instance from CloudServiceClient.

CloudServiceExists ( string name ) : bool

Checks if a cloud service exists or not.

CreateCloudServiceIfNotExist ( string name, string label = null, string location = null, string affinityGroup = null ) : void

Creates cloud service if it does not exist.

CreateStorageServiceIfNotExist ( string name, string label = null, string location = null, string affinityGroup = null ) : void

Creates storage service if it does not exist.

DeploymentExists ( string name = null, string slot = null ) : bool

Check if the deployment exists for given cloud service.

GetDefaultLocation ( ) : string

Gets the default subscription location.

GetStorageServiceConnectionString ( string name ) : string

Gets connection string of the given storage service name.

PublishCloudService ( string name = null, string slot = null, string location = null, string affinityGroup = null, string storageAccount = null, string deploymentName = null, bool launch = false, bool forceUpgrade = false ) : Deployment

Publishes a service project on Microsoft Azure.

PublishCloudService ( string package, string configuration, string slot = null, string location = null, string affinityGroup = null, string storageAccount = null, string deploymentName = null, bool launch = false, bool forceUpgrade = false ) : Deployment
RemoveCloudService ( string name ) : void

Removes all deployments in the given cloud service and the service itself.

RemoveCloudService ( string name, bool deleteFromStorage ) : void

Removes all deployments in the given cloud service and the service itself.

StartCloudService ( string name = null, string slot = null ) : void

Starts a cloud service.

StopCloudService ( string name = null, string slot = null ) : void

Stops a cloud service.

StorageServiceExists ( string name ) : bool

Checks if the provided storage service exists under the subscription or not.

Приватные методы

Метод Описание
AddCertificates ( ServiceCertificateListResponse uploadedCertificates, PublishContext context ) : void
CloudServiceClient ( AzureSubscription subscription, ManagementClient managementClient, StorageManagementClient storageManagementClient, ComputeManagementClient computeManagementClient ) : Common.System
CloudServiceClient ( string currentLocation, Action debugStream, Action verboseStream, Action warningStream ) : Common.System
CreateDeployment ( PublishContext context ) : void
CreatePublishContext ( string name, string slot, string location, string affinityGroup, string storageServiceName, string deploymentName, CloudServiceProject cloudServiceProject ) : PublishContext
DeleteDeploymentIfExists ( string name, DeploymentSlot slot, bool deleteFromStorage ) : void
DeployPackage ( bool launch, bool forceUpgrade, PublishContext context ) : DeploymentGetResponse
DeploymentExists ( string name, DeploymentSlot slot, string &deploymentName ) : bool
GetCloudService ( string name ) : HostedServiceGetDetailedResponse
GetCloudServiceName ( string name ) : string
GetCurrentDirectory ( ) : string
GetCurrentServiceProject ( ) : CloudServiceProject
GetDeploymentId ( PublishContext context ) : string
GetSlot ( string slot ) : DeploymentSlot
PrepareCloudServicePackagesRuntime ( PublishContext context ) : void
SetCloudServiceState ( string name, DeploymentSlot slot, CloudServiceState state ) : void
SetupStorageService ( PublishContext context ) : void
TranslateException ( Action a ) : void
UpdateCacheWorkerRolesCloudConfiguration ( PublishContext context ) : void
UpgradeDeployment ( PublishContext context, bool forceUpgrade ) : void
UploadCertificate ( X509Certificate2 cert, ConfigCertificate certElement, string name ) : void
UploadPackage ( PublishContext context ) : Uri
UploadPackageIfNeeded ( PublishContext context ) : Uri
VerifyDeployment ( PublishContext context ) : void
VerifyDeploymentExists ( HostedServiceGetDetailedResponse cloudService, DeploymentSlot slot, string &name ) : void
WriteToStream ( Action stream, string format ) : void
WriteVerbose ( string format ) : void
WriteVerboseWithTimestamp ( string format ) : void
WriteWarning ( string format ) : void

Описание методов

CheckHostedServiceNameAvailability() публичный Метод

Checks if the given hosted service name is available to be created
public CheckHostedServiceNameAvailability ( string name ) : bool
name string The name of the hosted service
Результат bool

CheckStorageServiceAvailability() публичный Метод

Checks if the given storage service name is available to be created
public CheckStorageServiceAvailability ( string name ) : bool
name string The name of the storage service
Результат bool

CloudServiceClient() публичный Метод

Creates new instance from CloudServiceClient.
public CloudServiceClient ( AzureSMProfile profile, AzureSubscription subscription, string currentLocation = null, Action debugStream = null, Action verboseStream = null, Action warningStream = null ) : Common.System
profile AzureSMProfile
subscription AzureSubscription The subscription data
currentLocation string Directory to do operations in
debugStream Action Action used to log http requests/responses
verboseStream Action Action used to log detailed client progress
warningStream Action Action used to log warning messages
Результат Common.System

CloudServiceExists() публичный Метод

Checks if a cloud service exists or not.
public CloudServiceExists ( string name ) : bool
name string The cloud service name
Результат bool

CreateCloudServiceIfNotExist() публичный Метод

Creates cloud service if it does not exist.
public CreateCloudServiceIfNotExist ( string name, string label = null, string location = null, string affinityGroup = null ) : void
name string The cloud service name
label string The cloud service label
location string The location to create the cloud service in.
affinityGroup string Affinity group name for cloud service
Результат void

CreateStorageServiceIfNotExist() публичный Метод

Creates storage service if it does not exist.
public CreateStorageServiceIfNotExist ( string name, string label = null, string location = null, string affinityGroup = null ) : void
name string The storage service name
label string The storage service label
location string The location name. If not provided default one will be used
affinityGroup string The affinity group name
Результат void

DeploymentExists() публичный Метод

Check if the deployment exists for given cloud service.
public DeploymentExists ( string name = null, string slot = null ) : bool
name string The cloud service name
slot string The deployment slot name
Результат bool

GetDefaultLocation() публичный Метод

Gets the default subscription location.
public GetDefaultLocation ( ) : string
Результат string

GetStorageServiceConnectionString() публичный Метод

Gets connection string of the given storage service name.
public GetStorageServiceConnectionString ( string name ) : string
name string The storage service name
Результат string

PublishCloudService() публичный Метод

Publishes a service project on Microsoft Azure.
public PublishCloudService ( string name = null, string slot = null, string location = null, string affinityGroup = null, string storageAccount = null, string deploymentName = null, bool launch = false, bool forceUpgrade = false ) : Deployment
name string The cloud service name
slot string The deployment slot
location string The deployment location
affinityGroup string The deployment affinity group
storageAccount string The storage account to store the package
deploymentName string The deployment name
launch bool Launch the service after publishing
forceUpgrade bool force the service upgrade even if this would result in loss of any local data on the vm (for example, changing the vm size)
Результат Deployment

PublishCloudService() публичный Метод

public PublishCloudService ( string package, string configuration, string slot = null, string location = null, string affinityGroup = null, string storageAccount = null, string deploymentName = null, bool launch = false, bool forceUpgrade = false ) : Deployment
package string
configuration string
slot string
location string
affinityGroup string
storageAccount string
deploymentName string
launch bool
forceUpgrade bool
Результат Deployment

RemoveCloudService() публичный Метод

Removes all deployments in the given cloud service and the service itself.
public RemoveCloudService ( string name ) : void
name string The cloud service name
Результат void

RemoveCloudService() публичный Метод

Removes all deployments in the given cloud service and the service itself.
public RemoveCloudService ( string name, bool deleteFromStorage ) : void
name string The cloud service name
deleteFromStorage bool Indicates whether the underlying disk blob(s) should be deleted from storage.
Результат void

StartCloudService() публичный Метод

Starts a cloud service.
public StartCloudService ( string name = null, string slot = null ) : void
name string The cloud service name
slot string The deployment slot
Результат void

StopCloudService() публичный Метод

Stops a cloud service.
public StopCloudService ( string name = null, string slot = null ) : void
name string The cloud service name
slot string The deployment slot
Результат void

StorageServiceExists() публичный Метод

Checks if the provided storage service exists under the subscription or not.
public StorageServiceExists ( string name ) : bool
name string The storage service name
Результат bool