Suspends operation of the specified Analysis Services server instance.
POST https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.AnalysisServices/servers/{serverName}/suspend?api-version=2017-08-01
URI Parameters
Name
In
Required
Type
Description
resourceGroupName
path
True
string
The name of the Azure Resource group of which a given Analysis Services server is part. This name must be at least 1 character in length, and no more than 90.
Regex pattern: ^[-\w\._\(\)]+$
serverName
path
True
string
The name of the Analysis Services server. It must be at least 3 characters in length, and no more than 63.
Regex pattern: ^[a-z][a-z0-9]*$
subscriptionId
path
True
string
A unique identifier for a Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.
POST https://management.azure.com/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.AnalysisServices/servers/azsdktest/suspend?api-version=2017-08-01
package armanalysisservices_test
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/analysisservices/armanalysisservices"
)
// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/analysisservices/resource-manager/Microsoft.AnalysisServices/stable/2017-08-01/examples/suspendServer.json
func ExampleServersClient_BeginSuspend() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
client, err := armanalysisservices.NewServersClient("613192d7-503f-477a-9cfe-4efc3ee2bd60", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
poller, err := client.BeginSuspend(ctx,
"TestRG",
"azsdktest",
nil)
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
_, err = poller.PollUntilDone(ctx, nil)
if err != nil {
log.Fatalf("failed to pull the result: %v", err)
}
}
using System;
using System.Threading.Tasks;
using Azure;
using Azure.Core;
using Azure.Identity;
using Azure.ResourceManager;
using Azure.ResourceManager.Analysis.Models;
using Azure.ResourceManager.Resources;
using Azure.ResourceManager.Analysis;
// Generated from example definition: specification/analysisservices/resource-manager/Microsoft.AnalysisServices/stable/2017-08-01/examples/suspendServer.json
// this example is just showing the usage of "Servers_Suspend" operation, for the dependent resources, they will have to be created separately.
// authenticate your client
ArmClient client = new ArmClient(new DefaultAzureCredential());
// this example assumes you already have this AnalysisServerResource created on azure
// for more information of creating AnalysisServerResource, please refer to the document of AnalysisServerResource
string subscriptionId = "613192d7-503f-477a-9cfe-4efc3ee2bd60";
string resourceGroupName = "TestRG";
string serverName = "azsdktest";
ResourceIdentifier analysisServerResourceId = AnalysisServerResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, serverName);
AnalysisServerResource analysisServer = client.GetAnalysisServerResource(analysisServerResourceId);
// invoke the operation
await analysisServer.SuspendAsync(WaitUntil.Completed);
Console.WriteLine($"Succeeded");