armworkloads

package module
v0.3.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 22, 2023 License: MIT Imports: 16 Imported by: 11

README

Azure Workloads Module for Go

PkgGoDev

The armworkloads module provides operations for working with Azure Workloads.

Source code

Getting started

Prerequisites

  • an Azure subscription
  • Go 1.18 or above (You could download and install the latest version of Go from here. It will replace the existing Go on your machine. If you want to install multiple Go versions on the same machine, you could refer this doc.)

Install the package

This project uses Go modules for versioning and dependency management.

Install the Azure Workloads module:

go get github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads

Authorization

When creating a client, you will need to provide a credential for authenticating with Azure Workloads. The azidentity module provides facilities for various ways of authenticating with Azure including client/secret, certificate, managed identity, and more.

cred, err := azidentity.NewDefaultAzureCredential(nil)

For more information on authentication, please see the documentation for azidentity at pkg.go.dev/github.com/Azure/azure-sdk-for-go/sdk/azidentity.

Clients

Azure Workloads modules consist of one or more clients. A client groups a set of related APIs, providing access to its functionality within the specified subscription. Create one or more clients to access the APIs you require using your credential.

client, err := armworkloads.NewProviderInstancesClient(<subscription ID>, cred, nil)

You can use ClientOptions in package github.com/Azure/azure-sdk-for-go/sdk/azcore/arm to set endpoint to connect with public and sovereign clouds as well as Azure Stack. For more information, please see the documentation for azcore at pkg.go.dev/github.com/Azure/azure-sdk-for-go/sdk/azcore.

options := arm.ClientOptions{
    ClientOptions: azcore.ClientOptions {
        Cloud: cloud.AzureChina,
    },
}
client, err := armworkloads.NewProviderInstancesClient(<subscription ID>, cred, &options)

Provide Feedback

If you encounter bugs or have suggestions, please open an issue and assign the Workloads label.

Contributing

This project welcomes contributions and suggestions. Most contributions require you to agree to a Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us the rights to use your contribution. For details, visit https://cla.microsoft.com.

When you submit a pull request, a CLA-bot will automatically determine whether you need to provide a CLA and decorate the PR appropriately (e.g., label, comment). Simply follow the instructions provided by the bot. You will only need to do this once across all repos using our CLA.

This project has adopted the Microsoft Open Source Code of Conduct. For more information, see the Code of Conduct FAQ or contact opencode@microsoft.com with any additional questions or comments.

Documentation

Index

Examples

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ActionType

type ActionType string

ActionType - Enum. Indicates the action type. "Internal" refers to actions that are for internal only APIs.

const (
	ActionTypeInternal ActionType = "Internal"
)

func PossibleActionTypeValues

func PossibleActionTypeValues() []ActionType

PossibleActionTypeValues returns the possible values for the ActionType const type.

type ApplicationServerConfiguration added in v0.2.0

type ApplicationServerConfiguration struct {
	// REQUIRED; The number of app server instances.
	InstanceCount *int64 `json:"instanceCount,omitempty"`

	// REQUIRED; The subnet id.
	SubnetID *string `json:"subnetId,omitempty"`

	// REQUIRED; Gets or sets the virtual machine configuration.
	VirtualMachineConfiguration *VirtualMachineConfiguration `json:"virtualMachineConfiguration,omitempty"`
}

ApplicationServerConfiguration - Gets or sets the application server configuration.

func (ApplicationServerConfiguration) MarshalJSON added in v0.2.0

func (a ApplicationServerConfiguration) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ApplicationServerConfiguration.

func (*ApplicationServerConfiguration) UnmarshalJSON added in v0.2.0

func (a *ApplicationServerConfiguration) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ApplicationServerConfiguration.

type ApplicationServerFullResourceNames added in v0.3.0

type ApplicationServerFullResourceNames struct {
	// The full name for availability set. In case name is not provided, it will be defaulted to {SID}-App-AvSet.
	AvailabilitySetName *string `json:"availabilitySetName,omitempty"`

	// The list of virtual machine naming details.
	VirtualMachines []*VirtualMachineResourceNames `json:"virtualMachines,omitempty"`
}

ApplicationServerFullResourceNames - The full resource names object for application layer resources. The number of entries in this list should be equal to the number VMs to be created for application layer.

func (ApplicationServerFullResourceNames) MarshalJSON added in v0.3.0

func (a ApplicationServerFullResourceNames) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ApplicationServerFullResourceNames.

func (*ApplicationServerFullResourceNames) UnmarshalJSON added in v0.3.0

func (a *ApplicationServerFullResourceNames) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ApplicationServerFullResourceNames.

type ApplicationServerVMDetails added in v0.3.0

type ApplicationServerVMDetails struct {
	// READ-ONLY; Storage details of all the Storage Accounts attached to the App Virtual Machine. For e.g. NFS on AFS Shared
	// Storage.
	StorageDetails []*StorageInformation `json:"storageDetails,omitempty" azure:"ro"`

	// READ-ONLY; Defines the type of application server VM.
	Type *ApplicationServerVirtualMachineType `json:"type,omitempty" azure:"ro"`

	// READ-ONLY
	VirtualMachineID *string `json:"virtualMachineId,omitempty" azure:"ro"`
}

ApplicationServerVMDetails - The Application Server VM Details.

func (ApplicationServerVMDetails) MarshalJSON added in v0.3.0

func (a ApplicationServerVMDetails) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ApplicationServerVMDetails.

func (*ApplicationServerVMDetails) UnmarshalJSON added in v0.3.0

func (a *ApplicationServerVMDetails) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ApplicationServerVMDetails.

type ApplicationServerVirtualMachineType added in v0.3.0

type ApplicationServerVirtualMachineType string

ApplicationServerVirtualMachineType - Defines the type of application server VM.

const (
	ApplicationServerVirtualMachineTypeActive  ApplicationServerVirtualMachineType = "Active"
	ApplicationServerVirtualMachineTypeStandby ApplicationServerVirtualMachineType = "Standby"
	ApplicationServerVirtualMachineTypeUnknown ApplicationServerVirtualMachineType = "Unknown"
)

func PossibleApplicationServerVirtualMachineTypeValues added in v0.3.0

func PossibleApplicationServerVirtualMachineTypeValues() []ApplicationServerVirtualMachineType

PossibleApplicationServerVirtualMachineTypeValues returns the possible values for the ApplicationServerVirtualMachineType const type.

type CentralServerConfiguration added in v0.2.0

type CentralServerConfiguration struct {
	// REQUIRED; The number of central server VMs.
	InstanceCount *int64 `json:"instanceCount,omitempty"`

	// REQUIRED; The subnet id.
	SubnetID *string `json:"subnetId,omitempty"`

	// REQUIRED; Gets or sets the virtual machine configuration.
	VirtualMachineConfiguration *VirtualMachineConfiguration `json:"virtualMachineConfiguration,omitempty"`
}

CentralServerConfiguration - Gets or sets the central server configuration.

func (CentralServerConfiguration) MarshalJSON added in v0.2.0

func (c CentralServerConfiguration) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type CentralServerConfiguration.

func (*CentralServerConfiguration) UnmarshalJSON added in v0.2.0

func (c *CentralServerConfiguration) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type CentralServerConfiguration.

type CentralServerFullResourceNames added in v0.3.0

type CentralServerFullResourceNames struct {
	// The full name for availability set. In case name is not provided, it will be defaulted to {SID}-ASCS-AvSet.
	AvailabilitySetName *string `json:"availabilitySetName,omitempty"`

	// The resource names object for load balancer and related resources.
	LoadBalancer *LoadBalancerResourceNames `json:"loadBalancer,omitempty"`

	// The list of names for all ASCS virtual machines to be deployed. The number of entries in this list should be equal to the
	// number VMs to be created for ASCS layer. At maximum, there can be two virtual
	// machines at this layer: ASCS and ERS.
	VirtualMachines []*VirtualMachineResourceNames `json:"virtualMachines,omitempty"`
}

CentralServerFullResourceNames - The full resource names object for central server layer resources.

func (CentralServerFullResourceNames) MarshalJSON added in v0.3.0

func (c CentralServerFullResourceNames) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type CentralServerFullResourceNames.

func (*CentralServerFullResourceNames) UnmarshalJSON added in v0.3.0

func (c *CentralServerFullResourceNames) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type CentralServerFullResourceNames.

type CentralServerVMDetails added in v0.2.0

type CentralServerVMDetails struct {
	// READ-ONLY; Storage details of all the Storage Accounts attached to the ASCS Virtual Machine. For e.g. NFS on AFS Shared
	// Storage.
	StorageDetails []*StorageInformation `json:"storageDetails,omitempty" azure:"ro"`

	// READ-ONLY; Defines the type of central server VM.
	Type *CentralServerVirtualMachineType `json:"type,omitempty" azure:"ro"`

	// READ-ONLY
	VirtualMachineID *string `json:"virtualMachineId,omitempty" azure:"ro"`
}

CentralServerVMDetails - The SAP Central Services Instance VM details.

func (CentralServerVMDetails) MarshalJSON added in v0.2.0

func (c CentralServerVMDetails) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type CentralServerVMDetails.

func (*CentralServerVMDetails) UnmarshalJSON added in v0.2.0

func (c *CentralServerVMDetails) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type CentralServerVMDetails.

type CentralServerVirtualMachineType added in v0.2.0

type CentralServerVirtualMachineType string

CentralServerVirtualMachineType - Defines the type of central server VM.

const (
	CentralServerVirtualMachineTypeASCS        CentralServerVirtualMachineType = "ASCS"
	CentralServerVirtualMachineTypeERS         CentralServerVirtualMachineType = "ERS"
	CentralServerVirtualMachineTypeERSInactive CentralServerVirtualMachineType = "ERSInactive"
	CentralServerVirtualMachineTypePrimary     CentralServerVirtualMachineType = "Primary"
	CentralServerVirtualMachineTypeSecondary   CentralServerVirtualMachineType = "Secondary"
	CentralServerVirtualMachineTypeStandby     CentralServerVirtualMachineType = "Standby"
	CentralServerVirtualMachineTypeUnknown     CentralServerVirtualMachineType = "Unknown"
)

func PossibleCentralServerVirtualMachineTypeValues added in v0.2.0

func PossibleCentralServerVirtualMachineTypeValues() []CentralServerVirtualMachineType

PossibleCentralServerVirtualMachineTypeValues returns the possible values for the CentralServerVirtualMachineType const type.

type Client added in v0.2.0

type Client struct {
	// contains filtered or unexported fields
}

Client contains the methods for the WorkloadsClient group. Don't use this type directly, use NewClient() instead.

func NewClient added in v0.2.0

func NewClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*Client, error)

NewClient creates a new instance of Client with the specified values.

  • subscriptionID - The ID of the target subscription.
  • credential - used to authorize requests. Usually a credential from azidentity.
  • options - pass nil to accept the default values.

func (*Client) SAPAvailabilityZoneDetails added in v0.2.0

func (client *Client) SAPAvailabilityZoneDetails(ctx context.Context, location string, options *ClientSAPAvailabilityZoneDetailsOptions) (ClientSAPAvailabilityZoneDetailsResponse, error)

SAPAvailabilityZoneDetails - Get the recommended SAP Availability Zone Pair Details for your region. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • location - The name of Azure region.
  • options - ClientSAPAvailabilityZoneDetailsOptions contains the optional parameters for the Client.SAPAvailabilityZoneDetails method.
Example (SapAvailabilityZoneDetailsEastus)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPAvailabilityZoneDetails_eastus.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := client.SAPAvailabilityZoneDetails(ctx, "centralus", &armworkloads.ClientSAPAvailabilityZoneDetailsOptions{SAPAvailabilityZoneDetails: nil})
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPAvailabilityZoneDetailsResult = armworkloads.SAPAvailabilityZoneDetailsResult{
	// 	AvailabilityZonePairs: []*armworkloads.SAPAvailabilityZonePair{
	// 		{
	// 			ZoneA: to.Ptr[int64](1),
	// 			ZoneB: to.Ptr[int64](2),
	// 	}},
	// }
}
Output:

Example (SapAvailabilityZoneDetailsNortheurope)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPAvailabilityZoneDetails_northeurope.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := client.SAPAvailabilityZoneDetails(ctx, "centralus", &armworkloads.ClientSAPAvailabilityZoneDetailsOptions{SAPAvailabilityZoneDetails: nil})
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPAvailabilityZoneDetailsResult = armworkloads.SAPAvailabilityZoneDetailsResult{
	// 	AvailabilityZonePairs: []*armworkloads.SAPAvailabilityZonePair{
	// 		{
	// 			ZoneA: to.Ptr[int64](2),
	// 			ZoneB: to.Ptr[int64](3),
	// 	}},
	// }
}
Output:

func (*Client) SAPDiskConfigurations added in v0.2.0

func (client *Client) SAPDiskConfigurations(ctx context.Context, location string, options *ClientSAPDiskConfigurationsOptions) (ClientSAPDiskConfigurationsResponse, error)

SAPDiskConfigurations - Get the SAP Disk Configuration Layout prod/non-prod SAP System. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • location - The name of Azure region.
  • options - ClientSAPDiskConfigurationsOptions contains the optional parameters for the Client.SAPDiskConfigurations method.
Example (SapDiskConfigurationsNonProd)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPDiskConfigurations_NonProd.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := client.SAPDiskConfigurations(ctx, "centralus", &armworkloads.ClientSAPDiskConfigurationsOptions{SAPDiskConfigurations: nil})
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPDiskConfigurationsResult = armworkloads.SAPDiskConfigurationsResult{
	// 	VolumeConfigurations: map[string]*armworkloads.SAPDiskConfiguration{
	// 		"backup": &armworkloads.SAPDiskConfiguration{
	// 			RecommendedConfiguration: &armworkloads.DiskVolumeConfiguration{
	// 				Count: to.Ptr[int64](2),
	// 				SizeGB: to.Ptr[int64](256),
	// 				SKU: &armworkloads.DiskSKU{
	// 					Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
	// 				},
	// 			},
	// 			SupportedConfigurations: []*armworkloads.DiskDetails{
	// 				{
	// 					DiskTier: to.Ptr("E10"),
	// 					IopsReadWrite: to.Ptr[int64](500),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](6),
	// 					MbpsReadWrite: to.Ptr[int64](60),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](0),
	// 					SizeGB: to.Ptr[int64](128),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
	// 					},
	// 				},
	// 				{
	// 					DiskTier: to.Ptr("E15"),
	// 					IopsReadWrite: to.Ptr[int64](500),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](6),
	// 					MbpsReadWrite: to.Ptr[int64](60),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](0),
	// 					SizeGB: to.Ptr[int64](256),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
	// 					},
	// 				},
	// 				{
	// 					DiskTier: to.Ptr("E20"),
	// 					IopsReadWrite: to.Ptr[int64](500),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](6),
	// 					MbpsReadWrite: to.Ptr[int64](60),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](0),
	// 					SizeGB: to.Ptr[int64](512),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
	// 					},
	// 				},
	// 				{
	// 					DiskTier: to.Ptr("P10"),
	// 					IopsReadWrite: to.Ptr[int64](500),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](6),
	// 					MbpsReadWrite: to.Ptr[int64](100),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](0),
	// 					SizeGB: to.Ptr[int64](128),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 					},
	// 				},
	// 				{
	// 					DiskTier: to.Ptr("P15"),
	// 					IopsReadWrite: to.Ptr[int64](1100),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](6),
	// 					MbpsReadWrite: to.Ptr[int64](125),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](0),
	// 					SizeGB: to.Ptr[int64](256),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 					},
	// 				},
	// 				{
	// 					DiskTier: to.Ptr("P20"),
	// 					IopsReadWrite: to.Ptr[int64](2300),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](6),
	// 					MbpsReadWrite: to.Ptr[int64](150),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](0),
	// 					SizeGB: to.Ptr[int64](512),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 					},
	// 			}},
	// 		},
	// 		"hana/data": &armworkloads.SAPDiskConfiguration{
	// 			RecommendedConfiguration: &armworkloads.DiskVolumeConfiguration{
	// 				Count: to.Ptr[int64](4),
	// 				SizeGB: to.Ptr[int64](128),
	// 				SKU: &armworkloads.DiskSKU{
	// 					Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 				},
	// 			},
	// 			SupportedConfigurations: []*armworkloads.DiskDetails{
	// 				{
	// 					DiskTier: to.Ptr("P10"),
	// 					IopsReadWrite: to.Ptr[int64](500),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](5),
	// 					MbpsReadWrite: to.Ptr[int64](100),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](4),
	// 					SizeGB: to.Ptr[int64](128),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 					},
	// 			}},
	// 		},
	// 		"hana/log": &armworkloads.SAPDiskConfiguration{
	// 			RecommendedConfiguration: &armworkloads.DiskVolumeConfiguration{
	// 				Count: to.Ptr[int64](3),
	// 				SizeGB: to.Ptr[int64](128),
	// 				SKU: &armworkloads.DiskSKU{
	// 					Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 				},
	// 			},
	// 			SupportedConfigurations: []*armworkloads.DiskDetails{
	// 				{
	// 					DiskTier: to.Ptr("P10"),
	// 					IopsReadWrite: to.Ptr[int64](500),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](5),
	// 					MbpsReadWrite: to.Ptr[int64](100),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](3),
	// 					SizeGB: to.Ptr[int64](128),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 					},
	// 			}},
	// 		},
	// 		"hana/shared": &armworkloads.SAPDiskConfiguration{
	// 			RecommendedConfiguration: &armworkloads.DiskVolumeConfiguration{
	// 				Count: to.Ptr[int64](1),
	// 				SizeGB: to.Ptr[int64](256),
	// 				SKU: &armworkloads.DiskSKU{
	// 					Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
	// 				},
	// 			},
	// 			SupportedConfigurations: []*armworkloads.DiskDetails{
	// 				{
	// 					DiskTier: to.Ptr("P15"),
	// 					IopsReadWrite: to.Ptr[int64](1100),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](1),
	// 					MbpsReadWrite: to.Ptr[int64](125),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](1),
	// 					SizeGB: to.Ptr[int64](256),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 					},
	// 				},
	// 				{
	// 					DiskTier: to.Ptr("P20"),
	// 					IopsReadWrite: to.Ptr[int64](2300),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](1),
	// 					MbpsReadWrite: to.Ptr[int64](150),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](1),
	// 					SizeGB: to.Ptr[int64](512),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 					},
	// 				},
	// 				{
	// 					DiskTier: to.Ptr("P30"),
	// 					IopsReadWrite: to.Ptr[int64](5000),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](1),
	// 					MbpsReadWrite: to.Ptr[int64](200),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](1),
	// 					SizeGB: to.Ptr[int64](1024),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 					},
	// 				},
	// 				{
	// 					DiskTier: to.Ptr("P40"),
	// 					IopsReadWrite: to.Ptr[int64](7500),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](1),
	// 					MbpsReadWrite: to.Ptr[int64](250),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](1),
	// 					SizeGB: to.Ptr[int64](2048),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 					},
	// 				},
	// 				{
	// 					DiskTier: to.Ptr("P50"),
	// 					IopsReadWrite: to.Ptr[int64](7500),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](1),
	// 					MbpsReadWrite: to.Ptr[int64](250),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](1),
	// 					SizeGB: to.Ptr[int64](4096),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 					},
	// 				},
	// 				{
	// 					DiskTier: to.Ptr("E15"),
	// 					IopsReadWrite: to.Ptr[int64](500),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](1),
	// 					MbpsReadWrite: to.Ptr[int64](60),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](1),
	// 					SizeGB: to.Ptr[int64](256),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
	// 					},
	// 				},
	// 				{
	// 					DiskTier: to.Ptr("E20"),
	// 					IopsReadWrite: to.Ptr[int64](500),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](1),
	// 					MbpsReadWrite: to.Ptr[int64](60),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](1),
	// 					SizeGB: to.Ptr[int64](512),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
	// 					},
	// 				},
	// 				{
	// 					DiskTier: to.Ptr("E30"),
	// 					IopsReadWrite: to.Ptr[int64](500),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](1),
	// 					MbpsReadWrite: to.Ptr[int64](60),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](1),
	// 					SizeGB: to.Ptr[int64](1024),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
	// 					},
	// 				},
	// 				{
	// 					DiskTier: to.Ptr("E40"),
	// 					IopsReadWrite: to.Ptr[int64](500),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](1),
	// 					MbpsReadWrite: to.Ptr[int64](60),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](1),
	// 					SizeGB: to.Ptr[int64](2048),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
	// 					},
	// 				},
	// 				{
	// 					DiskTier: to.Ptr("E50"),
	// 					IopsReadWrite: to.Ptr[int64](500),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](1),
	// 					MbpsReadWrite: to.Ptr[int64](60),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](1),
	// 					SizeGB: to.Ptr[int64](4096),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
	// 					},
	// 			}},
	// 		},
	// 		"os": &armworkloads.SAPDiskConfiguration{
	// 			RecommendedConfiguration: &armworkloads.DiskVolumeConfiguration{
	// 				Count: to.Ptr[int64](1),
	// 				SizeGB: to.Ptr[int64](64),
	// 				SKU: &armworkloads.DiskSKU{
	// 					Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
	// 				},
	// 			},
	// 			SupportedConfigurations: []*armworkloads.DiskDetails{
	// 				{
	// 					DiskTier: to.Ptr("P6"),
	// 					IopsReadWrite: to.Ptr[int64](240),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](1),
	// 					MbpsReadWrite: to.Ptr[int64](50),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](1),
	// 					SizeGB: to.Ptr[int64](64),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 					},
	// 				},
	// 				{
	// 					DiskTier: to.Ptr("P10"),
	// 					IopsReadWrite: to.Ptr[int64](500),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](1),
	// 					MbpsReadWrite: to.Ptr[int64](100),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](1),
	// 					SizeGB: to.Ptr[int64](128),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 					},
	// 				},
	// 				{
	// 					DiskTier: to.Ptr("P6"),
	// 					IopsReadWrite: to.Ptr[int64](500),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](1),
	// 					MbpsReadWrite: to.Ptr[int64](60),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](1),
	// 					SizeGB: to.Ptr[int64](64),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
	// 					},
	// 				},
	// 				{
	// 					DiskTier: to.Ptr("P10"),
	// 					IopsReadWrite: to.Ptr[int64](500),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](1),
	// 					MbpsReadWrite: to.Ptr[int64](60),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](1),
	// 					SizeGB: to.Ptr[int64](128),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
	// 					},
	// 			}},
	// 		},
	// 		"usr/sap": &armworkloads.SAPDiskConfiguration{
	// 			RecommendedConfiguration: &armworkloads.DiskVolumeConfiguration{
	// 				Count: to.Ptr[int64](1),
	// 				SizeGB: to.Ptr[int64](128),
	// 				SKU: &armworkloads.DiskSKU{
	// 					Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 				},
	// 			},
	// 			SupportedConfigurations: []*armworkloads.DiskDetails{
	// 				{
	// 					DiskTier: to.Ptr("P10"),
	// 					IopsReadWrite: to.Ptr[int64](500),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](1),
	// 					MbpsReadWrite: to.Ptr[int64](100),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](1),
	// 					SizeGB: to.Ptr[int64](128),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 					},
	// 				},
	// 				{
	// 					DiskTier: to.Ptr("P10"),
	// 					IopsReadWrite: to.Ptr[int64](1100),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](1),
	// 					MbpsReadWrite: to.Ptr[int64](125),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](1),
	// 					SizeGB: to.Ptr[int64](256),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 					},
	// 				},
	// 				{
	// 					DiskTier: to.Ptr("P10"),
	// 					IopsReadWrite: to.Ptr[int64](2300),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](1),
	// 					MbpsReadWrite: to.Ptr[int64](150),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](1),
	// 					SizeGB: to.Ptr[int64](512),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 					},
	// 				},
	// 				{
	// 					DiskTier: to.Ptr("E10"),
	// 					IopsReadWrite: to.Ptr[int64](500),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](1),
	// 					MbpsReadWrite: to.Ptr[int64](60),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](1),
	// 					SizeGB: to.Ptr[int64](128),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
	// 					},
	// 				},
	// 				{
	// 					DiskTier: to.Ptr("E15"),
	// 					IopsReadWrite: to.Ptr[int64](500),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](1),
	// 					MbpsReadWrite: to.Ptr[int64](60),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](1),
	// 					SizeGB: to.Ptr[int64](256),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
	// 					},
	// 				},
	// 				{
	// 					DiskTier: to.Ptr("E20"),
	// 					IopsReadWrite: to.Ptr[int64](500),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](1),
	// 					MbpsReadWrite: to.Ptr[int64](60),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](1),
	// 					SizeGB: to.Ptr[int64](512),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
	// 					},
	// 			}},
	// 		},
	// 	},
	// }
}
Output:

Example (SapDiskConfigurationsProd)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPDiskConfigurations_Prod.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := client.SAPDiskConfigurations(ctx, "centralus", &armworkloads.ClientSAPDiskConfigurationsOptions{SAPDiskConfigurations: nil})
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPDiskConfigurationsResult = armworkloads.SAPDiskConfigurationsResult{
	// 	VolumeConfigurations: map[string]*armworkloads.SAPDiskConfiguration{
	// 		"backup": &armworkloads.SAPDiskConfiguration{
	// 			RecommendedConfiguration: &armworkloads.DiskVolumeConfiguration{
	// 				Count: to.Ptr[int64](2),
	// 				SizeGB: to.Ptr[int64](256),
	// 				SKU: &armworkloads.DiskSKU{
	// 					Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 				},
	// 			},
	// 			SupportedConfigurations: []*armworkloads.DiskDetails{
	// 				{
	// 					DiskTier: to.Ptr("P10"),
	// 					IopsReadWrite: to.Ptr[int64](500),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](6),
	// 					MbpsReadWrite: to.Ptr[int64](100),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](0),
	// 					SizeGB: to.Ptr[int64](128),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 					},
	// 				},
	// 				{
	// 					DiskTier: to.Ptr("P15"),
	// 					IopsReadWrite: to.Ptr[int64](1100),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](6),
	// 					MbpsReadWrite: to.Ptr[int64](125),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](0),
	// 					SizeGB: to.Ptr[int64](256),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 					},
	// 				},
	// 				{
	// 					DiskTier: to.Ptr("P20"),
	// 					IopsReadWrite: to.Ptr[int64](2300),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](6),
	// 					MbpsReadWrite: to.Ptr[int64](150),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](0),
	// 					SizeGB: to.Ptr[int64](512),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 					},
	// 			}},
	// 		},
	// 		"hana/data": &armworkloads.SAPDiskConfiguration{
	// 			RecommendedConfiguration: &armworkloads.DiskVolumeConfiguration{
	// 				Count: to.Ptr[int64](4),
	// 				SizeGB: to.Ptr[int64](128),
	// 				SKU: &armworkloads.DiskSKU{
	// 					Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 				},
	// 			},
	// 			SupportedConfigurations: []*armworkloads.DiskDetails{
	// 				{
	// 					DiskTier: to.Ptr("P10"),
	// 					IopsReadWrite: to.Ptr[int64](500),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](5),
	// 					MbpsReadWrite: to.Ptr[int64](100),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](4),
	// 					SizeGB: to.Ptr[int64](128),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 					},
	// 			}},
	// 		},
	// 		"hana/log": &armworkloads.SAPDiskConfiguration{
	// 			RecommendedConfiguration: &armworkloads.DiskVolumeConfiguration{
	// 				Count: to.Ptr[int64](3),
	// 				SizeGB: to.Ptr[int64](128),
	// 				SKU: &armworkloads.DiskSKU{
	// 					Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 				},
	// 			},
	// 			SupportedConfigurations: []*armworkloads.DiskDetails{
	// 				{
	// 					DiskTier: to.Ptr("P10"),
	// 					IopsReadWrite: to.Ptr[int64](500),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](5),
	// 					MbpsReadWrite: to.Ptr[int64](100),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](3),
	// 					SizeGB: to.Ptr[int64](128),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 					},
	// 			}},
	// 		},
	// 		"hana/shared": &armworkloads.SAPDiskConfiguration{
	// 			RecommendedConfiguration: &armworkloads.DiskVolumeConfiguration{
	// 				Count: to.Ptr[int64](1),
	// 				SizeGB: to.Ptr[int64](256),
	// 				SKU: &armworkloads.DiskSKU{
	// 					Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 				},
	// 			},
	// 			SupportedConfigurations: []*armworkloads.DiskDetails{
	// 				{
	// 					DiskTier: to.Ptr("P15"),
	// 					IopsReadWrite: to.Ptr[int64](1100),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](1),
	// 					MbpsReadWrite: to.Ptr[int64](125),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](1),
	// 					SizeGB: to.Ptr[int64](256),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 					},
	// 				},
	// 				{
	// 					DiskTier: to.Ptr("P20"),
	// 					IopsReadWrite: to.Ptr[int64](2300),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](1),
	// 					MbpsReadWrite: to.Ptr[int64](150),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](1),
	// 					SizeGB: to.Ptr[int64](512),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 					},
	// 				},
	// 				{
	// 					DiskTier: to.Ptr("P30"),
	// 					IopsReadWrite: to.Ptr[int64](5000),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](1),
	// 					MbpsReadWrite: to.Ptr[int64](200),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](1),
	// 					SizeGB: to.Ptr[int64](1024),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 					},
	// 				},
	// 				{
	// 					DiskTier: to.Ptr("P40"),
	// 					IopsReadWrite: to.Ptr[int64](7500),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](1),
	// 					MbpsReadWrite: to.Ptr[int64](250),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](1),
	// 					SizeGB: to.Ptr[int64](2048),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 					},
	// 				},
	// 				{
	// 					DiskTier: to.Ptr("P50"),
	// 					IopsReadWrite: to.Ptr[int64](7500),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](1),
	// 					MbpsReadWrite: to.Ptr[int64](250),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](1),
	// 					SizeGB: to.Ptr[int64](4096),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 					},
	// 			}},
	// 		},
	// 		"os": &armworkloads.SAPDiskConfiguration{
	// 			RecommendedConfiguration: &armworkloads.DiskVolumeConfiguration{
	// 				Count: to.Ptr[int64](1),
	// 				SizeGB: to.Ptr[int64](64),
	// 				SKU: &armworkloads.DiskSKU{
	// 					Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 				},
	// 			},
	// 			SupportedConfigurations: []*armworkloads.DiskDetails{
	// 				{
	// 					DiskTier: to.Ptr("P6"),
	// 					IopsReadWrite: to.Ptr[int64](240),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](1),
	// 					MbpsReadWrite: to.Ptr[int64](50),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](1),
	// 					SizeGB: to.Ptr[int64](64),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 					},
	// 				},
	// 				{
	// 					DiskTier: to.Ptr("P10"),
	// 					IopsReadWrite: to.Ptr[int64](500),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](1),
	// 					MbpsReadWrite: to.Ptr[int64](100),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](1),
	// 					SizeGB: to.Ptr[int64](128),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 					},
	// 			}},
	// 		},
	// 		"usr/sap": &armworkloads.SAPDiskConfiguration{
	// 			RecommendedConfiguration: &armworkloads.DiskVolumeConfiguration{
	// 				Count: to.Ptr[int64](1),
	// 				SizeGB: to.Ptr[int64](128),
	// 				SKU: &armworkloads.DiskSKU{
	// 					Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 				},
	// 			},
	// 			SupportedConfigurations: []*armworkloads.DiskDetails{
	// 				{
	// 					DiskTier: to.Ptr("P10"),
	// 					IopsReadWrite: to.Ptr[int64](500),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](1),
	// 					MbpsReadWrite: to.Ptr[int64](100),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](1),
	// 					SizeGB: to.Ptr[int64](128),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 					},
	// 				},
	// 				{
	// 					DiskTier: to.Ptr("P10"),
	// 					IopsReadWrite: to.Ptr[int64](1100),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](1),
	// 					MbpsReadWrite: to.Ptr[int64](125),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](1),
	// 					SizeGB: to.Ptr[int64](256),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 					},
	// 				},
	// 				{
	// 					DiskTier: to.Ptr("P10"),
	// 					IopsReadWrite: to.Ptr[int64](2300),
	// 					MaximumSupportedDiskCount: to.Ptr[int64](1),
	// 					MbpsReadWrite: to.Ptr[int64](150),
	// 					MinimumSupportedDiskCount: to.Ptr[int64](1),
	// 					SizeGB: to.Ptr[int64](512),
	// 					SKU: &armworkloads.DiskSKU{
	// 						Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 					},
	// 			}},
	// 		},
	// 	},
	// }
}
Output:

func (*Client) SAPSizingRecommendations added in v0.2.0

func (client *Client) SAPSizingRecommendations(ctx context.Context, location string, options *ClientSAPSizingRecommendationsOptions) (ClientSAPSizingRecommendationsResponse, error)

SAPSizingRecommendations - Get SAP sizing recommendations by providing input SAPS for application tier and memory required for database tier If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • location - The name of Azure region.
  • options - ClientSAPSizingRecommendationsOptions contains the optional parameters for the Client.SAPSizingRecommendations method.
Example (SapSizingRecommendationsS4HanaDistributed)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPSizingRecommendations_S4HANA_Distributed.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := client.SAPSizingRecommendations(ctx, "centralus", &armworkloads.ClientSAPSizingRecommendationsOptions{SAPSizingRecommendation: nil})
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res = armworkloads.ClientSAPSizingRecommendationsResponse{
	// 	                            SAPSizingRecommendationResultClassification: &armworkloads.ThreeTierRecommendationResult{
	// 		DeploymentType: to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
	// 		ApplicationServerInstanceCount: to.Ptr[int64](2),
	// 		ApplicationServerVMSKU: to.Ptr("Standard_E8ds_v4"),
	// 		CentralServerInstanceCount: to.Ptr[int64](1),
	// 		CentralServerVMSKU: to.Ptr("Standard_E4ds_v4"),
	// 		DatabaseInstanceCount: to.Ptr[int64](1),
	// 		DbVMSKU: to.Ptr("Standard_M64s"),
	// 	},
	// 	                        }
}
Output:

Example (SapSizingRecommendationsS4HanaDistributedHaAvSet)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPSizingRecommendations_S4HANA_HA_AvSet.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := client.SAPSizingRecommendations(ctx, "centralus", &armworkloads.ClientSAPSizingRecommendationsOptions{SAPSizingRecommendation: nil})
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res = armworkloads.ClientSAPSizingRecommendationsResponse{
	// 	                            SAPSizingRecommendationResultClassification: &armworkloads.ThreeTierRecommendationResult{
	// 		DeploymentType: to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
	// 		ApplicationServerInstanceCount: to.Ptr[int64](3),
	// 		ApplicationServerVMSKU: to.Ptr("Standard_E16ds_v4"),
	// 		CentralServerInstanceCount: to.Ptr[int64](2),
	// 		CentralServerVMSKU: to.Ptr("Standard_E8ds_v4"),
	// 		DatabaseInstanceCount: to.Ptr[int64](2),
	// 		DbVMSKU: to.Ptr("Standard_M64s"),
	// 	},
	// 	                        }
}
Output:

Example (SapSizingRecommendationsS4HanaDistributedHaAvZone)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPSizingRecommendations_S4HANA_HA_AvZone.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := client.SAPSizingRecommendations(ctx, "centralus", &armworkloads.ClientSAPSizingRecommendationsOptions{SAPSizingRecommendation: nil})
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res = armworkloads.ClientSAPSizingRecommendationsResponse{
	// 	                            SAPSizingRecommendationResultClassification: &armworkloads.ThreeTierRecommendationResult{
	// 		DeploymentType: to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
	// 		ApplicationServerInstanceCount: to.Ptr[int64](6),
	// 		ApplicationServerVMSKU: to.Ptr("Standard_E8ds_v4"),
	// 		CentralServerInstanceCount: to.Ptr[int64](2),
	// 		CentralServerVMSKU: to.Ptr("Standard_E4ds_v4"),
	// 		DatabaseInstanceCount: to.Ptr[int64](2),
	// 		DbVMSKU: to.Ptr("Standard_M64s"),
	// 	},
	// 	                        }
}
Output:

Example (SapSizingRecommendationsS4HanaSingleServer)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPSizingRecommendations_S4HANA_SingleServer.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := client.SAPSizingRecommendations(ctx, "centralus", &armworkloads.ClientSAPSizingRecommendationsOptions{SAPSizingRecommendation: nil})
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res = armworkloads.ClientSAPSizingRecommendationsResponse{
	// 	                            SAPSizingRecommendationResultClassification: &armworkloads.SingleServerRecommendationResult{
	// 		DeploymentType: to.Ptr(armworkloads.SAPDeploymentTypeSingleServer),
	// 		VMSKU: to.Ptr("Standard_M128s"),
	// 	},
	// 	                        }
}
Output:

func (*Client) SAPSupportedSKU added in v0.2.0

func (client *Client) SAPSupportedSKU(ctx context.Context, location string, options *ClientSAPSupportedSKUOptions) (ClientSAPSupportedSKUResponse, error)

SAPSupportedSKU - Get a list of SAP supported SKUs for ASCS, Application and Database tier. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • location - The name of Azure region.
  • options - ClientSAPSupportedSKUOptions contains the optional parameters for the Client.SAPSupportedSKU method.
Example (SapSupportedSkusDistributed)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPSupportedSkus_Distributed.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := client.SAPSupportedSKU(ctx, "centralus", &armworkloads.ClientSAPSupportedSKUOptions{SAPSupportedSKU: nil})
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPSupportedResourceSKUsResult = armworkloads.SAPSupportedResourceSKUsResult{
	// 	SupportedSKUs: []*armworkloads.SAPSupportedSKU{
	// 		{
	// 			IsAppServerCertified: to.Ptr(true),
	// 			IsDatabaseCertified: to.Ptr(false),
	// 			VMSKU: to.Ptr("Standard_E4ds_v4"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(true),
	// 			IsDatabaseCertified: to.Ptr(false),
	// 			VMSKU: to.Ptr("Standard_E8ds_v4"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(true),
	// 			IsDatabaseCertified: to.Ptr(false),
	// 			VMSKU: to.Ptr("Standard_E16ds_v4"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(true),
	// 			IsDatabaseCertified: to.Ptr(false),
	// 			VMSKU: to.Ptr("Standard_E20ds_v4"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(true),
	// 			IsDatabaseCertified: to.Ptr(false),
	// 			VMSKU: to.Ptr("Standard_E32ds_v4"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(true),
	// 			IsDatabaseCertified: to.Ptr(false),
	// 			VMSKU: to.Ptr("Standard_E48ds_v4"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(true),
	// 			IsDatabaseCertified: to.Ptr(false),
	// 			VMSKU: to.Ptr("Standard_E64ds_v4"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(false),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_M32Is"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(false),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_M32ts"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(false),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_M64Is"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(false),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_M64ms"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(false),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_M64s"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(false),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_M128ms"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(false),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_M128s"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(false),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_M208ms_v2"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(false),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_M208s_v2"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(false),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_M416ms_v2"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(false),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_M416s_v2"),
	// 	}},
	// }
}
Output:

Example (SapSupportedSkusDistributedHaAvSet)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPSupportedSkus_DistributedHA_AvSet.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := client.SAPSupportedSKU(ctx, "centralus", &armworkloads.ClientSAPSupportedSKUOptions{SAPSupportedSKU: nil})
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPSupportedResourceSKUsResult = armworkloads.SAPSupportedResourceSKUsResult{
	// 	SupportedSKUs: []*armworkloads.SAPSupportedSKU{
	// 		{
	// 			IsAppServerCertified: to.Ptr(true),
	// 			IsDatabaseCertified: to.Ptr(false),
	// 			VMSKU: to.Ptr("Standard_E4ds_v4"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(true),
	// 			IsDatabaseCertified: to.Ptr(false),
	// 			VMSKU: to.Ptr("Standard_E8ds_v4"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(true),
	// 			IsDatabaseCertified: to.Ptr(false),
	// 			VMSKU: to.Ptr("Standard_E16ds_v4"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(true),
	// 			IsDatabaseCertified: to.Ptr(false),
	// 			VMSKU: to.Ptr("Standard_E20ds_v4"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(true),
	// 			IsDatabaseCertified: to.Ptr(false),
	// 			VMSKU: to.Ptr("Standard_E32ds_v4"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(true),
	// 			IsDatabaseCertified: to.Ptr(false),
	// 			VMSKU: to.Ptr("Standard_E48ds_v4"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(true),
	// 			IsDatabaseCertified: to.Ptr(false),
	// 			VMSKU: to.Ptr("Standard_E64ds_v4"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(false),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_M32Is"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(false),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_M32ts"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(false),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_M64Is"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(false),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_M64ms"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(false),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_M64s"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(false),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_M128ms"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(false),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_M128s"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(false),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_M208ms_v2"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(false),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_M208s_v2"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(false),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_M416ms_v2"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(false),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_M416s_v2"),
	// 	}},
	// }
}
Output:

Example (SapSupportedSkusDistributedHaAvZone)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPSupportedSkus_DistributedHA_AvZone.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := client.SAPSupportedSKU(ctx, "centralus", &armworkloads.ClientSAPSupportedSKUOptions{SAPSupportedSKU: nil})
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPSupportedResourceSKUsResult = armworkloads.SAPSupportedResourceSKUsResult{
	// 	SupportedSKUs: []*armworkloads.SAPSupportedSKU{
	// 		{
	// 			IsAppServerCertified: to.Ptr(true),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_E32ds_v4"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(true),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_E48ds_v4"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(true),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_E64ds_v4"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(true),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_M32Is"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(true),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_M32ts"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(true),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_M64Is"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(true),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_M64ms"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(true),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_M64s"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(true),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_M128ms"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(true),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_M128s"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(true),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_M208ms_v2"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(true),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_M208s_v2"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(true),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_M416ms_v2"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(true),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_M416s_v2"),
	// 	}},
	// }
}
Output:

Example (SapSupportedSkusSingleServer)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPSupportedSkus_SingleServer.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := client.SAPSupportedSKU(ctx, "centralus", &armworkloads.ClientSAPSupportedSKUOptions{SAPSupportedSKU: nil})
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPSupportedResourceSKUsResult = armworkloads.SAPSupportedResourceSKUsResult{
	// 	SupportedSKUs: []*armworkloads.SAPSupportedSKU{
	// 		{
	// 			IsAppServerCertified: to.Ptr(true),
	// 			IsDatabaseCertified: to.Ptr(false),
	// 			VMSKU: to.Ptr("Standard_E32ds_v4"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(true),
	// 			IsDatabaseCertified: to.Ptr(false),
	// 			VMSKU: to.Ptr("Standard_E48ds_v4"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(true),
	// 			IsDatabaseCertified: to.Ptr(false),
	// 			VMSKU: to.Ptr("Standard_E64ds_v4"),
	// 		},
	// 		{
	// 			IsAppServerCertified: to.Ptr(true),
	// 			IsDatabaseCertified: to.Ptr(true),
	// 			VMSKU: to.Ptr("Standard_M32ts"),
	// 	}},
	// }
}
Output:

type ClientSAPAvailabilityZoneDetailsOptions added in v0.2.0

type ClientSAPAvailabilityZoneDetailsOptions struct {
	// SAP Availability Zone Details Request body
	SAPAvailabilityZoneDetails *SAPAvailabilityZoneDetailsRequest
}

ClientSAPAvailabilityZoneDetailsOptions contains the optional parameters for the Client.SAPAvailabilityZoneDetails method.

type ClientSAPAvailabilityZoneDetailsResponse added in v0.2.0

type ClientSAPAvailabilityZoneDetailsResponse struct {
	SAPAvailabilityZoneDetailsResult
}

ClientSAPAvailabilityZoneDetailsResponse contains the response from method Client.SAPAvailabilityZoneDetails.

type ClientSAPDiskConfigurationsOptions added in v0.2.0

type ClientSAPDiskConfigurationsOptions struct {
	// SAP Disk Configurations Request body
	SAPDiskConfigurations *SAPDiskConfigurationsRequest
}

ClientSAPDiskConfigurationsOptions contains the optional parameters for the Client.SAPDiskConfigurations method.

type ClientSAPDiskConfigurationsResponse added in v0.2.0

type ClientSAPDiskConfigurationsResponse struct {
	SAPDiskConfigurationsResult
}

ClientSAPDiskConfigurationsResponse contains the response from method Client.SAPDiskConfigurations.

type ClientSAPSizingRecommendationsOptions added in v0.2.0

type ClientSAPSizingRecommendationsOptions struct {
	// SAP Sizing Recommendation Request body
	SAPSizingRecommendation *SAPSizingRecommendationRequest
}

ClientSAPSizingRecommendationsOptions contains the optional parameters for the Client.SAPSizingRecommendations method.

type ClientSAPSizingRecommendationsResponse added in v0.2.0

type ClientSAPSizingRecommendationsResponse struct {
	SAPSizingRecommendationResultClassification
}

ClientSAPSizingRecommendationsResponse contains the response from method Client.SAPSizingRecommendations.

func (*ClientSAPSizingRecommendationsResponse) UnmarshalJSON added in v0.2.0

func (c *ClientSAPSizingRecommendationsResponse) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ClientSAPSizingRecommendationsResponse.

type ClientSAPSupportedSKUOptions added in v0.2.0

type ClientSAPSupportedSKUOptions struct {
	// SAP Supported SKU Request body
	SAPSupportedSKU *SAPSupportedSKUsRequest
}

ClientSAPSupportedSKUOptions contains the optional parameters for the Client.SAPSupportedSKU method.

type ClientSAPSupportedSKUResponse added in v0.2.0

type ClientSAPSupportedSKUResponse struct {
	SAPSupportedResourceSKUsResult
}

ClientSAPSupportedSKUResponse contains the response from method Client.SAPSupportedSKU.

type ConfigurationType added in v0.3.0

type ConfigurationType string

ConfigurationType - The type of file share config.

const (
	ConfigurationTypeCreateAndMount ConfigurationType = "CreateAndMount"
	ConfigurationTypeMount          ConfigurationType = "Mount"
	ConfigurationTypeSkip           ConfigurationType = "Skip"
)

func PossibleConfigurationTypeValues added in v0.3.0

func PossibleConfigurationTypeValues() []ConfigurationType

PossibleConfigurationTypeValues returns the possible values for the ConfigurationType const type.

type CreateAndMountFileShareConfiguration added in v0.3.0

type CreateAndMountFileShareConfiguration struct {
	// REQUIRED; The type of file share config.
	ConfigurationType *ConfigurationType `json:"configurationType,omitempty"`

	// The name of file share resource group. The app rg is used in case of missing input.
	ResourceGroup *string `json:"resourceGroup,omitempty"`

	// The name of file share storage account name . A custom name is used in case of missing input.
	StorageAccountName *string `json:"storageAccountName,omitempty"`
}

CreateAndMountFileShareConfiguration - Gets or sets the file share configuration for file share created with the VIS case.

func (*CreateAndMountFileShareConfiguration) GetFileShareConfiguration added in v0.3.0

func (c *CreateAndMountFileShareConfiguration) GetFileShareConfiguration() *FileShareConfiguration

GetFileShareConfiguration implements the FileShareConfigurationClassification interface for type CreateAndMountFileShareConfiguration.

func (CreateAndMountFileShareConfiguration) MarshalJSON added in v0.3.0

func (c CreateAndMountFileShareConfiguration) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type CreateAndMountFileShareConfiguration.

func (*CreateAndMountFileShareConfiguration) UnmarshalJSON added in v0.3.0

func (c *CreateAndMountFileShareConfiguration) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type CreateAndMountFileShareConfiguration.

type CreatedByType

type CreatedByType string

CreatedByType - The type of identity that created the resource.

const (
	CreatedByTypeApplication     CreatedByType = "Application"
	CreatedByTypeKey             CreatedByType = "Key"
	CreatedByTypeManagedIdentity CreatedByType = "ManagedIdentity"
	CreatedByTypeUser            CreatedByType = "User"
)

func PossibleCreatedByTypeValues

func PossibleCreatedByTypeValues() []CreatedByType

PossibleCreatedByTypeValues returns the possible values for the CreatedByType const type.

type DB2ProviderInstanceProperties

type DB2ProviderInstanceProperties struct {
	// REQUIRED; The provider type. For example, the value can be SapHana.
	ProviderType *string `json:"providerType,omitempty"`

	// Gets or sets the db2 database name.
	DbName *string `json:"dbName,omitempty"`

	// Gets or sets the db2 database password.
	DbPassword *string `json:"dbPassword,omitempty"`

	// Gets or sets the key vault URI to secret with the database password.
	DbPasswordURI *string `json:"dbPasswordUri,omitempty"`

	// Gets or sets the db2 database sql port.
	DbPort *string `json:"dbPort,omitempty"`

	// Gets or sets the db2 database user name.
	DbUsername *string `json:"dbUsername,omitempty"`

	// Gets or sets the target virtual machine name.
	Hostname *string `json:"hostname,omitempty"`

	// Gets or sets the blob URI to SSL certificate for the DB2 Database.
	SSLCertificateURI *string `json:"sslCertificateUri,omitempty"`

	// Gets or sets certificate preference if secure communication is enabled.
	SSLPreference *SSLPreference `json:"sslPreference,omitempty"`

	// Gets or sets the SAP System Identifier
	SapSid *string `json:"sapSid,omitempty"`
}

DB2ProviderInstanceProperties - Gets or sets the DB2 provider properties.

func (*DB2ProviderInstanceProperties) GetProviderSpecificProperties

func (d *DB2ProviderInstanceProperties) GetProviderSpecificProperties() *ProviderSpecificProperties

GetProviderSpecificProperties implements the ProviderSpecificPropertiesClassification interface for type DB2ProviderInstanceProperties.

func (DB2ProviderInstanceProperties) MarshalJSON

func (d DB2ProviderInstanceProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type DB2ProviderInstanceProperties.

func (*DB2ProviderInstanceProperties) UnmarshalJSON

func (d *DB2ProviderInstanceProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type DB2ProviderInstanceProperties.

type DatabaseConfiguration added in v0.2.0

type DatabaseConfiguration struct {
	// REQUIRED; The number of database VMs.
	InstanceCount *int64 `json:"instanceCount,omitempty"`

	// REQUIRED; The subnet id.
	SubnetID *string `json:"subnetId,omitempty"`

	// REQUIRED; Gets or sets the virtual machine configuration.
	VirtualMachineConfiguration *VirtualMachineConfiguration `json:"virtualMachineConfiguration,omitempty"`

	// The database type.
	DatabaseType *SAPDatabaseType `json:"databaseType,omitempty"`

	// Gets or sets the disk configuration.
	DiskConfiguration *DiskConfiguration `json:"diskConfiguration,omitempty"`
}

DatabaseConfiguration - Gets or sets the database configuration.

func (DatabaseConfiguration) MarshalJSON added in v0.2.0

func (d DatabaseConfiguration) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type DatabaseConfiguration.

func (*DatabaseConfiguration) UnmarshalJSON added in v0.2.0

func (d *DatabaseConfiguration) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type DatabaseConfiguration.

type DatabaseServerFullResourceNames added in v0.3.0

type DatabaseServerFullResourceNames struct {
	// The full name for availability set. In case name is not provided, it will be defaulted to {SID}-DB-AvSet.
	AvailabilitySetName *string `json:"availabilitySetName,omitempty"`

	// The resource names object for load balancer and related resources.
	LoadBalancer *LoadBalancerResourceNames `json:"loadBalancer,omitempty"`

	// The list of virtual machine naming details.
	VirtualMachines []*VirtualMachineResourceNames `json:"virtualMachines,omitempty"`
}

DatabaseServerFullResourceNames - The full resource names object for database layer resources. The number of entries in this list should be equal to the number VMs to be created for database layer.

func (DatabaseServerFullResourceNames) MarshalJSON added in v0.3.0

func (d DatabaseServerFullResourceNames) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type DatabaseServerFullResourceNames.

func (*DatabaseServerFullResourceNames) UnmarshalJSON added in v0.3.0

func (d *DatabaseServerFullResourceNames) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type DatabaseServerFullResourceNames.

type DatabaseVMDetails added in v0.2.0

type DatabaseVMDetails struct {
	// READ-ONLY; Defines the SAP Instance status.
	Status *SAPVirtualInstanceStatus `json:"status,omitempty" azure:"ro"`

	// READ-ONLY; Storage details of all the Storage Accounts attached to the Database Virtual Machine. For e.g. NFS on AFS Shared
	// Storage.
	StorageDetails []*StorageInformation `json:"storageDetails,omitempty" azure:"ro"`

	// READ-ONLY
	VirtualMachineID *string `json:"virtualMachineId,omitempty" azure:"ro"`
}

DatabaseVMDetails - Database VM details.

func (DatabaseVMDetails) MarshalJSON added in v0.2.0

func (d DatabaseVMDetails) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type DatabaseVMDetails.

func (*DatabaseVMDetails) UnmarshalJSON added in v0.2.0

func (d *DatabaseVMDetails) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type DatabaseVMDetails.

type DeployerVMPackages added in v0.2.0

type DeployerVMPackages struct {
	// The deployer VM packages storage account id
	StorageAccountID *string `json:"storageAccountId,omitempty"`

	// The URL to the deployer VM packages file.
	URL *string `json:"url,omitempty"`
}

DeployerVMPackages - Defines the url and storage account ID where deployer VM packages are uploaded

func (DeployerVMPackages) MarshalJSON added in v0.2.0

func (d DeployerVMPackages) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type DeployerVMPackages.

func (*DeployerVMPackages) UnmarshalJSON added in v0.2.0

func (d *DeployerVMPackages) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type DeployerVMPackages.

type DeploymentConfiguration added in v0.2.0

type DeploymentConfiguration struct {
	// REQUIRED; The configuration Type.
	ConfigurationType *SAPConfigurationType `json:"configurationType,omitempty"`

	// The geo-location where the SAP system is to be created.
	AppLocation *string `json:"appLocation,omitempty"`

	// The infrastructure configuration.
	InfrastructureConfiguration InfrastructureConfigurationClassification `json:"infrastructureConfiguration,omitempty"`

	// The software configuration.
	SoftwareConfiguration SoftwareConfigurationClassification `json:"softwareConfiguration,omitempty"`
}

DeploymentConfiguration - Deployment Configuration.

func (*DeploymentConfiguration) GetSAPConfiguration added in v0.2.0

func (d *DeploymentConfiguration) GetSAPConfiguration() *SAPConfiguration

GetSAPConfiguration implements the SAPConfigurationClassification interface for type DeploymentConfiguration.

func (DeploymentConfiguration) MarshalJSON added in v0.2.0

func (d DeploymentConfiguration) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type DeploymentConfiguration.

func (*DeploymentConfiguration) UnmarshalJSON added in v0.2.0

func (d *DeploymentConfiguration) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type DeploymentConfiguration.

type DeploymentWithOSConfiguration added in v0.2.0

type DeploymentWithOSConfiguration struct {
	// REQUIRED; The configuration Type.
	ConfigurationType *SAPConfigurationType `json:"configurationType,omitempty"`

	// The geo-location where the SAP system is to be created.
	AppLocation *string `json:"appLocation,omitempty"`

	// The infrastructure configuration.
	InfrastructureConfiguration InfrastructureConfigurationClassification `json:"infrastructureConfiguration,omitempty"`

	// The OS and SAP configuration.
	OSSapConfiguration *OsSapConfiguration `json:"osSapConfiguration,omitempty"`

	// The software configuration.
	SoftwareConfiguration SoftwareConfigurationClassification `json:"softwareConfiguration,omitempty"`
}

DeploymentWithOSConfiguration - Deployment along with OS Configuration.

func (*DeploymentWithOSConfiguration) GetSAPConfiguration added in v0.2.0

func (d *DeploymentWithOSConfiguration) GetSAPConfiguration() *SAPConfiguration

GetSAPConfiguration implements the SAPConfigurationClassification interface for type DeploymentWithOSConfiguration.

func (DeploymentWithOSConfiguration) MarshalJSON added in v0.2.0

func (d DeploymentWithOSConfiguration) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type DeploymentWithOSConfiguration.

func (*DeploymentWithOSConfiguration) UnmarshalJSON added in v0.2.0

func (d *DeploymentWithOSConfiguration) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type DeploymentWithOSConfiguration.

type DiscoveryConfiguration added in v0.2.0

type DiscoveryConfiguration struct {
	// REQUIRED; The configuration Type.
	ConfigurationType *SAPConfigurationType `json:"configurationType,omitempty"`

	// The virtual machine ID of the Central Server.
	CentralServerVMID *string `json:"centralServerVmId,omitempty"`

	// The custom storage account name for the storage account created by the service in the managed resource group created as
	// part of VIS deployment.
	// Refer to the storage account naming rules here [https://learn.microsoft.com/azure/azure-resource-manager/management/resource-name-rules#microsoftstorage].
	// If not provided, the service will create the storage account with a random name.
	ManagedRgStorageAccountName *string `json:"managedRgStorageAccountName,omitempty"`

	// READ-ONLY; The geo-location where the SAP system exists.
	AppLocation *string `json:"appLocation,omitempty" azure:"ro"`
}

DiscoveryConfiguration - Discovery Details.

func (*DiscoveryConfiguration) GetSAPConfiguration added in v0.2.0

func (d *DiscoveryConfiguration) GetSAPConfiguration() *SAPConfiguration

GetSAPConfiguration implements the SAPConfigurationClassification interface for type DiscoveryConfiguration.

func (DiscoveryConfiguration) MarshalJSON added in v0.2.0

func (d DiscoveryConfiguration) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type DiscoveryConfiguration.

func (*DiscoveryConfiguration) UnmarshalJSON added in v0.2.0

func (d *DiscoveryConfiguration) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type DiscoveryConfiguration.

type DiskConfiguration added in v0.3.0

type DiskConfiguration struct {
	// The disk configuration for the db volume. For HANA, Required volumes are: ['hana/data', 'hana/log', hana/shared', 'usr/sap',
	// 'os'], Optional volume : ['backup'].
	DiskVolumeConfigurations map[string]*DiskVolumeConfiguration `json:"diskVolumeConfigurations,omitempty"`
}

DiskConfiguration - The Disk Configuration Details.

func (DiskConfiguration) MarshalJSON added in v0.3.0

func (d DiskConfiguration) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type DiskConfiguration.

func (*DiskConfiguration) UnmarshalJSON added in v0.3.0

func (d *DiskConfiguration) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type DiskConfiguration.

type DiskDetails added in v0.3.0

type DiskDetails struct {
	// The disk tier, e.g. P10, E10.
	DiskTier *string `json:"diskTier,omitempty"`

	// The disk Iops.
	IopsReadWrite *int64 `json:"iopsReadWrite,omitempty"`

	// The maximum supported disk count.
	MaximumSupportedDiskCount *int64 `json:"maximumSupportedDiskCount,omitempty"`

	// The disk provisioned throughput in MBps.
	MbpsReadWrite *int64 `json:"mbpsReadWrite,omitempty"`

	// The minimum supported disk count.
	MinimumSupportedDiskCount *int64 `json:"minimumSupportedDiskCount,omitempty"`

	// The disk sku.
	SKU *DiskSKU `json:"sku,omitempty"`

	// The disk size in GB.
	SizeGB *int64 `json:"sizeGB,omitempty"`
}

DiskDetails - The supported disk size details for a disk type.

func (DiskDetails) MarshalJSON added in v0.3.0

func (d DiskDetails) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type DiskDetails.

func (*DiskDetails) UnmarshalJSON added in v0.3.0

func (d *DiskDetails) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type DiskDetails.

type DiskSKU added in v0.3.0

type DiskSKU struct {
	// Defines the disk sku name.
	Name *DiskSKUName `json:"name,omitempty"`
}

DiskSKU - The disk sku.

func (DiskSKU) MarshalJSON added in v0.3.0

func (d DiskSKU) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type DiskSKU.

func (*DiskSKU) UnmarshalJSON added in v0.3.0

func (d *DiskSKU) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type DiskSKU.

type DiskSKUName added in v0.3.0

type DiskSKUName string

DiskSKUName - Defines the disk sku name.

const (
	DiskSKUNamePremiumLRS     DiskSKUName = "Premium_LRS"
	DiskSKUNamePremiumV2LRS   DiskSKUName = "PremiumV2_LRS"
	DiskSKUNamePremiumZRS     DiskSKUName = "Premium_ZRS"
	DiskSKUNameStandardLRS    DiskSKUName = "Standard_LRS"
	DiskSKUNameStandardSSDLRS DiskSKUName = "StandardSSD_LRS"
	DiskSKUNameStandardSSDZRS DiskSKUName = "StandardSSD_ZRS"
	DiskSKUNameUltraSSDLRS    DiskSKUName = "UltraSSD_LRS"
)

func PossibleDiskSKUNameValues added in v0.3.0

func PossibleDiskSKUNameValues() []DiskSKUName

PossibleDiskSKUNameValues returns the possible values for the DiskSKUName const type.

type DiskVolumeConfiguration added in v0.3.0

type DiskVolumeConfiguration struct {
	// The total number of disks required for the concerned volume.
	Count *int64 `json:"count,omitempty"`

	// The disk SKU details.
	SKU *DiskSKU `json:"sku,omitempty"`

	// The disk size in GB.
	SizeGB *int64 `json:"sizeGB,omitempty"`
}

DiskVolumeConfiguration - The disk configuration required for the selected volume.

func (DiskVolumeConfiguration) MarshalJSON added in v0.3.0

func (d DiskVolumeConfiguration) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type DiskVolumeConfiguration.

func (*DiskVolumeConfiguration) UnmarshalJSON added in v0.3.0

func (d *DiskVolumeConfiguration) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type DiskVolumeConfiguration.

type EnqueueReplicationServerProperties added in v0.2.0

type EnqueueReplicationServerProperties struct {
	// READ-ONLY; Defines the type of Enqueue Replication Server.
	ErsVersion *EnqueueReplicationServerType `json:"ersVersion,omitempty" azure:"ro"`

	// READ-ONLY; Defines the health of SAP Instances.
	Health *SAPHealthState `json:"health,omitempty" azure:"ro"`

	// READ-ONLY; ERS SAP Hostname.
	Hostname *string `json:"hostname,omitempty" azure:"ro"`

	// READ-ONLY; ERS SAP IP Address.
	IPAddress *string `json:"ipAddress,omitempty" azure:"ro"`

	// READ-ONLY; ERS Instance Number.
	InstanceNo *string `json:"instanceNo,omitempty" azure:"ro"`

	// READ-ONLY; ERS SAP Kernel Patch level.
	KernelPatch *string `json:"kernelPatch,omitempty" azure:"ro"`

	// READ-ONLY; ERS SAP Kernel Version.
	KernelVersion *string `json:"kernelVersion,omitempty" azure:"ro"`
}

EnqueueReplicationServerProperties - Defines the SAP Enqueue Replication Server (ERS) properties.

func (EnqueueReplicationServerProperties) MarshalJSON added in v0.2.0

func (e EnqueueReplicationServerProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type EnqueueReplicationServerProperties.

func (*EnqueueReplicationServerProperties) UnmarshalJSON added in v0.2.0

func (e *EnqueueReplicationServerProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type EnqueueReplicationServerProperties.

type EnqueueReplicationServerType added in v0.2.0

type EnqueueReplicationServerType string

EnqueueReplicationServerType - Defines the type of Enqueue Replication Server.

const (
	EnqueueReplicationServerTypeEnqueueReplicator1 EnqueueReplicationServerType = "EnqueueReplicator1"
	EnqueueReplicationServerTypeEnqueueReplicator2 EnqueueReplicationServerType = "EnqueueReplicator2"
)

func PossibleEnqueueReplicationServerTypeValues added in v0.2.0

func PossibleEnqueueReplicationServerTypeValues() []EnqueueReplicationServerType

PossibleEnqueueReplicationServerTypeValues returns the possible values for the EnqueueReplicationServerType const type.

type EnqueueServerProperties added in v0.2.0

type EnqueueServerProperties struct {
	// READ-ONLY; Defines the health of SAP Instances.
	Health *SAPHealthState `json:"health,omitempty" azure:"ro"`

	// READ-ONLY; Enqueue Server SAP Hostname.
	Hostname *string `json:"hostname,omitempty" azure:"ro"`

	// READ-ONLY; Enqueue Server SAP IP Address.
	IPAddress *string `json:"ipAddress,omitempty" azure:"ro"`

	// READ-ONLY; Enqueue Server Port.
	Port *int64 `json:"port,omitempty" azure:"ro"`
}

EnqueueServerProperties - Defines the SAP Enqueue Server properties.

func (EnqueueServerProperties) MarshalJSON added in v0.2.0

func (e EnqueueServerProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type EnqueueServerProperties.

func (*EnqueueServerProperties) UnmarshalJSON added in v0.2.0

func (e *EnqueueServerProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type EnqueueServerProperties.

type Error

type Error struct {
	// READ-ONLY; Server-defined set of error codes.
	Code *string `json:"code,omitempty" azure:"ro"`

	// READ-ONLY; Array of details about specific errors that led to this reported error.
	Details []*Error `json:"details,omitempty" azure:"ro"`

	// READ-ONLY; Object containing more specific information than the current object about the error.
	InnerError *ErrorInnerError `json:"innerError,omitempty" azure:"ro"`

	// READ-ONLY; Human-readable representation of the error.
	Message *string `json:"message,omitempty" azure:"ro"`

	// READ-ONLY; Target of the error.
	Target *string `json:"target,omitempty" azure:"ro"`
}

Error - Standard error object.

func (Error) MarshalJSON

func (e Error) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type Error.

func (*Error) UnmarshalJSON added in v0.2.0

func (e *Error) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type Error.

type ErrorAdditionalInfo

type ErrorAdditionalInfo struct {
	// READ-ONLY; The additional info.
	Info any `json:"info,omitempty" azure:"ro"`

	// READ-ONLY; The additional info type.
	Type *string `json:"type,omitempty" azure:"ro"`
}

ErrorAdditionalInfo - The resource management error additional info.

func (ErrorAdditionalInfo) MarshalJSON added in v0.2.0

func (e ErrorAdditionalInfo) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ErrorAdditionalInfo.

func (*ErrorAdditionalInfo) UnmarshalJSON added in v0.2.0

func (e *ErrorAdditionalInfo) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ErrorAdditionalInfo.

type ErrorDefinition added in v0.2.0

type ErrorDefinition struct {
	// READ-ONLY; Service specific error code which serves as the substatus for the HTTP error code.
	Code *string `json:"code,omitempty" azure:"ro"`

	// READ-ONLY; Internal error details.
	Details []*ErrorDefinition `json:"details,omitempty" azure:"ro"`

	// READ-ONLY; Description of the error.
	Message *string `json:"message,omitempty" azure:"ro"`
}

ErrorDefinition - Error definition.

func (ErrorDefinition) MarshalJSON added in v0.2.0

func (e ErrorDefinition) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ErrorDefinition.

func (*ErrorDefinition) UnmarshalJSON added in v0.2.0

func (e *ErrorDefinition) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ErrorDefinition.

type ErrorDetail

type ErrorDetail struct {
	// READ-ONLY; The error additional info.
	AdditionalInfo []*ErrorAdditionalInfo `json:"additionalInfo,omitempty" azure:"ro"`

	// READ-ONLY; The error code.
	Code *string `json:"code,omitempty" azure:"ro"`

	// READ-ONLY; The error details.
	Details []*ErrorDetail `json:"details,omitempty" azure:"ro"`

	// READ-ONLY; The error message.
	Message *string `json:"message,omitempty" azure:"ro"`

	// READ-ONLY; The error target.
	Target *string `json:"target,omitempty" azure:"ro"`
}

ErrorDetail - The error detail.

func (ErrorDetail) MarshalJSON added in v0.2.0

func (e ErrorDetail) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ErrorDetail.

func (*ErrorDetail) UnmarshalJSON added in v0.2.0

func (e *ErrorDetail) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ErrorDetail.

type ErrorInnerError

type ErrorInnerError struct {
	// Standard error object.
	InnerError *Error `json:"innerError,omitempty"`
}

ErrorInnerError - Object containing more specific information than the current object about the error.

func (ErrorInnerError) MarshalJSON added in v0.2.0

func (e ErrorInnerError) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ErrorInnerError.

func (*ErrorInnerError) UnmarshalJSON added in v0.2.0

func (e *ErrorInnerError) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ErrorInnerError.

type ErrorResponse

type ErrorResponse struct {
	// The error object.
	Error *ErrorDetail `json:"error,omitempty"`
}

ErrorResponse - Common error response for all Azure Resource Manager APIs to return error details for failed operations. (This also follows the OData error response format.).

func (ErrorResponse) MarshalJSON added in v0.2.0

func (e ErrorResponse) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ErrorResponse.

func (*ErrorResponse) UnmarshalJSON added in v0.2.0

func (e *ErrorResponse) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ErrorResponse.

type ExternalInstallationSoftwareConfiguration added in v0.3.0

type ExternalInstallationSoftwareConfiguration struct {
	// REQUIRED; The SAP software installation Type.
	SoftwareInstallationType *SAPSoftwareInstallationType `json:"softwareInstallationType,omitempty"`

	// The resource ID of the virtual machine containing the central server instance.
	CentralServerVMID *string `json:"centralServerVmId,omitempty"`
}

ExternalInstallationSoftwareConfiguration - The SAP Software configuration Input when the software is installed externally outside the service.

func (*ExternalInstallationSoftwareConfiguration) GetSoftwareConfiguration added in v0.3.0

GetSoftwareConfiguration implements the SoftwareConfigurationClassification interface for type ExternalInstallationSoftwareConfiguration.

func (ExternalInstallationSoftwareConfiguration) MarshalJSON added in v0.3.0

MarshalJSON implements the json.Marshaller interface for type ExternalInstallationSoftwareConfiguration.

func (*ExternalInstallationSoftwareConfiguration) UnmarshalJSON added in v0.3.0

func (e *ExternalInstallationSoftwareConfiguration) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ExternalInstallationSoftwareConfiguration.

type FileShareConfiguration added in v0.3.0

type FileShareConfiguration struct {
	// REQUIRED; The type of file share config.
	ConfigurationType *ConfigurationType `json:"configurationType,omitempty"`
}

FileShareConfiguration - File Share configuration details, populated with information on storage configuration mounted on the VIS. The createAndMount option is selected in case of missing input.

func (*FileShareConfiguration) GetFileShareConfiguration added in v0.3.0

func (f *FileShareConfiguration) GetFileShareConfiguration() *FileShareConfiguration

GetFileShareConfiguration implements the FileShareConfigurationClassification interface for type FileShareConfiguration.

func (FileShareConfiguration) MarshalJSON added in v0.3.0

func (f FileShareConfiguration) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type FileShareConfiguration.

func (*FileShareConfiguration) UnmarshalJSON added in v0.3.0

func (f *FileShareConfiguration) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type FileShareConfiguration.

type FileShareConfigurationClassification added in v0.3.0

type FileShareConfigurationClassification interface {
	// GetFileShareConfiguration returns the FileShareConfiguration content of the underlying type.
	GetFileShareConfiguration() *FileShareConfiguration
}

FileShareConfigurationClassification provides polymorphic access to related types. Call the interface's GetFileShareConfiguration() method to access the common type. Use a type switch to determine the concrete type. The possible types are: - *CreateAndMountFileShareConfiguration, *FileShareConfiguration, *MountFileShareConfiguration, *SkipFileShareConfiguration

type GatewayServerProperties added in v0.2.0

type GatewayServerProperties struct {
	// READ-ONLY; Defines the health of SAP Instances.
	Health *SAPHealthState `json:"health,omitempty" azure:"ro"`

	// READ-ONLY; Gateway Port.
	Port *int64 `json:"port,omitempty" azure:"ro"`
}

GatewayServerProperties - Defines the SAP Gateway Server properties.

func (GatewayServerProperties) MarshalJSON added in v0.2.0

func (g GatewayServerProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type GatewayServerProperties.

func (*GatewayServerProperties) UnmarshalJSON added in v0.2.0

func (g *GatewayServerProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type GatewayServerProperties.

type HanaDbProviderInstanceProperties

type HanaDbProviderInstanceProperties struct {
	// REQUIRED; The provider type. For example, the value can be SapHana.
	ProviderType *string `json:"providerType,omitempty"`

	// Gets or sets the hana database name.
	DbName *string `json:"dbName,omitempty"`

	// Gets or sets the database password.
	DbPassword *string `json:"dbPassword,omitempty"`

	// Gets or sets the key vault URI to secret with the database password.
	DbPasswordURI *string `json:"dbPasswordUri,omitempty"`

	// Gets or sets the database user name.
	DbUsername *string `json:"dbUsername,omitempty"`

	// Gets or sets the target virtual machine size.
	Hostname *string `json:"hostname,omitempty"`

	// Gets or sets the database instance number.
	InstanceNumber *string `json:"instanceNumber,omitempty"`

	// Gets or sets the database sql port.
	SQLPort *string `json:"sqlPort,omitempty"`

	// Gets or sets the blob URI to SSL certificate for the DB.
	SSLCertificateURI *string `json:"sslCertificateUri,omitempty"`

	// Gets or sets the hostname(s) in the SSL certificate.
	SSLHostNameInCertificate *string `json:"sslHostNameInCertificate,omitempty"`

	// Gets or sets certificate preference if secure communication is enabled.
	SSLPreference *SSLPreference `json:"sslPreference,omitempty"`

	// Gets or sets the SAP System Identifier.
	SapSid *string `json:"sapSid,omitempty"`
}

HanaDbProviderInstanceProperties - Gets or sets the provider properties.

func (*HanaDbProviderInstanceProperties) GetProviderSpecificProperties

func (h *HanaDbProviderInstanceProperties) GetProviderSpecificProperties() *ProviderSpecificProperties

GetProviderSpecificProperties implements the ProviderSpecificPropertiesClassification interface for type HanaDbProviderInstanceProperties.

func (HanaDbProviderInstanceProperties) MarshalJSON

func (h HanaDbProviderInstanceProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type HanaDbProviderInstanceProperties.

func (*HanaDbProviderInstanceProperties) UnmarshalJSON

func (h *HanaDbProviderInstanceProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type HanaDbProviderInstanceProperties.

type HighAvailabilityConfiguration added in v0.2.0

type HighAvailabilityConfiguration struct {
	// REQUIRED; The high availability type.
	HighAvailabilityType *SAPHighAvailabilityType `json:"highAvailabilityType,omitempty"`
}

HighAvailabilityConfiguration - Gets or sets the high availability configuration.

func (HighAvailabilityConfiguration) MarshalJSON added in v0.2.0

func (h HighAvailabilityConfiguration) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type HighAvailabilityConfiguration.

func (*HighAvailabilityConfiguration) UnmarshalJSON added in v0.2.0

func (h *HighAvailabilityConfiguration) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type HighAvailabilityConfiguration.

type HighAvailabilitySoftwareConfiguration added in v0.2.0

type HighAvailabilitySoftwareConfiguration struct {
	// REQUIRED; The fencing client id.
	FencingClientID *string `json:"fencingClientId,omitempty"`

	// REQUIRED; The fencing client id secret/password. The secret should never expire. This will be used pacemaker to start/stop
	// the cluster VMs.
	FencingClientPassword *string `json:"fencingClientPassword,omitempty"`
}

HighAvailabilitySoftwareConfiguration - Gets or sets the HA software configuration.

func (HighAvailabilitySoftwareConfiguration) MarshalJSON added in v0.2.0

func (h HighAvailabilitySoftwareConfiguration) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type HighAvailabilitySoftwareConfiguration.

func (*HighAvailabilitySoftwareConfiguration) UnmarshalJSON added in v0.2.0

func (h *HighAvailabilitySoftwareConfiguration) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type HighAvailabilitySoftwareConfiguration.

type ImageReference added in v0.2.0

type ImageReference struct {
	// Specifies the offer of the platform image or marketplace image used to create the virtual machine.
	Offer *string `json:"offer,omitempty"`

	// The image publisher.
	Publisher *string `json:"publisher,omitempty"`

	// The image SKU.
	SKU *string `json:"sku,omitempty"`

	// Specified the shared gallery image unique id for vm deployment. This can be fetched from shared gallery image GET call.
	SharedGalleryImageID *string `json:"sharedGalleryImageId,omitempty"`

	// Specifies the version of the platform image or marketplace image used to create the virtual machine. The allowed formats
	// are Major.Minor.Build or 'latest'. Major, Minor, and Build are decimal numbers.
	// Specify 'latest' to use the latest version of an image available at deploy time. Even if you use 'latest', the VM image
	// will not automatically update after deploy time even if a new version becomes
	// available.
	Version *string `json:"version,omitempty"`

	// READ-ONLY; Specifies in decimal numbers, the version of platform image or marketplace image used to create the virtual
	// machine. This readonly field differs from 'version', only if the value specified in
	// 'version' field is 'latest'.
	ExactVersion *string `json:"exactVersion,omitempty" azure:"ro"`
}

ImageReference - Specifies information about the image to use. You can specify information about platform images, marketplace images, or virtual machine images. This element is required when you want to use a platform image, marketplace image, or virtual machine image, but is not used in other creation operations. NOTE: Image reference publisher and offer can only be set when you create the scale set.

func (ImageReference) MarshalJSON added in v0.2.0

func (i ImageReference) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ImageReference.

func (*ImageReference) UnmarshalJSON added in v0.2.0

func (i *ImageReference) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ImageReference.

type InfrastructureConfiguration added in v0.2.0

type InfrastructureConfiguration struct {
	// REQUIRED; The application resource group where SAP system resources will be deployed.
	AppResourceGroup *string `json:"appResourceGroup,omitempty"`

	// REQUIRED; The type of SAP deployment, single server or Three tier.
	DeploymentType *SAPDeploymentType `json:"deploymentType,omitempty"`
}

InfrastructureConfiguration - Deploy SAP Infrastructure Details.

func (*InfrastructureConfiguration) GetInfrastructureConfiguration added in v0.2.0

func (i *InfrastructureConfiguration) GetInfrastructureConfiguration() *InfrastructureConfiguration

GetInfrastructureConfiguration implements the InfrastructureConfigurationClassification interface for type InfrastructureConfiguration.

func (InfrastructureConfiguration) MarshalJSON added in v0.2.0

func (i InfrastructureConfiguration) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type InfrastructureConfiguration.

func (*InfrastructureConfiguration) UnmarshalJSON added in v0.2.0

func (i *InfrastructureConfiguration) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type InfrastructureConfiguration.

type InfrastructureConfigurationClassification added in v0.2.0

type InfrastructureConfigurationClassification interface {
	// GetInfrastructureConfiguration returns the InfrastructureConfiguration content of the underlying type.
	GetInfrastructureConfiguration() *InfrastructureConfiguration
}

InfrastructureConfigurationClassification provides polymorphic access to related types. Call the interface's GetInfrastructureConfiguration() method to access the common type. Use a type switch to determine the concrete type. The possible types are: - *InfrastructureConfiguration, *SingleServerConfiguration, *ThreeTierConfiguration

type LinuxConfiguration added in v0.2.0

type LinuxConfiguration struct {
	// REQUIRED; The OS Type
	OSType *OSType `json:"osType,omitempty"`

	// Specifies whether password authentication should be disabled.
	DisablePasswordAuthentication *bool `json:"disablePasswordAuthentication,omitempty"`

	// Specifies the ssh key configuration for a Linux OS. (This property is deprecated, please use 'sshKeyPair' instead)
	SSH *SSHConfiguration `json:"ssh,omitempty"`

	// The SSH Key-pair used to authenticate with the VM's.
	SSHKeyPair *SSHKeyPair `json:"sshKeyPair,omitempty"`
}

LinuxConfiguration - Specifies the Linux operating system settings on the virtual machine. For a list of supported Linux distributions, see Linux on Azure-Endorsed Distributions [https://docs.microsoft.com/azure/virtual-machines/linux/endorsed-distros].

func (*LinuxConfiguration) GetOSConfiguration added in v0.2.0

func (l *LinuxConfiguration) GetOSConfiguration() *OSConfiguration

GetOSConfiguration implements the OSConfigurationClassification interface for type LinuxConfiguration.

func (LinuxConfiguration) MarshalJSON added in v0.2.0

func (l LinuxConfiguration) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type LinuxConfiguration.

func (*LinuxConfiguration) UnmarshalJSON added in v0.2.0

func (l *LinuxConfiguration) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type LinuxConfiguration.

type LoadBalancerDetails added in v0.3.0

type LoadBalancerDetails struct {
	// READ-ONLY
	ID *string `json:"id,omitempty" azure:"ro"`
}

LoadBalancerDetails - The Load Balancer details such as Load Balancer ID.

func (LoadBalancerDetails) MarshalJSON added in v0.3.0

func (l LoadBalancerDetails) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type LoadBalancerDetails.

func (*LoadBalancerDetails) UnmarshalJSON added in v0.3.0

func (l *LoadBalancerDetails) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type LoadBalancerDetails.

type LoadBalancerResourceNames added in v0.3.0

type LoadBalancerResourceNames struct {
	// The list of backend pool names. Currently, ACSS deploys only one backend pool and hence, size of this list should be 1
	BackendPoolNames []*string `json:"backendPoolNames,omitempty"`

	// The list of frontend IP configuration names. If provided as input, size of this list should be 2 for cs layer and should
	// be 1 for database layer.
	FrontendIPConfigurationNames []*string `json:"frontendIpConfigurationNames,omitempty"`

	// The list of health probe names. If provided as input, size of this list should be 2 for cs layer and should be 1 for database
	// layer.
	HealthProbeNames []*string `json:"healthProbeNames,omitempty"`

	// The full resource name for load balancer. If this value is not provided, load balancer will be name as {ASCS/DB}-loadBalancer.
	LoadBalancerName *string `json:"loadBalancerName,omitempty"`
}

LoadBalancerResourceNames - The resource names object for load balancer and related resources.

func (LoadBalancerResourceNames) MarshalJSON added in v0.3.0

func (l LoadBalancerResourceNames) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type LoadBalancerResourceNames.

func (*LoadBalancerResourceNames) UnmarshalJSON added in v0.3.0

func (l *LoadBalancerResourceNames) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type LoadBalancerResourceNames.

type ManagedRGConfiguration

type ManagedRGConfiguration struct {
	// Managed resource group name
	Name *string `json:"name,omitempty"`
}

ManagedRGConfiguration - Managed resource group configuration

func (ManagedRGConfiguration) MarshalJSON added in v0.2.0

func (m ManagedRGConfiguration) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ManagedRGConfiguration.

func (*ManagedRGConfiguration) UnmarshalJSON added in v0.2.0

func (m *ManagedRGConfiguration) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ManagedRGConfiguration.

type ManagedServiceIdentityType added in v0.2.0

type ManagedServiceIdentityType string

ManagedServiceIdentityType - Type of managed service identity (only None, UserAssigned types are allowed).

const (
	ManagedServiceIdentityTypeNone         ManagedServiceIdentityType = "None"
	ManagedServiceIdentityTypeUserAssigned ManagedServiceIdentityType = "UserAssigned"
)

func PossibleManagedServiceIdentityTypeValues added in v0.2.0

func PossibleManagedServiceIdentityTypeValues() []ManagedServiceIdentityType

PossibleManagedServiceIdentityTypeValues returns the possible values for the ManagedServiceIdentityType const type.

type MessageServerProperties added in v0.2.0

type MessageServerProperties struct {
	// READ-ONLY; Message Server HTTP Port.
	HTTPPort *int64 `json:"httpPort,omitempty" azure:"ro"`

	// READ-ONLY; Message Server HTTPS Port.
	HTTPSPort *int64 `json:"httpsPort,omitempty" azure:"ro"`

	// READ-ONLY; Defines the health of SAP Instances.
	Health *SAPHealthState `json:"health,omitempty" azure:"ro"`

	// READ-ONLY; Message Server SAP Hostname.
	Hostname *string `json:"hostname,omitempty" azure:"ro"`

	// READ-ONLY; Message server IP Address.
	IPAddress *string `json:"ipAddress,omitempty" azure:"ro"`

	// READ-ONLY; Message Server internal MS port.
	InternalMsPort *int64 `json:"internalMsPort,omitempty" azure:"ro"`

	// READ-ONLY; Message Server port.
	MSPort *int64 `json:"msPort,omitempty" azure:"ro"`
}

MessageServerProperties - Defines the SAP Message Server properties.

func (MessageServerProperties) MarshalJSON added in v0.2.0

func (m MessageServerProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type MessageServerProperties.

func (*MessageServerProperties) UnmarshalJSON added in v0.2.0

func (m *MessageServerProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type MessageServerProperties.

type Monitor

type Monitor struct {
	// REQUIRED; The geo-location where the resource lives
	Location *string `json:"location,omitempty"`

	// Managed service identity (user assigned identities)
	Identity *UserAssignedServiceIdentity `json:"identity,omitempty"`

	// SAP monitor properties
	Properties *MonitorProperties `json:"properties,omitempty"`

	// Resource tags.
	Tags map[string]*string `json:"tags,omitempty"`

	// READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
	ID *string `json:"id,omitempty" azure:"ro"`

	// READ-ONLY; The name of the resource
	Name *string `json:"name,omitempty" azure:"ro"`

	// READ-ONLY; Azure Resource Manager metadata containing createdBy and modifiedBy information.
	SystemData *SystemData `json:"systemData,omitempty" azure:"ro"`

	// READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
	Type *string `json:"type,omitempty" azure:"ro"`
}

Monitor - SAP monitor info on Azure (ARM properties and SAP monitor properties)

func (Monitor) MarshalJSON

func (m Monitor) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type Monitor.

func (*Monitor) UnmarshalJSON added in v0.2.0

func (m *Monitor) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type Monitor.

type MonitorListResult

type MonitorListResult struct {
	// The URL to get the next set of SAP monitors.
	NextLink *string `json:"nextLink,omitempty"`

	// The list of SAP monitors.
	Value []*Monitor `json:"value,omitempty"`
}

MonitorListResult - The response from the List SAP monitors operation.

func (MonitorListResult) MarshalJSON added in v0.2.0

func (m MonitorListResult) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type MonitorListResult.

func (*MonitorListResult) UnmarshalJSON added in v0.2.0

func (m *MonitorListResult) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type MonitorListResult.

type MonitorProperties

type MonitorProperties struct {
	// The SAP monitor resources will be deployed in the SAP monitoring region. The subnet region should be same as the SAP monitoring
	// region.
	AppLocation *string `json:"appLocation,omitempty"`

	// The ARM ID of the Log Analytics Workspace that is used for SAP monitoring.
	LogAnalyticsWorkspaceArmID *string `json:"logAnalyticsWorkspaceArmId,omitempty"`

	// Managed resource group configuration
	ManagedResourceGroupConfiguration *ManagedRGConfiguration `json:"managedResourceGroupConfiguration,omitempty"`

	// The subnet which the SAP monitor will be deployed in
	MonitorSubnet *string `json:"monitorSubnet,omitempty"`

	// Sets the routing preference of the SAP monitor. By default only RFC1918 traffic is routed to the customer VNET.
	RoutingPreference *RoutingPreference `json:"routingPreference,omitempty"`

	// Sets the preference for zone redundancy on resources created for the SAP monitor. By default resources will be created
	// which do not support zone redundancy.
	ZoneRedundancyPreference *string `json:"zoneRedundancyPreference,omitempty"`

	// READ-ONLY; Defines the SAP monitor errors.
	Errors *MonitorPropertiesErrors `json:"errors,omitempty" azure:"ro"`

	// READ-ONLY; The ARM ID of the MSI used for SAP monitoring.
	MsiArmID *string `json:"msiArmId,omitempty" azure:"ro"`

	// READ-ONLY; State of provisioning of the SAP monitor.
	ProvisioningState *WorkloadMonitorProvisioningState `json:"provisioningState,omitempty" azure:"ro"`

	// READ-ONLY; The ARM ID of the Storage account used for SAP monitoring.
	StorageAccountArmID *string `json:"storageAccountArmId,omitempty" azure:"ro"`
}

MonitorProperties - Describes the properties of a SAP monitor.

func (MonitorProperties) MarshalJSON added in v0.2.0

func (m MonitorProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type MonitorProperties.

func (*MonitorProperties) UnmarshalJSON added in v0.2.0

func (m *MonitorProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type MonitorProperties.

type MonitorPropertiesErrors

type MonitorPropertiesErrors struct {
	// READ-ONLY; Server-defined set of error codes.
	Code *string `json:"code,omitempty" azure:"ro"`

	// READ-ONLY; Array of details about specific errors that led to this reported error.
	Details []*Error `json:"details,omitempty" azure:"ro"`

	// READ-ONLY; Object containing more specific information than the current object about the error.
	InnerError *ErrorInnerError `json:"innerError,omitempty" azure:"ro"`

	// READ-ONLY; Human-readable representation of the error.
	Message *string `json:"message,omitempty" azure:"ro"`

	// READ-ONLY; Target of the error.
	Target *string `json:"target,omitempty" azure:"ro"`
}

MonitorPropertiesErrors - Defines the SAP monitor errors.

func (MonitorPropertiesErrors) MarshalJSON

func (m MonitorPropertiesErrors) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type MonitorPropertiesErrors.

func (*MonitorPropertiesErrors) UnmarshalJSON added in v0.2.0

func (m *MonitorPropertiesErrors) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type MonitorPropertiesErrors.

type MonitorsClient

type MonitorsClient struct {
	// contains filtered or unexported fields
}

MonitorsClient contains the methods for the Monitors group. Don't use this type directly, use NewMonitorsClient() instead.

func NewMonitorsClient

func NewMonitorsClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*MonitorsClient, error)

NewMonitorsClient creates a new instance of MonitorsClient with the specified values.

  • subscriptionID - The ID of the target subscription.
  • credential - used to authorize requests. Usually a credential from azidentity.
  • options - pass nil to accept the default values.

func (*MonitorsClient) BeginCreate

func (client *MonitorsClient) BeginCreate(ctx context.Context, resourceGroupName string, monitorName string, monitorParameter Monitor, options *MonitorsClientBeginCreateOptions) (*runtime.Poller[MonitorsClientCreateResponse], error)

BeginCreate - Creates a SAP monitor for the specified subscription, resource group, and resource name. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • monitorName - Name of the SAP monitor resource.
  • monitorParameter - Request body representing a SAP monitor
  • options - MonitorsClientBeginCreateOptions contains the optional parameters for the MonitorsClient.BeginCreate method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/workloadmonitor/monitors_Create.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewMonitorsClient("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "myResourceGroup", "mySapMonitor", armworkloads.Monitor{
		Location: to.Ptr("westus"),
		Tags: map[string]*string{
			"key": to.Ptr("value"),
		},
		Properties: &armworkloads.MonitorProperties{
			AppLocation:                to.Ptr("westus"),
			LogAnalyticsWorkspaceArmID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/myResourceGroup/providers/microsoft.operationalinsights/workspaces/myWorkspace"),
			ManagedResourceGroupConfiguration: &armworkloads.ManagedRGConfiguration{
				Name: to.Ptr("myManagedRg"),
			},
			MonitorSubnet:     to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Network/virtualNetworks/myVnet/subnets/mySubnet"),
			RoutingPreference: to.Ptr(armworkloads.RoutingPreferenceRouteAll),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.Monitor = armworkloads.Monitor{
	// 	Name: to.Ptr("mySapMonitor"),
	// 	Type: to.Ptr("Microsoft.Workloads/workloads"),
	// 	ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/workloads/mySapMonitor"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westus"),
	// 	Tags: map[string]*string{
	// 		"key": to.Ptr("value"),
	// 	},
	// 	Properties: &armworkloads.MonitorProperties{
	// 		AppLocation: to.Ptr("eastus"),
	// 		Errors: &armworkloads.MonitorPropertiesErrors{
	// 		},
	// 		LogAnalyticsWorkspaceArmID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/myResourceGroup/providers/microsoft.operationalinsights/workspaces/myWorkspace"),
	// 		ManagedResourceGroupConfiguration: &armworkloads.ManagedRGConfiguration{
	// 			Name: to.Ptr("myManagedRg"),
	// 		},
	// 		MonitorSubnet: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Network/virtualNetworks/myVnet/subnets/mySubnet"),
	// 		MsiArmID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.ManagedIdentity/userAssignedIdentities/myMsi"),
	// 		ProvisioningState: to.Ptr(armworkloads.WorkloadMonitorProvisioningStateSucceeded),
	// 		RoutingPreference: to.Ptr(armworkloads.RoutingPreferenceRouteAll),
	// 		StorageAccountArmID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Storage/storageAccounts/mystorageaccount"),
	// 		ZoneRedundancyPreference: to.Ptr("ZoneRedundantApp"),
	// 	},
	// }
}
Output:

func (*MonitorsClient) BeginDelete

func (client *MonitorsClient) BeginDelete(ctx context.Context, resourceGroupName string, monitorName string, options *MonitorsClientBeginDeleteOptions) (*runtime.Poller[MonitorsClientDeleteResponse], error)

BeginDelete - Deletes a SAP monitor with the specified subscription, resource group, and SAP monitor name. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • monitorName - Name of the SAP monitor resource.
  • options - MonitorsClientBeginDeleteOptions contains the optional parameters for the MonitorsClient.BeginDelete method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/workloadmonitor/monitors_Delete.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewMonitorsClient("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginDelete(ctx, "myResourceGroup", "mySapMonitor", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.OperationStatusResult = armworkloads.OperationStatusResult{
	// 	Name: to.Ptr("1e4193c3-206e-4916-b124-1da16175eb0f"),
	// 	EndTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T03:38:07.000Z"); return t}()),
	// 	ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/operations/locations/westus/1e4193c3-206e-4916-b124-1da16175eb0f"),
	// 	StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T03:36:07.000Z"); return t}()),
	// 	Status: to.Ptr("Succeeded"),
	// }
}
Output:

func (*MonitorsClient) Get

func (client *MonitorsClient) Get(ctx context.Context, resourceGroupName string, monitorName string, options *MonitorsClientGetOptions) (MonitorsClientGetResponse, error)

Get - Gets properties of a SAP monitor for the specified subscription, resource group, and resource name. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • monitorName - Name of the SAP monitor resource.
  • options - MonitorsClientGetOptions contains the optional parameters for the MonitorsClient.Get method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/workloadmonitor/monitors_Get.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewMonitorsClient("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := client.Get(ctx, "myResourceGroup", "mySapMonitor", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.Monitor = armworkloads.Monitor{
	// 	Name: to.Ptr("mySapMonitor1"),
	// 	Type: to.Ptr("Microsoft.Workloads/workloads"),
	// 	ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/workloads/mySapMonitor"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westus"),
	// 	Tags: map[string]*string{
	// 		"key": to.Ptr("value"),
	// 	},
	// 	Properties: &armworkloads.MonitorProperties{
	// 		AppLocation: to.Ptr("eastus"),
	// 		Errors: &armworkloads.MonitorPropertiesErrors{
	// 		},
	// 		LogAnalyticsWorkspaceArmID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/myResourceGroup/providers/microsoft.operationalinsights/workspaces/myWorkspace"),
	// 		ManagedResourceGroupConfiguration: &armworkloads.ManagedRGConfiguration{
	// 			Name: to.Ptr("myManagedRg"),
	// 		},
	// 		MonitorSubnet: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Network/virtualNetworks/myVnet/subnets/mySubnet"),
	// 		MsiArmID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.ManagedIdentity/userAssignedIdentities/myMsi"),
	// 		ProvisioningState: to.Ptr(armworkloads.WorkloadMonitorProvisioningStateSucceeded),
	// 		RoutingPreference: to.Ptr(armworkloads.RoutingPreferenceRouteAll),
	// 		StorageAccountArmID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Storage/storageAccounts/mystorageaccount"),
	// 		ZoneRedundancyPreference: to.Ptr("ZoneRedundantApp"),
	// 	},
	// }
}
Output:

func (*MonitorsClient) NewListByResourceGroupPager

func (client *MonitorsClient) NewListByResourceGroupPager(resourceGroupName string, options *MonitorsClientListByResourceGroupOptions) *runtime.Pager[MonitorsClientListByResourceGroupResponse]

NewListByResourceGroupPager - Gets a list of SAP monitors in the specified resource group.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • options - MonitorsClientListByResourceGroupOptions contains the optional parameters for the MonitorsClient.NewListByResourceGroupPager method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/workloadmonitor/monitors_ListByRG.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewMonitorsClient("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	pager := client.NewListByResourceGroupPager("example-rg", nil)
	for pager.More() {
		page, err := pager.NextPage(ctx)
		if err != nil {
			log.Fatalf("failed to advance page: %v", err)
		}
		for _, v := range page.Value {
			// You could use page here. We use blank identifier for just demo purposes.
			_ = v
		}
		// If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
		// page.MonitorListResult = armworkloads.MonitorListResult{
		// 	Value: []*armworkloads.Monitor{
		// 		{
		// 			Name: to.Ptr("mySapMonitor1"),
		// 			Type: to.Ptr("Microsoft.Workloads/workloads"),
		// 			ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/example-rg/providers/Microsoft.Workloads/monitors/mySapMonitor1"),
		// 			Location: to.Ptr("westus"),
		// 			Tags: map[string]*string{
		// 				"key": to.Ptr("value"),
		// 			},
		// 			Properties: &armworkloads.MonitorProperties{
		// 				AppLocation: to.Ptr("eastus"),
		// 				Errors: &armworkloads.MonitorPropertiesErrors{
		// 				},
		// 				LogAnalyticsWorkspaceArmID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/example-rg/providers/microsoft.operationalinsights/workspaces/myWorkspace"),
		// 				ManagedResourceGroupConfiguration: &armworkloads.ManagedRGConfiguration{
		// 					Name: to.Ptr("myManagedRg1"),
		// 				},
		// 				MonitorSubnet: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/example-rg/providers/Microsoft.Network/virtualNetworks/myVnet/subnets/mySubnet"),
		// 				MsiArmID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.ManagedIdentity/userAssignedIdentities/myMsi"),
		// 				ProvisioningState: to.Ptr(armworkloads.WorkloadMonitorProvisioningStateSucceeded),
		// 				RoutingPreference: to.Ptr(armworkloads.RoutingPreferenceRouteAll),
		// 				StorageAccountArmID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Storage/storageAccounts/mystorageaccount"),
		// 				ZoneRedundancyPreference: to.Ptr("ZoneRedundantApp"),
		// 			},
		// 		},
		// 		{
		// 			Name: to.Ptr("mySapMonitor2"),
		// 			Type: to.Ptr("Microsoft.Workloads/workloads"),
		// 			ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/example-rg/providers/Microsoft.Workloads/workloads/mySapMonitor2"),
		// 			Location: to.Ptr("westus"),
		// 			Tags: map[string]*string{
		// 				"key": to.Ptr("value"),
		// 			},
		// 			Properties: &armworkloads.MonitorProperties{
		// 				AppLocation: to.Ptr("westus"),
		// 				Errors: &armworkloads.MonitorPropertiesErrors{
		// 				},
		// 				LogAnalyticsWorkspaceArmID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/example-rg/providers/microsoft.operationalinsights/workspaces/myWorkspace"),
		// 				ManagedResourceGroupConfiguration: &armworkloads.ManagedRGConfiguration{
		// 					Name: to.Ptr("myManagedRg2"),
		// 				},
		// 				MonitorSubnet: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/example-rg/providers/Microsoft.Network/virtualNetworks/myVnet/subnets/mySubnet"),
		// 				MsiArmID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.ManagedIdentity/userAssignedIdentities/myMsi"),
		// 				ProvisioningState: to.Ptr(armworkloads.WorkloadMonitorProvisioningStateSucceeded),
		// 				RoutingPreference: to.Ptr(armworkloads.RoutingPreferenceDefault),
		// 				StorageAccountArmID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Storage/storageAccounts/mystorageaccount"),
		// 			},
		// 	}},
		// }
	}
}
Output:

func (*MonitorsClient) NewListPager

NewListPager - Gets a list of SAP monitors in the specified subscription. The operations returns various properties of each SAP monitor.

Generated from API version 2022-11-01-preview

  • options - MonitorsClientListOptions contains the optional parameters for the MonitorsClient.NewListPager method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/workloadmonitor/monitors_List.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewMonitorsClient("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	pager := client.NewListPager(nil)
	for pager.More() {
		page, err := pager.NextPage(ctx)
		if err != nil {
			log.Fatalf("failed to advance page: %v", err)
		}
		for _, v := range page.Value {
			// You could use page here. We use blank identifier for just demo purposes.
			_ = v
		}
		// If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
		// page.MonitorListResult = armworkloads.MonitorListResult{
		// 	Value: []*armworkloads.Monitor{
		// 		{
		// 			Name: to.Ptr("mySapMonitor1"),
		// 			Type: to.Ptr("Microsoft.Workloads/workloads"),
		// 			ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/workloads/mySapMonitor1"),
		// 			Location: to.Ptr("westus"),
		// 			Tags: map[string]*string{
		// 				"key": to.Ptr("value"),
		// 			},
		// 			Properties: &armworkloads.MonitorProperties{
		// 				AppLocation: to.Ptr("eastus"),
		// 				Errors: &armworkloads.MonitorPropertiesErrors{
		// 				},
		// 				LogAnalyticsWorkspaceArmID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/myResourceGroup/providers/microsoft.operationalinsights/workspaces/myWorkspace"),
		// 				ManagedResourceGroupConfiguration: &armworkloads.ManagedRGConfiguration{
		// 					Name: to.Ptr("myManagedRg1"),
		// 				},
		// 				MonitorSubnet: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Network/virtualNetworks/myVnet/subnets/mySubnet"),
		// 				MsiArmID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.ManagedIdentity/userAssignedIdentities/myMsi"),
		// 				ProvisioningState: to.Ptr(armworkloads.WorkloadMonitorProvisioningStateSucceeded),
		// 				RoutingPreference: to.Ptr(armworkloads.RoutingPreferenceRouteAll),
		// 				StorageAccountArmID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Storage/storageAccounts/mystorageaccount"),
		// 				ZoneRedundancyPreference: to.Ptr("ZoneRedundantApp"),
		// 			},
		// 		},
		// 		{
		// 			Name: to.Ptr("mySapMonitor2"),
		// 			Type: to.Ptr("Microsoft.Workloads/workloads"),
		// 			ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/workloads/mySapMonitor2"),
		// 			Location: to.Ptr("westus"),
		// 			Tags: map[string]*string{
		// 				"key": to.Ptr("value"),
		// 			},
		// 			Properties: &armworkloads.MonitorProperties{
		// 				AppLocation: to.Ptr("westus"),
		// 				Errors: &armworkloads.MonitorPropertiesErrors{
		// 				},
		// 				LogAnalyticsWorkspaceArmID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/myResourceGroup/providers/microsoft.operationalinsights/workspaces/myWorkspace"),
		// 				ManagedResourceGroupConfiguration: &armworkloads.ManagedRGConfiguration{
		// 					Name: to.Ptr("myManagedRg2"),
		// 				},
		// 				MonitorSubnet: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Network/virtualNetworks/myVnet/subnets/mySubnet"),
		// 				MsiArmID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.ManagedIdentity/userAssignedIdentities/myMsi"),
		// 				ProvisioningState: to.Ptr(armworkloads.WorkloadMonitorProvisioningStateSucceeded),
		// 				RoutingPreference: to.Ptr(armworkloads.RoutingPreferenceDefault),
		// 				StorageAccountArmID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Storage/storageAccounts/mystorageaccount"),
		// 			},
		// 	}},
		// }
	}
}
Output:

func (*MonitorsClient) Update

func (client *MonitorsClient) Update(ctx context.Context, resourceGroupName string, monitorName string, body UpdateMonitorRequest, options *MonitorsClientUpdateOptions) (MonitorsClientUpdateResponse, error)

Update - Patches the Tags field of a SAP monitor for the specified subscription, resource group, and SAP monitor name. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • monitorName - Name of the SAP monitor resource.
  • body - The Update SAP workload monitor request body.
  • options - MonitorsClientUpdateOptions contains the optional parameters for the MonitorsClient.Update method.
Example (DeleteTagsFieldOfASapMonitor)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/workloadmonitor/monitors_PatchTags_Delete.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewMonitorsClient("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := client.Update(ctx, "myResourceGroup", "mySapMonitor", armworkloads.UpdateMonitorRequest{
		Identity: &armworkloads.UserAssignedServiceIdentity{
			Type: to.Ptr(armworkloads.ManagedServiceIdentityTypeNone),
		},
		Tags: map[string]*string{},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.Monitor = armworkloads.Monitor{
	// 	Name: to.Ptr("mySapMonitor"),
	// 	Type: to.Ptr("Microsoft.Workloads/workloads"),
	// 	ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/workloads/mySapMonitor"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westus"),
	// 	Tags: map[string]*string{
	// 		"testkey": to.Ptr("testvalue"),
	// 	},
	// 	Identity: &armworkloads.UserAssignedServiceIdentity{
	// 		Type: to.Ptr(armworkloads.ManagedServiceIdentityTypeNone),
	// 	},
	// 	Properties: &armworkloads.MonitorProperties{
	// 		AppLocation: to.Ptr("eastus"),
	// 		Errors: &armworkloads.MonitorPropertiesErrors{
	// 		},
	// 		LogAnalyticsWorkspaceArmID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/myResourceGroup/providers/microsoft.operationalinsights/workspaces/myWorkspace"),
	// 		ManagedResourceGroupConfiguration: &armworkloads.ManagedRGConfiguration{
	// 			Name: to.Ptr("myManagedRg"),
	// 		},
	// 		MonitorSubnet: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Network/virtualNetworks/myVnet/subnets/mySubnet"),
	// 		MsiArmID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.ManagedIdentity/userAssignedIdentities/myMsi"),
	// 		ProvisioningState: to.Ptr(armworkloads.WorkloadMonitorProvisioningStateSucceeded),
	// 		RoutingPreference: to.Ptr(armworkloads.RoutingPreferenceRouteAll),
	// 		StorageAccountArmID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Storage/storageAccounts/mystorageaccount"),
	// 		ZoneRedundancyPreference: to.Ptr("ZoneRedundantApp"),
	// 	},
	// }
}
Output:

Example (UpdateTagsFieldOfASapMonitor)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/workloadmonitor/monitors_PatchTags.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewMonitorsClient("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := client.Update(ctx, "myResourceGroup", "mySapMonitor", armworkloads.UpdateMonitorRequest{
		Identity: &armworkloads.UserAssignedServiceIdentity{
			Type: to.Ptr(armworkloads.ManagedServiceIdentityTypeNone),
		},
		Tags: map[string]*string{
			"testkey": to.Ptr("testvalue"),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.Monitor = armworkloads.Monitor{
	// 	Name: to.Ptr("mySapMonitor"),
	// 	Type: to.Ptr("Microsoft.Workloads/workloads"),
	// 	ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/workloads/mySapMonitor"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westus"),
	// 	Tags: map[string]*string{
	// 		"testkey": to.Ptr("testvalue"),
	// 	},
	// 	Identity: &armworkloads.UserAssignedServiceIdentity{
	// 		Type: to.Ptr(armworkloads.ManagedServiceIdentityTypeNone),
	// 	},
	// 	Properties: &armworkloads.MonitorProperties{
	// 		AppLocation: to.Ptr("eastus"),
	// 		Errors: &armworkloads.MonitorPropertiesErrors{
	// 		},
	// 		LogAnalyticsWorkspaceArmID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/myResourceGroup/providers/microsoft.operationalinsights/workspaces/myWorkspace"),
	// 		ManagedResourceGroupConfiguration: &armworkloads.ManagedRGConfiguration{
	// 			Name: to.Ptr("myManagedRg"),
	// 		},
	// 		MonitorSubnet: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Network/virtualNetworks/myVnet/subnets/mySubnet"),
	// 		MsiArmID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.ManagedIdentity/userAssignedIdentities/myMsi"),
	// 		ProvisioningState: to.Ptr(armworkloads.WorkloadMonitorProvisioningStateSucceeded),
	// 		RoutingPreference: to.Ptr(armworkloads.RoutingPreferenceRouteAll),
	// 		StorageAccountArmID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Storage/storageAccounts/mystorageaccount"),
	// 		ZoneRedundancyPreference: to.Ptr("ZoneRedundantApp"),
	// 	},
	// }
}
Output:

type MonitorsClientBeginCreateOptions

type MonitorsClientBeginCreateOptions struct {
	// Resumes the LRO from the provided token.
	ResumeToken string
}

MonitorsClientBeginCreateOptions contains the optional parameters for the MonitorsClient.BeginCreate method.

type MonitorsClientBeginDeleteOptions

type MonitorsClientBeginDeleteOptions struct {
	// Resumes the LRO from the provided token.
	ResumeToken string
}

MonitorsClientBeginDeleteOptions contains the optional parameters for the MonitorsClient.BeginDelete method.

type MonitorsClientCreateResponse

type MonitorsClientCreateResponse struct {
	Monitor
}

MonitorsClientCreateResponse contains the response from method MonitorsClient.BeginCreate.

type MonitorsClientDeleteResponse

type MonitorsClientDeleteResponse struct {
	OperationStatusResult
}

MonitorsClientDeleteResponse contains the response from method MonitorsClient.BeginDelete.

type MonitorsClientGetOptions

type MonitorsClientGetOptions struct {
}

MonitorsClientGetOptions contains the optional parameters for the MonitorsClient.Get method.

type MonitorsClientGetResponse

type MonitorsClientGetResponse struct {
	Monitor
}

MonitorsClientGetResponse contains the response from method MonitorsClient.Get.

type MonitorsClientListByResourceGroupOptions

type MonitorsClientListByResourceGroupOptions struct {
}

MonitorsClientListByResourceGroupOptions contains the optional parameters for the MonitorsClient.NewListByResourceGroupPager method.

type MonitorsClientListByResourceGroupResponse

type MonitorsClientListByResourceGroupResponse struct {
	MonitorListResult
}

MonitorsClientListByResourceGroupResponse contains the response from method MonitorsClient.NewListByResourceGroupPager.

type MonitorsClientListOptions

type MonitorsClientListOptions struct {
}

MonitorsClientListOptions contains the optional parameters for the MonitorsClient.NewListPager method.

type MonitorsClientListResponse

type MonitorsClientListResponse struct {
	MonitorListResult
}

MonitorsClientListResponse contains the response from method MonitorsClient.NewListPager.

type MonitorsClientUpdateOptions

type MonitorsClientUpdateOptions struct {
}

MonitorsClientUpdateOptions contains the optional parameters for the MonitorsClient.Update method.

type MonitorsClientUpdateResponse

type MonitorsClientUpdateResponse struct {
	Monitor
}

MonitorsClientUpdateResponse contains the response from method MonitorsClient.Update.

type MountFileShareConfiguration added in v0.3.0

type MountFileShareConfiguration struct {
	// REQUIRED; The type of file share config.
	ConfigurationType *ConfigurationType `json:"configurationType,omitempty"`

	// REQUIRED; The fileshare resource ID
	ID *string `json:"id,omitempty"`

	// REQUIRED; The private endpoint resource ID
	PrivateEndpointID *string `json:"privateEndpointId,omitempty"`
}

MountFileShareConfiguration - Gets or sets the file share configuration for externally mounted cases.

func (*MountFileShareConfiguration) GetFileShareConfiguration added in v0.3.0

func (m *MountFileShareConfiguration) GetFileShareConfiguration() *FileShareConfiguration

GetFileShareConfiguration implements the FileShareConfigurationClassification interface for type MountFileShareConfiguration.

func (MountFileShareConfiguration) MarshalJSON added in v0.3.0

func (m MountFileShareConfiguration) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type MountFileShareConfiguration.

func (*MountFileShareConfiguration) UnmarshalJSON added in v0.3.0

func (m *MountFileShareConfiguration) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type MountFileShareConfiguration.

type MsSQLServerProviderInstanceProperties

type MsSQLServerProviderInstanceProperties struct {
	// REQUIRED; The provider type. For example, the value can be SapHana.
	ProviderType *string `json:"providerType,omitempty"`

	// Gets or sets the database password.
	DbPassword *string `json:"dbPassword,omitempty"`

	// Gets or sets the key vault URI to secret with the database password.
	DbPasswordURI *string `json:"dbPasswordUri,omitempty"`

	// Gets or sets the database sql port.
	DbPort *string `json:"dbPort,omitempty"`

	// Gets or sets the database user name.
	DbUsername *string `json:"dbUsername,omitempty"`

	// Gets or sets the SQL server host name.
	Hostname *string `json:"hostname,omitempty"`

	// Gets or sets the blob URI to SSL certificate for the SQL Database.
	SSLCertificateURI *string `json:"sslCertificateUri,omitempty"`

	// Gets or sets certificate preference if secure communication is enabled.
	SSLPreference *SSLPreference `json:"sslPreference,omitempty"`

	// Gets or sets the SAP System Identifier
	SapSid *string `json:"sapSid,omitempty"`
}

MsSQLServerProviderInstanceProperties - Gets or sets the SQL server provider properties.

func (*MsSQLServerProviderInstanceProperties) GetProviderSpecificProperties

func (m *MsSQLServerProviderInstanceProperties) GetProviderSpecificProperties() *ProviderSpecificProperties

GetProviderSpecificProperties implements the ProviderSpecificPropertiesClassification interface for type MsSQLServerProviderInstanceProperties.

func (MsSQLServerProviderInstanceProperties) MarshalJSON

func (m MsSQLServerProviderInstanceProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type MsSQLServerProviderInstanceProperties.

func (*MsSQLServerProviderInstanceProperties) UnmarshalJSON

func (m *MsSQLServerProviderInstanceProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type MsSQLServerProviderInstanceProperties.

type NamingPatternType added in v0.3.0

type NamingPatternType string

NamingPatternType - The pattern type to be used for resource naming.

const (
	NamingPatternTypeFullResourceName NamingPatternType = "FullResourceName"
)

func PossibleNamingPatternTypeValues added in v0.3.0

func PossibleNamingPatternTypeValues() []NamingPatternType

PossibleNamingPatternTypeValues returns the possible values for the NamingPatternType const type.

type NetworkConfiguration added in v0.2.0

type NetworkConfiguration struct {
	// Specifies whether a secondary IP address should be added to the network interface on all VMs of the SAP system being deployed
	IsSecondaryIPEnabled *bool `json:"isSecondaryIpEnabled,omitempty"`
}

NetworkConfiguration - Defines the network configuration type for SAP system infrastructure that is being deployed

func (NetworkConfiguration) MarshalJSON added in v0.2.0

func (n NetworkConfiguration) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type NetworkConfiguration.

func (*NetworkConfiguration) UnmarshalJSON added in v0.2.0

func (n *NetworkConfiguration) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type NetworkConfiguration.

type NetworkInterfaceResourceNames added in v0.3.0

type NetworkInterfaceResourceNames struct {
	// The full name for network interface. If name is not provided, service uses a default name based on the deployment type.
	// For SingleServer, default name is {SID}-Nic. In case of HA-AvZone systems,
	// default name will be {SID}-{App/ASCS/DB}-Zone{A/B}-Nic with an incrementor at the end in case of more than 1 instance per
	// layer. For distributed and HA-AvSet systems, default name will be
	// {SID}-{App/ASCS/DB}-Nic with an incrementor at the end in case of more than 1 instance per layer.
	NetworkInterfaceName *string `json:"networkInterfaceName,omitempty"`
}

NetworkInterfaceResourceNames - The resource names object for network interface and related resources.

func (NetworkInterfaceResourceNames) MarshalJSON added in v0.3.0

func (n NetworkInterfaceResourceNames) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type NetworkInterfaceResourceNames.

func (*NetworkInterfaceResourceNames) UnmarshalJSON added in v0.3.0

func (n *NetworkInterfaceResourceNames) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type NetworkInterfaceResourceNames.

type OSConfiguration added in v0.2.0

type OSConfiguration struct {
	// REQUIRED; The OS Type
	OSType *OSType `json:"osType,omitempty"`
}

OSConfiguration - Defines the OS configuration.

func (*OSConfiguration) GetOSConfiguration added in v0.2.0

func (o *OSConfiguration) GetOSConfiguration() *OSConfiguration

GetOSConfiguration implements the OSConfigurationClassification interface for type OSConfiguration.

func (OSConfiguration) MarshalJSON added in v0.2.0

func (o OSConfiguration) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type OSConfiguration.

func (*OSConfiguration) UnmarshalJSON added in v0.2.0

func (o *OSConfiguration) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type OSConfiguration.

type OSConfigurationClassification added in v0.2.0

type OSConfigurationClassification interface {
	// GetOSConfiguration returns the OSConfiguration content of the underlying type.
	GetOSConfiguration() *OSConfiguration
}

OSConfigurationClassification provides polymorphic access to related types. Call the interface's GetOSConfiguration() method to access the common type. Use a type switch to determine the concrete type. The possible types are: - *LinuxConfiguration, *OSConfiguration, *WindowsConfiguration

type OSProfile added in v0.2.0

type OSProfile struct {
	// Specifies the password of the administrator account.
	// Minimum-length (Windows): 8 characters
	// Minimum-length (Linux): 6 characters
	// Max-length (Windows): 123 characters
	// Max-length (Linux): 72 characters
	// Complexity requirements: 3 out of 4 conditions below need to be fulfilled
	// Has lower characters
	// Has upper characters
	// Has a digit
	// Has a special character (Regex match [\W_])
	// Disallowed values: "abc@123", "P@$$w0rd", "P@ssw0rd", "P@ssword123", "Pa$$word", "pass@word1", "Password!", "Password1",
	// "Password22", "iloveyou!"
	// For resetting the password, see How to reset the Remote Desktop service or its login password in a Windows VM [https://docs.microsoft.com/troubleshoot/azure/virtual-machines/reset-rdp]
	// For resetting root password, see Manage users, SSH, and check or repair disks on Azure Linux VMs using the VMAccess Extension
	// [https://docs.microsoft.com/troubleshoot/azure/virtual-machines/troubleshoot-ssh-connection]
	AdminPassword *string `json:"adminPassword,omitempty"`

	// Specifies the name of the administrator account.
	// This property cannot be updated after the VM is created.
	// Windows-only restriction: Cannot end in "."
	// Disallowed values: "administrator", "admin", "user", "user1", "test", "user2", "test1", "user3", "admin1", "1", "123",
	// "a", "actuser", "adm", "admin2", "aspnet", "backup", "console", "david", "guest",
	// "john", "owner", "root", "server", "sql", "support", "support_388945a0", "sys", "test2", "test3", "user4", "user5".
	// Minimum-length (Linux): 1 character
	// Max-length (Linux): 64 characters
	// Max-length (Windows): 20 characters.
	AdminUsername *string `json:"adminUsername,omitempty"`

	// Specifies Windows operating system settings on the virtual machine.
	OSConfiguration OSConfigurationClassification `json:"osConfiguration,omitempty"`
}

OSProfile - Specifies the operating system settings for the virtual machine. Some of the settings cannot be changed once VM is provisioned.

func (OSProfile) MarshalJSON added in v0.2.0

func (o OSProfile) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type OSProfile.

func (*OSProfile) UnmarshalJSON added in v0.2.0

func (o *OSProfile) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type OSProfile.

type OSType added in v0.2.0

type OSType string

OSType - The OS Type

const (
	OSTypeLinux   OSType = "Linux"
	OSTypeWindows OSType = "Windows"
)

func PossibleOSTypeValues added in v0.2.0

func PossibleOSTypeValues() []OSType

PossibleOSTypeValues returns the possible values for the OSType const type.

type Operation

type Operation struct {
	// Localized display information for this particular operation.
	Display *OperationDisplay `json:"display,omitempty"`

	// READ-ONLY; Enum. Indicates the action type. "Internal" refers to actions that are for internal only APIs.
	ActionType *ActionType `json:"actionType,omitempty" azure:"ro"`

	// READ-ONLY; Whether the operation applies to data-plane. This is "true" for data-plane operations and "false" for ARM/control-plane
	// operations.
	IsDataAction *bool `json:"isDataAction,omitempty" azure:"ro"`

	// READ-ONLY; The name of the operation, as per Resource-Based Access Control (RBAC). Examples: "Microsoft.Compute/virtualMachines/write",
	// "Microsoft.Compute/virtualMachines/capture/action"
	Name *string `json:"name,omitempty" azure:"ro"`

	// READ-ONLY; The intended executor of the operation; as in Resource Based Access Control (RBAC) and audit logs UX. Default
	// value is "user,system"
	Origin *Origin `json:"origin,omitempty" azure:"ro"`
}

Operation - Details of a REST API operation, returned from the Resource Provider Operations API

func (Operation) MarshalJSON added in v0.2.0

func (o Operation) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type Operation.

func (*Operation) UnmarshalJSON added in v0.2.0

func (o *Operation) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type Operation.

type OperationDisplay

type OperationDisplay struct {
	// READ-ONLY; The short, localized friendly description of the operation; suitable for tool tips and detailed views.
	Description *string `json:"description,omitempty" azure:"ro"`

	// READ-ONLY; The concise, localized friendly name for the operation; suitable for dropdowns. E.g. "Create or Update Virtual
	// Machine", "Restart Virtual Machine".
	Operation *string `json:"operation,omitempty" azure:"ro"`

	// READ-ONLY; The localized friendly form of the resource provider name, e.g. "Microsoft Monitoring Insights" or "Microsoft
	// Compute".
	Provider *string `json:"provider,omitempty" azure:"ro"`

	// READ-ONLY; The localized friendly name of the resource type related to this operation. E.g. "Virtual Machines" or "Job
	// Schedule Collections".
	Resource *string `json:"resource,omitempty" azure:"ro"`
}

OperationDisplay - Localized display information for this particular operation.

func (OperationDisplay) MarshalJSON added in v0.2.0

func (o OperationDisplay) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type OperationDisplay.

func (*OperationDisplay) UnmarshalJSON added in v0.2.0

func (o *OperationDisplay) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type OperationDisplay.

type OperationListResult

type OperationListResult struct {
	// READ-ONLY; URL to get the next set of operation list results (if there are any).
	NextLink *string `json:"nextLink,omitempty" azure:"ro"`

	// READ-ONLY; List of operations supported by the resource provider
	Value []*Operation `json:"value,omitempty" azure:"ro"`
}

OperationListResult - A list of REST API operations supported by an Azure Resource Provider. It contains an URL link to get the next set of results.

func (OperationListResult) MarshalJSON added in v0.2.0

func (o OperationListResult) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type OperationListResult.

func (*OperationListResult) UnmarshalJSON added in v0.2.0

func (o *OperationListResult) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type OperationListResult.

type OperationProperties

type OperationProperties string

OperationProperties - Defines the workload operation origin.

const (
	OperationPropertiesNotSpecified OperationProperties = "NotSpecified"
	OperationPropertiesSystem       OperationProperties = "System"
	OperationPropertiesUser         OperationProperties = "User"
)

func PossibleOperationPropertiesValues

func PossibleOperationPropertiesValues() []OperationProperties

PossibleOperationPropertiesValues returns the possible values for the OperationProperties const type.

type OperationStatusResult

type OperationStatusResult struct {
	// REQUIRED; Operation status.
	Status *string `json:"status,omitempty"`

	// The end time of the operation.
	EndTime *time.Time `json:"endTime,omitempty"`

	// If present, details of the operation error.
	Error *ErrorDetail `json:"error,omitempty"`

	// Fully qualified ID for the async operation.
	ID *string `json:"id,omitempty"`

	// Name of the async operation.
	Name *string `json:"name,omitempty"`

	// The operations list.
	Operations []*OperationStatusResult `json:"operations,omitempty"`

	// Percent of the operation that is complete.
	PercentComplete *float32 `json:"percentComplete,omitempty"`

	// The start time of the operation.
	StartTime *time.Time `json:"startTime,omitempty"`
}

OperationStatusResult - The current status of an async operation.

func (OperationStatusResult) MarshalJSON added in v0.2.0

func (o OperationStatusResult) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type OperationStatusResult.

func (*OperationStatusResult) UnmarshalJSON

func (o *OperationStatusResult) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type OperationStatusResult.

type OperationsClient

type OperationsClient struct {
	// contains filtered or unexported fields
}

OperationsClient contains the methods for the Operations group. Don't use this type directly, use NewOperationsClient() instead.

func NewOperationsClient

func NewOperationsClient(credential azcore.TokenCredential, options *arm.ClientOptions) (*OperationsClient, error)

NewOperationsClient creates a new instance of OperationsClient with the specified values.

  • credential - used to authorize requests. Usually a credential from azidentity.
  • options - pass nil to accept the default values.

func (*OperationsClient) NewListPager

NewListPager - Lists all the available API operations under this PR

Generated from API version 2022-11-01-preview

  • options - OperationsClientListOptions contains the optional parameters for the OperationsClient.NewListPager method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/Operations_List.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewOperationsClient(cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	pager := client.NewListPager(nil)
	for pager.More() {
		page, err := pager.NextPage(ctx)
		if err != nil {
			log.Fatalf("failed to advance page: %v", err)
		}
		for _, v := range page.Value {
			// You could use page here. We use blank identifier for just demo purposes.
			_ = v
		}
		// If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
		// page.OperationListResult = armworkloads.OperationListResult{
		// 	Value: []*armworkloads.Operation{
		// 		{
		// 			Name: to.Ptr("Microsoft.Workloads/phpWorkloads/Write"),
		// 			Display: &armworkloads.OperationDisplay{
		// 				Description: to.Ptr("Set phpWorkloads"),
		// 				Operation: to.Ptr("Creates or updates the phpWorkloads"),
		// 				Provider: to.Ptr("Microsoft.Workloads"),
		// 				Resource: to.Ptr("phpWorkloads"),
		// 			},
		// 			IsDataAction: to.Ptr(false),
		// 		},
		// 		{
		// 			Name: to.Ptr("Microsoft.Workloads/phpWorkloads/Delete"),
		// 			Display: &armworkloads.OperationDisplay{
		// 				Description: to.Ptr("Delete phpWorkloads"),
		// 				Operation: to.Ptr("Deletes the phpWorkloads"),
		// 				Provider: to.Ptr("Microsoft.Workloads"),
		// 				Resource: to.Ptr("phpWorkloads"),
		// 			},
		// 			IsDataAction: to.Ptr(false),
		// 		},
		// 		{
		// 			Name: to.Ptr("Microsoft.Workloads/phpWorkloads/Read"),
		// 			Display: &armworkloads.OperationDisplay{
		// 				Description: to.Ptr("Read phpWorkloads"),
		// 				Operation: to.Ptr("Reads the phpWorkloads"),
		// 				Provider: to.Ptr("Microsoft.Workloads"),
		// 				Resource: to.Ptr("phpWorkloads"),
		// 			},
		// 			IsDataAction: to.Ptr(false),
		// 		},
		// 		{
		// 			Name: to.Ptr("Microsoft.Workloads/phpWorkloads/wordpressInstances/Write"),
		// 			Display: &armworkloads.OperationDisplay{
		// 				Description: to.Ptr("Set wordpressInstances"),
		// 				Operation: to.Ptr("Creates or updates the wordpressInstances"),
		// 				Provider: to.Ptr("Microsoft.Workloads"),
		// 				Resource: to.Ptr("wordpressInstances"),
		// 			},
		// 			IsDataAction: to.Ptr(false),
		// 		},
		// 		{
		// 			Name: to.Ptr("Microsoft.Workloads/phpWorkloads/wordpressInstances/Delete"),
		// 			Display: &armworkloads.OperationDisplay{
		// 				Description: to.Ptr("Delete wordpressInstances"),
		// 				Operation: to.Ptr("Deletes the wordpressInstances"),
		// 				Provider: to.Ptr("Microsoft.Workloads"),
		// 				Resource: to.Ptr("wordpressInstances"),
		// 			},
		// 			IsDataAction: to.Ptr(false),
		// 		},
		// 		{
		// 			Name: to.Ptr("Microsoft.Workloads/phpWorkloads/wordpressInstances/Read"),
		// 			Display: &armworkloads.OperationDisplay{
		// 				Description: to.Ptr("Read wordpressInstances"),
		// 				Operation: to.Ptr("Reads the wordpressInstances"),
		// 				Provider: to.Ptr("Microsoft.Workloads"),
		// 				Resource: to.Ptr("wordpressInstances"),
		// 			},
		// 			IsDataAction: to.Ptr(false),
		// 		},
		// 		{
		// 			Name: to.Ptr("Microsoft.Workloads/monitors/Read"),
		// 			Display: &armworkloads.OperationDisplay{
		// 				Description: to.Ptr("Reads the Monitor workload."),
		// 				Operation: to.Ptr("Read"),
		// 				Provider: to.Ptr("Microsoft.Workloads"),
		// 				Resource: to.Ptr("Microsoft.Workloads/monitors"),
		// 			},
		// 		},
		// 		{
		// 			Name: to.Ptr("Microsoft.Workloads/monitors/Write"),
		// 			Display: &armworkloads.OperationDisplay{
		// 				Description: to.Ptr("Creates or updates a Monitor workload."),
		// 				Operation: to.Ptr("Read"),
		// 				Provider: to.Ptr("Microsoft.Workloads"),
		// 				Resource: to.Ptr("Microsoft.Workloads/monitors"),
		// 			},
		// 	}},
		// }
	}
}
Output:

type OperationsClientListOptions

type OperationsClientListOptions struct {
}

OperationsClientListOptions contains the optional parameters for the OperationsClient.NewListPager method.

type OperationsClientListResponse

type OperationsClientListResponse struct {
	OperationListResult
}

OperationsClientListResponse contains the response from method OperationsClient.NewListPager.

type OperationsContent

type OperationsContent struct {
	// Operations content.
	Properties *OperationsDefinition `json:"properties,omitempty"`

	// READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
	ID *string `json:"id,omitempty" azure:"ro"`

	// READ-ONLY; The name of the resource
	Name *string `json:"name,omitempty" azure:"ro"`

	// READ-ONLY; Azure Resource Manager metadata containing createdBy and modifiedBy information.
	SystemData *SystemData `json:"systemData,omitempty" azure:"ro"`

	// READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
	Type *string `json:"type,omitempty" azure:"ro"`
}

OperationsContent - Defines the workload operation content.

func (OperationsContent) MarshalJSON added in v0.2.0

func (o OperationsContent) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type OperationsContent.

func (*OperationsContent) UnmarshalJSON added in v0.2.0

func (o *OperationsContent) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type OperationsContent.

type OperationsDefinition

type OperationsDefinition struct {
	// REQUIRED; Display information of the operation.
	Display *OperationsDefinitionDisplay `json:"display,omitempty"`

	// REQUIRED; Name of the operation.
	Name *string `json:"name,omitempty"`

	// Defines the action type of workload operation.
	ActionType *WorkloadMonitorActionType `json:"actionType,omitempty"`

	// Indicates whether the operation applies to data-plane.
	IsDataAction *bool `json:"isDataAction,omitempty"`

	// Defines the workload operation origin.
	Origin *OperationProperties `json:"origin,omitempty"`

	// Defines the workload operation properties.
	Properties any `json:"properties,omitempty"`
}

OperationsDefinition - Properties of an Operation.

func (OperationsDefinition) MarshalJSON added in v0.2.0

func (o OperationsDefinition) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type OperationsDefinition.

func (*OperationsDefinition) UnmarshalJSON added in v0.2.0

func (o *OperationsDefinition) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type OperationsDefinition.

type OperationsDefinitionArrayResponseWithContinuation

type OperationsDefinitionArrayResponseWithContinuation struct {
	// The URL to get to the next set of results, if there are any.
	NextLink *string `json:"nextLink,omitempty"`

	// Defines the workload operation definition response properties.
	Value []*OperationsDefinition `json:"value,omitempty"`
}

OperationsDefinitionArrayResponseWithContinuation - Defines the workload operation definition response.

func (OperationsDefinitionArrayResponseWithContinuation) MarshalJSON added in v0.2.0

MarshalJSON implements the json.Marshaller interface for type OperationsDefinitionArrayResponseWithContinuation.

func (*OperationsDefinitionArrayResponseWithContinuation) UnmarshalJSON added in v0.2.0

UnmarshalJSON implements the json.Unmarshaller interface for type OperationsDefinitionArrayResponseWithContinuation.

type OperationsDefinitionDisplay

type OperationsDefinitionDisplay struct {
	// REQUIRED; Describes the workload operation.
	Description *string `json:"description,omitempty"`

	// REQUIRED; Defines the workload operation.
	Operation *string `json:"operation,omitempty"`

	// REQUIRED; Defines the workload provider.
	Provider *string `json:"provider,omitempty"`

	// REQUIRED; Defines the workload resource.
	Resource *string `json:"resource,omitempty"`
}

OperationsDefinitionDisplay - Display information of the operation.

func (OperationsDefinitionDisplay) MarshalJSON added in v0.2.0

func (o OperationsDefinitionDisplay) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type OperationsDefinitionDisplay.

func (*OperationsDefinitionDisplay) UnmarshalJSON added in v0.2.0

func (o *OperationsDefinitionDisplay) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type OperationsDefinitionDisplay.

type OperationsDisplayDefinition

type OperationsDisplayDefinition struct {
	// REQUIRED; Describes the workload operation.
	Description *string `json:"description,omitempty"`

	// REQUIRED; Defines the workload operation.
	Operation *string `json:"operation,omitempty"`

	// REQUIRED; Defines the workload provider.
	Provider *string `json:"provider,omitempty"`

	// REQUIRED; Defines the workload resource.
	Resource *string `json:"resource,omitempty"`
}

OperationsDisplayDefinition - Defines the workload operation.

func (OperationsDisplayDefinition) MarshalJSON added in v0.2.0

func (o OperationsDisplayDefinition) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type OperationsDisplayDefinition.

func (*OperationsDisplayDefinition) UnmarshalJSON added in v0.2.0

func (o *OperationsDisplayDefinition) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type OperationsDisplayDefinition.

type Origin

type Origin string

Origin - The intended executor of the operation; as in Resource Based Access Control (RBAC) and audit logs UX. Default value is "user,system"

const (
	OriginSystem     Origin = "system"
	OriginUser       Origin = "user"
	OriginUserSystem Origin = "user,system"
)

func PossibleOriginValues

func PossibleOriginValues() []Origin

PossibleOriginValues returns the possible values for the Origin const type.

type OsSapConfiguration added in v0.2.0

type OsSapConfiguration struct {
	// The url and storage account ID where deployer VM packages are uploaded
	DeployerVMPackages *DeployerVMPackages `json:"deployerVmPackages,omitempty"`

	// The FQDN to set for the SAP system
	SapFqdn *string `json:"sapFqdn,omitempty"`
}

OsSapConfiguration - Defines the OS and SAP Configurations for Deployment

func (OsSapConfiguration) MarshalJSON added in v0.2.0

func (o OsSapConfiguration) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type OsSapConfiguration.

func (*OsSapConfiguration) UnmarshalJSON added in v0.2.0

func (o *OsSapConfiguration) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type OsSapConfiguration.

type PrometheusHaClusterProviderInstanceProperties

type PrometheusHaClusterProviderInstanceProperties struct {
	// REQUIRED; The provider type. For example, the value can be SapHana.
	ProviderType *string `json:"providerType,omitempty"`

	// Gets or sets the clusterName.
	ClusterName *string `json:"clusterName,omitempty"`

	// Gets or sets the target machine name.
	Hostname *string `json:"hostname,omitempty"`

	// URL of the Node Exporter endpoint.
	PrometheusURL *string `json:"prometheusUrl,omitempty"`

	// Gets or sets the blob URI to SSL certificate for the HA cluster exporter.
	SSLCertificateURI *string `json:"sslCertificateUri,omitempty"`

	// Gets or sets certificate preference if secure communication is enabled.
	SSLPreference *SSLPreference `json:"sslPreference,omitempty"`

	// Gets or sets the cluster sid.
	Sid *string `json:"sid,omitempty"`
}

PrometheusHaClusterProviderInstanceProperties - Gets or sets the PrometheusHaCluster provider properties.

func (*PrometheusHaClusterProviderInstanceProperties) GetProviderSpecificProperties

GetProviderSpecificProperties implements the ProviderSpecificPropertiesClassification interface for type PrometheusHaClusterProviderInstanceProperties.

func (PrometheusHaClusterProviderInstanceProperties) MarshalJSON

MarshalJSON implements the json.Marshaller interface for type PrometheusHaClusterProviderInstanceProperties.

func (*PrometheusHaClusterProviderInstanceProperties) UnmarshalJSON

func (p *PrometheusHaClusterProviderInstanceProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type PrometheusHaClusterProviderInstanceProperties.

type PrometheusOSProviderInstanceProperties

type PrometheusOSProviderInstanceProperties struct {
	// REQUIRED; The provider type. For example, the value can be SapHana.
	ProviderType *string `json:"providerType,omitempty"`

	// URL of the Node Exporter endpoint
	PrometheusURL *string `json:"prometheusUrl,omitempty"`

	// Gets or sets the blob URI to SSL certificate for the prometheus node exporter.
	SSLCertificateURI *string `json:"sslCertificateUri,omitempty"`

	// Gets or sets certificate preference if secure communication is enabled.
	SSLPreference *SSLPreference `json:"sslPreference,omitempty"`

	// Gets or sets the SAP System Identifier
	SapSid *string `json:"sapSid,omitempty"`
}

PrometheusOSProviderInstanceProperties - Gets or sets the PrometheusOS provider properties.

func (*PrometheusOSProviderInstanceProperties) GetProviderSpecificProperties

func (p *PrometheusOSProviderInstanceProperties) GetProviderSpecificProperties() *ProviderSpecificProperties

GetProviderSpecificProperties implements the ProviderSpecificPropertiesClassification interface for type PrometheusOSProviderInstanceProperties.

func (PrometheusOSProviderInstanceProperties) MarshalJSON

func (p PrometheusOSProviderInstanceProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type PrometheusOSProviderInstanceProperties.

func (*PrometheusOSProviderInstanceProperties) UnmarshalJSON

func (p *PrometheusOSProviderInstanceProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type PrometheusOSProviderInstanceProperties.

type ProviderInstance

type ProviderInstance struct {
	// Managed service identity (user assigned identities)
	Identity *UserAssignedServiceIdentity `json:"identity,omitempty"`

	// Provider Instance properties
	Properties *ProviderInstanceProperties `json:"properties,omitempty"`

	// READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
	ID *string `json:"id,omitempty" azure:"ro"`

	// READ-ONLY; The name of the resource
	Name *string `json:"name,omitempty" azure:"ro"`

	// READ-ONLY; Azure Resource Manager metadata containing createdBy and modifiedBy information.
	SystemData *SystemData `json:"systemData,omitempty" azure:"ro"`

	// READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
	Type *string `json:"type,omitempty" azure:"ro"`
}

ProviderInstance - A provider instance associated with SAP monitor.

func (ProviderInstance) MarshalJSON added in v0.2.0

func (p ProviderInstance) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ProviderInstance.

func (*ProviderInstance) UnmarshalJSON added in v0.2.0

func (p *ProviderInstance) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ProviderInstance.

type ProviderInstanceListResult

type ProviderInstanceListResult struct {
	// The URL to get the next set of provider instances.
	NextLink *string `json:"nextLink,omitempty"`

	// The list of provider instances.
	Value []*ProviderInstance `json:"value,omitempty"`
}

ProviderInstanceListResult - The response from the List provider instances operation.

func (ProviderInstanceListResult) MarshalJSON added in v0.2.0

func (p ProviderInstanceListResult) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ProviderInstanceListResult.

func (*ProviderInstanceListResult) UnmarshalJSON added in v0.2.0

func (p *ProviderInstanceListResult) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ProviderInstanceListResult.

type ProviderInstanceProperties

type ProviderInstanceProperties struct {
	// Defines the provider instance errors.
	ProviderSettings ProviderSpecificPropertiesClassification `json:"providerSettings,omitempty"`

	// READ-ONLY; Defines the provider instance errors.
	Errors *ProviderInstancePropertiesErrors `json:"errors,omitempty" azure:"ro"`

	// READ-ONLY; State of provisioning of the provider instance
	ProvisioningState *WorkloadMonitorProvisioningState `json:"provisioningState,omitempty" azure:"ro"`
}

ProviderInstanceProperties - Describes the properties of a provider instance.

func (ProviderInstanceProperties) MarshalJSON

func (p ProviderInstanceProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ProviderInstanceProperties.

func (*ProviderInstanceProperties) UnmarshalJSON

func (p *ProviderInstanceProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ProviderInstanceProperties.

type ProviderInstancePropertiesErrors

type ProviderInstancePropertiesErrors struct {
	// READ-ONLY; Server-defined set of error codes.
	Code *string `json:"code,omitempty" azure:"ro"`

	// READ-ONLY; Array of details about specific errors that led to this reported error.
	Details []*Error `json:"details,omitempty" azure:"ro"`

	// READ-ONLY; Object containing more specific information than the current object about the error.
	InnerError *ErrorInnerError `json:"innerError,omitempty" azure:"ro"`

	// READ-ONLY; Human-readable representation of the error.
	Message *string `json:"message,omitempty" azure:"ro"`

	// READ-ONLY; Target of the error.
	Target *string `json:"target,omitempty" azure:"ro"`
}

ProviderInstancePropertiesErrors - Defines the provider instance errors.

func (ProviderInstancePropertiesErrors) MarshalJSON

func (p ProviderInstancePropertiesErrors) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ProviderInstancePropertiesErrors.

func (*ProviderInstancePropertiesErrors) UnmarshalJSON added in v0.2.0

func (p *ProviderInstancePropertiesErrors) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ProviderInstancePropertiesErrors.

type ProviderInstancesClient

type ProviderInstancesClient struct {
	// contains filtered or unexported fields
}

ProviderInstancesClient contains the methods for the ProviderInstances group. Don't use this type directly, use NewProviderInstancesClient() instead.

func NewProviderInstancesClient

func NewProviderInstancesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*ProviderInstancesClient, error)

NewProviderInstancesClient creates a new instance of ProviderInstancesClient with the specified values.

  • subscriptionID - The ID of the target subscription.
  • credential - used to authorize requests. Usually a credential from azidentity.
  • options - pass nil to accept the default values.

func (*ProviderInstancesClient) BeginCreate

func (client *ProviderInstancesClient) BeginCreate(ctx context.Context, resourceGroupName string, monitorName string, providerInstanceName string, providerInstanceParameter ProviderInstance, options *ProviderInstancesClientBeginCreateOptions) (*runtime.Poller[ProviderInstancesClientCreateResponse], error)

BeginCreate - Creates a provider instance for the specified subscription, resource group, SAP monitor name, and resource name. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • monitorName - Name of the SAP monitor resource.
  • providerInstanceName - Name of the provider instance.
  • providerInstanceParameter - Request body representing a provider instance
  • options - ProviderInstancesClientBeginCreateOptions contains the optional parameters for the ProviderInstancesClient.BeginCreate method.
Example (CreateADb2Provider)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/workloadmonitor/Db2ProviderInstances_Create.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewProviderInstancesClient("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "myResourceGroup", "mySapMonitor", "myProviderInstance", armworkloads.ProviderInstance{
		Properties: &armworkloads.ProviderInstanceProperties{
			ProviderSettings: &armworkloads.DB2ProviderInstanceProperties{
				ProviderType:      to.Ptr("Db2"),
				DbName:            to.Ptr("dbName"),
				DbPassword:        to.Ptr("password"),
				DbPasswordURI:     to.Ptr(""),
				DbPort:            to.Ptr("dbPort"),
				DbUsername:        to.Ptr("username"),
				Hostname:          to.Ptr("hostname"),
				SapSid:            to.Ptr("SID"),
				SSLCertificateURI: to.Ptr("https://storageaccount.blob.core.windows.net/containername/filename"),
				SSLPreference:     to.Ptr(armworkloads.SSLPreferenceServerCertificate),
			},
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.ProviderInstance = armworkloads.ProviderInstance{
	// 	Name: to.Ptr("myProviderInstance"),
	// 	Type: to.Ptr("Microsoft.Workloads/workloads/providerInstances"),
	// 	ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/workloads/mySapMonitor/providerInstances/myProviderInstance"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Properties: &armworkloads.ProviderInstanceProperties{
	// 		ProviderSettings: &armworkloads.DB2ProviderInstanceProperties{
	// 			ProviderType: to.Ptr("Db2"),
	// 			DbName: to.Ptr("OPA"),
	// 			DbPasswordURI: to.Ptr(""),
	// 			DbPort: to.Ptr("5912"),
	// 			DbUsername: to.Ptr("Db2OPA"),
	// 			Hostname: to.Ptr("vmname.azure.com"),
	// 			SapSid: to.Ptr("SID"),
	// 			SSLCertificateURI: to.Ptr("https://storageaccount.blob.core.windows.net/containername/filename"),
	// 			SSLPreference: to.Ptr(armworkloads.SSLPreferenceServerCertificate),
	// 		},
	// 		ProvisioningState: to.Ptr(armworkloads.WorkloadMonitorProvisioningStateSucceeded),
	// 	},
	// }
}
Output:

Example (CreateADb2ProviderWithRootCertificate)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/workloadmonitor/Db2ProviderInstances_Create_Root_Certificate.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewProviderInstancesClient("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "myResourceGroup", "mySapMonitor", "myProviderInstance", armworkloads.ProviderInstance{
		Properties: &armworkloads.ProviderInstanceProperties{
			ProviderSettings: &armworkloads.DB2ProviderInstanceProperties{
				ProviderType:  to.Ptr("Db2"),
				DbName:        to.Ptr("dbName"),
				DbPassword:    to.Ptr("password"),
				DbPasswordURI: to.Ptr(""),
				DbPort:        to.Ptr("dbPort"),
				DbUsername:    to.Ptr("username"),
				Hostname:      to.Ptr("hostname"),
				SapSid:        to.Ptr("SID"),
				SSLPreference: to.Ptr(armworkloads.SSLPreferenceRootCertificate),
			},
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.ProviderInstance = armworkloads.ProviderInstance{
	// 	Name: to.Ptr("myProviderInstance"),
	// 	Type: to.Ptr("Microsoft.Workloads/workloads/providerInstances"),
	// 	ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/workloads/mySapMonitor/providerInstances/myProviderInstance"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Properties: &armworkloads.ProviderInstanceProperties{
	// 		ProviderSettings: &armworkloads.DB2ProviderInstanceProperties{
	// 			ProviderType: to.Ptr("Db2"),
	// 			DbName: to.Ptr("OPA"),
	// 			DbPasswordURI: to.Ptr(""),
	// 			DbPort: to.Ptr("5912"),
	// 			DbUsername: to.Ptr("Db2OPA"),
	// 			Hostname: to.Ptr("vmname.azure.com"),
	// 			SapSid: to.Ptr("SID"),
	// 			SSLPreference: to.Ptr(armworkloads.SSLPreferenceRootCertificate),
	// 		},
	// 		ProvisioningState: to.Ptr(armworkloads.WorkloadMonitorProvisioningStateSucceeded),
	// 	},
	// }
}
Output:

Example (CreateAMsSqlServerProvider)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/workloadmonitor/MsSqlServerProviderInstance_Create.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewProviderInstancesClient("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "myResourceGroup", "mySapMonitor", "myProviderInstance", armworkloads.ProviderInstance{
		Properties: &armworkloads.ProviderInstanceProperties{
			ProviderSettings: &armworkloads.MsSQLServerProviderInstanceProperties{
				ProviderType:      to.Ptr("MsSqlServer"),
				DbPassword:        to.Ptr("****"),
				DbPasswordURI:     to.Ptr(""),
				DbPort:            to.Ptr("5912"),
				DbUsername:        to.Ptr("user"),
				Hostname:          to.Ptr("hostname"),
				SapSid:            to.Ptr("sid"),
				SSLCertificateURI: to.Ptr("https://storageaccount.blob.core.windows.net/containername/filename"),
				SSLPreference:     to.Ptr(armworkloads.SSLPreferenceServerCertificate),
			},
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.ProviderInstance = armworkloads.ProviderInstance{
	// 	Name: to.Ptr("myProviderInstance"),
	// 	Type: to.Ptr("Microsoft.Workloads/workloads/providerInstances"),
	// 	ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/workloads/mySapMonitor/providerInstances/myProviderInstance"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Properties: &armworkloads.ProviderInstanceProperties{
	// 		ProviderSettings: &armworkloads.MsSQLServerProviderInstanceProperties{
	// 			ProviderType: to.Ptr("MsSqlServer"),
	// 			DbPort: to.Ptr("5912"),
	// 			DbUsername: to.Ptr("user"),
	// 			Hostname: to.Ptr("hostname"),
	// 			SapSid: to.Ptr("sid"),
	// 			SSLCertificateURI: to.Ptr("https://storageaccount.blob.core.windows.net/containername/filename"),
	// 			SSLPreference: to.Ptr(armworkloads.SSLPreferenceServerCertificate),
	// 		},
	// 		ProvisioningState: to.Ptr(armworkloads.WorkloadMonitorProvisioningStateSucceeded),
	// 	},
	// }
}
Output:

Example (CreateAMsSqlServerProviderWithRootCertificate)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/workloadmonitor/MsSqlServerProviderInstance_Create_Root_Certificate.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewProviderInstancesClient("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "myResourceGroup", "mySapMonitor", "myProviderInstance", armworkloads.ProviderInstance{
		Properties: &armworkloads.ProviderInstanceProperties{
			ProviderSettings: &armworkloads.MsSQLServerProviderInstanceProperties{
				ProviderType:  to.Ptr("MsSqlServer"),
				DbPassword:    to.Ptr("****"),
				DbPasswordURI: to.Ptr(""),
				DbPort:        to.Ptr("5912"),
				DbUsername:    to.Ptr("user"),
				Hostname:      to.Ptr("hostname"),
				SapSid:        to.Ptr("sid"),
				SSLPreference: to.Ptr(armworkloads.SSLPreferenceRootCertificate),
			},
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.ProviderInstance = armworkloads.ProviderInstance{
	// 	Name: to.Ptr("myProviderInstance"),
	// 	Type: to.Ptr("Microsoft.Workloads/workloads/providerInstances"),
	// 	ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/workloads/mySapMonitor/providerInstances/myProviderInstance"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Properties: &armworkloads.ProviderInstanceProperties{
	// 		ProviderSettings: &armworkloads.MsSQLServerProviderInstanceProperties{
	// 			ProviderType: to.Ptr("MsSqlServer"),
	// 			DbPort: to.Ptr("5912"),
	// 			DbUsername: to.Ptr("user"),
	// 			Hostname: to.Ptr("hostname"),
	// 			SapSid: to.Ptr("sid"),
	// 			SSLPreference: to.Ptr(armworkloads.SSLPreferenceRootCertificate),
	// 		},
	// 		ProvisioningState: to.Ptr(armworkloads.WorkloadMonitorProvisioningStateSucceeded),
	// 	},
	// }
}
Output:

Example (CreateAOsProvider)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/workloadmonitor/PrometheusOSProviderInstances_Create.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewProviderInstancesClient("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "myResourceGroup", "mySapMonitor", "myProviderInstance", armworkloads.ProviderInstance{
		Properties: &armworkloads.ProviderInstanceProperties{
			ProviderSettings: &armworkloads.PrometheusOSProviderInstanceProperties{
				ProviderType:      to.Ptr("PrometheusOS"),
				PrometheusURL:     to.Ptr("http://192.168.0.0:9090/metrics"),
				SapSid:            to.Ptr("SID"),
				SSLCertificateURI: to.Ptr("https://storageaccount.blob.core.windows.net/containername/filename"),
				SSLPreference:     to.Ptr(armworkloads.SSLPreferenceServerCertificate),
			},
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.ProviderInstance = armworkloads.ProviderInstance{
	// 	Name: to.Ptr("myProviderInstance"),
	// 	Type: to.Ptr("Microsoft.Workloads/workloads/providerInstances"),
	// 	ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/workloads/mySapMonitor/providerInstances/myProviderInstance"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Properties: &armworkloads.ProviderInstanceProperties{
	// 		ProviderSettings: &armworkloads.PrometheusOSProviderInstanceProperties{
	// 			ProviderType: to.Ptr("PrometheusOS"),
	// 			PrometheusURL: to.Ptr("http://192.168.0.0:9090/metrics"),
	// 			SapSid: to.Ptr("SID"),
	// 			SSLCertificateURI: to.Ptr("https://storageaccount.blob.core.windows.net/containername/filename"),
	// 			SSLPreference: to.Ptr(armworkloads.SSLPreferenceServerCertificate),
	// 		},
	// 		ProvisioningState: to.Ptr(armworkloads.WorkloadMonitorProvisioningStateSucceeded),
	// 	},
	// }
}
Output:

Example (CreateAOsProviderWithRootCertificate)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/workloadmonitor/PrometheusOSProviderInstances_Create_Root_Certificate.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewProviderInstancesClient("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "myResourceGroup", "mySapMonitor", "myProviderInstance", armworkloads.ProviderInstance{
		Properties: &armworkloads.ProviderInstanceProperties{
			ProviderSettings: &armworkloads.PrometheusOSProviderInstanceProperties{
				ProviderType:  to.Ptr("PrometheusOS"),
				PrometheusURL: to.Ptr("http://192.168.0.0:9090/metrics"),
				SapSid:        to.Ptr("SID"),
				SSLPreference: to.Ptr(armworkloads.SSLPreferenceRootCertificate),
			},
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.ProviderInstance = armworkloads.ProviderInstance{
	// 	Name: to.Ptr("myProviderInstance"),
	// 	Type: to.Ptr("Microsoft.Workloads/workloads/providerInstances"),
	// 	ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/workloads/mySapMonitor/providerInstances/myProviderInstance"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Properties: &armworkloads.ProviderInstanceProperties{
	// 		ProviderSettings: &armworkloads.PrometheusOSProviderInstanceProperties{
	// 			ProviderType: to.Ptr("PrometheusOS"),
	// 			PrometheusURL: to.Ptr("http://192.168.0.0:9090/metrics"),
	// 			SapSid: to.Ptr("SID"),
	// 			SSLPreference: to.Ptr(armworkloads.SSLPreferenceRootCertificate),
	// 		},
	// 		ProvisioningState: to.Ptr(armworkloads.WorkloadMonitorProvisioningStateSucceeded),
	// 	},
	// }
}
Output:

Example (CreateAPrometheusHaClusterProvider)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/workloadmonitor/PrometheusHaClusterProviderInstances_Create.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewProviderInstancesClient("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "myResourceGroup", "mySapMonitor", "myProviderInstance", armworkloads.ProviderInstance{
		Properties: &armworkloads.ProviderInstanceProperties{
			ProviderSettings: &armworkloads.PrometheusHaClusterProviderInstanceProperties{
				ProviderType:      to.Ptr("PrometheusHaCluster"),
				ClusterName:       to.Ptr("clusterName"),
				Hostname:          to.Ptr("hostname"),
				PrometheusURL:     to.Ptr("http://192.168.0.0:9090/metrics"),
				Sid:               to.Ptr("sid"),
				SSLCertificateURI: to.Ptr("https://storageaccount.blob.core.windows.net/containername/filename"),
				SSLPreference:     to.Ptr(armworkloads.SSLPreferenceServerCertificate),
			},
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.ProviderInstance = armworkloads.ProviderInstance{
	// 	Name: to.Ptr("myProviderInstance"),
	// 	Type: to.Ptr("Microsoft.Workloads/workloads/providerInstances"),
	// 	ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/workloads/mySapMonitor/providerInstances/myProviderInstance"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Properties: &armworkloads.ProviderInstanceProperties{
	// 		ProviderSettings: &armworkloads.PrometheusHaClusterProviderInstanceProperties{
	// 			ProviderType: to.Ptr("PrometheusHaCluster"),
	// 			ClusterName: to.Ptr("clusterName"),
	// 			Hostname: to.Ptr("hostname"),
	// 			PrometheusURL: to.Ptr("http://192.168.0.0:9090/metrics"),
	// 			Sid: to.Ptr("sid"),
	// 			SSLCertificateURI: to.Ptr("https://storageaccount.blob.core.windows.net/containername/filename"),
	// 			SSLPreference: to.Ptr(armworkloads.SSLPreferenceServerCertificate),
	// 		},
	// 		ProvisioningState: to.Ptr(armworkloads.WorkloadMonitorProvisioningStateSucceeded),
	// 	},
	// }
}
Output:

Example (CreateAPrometheusHaClusterProviderWithRootCertificate)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/workloadmonitor/PrometheusHaClusterProviderInstances_Create_Root_Certificate.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewProviderInstancesClient("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "myResourceGroup", "mySapMonitor", "myProviderInstance", armworkloads.ProviderInstance{
		Properties: &armworkloads.ProviderInstanceProperties{
			ProviderSettings: &armworkloads.PrometheusHaClusterProviderInstanceProperties{
				ProviderType:  to.Ptr("PrometheusHaCluster"),
				ClusterName:   to.Ptr("clusterName"),
				Hostname:      to.Ptr("hostname"),
				PrometheusURL: to.Ptr("http://192.168.0.0:9090/metrics"),
				Sid:           to.Ptr("sid"),
				SSLPreference: to.Ptr(armworkloads.SSLPreferenceRootCertificate),
			},
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.ProviderInstance = armworkloads.ProviderInstance{
	// 	Name: to.Ptr("myProviderInstance"),
	// 	Type: to.Ptr("Microsoft.Workloads/workloads/providerInstances"),
	// 	ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/workloads/mySapMonitor/providerInstances/myProviderInstance"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Properties: &armworkloads.ProviderInstanceProperties{
	// 		ProviderSettings: &armworkloads.PrometheusHaClusterProviderInstanceProperties{
	// 			ProviderType: to.Ptr("PrometheusHaCluster"),
	// 			ClusterName: to.Ptr("clusterName"),
	// 			Hostname: to.Ptr("hostname"),
	// 			PrometheusURL: to.Ptr("http://192.168.0.0:9090/metrics"),
	// 			Sid: to.Ptr("sid"),
	// 			SSLPreference: to.Ptr(armworkloads.SSLPreferenceRootCertificate),
	// 		},
	// 		ProvisioningState: to.Ptr(armworkloads.WorkloadMonitorProvisioningStateSucceeded),
	// 	},
	// }
}
Output:

Example (CreateASapMonitorHanaProvider)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/workloadmonitor/ProviderInstances_Create.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewProviderInstancesClient("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "myResourceGroup", "mySapMonitor", "myProviderInstance", armworkloads.ProviderInstance{
		Properties: &armworkloads.ProviderInstanceProperties{
			ProviderSettings: &armworkloads.HanaDbProviderInstanceProperties{
				ProviderType:             to.Ptr("SapHana"),
				DbName:                   to.Ptr("db"),
				DbPassword:               to.Ptr("****"),
				DbPasswordURI:            to.Ptr(""),
				DbUsername:               to.Ptr("user"),
				Hostname:                 to.Ptr("name"),
				InstanceNumber:           to.Ptr("00"),
				SapSid:                   to.Ptr("SID"),
				SQLPort:                  to.Ptr("0000"),
				SSLCertificateURI:        to.Ptr("https://storageaccount.blob.core.windows.net/containername/filename"),
				SSLHostNameInCertificate: to.Ptr("xyz.domain.com"),
				SSLPreference:            to.Ptr(armworkloads.SSLPreferenceServerCertificate),
			},
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.ProviderInstance = armworkloads.ProviderInstance{
	// 	Name: to.Ptr("myProviderInstance"),
	// 	Type: to.Ptr("Microsoft.Workloads/workloads/providerInstances"),
	// 	ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/workloads/mySapMonitor/providerInstances/myProviderInstance"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Properties: &armworkloads.ProviderInstanceProperties{
	// 		ProviderSettings: &armworkloads.HanaDbProviderInstanceProperties{
	// 			ProviderType: to.Ptr("SapHana"),
	// 			DbName: to.Ptr("db"),
	// 			DbPasswordURI: to.Ptr(""),
	// 			DbUsername: to.Ptr("user"),
	// 			Hostname: to.Ptr("name"),
	// 			InstanceNumber: to.Ptr("00"),
	// 			SapSid: to.Ptr("SID"),
	// 			SQLPort: to.Ptr("0000"),
	// 			SSLCertificateURI: to.Ptr("https://storageaccount.blob.core.windows.net/containername/filename"),
	// 			SSLHostNameInCertificate: to.Ptr("xyz.domain.com"),
	// 			SSLPreference: to.Ptr(armworkloads.SSLPreferenceServerCertificate),
	// 		},
	// 		ProvisioningState: to.Ptr(armworkloads.WorkloadMonitorProvisioningStateSucceeded),
	// 	},
	// }
}
Output:

Example (CreateASapMonitorHanaProviderWithRootCertificate)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/workloadmonitor/ProviderInstances_Create_Root_Certificate.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewProviderInstancesClient("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "myResourceGroup", "mySapMonitor", "myProviderInstance", armworkloads.ProviderInstance{
		Properties: &armworkloads.ProviderInstanceProperties{
			ProviderSettings: &armworkloads.HanaDbProviderInstanceProperties{
				ProviderType:             to.Ptr("SapHana"),
				DbName:                   to.Ptr("db"),
				DbPassword:               to.Ptr("****"),
				DbPasswordURI:            to.Ptr(""),
				DbUsername:               to.Ptr("user"),
				Hostname:                 to.Ptr("name"),
				InstanceNumber:           to.Ptr("00"),
				SapSid:                   to.Ptr("SID"),
				SQLPort:                  to.Ptr("0000"),
				SSLHostNameInCertificate: to.Ptr("xyz.domain.com"),
				SSLPreference:            to.Ptr(armworkloads.SSLPreferenceRootCertificate),
			},
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.ProviderInstance = armworkloads.ProviderInstance{
	// 	Name: to.Ptr("myProviderInstance"),
	// 	Type: to.Ptr("Microsoft.Workloads/workloads/providerInstances"),
	// 	ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/workloads/mySapMonitor/providerInstances/myProviderInstance"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Properties: &armworkloads.ProviderInstanceProperties{
	// 		ProviderSettings: &armworkloads.HanaDbProviderInstanceProperties{
	// 			ProviderType: to.Ptr("SapHana"),
	// 			DbName: to.Ptr("db"),
	// 			DbPasswordURI: to.Ptr(""),
	// 			DbUsername: to.Ptr("user"),
	// 			Hostname: to.Ptr("name"),
	// 			InstanceNumber: to.Ptr("00"),
	// 			SapSid: to.Ptr("SID"),
	// 			SQLPort: to.Ptr("0000"),
	// 			SSLHostNameInCertificate: to.Ptr("xyz.domain.com"),
	// 			SSLPreference: to.Ptr(armworkloads.SSLPreferenceRootCertificate),
	// 		},
	// 		ProvisioningState: to.Ptr(armworkloads.WorkloadMonitorProvisioningStateSucceeded),
	// 	},
	// }
}
Output:

Example (CreateASapMonitorNetWeaverProvider)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/workloadmonitor/NetWeaverProviderInstances_Create.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewProviderInstancesClient("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "myResourceGroup", "mySapMonitor", "myProviderInstance", armworkloads.ProviderInstance{
		Properties: &armworkloads.ProviderInstanceProperties{
			ProviderSettings: &armworkloads.SapNetWeaverProviderInstanceProperties{
				ProviderType: to.Ptr("SapNetWeaver"),
				SapClientID:  to.Ptr("111"),
				SapHostFileEntries: []*string{
					to.Ptr("127.0.0.1 name fqdn")},
				SapHostname:       to.Ptr("name"),
				SapInstanceNr:     to.Ptr("00"),
				SapPassword:       to.Ptr("****"),
				SapPasswordURI:    to.Ptr(""),
				SapPortNumber:     to.Ptr("1234"),
				SapSid:            to.Ptr("SID"),
				SapUsername:       to.Ptr("username"),
				SSLCertificateURI: to.Ptr("https://storageaccount.blob.core.windows.net/containername/filename"),
				SSLPreference:     to.Ptr(armworkloads.SSLPreferenceServerCertificate),
			},
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.ProviderInstance = armworkloads.ProviderInstance{
	// 	Name: to.Ptr("myProviderInstance"),
	// 	Type: to.Ptr("Microsoft.Workloads/workloads/providerInstances"),
	// 	ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/workloads/mySapMonitor/providerInstances/myProviderInstance"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Properties: &armworkloads.ProviderInstanceProperties{
	// 		ProviderSettings: &armworkloads.SapNetWeaverProviderInstanceProperties{
	// 			ProviderType: to.Ptr("SapNetWeaver"),
	// 			SapClientID: to.Ptr("111"),
	// 			SapHostFileEntries: []*string{
	// 				to.Ptr("127.0.0.1 name fqdn")},
	// 				SapHostname: to.Ptr("name"),
	// 				SapInstanceNr: to.Ptr("00"),
	// 				SapPasswordURI: to.Ptr(""),
	// 				SapPortNumber: to.Ptr("1234"),
	// 				SapSid: to.Ptr("SID"),
	// 				SapUsername: to.Ptr("username"),
	// 				SSLCertificateURI: to.Ptr("https://storageaccount.blob.core.windows.net/containername/filename"),
	// 				SSLPreference: to.Ptr(armworkloads.SSLPreferenceServerCertificate),
	// 			},
	// 			ProvisioningState: to.Ptr(armworkloads.WorkloadMonitorProvisioningStateSucceeded),
	// 		},
	// 	}
}
Output:

Example (CreateASapMonitorNetWeaverProviderWithRootCertificate)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/workloadmonitor/NetWeaverProviderInstances_Create_Root_Certificate.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewProviderInstancesClient("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "myResourceGroup", "mySapMonitor", "myProviderInstance", armworkloads.ProviderInstance{
		Properties: &armworkloads.ProviderInstanceProperties{
			ProviderSettings: &armworkloads.SapNetWeaverProviderInstanceProperties{
				ProviderType: to.Ptr("SapNetWeaver"),
				SapClientID:  to.Ptr("111"),
				SapHostFileEntries: []*string{
					to.Ptr("127.0.0.1 name fqdn")},
				SapHostname:    to.Ptr("name"),
				SapInstanceNr:  to.Ptr("00"),
				SapPassword:    to.Ptr("****"),
				SapPasswordURI: to.Ptr(""),
				SapPortNumber:  to.Ptr("1234"),
				SapSid:         to.Ptr("SID"),
				SapUsername:    to.Ptr("username"),
				SSLPreference:  to.Ptr(armworkloads.SSLPreferenceRootCertificate),
			},
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.ProviderInstance = armworkloads.ProviderInstance{
	// 	Name: to.Ptr("myProviderInstance"),
	// 	Type: to.Ptr("Microsoft.Workloads/workloads/providerInstances"),
	// 	ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/workloads/mySapMonitor/providerInstances/myProviderInstance"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Properties: &armworkloads.ProviderInstanceProperties{
	// 		ProviderSettings: &armworkloads.SapNetWeaverProviderInstanceProperties{
	// 			ProviderType: to.Ptr("SapNetWeaver"),
	// 			SapClientID: to.Ptr("111"),
	// 			SapHostFileEntries: []*string{
	// 				to.Ptr("127.0.0.1 name fqdn")},
	// 				SapHostname: to.Ptr("name"),
	// 				SapInstanceNr: to.Ptr("00"),
	// 				SapPasswordURI: to.Ptr(""),
	// 				SapPortNumber: to.Ptr("1234"),
	// 				SapSid: to.Ptr("SID"),
	// 				SapUsername: to.Ptr("username"),
	// 				SSLPreference: to.Ptr(armworkloads.SSLPreferenceRootCertificate),
	// 			},
	// 			ProvisioningState: to.Ptr(armworkloads.WorkloadMonitorProvisioningStateSucceeded),
	// 		},
	// 	}
}
Output:

func (*ProviderInstancesClient) BeginDelete

func (client *ProviderInstancesClient) BeginDelete(ctx context.Context, resourceGroupName string, monitorName string, providerInstanceName string, options *ProviderInstancesClientBeginDeleteOptions) (*runtime.Poller[ProviderInstancesClientDeleteResponse], error)

BeginDelete - Deletes a provider instance for the specified subscription, resource group, SAP monitor name, and resource name. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • monitorName - Name of the SAP monitor resource.
  • providerInstanceName - Name of the provider instance.
  • options - ProviderInstancesClientBeginDeleteOptions contains the optional parameters for the ProviderInstancesClient.BeginDelete method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/workloadmonitor/ProviderInstances_Delete.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewProviderInstancesClient("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginDelete(ctx, "myResourceGroup", "mySapMonitor", "myProviderInstance", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.OperationStatusResult = armworkloads.OperationStatusResult{
	// 	Name: to.Ptr("1e4193c3-206e-4916-b124-1da16175eb0f"),
	// 	EndTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T03:38:07.000Z"); return t}()),
	// 	ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/operations/locations/westus/1e4193c3-206e-4916-b124-1da16175eb0f"),
	// 	StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T03:36:07.000Z"); return t}()),
	// 	Status: to.Ptr("Succeeded"),
	// }
}
Output:

func (*ProviderInstancesClient) Get

func (client *ProviderInstancesClient) Get(ctx context.Context, resourceGroupName string, monitorName string, providerInstanceName string, options *ProviderInstancesClientGetOptions) (ProviderInstancesClientGetResponse, error)

Get - Gets properties of a provider instance for the specified subscription, resource group, SAP monitor name, and resource name. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • monitorName - Name of the SAP monitor resource.
  • providerInstanceName - Name of the provider instance.
  • options - ProviderInstancesClientGetOptions contains the optional parameters for the ProviderInstancesClient.Get method.
Example (GetPropertiesOfADb2Provider)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/workloadmonitor/Db2ProviderInstances_Get.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewProviderInstancesClient("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := client.Get(ctx, "myResourceGroup", "mySapMonitor", "myProviderInstance", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.ProviderInstance = armworkloads.ProviderInstance{
	// 	Name: to.Ptr("myProviderInstance"),
	// 	Type: to.Ptr("Microsoft.Workloads/workloads/providerInstances"),
	// 	ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/workloads/mySapMonitor/providerInstances/myProviderInstance"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Properties: &armworkloads.ProviderInstanceProperties{
	// 		ProviderSettings: &armworkloads.DB2ProviderInstanceProperties{
	// 			ProviderType: to.Ptr("Db2"),
	// 			DbName: to.Ptr("OPA"),
	// 			DbPasswordURI: to.Ptr(""),
	// 			DbPort: to.Ptr("5912"),
	// 			DbUsername: to.Ptr("Db2OPA"),
	// 			Hostname: to.Ptr("vmname.azure.com"),
	// 			SapSid: to.Ptr("SID"),
	// 			SSLCertificateURI: to.Ptr("https://storageaccount.blob.core.windows.net/containername/filename"),
	// 			SSLPreference: to.Ptr(armworkloads.SSLPreferenceServerCertificate),
	// 		},
	// 		ProvisioningState: to.Ptr(armworkloads.WorkloadMonitorProvisioningStateSucceeded),
	// 	},
	// }
}
Output:

Example (GetPropertiesOfAMsSqlServerProvider)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/workloadmonitor/MsSqlServerProviderInstance_Get.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewProviderInstancesClient("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := client.Get(ctx, "myResourceGroup", "mySapMonitor", "myProviderInstance", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.ProviderInstance = armworkloads.ProviderInstance{
	// 	Name: to.Ptr("myProviderInstance"),
	// 	Type: to.Ptr("Microsoft.Workloads/workloads/providerInstances"),
	// 	ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/workloads/mySapMonitor/providerInstances/myProviderInstance"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Properties: &armworkloads.ProviderInstanceProperties{
	// 		ProviderSettings: &armworkloads.MsSQLServerProviderInstanceProperties{
	// 			ProviderType: to.Ptr("MsSqlServer"),
	// 			DbPasswordURI: to.Ptr(""),
	// 			DbPort: to.Ptr("5912"),
	// 			DbUsername: to.Ptr("user"),
	// 			Hostname: to.Ptr("hostname"),
	// 			SapSid: to.Ptr("sid"),
	// 			SSLCertificateURI: to.Ptr("https://storageaccount.blob.core.windows.net/containername/filename"),
	// 			SSLPreference: to.Ptr(armworkloads.SSLPreferenceServerCertificate),
	// 		},
	// 		ProvisioningState: to.Ptr(armworkloads.WorkloadMonitorProvisioningStateSucceeded),
	// 	},
	// }
}
Output:

Example (GetPropertiesOfAOsProvider)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/workloadmonitor/PrometheusOSProviderInstances_Get.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewProviderInstancesClient("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := client.Get(ctx, "myResourceGroup", "mySapMonitor", "myProviderInstance", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.ProviderInstance = armworkloads.ProviderInstance{
	// 	Name: to.Ptr("myProviderInstance"),
	// 	Type: to.Ptr("Microsoft.Workloads/workloads/providerInstances"),
	// 	ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/workloads/mySapMonitor/providerInstances/myProviderInstance"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Properties: &armworkloads.ProviderInstanceProperties{
	// 		ProviderSettings: &armworkloads.PrometheusOSProviderInstanceProperties{
	// 			ProviderType: to.Ptr("PrometheusOS"),
	// 			PrometheusURL: to.Ptr("http://192.168.0.0:9090/metrics"),
	// 			SapSid: to.Ptr("SID"),
	// 			SSLCertificateURI: to.Ptr("https://storageaccount.blob.core.windows.net/containername/filename"),
	// 			SSLPreference: to.Ptr(armworkloads.SSLPreferenceServerCertificate),
	// 		},
	// 		ProvisioningState: to.Ptr(armworkloads.WorkloadMonitorProvisioningStateSucceeded),
	// 	},
	// }
}
Output:

Example (GetPropertiesOfAPrometheusHaClusterProvider)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/workloadmonitor/PrometheusHaClusterProviderInstances_Get.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewProviderInstancesClient("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := client.Get(ctx, "myResourceGroup", "mySapMonitor", "myProviderInstance", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.ProviderInstance = armworkloads.ProviderInstance{
	// 	Name: to.Ptr("myProviderInstance"),
	// 	Type: to.Ptr("Microsoft.Workloads/workloads/providerInstances"),
	// 	ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/workloads/mySapMonitor/providerInstances/myProviderInstance"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Properties: &armworkloads.ProviderInstanceProperties{
	// 		ProviderSettings: &armworkloads.PrometheusHaClusterProviderInstanceProperties{
	// 			ProviderType: to.Ptr("PrometheusHaCluster"),
	// 			ClusterName: to.Ptr("clusterName"),
	// 			Hostname: to.Ptr("hostname"),
	// 			PrometheusURL: to.Ptr("http://192.168.0.0:9090/metrics"),
	// 			Sid: to.Ptr("sid"),
	// 			SSLCertificateURI: to.Ptr("https://storageaccount.blob.core.windows.net/containername/filename"),
	// 			SSLPreference: to.Ptr(armworkloads.SSLPreferenceServerCertificate),
	// 		},
	// 		ProvisioningState: to.Ptr(armworkloads.WorkloadMonitorProvisioningStateSucceeded),
	// 	},
	// }
}
Output:

Example (GetPropertiesOfASapMonitorHanaProvider)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/workloadmonitor/ProviderInstances_Get.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewProviderInstancesClient("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := client.Get(ctx, "myResourceGroup", "mySapMonitor", "myProviderInstance", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.ProviderInstance = armworkloads.ProviderInstance{
	// 	Name: to.Ptr("myProviderInstance"),
	// 	Type: to.Ptr("Microsoft.Workloads/workloads/providerInstances"),
	// 	ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/workloads/mySapMonitor/providerInstances/myProviderInstance"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Properties: &armworkloads.ProviderInstanceProperties{
	// 		ProviderSettings: &armworkloads.HanaDbProviderInstanceProperties{
	// 			ProviderType: to.Ptr("SapHana"),
	// 			DbName: to.Ptr("db"),
	// 			DbPasswordURI: to.Ptr(""),
	// 			DbUsername: to.Ptr("user"),
	// 			Hostname: to.Ptr("name"),
	// 			InstanceNumber: to.Ptr("00"),
	// 			SapSid: to.Ptr("SID"),
	// 			SQLPort: to.Ptr("0000"),
	// 			SSLCertificateURI: to.Ptr("https://storageaccount.blob.core.windows.net/containername/filename"),
	// 			SSLHostNameInCertificate: to.Ptr("xyz.domain.com"),
	// 			SSLPreference: to.Ptr(armworkloads.SSLPreferenceServerCertificate),
	// 		},
	// 		ProvisioningState: to.Ptr(armworkloads.WorkloadMonitorProvisioningStateSucceeded),
	// 	},
	// }
}
Output:

Example (GetPropertiesOfASapMonitorNetWeaverProvider)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/workloadmonitor/NetWeaverProviderInstances_Get.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewProviderInstancesClient("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := client.Get(ctx, "myResourceGroup", "mySapMonitor", "myProviderInstance", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.ProviderInstance = armworkloads.ProviderInstance{
	// 	Name: to.Ptr("myProviderInstance"),
	// 	Type: to.Ptr("Microsoft.Workloads/workloads/providerInstances"),
	// 	ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/workloads/mySapMonitor/providerInstances/myProviderInstance"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Properties: &armworkloads.ProviderInstanceProperties{
	// 		ProviderSettings: &armworkloads.SapNetWeaverProviderInstanceProperties{
	// 			ProviderType: to.Ptr("SapNetWeaver"),
	// 			SapClientID: to.Ptr("111"),
	// 			SapHostFileEntries: []*string{
	// 				to.Ptr("127.0.0.1 name fqdn")},
	// 				SapHostname: to.Ptr("name"),
	// 				SapInstanceNr: to.Ptr("00"),
	// 				SapPasswordURI: to.Ptr(""),
	// 				SapPortNumber: to.Ptr("1234"),
	// 				SapSid: to.Ptr("SID"),
	// 				SapUsername: to.Ptr("username"),
	// 				SSLCertificateURI: to.Ptr("https://storageaccount.blob.core.windows.net/containername/filename"),
	// 				SSLPreference: to.Ptr(armworkloads.SSLPreferenceServerCertificate),
	// 			},
	// 			ProvisioningState: to.Ptr(armworkloads.WorkloadMonitorProvisioningStateSucceeded),
	// 		},
	// 	}
}
Output:

func (*ProviderInstancesClient) NewListPager

func (client *ProviderInstancesClient) NewListPager(resourceGroupName string, monitorName string, options *ProviderInstancesClientListOptions) *runtime.Pager[ProviderInstancesClientListResponse]

NewListPager - Gets a list of provider instances in the specified SAP monitor. The operations returns various properties of each provider instances.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • monitorName - Name of the SAP monitor resource.
  • options - ProviderInstancesClientListOptions contains the optional parameters for the ProviderInstancesClient.NewListPager method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/workloadmonitor/ProviderInstances_List.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewProviderInstancesClient("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	pager := client.NewListPager("myResourceGroup", "mySapMonitor", nil)
	for pager.More() {
		page, err := pager.NextPage(ctx)
		if err != nil {
			log.Fatalf("failed to advance page: %v", err)
		}
		for _, v := range page.Value {
			// You could use page here. We use blank identifier for just demo purposes.
			_ = v
		}
		// If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
		// page.ProviderInstanceListResult = armworkloads.ProviderInstanceListResult{
		// 	Value: []*armworkloads.ProviderInstance{
		// 		{
		// 			Name: to.Ptr("myProviderInstance1"),
		// 			Type: to.Ptr("Microsoft.Workloads/workloads/providerInstances"),
		// 			ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/workloads/mySapMonitor/providerInstances/myProviderInstance1"),
		// 			Properties: &armworkloads.ProviderInstanceProperties{
		// 				ProviderSettings: &armworkloads.HanaDbProviderInstanceProperties{
		// 					ProviderType: to.Ptr("SapHana"),
		// 					DbName: to.Ptr("db"),
		// 					DbPasswordURI: to.Ptr(""),
		// 					DbUsername: to.Ptr("user"),
		// 					Hostname: to.Ptr("name"),
		// 					InstanceNumber: to.Ptr("00"),
		// 					SapSid: to.Ptr("SID"),
		// 					SQLPort: to.Ptr("0000"),
		// 					SSLCertificateURI: to.Ptr("https://storageaccount.blob.core.windows.net/containername/filename"),
		// 					SSLHostNameInCertificate: to.Ptr("xyz.domain.com"),
		// 					SSLPreference: to.Ptr(armworkloads.SSLPreferenceServerCertificate),
		// 				},
		// 				ProvisioningState: to.Ptr(armworkloads.WorkloadMonitorProvisioningStateSucceeded),
		// 			},
		// 		},
		// 		{
		// 			Name: to.Ptr("myProviderInstance2"),
		// 			Type: to.Ptr("Microsoft.Workloads/workloads/providerInstances"),
		// 			ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/workloads/mySapMonitor/providerInstances/myProviderInstance1"),
		// 			Properties: &armworkloads.ProviderInstanceProperties{
		// 				ProviderSettings: &armworkloads.SapNetWeaverProviderInstanceProperties{
		// 					ProviderType: to.Ptr("SapNetWeaver"),
		// 					SapClientID: to.Ptr("111"),
		// 					SapHostFileEntries: []*string{
		// 						to.Ptr("127.0.0.1 name fqdn")},
		// 						SapHostname: to.Ptr("name"),
		// 						SapInstanceNr: to.Ptr("00"),
		// 						SapPasswordURI: to.Ptr(""),
		// 						SapPortNumber: to.Ptr("1234"),
		// 						SapSid: to.Ptr("SID"),
		// 						SapUsername: to.Ptr("username"),
		// 						SSLCertificateURI: to.Ptr("https://storageaccount.blob.core.windows.net/containername/filename"),
		// 						SSLPreference: to.Ptr(armworkloads.SSLPreferenceServerCertificate),
		// 					},
		// 					ProvisioningState: to.Ptr(armworkloads.WorkloadMonitorProvisioningStateSucceeded),
		// 				},
		// 			},
		// 			{
		// 				Name: to.Ptr("myProviderInstance4"),
		// 				Type: to.Ptr("Microsoft.Workloads/workloads/providerInstances"),
		// 				ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/workloads/mySapMonitor/providerInstances/myProviderInstance1"),
		// 				Properties: &armworkloads.ProviderInstanceProperties{
		// 					ProviderSettings: &armworkloads.MsSQLServerProviderInstanceProperties{
		// 						ProviderType: to.Ptr("MsSqlServer"),
		// 						DbPort: to.Ptr("5912"),
		// 						DbUsername: to.Ptr("user"),
		// 						Hostname: to.Ptr("hostname"),
		// 						SapSid: to.Ptr("sid"),
		// 						SSLCertificateURI: to.Ptr("https://storageaccount.blob.core.windows.net/containername/filename"),
		// 						SSLPreference: to.Ptr(armworkloads.SSLPreferenceServerCertificate),
		// 					},
		// 					ProvisioningState: to.Ptr(armworkloads.WorkloadMonitorProvisioningStateSucceeded),
		// 				},
		// 			},
		// 			{
		// 				Name: to.Ptr("myProviderInstance3"),
		// 				Type: to.Ptr("Microsoft.Workloads/workloads/providerInstances"),
		// 				ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/workloads/mySapMonitor/providerInstances/myProviderInstance1"),
		// 				Properties: &armworkloads.ProviderInstanceProperties{
		// 					ProviderSettings: &armworkloads.PrometheusOSProviderInstanceProperties{
		// 						ProviderType: to.Ptr("PrometheusOS"),
		// 						PrometheusURL: to.Ptr("http://192.168.0.0:9090/metrics"),
		// 						SapSid: to.Ptr("SID"),
		// 						SSLCertificateURI: to.Ptr("https://storageaccount.blob.core.windows.net/containername/filename"),
		// 						SSLPreference: to.Ptr(armworkloads.SSLPreferenceServerCertificate),
		// 					},
		// 					ProvisioningState: to.Ptr(armworkloads.WorkloadMonitorProvisioningStateSucceeded),
		// 				},
		// 			},
		// 			{
		// 				Name: to.Ptr("myProviderInstance3"),
		// 				Type: to.Ptr("Microsoft.Workloads/workloads/providerInstances"),
		// 				ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/workloads/mySapMonitor/providerInstances/myProviderInstance1"),
		// 				Properties: &armworkloads.ProviderInstanceProperties{
		// 					ProviderSettings: &armworkloads.PrometheusHaClusterProviderInstanceProperties{
		// 						ProviderType: to.Ptr("PrometheusHaCluster"),
		// 						ClusterName: to.Ptr("clusterName"),
		// 						Hostname: to.Ptr("hostname"),
		// 						PrometheusURL: to.Ptr("http://192.168.0.0:9090/metrics"),
		// 						Sid: to.Ptr("sid"),
		// 						SSLCertificateURI: to.Ptr("https://storageaccount.blob.core.windows.net/containername/filename"),
		// 						SSLPreference: to.Ptr(armworkloads.SSLPreferenceServerCertificate),
		// 					},
		// 					ProvisioningState: to.Ptr(armworkloads.WorkloadMonitorProvisioningStateSucceeded),
		// 				},
		// 			},
		// 			{
		// 				Name: to.Ptr("myProviderInstance3"),
		// 				Type: to.Ptr("Microsoft.Workloads/workloads/providerInstances"),
		// 				ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/workloads/mySapMonitor/providerInstances/myProviderInstance1"),
		// 				Properties: &armworkloads.ProviderInstanceProperties{
		// 					ProviderSettings: &armworkloads.DB2ProviderInstanceProperties{
		// 						ProviderType: to.Ptr("Db2"),
		// 						DbName: to.Ptr("OPA"),
		// 						DbPasswordURI: to.Ptr(""),
		// 						DbPort: to.Ptr("5912"),
		// 						DbUsername: to.Ptr("Db2OPA"),
		// 						Hostname: to.Ptr("vmname.azure.com"),
		// 						SapSid: to.Ptr("SID"),
		// 						SSLCertificateURI: to.Ptr("https://storageaccount.blob.core.windows.net/containername/filename"),
		// 						SSLPreference: to.Ptr(armworkloads.SSLPreferenceServerCertificate),
		// 					},
		// 					ProvisioningState: to.Ptr(armworkloads.WorkloadMonitorProvisioningStateSucceeded),
		// 				},
		// 		}},
		// 	}
	}
}
Output:

type ProviderInstancesClientBeginCreateOptions

type ProviderInstancesClientBeginCreateOptions struct {
	// Resumes the LRO from the provided token.
	ResumeToken string
}

ProviderInstancesClientBeginCreateOptions contains the optional parameters for the ProviderInstancesClient.BeginCreate method.

type ProviderInstancesClientBeginDeleteOptions

type ProviderInstancesClientBeginDeleteOptions struct {
	// Resumes the LRO from the provided token.
	ResumeToken string
}

ProviderInstancesClientBeginDeleteOptions contains the optional parameters for the ProviderInstancesClient.BeginDelete method.

type ProviderInstancesClientCreateResponse

type ProviderInstancesClientCreateResponse struct {
	ProviderInstance
}

ProviderInstancesClientCreateResponse contains the response from method ProviderInstancesClient.BeginCreate.

type ProviderInstancesClientDeleteResponse

type ProviderInstancesClientDeleteResponse struct {
	OperationStatusResult
}

ProviderInstancesClientDeleteResponse contains the response from method ProviderInstancesClient.BeginDelete.

type ProviderInstancesClientGetOptions

type ProviderInstancesClientGetOptions struct {
}

ProviderInstancesClientGetOptions contains the optional parameters for the ProviderInstancesClient.Get method.

type ProviderInstancesClientGetResponse

type ProviderInstancesClientGetResponse struct {
	ProviderInstance
}

ProviderInstancesClientGetResponse contains the response from method ProviderInstancesClient.Get.

type ProviderInstancesClientListOptions

type ProviderInstancesClientListOptions struct {
}

ProviderInstancesClientListOptions contains the optional parameters for the ProviderInstancesClient.NewListPager method.

type ProviderInstancesClientListResponse

type ProviderInstancesClientListResponse struct {
	ProviderInstanceListResult
}

ProviderInstancesClientListResponse contains the response from method ProviderInstancesClient.NewListPager.

type ProviderSpecificProperties

type ProviderSpecificProperties struct {
	// REQUIRED; The provider type. For example, the value can be SapHana.
	ProviderType *string `json:"providerType,omitempty"`
}

ProviderSpecificProperties - Gets or sets the provider specific properties.

func (*ProviderSpecificProperties) GetProviderSpecificProperties

func (p *ProviderSpecificProperties) GetProviderSpecificProperties() *ProviderSpecificProperties

GetProviderSpecificProperties implements the ProviderSpecificPropertiesClassification interface for type ProviderSpecificProperties.

func (ProviderSpecificProperties) MarshalJSON added in v0.2.0

func (p ProviderSpecificProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ProviderSpecificProperties.

func (*ProviderSpecificProperties) UnmarshalJSON added in v0.2.0

func (p *ProviderSpecificProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ProviderSpecificProperties.

type ProviderSpecificPropertiesClassification

type ProviderSpecificPropertiesClassification interface {
	// GetProviderSpecificProperties returns the ProviderSpecificProperties content of the underlying type.
	GetProviderSpecificProperties() *ProviderSpecificProperties
}

ProviderSpecificPropertiesClassification provides polymorphic access to related types. Call the interface's GetProviderSpecificProperties() method to access the common type. Use a type switch to determine the concrete type. The possible types are: - *DB2ProviderInstanceProperties, *HanaDbProviderInstanceProperties, *MsSQLServerProviderInstanceProperties, *PrometheusHaClusterProviderInstanceProperties, - *PrometheusOSProviderInstanceProperties, *ProviderSpecificProperties, *SapNetWeaverProviderInstanceProperties

type ProxyResource

type ProxyResource struct {
	// READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
	ID *string `json:"id,omitempty" azure:"ro"`

	// READ-ONLY; The name of the resource
	Name *string `json:"name,omitempty" azure:"ro"`

	// READ-ONLY; Azure Resource Manager metadata containing createdBy and modifiedBy information.
	SystemData *SystemData `json:"systemData,omitempty" azure:"ro"`

	// READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
	Type *string `json:"type,omitempty" azure:"ro"`
}

ProxyResource - The resource model definition for a Azure Resource Manager proxy resource. It will not have tags and a location

func (ProxyResource) MarshalJSON added in v0.2.0

func (p ProxyResource) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ProxyResource.

func (*ProxyResource) UnmarshalJSON added in v0.2.0

func (p *ProxyResource) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ProxyResource.

type Resource

type Resource struct {
	// READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
	ID *string `json:"id,omitempty" azure:"ro"`

	// READ-ONLY; The name of the resource
	Name *string `json:"name,omitempty" azure:"ro"`

	// READ-ONLY; Azure Resource Manager metadata containing createdBy and modifiedBy information.
	SystemData *SystemData `json:"systemData,omitempty" azure:"ro"`

	// READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
	Type *string `json:"type,omitempty" azure:"ro"`
}

Resource - Common fields that are returned in the response for all Azure Resource Manager resources

func (Resource) MarshalJSON added in v0.2.0

func (r Resource) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type Resource.

func (*Resource) UnmarshalJSON added in v0.2.0

func (r *Resource) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type Resource.

type RoutingPreference

type RoutingPreference string

RoutingPreference - Sets the routing preference of the SAP monitor. By default only RFC1918 traffic is routed to the customer VNET.

const (
	RoutingPreferenceDefault  RoutingPreference = "Default"
	RoutingPreferenceRouteAll RoutingPreference = "RouteAll"
)

func PossibleRoutingPreferenceValues

func PossibleRoutingPreferenceValues() []RoutingPreference

PossibleRoutingPreferenceValues returns the possible values for the RoutingPreference const type.

type SAPApplicationServerInstance added in v0.2.0

type SAPApplicationServerInstance struct {
	// REQUIRED; The geo-location where the resource lives
	Location *string `json:"location,omitempty"`

	// Defines the SAP Application Server instance properties.
	Properties *SAPApplicationServerProperties `json:"properties,omitempty"`

	// Resource tags.
	Tags map[string]*string `json:"tags,omitempty"`

	// READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
	ID *string `json:"id,omitempty" azure:"ro"`

	// READ-ONLY; The name of the resource
	Name *string `json:"name,omitempty" azure:"ro"`

	// READ-ONLY; Azure Resource Manager metadata containing createdBy and modifiedBy information.
	SystemData *SystemData `json:"systemData,omitempty" azure:"ro"`

	// READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
	Type *string `json:"type,omitempty" azure:"ro"`
}

SAPApplicationServerInstance - Define the SAP Application Server Instance resource.

func (SAPApplicationServerInstance) MarshalJSON added in v0.2.0

func (s SAPApplicationServerInstance) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SAPApplicationServerInstance.

func (*SAPApplicationServerInstance) UnmarshalJSON added in v0.2.0

func (s *SAPApplicationServerInstance) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SAPApplicationServerInstance.

type SAPApplicationServerInstanceList added in v0.2.0

type SAPApplicationServerInstanceList struct {
	// Gets the value of next link.
	NextLink *string `json:"nextLink,omitempty"`

	// Gets the list of SAP Application Server instance resources.
	Value []*SAPApplicationServerInstance `json:"value,omitempty"`
}

SAPApplicationServerInstanceList - Defines the collection of SAP Application Server Instance resources.

func (SAPApplicationServerInstanceList) MarshalJSON added in v0.2.0

func (s SAPApplicationServerInstanceList) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SAPApplicationServerInstanceList.

func (*SAPApplicationServerInstanceList) UnmarshalJSON added in v0.2.0

func (s *SAPApplicationServerInstanceList) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SAPApplicationServerInstanceList.

type SAPApplicationServerInstancesClient added in v0.2.0

type SAPApplicationServerInstancesClient struct {
	// contains filtered or unexported fields
}

SAPApplicationServerInstancesClient contains the methods for the SAPApplicationServerInstances group. Don't use this type directly, use NewSAPApplicationServerInstancesClient() instead.

func NewSAPApplicationServerInstancesClient added in v0.2.0

func NewSAPApplicationServerInstancesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*SAPApplicationServerInstancesClient, error)

NewSAPApplicationServerInstancesClient creates a new instance of SAPApplicationServerInstancesClient with the specified values.

  • subscriptionID - The ID of the target subscription.
  • credential - used to authorize requests. Usually a credential from azidentity.
  • options - pass nil to accept the default values.

func (*SAPApplicationServerInstancesClient) BeginCreate added in v0.2.0

BeginCreate - Puts the SAP Application Server Instance resource. This will be used by service only. PUT by end user will return a Bad Request error. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • sapVirtualInstanceName - The name of the Virtual Instances for SAP solutions resource
  • applicationInstanceName - The name of SAP Application Server instance resource.
  • body - The SAP Application Server Instance resource request body.
  • options - SAPApplicationServerInstancesClientBeginCreateOptions contains the optional parameters for the SAPApplicationServerInstancesClient.BeginCreate method.
Example (CreateSapApplicationServerInstancesForHaSystemWithAvailabilitySet)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPApplicationServerInstances_Create_HA_AvSet.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPApplicationServerInstancesClient("6d875e77-e412-4d7d-9af4-8895278b4443", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "test-rg", "X00", "app01", armworkloads.SAPApplicationServerInstance{
		Location:   to.Ptr("westcentralus"),
		Tags:       map[string]*string{},
		Properties: &armworkloads.SAPApplicationServerProperties{},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPApplicationServerInstance = armworkloads.SAPApplicationServerInstance{
	// 	Name: to.Ptr("app01"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances/applicationInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00/applicationInstances/app01"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPApplicationServerProperties{
	// 		GatewayPort: to.Ptr[int64](3300),
	// 		Health: to.Ptr(armworkloads.SAPHealthStateUnknown),
	// 		Hostname: to.Ptr("vh-nw1"),
	// 		IcmHTTPPort: to.Ptr[int64](3312),
	// 		IcmHTTPSPort: to.Ptr[int64](3313),
	// 		InstanceNo: to.Ptr("01"),
	// 		IPAddress: to.Ptr("10.0.0.5"),
	// 		KernelPatch: to.Ptr("patch 300"),
	// 		KernelVersion: to.Ptr("777"),
	// 		LoadBalancerDetails: &armworkloads.LoadBalancerDetails{
	// 			ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Network/loadBalancers/cs-loadBalancer"),
	// 		},
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		Status: to.Ptr(armworkloads.SAPVirtualInstanceStatusRunning),
	// 		VMDetails: []*armworkloads.ApplicationServerVMDetails{
	// 			{
	// 				Type: to.Ptr(armworkloads.ApplicationServerVirtualMachineTypeActive),
	// 				StorageDetails: []*armworkloads.StorageInformation{
	// 					{
	// 						ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Storage/storageAccounts/nfsstorageaccount"),
	// 				}},
	// 				VirtualMachineID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Compute/virtualMachines/cs-vm1"),
	// 			},
	// 			{
	// 				Type: to.Ptr(armworkloads.ApplicationServerVirtualMachineTypeStandby),
	// 				StorageDetails: []*armworkloads.StorageInformation{
	// 					{
	// 						ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Storage/storageAccounts/nfsstorageaccount"),
	// 				}},
	// 				VirtualMachineID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Compute/virtualMachines/cs-vm2"),
	// 		}},
	// 	},
	// }
}
Output:

Example (SapApplicationServerInstancesCreate)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPApplicationServerInstances_Create.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPApplicationServerInstancesClient("6d875e77-e412-4d7d-9af4-8895278b4443", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "test-rg", "X00", "app01", armworkloads.SAPApplicationServerInstance{
		Location:   to.Ptr("westcentralus"),
		Tags:       map[string]*string{},
		Properties: &armworkloads.SAPApplicationServerProperties{},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPApplicationServerInstance = armworkloads.SAPApplicationServerInstance{
	// 	Name: to.Ptr("app01"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances/applicationInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00/applicationInstances/app01"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPApplicationServerProperties{
	// 		GatewayPort: to.Ptr[int64](3300),
	// 		Health: to.Ptr(armworkloads.SAPHealthStateUnknown),
	// 		Hostname: to.Ptr("vh-nw1"),
	// 		IcmHTTPPort: to.Ptr[int64](3312),
	// 		IcmHTTPSPort: to.Ptr[int64](3313),
	// 		InstanceNo: to.Ptr("01"),
	// 		IPAddress: to.Ptr("10.0.0.5"),
	// 		KernelPatch: to.Ptr("patch 300"),
	// 		KernelVersion: to.Ptr("777"),
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		Status: to.Ptr(armworkloads.SAPVirtualInstanceStatusRunning),
	// 		VMDetails: []*armworkloads.ApplicationServerVMDetails{
	// 			{
	// 				Type: to.Ptr(armworkloads.ApplicationServerVirtualMachineTypeActive),
	// 				VirtualMachineID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Compute/virtualMachines/app01-vm"),
	// 		}},
	// 	},
	// }
}
Output:

func (*SAPApplicationServerInstancesClient) BeginDelete added in v0.2.0

func (client *SAPApplicationServerInstancesClient) BeginDelete(ctx context.Context, resourceGroupName string, sapVirtualInstanceName string, applicationInstanceName string, options *SAPApplicationServerInstancesClientBeginDeleteOptions) (*runtime.Poller[SAPApplicationServerInstancesClientDeleteResponse], error)

BeginDelete - Deletes the SAP Application Server Instance resource. This operation will be used by service only. Delete by end user will return a Bad Request error. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • sapVirtualInstanceName - The name of the Virtual Instances for SAP solutions resource
  • applicationInstanceName - The name of SAP Application Server instance resource.
  • options - SAPApplicationServerInstancesClientBeginDeleteOptions contains the optional parameters for the SAPApplicationServerInstancesClient.BeginDelete method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPApplicationServerInstances_Delete.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPApplicationServerInstancesClient("6d875e77-e412-4d7d-9af4-8895278b4443", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginDelete(ctx, "test-rg", "X00", "app01", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.OperationStatusResult = armworkloads.OperationStatusResult{
	// 	Name: to.Ptr("1e4193c3-206e-4916-b124-1da16175eb0e"),
	// 	EndTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T03:38:07.000Z"); return t}()),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/operations/locations/centralus/1e4193c3-206e-4916-b124-1da16175eb0e"),
	// 	StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T03:36:07.000Z"); return t}()),
	// 	Status: to.Ptr("Succeeded"),
	// }
}
Output:

func (*SAPApplicationServerInstancesClient) BeginStartInstance added in v0.3.0

func (client *SAPApplicationServerInstancesClient) BeginStartInstance(ctx context.Context, resourceGroupName string, sapVirtualInstanceName string, applicationInstanceName string, options *SAPApplicationServerInstancesClientBeginStartInstanceOptions) (*runtime.Poller[SAPApplicationServerInstancesClientStartInstanceResponse], error)

BeginStartInstance - Starts the SAP Application Server Instance. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • sapVirtualInstanceName - The name of the Virtual Instances for SAP solutions resource
  • applicationInstanceName - The name of SAP Application Server instance resource.
  • options - SAPApplicationServerInstancesClientBeginStartInstanceOptions contains the optional parameters for the SAPApplicationServerInstancesClient.BeginStartInstance method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPApplicationServerInstances_StartInstance.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPApplicationServerInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginStartInstance(ctx, "test-rg", "X00", "app01", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.OperationStatusResult = armworkloads.OperationStatusResult{
	// 	Name: to.Ptr("app01"),
	// 	EndTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T03:38:07.000Z"); return t}()),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00/applicationInstances/app01"),
	// 	StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T03:36:07.000Z"); return t}()),
	// 	Status: to.Ptr("Succeeded"),
	// }
}
Output:

func (*SAPApplicationServerInstancesClient) BeginStopInstance added in v0.3.0

func (client *SAPApplicationServerInstancesClient) BeginStopInstance(ctx context.Context, resourceGroupName string, sapVirtualInstanceName string, applicationInstanceName string, options *SAPApplicationServerInstancesClientBeginStopInstanceOptions) (*runtime.Poller[SAPApplicationServerInstancesClientStopInstanceResponse], error)

BeginStopInstance - Stops the SAP Application Server Instance. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • sapVirtualInstanceName - The name of the Virtual Instances for SAP solutions resource
  • applicationInstanceName - The name of SAP Application Server instance resource.
  • options - SAPApplicationServerInstancesClientBeginStopInstanceOptions contains the optional parameters for the SAPApplicationServerInstancesClient.BeginStopInstance method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPApplicationServerInstances_StopInstance.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPApplicationServerInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginStopInstance(ctx, "test-rg", "X00", "app01", &armworkloads.SAPApplicationServerInstancesClientBeginStopInstanceOptions{Body: &armworkloads.StopRequest{
		SoftStopTimeoutSeconds: to.Ptr[int64](0),
	},
	})
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.OperationStatusResult = armworkloads.OperationStatusResult{
	// 	Name: to.Ptr("app01"),
	// 	EndTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T03:38:07.000Z"); return t}()),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00/applicationInstances/app01"),
	// 	StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T03:36:07.000Z"); return t}()),
	// 	Status: to.Ptr("Succeeded"),
	// }
}
Output:

func (*SAPApplicationServerInstancesClient) BeginUpdate added in v0.2.0

BeginUpdate - Puts the SAP Application Server Instance resource. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • sapVirtualInstanceName - The name of the Virtual Instances for SAP solutions resource
  • applicationInstanceName - The name of SAP Application Server instance resource.
  • body - The SAP Application Server Instance resource request body.
  • options - SAPApplicationServerInstancesClientBeginUpdateOptions contains the optional parameters for the SAPApplicationServerInstancesClient.BeginUpdate method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPApplicationServerInstances_Update.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPApplicationServerInstancesClient("6d875e77-e412-4d7d-9af4-8895278b4443", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginUpdate(ctx, "test-rg", "X00", "app01", armworkloads.UpdateSAPApplicationInstanceRequest{
		Tags: map[string]*string{
			"tag1": to.Ptr("value1"),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPApplicationServerInstance = armworkloads.SAPApplicationServerInstance{
	// 	Name: to.Ptr("app01"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances/applicationInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00/applicationInstances/app01"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPApplicationServerProperties{
	// 		GatewayPort: to.Ptr[int64](3300),
	// 		Health: to.Ptr(armworkloads.SAPHealthStateUnknown),
	// 		Hostname: to.Ptr("vh-nw1"),
	// 		IcmHTTPPort: to.Ptr[int64](3312),
	// 		IcmHTTPSPort: to.Ptr[int64](3313),
	// 		InstanceNo: to.Ptr("01"),
	// 		IPAddress: to.Ptr("10.0.0.5"),
	// 		KernelPatch: to.Ptr("patch 300"),
	// 		KernelVersion: to.Ptr("777"),
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		Status: to.Ptr(armworkloads.SAPVirtualInstanceStatus("Unknown")),
	// 		VMDetails: []*armworkloads.ApplicationServerVMDetails{
	// 			{
	// 				Type: to.Ptr(armworkloads.ApplicationServerVirtualMachineTypeActive),
	// 				VirtualMachineID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Compute/virtualMachines/app01-vm"),
	// 		}},
	// 	},
	// }
}
Output:

func (*SAPApplicationServerInstancesClient) Get added in v0.2.0

func (client *SAPApplicationServerInstancesClient) Get(ctx context.Context, resourceGroupName string, sapVirtualInstanceName string, applicationInstanceName string, options *SAPApplicationServerInstancesClientGetOptions) (SAPApplicationServerInstancesClientGetResponse, error)

Get - Gets the SAP Application Server Instance corresponding to the Virtual Instance for SAP solutions resource. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • sapVirtualInstanceName - The name of the Virtual Instances for SAP solutions resource
  • applicationInstanceName - The name of SAP Application Server instance resource.
  • options - SAPApplicationServerInstancesClientGetOptions contains the optional parameters for the SAPApplicationServerInstancesClient.Get method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPApplicationServerInstances_Get.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPApplicationServerInstancesClient("6d875e77-e412-4d7d-9af4-8895278b4443", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := client.Get(ctx, "test-rg", "X00", "app01", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPApplicationServerInstance = armworkloads.SAPApplicationServerInstance{
	// 	Name: to.Ptr("app01"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances/applicationInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00/applicationInstances/app01"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPApplicationServerProperties{
	// 		GatewayPort: to.Ptr[int64](3300),
	// 		Health: to.Ptr(armworkloads.SAPHealthStateUnknown),
	// 		Hostname: to.Ptr("vh-nw1"),
	// 		IcmHTTPPort: to.Ptr[int64](3312),
	// 		IcmHTTPSPort: to.Ptr[int64](3313),
	// 		InstanceNo: to.Ptr("00"),
	// 		IPAddress: to.Ptr("10.0.0.5"),
	// 		KernelPatch: to.Ptr("patch 300"),
	// 		KernelVersion: to.Ptr("777"),
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		Status: to.Ptr(armworkloads.SAPVirtualInstanceStatus("Unknown")),
	// 		VMDetails: []*armworkloads.ApplicationServerVMDetails{
	// 			{
	// 				Type: to.Ptr(armworkloads.ApplicationServerVirtualMachineTypeActive),
	// 				VirtualMachineID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Compute/virtualMachines/app01-vm"),
	// 		}},
	// 	},
	// }
}
Output:

func (*SAPApplicationServerInstancesClient) NewListPager added in v0.2.0

NewListPager - Lists the SAP Application Server Instance resources for a given Virtual Instance for SAP solutions resource.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • sapVirtualInstanceName - The name of the Virtual Instances for SAP solutions resource
  • options - SAPApplicationServerInstancesClientListOptions contains the optional parameters for the SAPApplicationServerInstancesClient.NewListPager method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPApplicationServerInstances_List.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPApplicationServerInstancesClient("6d875e77-e412-4d7d-9af4-8895278b4443", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	pager := client.NewListPager("test-rg", "X00", nil)
	for pager.More() {
		page, err := pager.NextPage(ctx)
		if err != nil {
			log.Fatalf("failed to advance page: %v", err)
		}
		for _, v := range page.Value {
			// You could use page here. We use blank identifier for just demo purposes.
			_ = v
		}
		// If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
		// page.SAPApplicationServerInstanceList = armworkloads.SAPApplicationServerInstanceList{
		// 	Value: []*armworkloads.SAPApplicationServerInstance{
		// 		{
		// 			Name: to.Ptr("app01"),
		// 			Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances/applicationInstances"),
		// 			ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00/applicationInstances/app01"),
		// 			SystemData: &armworkloads.SystemData{
		// 				CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
		// 				CreatedBy: to.Ptr("user@xyz.com"),
		// 				CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
		// 				LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
		// 				LastModifiedBy: to.Ptr("user@xyz.com"),
		// 				LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
		// 			},
		// 			Location: to.Ptr("westcentralus"),
		// 			Tags: map[string]*string{
		// 			},
		// 			Properties: &armworkloads.SAPApplicationServerProperties{
		// 				GatewayPort: to.Ptr[int64](3300),
		// 				Health: to.Ptr(armworkloads.SAPHealthStateUnknown),
		// 				Hostname: to.Ptr("vh-nw1"),
		// 				IcmHTTPPort: to.Ptr[int64](3312),
		// 				IcmHTTPSPort: to.Ptr[int64](3313),
		// 				InstanceNo: to.Ptr("00"),
		// 				IPAddress: to.Ptr("10.0.0.5"),
		// 				KernelPatch: to.Ptr("patch 300"),
		// 				KernelVersion: to.Ptr("777"),
		// 				ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
		// 				Status: to.Ptr(armworkloads.SAPVirtualInstanceStatus("Unknown")),
		// 				VMDetails: []*armworkloads.ApplicationServerVMDetails{
		// 					{
		// 						Type: to.Ptr(armworkloads.ApplicationServerVirtualMachineTypeActive),
		// 						VirtualMachineID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Compute/virtualMachines/app01-vm"),
		// 				}},
		// 			},
		// 		},
		// 		{
		// 			Name: to.Ptr("app02"),
		// 			Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances/applicationInstances"),
		// 			ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00/applicationInstances/app02"),
		// 			SystemData: &armworkloads.SystemData{
		// 				CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
		// 				CreatedBy: to.Ptr("user@xyz.com"),
		// 				CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
		// 				LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
		// 				LastModifiedBy: to.Ptr("user@xyz.com"),
		// 				LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
		// 			},
		// 			Location: to.Ptr("westcentralus"),
		// 			Tags: map[string]*string{
		// 			},
		// 			Properties: &armworkloads.SAPApplicationServerProperties{
		// 				GatewayPort: to.Ptr[int64](3300),
		// 				Health: to.Ptr(armworkloads.SAPHealthStateUnknown),
		// 				Hostname: to.Ptr("vh-nw1"),
		// 				IcmHTTPPort: to.Ptr[int64](3312),
		// 				IcmHTTPSPort: to.Ptr[int64](3313),
		// 				InstanceNo: to.Ptr("01"),
		// 				IPAddress: to.Ptr("10.0.0.5"),
		// 				KernelPatch: to.Ptr("patch 300"),
		// 				KernelVersion: to.Ptr("777"),
		// 				ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
		// 				Status: to.Ptr(armworkloads.SAPVirtualInstanceStatus("Unknown")),
		// 				VMDetails: []*armworkloads.ApplicationServerVMDetails{
		// 					{
		// 						Type: to.Ptr(armworkloads.ApplicationServerVirtualMachineTypeActive),
		// 						VirtualMachineID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Compute/virtualMachines/app01-vm"),
		// 				}},
		// 			},
		// 	}},
		// }
	}
}
Output:

type SAPApplicationServerInstancesClientBeginCreateOptions added in v0.2.0

type SAPApplicationServerInstancesClientBeginCreateOptions struct {
	// Resumes the LRO from the provided token.
	ResumeToken string
}

SAPApplicationServerInstancesClientBeginCreateOptions contains the optional parameters for the SAPApplicationServerInstancesClient.BeginCreate method.

type SAPApplicationServerInstancesClientBeginDeleteOptions added in v0.2.0

type SAPApplicationServerInstancesClientBeginDeleteOptions struct {
	// Resumes the LRO from the provided token.
	ResumeToken string
}

SAPApplicationServerInstancesClientBeginDeleteOptions contains the optional parameters for the SAPApplicationServerInstancesClient.BeginDelete method.

type SAPApplicationServerInstancesClientBeginStartInstanceOptions added in v0.3.0

type SAPApplicationServerInstancesClientBeginStartInstanceOptions struct {
	// Resumes the LRO from the provided token.
	ResumeToken string
}

SAPApplicationServerInstancesClientBeginStartInstanceOptions contains the optional parameters for the SAPApplicationServerInstancesClient.BeginStartInstance method.

type SAPApplicationServerInstancesClientBeginStopInstanceOptions added in v0.3.0

type SAPApplicationServerInstancesClientBeginStopInstanceOptions struct {
	// SAP Application server instance stop request body.
	Body *StopRequest
	// Resumes the LRO from the provided token.
	ResumeToken string
}

SAPApplicationServerInstancesClientBeginStopInstanceOptions contains the optional parameters for the SAPApplicationServerInstancesClient.BeginStopInstance method.

type SAPApplicationServerInstancesClientBeginUpdateOptions added in v0.2.0

type SAPApplicationServerInstancesClientBeginUpdateOptions struct {
	// Resumes the LRO from the provided token.
	ResumeToken string
}

SAPApplicationServerInstancesClientBeginUpdateOptions contains the optional parameters for the SAPApplicationServerInstancesClient.BeginUpdate method.

type SAPApplicationServerInstancesClientCreateResponse added in v0.2.0

type SAPApplicationServerInstancesClientCreateResponse struct {
	SAPApplicationServerInstance
}

SAPApplicationServerInstancesClientCreateResponse contains the response from method SAPApplicationServerInstancesClient.BeginCreate.

type SAPApplicationServerInstancesClientDeleteResponse added in v0.2.0

type SAPApplicationServerInstancesClientDeleteResponse struct {
	OperationStatusResult
}

SAPApplicationServerInstancesClientDeleteResponse contains the response from method SAPApplicationServerInstancesClient.BeginDelete.

type SAPApplicationServerInstancesClientGetOptions added in v0.2.0

type SAPApplicationServerInstancesClientGetOptions struct {
}

SAPApplicationServerInstancesClientGetOptions contains the optional parameters for the SAPApplicationServerInstancesClient.Get method.

type SAPApplicationServerInstancesClientGetResponse added in v0.2.0

type SAPApplicationServerInstancesClientGetResponse struct {
	SAPApplicationServerInstance
}

SAPApplicationServerInstancesClientGetResponse contains the response from method SAPApplicationServerInstancesClient.Get.

type SAPApplicationServerInstancesClientListOptions added in v0.2.0

type SAPApplicationServerInstancesClientListOptions struct {
}

SAPApplicationServerInstancesClientListOptions contains the optional parameters for the SAPApplicationServerInstancesClient.NewListPager method.

type SAPApplicationServerInstancesClientListResponse added in v0.2.0

type SAPApplicationServerInstancesClientListResponse struct {
	SAPApplicationServerInstanceList
}

SAPApplicationServerInstancesClientListResponse contains the response from method SAPApplicationServerInstancesClient.NewListPager.

type SAPApplicationServerInstancesClientStartInstanceResponse added in v0.3.0

type SAPApplicationServerInstancesClientStartInstanceResponse struct {
	OperationStatusResult
}

SAPApplicationServerInstancesClientStartInstanceResponse contains the response from method SAPApplicationServerInstancesClient.BeginStartInstance.

type SAPApplicationServerInstancesClientStopInstanceResponse added in v0.3.0

type SAPApplicationServerInstancesClientStopInstanceResponse struct {
	OperationStatusResult
}

SAPApplicationServerInstancesClientStopInstanceResponse contains the response from method SAPApplicationServerInstancesClient.BeginStopInstance.

type SAPApplicationServerInstancesClientUpdateResponse added in v0.2.0

type SAPApplicationServerInstancesClientUpdateResponse struct {
	SAPApplicationServerInstance
}

SAPApplicationServerInstancesClientUpdateResponse contains the response from method SAPApplicationServerInstancesClient.BeginUpdate.

type SAPApplicationServerProperties added in v0.2.0

type SAPApplicationServerProperties struct {
	// READ-ONLY; Defines the Application Instance errors.
	Errors *SAPVirtualInstanceError `json:"errors,omitempty" azure:"ro"`

	// READ-ONLY; Application server instance gateway Port.
	GatewayPort *int64 `json:"gatewayPort,omitempty" azure:"ro"`

	// READ-ONLY; Defines the health of SAP Instances.
	Health *SAPHealthState `json:"health,omitempty" azure:"ro"`

	// READ-ONLY; Application server instance SAP hostname.
	Hostname *string `json:"hostname,omitempty" azure:"ro"`

	// READ-ONLY; Application server instance SAP IP Address.
	IPAddress *string `json:"ipAddress,omitempty" azure:"ro"`

	// READ-ONLY; Application server instance ICM HTTP Port.
	IcmHTTPPort *int64 `json:"icmHttpPort,omitempty" azure:"ro"`

	// READ-ONLY; Application server instance ICM HTTPS Port.
	IcmHTTPSPort *int64 `json:"icmHttpsPort,omitempty" azure:"ro"`

	// READ-ONLY; Application server Instance Number.
	InstanceNo *string `json:"instanceNo,omitempty" azure:"ro"`

	// READ-ONLY; Application server instance SAP Kernel Patch level.
	KernelPatch *string `json:"kernelPatch,omitempty" azure:"ro"`

	// READ-ONLY; Application server instance SAP Kernel Version.
	KernelVersion *string `json:"kernelVersion,omitempty" azure:"ro"`

	// READ-ONLY; The Load Balancer details such as LoadBalancer ID attached to Application Server Virtual Machines
	LoadBalancerDetails *LoadBalancerDetails `json:"loadBalancerDetails,omitempty" azure:"ro"`

	// READ-ONLY; Defines the provisioning states.
	ProvisioningState *SapVirtualInstanceProvisioningState `json:"provisioningState,omitempty" azure:"ro"`

	// READ-ONLY; Defines the SAP Instance status.
	Status *SAPVirtualInstanceStatus `json:"status,omitempty" azure:"ro"`

	// READ-ONLY; Application server Subnet.
	Subnet *string `json:"subnet,omitempty" azure:"ro"`

	// READ-ONLY; The list of virtual machines.
	VMDetails []*ApplicationServerVMDetails `json:"vmDetails,omitempty" azure:"ro"`
}

SAPApplicationServerProperties - Defines the SAP Application Server instance properties.

func (SAPApplicationServerProperties) MarshalJSON added in v0.2.0

func (s SAPApplicationServerProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SAPApplicationServerProperties.

func (*SAPApplicationServerProperties) UnmarshalJSON added in v0.2.0

func (s *SAPApplicationServerProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SAPApplicationServerProperties.

type SAPAvailabilityZoneDetailsRequest added in v0.2.0

type SAPAvailabilityZoneDetailsRequest struct {
	// REQUIRED; The geo-location where the SAP resources will be created.
	AppLocation *string `json:"appLocation,omitempty"`

	// REQUIRED; The database type. Eg: HANA, DB2, etc
	DatabaseType *SAPDatabaseType `json:"databaseType,omitempty"`

	// REQUIRED; Defines the SAP Product type.
	SapProduct *SAPProductType `json:"sapProduct,omitempty"`
}

SAPAvailabilityZoneDetailsRequest - The SAP request to get list of availability zones.

func (SAPAvailabilityZoneDetailsRequest) MarshalJSON added in v0.2.0

func (s SAPAvailabilityZoneDetailsRequest) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SAPAvailabilityZoneDetailsRequest.

func (*SAPAvailabilityZoneDetailsRequest) UnmarshalJSON added in v0.2.0

func (s *SAPAvailabilityZoneDetailsRequest) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SAPAvailabilityZoneDetailsRequest.

type SAPAvailabilityZoneDetailsResult added in v0.2.0

type SAPAvailabilityZoneDetailsResult struct {
	// Gets the list of availability zone pairs.
	AvailabilityZonePairs []*SAPAvailabilityZonePair `json:"availabilityZonePairs,omitempty"`
}

SAPAvailabilityZoneDetailsResult - The list of supported availability zone pairs which are part of SAP HA deployment.

func (SAPAvailabilityZoneDetailsResult) MarshalJSON added in v0.2.0

func (s SAPAvailabilityZoneDetailsResult) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SAPAvailabilityZoneDetailsResult.

func (*SAPAvailabilityZoneDetailsResult) UnmarshalJSON added in v0.2.0

func (s *SAPAvailabilityZoneDetailsResult) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SAPAvailabilityZoneDetailsResult.

type SAPAvailabilityZonePair added in v0.2.0

type SAPAvailabilityZonePair struct {
	// The zone A.
	ZoneA *int64 `json:"zoneA,omitempty"`

	// The zone B.
	ZoneB *int64 `json:"zoneB,omitempty"`
}

SAPAvailabilityZonePair - The SAP Availability Zone Pair.

func (SAPAvailabilityZonePair) MarshalJSON added in v0.2.0

func (s SAPAvailabilityZonePair) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SAPAvailabilityZonePair.

func (*SAPAvailabilityZonePair) UnmarshalJSON added in v0.2.0

func (s *SAPAvailabilityZonePair) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SAPAvailabilityZonePair.

type SAPCentralInstanceList added in v0.2.0

type SAPCentralInstanceList struct {
	// Gets the value of next link.
	NextLink *string `json:"nextLink,omitempty"`

	// Gets the list of SAP central services instance resources.
	Value []*SAPCentralServerInstance `json:"value,omitempty"`
}

SAPCentralInstanceList - Defines the collection of SAP Central Services Instance resources.

func (SAPCentralInstanceList) MarshalJSON added in v0.2.0

func (s SAPCentralInstanceList) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SAPCentralInstanceList.

func (*SAPCentralInstanceList) UnmarshalJSON added in v0.2.0

func (s *SAPCentralInstanceList) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SAPCentralInstanceList.

type SAPCentralInstancesClient added in v0.2.0

type SAPCentralInstancesClient struct {
	// contains filtered or unexported fields
}

SAPCentralInstancesClient contains the methods for the SAPCentralInstances group. Don't use this type directly, use NewSAPCentralInstancesClient() instead.

func NewSAPCentralInstancesClient added in v0.2.0

func NewSAPCentralInstancesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*SAPCentralInstancesClient, error)

NewSAPCentralInstancesClient creates a new instance of SAPCentralInstancesClient with the specified values.

  • subscriptionID - The ID of the target subscription.
  • credential - used to authorize requests. Usually a credential from azidentity.
  • options - pass nil to accept the default values.

func (*SAPCentralInstancesClient) BeginCreate added in v0.2.0

func (client *SAPCentralInstancesClient) BeginCreate(ctx context.Context, resourceGroupName string, sapVirtualInstanceName string, centralInstanceName string, body SAPCentralServerInstance, options *SAPCentralInstancesClientBeginCreateOptions) (*runtime.Poller[SAPCentralInstancesClientCreateResponse], error)

BeginCreate - Creates the SAP Central Services Instance resource. This will be used by service only. PUT operation on this resource by end user will return a Bad Request error. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • sapVirtualInstanceName - The name of the Virtual Instances for SAP solutions resource
  • centralInstanceName - Central Services Instance resource name string modeled as parameter for auto generation to work correctly.
  • body - The SAP Central Services Instance request body.
  • options - SAPCentralInstancesClientBeginCreateOptions contains the optional parameters for the SAPCentralInstancesClient.BeginCreate method.
Example (CreateSapCentralInstancesForHaSystemWithAvailabilitySet)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPCentralInstances_Create_HA_AvSet.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPCentralInstancesClient("6d875e77-e412-4d7d-9af4-8895278b4443", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "test-rg", "X00", "centralServer", armworkloads.SAPCentralServerInstance{
		Location:   to.Ptr("westcentralus"),
		Tags:       map[string]*string{},
		Properties: &armworkloads.SAPCentralServerProperties{},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPCentralServerInstance = armworkloads.SAPCentralServerInstance{
	// 	Name: to.Ptr("centralServer"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances/centralInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00/centralInstances/centralServer"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPCentralServerProperties{
	// 		EnqueueReplicationServerProperties: &armworkloads.EnqueueReplicationServerProperties{
	// 			ErsVersion: to.Ptr(armworkloads.EnqueueReplicationServerTypeEnqueueReplicator1),
	// 			Health: to.Ptr(armworkloads.SAPHealthStateHealthy),
	// 			Hostname: to.Ptr("vh-ers1"),
	// 			InstanceNo: to.Ptr("00"),
	// 			IPAddress: to.Ptr("10.0.0.5"),
	// 			KernelPatch: to.Ptr("patch 300"),
	// 			KernelVersion: to.Ptr("777"),
	// 		},
	// 		EnqueueServerProperties: &armworkloads.EnqueueServerProperties{
	// 			Health: to.Ptr(armworkloads.SAPHealthStateHealthy),
	// 			Hostname: to.Ptr("vh-ascs1"),
	// 			IPAddress: to.Ptr("10.0.0.5"),
	// 			Port: to.Ptr[int64](3600),
	// 		},
	// 		GatewayServerProperties: &armworkloads.GatewayServerProperties{
	// 			Health: to.Ptr(armworkloads.SAPHealthStateHealthy),
	// 			Port: to.Ptr[int64](3300),
	// 		},
	// 		Health: to.Ptr(armworkloads.SAPHealthStateUnknown),
	// 		InstanceNo: to.Ptr("00"),
	// 		KernelPatch: to.Ptr("patch 300"),
	// 		KernelVersion: to.Ptr("777"),
	// 		LoadBalancerDetails: &armworkloads.LoadBalancerDetails{
	// 			ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Network/loadBalancers/cs-ASCS-loadBalancer"),
	// 		},
	// 		MessageServerProperties: &armworkloads.MessageServerProperties{
	// 			Health: to.Ptr(armworkloads.SAPHealthStateHealthy),
	// 			Hostname: to.Ptr("vh-ascs1"),
	// 			HTTPPort: to.Ptr[int64](8100),
	// 			HTTPSPort: to.Ptr[int64](44400),
	// 			InternalMsPort: to.Ptr[int64](3900),
	// 			IPAddress: to.Ptr("10.0.0.5"),
	// 			MSPort: to.Ptr[int64](3600),
	// 		},
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		Status: to.Ptr(armworkloads.SAPVirtualInstanceStatusRunning),
	// 		VMDetails: []*armworkloads.CentralServerVMDetails{
	// 			{
	// 				Type: to.Ptr(armworkloads.CentralServerVirtualMachineTypePrimary),
	// 				StorageDetails: []*armworkloads.StorageInformation{
	// 					{
	// 						ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Storage/storageAccounts/nfsstorageaccount"),
	// 				}},
	// 				VirtualMachineID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Compute/virtualMachines/cs-vm1"),
	// 			},
	// 			{
	// 				Type: to.Ptr(armworkloads.CentralServerVirtualMachineTypePrimary),
	// 				StorageDetails: []*armworkloads.StorageInformation{
	// 					{
	// 						ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Storage/storageAccounts/nfsstorageaccount"),
	// 				}},
	// 				VirtualMachineID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Compute/virtualMachines/cs-vm2"),
	// 		}},
	// 	},
	// }
}
Output:

Example (SapCentralInstancesCreate)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPCentralInstances_Create.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPCentralInstancesClient("6d875e77-e412-4d7d-9af4-8895278b4443", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "test-rg", "X00", "centralServer", armworkloads.SAPCentralServerInstance{
		Location:   to.Ptr("westcentralus"),
		Tags:       map[string]*string{},
		Properties: &armworkloads.SAPCentralServerProperties{},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPCentralServerInstance = armworkloads.SAPCentralServerInstance{
	// 	Name: to.Ptr("centralServer"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances/centralInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00/centralInstances/centralServer"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPCentralServerProperties{
	// 		EnqueueReplicationServerProperties: &armworkloads.EnqueueReplicationServerProperties{
	// 			ErsVersion: to.Ptr(armworkloads.EnqueueReplicationServerTypeEnqueueReplicator1),
	// 			Health: to.Ptr(armworkloads.SAPHealthStateHealthy),
	// 			Hostname: to.Ptr("vh-ers1"),
	// 			InstanceNo: to.Ptr("00"),
	// 			IPAddress: to.Ptr("10.0.0.5"),
	// 			KernelPatch: to.Ptr("patch 300"),
	// 			KernelVersion: to.Ptr("777"),
	// 		},
	// 		EnqueueServerProperties: &armworkloads.EnqueueServerProperties{
	// 			Health: to.Ptr(armworkloads.SAPHealthStateHealthy),
	// 			Hostname: to.Ptr("vh-ascs1"),
	// 			IPAddress: to.Ptr("10.0.0.5"),
	// 			Port: to.Ptr[int64](3600),
	// 		},
	// 		GatewayServerProperties: &armworkloads.GatewayServerProperties{
	// 			Health: to.Ptr(armworkloads.SAPHealthStateHealthy),
	// 			Port: to.Ptr[int64](3300),
	// 		},
	// 		Health: to.Ptr(armworkloads.SAPHealthStateUnknown),
	// 		InstanceNo: to.Ptr("00"),
	// 		KernelPatch: to.Ptr("patch 300"),
	// 		KernelVersion: to.Ptr("777"),
	// 		MessageServerProperties: &armworkloads.MessageServerProperties{
	// 			Health: to.Ptr(armworkloads.SAPHealthStateHealthy),
	// 			Hostname: to.Ptr("vh-ascs1"),
	// 			HTTPPort: to.Ptr[int64](8100),
	// 			HTTPSPort: to.Ptr[int64](44400),
	// 			InternalMsPort: to.Ptr[int64](3900),
	// 			IPAddress: to.Ptr("10.0.0.5"),
	// 			MSPort: to.Ptr[int64](3600),
	// 		},
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		Status: to.Ptr(armworkloads.SAPVirtualInstanceStatusRunning),
	// 		VMDetails: []*armworkloads.CentralServerVMDetails{
	// 			{
	// 				Type: to.Ptr(armworkloads.CentralServerVirtualMachineTypePrimary),
	// 				VirtualMachineID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Compute/virtualMachines/cs-vm"),
	// 		}},
	// 	},
	// }
}
Output:

func (*SAPCentralInstancesClient) BeginDelete added in v0.2.0

func (client *SAPCentralInstancesClient) BeginDelete(ctx context.Context, resourceGroupName string, sapVirtualInstanceName string, centralInstanceName string, options *SAPCentralInstancesClientBeginDeleteOptions) (*runtime.Poller[SAPCentralInstancesClientDeleteResponse], error)

BeginDelete - Deletes the SAP Central Services Instance resource. This will be used by service only. Delete operation on this resource by end user will return a Bad Request error. You can delete the parent resource, which is the Virtual Instance for SAP solutions resource, using the delete operation on it. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • sapVirtualInstanceName - The name of the Virtual Instances for SAP solutions resource
  • centralInstanceName - Central Services Instance resource name string modeled as parameter for auto generation to work correctly.
  • options - SAPCentralInstancesClientBeginDeleteOptions contains the optional parameters for the SAPCentralInstancesClient.BeginDelete method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPCentralInstances_Delete.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPCentralInstancesClient("6d875e77-e412-4d7d-9af4-8895278b4443", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginDelete(ctx, "test-rg", "X00", "centralServer", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.OperationStatusResult = armworkloads.OperationStatusResult{
	// 	Name: to.Ptr("1e4193c3-206e-4916-b124-1da16175eb0e"),
	// 	EndTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T03:38:07.000Z"); return t}()),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/operations/locations/centralus/1e4193c3-206e-4916-b124-1da16175eb0e"),
	// 	StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T03:36:07.000Z"); return t}()),
	// 	Status: to.Ptr("Succeeded"),
	// }
}
Output:

func (*SAPCentralInstancesClient) BeginStartInstance added in v0.3.0

func (client *SAPCentralInstancesClient) BeginStartInstance(ctx context.Context, resourceGroupName string, sapVirtualInstanceName string, centralInstanceName string, options *SAPCentralInstancesClientBeginStartInstanceOptions) (*runtime.Poller[SAPCentralInstancesClientStartInstanceResponse], error)

BeginStartInstance - Starts the SAP Central Services Instance. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • sapVirtualInstanceName - The name of the Virtual Instances for SAP solutions resource
  • centralInstanceName - Central Services Instance resource name string modeled as parameter for auto generation to work correctly.
  • options - SAPCentralInstancesClientBeginStartInstanceOptions contains the optional parameters for the SAPCentralInstancesClient.BeginStartInstance method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPCentralInstances_StartInstance.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPCentralInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginStartInstance(ctx, "test-rg", "X00", "centralServer", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.OperationStatusResult = armworkloads.OperationStatusResult{
	// 	Name: to.Ptr("centralServer"),
	// 	EndTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T03:38:07.000Z"); return t}()),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00/centralInstances/centralServer"),
	// 	StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T03:36:07.000Z"); return t}()),
	// 	Status: to.Ptr("Succeeded"),
	// }
}
Output:

func (*SAPCentralInstancesClient) BeginStopInstance added in v0.3.0

func (client *SAPCentralInstancesClient) BeginStopInstance(ctx context.Context, resourceGroupName string, sapVirtualInstanceName string, centralInstanceName string, options *SAPCentralInstancesClientBeginStopInstanceOptions) (*runtime.Poller[SAPCentralInstancesClientStopInstanceResponse], error)

BeginStopInstance - Stops the SAP Central Services Instance. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • sapVirtualInstanceName - The name of the Virtual Instances for SAP solutions resource
  • centralInstanceName - Central Services Instance resource name string modeled as parameter for auto generation to work correctly.
  • options - SAPCentralInstancesClientBeginStopInstanceOptions contains the optional parameters for the SAPCentralInstancesClient.BeginStopInstance method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPCentralInstances_StopInstance.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPCentralInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginStopInstance(ctx, "test-rg", "X00", "centralServer", &armworkloads.SAPCentralInstancesClientBeginStopInstanceOptions{Body: &armworkloads.StopRequest{
		SoftStopTimeoutSeconds: to.Ptr[int64](1200),
	},
	})
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.OperationStatusResult = armworkloads.OperationStatusResult{
	// 	Name: to.Ptr("centralServer"),
	// 	EndTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T03:38:07.000Z"); return t}()),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00/centralInstances/centralServer"),
	// 	StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T03:36:07.000Z"); return t}()),
	// 	Status: to.Ptr("Succeeded"),
	// }
}
Output:

func (*SAPCentralInstancesClient) BeginUpdate added in v0.2.0

func (client *SAPCentralInstancesClient) BeginUpdate(ctx context.Context, resourceGroupName string, sapVirtualInstanceName string, centralInstanceName string, body UpdateSAPCentralInstanceRequest, options *SAPCentralInstancesClientBeginUpdateOptions) (*runtime.Poller[SAPCentralInstancesClientUpdateResponse], error)

BeginUpdate - Updates the SAP Central Services Instance resource. This can be used to update tags on the resource. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • sapVirtualInstanceName - The name of the Virtual Instances for SAP solutions resource
  • centralInstanceName - Central Services Instance resource name string modeled as parameter for auto generation to work correctly.
  • body - The SAP Central Services Instance resource request body.
  • options - SAPCentralInstancesClientBeginUpdateOptions contains the optional parameters for the SAPCentralInstancesClient.BeginUpdate method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPCentralInstances_Update.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPCentralInstancesClient("6d875e77-e412-4d7d-9af4-8895278b4443", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginUpdate(ctx, "test-rg", "X00", "centralServer", armworkloads.UpdateSAPCentralInstanceRequest{
		Tags: map[string]*string{
			"tag1": to.Ptr("value1"),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPCentralServerInstance = armworkloads.SAPCentralServerInstance{
	// 	Name: to.Ptr("centralServer"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances/centralInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00/centralInstances/centralServer"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPCentralServerProperties{
	// 		EnqueueReplicationServerProperties: &armworkloads.EnqueueReplicationServerProperties{
	// 			ErsVersion: to.Ptr(armworkloads.EnqueueReplicationServerTypeEnqueueReplicator1),
	// 			Health: to.Ptr(armworkloads.SAPHealthStateHealthy),
	// 			Hostname: to.Ptr("vh-ers1"),
	// 			InstanceNo: to.Ptr("00"),
	// 			IPAddress: to.Ptr("10.0.0.5"),
	// 			KernelPatch: to.Ptr("patch 300"),
	// 			KernelVersion: to.Ptr("777"),
	// 		},
	// 		EnqueueServerProperties: &armworkloads.EnqueueServerProperties{
	// 			Health: to.Ptr(armworkloads.SAPHealthStateHealthy),
	// 			Hostname: to.Ptr("vh-ascs1"),
	// 			IPAddress: to.Ptr("10.0.0.5"),
	// 			Port: to.Ptr[int64](3600),
	// 		},
	// 		GatewayServerProperties: &armworkloads.GatewayServerProperties{
	// 			Health: to.Ptr(armworkloads.SAPHealthStateHealthy),
	// 			Port: to.Ptr[int64](3300),
	// 		},
	// 		Health: to.Ptr(armworkloads.SAPHealthStateUnknown),
	// 		InstanceNo: to.Ptr("00"),
	// 		KernelPatch: to.Ptr("patch 300"),
	// 		KernelVersion: to.Ptr("777"),
	// 		MessageServerProperties: &armworkloads.MessageServerProperties{
	// 			Health: to.Ptr(armworkloads.SAPHealthStateHealthy),
	// 			Hostname: to.Ptr("vh-ascs1"),
	// 			HTTPPort: to.Ptr[int64](8100),
	// 			HTTPSPort: to.Ptr[int64](44400),
	// 			InternalMsPort: to.Ptr[int64](3900),
	// 			IPAddress: to.Ptr("10.0.0.5"),
	// 			MSPort: to.Ptr[int64](3600),
	// 		},
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		Status: to.Ptr(armworkloads.SAPVirtualInstanceStatusRunning),
	// 		VMDetails: []*armworkloads.CentralServerVMDetails{
	// 			{
	// 				Type: to.Ptr(armworkloads.CentralServerVirtualMachineTypePrimary),
	// 				VirtualMachineID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Compute/virtualMachines/cs-vm"),
	// 		}},
	// 	},
	// }
}
Output:

func (*SAPCentralInstancesClient) Get added in v0.2.0

func (client *SAPCentralInstancesClient) Get(ctx context.Context, resourceGroupName string, sapVirtualInstanceName string, centralInstanceName string, options *SAPCentralInstancesClientGetOptions) (SAPCentralInstancesClientGetResponse, error)

Get - Gets the SAP Central Services Instance resource. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • sapVirtualInstanceName - The name of the Virtual Instances for SAP solutions resource
  • centralInstanceName - Central Services Instance resource name string modeled as parameter for auto generation to work correctly.
  • options - SAPCentralInstancesClientGetOptions contains the optional parameters for the SAPCentralInstancesClient.Get method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPCentralInstances_Get.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPCentralInstancesClient("6d875e77-e412-4d7d-9af4-8895278b4443", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := client.Get(ctx, "test-rg", "X00", "centralServer", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPCentralServerInstance = armworkloads.SAPCentralServerInstance{
	// 	Name: to.Ptr("centralServer"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances/centralInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00/centralInstances/centralServer"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPCentralServerProperties{
	// 		EnqueueReplicationServerProperties: &armworkloads.EnqueueReplicationServerProperties{
	// 			ErsVersion: to.Ptr(armworkloads.EnqueueReplicationServerTypeEnqueueReplicator1),
	// 			Health: to.Ptr(armworkloads.SAPHealthStateHealthy),
	// 			Hostname: to.Ptr("vh-ers1"),
	// 			InstanceNo: to.Ptr("00"),
	// 			IPAddress: to.Ptr("10.0.0.5"),
	// 			KernelPatch: to.Ptr("patch 300"),
	// 			KernelVersion: to.Ptr("777"),
	// 		},
	// 		EnqueueServerProperties: &armworkloads.EnqueueServerProperties{
	// 			Health: to.Ptr(armworkloads.SAPHealthStateUnknown),
	// 			Hostname: to.Ptr("vh-ascs1"),
	// 			IPAddress: to.Ptr("10.0.0.5"),
	// 			Port: to.Ptr[int64](3600),
	// 		},
	// 		GatewayServerProperties: &armworkloads.GatewayServerProperties{
	// 			Health: to.Ptr(armworkloads.SAPHealthStateDegraded),
	// 			Port: to.Ptr[int64](3300),
	// 		},
	// 		Health: to.Ptr(armworkloads.SAPHealthStateUnknown),
	// 		InstanceNo: to.Ptr("00"),
	// 		KernelPatch: to.Ptr("patch 300"),
	// 		KernelVersion: to.Ptr("777"),
	// 		MessageServerProperties: &armworkloads.MessageServerProperties{
	// 			Health: to.Ptr(armworkloads.SAPHealthStateUnhealthy),
	// 			Hostname: to.Ptr("vh-ascs1"),
	// 			HTTPPort: to.Ptr[int64](8100),
	// 			HTTPSPort: to.Ptr[int64](44400),
	// 			InternalMsPort: to.Ptr[int64](3900),
	// 			IPAddress: to.Ptr("10.0.0.5"),
	// 			MSPort: to.Ptr[int64](3600),
	// 		},
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		Status: to.Ptr(armworkloads.SAPVirtualInstanceStatusRunning),
	// 		VMDetails: []*armworkloads.CentralServerVMDetails{
	// 			{
	// 				Type: to.Ptr(armworkloads.CentralServerVirtualMachineTypePrimary),
	// 				VirtualMachineID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Compute/virtualMachines/cs-vm"),
	// 		}},
	// 	},
	// }
}
Output:

func (*SAPCentralInstancesClient) NewListPager added in v0.2.0

func (client *SAPCentralInstancesClient) NewListPager(resourceGroupName string, sapVirtualInstanceName string, options *SAPCentralInstancesClientListOptions) *runtime.Pager[SAPCentralInstancesClientListResponse]

NewListPager - Lists the SAP Central Services Instance resource for the given Virtual Instance for SAP solutions resource.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • sapVirtualInstanceName - The name of the Virtual Instances for SAP solutions resource
  • options - SAPCentralInstancesClientListOptions contains the optional parameters for the SAPCentralInstancesClient.NewListPager method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPCentralInstances_List.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPCentralInstancesClient("6d875e77-e412-4d7d-9af4-8895278b4443", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	pager := client.NewListPager("test-rg", "X00", nil)
	for pager.More() {
		page, err := pager.NextPage(ctx)
		if err != nil {
			log.Fatalf("failed to advance page: %v", err)
		}
		for _, v := range page.Value {
			// You could use page here. We use blank identifier for just demo purposes.
			_ = v
		}
		// If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
		// page.SAPCentralInstanceList = armworkloads.SAPCentralInstanceList{
		// 	Value: []*armworkloads.SAPCentralServerInstance{
		// 		{
		// 			Name: to.Ptr("centralServer"),
		// 			Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances/centralInstances"),
		// 			ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00/centralInstances/centralServer"),
		// 			SystemData: &armworkloads.SystemData{
		// 				CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
		// 				CreatedBy: to.Ptr("user@xyz.com"),
		// 				CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
		// 				LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
		// 				LastModifiedBy: to.Ptr("user@xyz.com"),
		// 				LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
		// 			},
		// 			Location: to.Ptr("westcentralus"),
		// 			Tags: map[string]*string{
		// 			},
		// 			Properties: &armworkloads.SAPCentralServerProperties{
		// 				EnqueueReplicationServerProperties: &armworkloads.EnqueueReplicationServerProperties{
		// 					ErsVersion: to.Ptr(armworkloads.EnqueueReplicationServerTypeEnqueueReplicator1),
		// 					Health: to.Ptr(armworkloads.SAPHealthStateHealthy),
		// 					Hostname: to.Ptr("vh-ers1"),
		// 					InstanceNo: to.Ptr("00"),
		// 					IPAddress: to.Ptr("10.0.0.5"),
		// 					KernelPatch: to.Ptr("patch 300"),
		// 					KernelVersion: to.Ptr("777"),
		// 				},
		// 				EnqueueServerProperties: &armworkloads.EnqueueServerProperties{
		// 					Health: to.Ptr(armworkloads.SAPHealthStateHealthy),
		// 					Hostname: to.Ptr("vh-ascs1"),
		// 					IPAddress: to.Ptr("10.0.0.5"),
		// 					Port: to.Ptr[int64](3600),
		// 				},
		// 				GatewayServerProperties: &armworkloads.GatewayServerProperties{
		// 					Health: to.Ptr(armworkloads.SAPHealthStateHealthy),
		// 					Port: to.Ptr[int64](3300),
		// 				},
		// 				Health: to.Ptr(armworkloads.SAPHealthStateUnknown),
		// 				InstanceNo: to.Ptr("00"),
		// 				KernelPatch: to.Ptr("patch 300"),
		// 				KernelVersion: to.Ptr("777"),
		// 				MessageServerProperties: &armworkloads.MessageServerProperties{
		// 					Health: to.Ptr(armworkloads.SAPHealthStateHealthy),
		// 					Hostname: to.Ptr("vh-ascs1"),
		// 					HTTPPort: to.Ptr[int64](8100),
		// 					HTTPSPort: to.Ptr[int64](44400),
		// 					InternalMsPort: to.Ptr[int64](3900),
		// 					IPAddress: to.Ptr("10.0.0.5"),
		// 					MSPort: to.Ptr[int64](3600),
		// 				},
		// 				ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
		// 				Status: to.Ptr(armworkloads.SAPVirtualInstanceStatusRunning),
		// 				VMDetails: []*armworkloads.CentralServerVMDetails{
		// 					{
		// 						Type: to.Ptr(armworkloads.CentralServerVirtualMachineTypePrimary),
		// 						VirtualMachineID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Compute/virtualMachines/cs-vm"),
		// 				}},
		// 			},
		// 	}},
		// }
	}
}
Output:

type SAPCentralInstancesClientBeginCreateOptions added in v0.2.0

type SAPCentralInstancesClientBeginCreateOptions struct {
	// Resumes the LRO from the provided token.
	ResumeToken string
}

SAPCentralInstancesClientBeginCreateOptions contains the optional parameters for the SAPCentralInstancesClient.BeginCreate method.

type SAPCentralInstancesClientBeginDeleteOptions added in v0.2.0

type SAPCentralInstancesClientBeginDeleteOptions struct {
	// Resumes the LRO from the provided token.
	ResumeToken string
}

SAPCentralInstancesClientBeginDeleteOptions contains the optional parameters for the SAPCentralInstancesClient.BeginDelete method.

type SAPCentralInstancesClientBeginStartInstanceOptions added in v0.3.0

type SAPCentralInstancesClientBeginStartInstanceOptions struct {
	// Resumes the LRO from the provided token.
	ResumeToken string
}

SAPCentralInstancesClientBeginStartInstanceOptions contains the optional parameters for the SAPCentralInstancesClient.BeginStartInstance method.

type SAPCentralInstancesClientBeginStopInstanceOptions added in v0.3.0

type SAPCentralInstancesClientBeginStopInstanceOptions struct {
	// SAP Central Services instance stop request body.
	Body *StopRequest
	// Resumes the LRO from the provided token.
	ResumeToken string
}

SAPCentralInstancesClientBeginStopInstanceOptions contains the optional parameters for the SAPCentralInstancesClient.BeginStopInstance method.

type SAPCentralInstancesClientBeginUpdateOptions added in v0.2.0

type SAPCentralInstancesClientBeginUpdateOptions struct {
	// Resumes the LRO from the provided token.
	ResumeToken string
}

SAPCentralInstancesClientBeginUpdateOptions contains the optional parameters for the SAPCentralInstancesClient.BeginUpdate method.

type SAPCentralInstancesClientCreateResponse added in v0.2.0

type SAPCentralInstancesClientCreateResponse struct {
	SAPCentralServerInstance
}

SAPCentralInstancesClientCreateResponse contains the response from method SAPCentralInstancesClient.BeginCreate.

type SAPCentralInstancesClientDeleteResponse added in v0.2.0

type SAPCentralInstancesClientDeleteResponse struct {
	OperationStatusResult
}

SAPCentralInstancesClientDeleteResponse contains the response from method SAPCentralInstancesClient.BeginDelete.

type SAPCentralInstancesClientGetOptions added in v0.2.0

type SAPCentralInstancesClientGetOptions struct {
}

SAPCentralInstancesClientGetOptions contains the optional parameters for the SAPCentralInstancesClient.Get method.

type SAPCentralInstancesClientGetResponse added in v0.2.0

type SAPCentralInstancesClientGetResponse struct {
	SAPCentralServerInstance
}

SAPCentralInstancesClientGetResponse contains the response from method SAPCentralInstancesClient.Get.

type SAPCentralInstancesClientListOptions added in v0.2.0

type SAPCentralInstancesClientListOptions struct {
}

SAPCentralInstancesClientListOptions contains the optional parameters for the SAPCentralInstancesClient.NewListPager method.

type SAPCentralInstancesClientListResponse added in v0.2.0

type SAPCentralInstancesClientListResponse struct {
	SAPCentralInstanceList
}

SAPCentralInstancesClientListResponse contains the response from method SAPCentralInstancesClient.NewListPager.

type SAPCentralInstancesClientStartInstanceResponse added in v0.3.0

type SAPCentralInstancesClientStartInstanceResponse struct {
	OperationStatusResult
}

SAPCentralInstancesClientStartInstanceResponse contains the response from method SAPCentralInstancesClient.BeginStartInstance.

type SAPCentralInstancesClientStopInstanceResponse added in v0.3.0

type SAPCentralInstancesClientStopInstanceResponse struct {
	OperationStatusResult
}

SAPCentralInstancesClientStopInstanceResponse contains the response from method SAPCentralInstancesClient.BeginStopInstance.

type SAPCentralInstancesClientUpdateResponse added in v0.2.0

type SAPCentralInstancesClientUpdateResponse struct {
	SAPCentralServerInstance
}

SAPCentralInstancesClientUpdateResponse contains the response from method SAPCentralInstancesClient.BeginUpdate.

type SAPCentralServerInstance added in v0.2.0

type SAPCentralServerInstance struct {
	// REQUIRED; The geo-location where the resource lives
	Location *string `json:"location,omitempty"`

	// Defines the SAP Central Services Instance properties.
	Properties *SAPCentralServerProperties `json:"properties,omitempty"`

	// Resource tags.
	Tags map[string]*string `json:"tags,omitempty"`

	// READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
	ID *string `json:"id,omitempty" azure:"ro"`

	// READ-ONLY; The name of the resource
	Name *string `json:"name,omitempty" azure:"ro"`

	// READ-ONLY; Azure Resource Manager metadata containing createdBy and modifiedBy information.
	SystemData *SystemData `json:"systemData,omitempty" azure:"ro"`

	// READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
	Type *string `json:"type,omitempty" azure:"ro"`
}

SAPCentralServerInstance - Define the SAP Central Services Instance resource.

func (SAPCentralServerInstance) MarshalJSON added in v0.2.0

func (s SAPCentralServerInstance) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SAPCentralServerInstance.

func (*SAPCentralServerInstance) UnmarshalJSON added in v0.2.0

func (s *SAPCentralServerInstance) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SAPCentralServerInstance.

type SAPCentralServerProperties added in v0.2.0

type SAPCentralServerProperties struct {
	// Defines the SAP Enqueue Replication Server (ERS) properties.
	EnqueueReplicationServerProperties *EnqueueReplicationServerProperties `json:"enqueueReplicationServerProperties,omitempty"`

	// Defines the SAP Enqueue Server properties.
	EnqueueServerProperties *EnqueueServerProperties `json:"enqueueServerProperties,omitempty"`

	// Defines the SAP Gateway Server properties.
	GatewayServerProperties *GatewayServerProperties `json:"gatewayServerProperties,omitempty"`

	// Defines the SAP Message Server properties.
	MessageServerProperties *MessageServerProperties `json:"messageServerProperties,omitempty"`

	// READ-ONLY; Defines the errors related to SAP Central Services Instance resource.
	Errors *SAPVirtualInstanceError `json:"errors,omitempty" azure:"ro"`

	// READ-ONLY; Defines the health of SAP Instances.
	Health *SAPHealthState `json:"health,omitempty" azure:"ro"`

	// READ-ONLY; The central services instance number.
	InstanceNo *string `json:"instanceNo,omitempty" azure:"ro"`

	// READ-ONLY; The central services instance Kernel Patch level.
	KernelPatch *string `json:"kernelPatch,omitempty" azure:"ro"`

	// READ-ONLY; The central services instance Kernel Version.
	KernelVersion *string `json:"kernelVersion,omitempty" azure:"ro"`

	// READ-ONLY; The Load Balancer details such as LoadBalancer ID attached to ASCS Virtual Machines
	LoadBalancerDetails *LoadBalancerDetails `json:"loadBalancerDetails,omitempty" azure:"ro"`

	// READ-ONLY; Defines the provisioning states.
	ProvisioningState *SapVirtualInstanceProvisioningState `json:"provisioningState,omitempty" azure:"ro"`

	// READ-ONLY; Defines the SAP Instance status.
	Status *SAPVirtualInstanceStatus `json:"status,omitempty" azure:"ro"`

	// READ-ONLY; The central services instance subnet.
	Subnet *string `json:"subnet,omitempty" azure:"ro"`

	// READ-ONLY; The list of virtual machines corresponding to the Central Services instance.
	VMDetails []*CentralServerVMDetails `json:"vmDetails,omitempty" azure:"ro"`
}

SAPCentralServerProperties - Defines the SAP Central Services Instance properties.

func (SAPCentralServerProperties) MarshalJSON added in v0.2.0

func (s SAPCentralServerProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SAPCentralServerProperties.

func (*SAPCentralServerProperties) UnmarshalJSON added in v0.2.0

func (s *SAPCentralServerProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SAPCentralServerProperties.

type SAPConfiguration added in v0.2.0

type SAPConfiguration struct {
	// REQUIRED; The configuration Type.
	ConfigurationType *SAPConfigurationType `json:"configurationType,omitempty"`
}

SAPConfiguration - The SAP Configuration.

func (*SAPConfiguration) GetSAPConfiguration added in v0.2.0

func (s *SAPConfiguration) GetSAPConfiguration() *SAPConfiguration

GetSAPConfiguration implements the SAPConfigurationClassification interface for type SAPConfiguration.

func (SAPConfiguration) MarshalJSON added in v0.2.0

func (s SAPConfiguration) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SAPConfiguration.

func (*SAPConfiguration) UnmarshalJSON added in v0.2.0

func (s *SAPConfiguration) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SAPConfiguration.

type SAPConfigurationClassification added in v0.2.0

type SAPConfigurationClassification interface {
	// GetSAPConfiguration returns the SAPConfiguration content of the underlying type.
	GetSAPConfiguration() *SAPConfiguration
}

SAPConfigurationClassification provides polymorphic access to related types. Call the interface's GetSAPConfiguration() method to access the common type. Use a type switch to determine the concrete type. The possible types are: - *DeploymentConfiguration, *DeploymentWithOSConfiguration, *DiscoveryConfiguration, *SAPConfiguration

type SAPConfigurationType added in v0.2.0

type SAPConfigurationType string

SAPConfigurationType - The configuration Type.

const (
	SAPConfigurationTypeDeployment             SAPConfigurationType = "Deployment"
	SAPConfigurationTypeDeploymentWithOSConfig SAPConfigurationType = "DeploymentWithOSConfig"
	SAPConfigurationTypeDiscovery              SAPConfigurationType = "Discovery"
)

func PossibleSAPConfigurationTypeValues added in v0.2.0

func PossibleSAPConfigurationTypeValues() []SAPConfigurationType

PossibleSAPConfigurationTypeValues returns the possible values for the SAPConfigurationType const type.

type SAPDatabaseInstance added in v0.2.0

type SAPDatabaseInstance struct {
	// REQUIRED; The geo-location where the resource lives
	Location *string `json:"location,omitempty"`

	// Defines the Database properties.
	Properties *SAPDatabaseProperties `json:"properties,omitempty"`

	// Resource tags.
	Tags map[string]*string `json:"tags,omitempty"`

	// READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
	ID *string `json:"id,omitempty" azure:"ro"`

	// READ-ONLY; The name of the resource
	Name *string `json:"name,omitempty" azure:"ro"`

	// READ-ONLY; Azure Resource Manager metadata containing createdBy and modifiedBy information.
	SystemData *SystemData `json:"systemData,omitempty" azure:"ro"`

	// READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
	Type *string `json:"type,omitempty" azure:"ro"`
}

SAPDatabaseInstance - Define the Database resource.

func (SAPDatabaseInstance) MarshalJSON added in v0.2.0

func (s SAPDatabaseInstance) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SAPDatabaseInstance.

func (*SAPDatabaseInstance) UnmarshalJSON added in v0.2.0

func (s *SAPDatabaseInstance) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SAPDatabaseInstance.

type SAPDatabaseInstanceList added in v0.2.0

type SAPDatabaseInstanceList struct {
	// Gets the value of next link.
	NextLink *string `json:"nextLink,omitempty"`

	// Gets the list of SAP Database instances.
	Value []*SAPDatabaseInstance `json:"value,omitempty"`
}

SAPDatabaseInstanceList - Defines the collection of SAP Database Instances.

func (SAPDatabaseInstanceList) MarshalJSON added in v0.2.0

func (s SAPDatabaseInstanceList) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SAPDatabaseInstanceList.

func (*SAPDatabaseInstanceList) UnmarshalJSON added in v0.2.0

func (s *SAPDatabaseInstanceList) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SAPDatabaseInstanceList.

type SAPDatabaseInstancesClient added in v0.2.0

type SAPDatabaseInstancesClient struct {
	// contains filtered or unexported fields
}

SAPDatabaseInstancesClient contains the methods for the SAPDatabaseInstances group. Don't use this type directly, use NewSAPDatabaseInstancesClient() instead.

func NewSAPDatabaseInstancesClient added in v0.2.0

func NewSAPDatabaseInstancesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*SAPDatabaseInstancesClient, error)

NewSAPDatabaseInstancesClient creates a new instance of SAPDatabaseInstancesClient with the specified values.

  • subscriptionID - The ID of the target subscription.
  • credential - used to authorize requests. Usually a credential from azidentity.
  • options - pass nil to accept the default values.

func (*SAPDatabaseInstancesClient) BeginCreate added in v0.2.0

func (client *SAPDatabaseInstancesClient) BeginCreate(ctx context.Context, resourceGroupName string, sapVirtualInstanceName string, databaseInstanceName string, body SAPDatabaseInstance, options *SAPDatabaseInstancesClientBeginCreateOptions) (*runtime.Poller[SAPDatabaseInstancesClientCreateResponse], error)

BeginCreate - Creates the Database resource corresponding to the Virtual Instance for SAP solutions resource. This will be used by service only. PUT by end user will return a Bad Request error. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • sapVirtualInstanceName - The name of the Virtual Instances for SAP solutions resource
  • databaseInstanceName - Database resource name string modeled as parameter for auto generation to work correctly.
  • body - Request body of Database resource of a SAP system.
  • options - SAPDatabaseInstancesClientBeginCreateOptions contains the optional parameters for the SAPDatabaseInstancesClient.BeginCreate method.
Example (CreateSapDatabaseInstancesForHaSystemWithAvailabilitySet)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPDatabaseInstances_Create_HA_AvSet.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPDatabaseInstancesClient("6d875e77-e412-4d7d-9af4-8895278b4443", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "test-rg", "X00", "databaseServer", armworkloads.SAPDatabaseInstance{
		Location:   to.Ptr("westcentralus"),
		Tags:       map[string]*string{},
		Properties: &armworkloads.SAPDatabaseProperties{},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPDatabaseInstance = armworkloads.SAPDatabaseInstance{
	// 	Name: to.Ptr("databaseServer"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances/databaseInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00/databaseInstances/databaseServer"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPDatabaseProperties{
	// 		DatabaseSid: to.Ptr("X00"),
	// 		DatabaseType: to.Ptr("hdb"),
	// 		IPAddress: to.Ptr("10.0.0.5"),
	// 		LoadBalancerDetails: &armworkloads.LoadBalancerDetails{
	// 			ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Network/loadBalancers/db-loadBalancer"),
	// 		},
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		Status: to.Ptr(armworkloads.SAPVirtualInstanceStatusRunning),
	// 		Subnet: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1"),
	// 		VMDetails: []*armworkloads.DatabaseVMDetails{
	// 			{
	// 				StorageDetails: []*armworkloads.StorageInformation{
	// 					{
	// 						ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Storage/storageAccounts/nfsstorageaccount"),
	// 				}},
	// 				VirtualMachineID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Compute/virtualMachines/db-vm"),
	// 		}},
	// 	},
	// }
}
Output:

Example (SapDatabaseInstancesCreate)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPDatabaseInstances_Create.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPDatabaseInstancesClient("6d875e77-e412-4d7d-9af4-8895278b4443", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "test-rg", "X00", "databaseServer", armworkloads.SAPDatabaseInstance{
		Location:   to.Ptr("westcentralus"),
		Tags:       map[string]*string{},
		Properties: &armworkloads.SAPDatabaseProperties{},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPDatabaseInstance = armworkloads.SAPDatabaseInstance{
	// 	Name: to.Ptr("databaseServer"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances/databaseInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00/databaseInstances/databaseServer"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPDatabaseProperties{
	// 		DatabaseSid: to.Ptr("X00"),
	// 		DatabaseType: to.Ptr("hdb"),
	// 		IPAddress: to.Ptr("10.0.0.5"),
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		Status: to.Ptr(armworkloads.SAPVirtualInstanceStatusRunning),
	// 		Subnet: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1"),
	// 		VMDetails: []*armworkloads.DatabaseVMDetails{
	// 			{
	// 				VirtualMachineID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Compute/virtualMachines/db-vm"),
	// 		}},
	// 	},
	// }
}
Output:

func (*SAPDatabaseInstancesClient) BeginDelete added in v0.2.0

func (client *SAPDatabaseInstancesClient) BeginDelete(ctx context.Context, resourceGroupName string, sapVirtualInstanceName string, databaseInstanceName string, options *SAPDatabaseInstancesClientBeginDeleteOptions) (*runtime.Poller[SAPDatabaseInstancesClientDeleteResponse], error)

BeginDelete - Deletes the Database resource corresponding to a Virtual Instance for SAP solutions resource. This will be used by service only. Delete by end user will return a Bad Request error. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • sapVirtualInstanceName - The name of the Virtual Instances for SAP solutions resource
  • databaseInstanceName - Database resource name string modeled as parameter for auto generation to work correctly.
  • options - SAPDatabaseInstancesClientBeginDeleteOptions contains the optional parameters for the SAPDatabaseInstancesClient.BeginDelete method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPDatabaseInstances_Delete.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPDatabaseInstancesClient("6d875e77-e412-4d7d-9af4-8895278b4443", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginDelete(ctx, "test-rg", "X00", "databaseServer", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.OperationStatusResult = armworkloads.OperationStatusResult{
	// 	Name: to.Ptr("1e4193c3-206e-4916-b124-1da16175eb0e"),
	// 	EndTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T03:38:07.000Z"); return t}()),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/operations/locations/centralus/1e4193c3-206e-4916-b124-1da16175eb0e"),
	// 	StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T03:36:07.000Z"); return t}()),
	// 	Status: to.Ptr("Succeeded"),
	// }
}
Output:

func (*SAPDatabaseInstancesClient) BeginStartInstance added in v0.3.0

func (client *SAPDatabaseInstancesClient) BeginStartInstance(ctx context.Context, resourceGroupName string, sapVirtualInstanceName string, databaseInstanceName string, options *SAPDatabaseInstancesClientBeginStartInstanceOptions) (*runtime.Poller[SAPDatabaseInstancesClientStartInstanceResponse], error)

BeginStartInstance - Starts the database instance of the SAP system. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • sapVirtualInstanceName - The name of the Virtual Instances for SAP solutions resource
  • databaseInstanceName - Database resource name string modeled as parameter for auto generation to work correctly.
  • options - SAPDatabaseInstancesClientBeginStartInstanceOptions contains the optional parameters for the SAPDatabaseInstancesClient.BeginStartInstance method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPDatabaseInstances_StartInstance.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPDatabaseInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginStartInstance(ctx, "test-rg", "X00", "db0", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.OperationStatusResult = armworkloads.OperationStatusResult{
	// 	Name: to.Ptr("db0"),
	// 	EndTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2022-11-01T03:38:07.000Z"); return t}()),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00/applicationInstances/db0"),
	// 	StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2022-11-01T03:36:07.000Z"); return t}()),
	// 	Status: to.Ptr("Succeeded"),
	// }
}
Output:

func (*SAPDatabaseInstancesClient) BeginStopInstance added in v0.3.0

func (client *SAPDatabaseInstancesClient) BeginStopInstance(ctx context.Context, resourceGroupName string, sapVirtualInstanceName string, databaseInstanceName string, options *SAPDatabaseInstancesClientBeginStopInstanceOptions) (*runtime.Poller[SAPDatabaseInstancesClientStopInstanceResponse], error)

BeginStopInstance - Stops the database instance of the SAP system. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • sapVirtualInstanceName - The name of the Virtual Instances for SAP solutions resource
  • databaseInstanceName - Database resource name string modeled as parameter for auto generation to work correctly.
  • options - SAPDatabaseInstancesClientBeginStopInstanceOptions contains the optional parameters for the SAPDatabaseInstancesClient.BeginStopInstance method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPDatabaseInstances_StopInstance.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPDatabaseInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginStopInstance(ctx, "test-rg", "X00", "db0", &armworkloads.SAPDatabaseInstancesClientBeginStopInstanceOptions{Body: &armworkloads.StopRequest{
		SoftStopTimeoutSeconds: to.Ptr[int64](0),
	},
	})
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.OperationStatusResult = armworkloads.OperationStatusResult{
	// 	Name: to.Ptr("db0"),
	// 	EndTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2022-11-01T03:38:07.000Z"); return t}()),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00/applicationInstances/db0"),
	// 	StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2022-11-01T03:36:07.000Z"); return t}()),
	// 	Status: to.Ptr("Succeeded"),
	// }
}
Output:

func (*SAPDatabaseInstancesClient) BeginUpdate added in v0.2.0

func (client *SAPDatabaseInstancesClient) BeginUpdate(ctx context.Context, resourceGroupName string, sapVirtualInstanceName string, databaseInstanceName string, body UpdateSAPDatabaseInstanceRequest, options *SAPDatabaseInstancesClientBeginUpdateOptions) (*runtime.Poller[SAPDatabaseInstancesClientUpdateResponse], error)

BeginUpdate - Updates the Database resource. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • sapVirtualInstanceName - The name of the Virtual Instances for SAP solutions resource
  • databaseInstanceName - Database resource name string modeled as parameter for auto generation to work correctly.
  • body - Database resource update request body.
  • options - SAPDatabaseInstancesClientBeginUpdateOptions contains the optional parameters for the SAPDatabaseInstancesClient.BeginUpdate method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPDatabaseInstances_Update.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPDatabaseInstancesClient("6d875e77-e412-4d7d-9af4-8895278b4443", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginUpdate(ctx, "test-rg", "X00", "databaseServer", armworkloads.UpdateSAPDatabaseInstanceRequest{
		Tags: map[string]*string{
			"key1": to.Ptr("value1"),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPDatabaseInstance = armworkloads.SAPDatabaseInstance{
	// 	Name: to.Ptr("databaseServer"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances/databaseInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00/databaseInstances/databaseServer"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPDatabaseProperties{
	// 		DatabaseSid: to.Ptr("X00"),
	// 		DatabaseType: to.Ptr("hdb"),
	// 		IPAddress: to.Ptr("10.0.0.5"),
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		Status: to.Ptr(armworkloads.SAPVirtualInstanceStatusRunning),
	// 		Subnet: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1"),
	// 		VMDetails: []*armworkloads.DatabaseVMDetails{
	// 			{
	// 				VirtualMachineID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Compute/virtualMachines/db-vm"),
	// 		}},
	// 	},
	// }
}
Output:

func (*SAPDatabaseInstancesClient) Get added in v0.2.0

func (client *SAPDatabaseInstancesClient) Get(ctx context.Context, resourceGroupName string, sapVirtualInstanceName string, databaseInstanceName string, options *SAPDatabaseInstancesClientGetOptions) (SAPDatabaseInstancesClientGetResponse, error)

Get - Gets the SAP Database Instance resource. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • sapVirtualInstanceName - The name of the Virtual Instances for SAP solutions resource
  • databaseInstanceName - Database resource name string modeled as parameter for auto generation to work correctly.
  • options - SAPDatabaseInstancesClientGetOptions contains the optional parameters for the SAPDatabaseInstancesClient.Get method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPDatabaseInstances_Get.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPDatabaseInstancesClient("6d875e77-e412-4d7d-9af4-8895278b4443", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := client.Get(ctx, "test-rg", "X00", "databaseServer", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPDatabaseInstance = armworkloads.SAPDatabaseInstance{
	// 	Name: to.Ptr("databaseServer"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances/databaseInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00/databaseInstances/databaseServer"),
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPDatabaseProperties{
	// 		DatabaseSid: to.Ptr("X00"),
	// 		DatabaseType: to.Ptr("hdb"),
	// 		IPAddress: to.Ptr("10.0.0.5"),
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		Status: to.Ptr(armworkloads.SAPVirtualInstanceStatusRunning),
	// 		Subnet: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1"),
	// 		VMDetails: []*armworkloads.DatabaseVMDetails{
	// 			{
	// 				VirtualMachineID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Compute/virtualMachines/db-vm"),
	// 		}},
	// 	},
	// }
}
Output:

func (*SAPDatabaseInstancesClient) NewListPager added in v0.2.0

func (client *SAPDatabaseInstancesClient) NewListPager(resourceGroupName string, sapVirtualInstanceName string, options *SAPDatabaseInstancesClientListOptions) *runtime.Pager[SAPDatabaseInstancesClientListResponse]

NewListPager - Lists the Database resources associated with a Virtual Instance for SAP solutions resource.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • sapVirtualInstanceName - The name of the Virtual Instances for SAP solutions resource
  • options - SAPDatabaseInstancesClientListOptions contains the optional parameters for the SAPDatabaseInstancesClient.NewListPager method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPDatabaseInstances_List.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPDatabaseInstancesClient("6d875e77-e412-4d7d-9af4-8895278b4443", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	pager := client.NewListPager("test-rg", "X00", nil)
	for pager.More() {
		page, err := pager.NextPage(ctx)
		if err != nil {
			log.Fatalf("failed to advance page: %v", err)
		}
		for _, v := range page.Value {
			// You could use page here. We use blank identifier for just demo purposes.
			_ = v
		}
		// If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
		// page.SAPDatabaseInstanceList = armworkloads.SAPDatabaseInstanceList{
		// 	Value: []*armworkloads.SAPDatabaseInstance{
		// 		{
		// 			Name: to.Ptr("databaseServer"),
		// 			Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances/databaseInstances"),
		// 			ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00/databaseInstances/databaseServer"),
		// 			SystemData: &armworkloads.SystemData{
		// 				CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
		// 				CreatedBy: to.Ptr("user@xyz.com"),
		// 				CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
		// 				LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
		// 				LastModifiedBy: to.Ptr("user@xyz.com"),
		// 				LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
		// 			},
		// 			Location: to.Ptr("westcentralus"),
		// 			Tags: map[string]*string{
		// 			},
		// 			Properties: &armworkloads.SAPDatabaseProperties{
		// 				DatabaseSid: to.Ptr("X00"),
		// 				DatabaseType: to.Ptr("hdb"),
		// 				IPAddress: to.Ptr("10.0.0.5"),
		// 				ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
		// 				Status: to.Ptr(armworkloads.SAPVirtualInstanceStatusRunning),
		// 				Subnet: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1"),
		// 				VMDetails: []*armworkloads.DatabaseVMDetails{
		// 					{
		// 						VirtualMachineID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Compute/virtualMachines/db-vm"),
		// 				}},
		// 			},
		// 	}},
		// }
	}
}
Output:

type SAPDatabaseInstancesClientBeginCreateOptions added in v0.2.0

type SAPDatabaseInstancesClientBeginCreateOptions struct {
	// Resumes the LRO from the provided token.
	ResumeToken string
}

SAPDatabaseInstancesClientBeginCreateOptions contains the optional parameters for the SAPDatabaseInstancesClient.BeginCreate method.

type SAPDatabaseInstancesClientBeginDeleteOptions added in v0.2.0

type SAPDatabaseInstancesClientBeginDeleteOptions struct {
	// Resumes the LRO from the provided token.
	ResumeToken string
}

SAPDatabaseInstancesClientBeginDeleteOptions contains the optional parameters for the SAPDatabaseInstancesClient.BeginDelete method.

type SAPDatabaseInstancesClientBeginStartInstanceOptions added in v0.3.0

type SAPDatabaseInstancesClientBeginStartInstanceOptions struct {
	// Resumes the LRO from the provided token.
	ResumeToken string
}

SAPDatabaseInstancesClientBeginStartInstanceOptions contains the optional parameters for the SAPDatabaseInstancesClient.BeginStartInstance method.

type SAPDatabaseInstancesClientBeginStopInstanceOptions added in v0.3.0

type SAPDatabaseInstancesClientBeginStopInstanceOptions struct {
	// Stop request for the database instance of the SAP system.
	Body *StopRequest
	// Resumes the LRO from the provided token.
	ResumeToken string
}

SAPDatabaseInstancesClientBeginStopInstanceOptions contains the optional parameters for the SAPDatabaseInstancesClient.BeginStopInstance method.

type SAPDatabaseInstancesClientBeginUpdateOptions added in v0.2.0

type SAPDatabaseInstancesClientBeginUpdateOptions struct {
	// Resumes the LRO from the provided token.
	ResumeToken string
}

SAPDatabaseInstancesClientBeginUpdateOptions contains the optional parameters for the SAPDatabaseInstancesClient.BeginUpdate method.

type SAPDatabaseInstancesClientCreateResponse added in v0.2.0

type SAPDatabaseInstancesClientCreateResponse struct {
	SAPDatabaseInstance
}

SAPDatabaseInstancesClientCreateResponse contains the response from method SAPDatabaseInstancesClient.BeginCreate.

type SAPDatabaseInstancesClientDeleteResponse added in v0.2.0

type SAPDatabaseInstancesClientDeleteResponse struct {
	OperationStatusResult
}

SAPDatabaseInstancesClientDeleteResponse contains the response from method SAPDatabaseInstancesClient.BeginDelete.

type SAPDatabaseInstancesClientGetOptions added in v0.2.0

type SAPDatabaseInstancesClientGetOptions struct {
}

SAPDatabaseInstancesClientGetOptions contains the optional parameters for the SAPDatabaseInstancesClient.Get method.

type SAPDatabaseInstancesClientGetResponse added in v0.2.0

type SAPDatabaseInstancesClientGetResponse struct {
	SAPDatabaseInstance
}

SAPDatabaseInstancesClientGetResponse contains the response from method SAPDatabaseInstancesClient.Get.

type SAPDatabaseInstancesClientListOptions added in v0.2.0

type SAPDatabaseInstancesClientListOptions struct {
}

SAPDatabaseInstancesClientListOptions contains the optional parameters for the SAPDatabaseInstancesClient.NewListPager method.

type SAPDatabaseInstancesClientListResponse added in v0.2.0

type SAPDatabaseInstancesClientListResponse struct {
	SAPDatabaseInstanceList
}

SAPDatabaseInstancesClientListResponse contains the response from method SAPDatabaseInstancesClient.NewListPager.

type SAPDatabaseInstancesClientStartInstanceResponse added in v0.3.0

type SAPDatabaseInstancesClientStartInstanceResponse struct {
	OperationStatusResult
}

SAPDatabaseInstancesClientStartInstanceResponse contains the response from method SAPDatabaseInstancesClient.BeginStartInstance.

type SAPDatabaseInstancesClientStopInstanceResponse added in v0.3.0

type SAPDatabaseInstancesClientStopInstanceResponse struct {
	OperationStatusResult
}

SAPDatabaseInstancesClientStopInstanceResponse contains the response from method SAPDatabaseInstancesClient.BeginStopInstance.

type SAPDatabaseInstancesClientUpdateResponse added in v0.2.0

type SAPDatabaseInstancesClientUpdateResponse struct {
	SAPDatabaseInstance
}

SAPDatabaseInstancesClientUpdateResponse contains the response from method SAPDatabaseInstancesClient.BeginUpdate.

type SAPDatabaseProperties added in v0.2.0

type SAPDatabaseProperties struct {
	// READ-ONLY; Database SID name.
	DatabaseSid *string `json:"databaseSid,omitempty" azure:"ro"`

	// READ-ONLY; Database type, that is if the DB is HANA, DB2, Oracle, SAP ASE, Max DB or MS SQL Server.
	DatabaseType *string `json:"databaseType,omitempty" azure:"ro"`

	// READ-ONLY; Defines the errors related to Database resource.
	Errors *SAPVirtualInstanceError `json:"errors,omitempty" azure:"ro"`

	// READ-ONLY; Database IP Address.
	IPAddress *string `json:"ipAddress,omitempty" azure:"ro"`

	// READ-ONLY; The Load Balancer details such as LoadBalancer ID attached to Database Virtual Machines
	LoadBalancerDetails *LoadBalancerDetails `json:"loadBalancerDetails,omitempty" azure:"ro"`

	// READ-ONLY; Defines the provisioning states.
	ProvisioningState *SapVirtualInstanceProvisioningState `json:"provisioningState,omitempty" azure:"ro"`

	// READ-ONLY; Defines the SAP Instance status.
	Status *SAPVirtualInstanceStatus `json:"status,omitempty" azure:"ro"`

	// READ-ONLY; Database subnet.
	Subnet *string `json:"subnet,omitempty" azure:"ro"`

	// READ-ONLY; The list of virtual machines corresponding to the Database resource.
	VMDetails []*DatabaseVMDetails `json:"vmDetails,omitempty" azure:"ro"`
}

SAPDatabaseProperties - Defines the Database properties.

func (SAPDatabaseProperties) MarshalJSON added in v0.2.0

func (s SAPDatabaseProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SAPDatabaseProperties.

func (*SAPDatabaseProperties) UnmarshalJSON added in v0.2.0

func (s *SAPDatabaseProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SAPDatabaseProperties.

type SAPDatabaseScaleMethod added in v0.2.0

type SAPDatabaseScaleMethod string

SAPDatabaseScaleMethod - The database scale method.

const (
	SAPDatabaseScaleMethodScaleUp SAPDatabaseScaleMethod = "ScaleUp"
)

func PossibleSAPDatabaseScaleMethodValues added in v0.2.0

func PossibleSAPDatabaseScaleMethodValues() []SAPDatabaseScaleMethod

PossibleSAPDatabaseScaleMethodValues returns the possible values for the SAPDatabaseScaleMethod const type.

type SAPDatabaseType added in v0.2.0

type SAPDatabaseType string

SAPDatabaseType - Defines the supported SAP Database types.

const (
	SAPDatabaseTypeDB2  SAPDatabaseType = "DB2"
	SAPDatabaseTypeHANA SAPDatabaseType = "HANA"
)

func PossibleSAPDatabaseTypeValues added in v0.2.0

func PossibleSAPDatabaseTypeValues() []SAPDatabaseType

PossibleSAPDatabaseTypeValues returns the possible values for the SAPDatabaseType const type.

type SAPDeploymentType added in v0.2.0

type SAPDeploymentType string

SAPDeploymentType - The type of SAP deployment, single server or Three tier.

const (
	SAPDeploymentTypeSingleServer SAPDeploymentType = "SingleServer"
	SAPDeploymentTypeThreeTier    SAPDeploymentType = "ThreeTier"
)

func PossibleSAPDeploymentTypeValues added in v0.2.0

func PossibleSAPDeploymentTypeValues() []SAPDeploymentType

PossibleSAPDeploymentTypeValues returns the possible values for the SAPDeploymentType const type.

type SAPDiskConfiguration added in v0.2.0

type SAPDiskConfiguration struct {
	// The recommended disk details for a given VM Sku.
	RecommendedConfiguration *DiskVolumeConfiguration `json:"recommendedConfiguration,omitempty"`

	// The list of supported disks for a given VM Sku.
	SupportedConfigurations []*DiskDetails `json:"supportedConfigurations,omitempty"`
}

SAPDiskConfiguration - The SAP Disk Configuration contains 'recommended disk' details and list of supported disks detail for a volume type.

func (SAPDiskConfiguration) MarshalJSON added in v0.2.0

func (s SAPDiskConfiguration) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SAPDiskConfiguration.

func (*SAPDiskConfiguration) UnmarshalJSON added in v0.2.0

func (s *SAPDiskConfiguration) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SAPDiskConfiguration.

type SAPDiskConfigurationsRequest added in v0.2.0

type SAPDiskConfigurationsRequest struct {
	// REQUIRED; The geo-location where the SAP resources will be created.
	AppLocation *string `json:"appLocation,omitempty"`

	// REQUIRED; The database type. Eg: HANA, DB2, etc
	DatabaseType *SAPDatabaseType `json:"databaseType,omitempty"`

	// REQUIRED; The VM SKU for database instance.
	DbVMSKU *string `json:"dbVmSku,omitempty"`

	// REQUIRED; The deployment type. Eg: SingleServer/ThreeTier
	DeploymentType *SAPDeploymentType `json:"deploymentType,omitempty"`

	// REQUIRED; Defines the environment type - Production/Non Production.
	Environment *SAPEnvironmentType `json:"environment,omitempty"`

	// REQUIRED; Defines the SAP Product type.
	SapProduct *SAPProductType `json:"sapProduct,omitempty"`
}

SAPDiskConfigurationsRequest - The SAP request to get list of disk configurations.

func (SAPDiskConfigurationsRequest) MarshalJSON added in v0.2.0

func (s SAPDiskConfigurationsRequest) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SAPDiskConfigurationsRequest.

func (*SAPDiskConfigurationsRequest) UnmarshalJSON added in v0.2.0

func (s *SAPDiskConfigurationsRequest) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SAPDiskConfigurationsRequest.

type SAPDiskConfigurationsResult added in v0.2.0

type SAPDiskConfigurationsResult struct {
	// The disk configuration for the db volume. For HANA, Required volumes are: ['hana/data', 'hana/log', hana/shared', 'usr/sap',
	// 'os'], Optional volume : ['backup'].
	VolumeConfigurations map[string]*SAPDiskConfiguration `json:"volumeConfigurations,omitempty"`
}

SAPDiskConfigurationsResult - The list of disk configuration for vmSku which are part of SAP deployment.

func (SAPDiskConfigurationsResult) MarshalJSON added in v0.2.0

func (s SAPDiskConfigurationsResult) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SAPDiskConfigurationsResult.

func (*SAPDiskConfigurationsResult) UnmarshalJSON added in v0.2.0

func (s *SAPDiskConfigurationsResult) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SAPDiskConfigurationsResult.

type SAPEnvironmentType added in v0.2.0

type SAPEnvironmentType string

SAPEnvironmentType - Defines the environment type - Production/Non Production.

const (
	SAPEnvironmentTypeNonProd SAPEnvironmentType = "NonProd"
	SAPEnvironmentTypeProd    SAPEnvironmentType = "Prod"
)

func PossibleSAPEnvironmentTypeValues added in v0.2.0

func PossibleSAPEnvironmentTypeValues() []SAPEnvironmentType

PossibleSAPEnvironmentTypeValues returns the possible values for the SAPEnvironmentType const type.

type SAPHealthState added in v0.2.0

type SAPHealthState string

SAPHealthState - Defines the health of SAP Instances.

const (
	SAPHealthStateDegraded  SAPHealthState = "Degraded"
	SAPHealthStateHealthy   SAPHealthState = "Healthy"
	SAPHealthStateUnhealthy SAPHealthState = "Unhealthy"
	SAPHealthStateUnknown   SAPHealthState = "Unknown"
)

func PossibleSAPHealthStateValues added in v0.2.0

func PossibleSAPHealthStateValues() []SAPHealthState

PossibleSAPHealthStateValues returns the possible values for the SAPHealthState const type.

type SAPHighAvailabilityType added in v0.2.0

type SAPHighAvailabilityType string

SAPHighAvailabilityType - The high availability Type. AvailabilitySet guarantees 99.95% availability. Availability Zone guarantees 99.99% availability.

const (
	SAPHighAvailabilityTypeAvailabilitySet  SAPHighAvailabilityType = "AvailabilitySet"
	SAPHighAvailabilityTypeAvailabilityZone SAPHighAvailabilityType = "AvailabilityZone"
)

func PossibleSAPHighAvailabilityTypeValues added in v0.2.0

func PossibleSAPHighAvailabilityTypeValues() []SAPHighAvailabilityType

PossibleSAPHighAvailabilityTypeValues returns the possible values for the SAPHighAvailabilityType const type.

type SAPInstallWithoutOSConfigSoftwareConfiguration added in v0.2.0

type SAPInstallWithoutOSConfigSoftwareConfiguration struct {
	// REQUIRED; The URL to the SAP Build of Materials(BOM) file.
	BomURL *string `json:"bomUrl,omitempty"`

	// REQUIRED; The SAP bits storage account id.
	SapBitsStorageAccountID *string `json:"sapBitsStorageAccountId,omitempty"`

	// REQUIRED; The SAP software installation Type.
	SoftwareInstallationType *SAPSoftwareInstallationType `json:"softwareInstallationType,omitempty"`

	// REQUIRED; The software version to install.
	SoftwareVersion *string `json:"softwareVersion,omitempty"`

	// Gets or sets the HA software configuration.
	HighAvailabilitySoftwareConfiguration *HighAvailabilitySoftwareConfiguration `json:"highAvailabilitySoftwareConfiguration,omitempty"`
}

SAPInstallWithoutOSConfigSoftwareConfiguration - The SAP Software configuration Input when the software is to be installed by service without OS Configurations

func (*SAPInstallWithoutOSConfigSoftwareConfiguration) GetSoftwareConfiguration added in v0.2.0

GetSoftwareConfiguration implements the SoftwareConfigurationClassification interface for type SAPInstallWithoutOSConfigSoftwareConfiguration.

func (SAPInstallWithoutOSConfigSoftwareConfiguration) MarshalJSON added in v0.2.0

MarshalJSON implements the json.Marshaller interface for type SAPInstallWithoutOSConfigSoftwareConfiguration.

func (*SAPInstallWithoutOSConfigSoftwareConfiguration) UnmarshalJSON added in v0.2.0

UnmarshalJSON implements the json.Unmarshaller interface for type SAPInstallWithoutOSConfigSoftwareConfiguration.

type SAPProductType added in v0.2.0

type SAPProductType string

SAPProductType - Defines the SAP Product type.

const (
	SAPProductTypeECC    SAPProductType = "ECC"
	SAPProductTypeOther  SAPProductType = "Other"
	SAPProductTypeS4HANA SAPProductType = "S4HANA"
)

func PossibleSAPProductTypeValues added in v0.2.0

func PossibleSAPProductTypeValues() []SAPProductType

PossibleSAPProductTypeValues returns the possible values for the SAPProductType const type.

type SAPSizingRecommendationRequest added in v0.2.0

type SAPSizingRecommendationRequest struct {
	// REQUIRED; The geo-location where the resource is to be created.
	AppLocation *string `json:"appLocation,omitempty"`

	// REQUIRED; The database type.
	DatabaseType *SAPDatabaseType `json:"databaseType,omitempty"`

	// REQUIRED; The database memory configuration.
	DbMemory *int64 `json:"dbMemory,omitempty"`

	// REQUIRED; The deployment type. Eg: SingleServer/ThreeTier
	DeploymentType *SAPDeploymentType `json:"deploymentType,omitempty"`

	// REQUIRED; Defines the environment type - Production/Non Production.
	Environment *SAPEnvironmentType `json:"environment,omitempty"`

	// REQUIRED; Defines the SAP Product type.
	SapProduct *SAPProductType `json:"sapProduct,omitempty"`

	// REQUIRED; The SAP Application Performance Standard measurement.
	Saps *int64 `json:"saps,omitempty"`

	// The DB scale method.
	DbScaleMethod *SAPDatabaseScaleMethod `json:"dbScaleMethod,omitempty"`

	// The high availability type.
	HighAvailabilityType *SAPHighAvailabilityType `json:"highAvailabilityType,omitempty"`
}

SAPSizingRecommendationRequest - The SAP Sizing Recommendation request.

func (SAPSizingRecommendationRequest) MarshalJSON added in v0.2.0

func (s SAPSizingRecommendationRequest) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SAPSizingRecommendationRequest.

func (*SAPSizingRecommendationRequest) UnmarshalJSON added in v0.2.0

func (s *SAPSizingRecommendationRequest) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SAPSizingRecommendationRequest.

type SAPSizingRecommendationResult added in v0.2.0

type SAPSizingRecommendationResult struct {
	// REQUIRED; The type of SAP deployment, single server or Three tier.
	DeploymentType *SAPDeploymentType `json:"deploymentType,omitempty"`
}

SAPSizingRecommendationResult - The SAP sizing recommendation result.

func (*SAPSizingRecommendationResult) GetSAPSizingRecommendationResult added in v0.2.0

func (s *SAPSizingRecommendationResult) GetSAPSizingRecommendationResult() *SAPSizingRecommendationResult

GetSAPSizingRecommendationResult implements the SAPSizingRecommendationResultClassification interface for type SAPSizingRecommendationResult.

func (SAPSizingRecommendationResult) MarshalJSON added in v0.2.0

func (s SAPSizingRecommendationResult) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SAPSizingRecommendationResult.

func (*SAPSizingRecommendationResult) UnmarshalJSON added in v0.2.0

func (s *SAPSizingRecommendationResult) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SAPSizingRecommendationResult.

type SAPSizingRecommendationResultClassification added in v0.2.0

type SAPSizingRecommendationResultClassification interface {
	// GetSAPSizingRecommendationResult returns the SAPSizingRecommendationResult content of the underlying type.
	GetSAPSizingRecommendationResult() *SAPSizingRecommendationResult
}

SAPSizingRecommendationResultClassification provides polymorphic access to related types. Call the interface's GetSAPSizingRecommendationResult() method to access the common type. Use a type switch to determine the concrete type. The possible types are: - *SAPSizingRecommendationResult, *SingleServerRecommendationResult, *ThreeTierRecommendationResult

type SAPSoftwareInstallationType added in v0.2.0

type SAPSoftwareInstallationType string

SAPSoftwareInstallationType - The SAP software installation Type.

const (
	SAPSoftwareInstallationTypeExternal                  SAPSoftwareInstallationType = "External"
	SAPSoftwareInstallationTypeSAPInstallWithoutOSConfig SAPSoftwareInstallationType = "SAPInstallWithoutOSConfig"
	SAPSoftwareInstallationTypeServiceInitiated          SAPSoftwareInstallationType = "ServiceInitiated"
)

func PossibleSAPSoftwareInstallationTypeValues added in v0.2.0

func PossibleSAPSoftwareInstallationTypeValues() []SAPSoftwareInstallationType

PossibleSAPSoftwareInstallationTypeValues returns the possible values for the SAPSoftwareInstallationType const type.

type SAPSupportedResourceSKUsResult added in v0.2.0

type SAPSupportedResourceSKUsResult struct {
	// Gets the list of SAP supported SKUs.
	SupportedSKUs []*SAPSupportedSKU `json:"supportedSkus,omitempty"`
}

SAPSupportedResourceSKUsResult - The list of supported SKUs for different resources which are part of SAP deployment.

func (SAPSupportedResourceSKUsResult) MarshalJSON added in v0.2.0

func (s SAPSupportedResourceSKUsResult) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SAPSupportedResourceSKUsResult.

func (*SAPSupportedResourceSKUsResult) UnmarshalJSON added in v0.2.0

func (s *SAPSupportedResourceSKUsResult) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SAPSupportedResourceSKUsResult.

type SAPSupportedSKU added in v0.2.0

type SAPSupportedSKU struct {
	// True if the Sku is certified for App server in the SAP system.
	IsAppServerCertified *bool `json:"isAppServerCertified,omitempty"`

	// True if the Sku is certified for Database server in the SAP system.
	IsDatabaseCertified *bool `json:"isDatabaseCertified,omitempty"`

	// The VM Sku.
	VMSKU *string `json:"vmSku,omitempty"`
}

SAPSupportedSKU - The SAP supported SKU.

func (SAPSupportedSKU) MarshalJSON added in v0.2.0

func (s SAPSupportedSKU) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SAPSupportedSKU.

func (*SAPSupportedSKU) UnmarshalJSON added in v0.2.0

func (s *SAPSupportedSKU) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SAPSupportedSKU.

type SAPSupportedSKUsRequest added in v0.2.0

type SAPSupportedSKUsRequest struct {
	// REQUIRED; The geo-location where the resource is to be created.
	AppLocation *string `json:"appLocation,omitempty"`

	// REQUIRED; The database type. Eg: HANA, DB2, etc
	DatabaseType *SAPDatabaseType `json:"databaseType,omitempty"`

	// REQUIRED; The deployment type. Eg: SingleServer/ThreeTier
	DeploymentType *SAPDeploymentType `json:"deploymentType,omitempty"`

	// REQUIRED; Defines the environment type - Production/Non Production.
	Environment *SAPEnvironmentType `json:"environment,omitempty"`

	// REQUIRED; Defines the SAP Product type.
	SapProduct *SAPProductType `json:"sapProduct,omitempty"`

	// The high availability type.
	HighAvailabilityType *SAPHighAvailabilityType `json:"highAvailabilityType,omitempty"`
}

SAPSupportedSKUsRequest - The SAP request to get list of supported SKUs.

func (SAPSupportedSKUsRequest) MarshalJSON added in v0.2.0

func (s SAPSupportedSKUsRequest) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SAPSupportedSKUsRequest.

func (*SAPSupportedSKUsRequest) UnmarshalJSON added in v0.2.0

func (s *SAPSupportedSKUsRequest) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SAPSupportedSKUsRequest.

type SAPVirtualInstance added in v0.2.0

type SAPVirtualInstance struct {
	// REQUIRED; The geo-location where the resource lives
	Location *string `json:"location,omitempty"`

	// REQUIRED; Defines the Virtual Instance for SAP solutions resource properties.
	Properties *SAPVirtualInstanceProperties `json:"properties,omitempty"`

	// Managed service identity (user assigned identities)
	Identity *UserAssignedServiceIdentity `json:"identity,omitempty"`

	// Resource tags.
	Tags map[string]*string `json:"tags,omitempty"`

	// READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
	ID *string `json:"id,omitempty" azure:"ro"`

	// READ-ONLY; The name of the resource
	Name *string `json:"name,omitempty" azure:"ro"`

	// READ-ONLY; Azure Resource Manager metadata containing createdBy and modifiedBy information.
	SystemData *SystemData `json:"systemData,omitempty" azure:"ro"`

	// READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
	Type *string `json:"type,omitempty" azure:"ro"`
}

SAPVirtualInstance - Define the Virtual Instance for SAP solutions resource.

func (SAPVirtualInstance) MarshalJSON added in v0.2.0

func (s SAPVirtualInstance) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SAPVirtualInstance.

func (*SAPVirtualInstance) UnmarshalJSON added in v0.2.0

func (s *SAPVirtualInstance) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SAPVirtualInstance.

type SAPVirtualInstanceError added in v0.2.0

type SAPVirtualInstanceError struct {
	// The Virtual Instance for SAP error body.
	Properties *ErrorDefinition `json:"properties,omitempty"`
}

SAPVirtualInstanceError - An error response from the Virtual Instance for SAP Workload service.

func (SAPVirtualInstanceError) MarshalJSON added in v0.2.0

func (s SAPVirtualInstanceError) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SAPVirtualInstanceError.

func (*SAPVirtualInstanceError) UnmarshalJSON added in v0.2.0

func (s *SAPVirtualInstanceError) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SAPVirtualInstanceError.

type SAPVirtualInstanceList added in v0.2.0

type SAPVirtualInstanceList struct {
	// Gets the value of next link.
	NextLink *string `json:"nextLink,omitempty"`

	// Gets the list of Virtual Instances for SAP solutions resources.
	Value []*SAPVirtualInstance `json:"value,omitempty"`
}

SAPVirtualInstanceList - Defines the collection of Virtual Instance for SAP solutions resources.

func (SAPVirtualInstanceList) MarshalJSON added in v0.2.0

func (s SAPVirtualInstanceList) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SAPVirtualInstanceList.

func (*SAPVirtualInstanceList) UnmarshalJSON added in v0.2.0

func (s *SAPVirtualInstanceList) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SAPVirtualInstanceList.

type SAPVirtualInstanceProperties added in v0.2.0

type SAPVirtualInstanceProperties struct {
	// REQUIRED; Defines if the SAP system is being created using Azure Center for SAP solutions (ACSS) or if an existing SAP
	// system is being registered with ACSS
	Configuration SAPConfigurationClassification `json:"configuration,omitempty"`

	// REQUIRED; Defines the environment type - Production/Non Production.
	Environment *SAPEnvironmentType `json:"environment,omitempty"`

	// REQUIRED; Defines the SAP Product type.
	SapProduct *SAPProductType `json:"sapProduct,omitempty"`

	// Managed resource group configuration
	ManagedResourceGroupConfiguration *ManagedRGConfiguration `json:"managedResourceGroupConfiguration,omitempty"`

	// READ-ONLY; Indicates any errors on the Virtual Instance for SAP solutions resource.
	Errors *SAPVirtualInstanceError `json:"errors,omitempty" azure:"ro"`

	// READ-ONLY; Defines the health of SAP Instances.
	Health *SAPHealthState `json:"health,omitempty" azure:"ro"`

	// READ-ONLY; Defines the provisioning states.
	ProvisioningState *SapVirtualInstanceProvisioningState `json:"provisioningState,omitempty" azure:"ro"`

	// READ-ONLY; Defines the Virtual Instance for SAP state.
	State *SAPVirtualInstanceState `json:"state,omitempty" azure:"ro"`

	// READ-ONLY; Defines the SAP Instance status.
	Status *SAPVirtualInstanceStatus `json:"status,omitempty" azure:"ro"`
}

SAPVirtualInstanceProperties - Defines the Virtual Instance for SAP solutions resource properties.

func (SAPVirtualInstanceProperties) MarshalJSON added in v0.2.0

func (s SAPVirtualInstanceProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SAPVirtualInstanceProperties.

func (*SAPVirtualInstanceProperties) UnmarshalJSON added in v0.2.0

func (s *SAPVirtualInstanceProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SAPVirtualInstanceProperties.

type SAPVirtualInstanceState added in v0.2.0

type SAPVirtualInstanceState string

SAPVirtualInstanceState - Defines the Virtual Instance for SAP state.

const (
	SAPVirtualInstanceStateDiscoveryFailed                    SAPVirtualInstanceState = "DiscoveryFailed"
	SAPVirtualInstanceStateDiscoveryInProgress                SAPVirtualInstanceState = "DiscoveryInProgress"
	SAPVirtualInstanceStateDiscoveryPending                   SAPVirtualInstanceState = "DiscoveryPending"
	SAPVirtualInstanceStateInfrastructureDeploymentFailed     SAPVirtualInstanceState = "InfrastructureDeploymentFailed"
	SAPVirtualInstanceStateInfrastructureDeploymentInProgress SAPVirtualInstanceState = "InfrastructureDeploymentInProgress"
	SAPVirtualInstanceStateInfrastructureDeploymentPending    SAPVirtualInstanceState = "InfrastructureDeploymentPending"
	SAPVirtualInstanceStateRegistrationComplete               SAPVirtualInstanceState = "RegistrationComplete"
	SAPVirtualInstanceStateSoftwareDetectionFailed            SAPVirtualInstanceState = "SoftwareDetectionFailed"
	SAPVirtualInstanceStateSoftwareDetectionInProgress        SAPVirtualInstanceState = "SoftwareDetectionInProgress"
	SAPVirtualInstanceStateSoftwareInstallationFailed         SAPVirtualInstanceState = "SoftwareInstallationFailed"
	SAPVirtualInstanceStateSoftwareInstallationInProgress     SAPVirtualInstanceState = "SoftwareInstallationInProgress"
	SAPVirtualInstanceStateSoftwareInstallationPending        SAPVirtualInstanceState = "SoftwareInstallationPending"
)

func PossibleSAPVirtualInstanceStateValues added in v0.2.0

func PossibleSAPVirtualInstanceStateValues() []SAPVirtualInstanceState

PossibleSAPVirtualInstanceStateValues returns the possible values for the SAPVirtualInstanceState const type.

type SAPVirtualInstanceStatus added in v0.2.0

type SAPVirtualInstanceStatus string

SAPVirtualInstanceStatus - Defines the SAP Instance status.

const (
	SAPVirtualInstanceStatusOffline          SAPVirtualInstanceStatus = "Offline"
	SAPVirtualInstanceStatusPartiallyRunning SAPVirtualInstanceStatus = "PartiallyRunning"
	SAPVirtualInstanceStatusRunning          SAPVirtualInstanceStatus = "Running"
	SAPVirtualInstanceStatusSoftShutdown     SAPVirtualInstanceStatus = "SoftShutdown"
	SAPVirtualInstanceStatusStarting         SAPVirtualInstanceStatus = "Starting"
	SAPVirtualInstanceStatusStopping         SAPVirtualInstanceStatus = "Stopping"
	SAPVirtualInstanceStatusUnavailable      SAPVirtualInstanceStatus = "Unavailable"
)

func PossibleSAPVirtualInstanceStatusValues added in v0.2.0

func PossibleSAPVirtualInstanceStatusValues() []SAPVirtualInstanceStatus

PossibleSAPVirtualInstanceStatusValues returns the possible values for the SAPVirtualInstanceStatus const type.

type SAPVirtualInstancesClient added in v0.2.0

type SAPVirtualInstancesClient struct {
	// contains filtered or unexported fields
}

SAPVirtualInstancesClient contains the methods for the SAPVirtualInstances group. Don't use this type directly, use NewSAPVirtualInstancesClient() instead.

func NewSAPVirtualInstancesClient added in v0.2.0

func NewSAPVirtualInstancesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*SAPVirtualInstancesClient, error)

NewSAPVirtualInstancesClient creates a new instance of SAPVirtualInstancesClient with the specified values.

  • subscriptionID - The ID of the target subscription.
  • credential - used to authorize requests. Usually a credential from azidentity.
  • options - pass nil to accept the default values.

func (*SAPVirtualInstancesClient) BeginCreate added in v0.2.0

BeginCreate - Creates a Virtual Instance for SAP solutions (VIS) resource If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • sapVirtualInstanceName - The name of the Virtual Instances for SAP solutions resource
  • body - Virtual Instance for SAP solutions resource request body.
  • options - SAPVirtualInstancesClientBeginCreateOptions contains the optional parameters for the SAPVirtualInstancesClient.BeginCreate method.
Example (CreateInfrastructureOnlyForDistributedSystem)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPVirtualInstances_Create_Distributed.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPVirtualInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "test-rg", "X00", armworkloads.SAPVirtualInstance{
		Location: to.Ptr("westcentralus"),
		Tags:     map[string]*string{},
		Properties: &armworkloads.SAPVirtualInstanceProperties{
			Configuration: &armworkloads.DeploymentConfiguration{
				ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeployment),
				AppLocation:       to.Ptr("eastus"),
				InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
					AppResourceGroup: to.Ptr("X00-RG"),
					DeploymentType:   to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
					ApplicationServer: &armworkloads.ApplicationServerConfiguration{
						InstanceCount: to.Ptr[int64](6),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSH: &armworkloads.SSHConfiguration{
										PublicKeys: []*armworkloads.SSHPublicKey{
											{
												KeyData: to.Ptr("ssh-rsa public key"),
											}},
									},
								},
							},
							VMSize: to.Ptr("Standard_E32ds_v4"),
						},
					},
					CentralServer: &armworkloads.CentralServerConfiguration{
						InstanceCount: to.Ptr[int64](1),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSH: &armworkloads.SSHConfiguration{
										PublicKeys: []*armworkloads.SSHPublicKey{
											{
												KeyData: to.Ptr("ssh-rsa public key"),
											}},
									},
								},
							},
							VMSize: to.Ptr("Standard_E16ds_v4"),
						},
					},
					DatabaseServer: &armworkloads.DatabaseConfiguration{
						DatabaseType:  to.Ptr(armworkloads.SAPDatabaseTypeHANA),
						InstanceCount: to.Ptr[int64](1),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/dbsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSH: &armworkloads.SSHConfiguration{
										PublicKeys: []*armworkloads.SSHPublicKey{
											{
												KeyData: to.Ptr("ssh-rsa public key"),
											}},
									},
								},
							},
							VMSize: to.Ptr("Standard_M32ts"),
						},
					},
				},
			},
			Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
			SapProduct:  to.Ptr(armworkloads.SAPProductTypeS4HANA),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPVirtualInstance = armworkloads.SAPVirtualInstance{
	// 	Name: to.Ptr("X00"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPVirtualInstanceProperties{
	// 		Configuration: &armworkloads.DeploymentConfiguration{
	// 			ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeployment),
	// 			AppLocation: to.Ptr("eastus"),
	// 			InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
	// 				AppResourceGroup: to.Ptr("X00-RG"),
	// 				DeploymentType: to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
	// 				ApplicationServer: &armworkloads.ApplicationServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](6),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSH: &armworkloads.SSHConfiguration{
	// 									PublicKeys: []*armworkloads.SSHPublicKey{
	// 										{
	// 											KeyData: to.Ptr("ssh-rsa public key"),
	// 									}},
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E32ds_v4"),
	// 					},
	// 				},
	// 				CentralServer: &armworkloads.CentralServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](1),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSH: &armworkloads.SSHConfiguration{
	// 									PublicKeys: []*armworkloads.SSHPublicKey{
	// 										{
	// 											KeyData: to.Ptr("ssh-rsa public key"),
	// 									}},
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E16ds_v4"),
	// 					},
	// 				},
	// 				DatabaseServer: &armworkloads.DatabaseConfiguration{
	// 					DatabaseType: to.Ptr(armworkloads.SAPDatabaseTypeHANA),
	// 					InstanceCount: to.Ptr[int64](1),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/dbsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSH: &armworkloads.SSHConfiguration{
	// 									PublicKeys: []*armworkloads.SSHPublicKey{
	// 										{
	// 											KeyData: to.Ptr("ssh-rsa public key"),
	// 									}},
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_M32ts"),
	// 					},
	// 				},
	// 			},
	// 		},
	// 		Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
	// 		Health: to.Ptr(armworkloads.SAPHealthStateUnknown),
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		SapProduct: to.Ptr(armworkloads.SAPProductTypeS4HANA),
	// 		State: to.Ptr(armworkloads.SAPVirtualInstanceStateSoftwareInstallationPending),
	// 		Status: to.Ptr(armworkloads.SAPVirtualInstanceStatus("Unknown")),
	// 	},
	// }
}
Output:

Example (CreateInfrastructureOnlyForHaSystemWithAvailabilitySet)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPVirtualInstances_Create_HA_AvSet.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPVirtualInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "test-rg", "X00", armworkloads.SAPVirtualInstance{
		Location: to.Ptr("westcentralus"),
		Tags:     map[string]*string{},
		Properties: &armworkloads.SAPVirtualInstanceProperties{
			Configuration: &armworkloads.DeploymentConfiguration{
				ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeployment),
				AppLocation:       to.Ptr("eastus"),
				InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
					AppResourceGroup: to.Ptr("X00-RG"),
					DeploymentType:   to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
					ApplicationServer: &armworkloads.ApplicationServerConfiguration{
						InstanceCount: to.Ptr[int64](5),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSH: &armworkloads.SSHConfiguration{
										PublicKeys: []*armworkloads.SSHPublicKey{
											{
												KeyData: to.Ptr("ssh-rsa public key"),
											}},
									},
								},
							},
							VMSize: to.Ptr("Standard_E32ds_v4"),
						},
					},
					CentralServer: &armworkloads.CentralServerConfiguration{
						InstanceCount: to.Ptr[int64](2),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSH: &armworkloads.SSHConfiguration{
										PublicKeys: []*armworkloads.SSHPublicKey{
											{
												KeyData: to.Ptr("ssh-rsa public key"),
											}},
									},
								},
							},
							VMSize: to.Ptr("Standard_E16ds_v4"),
						},
					},
					DatabaseServer: &armworkloads.DatabaseConfiguration{
						DatabaseType:  to.Ptr(armworkloads.SAPDatabaseTypeHANA),
						InstanceCount: to.Ptr[int64](2),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/dbsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSH: &armworkloads.SSHConfiguration{
										PublicKeys: []*armworkloads.SSHPublicKey{
											{
												KeyData: to.Ptr("ssh-rsa public key"),
											}},
									},
								},
							},
							VMSize: to.Ptr("Standard_M32ts"),
						},
					},
					HighAvailabilityConfig: &armworkloads.HighAvailabilityConfiguration{
						HighAvailabilityType: to.Ptr(armworkloads.SAPHighAvailabilityTypeAvailabilitySet),
					},
				},
			},
			Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
			SapProduct:  to.Ptr(armworkloads.SAPProductTypeS4HANA),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPVirtualInstance = armworkloads.SAPVirtualInstance{
	// 	Name: to.Ptr("X00"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPVirtualInstanceProperties{
	// 		Configuration: &armworkloads.DeploymentConfiguration{
	// 			ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeployment),
	// 			AppLocation: to.Ptr("eastus"),
	// 			InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
	// 				AppResourceGroup: to.Ptr("X00-RG"),
	// 				DeploymentType: to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
	// 				ApplicationServer: &armworkloads.ApplicationServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](5),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSH: &armworkloads.SSHConfiguration{
	// 									PublicKeys: []*armworkloads.SSHPublicKey{
	// 										{
	// 											KeyData: to.Ptr("ssh-rsa public key"),
	// 									}},
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E32ds_v4"),
	// 					},
	// 				},
	// 				CentralServer: &armworkloads.CentralServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](2),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSH: &armworkloads.SSHConfiguration{
	// 									PublicKeys: []*armworkloads.SSHPublicKey{
	// 										{
	// 											KeyData: to.Ptr("ssh-rsa public key"),
	// 									}},
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E16ds_v4"),
	// 					},
	// 				},
	// 				DatabaseServer: &armworkloads.DatabaseConfiguration{
	// 					DatabaseType: to.Ptr(armworkloads.SAPDatabaseTypeHANA),
	// 					InstanceCount: to.Ptr[int64](2),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/dbsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSH: &armworkloads.SSHConfiguration{
	// 									PublicKeys: []*armworkloads.SSHPublicKey{
	// 										{
	// 											KeyData: to.Ptr("ssh-rsa public key"),
	// 									}},
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_M32ts"),
	// 					},
	// 				},
	// 				HighAvailabilityConfig: &armworkloads.HighAvailabilityConfiguration{
	// 					HighAvailabilityType: to.Ptr(armworkloads.SAPHighAvailabilityTypeAvailabilitySet),
	// 				},
	// 			},
	// 		},
	// 		Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
	// 		Health: to.Ptr(armworkloads.SAPHealthStateUnknown),
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		SapProduct: to.Ptr(armworkloads.SAPProductTypeS4HANA),
	// 		State: to.Ptr(armworkloads.SAPVirtualInstanceStateSoftwareInstallationPending),
	// 		Status: to.Ptr(armworkloads.SAPVirtualInstanceStatus("Unknown")),
	// 	},
	// }
}
Output:

Example (CreateInfrastructureOnlyForHaSystemWithAvailabilityZone)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPVirtualInstances_Create_HA_AvZone.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPVirtualInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "test-rg", "X00", armworkloads.SAPVirtualInstance{
		Location: to.Ptr("westcentralus"),
		Tags:     map[string]*string{},
		Properties: &armworkloads.SAPVirtualInstanceProperties{
			Configuration: &armworkloads.DeploymentConfiguration{
				ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeployment),
				AppLocation:       to.Ptr("eastus"),
				InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
					AppResourceGroup: to.Ptr("X00-RG"),
					DeploymentType:   to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
					ApplicationServer: &armworkloads.ApplicationServerConfiguration{
						InstanceCount: to.Ptr[int64](6),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSH: &armworkloads.SSHConfiguration{
										PublicKeys: []*armworkloads.SSHPublicKey{
											{
												KeyData: to.Ptr("ssh-rsa public key"),
											}},
									},
								},
							},
							VMSize: to.Ptr("Standard_E32ds_v4"),
						},
					},
					CentralServer: &armworkloads.CentralServerConfiguration{
						InstanceCount: to.Ptr[int64](2),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSH: &armworkloads.SSHConfiguration{
										PublicKeys: []*armworkloads.SSHPublicKey{
											{
												KeyData: to.Ptr("ssh-rsa public key"),
											}},
									},
								},
							},
							VMSize: to.Ptr("Standard_E16ds_v4"),
						},
					},
					DatabaseServer: &armworkloads.DatabaseConfiguration{
						DatabaseType:  to.Ptr(armworkloads.SAPDatabaseTypeHANA),
						InstanceCount: to.Ptr[int64](2),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/dbsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSH: &armworkloads.SSHConfiguration{
										PublicKeys: []*armworkloads.SSHPublicKey{
											{
												KeyData: to.Ptr("ssh-rsa public key"),
											}},
									},
								},
							},
							VMSize: to.Ptr("Standard_M32ts"),
						},
					},
					HighAvailabilityConfig: &armworkloads.HighAvailabilityConfiguration{
						HighAvailabilityType: to.Ptr(armworkloads.SAPHighAvailabilityTypeAvailabilityZone),
					},
				},
			},
			Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
			SapProduct:  to.Ptr(armworkloads.SAPProductTypeS4HANA),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPVirtualInstance = armworkloads.SAPVirtualInstance{
	// 	Name: to.Ptr("X00"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPVirtualInstanceProperties{
	// 		Configuration: &armworkloads.DeploymentConfiguration{
	// 			ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeployment),
	// 			AppLocation: to.Ptr("eastus"),
	// 			InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
	// 				AppResourceGroup: to.Ptr("X00-RG"),
	// 				DeploymentType: to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
	// 				ApplicationServer: &armworkloads.ApplicationServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](6),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSH: &armworkloads.SSHConfiguration{
	// 									PublicKeys: []*armworkloads.SSHPublicKey{
	// 										{
	// 											KeyData: to.Ptr("ssh-rsa public key"),
	// 									}},
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E32ds_v4"),
	// 					},
	// 				},
	// 				CentralServer: &armworkloads.CentralServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](2),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSH: &armworkloads.SSHConfiguration{
	// 									PublicKeys: []*armworkloads.SSHPublicKey{
	// 										{
	// 											KeyData: to.Ptr("ssh-rsa public key"),
	// 									}},
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E16ds_v4"),
	// 					},
	// 				},
	// 				DatabaseServer: &armworkloads.DatabaseConfiguration{
	// 					DatabaseType: to.Ptr(armworkloads.SAPDatabaseTypeHANA),
	// 					InstanceCount: to.Ptr[int64](2),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/dbsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSH: &armworkloads.SSHConfiguration{
	// 									PublicKeys: []*armworkloads.SSHPublicKey{
	// 										{
	// 											KeyData: to.Ptr("ssh-rsa public key"),
	// 									}},
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_M32ts"),
	// 					},
	// 				},
	// 				HighAvailabilityConfig: &armworkloads.HighAvailabilityConfiguration{
	// 					HighAvailabilityType: to.Ptr(armworkloads.SAPHighAvailabilityTypeAvailabilityZone),
	// 				},
	// 			},
	// 		},
	// 		Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
	// 		Health: to.Ptr(armworkloads.SAPHealthStateUnknown),
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		SapProduct: to.Ptr(armworkloads.SAPProductTypeS4HANA),
	// 		State: to.Ptr(armworkloads.SAPVirtualInstanceStateSoftwareInstallationPending),
	// 		Status: to.Ptr(armworkloads.SAPVirtualInstanceStatus("Unknown")),
	// 	},
	// }
}
Output:

Example (CreateInfrastructureOnlyForSingleServerSystem)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPVirtualInstances_Create_SingleServer.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPVirtualInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "test-rg", "X00", armworkloads.SAPVirtualInstance{
		Location: to.Ptr("westcentralus"),
		Tags:     map[string]*string{},
		Properties: &armworkloads.SAPVirtualInstanceProperties{
			Configuration: &armworkloads.DeploymentConfiguration{
				ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeployment),
				AppLocation:       to.Ptr("eastus"),
				InfrastructureConfiguration: &armworkloads.SingleServerConfiguration{
					AppResourceGroup: to.Ptr("X00-RG"),
					DeploymentType:   to.Ptr(armworkloads.SAPDeploymentTypeSingleServer),
					DatabaseType:     to.Ptr(armworkloads.SAPDatabaseTypeHANA),
					NetworkConfiguration: &armworkloads.NetworkConfiguration{
						IsSecondaryIPEnabled: to.Ptr(true),
					},
					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
						ImageReference: &armworkloads.ImageReference{
							Offer:     to.Ptr("RHEL-SAP"),
							Publisher: to.Ptr("RedHat"),
							SKU:       to.Ptr("7.4"),
							Version:   to.Ptr("7.4.2019062505"),
						},
						OSProfile: &armworkloads.OSProfile{
							AdminUsername: to.Ptr("{your-username}"),
							OSConfiguration: &armworkloads.LinuxConfiguration{
								OSType:                        to.Ptr(armworkloads.OSTypeLinux),
								DisablePasswordAuthentication: to.Ptr(true),
								SSH: &armworkloads.SSHConfiguration{
									PublicKeys: []*armworkloads.SSHPublicKey{
										{
											KeyData: to.Ptr("ssh-rsa public key"),
										}},
								},
							},
						},
						VMSize: to.Ptr("Standard_E32ds_v4"),
					},
				},
			},
			Environment: to.Ptr(armworkloads.SAPEnvironmentTypeNonProd),
			SapProduct:  to.Ptr(armworkloads.SAPProductTypeS4HANA),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPVirtualInstance = armworkloads.SAPVirtualInstance{
	// 	Name: to.Ptr("X00"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPVirtualInstanceProperties{
	// 		Configuration: &armworkloads.DeploymentConfiguration{
	// 			ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeployment),
	// 			AppLocation: to.Ptr("eastus"),
	// 			InfrastructureConfiguration: &armworkloads.SingleServerConfiguration{
	// 				AppResourceGroup: to.Ptr("X00-RG"),
	// 				DeploymentType: to.Ptr(armworkloads.SAPDeploymentTypeSingleServer),
	// 				DatabaseType: to.Ptr(armworkloads.SAPDatabaseTypeHANA),
	// 				SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 				VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 					ImageReference: &armworkloads.ImageReference{
	// 						Offer: to.Ptr("RHEL-SAP"),
	// 						Publisher: to.Ptr("RedHat"),
	// 						SKU: to.Ptr("7.4"),
	// 						Version: to.Ptr("7.4.2019062505"),
	// 					},
	// 					OSProfile: &armworkloads.OSProfile{
	// 						AdminUsername: to.Ptr("{your-username}"),
	// 						OSConfiguration: &armworkloads.LinuxConfiguration{
	// 							OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 							DisablePasswordAuthentication: to.Ptr(true),
	// 							SSH: &armworkloads.SSHConfiguration{
	// 								PublicKeys: []*armworkloads.SSHPublicKey{
	// 									{
	// 										KeyData: to.Ptr("ssh-rsa public key"),
	// 								}},
	// 							},
	// 						},
	// 					},
	// 					VMSize: to.Ptr("Standard_E32ds_v4"),
	// 				},
	// 			},
	// 		},
	// 		Environment: to.Ptr(armworkloads.SAPEnvironmentTypeNonProd),
	// 		Health: to.Ptr(armworkloads.SAPHealthStateUnknown),
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		SapProduct: to.Ptr(armworkloads.SAPProductTypeS4HANA),
	// 		State: to.Ptr(armworkloads.SAPVirtualInstanceStateSoftwareInstallationPending),
	// 		Status: to.Ptr(armworkloads.SAPVirtualInstanceStatus("Unknown")),
	// 	},
	// }
}
Output:

Example (CreateInfrastructureWithANewSapTransFileshare)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPVirtualInstances_Create_Distributed_CreateTrans.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPVirtualInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "test-rg", "X00", armworkloads.SAPVirtualInstance{
		Location: to.Ptr("westcentralus"),
		Tags:     map[string]*string{},
		Properties: &armworkloads.SAPVirtualInstanceProperties{
			Configuration: &armworkloads.DeploymentWithOSConfiguration{
				ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
				AppLocation:       to.Ptr("eastus"),
				InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
					AppResourceGroup: to.Ptr("X00-RG"),
					DeploymentType:   to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
					ApplicationServer: &armworkloads.ApplicationServerConfiguration{
						InstanceCount: to.Ptr[int64](6),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_E32ds_v4"),
						},
					},
					CentralServer: &armworkloads.CentralServerConfiguration{
						InstanceCount: to.Ptr[int64](1),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_E16ds_v4"),
						},
					},
					DatabaseServer: &armworkloads.DatabaseConfiguration{
						DatabaseType:  to.Ptr(armworkloads.SAPDatabaseTypeHANA),
						InstanceCount: to.Ptr[int64](1),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/dbsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_M32ts"),
						},
					},
					StorageConfiguration: &armworkloads.StorageConfiguration{
						TransportFileShareConfiguration: &armworkloads.CreateAndMountFileShareConfiguration{
							ConfigurationType:  to.Ptr(armworkloads.ConfigurationTypeCreateAndMount),
							ResourceGroup:      to.Ptr("test-rg"),
							StorageAccountName: to.Ptr("input-sa-name"),
						},
					},
				},
				OSSapConfiguration: &armworkloads.OsSapConfiguration{
					SapFqdn: to.Ptr("xyz.test.com"),
				},
			},
			Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
			SapProduct:  to.Ptr(armworkloads.SAPProductTypeS4HANA),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPVirtualInstance = armworkloads.SAPVirtualInstance{
	// 	Name: to.Ptr("X00"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPVirtualInstanceProperties{
	// 		Configuration: &armworkloads.DeploymentWithOSConfiguration{
	// 			ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
	// 			AppLocation: to.Ptr("eastus"),
	// 			InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
	// 				AppResourceGroup: to.Ptr("X00-RG"),
	// 				DeploymentType: to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
	// 				ApplicationServer: &armworkloads.ApplicationServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](6),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E32ds_v4"),
	// 					},
	// 				},
	// 				CentralServer: &armworkloads.CentralServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](1),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E16ds_v4"),
	// 					},
	// 				},
	// 				DatabaseServer: &armworkloads.DatabaseConfiguration{
	// 					DatabaseType: to.Ptr(armworkloads.SAPDatabaseTypeHANA),
	// 					InstanceCount: to.Ptr[int64](1),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/dbsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_M32ts"),
	// 					},
	// 				},
	// 				StorageConfiguration: &armworkloads.StorageConfiguration{
	// 					TransportFileShareConfiguration: &armworkloads.CreateAndMountFileShareConfiguration{
	// 						ConfigurationType: to.Ptr(armworkloads.ConfigurationTypeCreateAndMount),
	// 						ResourceGroup: to.Ptr("test-rg"),
	// 						StorageAccountName: to.Ptr("input-sa-name"),
	// 					},
	// 				},
	// 			},
	// 			OSSapConfiguration: &armworkloads.OsSapConfiguration{
	// 				SapFqdn: to.Ptr("xyz.test.com"),
	// 			},
	// 		},
	// 		Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
	// 		Health: to.Ptr(armworkloads.SAPHealthStateUnknown),
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		SapProduct: to.Ptr(armworkloads.SAPProductTypeS4HANA),
	// 		State: to.Ptr(armworkloads.SAPVirtualInstanceStateSoftwareInstallationPending),
	// 		Status: to.Ptr(armworkloads.SAPVirtualInstanceStatus("Unknown")),
	// 	},
	// }
}
Output:

Example (CreateInfrastructureWithAnExistingSapTransFileshare)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPVirtualInstances_Create_Distributed_MountTrans.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPVirtualInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "test-rg", "X00", armworkloads.SAPVirtualInstance{
		Location: to.Ptr("westcentralus"),
		Tags:     map[string]*string{},
		Properties: &armworkloads.SAPVirtualInstanceProperties{
			Configuration: &armworkloads.DeploymentWithOSConfiguration{
				ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
				AppLocation:       to.Ptr("eastus"),
				InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
					AppResourceGroup: to.Ptr("X00-RG"),
					DeploymentType:   to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
					ApplicationServer: &armworkloads.ApplicationServerConfiguration{
						InstanceCount: to.Ptr[int64](6),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_E32ds_v4"),
						},
					},
					CentralServer: &armworkloads.CentralServerConfiguration{
						InstanceCount: to.Ptr[int64](1),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_E16ds_v4"),
						},
					},
					DatabaseServer: &armworkloads.DatabaseConfiguration{
						DatabaseType:  to.Ptr(armworkloads.SAPDatabaseTypeHANA),
						InstanceCount: to.Ptr[int64](1),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/dbsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_M32ts"),
						},
					},
					StorageConfiguration: &armworkloads.StorageConfiguration{
						TransportFileShareConfiguration: &armworkloads.MountFileShareConfiguration{
							ConfigurationType: to.Ptr(armworkloads.ConfigurationTypeMount),
							ID:                to.Ptr("fileshareID"),
							PrivateEndpointID: to.Ptr("pe-arm-id"),
						},
					},
				},
				OSSapConfiguration: &armworkloads.OsSapConfiguration{
					SapFqdn: to.Ptr("xyz.test.com"),
				},
			},
			Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
			SapProduct:  to.Ptr(armworkloads.SAPProductTypeS4HANA),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPVirtualInstance = armworkloads.SAPVirtualInstance{
	// 	Name: to.Ptr("X00"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPVirtualInstanceProperties{
	// 		Configuration: &armworkloads.DeploymentWithOSConfiguration{
	// 			ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
	// 			AppLocation: to.Ptr("eastus"),
	// 			InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
	// 				AppResourceGroup: to.Ptr("X00-RG"),
	// 				DeploymentType: to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
	// 				ApplicationServer: &armworkloads.ApplicationServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](6),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E32ds_v4"),
	// 					},
	// 				},
	// 				CentralServer: &armworkloads.CentralServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](1),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E16ds_v4"),
	// 					},
	// 				},
	// 				DatabaseServer: &armworkloads.DatabaseConfiguration{
	// 					DatabaseType: to.Ptr(armworkloads.SAPDatabaseTypeHANA),
	// 					InstanceCount: to.Ptr[int64](1),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/dbsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_M32ts"),
	// 					},
	// 				},
	// 				StorageConfiguration: &armworkloads.StorageConfiguration{
	// 					TransportFileShareConfiguration: &armworkloads.MountFileShareConfiguration{
	// 						ConfigurationType: to.Ptr(armworkloads.ConfigurationTypeMount),
	// 						ID: to.Ptr("fileshareID"),
	// 						PrivateEndpointID: to.Ptr("pe-arm-id"),
	// 					},
	// 				},
	// 			},
	// 			OSSapConfiguration: &armworkloads.OsSapConfiguration{
	// 				SapFqdn: to.Ptr("xyz.test.com"),
	// 			},
	// 		},
	// 		Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
	// 		Health: to.Ptr(armworkloads.SAPHealthStateUnknown),
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		SapProduct: to.Ptr(armworkloads.SAPProductTypeS4HANA),
	// 		State: to.Ptr(armworkloads.SAPVirtualInstanceStateSoftwareInstallationPending),
	// 		Status: to.Ptr(armworkloads.SAPVirtualInstanceStatus("Unknown")),
	// 	},
	// }
}
Output:

Example (CreateInfrastructureWithDiskAndOsConfigurationForDistributedSystemRecommended)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPVirtualInstances_Create_DiskDetails_Distributed.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPVirtualInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "test-rg", "X00", armworkloads.SAPVirtualInstance{
		Location: to.Ptr("westcentralus"),
		Tags:     map[string]*string{},
		Properties: &armworkloads.SAPVirtualInstanceProperties{
			Configuration: &armworkloads.DeploymentWithOSConfiguration{
				ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
				AppLocation:       to.Ptr("eastus"),
				InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
					AppResourceGroup: to.Ptr("X00-RG"),
					DeploymentType:   to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
					ApplicationServer: &armworkloads.ApplicationServerConfiguration{
						InstanceCount: to.Ptr[int64](6),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/dindurkhya-e2etesting/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_E32ds_v4"),
						},
					},
					CentralServer: &armworkloads.CentralServerConfiguration{
						InstanceCount: to.Ptr[int64](1),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/dindurkhya-e2etesting/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_E16ds_v4"),
						},
					},
					DatabaseServer: &armworkloads.DatabaseConfiguration{
						DatabaseType: to.Ptr(armworkloads.SAPDatabaseTypeHANA),
						DiskConfiguration: &armworkloads.DiskConfiguration{
							DiskVolumeConfigurations: map[string]*armworkloads.DiskVolumeConfiguration{
								"backup": {
									Count:  to.Ptr[int64](2),
									SizeGB: to.Ptr[int64](256),
									SKU: &armworkloads.DiskSKU{
										Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
									},
								},
								"hana/data": {
									Count:  to.Ptr[int64](4),
									SizeGB: to.Ptr[int64](128),
									SKU: &armworkloads.DiskSKU{
										Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
									},
								},
								"hana/log": {
									Count:  to.Ptr[int64](3),
									SizeGB: to.Ptr[int64](128),
									SKU: &armworkloads.DiskSKU{
										Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
									},
								},
								"hana/shared": {
									Count:  to.Ptr[int64](1),
									SizeGB: to.Ptr[int64](256),
									SKU: &armworkloads.DiskSKU{
										Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
									},
								},
								"os": {
									Count:  to.Ptr[int64](1),
									SizeGB: to.Ptr[int64](64),
									SKU: &armworkloads.DiskSKU{
										Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
									},
								},
								"usr/sap": {
									Count:  to.Ptr[int64](1),
									SizeGB: to.Ptr[int64](128),
									SKU: &armworkloads.DiskSKU{
										Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
									},
								},
							},
						},
						InstanceCount: to.Ptr[int64](1),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/dindurkhya-e2etesting/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/dbsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_M32ts"),
						},
					},
				},
				OSSapConfiguration: &armworkloads.OsSapConfiguration{
					SapFqdn: to.Ptr("xyz.test.com"),
				},
			},
			Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
			SapProduct:  to.Ptr(armworkloads.SAPProductTypeS4HANA),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPVirtualInstance = armworkloads.SAPVirtualInstance{
	// 	Name: to.Ptr("X00"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPVirtualInstanceProperties{
	// 		Configuration: &armworkloads.DeploymentWithOSConfiguration{
	// 			ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
	// 			AppLocation: to.Ptr("eastus"),
	// 			InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
	// 				AppResourceGroup: to.Ptr("X00-RG"),
	// 				DeploymentType: to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
	// 				ApplicationServer: &armworkloads.ApplicationServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](6),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/dindurkhya-e2etesting/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E32ds_v4"),
	// 					},
	// 				},
	// 				CentralServer: &armworkloads.CentralServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](1),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/dindurkhya-e2etesting/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E16ds_v4"),
	// 					},
	// 				},
	// 				DatabaseServer: &armworkloads.DatabaseConfiguration{
	// 					DatabaseType: to.Ptr(armworkloads.SAPDatabaseTypeHANA),
	// 					DiskConfiguration: &armworkloads.DiskConfiguration{
	// 						DiskVolumeConfigurations: map[string]*armworkloads.DiskVolumeConfiguration{
	// 							"backup": &armworkloads.DiskVolumeConfiguration{
	// 								Count: to.Ptr[int64](2),
	// 								SizeGB: to.Ptr[int64](256),
	// 								SKU: &armworkloads.DiskSKU{
	// 									Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
	// 								},
	// 							},
	// 							"hana/data": &armworkloads.DiskVolumeConfiguration{
	// 								Count: to.Ptr[int64](4),
	// 								SizeGB: to.Ptr[int64](128),
	// 								SKU: &armworkloads.DiskSKU{
	// 									Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 								},
	// 							},
	// 							"hana/log": &armworkloads.DiskVolumeConfiguration{
	// 								Count: to.Ptr[int64](3),
	// 								SizeGB: to.Ptr[int64](128),
	// 								SKU: &armworkloads.DiskSKU{
	// 									Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 								},
	// 							},
	// 							"hana/shared": &armworkloads.DiskVolumeConfiguration{
	// 								Count: to.Ptr[int64](1),
	// 								SizeGB: to.Ptr[int64](256),
	// 								SKU: &armworkloads.DiskSKU{
	// 									Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
	// 								},
	// 							},
	// 							"os": &armworkloads.DiskVolumeConfiguration{
	// 								Count: to.Ptr[int64](1),
	// 								SizeGB: to.Ptr[int64](64),
	// 								SKU: &armworkloads.DiskSKU{
	// 									Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
	// 								},
	// 							},
	// 							"usr/sap": &armworkloads.DiskVolumeConfiguration{
	// 								Count: to.Ptr[int64](1),
	// 								SizeGB: to.Ptr[int64](128),
	// 								SKU: &armworkloads.DiskSKU{
	// 									Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 								},
	// 							},
	// 						},
	// 					},
	// 					InstanceCount: to.Ptr[int64](1),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/dindurkhya-e2etesting/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/dbsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_M32ts"),
	// 					},
	// 				},
	// 			},
	// 			OSSapConfiguration: &armworkloads.OsSapConfiguration{
	// 				SapFqdn: to.Ptr("xyz.test.com"),
	// 			},
	// 		},
	// 		Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
	// 		Health: to.Ptr(armworkloads.SAPHealthStateUnknown),
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		SapProduct: to.Ptr(armworkloads.SAPProductTypeS4HANA),
	// 		State: to.Ptr(armworkloads.SAPVirtualInstanceStateSoftwareInstallationPending),
	// 		Status: to.Ptr(armworkloads.SAPVirtualInstanceStatus("Unknown")),
	// 	},
	// }
}
Output:

Example (CreateInfrastructureWithDiskAndOsConfigurationForHaSystemWithAvailabilitySetRecommended)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPVirtualInstances_Create_DiskDetails_HA_AvSet.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPVirtualInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "test-rg", "X00", armworkloads.SAPVirtualInstance{
		Location: to.Ptr("westcentralus"),
		Tags:     map[string]*string{},
		Properties: &armworkloads.SAPVirtualInstanceProperties{
			Configuration: &armworkloads.DeploymentWithOSConfiguration{
				ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
				AppLocation:       to.Ptr("eastus"),
				InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
					AppResourceGroup: to.Ptr("X00-RG"),
					DeploymentType:   to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
					ApplicationServer: &armworkloads.ApplicationServerConfiguration{
						InstanceCount: to.Ptr[int64](6),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/dindurkhya-e2etesting/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_E32ds_v4"),
						},
					},
					CentralServer: &armworkloads.CentralServerConfiguration{
						InstanceCount: to.Ptr[int64](2),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/dindurkhya-e2etesting/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_E16ds_v4"),
						},
					},
					DatabaseServer: &armworkloads.DatabaseConfiguration{
						DatabaseType: to.Ptr(armworkloads.SAPDatabaseTypeHANA),
						DiskConfiguration: &armworkloads.DiskConfiguration{
							DiskVolumeConfigurations: map[string]*armworkloads.DiskVolumeConfiguration{
								"backup": {
									Count:  to.Ptr[int64](2),
									SizeGB: to.Ptr[int64](256),
									SKU: &armworkloads.DiskSKU{
										Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
									},
								},
								"hana/data": {
									Count:  to.Ptr[int64](4),
									SizeGB: to.Ptr[int64](128),
									SKU: &armworkloads.DiskSKU{
										Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
									},
								},
								"hana/log": {
									Count:  to.Ptr[int64](3),
									SizeGB: to.Ptr[int64](128),
									SKU: &armworkloads.DiskSKU{
										Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
									},
								},
								"hana/shared": {
									Count:  to.Ptr[int64](1),
									SizeGB: to.Ptr[int64](256),
									SKU: &armworkloads.DiskSKU{
										Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
									},
								},
								"os": {
									Count:  to.Ptr[int64](1),
									SizeGB: to.Ptr[int64](64),
									SKU: &armworkloads.DiskSKU{
										Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
									},
								},
								"usr/sap": {
									Count:  to.Ptr[int64](1),
									SizeGB: to.Ptr[int64](128),
									SKU: &armworkloads.DiskSKU{
										Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
									},
								},
							},
						},
						InstanceCount: to.Ptr[int64](2),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/dindurkhya-e2etesting/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/dbsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_M32ts"),
						},
					},
					HighAvailabilityConfig: &armworkloads.HighAvailabilityConfiguration{
						HighAvailabilityType: to.Ptr(armworkloads.SAPHighAvailabilityTypeAvailabilitySet),
					},
				},
				OSSapConfiguration: &armworkloads.OsSapConfiguration{
					SapFqdn: to.Ptr("xyz.test.com"),
				},
			},
			Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
			SapProduct:  to.Ptr(armworkloads.SAPProductTypeS4HANA),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPVirtualInstance = armworkloads.SAPVirtualInstance{
	// 	Name: to.Ptr("X00"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPVirtualInstanceProperties{
	// 		Configuration: &armworkloads.DeploymentWithOSConfiguration{
	// 			ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
	// 			AppLocation: to.Ptr("eastus"),
	// 			InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
	// 				AppResourceGroup: to.Ptr("X00-RG"),
	// 				DeploymentType: to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
	// 				ApplicationServer: &armworkloads.ApplicationServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](6),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/dindurkhya-e2etesting/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E32ds_v4"),
	// 					},
	// 				},
	// 				CentralServer: &armworkloads.CentralServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](2),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/dindurkhya-e2etesting/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E16ds_v4"),
	// 					},
	// 				},
	// 				DatabaseServer: &armworkloads.DatabaseConfiguration{
	// 					DatabaseType: to.Ptr(armworkloads.SAPDatabaseTypeHANA),
	// 					DiskConfiguration: &armworkloads.DiskConfiguration{
	// 						DiskVolumeConfigurations: map[string]*armworkloads.DiskVolumeConfiguration{
	// 							"backup": &armworkloads.DiskVolumeConfiguration{
	// 								Count: to.Ptr[int64](2),
	// 								SizeGB: to.Ptr[int64](256),
	// 								SKU: &armworkloads.DiskSKU{
	// 									Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
	// 								},
	// 							},
	// 							"hana/data": &armworkloads.DiskVolumeConfiguration{
	// 								Count: to.Ptr[int64](4),
	// 								SizeGB: to.Ptr[int64](128),
	// 								SKU: &armworkloads.DiskSKU{
	// 									Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 								},
	// 							},
	// 							"hana/log": &armworkloads.DiskVolumeConfiguration{
	// 								Count: to.Ptr[int64](3),
	// 								SizeGB: to.Ptr[int64](128),
	// 								SKU: &armworkloads.DiskSKU{
	// 									Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 								},
	// 							},
	// 							"hana/shared": &armworkloads.DiskVolumeConfiguration{
	// 								Count: to.Ptr[int64](1),
	// 								SizeGB: to.Ptr[int64](256),
	// 								SKU: &armworkloads.DiskSKU{
	// 									Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
	// 								},
	// 							},
	// 							"os": &armworkloads.DiskVolumeConfiguration{
	// 								Count: to.Ptr[int64](1),
	// 								SizeGB: to.Ptr[int64](64),
	// 								SKU: &armworkloads.DiskSKU{
	// 									Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
	// 								},
	// 							},
	// 							"usr/sap": &armworkloads.DiskVolumeConfiguration{
	// 								Count: to.Ptr[int64](1),
	// 								SizeGB: to.Ptr[int64](128),
	// 								SKU: &armworkloads.DiskSKU{
	// 									Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 								},
	// 							},
	// 						},
	// 					},
	// 					InstanceCount: to.Ptr[int64](2),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/dindurkhya-e2etesting/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/dbsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_M32ts"),
	// 					},
	// 				},
	// 				HighAvailabilityConfig: &armworkloads.HighAvailabilityConfiguration{
	// 					HighAvailabilityType: to.Ptr(armworkloads.SAPHighAvailabilityTypeAvailabilitySet),
	// 				},
	// 			},
	// 			OSSapConfiguration: &armworkloads.OsSapConfiguration{
	// 				SapFqdn: to.Ptr("xyz.test.com"),
	// 			},
	// 		},
	// 		Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
	// 		Health: to.Ptr(armworkloads.SAPHealthStateUnknown),
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		SapProduct: to.Ptr(armworkloads.SAPProductTypeS4HANA),
	// 		State: to.Ptr(armworkloads.SAPVirtualInstanceStateSoftwareInstallationPending),
	// 		Status: to.Ptr(armworkloads.SAPVirtualInstanceStatus("Unknown")),
	// 	},
	// }
}
Output:

Example (CreateInfrastructureWithDiskAndOsConfigurationForHaSystemWithAvailabilityZoneRecommended)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPVirtualInstances_Create_DiskDetails_HA_AvZone.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPVirtualInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "test-rg", "X00", armworkloads.SAPVirtualInstance{
		Location: to.Ptr("westcentralus"),
		Tags:     map[string]*string{},
		Properties: &armworkloads.SAPVirtualInstanceProperties{
			Configuration: &armworkloads.DeploymentWithOSConfiguration{
				ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
				AppLocation:       to.Ptr("eastus"),
				InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
					AppResourceGroup: to.Ptr("X00-RG"),
					DeploymentType:   to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
					ApplicationServer: &armworkloads.ApplicationServerConfiguration{
						InstanceCount: to.Ptr[int64](6),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/dindurkhya-e2etesting/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_E32ds_v4"),
						},
					},
					CentralServer: &armworkloads.CentralServerConfiguration{
						InstanceCount: to.Ptr[int64](2),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/dindurkhya-e2etesting/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_E16ds_v4"),
						},
					},
					DatabaseServer: &armworkloads.DatabaseConfiguration{
						DatabaseType: to.Ptr(armworkloads.SAPDatabaseTypeHANA),
						DiskConfiguration: &armworkloads.DiskConfiguration{
							DiskVolumeConfigurations: map[string]*armworkloads.DiskVolumeConfiguration{
								"backup": {
									Count:  to.Ptr[int64](2),
									SizeGB: to.Ptr[int64](256),
									SKU: &armworkloads.DiskSKU{
										Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
									},
								},
								"hana/data": {
									Count:  to.Ptr[int64](4),
									SizeGB: to.Ptr[int64](128),
									SKU: &armworkloads.DiskSKU{
										Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
									},
								},
								"hana/log": {
									Count:  to.Ptr[int64](3),
									SizeGB: to.Ptr[int64](128),
									SKU: &armworkloads.DiskSKU{
										Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
									},
								},
								"hana/shared": {
									Count:  to.Ptr[int64](1),
									SizeGB: to.Ptr[int64](256),
									SKU: &armworkloads.DiskSKU{
										Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
									},
								},
								"os": {
									Count:  to.Ptr[int64](1),
									SizeGB: to.Ptr[int64](64),
									SKU: &armworkloads.DiskSKU{
										Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
									},
								},
								"usr/sap": {
									Count:  to.Ptr[int64](1),
									SizeGB: to.Ptr[int64](128),
									SKU: &armworkloads.DiskSKU{
										Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
									},
								},
							},
						},
						InstanceCount: to.Ptr[int64](2),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/dindurkhya-e2etesting/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/dbsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_M32ts"),
						},
					},
					HighAvailabilityConfig: &armworkloads.HighAvailabilityConfiguration{
						HighAvailabilityType: to.Ptr(armworkloads.SAPHighAvailabilityTypeAvailabilityZone),
					},
				},
				OSSapConfiguration: &armworkloads.OsSapConfiguration{
					SapFqdn: to.Ptr("xyz.test.com"),
				},
			},
			Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
			SapProduct:  to.Ptr(armworkloads.SAPProductTypeS4HANA),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPVirtualInstance = armworkloads.SAPVirtualInstance{
	// 	Name: to.Ptr("X00"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPVirtualInstanceProperties{
	// 		Configuration: &armworkloads.DeploymentWithOSConfiguration{
	// 			ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
	// 			AppLocation: to.Ptr("eastus"),
	// 			InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
	// 				AppResourceGroup: to.Ptr("X00-RG"),
	// 				DeploymentType: to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
	// 				ApplicationServer: &armworkloads.ApplicationServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](6),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/dindurkhya-e2etesting/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E32ds_v4"),
	// 					},
	// 				},
	// 				CentralServer: &armworkloads.CentralServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](2),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/dindurkhya-e2etesting/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E16ds_v4"),
	// 					},
	// 				},
	// 				DatabaseServer: &armworkloads.DatabaseConfiguration{
	// 					DatabaseType: to.Ptr(armworkloads.SAPDatabaseTypeHANA),
	// 					DiskConfiguration: &armworkloads.DiskConfiguration{
	// 						DiskVolumeConfigurations: map[string]*armworkloads.DiskVolumeConfiguration{
	// 							"backup": &armworkloads.DiskVolumeConfiguration{
	// 								Count: to.Ptr[int64](2),
	// 								SizeGB: to.Ptr[int64](256),
	// 								SKU: &armworkloads.DiskSKU{
	// 									Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
	// 								},
	// 							},
	// 							"hana/data": &armworkloads.DiskVolumeConfiguration{
	// 								Count: to.Ptr[int64](4),
	// 								SizeGB: to.Ptr[int64](128),
	// 								SKU: &armworkloads.DiskSKU{
	// 									Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 								},
	// 							},
	// 							"hana/log": &armworkloads.DiskVolumeConfiguration{
	// 								Count: to.Ptr[int64](3),
	// 								SizeGB: to.Ptr[int64](128),
	// 								SKU: &armworkloads.DiskSKU{
	// 									Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 								},
	// 							},
	// 							"hana/shared": &armworkloads.DiskVolumeConfiguration{
	// 								Count: to.Ptr[int64](1),
	// 								SizeGB: to.Ptr[int64](256),
	// 								SKU: &armworkloads.DiskSKU{
	// 									Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
	// 								},
	// 							},
	// 							"os": &armworkloads.DiskVolumeConfiguration{
	// 								Count: to.Ptr[int64](1),
	// 								SizeGB: to.Ptr[int64](64),
	// 								SKU: &armworkloads.DiskSKU{
	// 									Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
	// 								},
	// 							},
	// 							"usr/sap": &armworkloads.DiskVolumeConfiguration{
	// 								Count: to.Ptr[int64](1),
	// 								SizeGB: to.Ptr[int64](128),
	// 								SKU: &armworkloads.DiskSKU{
	// 									Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 								},
	// 							},
	// 						},
	// 					},
	// 					InstanceCount: to.Ptr[int64](2),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/dindurkhya-e2etesting/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/dbsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_M32ts"),
	// 					},
	// 				},
	// 				HighAvailabilityConfig: &armworkloads.HighAvailabilityConfiguration{
	// 					HighAvailabilityType: to.Ptr(armworkloads.SAPHighAvailabilityTypeAvailabilityZone),
	// 				},
	// 			},
	// 			OSSapConfiguration: &armworkloads.OsSapConfiguration{
	// 				SapFqdn: to.Ptr("xyz.test.com"),
	// 			},
	// 		},
	// 		Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
	// 		Health: to.Ptr(armworkloads.SAPHealthStateUnknown),
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		SapProduct: to.Ptr(armworkloads.SAPProductTypeS4HANA),
	// 		State: to.Ptr(armworkloads.SAPVirtualInstanceStateSoftwareInstallationPending),
	// 		Status: to.Ptr(armworkloads.SAPVirtualInstanceStatus("Unknown")),
	// 	},
	// }
}
Output:

Example (CreateInfrastructureWithDiskAndOsConfigurationsForSingleServerSystemRecommended)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPVirtualInstances_Create_DiskDetails_SingleServer.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPVirtualInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "test-rg", "X00", armworkloads.SAPVirtualInstance{
		Location: to.Ptr("westcentralus"),
		Tags:     map[string]*string{},
		Properties: &armworkloads.SAPVirtualInstanceProperties{
			Configuration: &armworkloads.DeploymentWithOSConfiguration{
				ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
				AppLocation:       to.Ptr("eastus"),
				InfrastructureConfiguration: &armworkloads.SingleServerConfiguration{
					AppResourceGroup: to.Ptr("X00-RG"),
					DeploymentType:   to.Ptr(armworkloads.SAPDeploymentTypeSingleServer),
					DatabaseType:     to.Ptr(armworkloads.SAPDatabaseTypeHANA),
					DbDiskConfiguration: &armworkloads.DiskConfiguration{
						DiskVolumeConfigurations: map[string]*armworkloads.DiskVolumeConfiguration{
							"backup": {
								Count:  to.Ptr[int64](2),
								SizeGB: to.Ptr[int64](256),
								SKU: &armworkloads.DiskSKU{
									Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
								},
							},
							"hana/data": {
								Count:  to.Ptr[int64](4),
								SizeGB: to.Ptr[int64](128),
								SKU: &armworkloads.DiskSKU{
									Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
								},
							},
							"hana/log": {
								Count:  to.Ptr[int64](3),
								SizeGB: to.Ptr[int64](128),
								SKU: &armworkloads.DiskSKU{
									Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
								},
							},
							"hana/shared": {
								Count:  to.Ptr[int64](1),
								SizeGB: to.Ptr[int64](256),
								SKU: &armworkloads.DiskSKU{
									Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
								},
							},
							"os": {
								Count:  to.Ptr[int64](1),
								SizeGB: to.Ptr[int64](64),
								SKU: &armworkloads.DiskSKU{
									Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
								},
							},
							"usr/sap": {
								Count:  to.Ptr[int64](1),
								SizeGB: to.Ptr[int64](128),
								SKU: &armworkloads.DiskSKU{
									Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
								},
							},
						},
					},
					NetworkConfiguration: &armworkloads.NetworkConfiguration{
						IsSecondaryIPEnabled: to.Ptr(true),
					},
					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/dindurkhya-e2etesting/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
						ImageReference: &armworkloads.ImageReference{
							Offer:     to.Ptr("RHEL-SAP"),
							Publisher: to.Ptr("RedHat"),
							SKU:       to.Ptr("7.4"),
							Version:   to.Ptr("7.4.2019062505"),
						},
						OSProfile: &armworkloads.OSProfile{
							AdminUsername: to.Ptr("{your-username}"),
							OSConfiguration: &armworkloads.LinuxConfiguration{
								OSType:                        to.Ptr(armworkloads.OSTypeLinux),
								DisablePasswordAuthentication: to.Ptr(true),
								SSHKeyPair: &armworkloads.SSHKeyPair{
									PrivateKey: to.Ptr("xyz"),
									PublicKey:  to.Ptr("abc"),
								},
							},
						},
						VMSize: to.Ptr("Standard_E32ds_v4"),
					},
				},
				OSSapConfiguration: &armworkloads.OsSapConfiguration{
					SapFqdn: to.Ptr("xyz.test.com"),
				},
			},
			Environment: to.Ptr(armworkloads.SAPEnvironmentTypeNonProd),
			SapProduct:  to.Ptr(armworkloads.SAPProductTypeS4HANA),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPVirtualInstance = armworkloads.SAPVirtualInstance{
	// 	Name: to.Ptr("X00"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPVirtualInstanceProperties{
	// 		Configuration: &armworkloads.DeploymentWithOSConfiguration{
	// 			ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
	// 			AppLocation: to.Ptr("eastus"),
	// 			InfrastructureConfiguration: &armworkloads.SingleServerConfiguration{
	// 				AppResourceGroup: to.Ptr("X00-RG"),
	// 				DeploymentType: to.Ptr(armworkloads.SAPDeploymentTypeSingleServer),
	// 				DatabaseType: to.Ptr(armworkloads.SAPDatabaseTypeHANA),
	// 				DbDiskConfiguration: &armworkloads.DiskConfiguration{
	// 					DiskVolumeConfigurations: map[string]*armworkloads.DiskVolumeConfiguration{
	// 						"backup": &armworkloads.DiskVolumeConfiguration{
	// 							Count: to.Ptr[int64](2),
	// 							SizeGB: to.Ptr[int64](256),
	// 							SKU: &armworkloads.DiskSKU{
	// 								Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
	// 							},
	// 						},
	// 						"hana/data": &armworkloads.DiskVolumeConfiguration{
	// 							Count: to.Ptr[int64](4),
	// 							SizeGB: to.Ptr[int64](128),
	// 							SKU: &armworkloads.DiskSKU{
	// 								Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 							},
	// 						},
	// 						"hana/log": &armworkloads.DiskVolumeConfiguration{
	// 							Count: to.Ptr[int64](3),
	// 							SizeGB: to.Ptr[int64](128),
	// 							SKU: &armworkloads.DiskSKU{
	// 								Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 							},
	// 						},
	// 						"hana/shared": &armworkloads.DiskVolumeConfiguration{
	// 							Count: to.Ptr[int64](1),
	// 							SizeGB: to.Ptr[int64](256),
	// 							SKU: &armworkloads.DiskSKU{
	// 								Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
	// 							},
	// 						},
	// 						"os": &armworkloads.DiskVolumeConfiguration{
	// 							Count: to.Ptr[int64](1),
	// 							SizeGB: to.Ptr[int64](64),
	// 							SKU: &armworkloads.DiskSKU{
	// 								Name: to.Ptr(armworkloads.DiskSKUNameStandardSSDLRS),
	// 							},
	// 						},
	// 						"usr/sap": &armworkloads.DiskVolumeConfiguration{
	// 							Count: to.Ptr[int64](1),
	// 							SizeGB: to.Ptr[int64](128),
	// 							SKU: &armworkloads.DiskSKU{
	// 								Name: to.Ptr(armworkloads.DiskSKUNamePremiumLRS),
	// 							},
	// 						},
	// 					},
	// 				},
	// 				NetworkConfiguration: &armworkloads.NetworkConfiguration{
	// 					IsSecondaryIPEnabled: to.Ptr(true),
	// 				},
	// 				SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/dindurkhya-e2etesting/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 				VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 					ImageReference: &armworkloads.ImageReference{
	// 						Offer: to.Ptr("RHEL-SAP"),
	// 						Publisher: to.Ptr("RedHat"),
	// 						SKU: to.Ptr("7.4"),
	// 						Version: to.Ptr("7.4.2019062505"),
	// 					},
	// 					OSProfile: &armworkloads.OSProfile{
	// 						AdminUsername: to.Ptr("{your-username}"),
	// 						OSConfiguration: &armworkloads.LinuxConfiguration{
	// 							OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 							DisablePasswordAuthentication: to.Ptr(true),
	// 							SSHKeyPair: &armworkloads.SSHKeyPair{
	// 								PublicKey: to.Ptr("abc"),
	// 							},
	// 						},
	// 					},
	// 					VMSize: to.Ptr("Standard_E32ds_v4"),
	// 				},
	// 			},
	// 			OSSapConfiguration: &armworkloads.OsSapConfiguration{
	// 				SapFqdn: to.Ptr("xyz.test.com"),
	// 			},
	// 		},
	// 		Environment: to.Ptr(armworkloads.SAPEnvironmentTypeNonProd),
	// 		Health: to.Ptr(armworkloads.SAPHealthStateUnknown),
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		SapProduct: to.Ptr(armworkloads.SAPProductTypeS4HANA),
	// 		State: to.Ptr(armworkloads.SAPVirtualInstanceStateSoftwareInstallationPending),
	// 		Status: to.Ptr(armworkloads.SAPVirtualInstanceStatus("Unknown")),
	// 	},
	// }
}
Output:

Example (CreateInfrastructureWithOsConfigurationForDistributedSystemRecommended)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPVirtualInstances_Create_WithOSConfig_Distributed.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPVirtualInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "test-rg", "X00", armworkloads.SAPVirtualInstance{
		Location: to.Ptr("westcentralus"),
		Tags:     map[string]*string{},
		Properties: &armworkloads.SAPVirtualInstanceProperties{
			Configuration: &armworkloads.DeploymentWithOSConfiguration{
				ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
				AppLocation:       to.Ptr("eastus"),
				InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
					AppResourceGroup: to.Ptr("X00-RG"),
					DeploymentType:   to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
					ApplicationServer: &armworkloads.ApplicationServerConfiguration{
						InstanceCount: to.Ptr[int64](6),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_E32ds_v4"),
						},
					},
					CentralServer: &armworkloads.CentralServerConfiguration{
						InstanceCount: to.Ptr[int64](1),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_E16ds_v4"),
						},
					},
					DatabaseServer: &armworkloads.DatabaseConfiguration{
						DatabaseType:  to.Ptr(armworkloads.SAPDatabaseTypeHANA),
						InstanceCount: to.Ptr[int64](1),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/dbsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_M32ts"),
						},
					},
				},
				OSSapConfiguration: &armworkloads.OsSapConfiguration{
					SapFqdn: to.Ptr("xyz.test.com"),
				},
			},
			Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
			SapProduct:  to.Ptr(armworkloads.SAPProductTypeS4HANA),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPVirtualInstance = armworkloads.SAPVirtualInstance{
	// 	Name: to.Ptr("X00"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPVirtualInstanceProperties{
	// 		Configuration: &armworkloads.DeploymentWithOSConfiguration{
	// 			ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
	// 			AppLocation: to.Ptr("eastus"),
	// 			InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
	// 				AppResourceGroup: to.Ptr("X00-RG"),
	// 				DeploymentType: to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
	// 				ApplicationServer: &armworkloads.ApplicationServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](6),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E32ds_v4"),
	// 					},
	// 				},
	// 				CentralServer: &armworkloads.CentralServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](1),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E16ds_v4"),
	// 					},
	// 				},
	// 				DatabaseServer: &armworkloads.DatabaseConfiguration{
	// 					DatabaseType: to.Ptr(armworkloads.SAPDatabaseTypeHANA),
	// 					InstanceCount: to.Ptr[int64](1),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/dbsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_M32ts"),
	// 					},
	// 				},
	// 			},
	// 			OSSapConfiguration: &armworkloads.OsSapConfiguration{
	// 				SapFqdn: to.Ptr("xyz.test.com"),
	// 			},
	// 		},
	// 		Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
	// 		Health: to.Ptr(armworkloads.SAPHealthStateUnknown),
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		SapProduct: to.Ptr(armworkloads.SAPProductTypeS4HANA),
	// 		State: to.Ptr(armworkloads.SAPVirtualInstanceStateSoftwareInstallationPending),
	// 		Status: to.Ptr(armworkloads.SAPVirtualInstanceStatus("Unknown")),
	// 	},
	// }
}
Output:

Example (CreateInfrastructureWithOsConfigurationForHaSystemWithAvailabilitySetRecommended)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPVirtualInstances_Create_WithOSConfig_HA_AvSet.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPVirtualInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "test-rg", "X00", armworkloads.SAPVirtualInstance{
		Location: to.Ptr("westcentralus"),
		Tags:     map[string]*string{},
		Properties: &armworkloads.SAPVirtualInstanceProperties{
			Configuration: &armworkloads.DeploymentWithOSConfiguration{
				ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
				AppLocation:       to.Ptr("eastus"),
				InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
					AppResourceGroup: to.Ptr("X00-RG"),
					DeploymentType:   to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
					ApplicationServer: &armworkloads.ApplicationServerConfiguration{
						InstanceCount: to.Ptr[int64](6),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_E32ds_v4"),
						},
					},
					CentralServer: &armworkloads.CentralServerConfiguration{
						InstanceCount: to.Ptr[int64](2),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_E16ds_v4"),
						},
					},
					DatabaseServer: &armworkloads.DatabaseConfiguration{
						DatabaseType:  to.Ptr(armworkloads.SAPDatabaseTypeHANA),
						InstanceCount: to.Ptr[int64](2),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/dbsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_M32ts"),
						},
					},
					HighAvailabilityConfig: &armworkloads.HighAvailabilityConfiguration{
						HighAvailabilityType: to.Ptr(armworkloads.SAPHighAvailabilityTypeAvailabilitySet),
					},
				},
				OSSapConfiguration: &armworkloads.OsSapConfiguration{
					SapFqdn: to.Ptr("xyz.test.com"),
				},
			},
			Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
			SapProduct:  to.Ptr(armworkloads.SAPProductTypeS4HANA),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPVirtualInstance = armworkloads.SAPVirtualInstance{
	// 	Name: to.Ptr("X00"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPVirtualInstanceProperties{
	// 		Configuration: &armworkloads.DeploymentWithOSConfiguration{
	// 			ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
	// 			AppLocation: to.Ptr("eastus"),
	// 			InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
	// 				AppResourceGroup: to.Ptr("X00-RG"),
	// 				DeploymentType: to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
	// 				ApplicationServer: &armworkloads.ApplicationServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](6),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E32ds_v4"),
	// 					},
	// 				},
	// 				CentralServer: &armworkloads.CentralServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](2),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E16ds_v4"),
	// 					},
	// 				},
	// 				DatabaseServer: &armworkloads.DatabaseConfiguration{
	// 					DatabaseType: to.Ptr(armworkloads.SAPDatabaseTypeHANA),
	// 					InstanceCount: to.Ptr[int64](2),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/dbsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_M32ts"),
	// 					},
	// 				},
	// 				HighAvailabilityConfig: &armworkloads.HighAvailabilityConfiguration{
	// 					HighAvailabilityType: to.Ptr(armworkloads.SAPHighAvailabilityTypeAvailabilitySet),
	// 				},
	// 			},
	// 			OSSapConfiguration: &armworkloads.OsSapConfiguration{
	// 				SapFqdn: to.Ptr("xyz.test.com"),
	// 			},
	// 		},
	// 		Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
	// 		Health: to.Ptr(armworkloads.SAPHealthStateUnknown),
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		SapProduct: to.Ptr(armworkloads.SAPProductTypeS4HANA),
	// 		State: to.Ptr(armworkloads.SAPVirtualInstanceStateSoftwareInstallationPending),
	// 		Status: to.Ptr(armworkloads.SAPVirtualInstanceStatus("Unknown")),
	// 	},
	// }
}
Output:

Example (CreateInfrastructureWithOsConfigurationForHaSystemWithAvailabilityZoneRecommended)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPVirtualInstances_Create_WithOSConfig_HA_AvZone.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPVirtualInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "test-rg", "X00", armworkloads.SAPVirtualInstance{
		Location: to.Ptr("westcentralus"),
		Tags:     map[string]*string{},
		Properties: &armworkloads.SAPVirtualInstanceProperties{
			Configuration: &armworkloads.DeploymentWithOSConfiguration{
				ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
				AppLocation:       to.Ptr("eastus"),
				InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
					AppResourceGroup: to.Ptr("X00-RG"),
					DeploymentType:   to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
					ApplicationServer: &armworkloads.ApplicationServerConfiguration{
						InstanceCount: to.Ptr[int64](6),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_E32ds_v4"),
						},
					},
					CentralServer: &armworkloads.CentralServerConfiguration{
						InstanceCount: to.Ptr[int64](2),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_E16ds_v4"),
						},
					},
					DatabaseServer: &armworkloads.DatabaseConfiguration{
						DatabaseType:  to.Ptr(armworkloads.SAPDatabaseTypeHANA),
						InstanceCount: to.Ptr[int64](2),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/dbsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_M32ts"),
						},
					},
					HighAvailabilityConfig: &armworkloads.HighAvailabilityConfiguration{
						HighAvailabilityType: to.Ptr(armworkloads.SAPHighAvailabilityTypeAvailabilityZone),
					},
				},
				OSSapConfiguration: &armworkloads.OsSapConfiguration{
					SapFqdn: to.Ptr("xyz.test.com"),
				},
			},
			Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
			SapProduct:  to.Ptr(armworkloads.SAPProductTypeS4HANA),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPVirtualInstance = armworkloads.SAPVirtualInstance{
	// 	Name: to.Ptr("X00"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPVirtualInstanceProperties{
	// 		Configuration: &armworkloads.DeploymentWithOSConfiguration{
	// 			ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
	// 			AppLocation: to.Ptr("eastus"),
	// 			InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
	// 				AppResourceGroup: to.Ptr("X00-RG"),
	// 				DeploymentType: to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
	// 				ApplicationServer: &armworkloads.ApplicationServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](6),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E32ds_v4"),
	// 					},
	// 				},
	// 				CentralServer: &armworkloads.CentralServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](2),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E16ds_v4"),
	// 					},
	// 				},
	// 				DatabaseServer: &armworkloads.DatabaseConfiguration{
	// 					DatabaseType: to.Ptr(armworkloads.SAPDatabaseTypeHANA),
	// 					InstanceCount: to.Ptr[int64](2),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/dbsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_M32ts"),
	// 					},
	// 				},
	// 				HighAvailabilityConfig: &armworkloads.HighAvailabilityConfiguration{
	// 					HighAvailabilityType: to.Ptr(armworkloads.SAPHighAvailabilityTypeAvailabilityZone),
	// 				},
	// 			},
	// 			OSSapConfiguration: &armworkloads.OsSapConfiguration{
	// 				SapFqdn: to.Ptr("xyz.test.com"),
	// 			},
	// 		},
	// 		Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
	// 		Health: to.Ptr(armworkloads.SAPHealthStateUnknown),
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		SapProduct: to.Ptr(armworkloads.SAPProductTypeS4HANA),
	// 		State: to.Ptr(armworkloads.SAPVirtualInstanceStateSoftwareInstallationPending),
	// 		Status: to.Ptr(armworkloads.SAPVirtualInstanceStatus("Unknown")),
	// 	},
	// }
}
Output:

Example (CreateInfrastructureWithOsConfigurationForSingleServerSystemRecommended)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPVirtualInstances_Create_WithOSConfig_SingleServer.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPVirtualInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "test-rg", "X00", armworkloads.SAPVirtualInstance{
		Location: to.Ptr("westcentralus"),
		Tags:     map[string]*string{},
		Properties: &armworkloads.SAPVirtualInstanceProperties{
			Configuration: &armworkloads.DeploymentWithOSConfiguration{
				ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
				AppLocation:       to.Ptr("eastus"),
				InfrastructureConfiguration: &armworkloads.SingleServerConfiguration{
					AppResourceGroup: to.Ptr("X00-RG"),
					DeploymentType:   to.Ptr(armworkloads.SAPDeploymentTypeSingleServer),
					DatabaseType:     to.Ptr(armworkloads.SAPDatabaseTypeHANA),
					NetworkConfiguration: &armworkloads.NetworkConfiguration{
						IsSecondaryIPEnabled: to.Ptr(true),
					},
					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
						ImageReference: &armworkloads.ImageReference{
							Offer:     to.Ptr("RHEL-SAP"),
							Publisher: to.Ptr("RedHat"),
							SKU:       to.Ptr("7.4"),
							Version:   to.Ptr("7.4.2019062505"),
						},
						OSProfile: &armworkloads.OSProfile{
							AdminUsername: to.Ptr("{your-username}"),
							OSConfiguration: &armworkloads.LinuxConfiguration{
								OSType:                        to.Ptr(armworkloads.OSTypeLinux),
								DisablePasswordAuthentication: to.Ptr(true),
								SSHKeyPair: &armworkloads.SSHKeyPair{
									PrivateKey: to.Ptr("xyz"),
									PublicKey:  to.Ptr("abc"),
								},
							},
						},
						VMSize: to.Ptr("Standard_E32ds_v4"),
					},
				},
				OSSapConfiguration: &armworkloads.OsSapConfiguration{
					SapFqdn: to.Ptr("xyz.test.com"),
				},
			},
			Environment: to.Ptr(armworkloads.SAPEnvironmentTypeNonProd),
			SapProduct:  to.Ptr(armworkloads.SAPProductTypeS4HANA),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPVirtualInstance = armworkloads.SAPVirtualInstance{
	// 	Name: to.Ptr("X00"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPVirtualInstanceProperties{
	// 		Configuration: &armworkloads.DeploymentWithOSConfiguration{
	// 			ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
	// 			AppLocation: to.Ptr("eastus"),
	// 			InfrastructureConfiguration: &armworkloads.SingleServerConfiguration{
	// 				AppResourceGroup: to.Ptr("X00-RG"),
	// 				DeploymentType: to.Ptr(armworkloads.SAPDeploymentTypeSingleServer),
	// 				DatabaseType: to.Ptr(armworkloads.SAPDatabaseTypeHANA),
	// 				NetworkConfiguration: &armworkloads.NetworkConfiguration{
	// 					IsSecondaryIPEnabled: to.Ptr(true),
	// 				},
	// 				SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 				VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 					ImageReference: &armworkloads.ImageReference{
	// 						Offer: to.Ptr("RHEL-SAP"),
	// 						Publisher: to.Ptr("RedHat"),
	// 						SKU: to.Ptr("7.4"),
	// 						Version: to.Ptr("7.4.2019062505"),
	// 					},
	// 					OSProfile: &armworkloads.OSProfile{
	// 						AdminUsername: to.Ptr("{your-username}"),
	// 						OSConfiguration: &armworkloads.LinuxConfiguration{
	// 							OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 							DisablePasswordAuthentication: to.Ptr(true),
	// 							SSHKeyPair: &armworkloads.SSHKeyPair{
	// 								PublicKey: to.Ptr("abc"),
	// 							},
	// 						},
	// 					},
	// 					VMSize: to.Ptr("Standard_E32ds_v4"),
	// 				},
	// 			},
	// 			OSSapConfiguration: &armworkloads.OsSapConfiguration{
	// 				SapFqdn: to.Ptr("xyz.test.com"),
	// 			},
	// 		},
	// 		Environment: to.Ptr(armworkloads.SAPEnvironmentTypeNonProd),
	// 		Health: to.Ptr(armworkloads.SAPHealthStateUnknown),
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		SapProduct: to.Ptr(armworkloads.SAPProductTypeS4HANA),
	// 		State: to.Ptr(armworkloads.SAPVirtualInstanceStateSoftwareInstallationPending),
	// 		Status: to.Ptr(armworkloads.SAPVirtualInstanceStatus("Unknown")),
	// 	},
	// }
}
Output:

Example (CreateInfrastructureWithOsConfigurationWithCustomResourceNamesForDistributedSystem)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPVirtualInstances_Create_CustomFullResourceNames_Distributed.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPVirtualInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "test-rg", "X00", armworkloads.SAPVirtualInstance{
		Location: to.Ptr("westcentralus"),
		Tags:     map[string]*string{},
		Properties: &armworkloads.SAPVirtualInstanceProperties{
			Configuration: &armworkloads.DeploymentWithOSConfiguration{
				ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
				AppLocation:       to.Ptr("eastus"),
				InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
					AppResourceGroup: to.Ptr("X00-RG"),
					DeploymentType:   to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
					ApplicationServer: &armworkloads.ApplicationServerConfiguration{
						InstanceCount: to.Ptr[int64](6),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_E32ds_v4"),
						},
					},
					CentralServer: &armworkloads.CentralServerConfiguration{
						InstanceCount: to.Ptr[int64](1),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_E16ds_v4"),
						},
					},
					CustomResourceNames: &armworkloads.ThreeTierFullResourceNames{
						NamingPatternType: to.Ptr(armworkloads.NamingPatternTypeFullResourceName),
						ApplicationServer: &armworkloads.ApplicationServerFullResourceNames{
							AvailabilitySetName: to.Ptr("appAvSet"),
							VirtualMachines: []*armworkloads.VirtualMachineResourceNames{
								{
									DataDiskNames: map[string][]*string{
										"default": {
											to.Ptr("app0disk0")},
									},
									HostName: to.Ptr("apphostName0"),
									NetworkInterfaces: []*armworkloads.NetworkInterfaceResourceNames{
										{
											NetworkInterfaceName: to.Ptr("appnic0"),
										}},
									OSDiskName: to.Ptr("app0osdisk"),
									VMName:     to.Ptr("appvm0"),
								},
								{
									DataDiskNames: map[string][]*string{
										"default": {
											to.Ptr("app1disk0")},
									},
									HostName: to.Ptr("apphostName1"),
									NetworkInterfaces: []*armworkloads.NetworkInterfaceResourceNames{
										{
											NetworkInterfaceName: to.Ptr("appnic1"),
										}},
									OSDiskName: to.Ptr("app1osdisk"),
									VMName:     to.Ptr("appvm1"),
								}},
						},
						CentralServer: &armworkloads.CentralServerFullResourceNames{
							VirtualMachines: []*armworkloads.VirtualMachineResourceNames{
								{
									DataDiskNames: map[string][]*string{
										"default": {
											to.Ptr("ascsdisk0")},
									},
									HostName: to.Ptr("ascshostName"),
									NetworkInterfaces: []*armworkloads.NetworkInterfaceResourceNames{
										{
											NetworkInterfaceName: to.Ptr("ascsnic"),
										}},
									OSDiskName: to.Ptr("ascsosdisk"),
									VMName:     to.Ptr("ascsvm"),
								}},
						},
						DatabaseServer: &armworkloads.DatabaseServerFullResourceNames{
							VirtualMachines: []*armworkloads.VirtualMachineResourceNames{
								{
									DataDiskNames: map[string][]*string{
										"hanaData": {
											to.Ptr("hanadata0"),
											to.Ptr("hanadata1")},
										"hanaLog": {
											to.Ptr("hanalog0"),
											to.Ptr("hanalog1"),
											to.Ptr("hanalog2")},
										"hanaShared": {
											to.Ptr("hanashared0"),
											to.Ptr("hanashared1")},
										"usrSap": {
											to.Ptr("usrsap0")},
									},
									HostName: to.Ptr("dbhostName"),
									NetworkInterfaces: []*armworkloads.NetworkInterfaceResourceNames{
										{
											NetworkInterfaceName: to.Ptr("dbnic"),
										}},
									OSDiskName: to.Ptr("dbosdisk"),
									VMName:     to.Ptr("dbvm"),
								}},
						},
						SharedStorage: &armworkloads.SharedStorageResourceNames{
							SharedStorageAccountName:                to.Ptr("storageacc"),
							SharedStorageAccountPrivateEndPointName: to.Ptr("peForxNFS"),
						},
					},
					DatabaseServer: &armworkloads.DatabaseConfiguration{
						DatabaseType:  to.Ptr(armworkloads.SAPDatabaseTypeHANA),
						InstanceCount: to.Ptr[int64](1),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/dbsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_M32ts"),
						},
					},
				},
				OSSapConfiguration: &armworkloads.OsSapConfiguration{
					SapFqdn: to.Ptr("xyz.test.com"),
				},
			},
			Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
			SapProduct:  to.Ptr(armworkloads.SAPProductTypeS4HANA),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPVirtualInstance = armworkloads.SAPVirtualInstance{
	// 	Name: to.Ptr("X00"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPVirtualInstanceProperties{
	// 		Configuration: &armworkloads.DeploymentWithOSConfiguration{
	// 			ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
	// 			AppLocation: to.Ptr("eastus"),
	// 			InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
	// 				AppResourceGroup: to.Ptr("X00-RG"),
	// 				DeploymentType: to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
	// 				ApplicationServer: &armworkloads.ApplicationServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](6),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E32ds_v4"),
	// 					},
	// 				},
	// 				CentralServer: &armworkloads.CentralServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](1),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E16ds_v4"),
	// 					},
	// 				},
	// 				CustomResourceNames: &armworkloads.ThreeTierFullResourceNames{
	// 					NamingPatternType: to.Ptr(armworkloads.NamingPatternTypeFullResourceName),
	// 					ApplicationServer: &armworkloads.ApplicationServerFullResourceNames{
	// 						AvailabilitySetName: to.Ptr("appAvSet"),
	// 						VirtualMachines: []*armworkloads.VirtualMachineResourceNames{
	// 							{
	// 								DataDiskNames: map[string][]*string{
	// 									"default": []*string{
	// 										to.Ptr("app0disk0")},
	// 									},
	// 									HostName: to.Ptr("apphostName0"),
	// 									NetworkInterfaces: []*armworkloads.NetworkInterfaceResourceNames{
	// 										{
	// 											NetworkInterfaceName: to.Ptr("appnic0"),
	// 									}},
	// 									OSDiskName: to.Ptr("app0osdisk"),
	// 									VMName: to.Ptr("appvm0"),
	// 								},
	// 								{
	// 									DataDiskNames: map[string][]*string{
	// 										"default": []*string{
	// 											to.Ptr("app1disk0")},
	// 										},
	// 										HostName: to.Ptr("apphostName1"),
	// 										NetworkInterfaces: []*armworkloads.NetworkInterfaceResourceNames{
	// 											{
	// 												NetworkInterfaceName: to.Ptr("appnic1"),
	// 										}},
	// 										OSDiskName: to.Ptr("app1osdisk"),
	// 										VMName: to.Ptr("appvm1"),
	// 								}},
	// 							},
	// 							CentralServer: &armworkloads.CentralServerFullResourceNames{
	// 								VirtualMachines: []*armworkloads.VirtualMachineResourceNames{
	// 									{
	// 										DataDiskNames: map[string][]*string{
	// 											"default": []*string{
	// 												to.Ptr("ascsdisk0")},
	// 											},
	// 											HostName: to.Ptr("ascshostName"),
	// 											NetworkInterfaces: []*armworkloads.NetworkInterfaceResourceNames{
	// 												{
	// 													NetworkInterfaceName: to.Ptr("ascsnic"),
	// 											}},
	// 											OSDiskName: to.Ptr("ascsosdisk"),
	// 											VMName: to.Ptr("ascsvm"),
	// 									}},
	// 								},
	// 								DatabaseServer: &armworkloads.DatabaseServerFullResourceNames{
	// 									VirtualMachines: []*armworkloads.VirtualMachineResourceNames{
	// 										{
	// 											DataDiskNames: map[string][]*string{
	// 												"hanaData": []*string{
	// 													to.Ptr("hanadata0"),
	// 													to.Ptr("hanadata1")},
	// 													"hanaLog": []*string{
	// 														to.Ptr("hanalog0"),
	// 														to.Ptr("hanalog1"),
	// 														to.Ptr("hanalog2")},
	// 														"hanaShared": []*string{
	// 															to.Ptr("hanashared0"),
	// 															to.Ptr("hanashared1")},
	// 															"usrSap": []*string{
	// 																to.Ptr("usrsap0")},
	// 															},
	// 															HostName: to.Ptr("dbhostName"),
	// 															NetworkInterfaces: []*armworkloads.NetworkInterfaceResourceNames{
	// 																{
	// 																	NetworkInterfaceName: to.Ptr("dbnic"),
	// 															}},
	// 															OSDiskName: to.Ptr("dbosdisk"),
	// 															VMName: to.Ptr("dbvm"),
	// 													}},
	// 												},
	// 												SharedStorage: &armworkloads.SharedStorageResourceNames{
	// 													SharedStorageAccountName: to.Ptr("storageacc"),
	// 													SharedStorageAccountPrivateEndPointName: to.Ptr("peForxNFS"),
	// 												},
	// 											},
	// 											DatabaseServer: &armworkloads.DatabaseConfiguration{
	// 												DatabaseType: to.Ptr(armworkloads.SAPDatabaseTypeHANA),
	// 												InstanceCount: to.Ptr[int64](1),
	// 												SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/dbsubnet"),
	// 												VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 													ImageReference: &armworkloads.ImageReference{
	// 														Offer: to.Ptr("RHEL-SAP"),
	// 														Publisher: to.Ptr("RedHat"),
	// 														SKU: to.Ptr("7.4"),
	// 														Version: to.Ptr("7.4.2019062505"),
	// 													},
	// 													OSProfile: &armworkloads.OSProfile{
	// 														AdminUsername: to.Ptr("{your-username}"),
	// 														OSConfiguration: &armworkloads.LinuxConfiguration{
	// 															OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 															DisablePasswordAuthentication: to.Ptr(true),
	// 															SSHKeyPair: &armworkloads.SSHKeyPair{
	// 																PublicKey: to.Ptr("abc"),
	// 															},
	// 														},
	// 													},
	// 													VMSize: to.Ptr("Standard_M32ts"),
	// 												},
	// 											},
	// 										},
	// 										OSSapConfiguration: &armworkloads.OsSapConfiguration{
	// 											SapFqdn: to.Ptr("xyz.test.com"),
	// 										},
	// 									},
	// 									Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
	// 									Health: to.Ptr(armworkloads.SAPHealthStateUnknown),
	// 									ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 									SapProduct: to.Ptr(armworkloads.SAPProductTypeS4HANA),
	// 									State: to.Ptr(armworkloads.SAPVirtualInstanceStateSoftwareInstallationPending),
	// 									Status: to.Ptr(armworkloads.SAPVirtualInstanceStatus("Unknown")),
	// 								},
	// 							}
}
Output:

Example (CreateInfrastructureWithOsConfigurationWithCustomResourceNamesForHaSystemWithAvailabilitySet)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPVirtualInstances_Create_CustomFullResourceNames_HA_AvSet.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPVirtualInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "test-rg", "X00", armworkloads.SAPVirtualInstance{
		Location: to.Ptr("westcentralus"),
		Tags:     map[string]*string{},
		Properties: &armworkloads.SAPVirtualInstanceProperties{
			Configuration: &armworkloads.DeploymentWithOSConfiguration{
				ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
				AppLocation:       to.Ptr("eastus"),
				InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
					AppResourceGroup: to.Ptr("X00-RG"),
					DeploymentType:   to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
					ApplicationServer: &armworkloads.ApplicationServerConfiguration{
						InstanceCount: to.Ptr[int64](6),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_E32ds_v4"),
						},
					},
					CentralServer: &armworkloads.CentralServerConfiguration{
						InstanceCount: to.Ptr[int64](2),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_E16ds_v4"),
						},
					},
					CustomResourceNames: &armworkloads.ThreeTierFullResourceNames{
						NamingPatternType: to.Ptr(armworkloads.NamingPatternTypeFullResourceName),
						ApplicationServer: &armworkloads.ApplicationServerFullResourceNames{
							AvailabilitySetName: to.Ptr("appAvSet"),
							VirtualMachines: []*armworkloads.VirtualMachineResourceNames{
								{
									DataDiskNames: map[string][]*string{
										"default": {
											to.Ptr("app0disk0")},
									},
									HostName: to.Ptr("apphostName0"),
									NetworkInterfaces: []*armworkloads.NetworkInterfaceResourceNames{
										{
											NetworkInterfaceName: to.Ptr("appnic0"),
										}},
									OSDiskName: to.Ptr("app0osdisk"),
									VMName:     to.Ptr("appvm0"),
								},
								{
									DataDiskNames: map[string][]*string{
										"default": {
											to.Ptr("app1disk0")},
									},
									HostName: to.Ptr("apphostName1"),
									NetworkInterfaces: []*armworkloads.NetworkInterfaceResourceNames{
										{
											NetworkInterfaceName: to.Ptr("appnic1"),
										}},
									OSDiskName: to.Ptr("app1osdisk"),
									VMName:     to.Ptr("appvm1"),
								}},
						},
						CentralServer: &armworkloads.CentralServerFullResourceNames{
							AvailabilitySetName: to.Ptr("csAvSet"),
							LoadBalancer: &armworkloads.LoadBalancerResourceNames{
								BackendPoolNames: []*string{
									to.Ptr("ascsBackendPool")},
								FrontendIPConfigurationNames: []*string{
									to.Ptr("ascsip0"),
									to.Ptr("ersip0")},
								HealthProbeNames: []*string{
									to.Ptr("ascsHealthProbe"),
									to.Ptr("ersHealthProbe")},
								LoadBalancerName: to.Ptr("ascslb"),
							},
							VirtualMachines: []*armworkloads.VirtualMachineResourceNames{
								{
									HostName: to.Ptr("ascshostName"),
									NetworkInterfaces: []*armworkloads.NetworkInterfaceResourceNames{
										{
											NetworkInterfaceName: to.Ptr("ascsnic"),
										}},
									OSDiskName: to.Ptr("ascsosdisk"),
									VMName:     to.Ptr("ascsvm"),
								},
								{
									HostName: to.Ptr("ershostName"),
									NetworkInterfaces: []*armworkloads.NetworkInterfaceResourceNames{
										{
											NetworkInterfaceName: to.Ptr("ersnic"),
										}},
									OSDiskName: to.Ptr("ersosdisk"),
									VMName:     to.Ptr("ersvm"),
								}},
						},
						DatabaseServer: &armworkloads.DatabaseServerFullResourceNames{
							AvailabilitySetName: to.Ptr("dbAvSet"),
							LoadBalancer: &armworkloads.LoadBalancerResourceNames{
								BackendPoolNames: []*string{
									to.Ptr("dbBackendPool")},
								FrontendIPConfigurationNames: []*string{
									to.Ptr("dbip")},
								HealthProbeNames: []*string{
									to.Ptr("dbHealthProbe")},
								LoadBalancerName: to.Ptr("dblb"),
							},
							VirtualMachines: []*armworkloads.VirtualMachineResourceNames{
								{
									DataDiskNames: map[string][]*string{
										"hanaData": {
											to.Ptr("hanadatapr0"),
											to.Ptr("hanadatapr1")},
										"hanaLog": {
											to.Ptr("hanalogpr0"),
											to.Ptr("hanalogpr1"),
											to.Ptr("hanalogpr2")},
										"hanaShared": {
											to.Ptr("hanasharedpr0"),
											to.Ptr("hanasharedpr1")},
										"usrSap": {
											to.Ptr("usrsappr0")},
									},
									HostName: to.Ptr("dbprhostName"),
									NetworkInterfaces: []*armworkloads.NetworkInterfaceResourceNames{
										{
											NetworkInterfaceName: to.Ptr("dbprnic"),
										}},
									OSDiskName: to.Ptr("dbprosdisk"),
									VMName:     to.Ptr("dbvmpr"),
								},
								{
									DataDiskNames: map[string][]*string{
										"hanaData": {
											to.Ptr("hanadatasr0"),
											to.Ptr("hanadatasr1")},
										"hanaLog": {
											to.Ptr("hanalogsr0"),
											to.Ptr("hanalogsr1"),
											to.Ptr("hanalogsr2")},
										"hanaShared": {
											to.Ptr("hanasharedsr0"),
											to.Ptr("hanasharedsr1")},
										"usrSap": {
											to.Ptr("usrsapsr0")},
									},
									HostName: to.Ptr("dbsrhostName"),
									NetworkInterfaces: []*armworkloads.NetworkInterfaceResourceNames{
										{
											NetworkInterfaceName: to.Ptr("dbsrnic"),
										}},
									OSDiskName: to.Ptr("dbsrosdisk"),
									VMName:     to.Ptr("dbvmsr"),
								}},
						},
						SharedStorage: &armworkloads.SharedStorageResourceNames{
							SharedStorageAccountName:                to.Ptr("storageacc"),
							SharedStorageAccountPrivateEndPointName: to.Ptr("peForxNFS"),
						},
					},
					DatabaseServer: &armworkloads.DatabaseConfiguration{
						DatabaseType:  to.Ptr(armworkloads.SAPDatabaseTypeHANA),
						InstanceCount: to.Ptr[int64](2),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/dbsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_M32ts"),
						},
					},
					HighAvailabilityConfig: &armworkloads.HighAvailabilityConfiguration{
						HighAvailabilityType: to.Ptr(armworkloads.SAPHighAvailabilityTypeAvailabilitySet),
					},
				},
				OSSapConfiguration: &armworkloads.OsSapConfiguration{
					SapFqdn: to.Ptr("xyz.test.com"),
				},
			},
			Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
			SapProduct:  to.Ptr(armworkloads.SAPProductTypeS4HANA),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPVirtualInstance = armworkloads.SAPVirtualInstance{
	// 	Name: to.Ptr("X00"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPVirtualInstanceProperties{
	// 		Configuration: &armworkloads.DeploymentWithOSConfiguration{
	// 			ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
	// 			AppLocation: to.Ptr("eastus"),
	// 			InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
	// 				AppResourceGroup: to.Ptr("X00-RG"),
	// 				DeploymentType: to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
	// 				ApplicationServer: &armworkloads.ApplicationServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](6),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E32ds_v4"),
	// 					},
	// 				},
	// 				CentralServer: &armworkloads.CentralServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](2),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E16ds_v4"),
	// 					},
	// 				},
	// 				CustomResourceNames: &armworkloads.ThreeTierFullResourceNames{
	// 					NamingPatternType: to.Ptr(armworkloads.NamingPatternTypeFullResourceName),
	// 					ApplicationServer: &armworkloads.ApplicationServerFullResourceNames{
	// 						AvailabilitySetName: to.Ptr("appAvSet"),
	// 						VirtualMachines: []*armworkloads.VirtualMachineResourceNames{
	// 							{
	// 								DataDiskNames: map[string][]*string{
	// 									"default": []*string{
	// 										to.Ptr("app0disk0")},
	// 									},
	// 									HostName: to.Ptr("apphostName0"),
	// 									NetworkInterfaces: []*armworkloads.NetworkInterfaceResourceNames{
	// 										{
	// 											NetworkInterfaceName: to.Ptr("appnic0"),
	// 									}},
	// 									OSDiskName: to.Ptr("app0osdisk"),
	// 									VMName: to.Ptr("appvm0"),
	// 								},
	// 								{
	// 									DataDiskNames: map[string][]*string{
	// 										"default": []*string{
	// 											to.Ptr("app1disk0")},
	// 										},
	// 										HostName: to.Ptr("apphostName1"),
	// 										NetworkInterfaces: []*armworkloads.NetworkInterfaceResourceNames{
	// 											{
	// 												NetworkInterfaceName: to.Ptr("appnic1"),
	// 										}},
	// 										OSDiskName: to.Ptr("app1osdisk"),
	// 										VMName: to.Ptr("appvm1"),
	// 								}},
	// 							},
	// 							CentralServer: &armworkloads.CentralServerFullResourceNames{
	// 								AvailabilitySetName: to.Ptr("csAvSet"),
	// 								LoadBalancer: &armworkloads.LoadBalancerResourceNames{
	// 									BackendPoolNames: []*string{
	// 										to.Ptr("ascsBackendPool")},
	// 										FrontendIPConfigurationNames: []*string{
	// 											to.Ptr("ascsip0"),
	// 											to.Ptr("ersip0")},
	// 											HealthProbeNames: []*string{
	// 												to.Ptr("ascsHealthProbe"),
	// 												to.Ptr("ersHealthProbe")},
	// 												LoadBalancerName: to.Ptr("ascslb"),
	// 											},
	// 											VirtualMachines: []*armworkloads.VirtualMachineResourceNames{
	// 												{
	// 													HostName: to.Ptr("ascshostName"),
	// 													NetworkInterfaces: []*armworkloads.NetworkInterfaceResourceNames{
	// 														{
	// 															NetworkInterfaceName: to.Ptr("ascsnic"),
	// 													}},
	// 													OSDiskName: to.Ptr("ascsosdisk"),
	// 													VMName: to.Ptr("ascsvm"),
	// 												},
	// 												{
	// 													HostName: to.Ptr("ershostName"),
	// 													NetworkInterfaces: []*armworkloads.NetworkInterfaceResourceNames{
	// 														{
	// 															NetworkInterfaceName: to.Ptr("ersnic"),
	// 													}},
	// 													OSDiskName: to.Ptr("ersosdisk"),
	// 													VMName: to.Ptr("ersvm"),
	// 											}},
	// 										},
	// 										DatabaseServer: &armworkloads.DatabaseServerFullResourceNames{
	// 											AvailabilitySetName: to.Ptr("dbAvSet"),
	// 											LoadBalancer: &armworkloads.LoadBalancerResourceNames{
	// 												BackendPoolNames: []*string{
	// 													to.Ptr("dbBackendPool")},
	// 													FrontendIPConfigurationNames: []*string{
	// 														to.Ptr("dbip")},
	// 														HealthProbeNames: []*string{
	// 															to.Ptr("dbHealthProbe")},
	// 															LoadBalancerName: to.Ptr("dblb"),
	// 														},
	// 														VirtualMachines: []*armworkloads.VirtualMachineResourceNames{
	// 															{
	// 																DataDiskNames: map[string][]*string{
	// 																	"hanaData": []*string{
	// 																		to.Ptr("hanadatapr0"),
	// 																		to.Ptr("hanadatapr1")},
	// 																		"hanaLog": []*string{
	// 																			to.Ptr("hanalogpr0"),
	// 																			to.Ptr("hanalogpr1"),
	// 																			to.Ptr("hanalogpr2")},
	// 																			"hanaShared": []*string{
	// 																				to.Ptr("hanasharedpr0"),
	// 																				to.Ptr("hanasharedpr1")},
	// 																				"usrSap": []*string{
	// 																					to.Ptr("usrsappr0")},
	// 																				},
	// 																				HostName: to.Ptr("dbprhostName"),
	// 																				NetworkInterfaces: []*armworkloads.NetworkInterfaceResourceNames{
	// 																					{
	// 																						NetworkInterfaceName: to.Ptr("dbprnic"),
	// 																				}},
	// 																				OSDiskName: to.Ptr("dbprosdisk"),
	// 																				VMName: to.Ptr("dbvmpr"),
	// 																			},
	// 																			{
	// 																				DataDiskNames: map[string][]*string{
	// 																					"hanaData": []*string{
	// 																						to.Ptr("hanadatasr0"),
	// 																						to.Ptr("hanadatasr1")},
	// 																						"hanaLog": []*string{
	// 																							to.Ptr("hanalogsr0"),
	// 																							to.Ptr("hanalogsr1"),
	// 																							to.Ptr("hanalogsr2")},
	// 																							"hanaShared": []*string{
	// 																								to.Ptr("hanasharedsr0"),
	// 																								to.Ptr("hanasharedsr1")},
	// 																								"usrSap": []*string{
	// 																									to.Ptr("usrsapsr0")},
	// 																								},
	// 																								HostName: to.Ptr("dbsrhostName"),
	// 																								NetworkInterfaces: []*armworkloads.NetworkInterfaceResourceNames{
	// 																									{
	// 																										NetworkInterfaceName: to.Ptr("dbsrnic"),
	// 																								}},
	// 																								OSDiskName: to.Ptr("dbsrosdisk"),
	// 																								VMName: to.Ptr("dbvmsr"),
	// 																						}},
	// 																					},
	// 																					SharedStorage: &armworkloads.SharedStorageResourceNames{
	// 																						SharedStorageAccountName: to.Ptr("storageacc"),
	// 																						SharedStorageAccountPrivateEndPointName: to.Ptr("peForxNFS"),
	// 																					},
	// 																				},
	// 																				DatabaseServer: &armworkloads.DatabaseConfiguration{
	// 																					DatabaseType: to.Ptr(armworkloads.SAPDatabaseTypeHANA),
	// 																					InstanceCount: to.Ptr[int64](2),
	// 																					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/dbsubnet"),
	// 																					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 																						ImageReference: &armworkloads.ImageReference{
	// 																							Offer: to.Ptr("RHEL-SAP"),
	// 																							Publisher: to.Ptr("RedHat"),
	// 																							SKU: to.Ptr("7.4"),
	// 																							Version: to.Ptr("7.4.2019062505"),
	// 																						},
	// 																						OSProfile: &armworkloads.OSProfile{
	// 																							AdminUsername: to.Ptr("{your-username}"),
	// 																							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 																								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 																								DisablePasswordAuthentication: to.Ptr(true),
	// 																								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 																									PublicKey: to.Ptr("abc"),
	// 																								},
	// 																							},
	// 																						},
	// 																						VMSize: to.Ptr("Standard_M32ts"),
	// 																					},
	// 																				},
	// 																				HighAvailabilityConfig: &armworkloads.HighAvailabilityConfiguration{
	// 																					HighAvailabilityType: to.Ptr(armworkloads.SAPHighAvailabilityTypeAvailabilitySet),
	// 																				},
	// 																			},
	// 																			OSSapConfiguration: &armworkloads.OsSapConfiguration{
	// 																				SapFqdn: to.Ptr("xyz.test.com"),
	// 																			},
	// 																		},
	// 																		Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
	// 																		Health: to.Ptr(armworkloads.SAPHealthStateUnknown),
	// 																		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 																		SapProduct: to.Ptr(armworkloads.SAPProductTypeS4HANA),
	// 																		State: to.Ptr(armworkloads.SAPVirtualInstanceStateSoftwareInstallationPending),
	// 																		Status: to.Ptr(armworkloads.SAPVirtualInstanceStatus("Unknown")),
	// 																	},
	// 																}
}
Output:

Example (CreateInfrastructureWithOsConfigurationWithCustomResourceNamesForHaSystemWithAvailabilityZone)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPVirtualInstances_Create_CustomFullResourceNames_HA_AvZone.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPVirtualInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "test-rg", "X00", armworkloads.SAPVirtualInstance{
		Location: to.Ptr("westcentralus"),
		Tags:     map[string]*string{},
		Properties: &armworkloads.SAPVirtualInstanceProperties{
			Configuration: &armworkloads.DeploymentWithOSConfiguration{
				ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
				AppLocation:       to.Ptr("eastus"),
				InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
					AppResourceGroup: to.Ptr("X00-RG"),
					DeploymentType:   to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
					ApplicationServer: &armworkloads.ApplicationServerConfiguration{
						InstanceCount: to.Ptr[int64](6),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_E32ds_v4"),
						},
					},
					CentralServer: &armworkloads.CentralServerConfiguration{
						InstanceCount: to.Ptr[int64](2),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_E16ds_v4"),
						},
					},
					CustomResourceNames: &armworkloads.ThreeTierFullResourceNames{
						NamingPatternType: to.Ptr(armworkloads.NamingPatternTypeFullResourceName),
						ApplicationServer: &armworkloads.ApplicationServerFullResourceNames{
							VirtualMachines: []*armworkloads.VirtualMachineResourceNames{
								{
									DataDiskNames: map[string][]*string{
										"default": {
											to.Ptr("app0disk0")},
									},
									HostName: to.Ptr("apphostName0"),
									NetworkInterfaces: []*armworkloads.NetworkInterfaceResourceNames{
										{
											NetworkInterfaceName: to.Ptr("appnic0"),
										}},
									OSDiskName: to.Ptr("app0osdisk"),
									VMName:     to.Ptr("appvm0"),
								},
								{
									DataDiskNames: map[string][]*string{
										"default": {
											to.Ptr("app1disk0")},
									},
									HostName: to.Ptr("apphostName1"),
									NetworkInterfaces: []*armworkloads.NetworkInterfaceResourceNames{
										{
											NetworkInterfaceName: to.Ptr("appnic1"),
										}},
									OSDiskName: to.Ptr("app1osdisk"),
									VMName:     to.Ptr("appvm1"),
								}},
						},
						CentralServer: &armworkloads.CentralServerFullResourceNames{
							LoadBalancer: &armworkloads.LoadBalancerResourceNames{
								BackendPoolNames: []*string{
									to.Ptr("ascsBackendPool")},
								FrontendIPConfigurationNames: []*string{
									to.Ptr("ascsip0"),
									to.Ptr("ersip0")},
								HealthProbeNames: []*string{
									to.Ptr("ascsHealthProbe"),
									to.Ptr("ersHealthProbe")},
								LoadBalancerName: to.Ptr("ascslb"),
							},
							VirtualMachines: []*armworkloads.VirtualMachineResourceNames{
								{
									HostName: to.Ptr("ascshostName"),
									NetworkInterfaces: []*armworkloads.NetworkInterfaceResourceNames{
										{
											NetworkInterfaceName: to.Ptr("ascsnic"),
										}},
									OSDiskName: to.Ptr("ascsosdisk"),
									VMName:     to.Ptr("ascsvm"),
								},
								{
									HostName: to.Ptr("ershostName"),
									NetworkInterfaces: []*armworkloads.NetworkInterfaceResourceNames{
										{
											NetworkInterfaceName: to.Ptr("ersnic"),
										}},
									OSDiskName: to.Ptr("ersosdisk"),
									VMName:     to.Ptr("ersvm"),
								}},
						},
						DatabaseServer: &armworkloads.DatabaseServerFullResourceNames{
							LoadBalancer: &armworkloads.LoadBalancerResourceNames{
								BackendPoolNames: []*string{
									to.Ptr("dbBackendPool")},
								FrontendIPConfigurationNames: []*string{
									to.Ptr("dbip")},
								HealthProbeNames: []*string{
									to.Ptr("dbHealthProbe")},
								LoadBalancerName: to.Ptr("dblb"),
							},
							VirtualMachines: []*armworkloads.VirtualMachineResourceNames{
								{
									DataDiskNames: map[string][]*string{
										"hanaData": {
											to.Ptr("hanadatapr0"),
											to.Ptr("hanadatapr1")},
										"hanaLog": {
											to.Ptr("hanalogpr0"),
											to.Ptr("hanalogpr1"),
											to.Ptr("hanalogpr2")},
										"hanaShared": {
											to.Ptr("hanasharedpr0"),
											to.Ptr("hanasharedpr1")},
										"usrSap": {
											to.Ptr("usrsappr0")},
									},
									HostName: to.Ptr("dbprhostName"),
									NetworkInterfaces: []*armworkloads.NetworkInterfaceResourceNames{
										{
											NetworkInterfaceName: to.Ptr("dbprnic"),
										}},
									OSDiskName: to.Ptr("dbprosdisk"),
									VMName:     to.Ptr("dbvmpr"),
								},
								{
									DataDiskNames: map[string][]*string{
										"hanaData": {
											to.Ptr("hanadatasr0"),
											to.Ptr("hanadatasr1")},
										"hanaLog": {
											to.Ptr("hanalogsr0"),
											to.Ptr("hanalogsr1"),
											to.Ptr("hanalogsr2")},
										"hanaShared": {
											to.Ptr("hanasharedsr0"),
											to.Ptr("hanasharedsr1")},
										"usrSap": {
											to.Ptr("usrsapsr0")},
									},
									HostName: to.Ptr("dbsrhostName"),
									NetworkInterfaces: []*armworkloads.NetworkInterfaceResourceNames{
										{
											NetworkInterfaceName: to.Ptr("dbsrnic"),
										}},
									OSDiskName: to.Ptr("dbsrosdisk"),
									VMName:     to.Ptr("dbvmsr"),
								}},
						},
						SharedStorage: &armworkloads.SharedStorageResourceNames{
							SharedStorageAccountName:                to.Ptr("storageacc"),
							SharedStorageAccountPrivateEndPointName: to.Ptr("peForxNFS"),
						},
					},
					DatabaseServer: &armworkloads.DatabaseConfiguration{
						DatabaseType:  to.Ptr(armworkloads.SAPDatabaseTypeHANA),
						InstanceCount: to.Ptr[int64](2),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/dbsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_M32ts"),
						},
					},
					HighAvailabilityConfig: &armworkloads.HighAvailabilityConfiguration{
						HighAvailabilityType: to.Ptr(armworkloads.SAPHighAvailabilityTypeAvailabilityZone),
					},
				},
				OSSapConfiguration: &armworkloads.OsSapConfiguration{
					SapFqdn: to.Ptr("xyz.test.com"),
				},
			},
			Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
			SapProduct:  to.Ptr(armworkloads.SAPProductTypeS4HANA),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPVirtualInstance = armworkloads.SAPVirtualInstance{
	// 	Name: to.Ptr("X00"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPVirtualInstanceProperties{
	// 		Configuration: &armworkloads.DeploymentWithOSConfiguration{
	// 			ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
	// 			AppLocation: to.Ptr("eastus"),
	// 			InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
	// 				AppResourceGroup: to.Ptr("X00-RG"),
	// 				DeploymentType: to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
	// 				ApplicationServer: &armworkloads.ApplicationServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](6),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E32ds_v4"),
	// 					},
	// 				},
	// 				CentralServer: &armworkloads.CentralServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](2),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E16ds_v4"),
	// 					},
	// 				},
	// 				CustomResourceNames: &armworkloads.ThreeTierFullResourceNames{
	// 					NamingPatternType: to.Ptr(armworkloads.NamingPatternTypeFullResourceName),
	// 					ApplicationServer: &armworkloads.ApplicationServerFullResourceNames{
	// 						VirtualMachines: []*armworkloads.VirtualMachineResourceNames{
	// 							{
	// 								DataDiskNames: map[string][]*string{
	// 									"default": []*string{
	// 										to.Ptr("app0disk0")},
	// 									},
	// 									HostName: to.Ptr("apphostName0"),
	// 									NetworkInterfaces: []*armworkloads.NetworkInterfaceResourceNames{
	// 										{
	// 											NetworkInterfaceName: to.Ptr("appnic0"),
	// 									}},
	// 									OSDiskName: to.Ptr("app0osdisk"),
	// 									VMName: to.Ptr("appvm0"),
	// 								},
	// 								{
	// 									DataDiskNames: map[string][]*string{
	// 										"default": []*string{
	// 											to.Ptr("app1disk0")},
	// 										},
	// 										HostName: to.Ptr("apphostName1"),
	// 										NetworkInterfaces: []*armworkloads.NetworkInterfaceResourceNames{
	// 											{
	// 												NetworkInterfaceName: to.Ptr("appnic1"),
	// 										}},
	// 										OSDiskName: to.Ptr("app1osdisk"),
	// 										VMName: to.Ptr("appvm1"),
	// 								}},
	// 							},
	// 							CentralServer: &armworkloads.CentralServerFullResourceNames{
	// 								LoadBalancer: &armworkloads.LoadBalancerResourceNames{
	// 									BackendPoolNames: []*string{
	// 										to.Ptr("ascsBackendPool")},
	// 										FrontendIPConfigurationNames: []*string{
	// 											to.Ptr("ascsip0"),
	// 											to.Ptr("ersip0")},
	// 											HealthProbeNames: []*string{
	// 												to.Ptr("ascsHealthProbe"),
	// 												to.Ptr("ersHealthProbe")},
	// 												LoadBalancerName: to.Ptr("ascslb"),
	// 											},
	// 											VirtualMachines: []*armworkloads.VirtualMachineResourceNames{
	// 												{
	// 													HostName: to.Ptr("ascshostName"),
	// 													NetworkInterfaces: []*armworkloads.NetworkInterfaceResourceNames{
	// 														{
	// 															NetworkInterfaceName: to.Ptr("ascsnic"),
	// 													}},
	// 													OSDiskName: to.Ptr("ascsosdisk"),
	// 													VMName: to.Ptr("ascsvm"),
	// 												},
	// 												{
	// 													HostName: to.Ptr("ershostName"),
	// 													NetworkInterfaces: []*armworkloads.NetworkInterfaceResourceNames{
	// 														{
	// 															NetworkInterfaceName: to.Ptr("ersnic"),
	// 													}},
	// 													OSDiskName: to.Ptr("ersosdisk"),
	// 													VMName: to.Ptr("ersvm"),
	// 											}},
	// 										},
	// 										DatabaseServer: &armworkloads.DatabaseServerFullResourceNames{
	// 											LoadBalancer: &armworkloads.LoadBalancerResourceNames{
	// 												BackendPoolNames: []*string{
	// 													to.Ptr("dbBackendPool")},
	// 													FrontendIPConfigurationNames: []*string{
	// 														to.Ptr("dbip")},
	// 														HealthProbeNames: []*string{
	// 															to.Ptr("dbHealthProbe")},
	// 															LoadBalancerName: to.Ptr("dblb"),
	// 														},
	// 														VirtualMachines: []*armworkloads.VirtualMachineResourceNames{
	// 															{
	// 																DataDiskNames: map[string][]*string{
	// 																	"hanaData": []*string{
	// 																		to.Ptr("hanadatapr0"),
	// 																		to.Ptr("hanadatapr1")},
	// 																		"hanaLog": []*string{
	// 																			to.Ptr("hanalogpr0"),
	// 																			to.Ptr("hanalogpr1"),
	// 																			to.Ptr("hanalogpr2")},
	// 																			"hanaShared": []*string{
	// 																				to.Ptr("hanasharedpr0"),
	// 																				to.Ptr("hanasharedpr1")},
	// 																				"usrSap": []*string{
	// 																					to.Ptr("usrsappr0")},
	// 																				},
	// 																				HostName: to.Ptr("dbprhostName"),
	// 																				NetworkInterfaces: []*armworkloads.NetworkInterfaceResourceNames{
	// 																					{
	// 																						NetworkInterfaceName: to.Ptr("dbprnic"),
	// 																				}},
	// 																				OSDiskName: to.Ptr("dbprosdisk"),
	// 																				VMName: to.Ptr("dbvmpr"),
	// 																			},
	// 																			{
	// 																				DataDiskNames: map[string][]*string{
	// 																					"hanaData": []*string{
	// 																						to.Ptr("hanadatasr0"),
	// 																						to.Ptr("hanadatasr1")},
	// 																						"hanaLog": []*string{
	// 																							to.Ptr("hanalogsr0"),
	// 																							to.Ptr("hanalogsr1"),
	// 																							to.Ptr("hanalogsr2")},
	// 																							"hanaShared": []*string{
	// 																								to.Ptr("hanasharedsr0"),
	// 																								to.Ptr("hanasharedsr1")},
	// 																								"usrSap": []*string{
	// 																									to.Ptr("usrsapsr0")},
	// 																								},
	// 																								HostName: to.Ptr("dbsrhostName"),
	// 																								NetworkInterfaces: []*armworkloads.NetworkInterfaceResourceNames{
	// 																									{
	// 																										NetworkInterfaceName: to.Ptr("dbsrnic"),
	// 																								}},
	// 																								OSDiskName: to.Ptr("dbsrosdisk"),
	// 																								VMName: to.Ptr("dbvmsr"),
	// 																						}},
	// 																					},
	// 																					SharedStorage: &armworkloads.SharedStorageResourceNames{
	// 																						SharedStorageAccountName: to.Ptr("storageacc"),
	// 																						SharedStorageAccountPrivateEndPointName: to.Ptr("peForxNFS"),
	// 																					},
	// 																				},
	// 																				DatabaseServer: &armworkloads.DatabaseConfiguration{
	// 																					DatabaseType: to.Ptr(armworkloads.SAPDatabaseTypeHANA),
	// 																					InstanceCount: to.Ptr[int64](2),
	// 																					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/dbsubnet"),
	// 																					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 																						ImageReference: &armworkloads.ImageReference{
	// 																							Offer: to.Ptr("RHEL-SAP"),
	// 																							Publisher: to.Ptr("RedHat"),
	// 																							SKU: to.Ptr("7.4"),
	// 																							Version: to.Ptr("7.4.2019062505"),
	// 																						},
	// 																						OSProfile: &armworkloads.OSProfile{
	// 																							AdminUsername: to.Ptr("{your-username}"),
	// 																							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 																								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 																								DisablePasswordAuthentication: to.Ptr(true),
	// 																								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 																									PublicKey: to.Ptr("abc"),
	// 																								},
	// 																							},
	// 																						},
	// 																						VMSize: to.Ptr("Standard_M32ts"),
	// 																					},
	// 																				},
	// 																				HighAvailabilityConfig: &armworkloads.HighAvailabilityConfiguration{
	// 																					HighAvailabilityType: to.Ptr(armworkloads.SAPHighAvailabilityTypeAvailabilityZone),
	// 																				},
	// 																			},
	// 																			OSSapConfiguration: &armworkloads.OsSapConfiguration{
	// 																				SapFqdn: to.Ptr("xyz.test.com"),
	// 																			},
	// 																		},
	// 																		Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
	// 																		Health: to.Ptr(armworkloads.SAPHealthStateUnknown),
	// 																		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 																		SapProduct: to.Ptr(armworkloads.SAPProductTypeS4HANA),
	// 																		State: to.Ptr(armworkloads.SAPVirtualInstanceStateSoftwareInstallationPending),
	// 																		Status: to.Ptr(armworkloads.SAPVirtualInstanceStatus("Unknown")),
	// 																	},
	// 																}
}
Output:

Example (CreateInfrastructureWithOsConfigurationWithCustomResourceNamesForSingleServerSystem)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPVirtualInstances_Create_CustomFullResourceNames_SingleServer.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPVirtualInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "test-rg", "X00", armworkloads.SAPVirtualInstance{
		Location: to.Ptr("westcentralus"),
		Tags:     map[string]*string{},
		Properties: &armworkloads.SAPVirtualInstanceProperties{
			Configuration: &armworkloads.DeploymentWithOSConfiguration{
				ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
				AppLocation:       to.Ptr("eastus"),
				InfrastructureConfiguration: &armworkloads.SingleServerConfiguration{
					AppResourceGroup: to.Ptr("X00-RG"),
					DeploymentType:   to.Ptr(armworkloads.SAPDeploymentTypeSingleServer),
					DatabaseType:     to.Ptr(armworkloads.SAPDatabaseTypeHANA),
					NetworkConfiguration: &armworkloads.NetworkConfiguration{
						IsSecondaryIPEnabled: to.Ptr(true),
					},
					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
						ImageReference: &armworkloads.ImageReference{
							Offer:     to.Ptr("RHEL-SAP"),
							Publisher: to.Ptr("RedHat"),
							SKU:       to.Ptr("7.4"),
							Version:   to.Ptr("7.4.2019062505"),
						},
						OSProfile: &armworkloads.OSProfile{
							AdminUsername: to.Ptr("{your-username}"),
							OSConfiguration: &armworkloads.LinuxConfiguration{
								OSType:                        to.Ptr(armworkloads.OSTypeLinux),
								DisablePasswordAuthentication: to.Ptr(true),
								SSHKeyPair: &armworkloads.SSHKeyPair{
									PrivateKey: to.Ptr("xyz"),
									PublicKey:  to.Ptr("abc"),
								},
							},
						},
						VMSize: to.Ptr("Standard_E32ds_v4"),
					},
				},
				OSSapConfiguration: &armworkloads.OsSapConfiguration{
					SapFqdn: to.Ptr("xyz.test.com"),
				},
			},
			Environment: to.Ptr(armworkloads.SAPEnvironmentTypeNonProd),
			SapProduct:  to.Ptr(armworkloads.SAPProductTypeS4HANA),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPVirtualInstance = armworkloads.SAPVirtualInstance{
	// 	Name: to.Ptr("X00"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPVirtualInstanceProperties{
	// 		Configuration: &armworkloads.DeploymentWithOSConfiguration{
	// 			ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
	// 			AppLocation: to.Ptr("eastus"),
	// 			InfrastructureConfiguration: &armworkloads.SingleServerConfiguration{
	// 				AppResourceGroup: to.Ptr("X00-RG"),
	// 				DeploymentType: to.Ptr(armworkloads.SAPDeploymentTypeSingleServer),
	// 				CustomResourceNames: &armworkloads.SingleServerFullResourceNames{
	// 					NamingPatternType: to.Ptr(armworkloads.NamingPatternTypeFullResourceName),
	// 					VirtualMachine: &armworkloads.VirtualMachineResourceNames{
	// 						DataDiskNames: map[string][]*string{
	// 							"hanaData": []*string{
	// 								to.Ptr("hanadata0"),
	// 								to.Ptr("hanadata1")},
	// 								"hanaLog": []*string{
	// 									to.Ptr("hanalog0"),
	// 									to.Ptr("hanalog1"),
	// 									to.Ptr("hanalog2")},
	// 									"hanaShared": []*string{
	// 										to.Ptr("hanashared0"),
	// 										to.Ptr("hanashared1")},
	// 										"usrSap": []*string{
	// 											to.Ptr("usrsap0")},
	// 										},
	// 										HostName: to.Ptr("sshostName"),
	// 										NetworkInterfaces: []*armworkloads.NetworkInterfaceResourceNames{
	// 											{
	// 												NetworkInterfaceName: to.Ptr("ssnic"),
	// 										}},
	// 										OSDiskName: to.Ptr("ssosdisk"),
	// 										VMName: to.Ptr("ssvm"),
	// 									},
	// 								},
	// 								DatabaseType: to.Ptr(armworkloads.SAPDatabaseTypeHANA),
	// 								NetworkConfiguration: &armworkloads.NetworkConfiguration{
	// 									IsSecondaryIPEnabled: to.Ptr(true),
	// 								},
	// 								SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 								VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 									ImageReference: &armworkloads.ImageReference{
	// 										Offer: to.Ptr("RHEL-SAP"),
	// 										Publisher: to.Ptr("RedHat"),
	// 										SKU: to.Ptr("7.4"),
	// 										Version: to.Ptr("7.4.2019062505"),
	// 									},
	// 									OSProfile: &armworkloads.OSProfile{
	// 										AdminUsername: to.Ptr("{your-username}"),
	// 										OSConfiguration: &armworkloads.LinuxConfiguration{
	// 											OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 											DisablePasswordAuthentication: to.Ptr(true),
	// 											SSHKeyPair: &armworkloads.SSHKeyPair{
	// 												PublicKey: to.Ptr("abc"),
	// 											},
	// 										},
	// 									},
	// 									VMSize: to.Ptr("Standard_E32ds_v4"),
	// 								},
	// 							},
	// 							OSSapConfiguration: &armworkloads.OsSapConfiguration{
	// 								SapFqdn: to.Ptr("xyz.test.com"),
	// 							},
	// 						},
	// 						Environment: to.Ptr(armworkloads.SAPEnvironmentTypeNonProd),
	// 						Health: to.Ptr(armworkloads.SAPHealthStateUnknown),
	// 						ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 						SapProduct: to.Ptr(armworkloads.SAPProductTypeS4HANA),
	// 						State: to.Ptr(armworkloads.SAPVirtualInstanceStateSoftwareInstallationPending),
	// 						Status: to.Ptr(armworkloads.SAPVirtualInstanceStatus("Unknown")),
	// 					},
	// 				}
}
Output:

Example (CreateInfrastructureWithoutSapTransFileshare)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPVirtualInstances_Create_Distributed_SkipTransMount.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPVirtualInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "test-rg", "X00", armworkloads.SAPVirtualInstance{
		Location: to.Ptr("westcentralus"),
		Tags:     map[string]*string{},
		Properties: &armworkloads.SAPVirtualInstanceProperties{
			Configuration: &armworkloads.DeploymentWithOSConfiguration{
				ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
				AppLocation:       to.Ptr("eastus"),
				InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
					AppResourceGroup: to.Ptr("X00-RG"),
					DeploymentType:   to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
					ApplicationServer: &armworkloads.ApplicationServerConfiguration{
						InstanceCount: to.Ptr[int64](6),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_E32ds_v4"),
						},
					},
					CentralServer: &armworkloads.CentralServerConfiguration{
						InstanceCount: to.Ptr[int64](1),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_E16ds_v4"),
						},
					},
					DatabaseServer: &armworkloads.DatabaseConfiguration{
						DatabaseType:  to.Ptr(armworkloads.SAPDatabaseTypeHANA),
						InstanceCount: to.Ptr[int64](1),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/dbsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("7.4"),
								Version:   to.Ptr("7.4.2019062505"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_M32ts"),
						},
					},
					StorageConfiguration: &armworkloads.StorageConfiguration{
						TransportFileShareConfiguration: &armworkloads.SkipFileShareConfiguration{
							ConfigurationType: to.Ptr(armworkloads.ConfigurationTypeSkip),
						},
					},
				},
				OSSapConfiguration: &armworkloads.OsSapConfiguration{
					SapFqdn: to.Ptr("xyz.test.com"),
				},
			},
			Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
			SapProduct:  to.Ptr(armworkloads.SAPProductTypeS4HANA),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPVirtualInstance = armworkloads.SAPVirtualInstance{
	// 	Name: to.Ptr("X00"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPVirtualInstanceProperties{
	// 		Configuration: &armworkloads.DeploymentWithOSConfiguration{
	// 			ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
	// 			AppLocation: to.Ptr("eastus"),
	// 			InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
	// 				AppResourceGroup: to.Ptr("X00-RG"),
	// 				DeploymentType: to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
	// 				ApplicationServer: &armworkloads.ApplicationServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](6),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E32ds_v4"),
	// 					},
	// 				},
	// 				CentralServer: &armworkloads.CentralServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](1),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E16ds_v4"),
	// 					},
	// 				},
	// 				DatabaseServer: &armworkloads.DatabaseConfiguration{
	// 					DatabaseType: to.Ptr(armworkloads.SAPDatabaseTypeHANA),
	// 					InstanceCount: to.Ptr[int64](1),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/dbsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_M32ts"),
	// 					},
	// 				},
	// 				StorageConfiguration: &armworkloads.StorageConfiguration{
	// 					TransportFileShareConfiguration: &armworkloads.SkipFileShareConfiguration{
	// 						ConfigurationType: to.Ptr(armworkloads.ConfigurationTypeSkip),
	// 					},
	// 				},
	// 			},
	// 			OSSapConfiguration: &armworkloads.OsSapConfiguration{
	// 				SapFqdn: to.Ptr("xyz.test.com"),
	// 			},
	// 		},
	// 		Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
	// 		Health: to.Ptr(armworkloads.SAPHealthStateUnknown),
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		SapProduct: to.Ptr(armworkloads.SAPProductTypeS4HANA),
	// 		State: to.Ptr(armworkloads.SAPVirtualInstanceStateSoftwareInstallationPending),
	// 		Status: to.Ptr(armworkloads.SAPVirtualInstanceStatus("Unknown")),
	// 	},
	// }
}
Output:

Example (DetectSapSoftwareInstallationOnADistributedSystem)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPVirtualInstances_DetectInstallation_Distributed.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPVirtualInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "test-rg", "X00", armworkloads.SAPVirtualInstance{
		Location: to.Ptr("eastus2"),
		Tags: map[string]*string{
			"created by": to.Ptr("azureuser"),
		},
		Properties: &armworkloads.SAPVirtualInstanceProperties{
			Configuration: &armworkloads.DeploymentWithOSConfiguration{
				ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
				AppLocation:       to.Ptr("eastus"),
				InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
					AppResourceGroup: to.Ptr("{{resourcegrp}}"),
					DeploymentType:   to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
					ApplicationServer: &armworkloads.ApplicationServerConfiguration{
						InstanceCount: to.Ptr[int64](2),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Network/virtualNetworks/test-vnet/subnets/app"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP-HA"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("84sapha-gen2"),
								Version:   to.Ptr("8.4.2021091202"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("azureuser"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("{{privateKey}}"),
										PublicKey:  to.Ptr("{{sshkey}}"),
									},
								},
							},
							VMSize: to.Ptr("Standard_E4ds_v4"),
						},
					},
					CentralServer: &armworkloads.CentralServerConfiguration{
						InstanceCount: to.Ptr[int64](1),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Network/virtualNetworks/test-vnet/subnets/app"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP-HA"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("84sapha-gen2"),
								Version:   to.Ptr("8.4.2021091202"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("azureuser"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("{{privateKey}}"),
										PublicKey:  to.Ptr("{{sshkey}}"),
									},
								},
							},
							VMSize: to.Ptr("Standard_E4ds_v4"),
						},
					},
					DatabaseServer: &armworkloads.DatabaseConfiguration{
						InstanceCount: to.Ptr[int64](1),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Network/virtualNetworks/test-vnet/subnets/app"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP-HA"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("84sapha-gen2"),
								Version:   to.Ptr("8.4.2021091202"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("azureuser"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("{{privateKey}}"),
										PublicKey:  to.Ptr("{{sshkey}}"),
									},
								},
							},
							VMSize: to.Ptr("Standard_M32ts"),
						},
					},
					NetworkConfiguration: &armworkloads.NetworkConfiguration{
						IsSecondaryIPEnabled: to.Ptr(true),
					},
				},
				OSSapConfiguration: &armworkloads.OsSapConfiguration{
					SapFqdn: to.Ptr("sap.bpaas.com"),
				},
				SoftwareConfiguration: &armworkloads.ExternalInstallationSoftwareConfiguration{
					SoftwareInstallationType: to.Ptr(armworkloads.SAPSoftwareInstallationTypeExternal),
					CentralServerVMID:        to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Compute/virtualMachines/sapq20scsvm0"),
				},
			},
			Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
			SapProduct:  to.Ptr(armworkloads.SAPProductTypeS4HANA),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPVirtualInstance = armworkloads.SAPVirtualInstance{
	// 	Name: to.Ptr("X00"),
	// 	Type: to.Ptr("microsoft.workloads/sapvirtualinstances"),
	// 	ID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2022-08-18T18:25:55.2406546Z"); return t}()),
	// 		CreatedBy: to.Ptr("f1bc9460-9d57-4c16-99a8-5a19378a3a93"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeApplication),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2022-08-18T18:50:59.1945444Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("f1bc9460-9d57-4c16-99a8-5a19378a3a93"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeApplication),
	// 	},
	// 	Location: to.Ptr("eastus2"),
	// 	Tags: map[string]*string{
	// 		"created by": to.Ptr("azureuser"),
	// 	},
	// 	Properties: &armworkloads.SAPVirtualInstanceProperties{
	// 		Configuration: &armworkloads.DeploymentWithOSConfiguration{
	// 			ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
	// 			AppLocation: to.Ptr("eastus"),
	// 			InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
	// 				AppResourceGroup: to.Ptr("aa-rg"),
	// 				DeploymentType: to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
	// 				ApplicationServer: &armworkloads.ApplicationServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](2),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Network/virtualNetworks/test-vnet/subnets/app"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP-HA"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("84sapha-gen2"),
	// 							Version: to.Ptr("8.4.2021091202"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("azureuser"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("ssh-rsa AAA generated-by-azure"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E4ds_v4"),
	// 					},
	// 				},
	// 				CentralServer: &armworkloads.CentralServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](1),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Network/virtualNetworks/test-vnet/subnets/app"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP-HA"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("84sapha-gen2"),
	// 							Version: to.Ptr("8.4.2021091202"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("azureuser"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("ssh-rsa AAA generated-by-azure"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E4ds_v4"),
	// 					},
	// 				},
	// 				DatabaseServer: &armworkloads.DatabaseConfiguration{
	// 					InstanceCount: to.Ptr[int64](1),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Network/virtualNetworks/test-vnet/subnets/app"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP-HA"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("84sapha-gen2"),
	// 							Version: to.Ptr("8.4.2021091202"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("azureuser"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("ssh-rsa AAA generated-by-azure"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_M32ts"),
	// 					},
	// 				},
	// 				NetworkConfiguration: &armworkloads.NetworkConfiguration{
	// 					IsSecondaryIPEnabled: to.Ptr(true),
	// 				},
	// 			},
	// 			OSSapConfiguration: &armworkloads.OsSapConfiguration{
	// 				SapFqdn: to.Ptr("sap.bpaas.com"),
	// 			},
	// 			SoftwareConfiguration: &armworkloads.ExternalInstallationSoftwareConfiguration{
	// 				SoftwareInstallationType: to.Ptr(armworkloads.SAPSoftwareInstallationTypeExternal),
	// 				CentralServerVMID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Compute/virtualMachines/sapq20scsvm0"),
	// 			},
	// 		},
	// 		Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		SapProduct: to.Ptr(armworkloads.SAPProductTypeS4HANA),
	// 		State: to.Ptr(armworkloads.SAPVirtualInstanceStateRegistrationComplete),
	// 	},
	// }
}
Output:

Example (DetectSapSoftwareInstallationOnASingleServerSystem)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPVirtualInstances_DetectInstallation_SingleServer.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPVirtualInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "test-rg", "X00", armworkloads.SAPVirtualInstance{
		Location: to.Ptr("westcentralus"),
		Tags:     map[string]*string{},
		Properties: &armworkloads.SAPVirtualInstanceProperties{
			Configuration: &armworkloads.DeploymentWithOSConfiguration{
				ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
				AppLocation:       to.Ptr("eastus"),
				InfrastructureConfiguration: &armworkloads.SingleServerConfiguration{
					AppResourceGroup: to.Ptr("X00-RG"),
					DeploymentType:   to.Ptr(armworkloads.SAPDeploymentTypeSingleServer),
					DatabaseType:     to.Ptr(armworkloads.SAPDatabaseTypeHANA),
					NetworkConfiguration: &armworkloads.NetworkConfiguration{
						IsSecondaryIPEnabled: to.Ptr(true),
					},
					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
						ImageReference: &armworkloads.ImageReference{
							Offer:     to.Ptr("RHEL-SAP-HA"),
							Publisher: to.Ptr("RedHat"),
							SKU:       to.Ptr("84sapha-gen2"),
							Version:   to.Ptr("8.4.2021091202"),
						},
						OSProfile: &armworkloads.OSProfile{
							AdminUsername: to.Ptr("{your-username}"),
							OSConfiguration: &armworkloads.LinuxConfiguration{
								OSType:                        to.Ptr(armworkloads.OSTypeLinux),
								DisablePasswordAuthentication: to.Ptr(true),
								SSHKeyPair: &armworkloads.SSHKeyPair{
									PrivateKey: to.Ptr("xyz"),
									PublicKey:  to.Ptr("abc"),
								},
							},
						},
						VMSize: to.Ptr("Standard_E32ds_v4"),
					},
				},
				OSSapConfiguration: &armworkloads.OsSapConfiguration{
					SapFqdn: to.Ptr("xyz.test.com"),
				},
				SoftwareConfiguration: &armworkloads.ExternalInstallationSoftwareConfiguration{
					SoftwareInstallationType: to.Ptr(armworkloads.SAPSoftwareInstallationTypeExternal),
					CentralServerVMID:        to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Compute/virtualMachines/sapq20scsvm0"),
				},
			},
			Environment: to.Ptr(armworkloads.SAPEnvironmentTypeNonProd),
			SapProduct:  to.Ptr(armworkloads.SAPProductTypeS4HANA),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPVirtualInstance = armworkloads.SAPVirtualInstance{
	// 	Name: to.Ptr("X00"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPVirtualInstanceProperties{
	// 		Configuration: &armworkloads.DeploymentWithOSConfiguration{
	// 			ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
	// 			AppLocation: to.Ptr("eastus"),
	// 			InfrastructureConfiguration: &armworkloads.SingleServerConfiguration{
	// 				AppResourceGroup: to.Ptr("X00-RG"),
	// 				DeploymentType: to.Ptr(armworkloads.SAPDeploymentTypeSingleServer),
	// 				DatabaseType: to.Ptr(armworkloads.SAPDatabaseTypeHANA),
	// 				NetworkConfiguration: &armworkloads.NetworkConfiguration{
	// 					IsSecondaryIPEnabled: to.Ptr(true),
	// 				},
	// 				SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 				VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 					ImageReference: &armworkloads.ImageReference{
	// 						Offer: to.Ptr("RHEL-SAP-HA"),
	// 						Publisher: to.Ptr("RedHat"),
	// 						SKU: to.Ptr("84sapha-gen2"),
	// 						Version: to.Ptr("8.4.2021091202"),
	// 					},
	// 					OSProfile: &armworkloads.OSProfile{
	// 						AdminUsername: to.Ptr("{your-username}"),
	// 						OSConfiguration: &armworkloads.LinuxConfiguration{
	// 							OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 							DisablePasswordAuthentication: to.Ptr(true),
	// 							SSHKeyPair: &armworkloads.SSHKeyPair{
	// 								PublicKey: to.Ptr("abc"),
	// 							},
	// 						},
	// 					},
	// 					VMSize: to.Ptr("Standard_E32ds_v4"),
	// 				},
	// 			},
	// 			OSSapConfiguration: &armworkloads.OsSapConfiguration{
	// 				SapFqdn: to.Ptr("xyz.test.com"),
	// 			},
	// 			SoftwareConfiguration: &armworkloads.ExternalInstallationSoftwareConfiguration{
	// 				SoftwareInstallationType: to.Ptr(armworkloads.SAPSoftwareInstallationTypeExternal),
	// 				CentralServerVMID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Compute/virtualMachines/sapq20scsvm0"),
	// 			},
	// 		},
	// 		Environment: to.Ptr(armworkloads.SAPEnvironmentTypeNonProd),
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		SapProduct: to.Ptr(armworkloads.SAPProductTypeS4HANA),
	// 		State: to.Ptr(armworkloads.SAPVirtualInstanceStateRegistrationComplete),
	// 	},
	// }
}
Output:

Example (DetectSapSoftwareInstallationOnAnHaSystemWithAvailabilitySet)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPVirtualInstances_DetectInstallation_HA_AvSet.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPVirtualInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "test-rg", "X00", armworkloads.SAPVirtualInstance{
		Location: to.Ptr("westcentralus"),
		Tags:     map[string]*string{},
		Properties: &armworkloads.SAPVirtualInstanceProperties{
			Configuration: &armworkloads.DeploymentWithOSConfiguration{
				ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
				AppLocation:       to.Ptr("eastus"),
				InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
					AppResourceGroup: to.Ptr("X00-RG"),
					DeploymentType:   to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
					ApplicationServer: &armworkloads.ApplicationServerConfiguration{
						InstanceCount: to.Ptr[int64](6),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP-HA"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("84sapha-gen2"),
								Version:   to.Ptr("8.4.2021091202"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_E32ds_v4"),
						},
					},
					CentralServer: &armworkloads.CentralServerConfiguration{
						InstanceCount: to.Ptr[int64](2),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP-HA"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("84sapha-gen2"),
								Version:   to.Ptr("8.4.2021091202"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_E16ds_v4"),
						},
					},
					DatabaseServer: &armworkloads.DatabaseConfiguration{
						DatabaseType:  to.Ptr(armworkloads.SAPDatabaseTypeHANA),
						InstanceCount: to.Ptr[int64](2),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/dbsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP-HA"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("84sapha-gen2"),
								Version:   to.Ptr("8.4.2021091202"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_M32ts"),
						},
					},
					HighAvailabilityConfig: &armworkloads.HighAvailabilityConfiguration{
						HighAvailabilityType: to.Ptr(armworkloads.SAPHighAvailabilityTypeAvailabilitySet),
					},
				},
				OSSapConfiguration: &armworkloads.OsSapConfiguration{
					SapFqdn: to.Ptr("xyz.test.com"),
				},
				SoftwareConfiguration: &armworkloads.ExternalInstallationSoftwareConfiguration{
					SoftwareInstallationType: to.Ptr(armworkloads.SAPSoftwareInstallationTypeExternal),
					CentralServerVMID:        to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Compute/virtualMachines/sapq20scsvm0"),
				},
			},
			Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
			SapProduct:  to.Ptr(armworkloads.SAPProductTypeS4HANA),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPVirtualInstance = armworkloads.SAPVirtualInstance{
	// 	Name: to.Ptr("X00"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPVirtualInstanceProperties{
	// 		Configuration: &armworkloads.DeploymentWithOSConfiguration{
	// 			ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
	// 			AppLocation: to.Ptr("eastus"),
	// 			InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
	// 				AppResourceGroup: to.Ptr("X00-RG"),
	// 				DeploymentType: to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
	// 				ApplicationServer: &armworkloads.ApplicationServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](6),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP-HA"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("84sapha-gen2"),
	// 							Version: to.Ptr("8.4.2021091202"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E32ds_v4"),
	// 					},
	// 				},
	// 				CentralServer: &armworkloads.CentralServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](2),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP-HA"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("84sapha-gen2"),
	// 							Version: to.Ptr("8.4.2021091202"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E16ds_v4"),
	// 					},
	// 				},
	// 				DatabaseServer: &armworkloads.DatabaseConfiguration{
	// 					DatabaseType: to.Ptr(armworkloads.SAPDatabaseTypeHANA),
	// 					InstanceCount: to.Ptr[int64](2),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/dbsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP-HA"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("84sapha-gen2"),
	// 							Version: to.Ptr("8.4.2021091202"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_M32ts"),
	// 					},
	// 				},
	// 				HighAvailabilityConfig: &armworkloads.HighAvailabilityConfiguration{
	// 					HighAvailabilityType: to.Ptr(armworkloads.SAPHighAvailabilityTypeAvailabilitySet),
	// 				},
	// 			},
	// 			OSSapConfiguration: &armworkloads.OsSapConfiguration{
	// 				SapFqdn: to.Ptr("xyz.test.com"),
	// 			},
	// 			SoftwareConfiguration: &armworkloads.ExternalInstallationSoftwareConfiguration{
	// 				SoftwareInstallationType: to.Ptr(armworkloads.SAPSoftwareInstallationTypeExternal),
	// 				CentralServerVMID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Compute/virtualMachines/sapq20scsvm0"),
	// 			},
	// 		},
	// 		Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		SapProduct: to.Ptr(armworkloads.SAPProductTypeS4HANA),
	// 		State: to.Ptr(armworkloads.SAPVirtualInstanceStateRegistrationComplete),
	// 	},
	// }
}
Output:

Example (DetectSapSoftwareInstallationOnAnHaSystemWithAvailabilityZone)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPVirtualInstances_DetectInstallation_HA_AvZone.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPVirtualInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "test-rg", "X00", armworkloads.SAPVirtualInstance{
		Location: to.Ptr("westcentralus"),
		Tags:     map[string]*string{},
		Properties: &armworkloads.SAPVirtualInstanceProperties{
			Configuration: &armworkloads.DeploymentWithOSConfiguration{
				ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
				AppLocation:       to.Ptr("eastus"),
				InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
					AppResourceGroup: to.Ptr("X00-RG"),
					DeploymentType:   to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
					ApplicationServer: &armworkloads.ApplicationServerConfiguration{
						InstanceCount: to.Ptr[int64](6),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP-HA"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("84sapha-gen2"),
								Version:   to.Ptr("8.4.2021091202"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_E32ds_v4"),
						},
					},
					CentralServer: &armworkloads.CentralServerConfiguration{
						InstanceCount: to.Ptr[int64](2),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP-HA"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("84sapha-gen2"),
								Version:   to.Ptr("8.4.2021091202"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_E16ds_v4"),
						},
					},
					DatabaseServer: &armworkloads.DatabaseConfiguration{
						DatabaseType:  to.Ptr(armworkloads.SAPDatabaseTypeHANA),
						InstanceCount: to.Ptr[int64](2),
						SubnetID:      to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/dbsubnet"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP-HA"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("84sapha-gen2"),
								Version:   to.Ptr("8.4.2021091202"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("{your-username}"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("xyz"),
										PublicKey:  to.Ptr("abc"),
									},
								},
							},
							VMSize: to.Ptr("Standard_M32ts"),
						},
					},
					HighAvailabilityConfig: &armworkloads.HighAvailabilityConfiguration{
						HighAvailabilityType: to.Ptr(armworkloads.SAPHighAvailabilityTypeAvailabilityZone),
					},
				},
				OSSapConfiguration: &armworkloads.OsSapConfiguration{
					SapFqdn: to.Ptr("xyz.test.com"),
				},
				SoftwareConfiguration: &armworkloads.ExternalInstallationSoftwareConfiguration{
					SoftwareInstallationType: to.Ptr(armworkloads.SAPSoftwareInstallationTypeExternal),
					CentralServerVMID:        to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Compute/virtualMachines/sapq20scsvm0"),
				},
			},
			Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
			SapProduct:  to.Ptr(armworkloads.SAPProductTypeS4HANA),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPVirtualInstance = armworkloads.SAPVirtualInstance{
	// 	Name: to.Ptr("X00"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPVirtualInstanceProperties{
	// 		Configuration: &armworkloads.DeploymentWithOSConfiguration{
	// 			ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
	// 			AppLocation: to.Ptr("eastus"),
	// 			InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
	// 				AppResourceGroup: to.Ptr("X00-RG"),
	// 				DeploymentType: to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
	// 				ApplicationServer: &armworkloads.ApplicationServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](6),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP-HA"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("84sapha-gen2"),
	// 							Version: to.Ptr("8.4.2021091202"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E32ds_v4"),
	// 					},
	// 				},
	// 				CentralServer: &armworkloads.CentralServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](2),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/appsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP-HA"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("84sapha-gen2"),
	// 							Version: to.Ptr("8.4.2021091202"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E16ds_v4"),
	// 					},
	// 				},
	// 				DatabaseServer: &armworkloads.DatabaseConfiguration{
	// 					DatabaseType: to.Ptr(armworkloads.SAPDatabaseTypeHANA),
	// 					InstanceCount: to.Ptr[int64](2),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/test-vnet/subnets/dbsubnet"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP-HA"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("84sapha-gen2"),
	// 							Version: to.Ptr("8.4.2021091202"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("abc"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_M32ts"),
	// 					},
	// 				},
	// 				HighAvailabilityConfig: &armworkloads.HighAvailabilityConfiguration{
	// 					HighAvailabilityType: to.Ptr(armworkloads.SAPHighAvailabilityTypeAvailabilityZone),
	// 				},
	// 			},
	// 			OSSapConfiguration: &armworkloads.OsSapConfiguration{
	// 				SapFqdn: to.Ptr("xyz.test.com"),
	// 			},
	// 			SoftwareConfiguration: &armworkloads.ExternalInstallationSoftwareConfiguration{
	// 				SoftwareInstallationType: to.Ptr(armworkloads.SAPSoftwareInstallationTypeExternal),
	// 				CentralServerVMID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Compute/virtualMachines/sapq20scsvm0"),
	// 			},
	// 		},
	// 		Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		SapProduct: to.Ptr(armworkloads.SAPProductTypeS4HANA),
	// 		State: to.Ptr(armworkloads.SAPVirtualInstanceStateRegistrationComplete),
	// 	},
	// }
}
Output:

Example (InstallSapSoftwareOnDistributedSystem)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPVirtualInstances_Install_Distributed.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPVirtualInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "test-rg", "X00", armworkloads.SAPVirtualInstance{
		Location: to.Ptr("eastus2"),
		Tags: map[string]*string{
			"created by": to.Ptr("azureuser"),
		},
		Properties: &armworkloads.SAPVirtualInstanceProperties{
			Configuration: &armworkloads.DeploymentWithOSConfiguration{
				ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
				AppLocation:       to.Ptr("eastus"),
				InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
					AppResourceGroup: to.Ptr("{{resourcegrp}}"),
					DeploymentType:   to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
					ApplicationServer: &armworkloads.ApplicationServerConfiguration{
						InstanceCount: to.Ptr[int64](2),
						SubnetID:      to.Ptr("/subscriptions/8e17e36c-42e9-4cd5-a078-7b44883414e0/resourceGroups/test-rg/providers/Microsoft.Network/virtualNetworks/test-vnet/subnets/app"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP-HA"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("8.2"),
								Version:   to.Ptr("8.2.2021091201"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("azureuser"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("{{privateKey}}"),
										PublicKey:  to.Ptr("{{sshkey}}"),
									},
								},
							},
							VMSize: to.Ptr("Standard_E4ds_v4"),
						},
					},
					CentralServer: &armworkloads.CentralServerConfiguration{
						InstanceCount: to.Ptr[int64](1),
						SubnetID:      to.Ptr("/subscriptions/8e17e36c-42e9-4cd5-a078-7b44883414e0/resourceGroups/test-rg/providers/Microsoft.Network/virtualNetworks/test-vnet/subnets/app"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP-HA"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("8.2"),
								Version:   to.Ptr("8.2.2021091201"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("azureuser"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("{{privateKey}}"),
										PublicKey:  to.Ptr("{{sshkey}}"),
									},
								},
							},
							VMSize: to.Ptr("Standard_E4ds_v4"),
						},
					},
					DatabaseServer: &armworkloads.DatabaseConfiguration{
						InstanceCount: to.Ptr[int64](1),
						SubnetID:      to.Ptr("/subscriptions/8e17e36c-42e9-4cd5-a078-7b44883414e0/resourceGroups/test-rg/providers/Microsoft.Network/virtualNetworks/test-vnet/subnets/app"),
						VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
							ImageReference: &armworkloads.ImageReference{
								Offer:     to.Ptr("RHEL-SAP-HA"),
								Publisher: to.Ptr("RedHat"),
								SKU:       to.Ptr("8.2"),
								Version:   to.Ptr("8.2.2021091201"),
							},
							OSProfile: &armworkloads.OSProfile{
								AdminUsername: to.Ptr("azureuser"),
								OSConfiguration: &armworkloads.LinuxConfiguration{
									OSType:                        to.Ptr(armworkloads.OSTypeLinux),
									DisablePasswordAuthentication: to.Ptr(true),
									SSHKeyPair: &armworkloads.SSHKeyPair{
										PrivateKey: to.Ptr("{{privateKey}}"),
										PublicKey:  to.Ptr("{{sshkey}}"),
									},
								},
							},
							VMSize: to.Ptr("Standard_M32ts"),
						},
					},
					NetworkConfiguration: &armworkloads.NetworkConfiguration{
						IsSecondaryIPEnabled: to.Ptr(true),
					},
				},
				OSSapConfiguration: &armworkloads.OsSapConfiguration{
					SapFqdn: to.Ptr("sap.bpaas.com"),
				},
				SoftwareConfiguration: &armworkloads.SAPInstallWithoutOSConfigSoftwareConfiguration{
					SoftwareInstallationType: to.Ptr(armworkloads.SAPSoftwareInstallationTypeSAPInstallWithoutOSConfig),
					BomURL:                   to.Ptr("https://teststorageaccount.blob.core.windows.net/sapbits/sapfiles/boms/S41909SPS03_v0011ms/S41909SPS03_v0011ms.yaml"),
					SapBitsStorageAccountID:  to.Ptr("/subscriptions/8e17e36c-42e9-4cd5-a078-7b44883414e0/resourceGroups/test-rg/providers/Microsoft.Storage/storageAccounts/teststorageaccount"),
					SoftwareVersion:          to.Ptr("SAP S/4HANA 1909 SPS 03"),
				},
			},
			Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
			SapProduct:  to.Ptr(armworkloads.SAPProductTypeS4HANA),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPVirtualInstance = armworkloads.SAPVirtualInstance{
	// 	Name: to.Ptr("X00"),
	// 	Type: to.Ptr("microsoft.workloads/sapvirtualinstances"),
	// 	ID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/aa-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2022-08-18T18:25:55.2406546Z"); return t}()),
	// 		CreatedBy: to.Ptr("f1bc9460-9d57-4c16-99a8-5a19378a3a93"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeApplication),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2022-08-18T18:50:59.1945444Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("f1bc9460-9d57-4c16-99a8-5a19378a3a93"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeApplication),
	// 	},
	// 	Location: to.Ptr("eastus2"),
	// 	Tags: map[string]*string{
	// 		"created by": to.Ptr("azureuser"),
	// 	},
	// 	Properties: &armworkloads.SAPVirtualInstanceProperties{
	// 		Configuration: &armworkloads.DeploymentWithOSConfiguration{
	// 			ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
	// 			AppLocation: to.Ptr("eastus"),
	// 			InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
	// 				AppResourceGroup: to.Ptr("aa-rg"),
	// 				DeploymentType: to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
	// 				ApplicationServer: &armworkloads.ApplicationServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](2),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Network/virtualNetworks/test-vnet/subnets/app"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP-HA"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("84sapha-gen2"),
	// 							Version: to.Ptr("8.4.2021091202"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("azureuser"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("ssh-rsa AAA generated-by-azure"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E4ds_v4"),
	// 					},
	// 				},
	// 				CentralServer: &armworkloads.CentralServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](1),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Network/virtualNetworks/test-vnet/subnets/app"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP-HA"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("84sapha-gen2"),
	// 							Version: to.Ptr("8.4.2021091202"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("azureuser"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("ssh-rsa AAA generated-by-azure"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E4ds_v4"),
	// 					},
	// 				},
	// 				DatabaseServer: &armworkloads.DatabaseConfiguration{
	// 					InstanceCount: to.Ptr[int64](1),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Network/virtualNetworks/test-vnet/subnets/app"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP-HA"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("84sapha-gen2"),
	// 							Version: to.Ptr("8.4.2021091202"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("azureuser"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("ssh-rsa AAA generated-by-azure"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_M32ts"),
	// 					},
	// 				},
	// 				NetworkConfiguration: &armworkloads.NetworkConfiguration{
	// 					IsSecondaryIPEnabled: to.Ptr(true),
	// 				},
	// 			},
	// 			OSSapConfiguration: &armworkloads.OsSapConfiguration{
	// 				SapFqdn: to.Ptr("sap.bpaas.com"),
	// 			},
	// 			SoftwareConfiguration: &armworkloads.SAPInstallWithoutOSConfigSoftwareConfiguration{
	// 				SoftwareInstallationType: to.Ptr(armworkloads.SAPSoftwareInstallationTypeSAPInstallWithoutOSConfig),
	// 				BomURL: to.Ptr("https://teststorageaccount.blob.core.windows.net/sapbits/sapfiles/boms/S41909SPS03_v0011ms/S41909SPS03_v0011ms.yaml"),
	// 				SapBitsStorageAccountID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Storage/storageAccounts/teststorageaccount"),
	// 				SoftwareVersion: to.Ptr("SAP S/4HANA 1909 SPS 03"),
	// 			},
	// 		},
	// 		Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		SapProduct: to.Ptr(armworkloads.SAPProductTypeS4HANA),
	// 		State: to.Ptr(armworkloads.SAPVirtualInstanceStateSoftwareInstallationInProgress),
	// 	},
	// }
}
Output:

Example (InstallSapSoftwareOnSingleServerSystem)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPVirtualInstances_Install_SingleServer.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPVirtualInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "test-rg", "X00", armworkloads.SAPVirtualInstance{
		Location: to.Ptr("eastus2"),
		Tags:     map[string]*string{},
		Properties: &armworkloads.SAPVirtualInstanceProperties{
			Configuration: &armworkloads.DeploymentWithOSConfiguration{
				ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
				AppLocation:       to.Ptr("eastus"),
				InfrastructureConfiguration: &armworkloads.SingleServerConfiguration{
					AppResourceGroup: to.Ptr("test-rg"),
					DeploymentType:   to.Ptr(armworkloads.SAPDeploymentTypeSingleServer),
					SubnetID:         to.Ptr("/subscriptions/8e17e36c-42e9-4cd5-a078-7b44883414e0/resourceGroups/test-rg/providers/Microsoft.Network/virtualNetworks/test-vnet/subnets/testsubnet"),
					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
						ImageReference: &armworkloads.ImageReference{
							Offer:     to.Ptr("SLES-SAP"),
							Publisher: to.Ptr("SUSE"),
							SKU:       to.Ptr("12-sp4-gen2"),
							Version:   to.Ptr("2022.02.01"),
						},
						OSProfile: &armworkloads.OSProfile{
							AdminUsername: to.Ptr("azureappadmin"),
							OSConfiguration: &armworkloads.LinuxConfiguration{
								OSType:                        to.Ptr(armworkloads.OSTypeLinux),
								DisablePasswordAuthentication: to.Ptr(true),
								SSHKeyPair: &armworkloads.SSHKeyPair{
									PrivateKey: to.Ptr("{{privateKey}}"),
									PublicKey:  to.Ptr("{{sshkey}}"),
								},
							},
						},
						VMSize: to.Ptr("Standard_E32ds_v4"),
					},
				},
				OSSapConfiguration: &armworkloads.OsSapConfiguration{
					SapFqdn: to.Ptr("sap.bpaas.com"),
				},
				SoftwareConfiguration: &armworkloads.SAPInstallWithoutOSConfigSoftwareConfiguration{
					SoftwareInstallationType: to.Ptr(armworkloads.SAPSoftwareInstallationTypeSAPInstallWithoutOSConfig),
					BomURL:                   to.Ptr("https://teststorageaccount.blob.core.windows.net/sapbits/sapfiles/boms/S41909SPS03_v0011ms/S41909SPS03_v0011ms.yaml"),
					SapBitsStorageAccountID:  to.Ptr("/subscriptions/8e17e36c-42e9-4cd5-a078-7b44883414e0/resourceGroups/test-rg/providers/Microsoft.Storage/storageAccounts/teststorageaccount"),
					SoftwareVersion:          to.Ptr("SAP S/4HANA 1909 SPS 03"),
				},
			},
			Environment: to.Ptr(armworkloads.SAPEnvironmentTypeNonProd),
			SapProduct:  to.Ptr(armworkloads.SAPProductTypeS4HANA),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPVirtualInstance = armworkloads.SAPVirtualInstance{
	// 	Name: to.Ptr("X00"),
	// 	Type: to.Ptr("microsoft.workloads/sapvirtualinstances"),
	// 	ID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/aa-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2022-08-18T18:25:55.2406546Z"); return t}()),
	// 		CreatedBy: to.Ptr("f1bc9460-9d57-4c16-99a8-5a19378a3a93"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeApplication),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2022-08-18T18:50:59.1945444Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("f1bc9460-9d57-4c16-99a8-5a19378a3a93"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeApplication),
	// 	},
	// 	Location: to.Ptr("eastus2"),
	// 	Tags: map[string]*string{
	// 		"created by": to.Ptr("azureuser"),
	// 	},
	// 	Properties: &armworkloads.SAPVirtualInstanceProperties{
	// 		Configuration: &armworkloads.DeploymentWithOSConfiguration{
	// 			ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeploymentWithOSConfig),
	// 			AppLocation: to.Ptr("eastus"),
	// 			InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
	// 				AppResourceGroup: to.Ptr("aa-rg"),
	// 				DeploymentType: to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
	// 				ApplicationServer: &armworkloads.ApplicationServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](2),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Network/virtualNetworks/test-vnet/subnets/app"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP-HA"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("84sapha-gen2"),
	// 							Version: to.Ptr("8.4.2021091202"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("azureuser"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("ssh-rsa AAA generated-by-azure"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E4ds_v4"),
	// 					},
	// 				},
	// 				CentralServer: &armworkloads.CentralServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](1),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Network/virtualNetworks/test-vnet/subnets/app"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP-HA"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("84sapha-gen2"),
	// 							Version: to.Ptr("8.4.2021091202"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("azureuser"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("ssh-rsa AAA generated-by-azure"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_E4ds_v4"),
	// 					},
	// 				},
	// 				DatabaseServer: &armworkloads.DatabaseConfiguration{
	// 					InstanceCount: to.Ptr[int64](1),
	// 					SubnetID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Network/virtualNetworks/test-vnet/subnets/app"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP-HA"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("84sapha-gen2"),
	// 							Version: to.Ptr("8.4.2021091202"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("azureuser"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSHKeyPair: &armworkloads.SSHKeyPair{
	// 									PublicKey: to.Ptr("ssh-rsa AAA generated-by-azure"),
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_M32ts"),
	// 					},
	// 				},
	// 				NetworkConfiguration: &armworkloads.NetworkConfiguration{
	// 					IsSecondaryIPEnabled: to.Ptr(true),
	// 				},
	// 			},
	// 			OSSapConfiguration: &armworkloads.OsSapConfiguration{
	// 				SapFqdn: to.Ptr("sap.bpaas.com"),
	// 			},
	// 			SoftwareConfiguration: &armworkloads.SAPInstallWithoutOSConfigSoftwareConfiguration{
	// 				SoftwareInstallationType: to.Ptr(armworkloads.SAPSoftwareInstallationTypeSAPInstallWithoutOSConfig),
	// 				BomURL: to.Ptr("https://teststorageaccount.blob.core.windows.net/sapbits/sapfiles/boms/S41909SPS03_v0011ms/S41909SPS03_v0011ms.yaml"),
	// 				SapBitsStorageAccountID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/test-rg/providers/Microsoft.Storage/storageAccounts/teststorageaccount"),
	// 				SoftwareVersion: to.Ptr("SAP S/4HANA 1909 SPS 03"),
	// 			},
	// 		},
	// 		Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		SapProduct: to.Ptr(armworkloads.SAPProductTypeS4HANA),
	// 		State: to.Ptr(armworkloads.SAPVirtualInstanceStateSoftwareInstallationInProgress),
	// 	},
	// }
}
Output:

Example (RegisterExistingSapSystemAsVirtualInstanceForSapSolutions)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPVirtualInstances_Create_Discover.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPVirtualInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "test-rg", "X00", armworkloads.SAPVirtualInstance{
		Location: to.Ptr("northeurope"),
		Tags: map[string]*string{
			"createdby": to.Ptr("abc@microsoft.com"),
			"test":      to.Ptr("abc"),
		},
		Properties: &armworkloads.SAPVirtualInstanceProperties{
			Configuration: &armworkloads.DiscoveryConfiguration{
				ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDiscovery),
				CentralServerVMID: to.Ptr("/subscriptions/8e17e36c-42e9-4cd5-a078-7b44883414e0/resourceGroups/test-rg/providers/Microsoft.Compute/virtualMachines/sapq20scsvm0"),
			},
			Environment: to.Ptr(armworkloads.SAPEnvironmentTypeNonProd),
			SapProduct:  to.Ptr(armworkloads.SAPProductTypeS4HANA),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPVirtualInstance = armworkloads.SAPVirtualInstance{
	// 	Name: to.Ptr("Q20"),
	// 	Type: to.Ptr("microsoft.workloads/sapvirtualinstances"),
	// 	ID: to.Ptr("/subscriptions/8e17e36c-42e9-4cd5-a078-7b44883414e0/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/Q20"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2022-07-27T08:22:52.3318907Z"); return t}()),
	// 		CreatedBy: to.Ptr("abc@microsoft.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2022-07-27T11:44:17.9310503Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("abc@microsoft.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("northeurope"),
	// 	Properties: &armworkloads.SAPVirtualInstanceProperties{
	// 		Configuration: &armworkloads.DiscoveryConfiguration{
	// 			ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDiscovery),
	// 			AppLocation: to.Ptr("westeurope"),
	// 			CentralServerVMID: to.Ptr("/subscriptions/8e17e36c-42e9-4cd5-a078-7b44883414e0/resourceGroups/test-rg-infra/providers/Microsoft.Compute/virtualMachines/q20ascsvm0"),
	// 		},
	// 		Environment: to.Ptr(armworkloads.SAPEnvironmentTypeNonProd),
	// 		Health: to.Ptr(armworkloads.SAPHealthStateHealthy),
	// 		ManagedResourceGroupConfiguration: &armworkloads.ManagedRGConfiguration{
	// 			Name: to.Ptr("mrg-Q20-5b0097"),
	// 		},
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		SapProduct: to.Ptr(armworkloads.SAPProductTypeS4HANA),
	// 		State: to.Ptr(armworkloads.SAPVirtualInstanceStateRegistrationComplete),
	// 		Status: to.Ptr(armworkloads.SAPVirtualInstanceStatusRunning),
	// 	},
	// }
}
Output:

Example (RegisterExistingSapSystemAsVirtualInstanceForSapSolutionsWithOptionalCustomizations)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPVirtualInstances_Create_Discover_CustomMrgStorageAccountName.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPVirtualInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginCreate(ctx, "test-rg", "X00", armworkloads.SAPVirtualInstance{
		Location: to.Ptr("northeurope"),
		Tags: map[string]*string{
			"createdby": to.Ptr("abc@microsoft.com"),
			"test":      to.Ptr("abc"),
		},
		Properties: &armworkloads.SAPVirtualInstanceProperties{
			Configuration: &armworkloads.DiscoveryConfiguration{
				ConfigurationType:           to.Ptr(armworkloads.SAPConfigurationTypeDiscovery),
				CentralServerVMID:           to.Ptr("/subscriptions/8e17e36c-42e9-4cd5-a078-7b44883414e0/resourceGroups/test-rg/providers/Microsoft.Compute/virtualMachines/sapq20scsvm0"),
				ManagedRgStorageAccountName: to.Ptr("q20saacssgrs"),
			},
			Environment: to.Ptr(armworkloads.SAPEnvironmentTypeNonProd),
			SapProduct:  to.Ptr(armworkloads.SAPProductTypeS4HANA),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPVirtualInstance = armworkloads.SAPVirtualInstance{
	// 	Name: to.Ptr("Q20"),
	// 	Type: to.Ptr("microsoft.workloads/sapvirtualinstances"),
	// 	ID: to.Ptr("/subscriptions/8e17e36c-42e9-4cd5-a078-7b44883414e0/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/Q20"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2022-07-27T08:22:52.3318907Z"); return t}()),
	// 		CreatedBy: to.Ptr("abc@microsoft.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2022-07-27T11:44:17.9310503Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("abc@microsoft.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("northeurope"),
	// 	Properties: &armworkloads.SAPVirtualInstanceProperties{
	// 		Configuration: &armworkloads.DiscoveryConfiguration{
	// 			ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDiscovery),
	// 			AppLocation: to.Ptr("westeurope"),
	// 			CentralServerVMID: to.Ptr("/subscriptions/8e17e36c-42e9-4cd5-a078-7b44883414e0/resourceGroups/test-rg-infra/providers/Microsoft.Compute/virtualMachines/q20ascsvm0"),
	// 			ManagedRgStorageAccountName: to.Ptr("q20saacssgrs"),
	// 		},
	// 		Environment: to.Ptr(armworkloads.SAPEnvironmentTypeNonProd),
	// 		Health: to.Ptr(armworkloads.SAPHealthStateHealthy),
	// 		ManagedResourceGroupConfiguration: &armworkloads.ManagedRGConfiguration{
	// 			Name: to.Ptr("mrg-Q20-5b0097"),
	// 		},
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		SapProduct: to.Ptr(armworkloads.SAPProductTypeS4HANA),
	// 		State: to.Ptr(armworkloads.SAPVirtualInstanceStateRegistrationComplete),
	// 		Status: to.Ptr(armworkloads.SAPVirtualInstanceStatusRunning),
	// 	},
	// }
}
Output:

func (*SAPVirtualInstancesClient) BeginDelete added in v0.2.0

func (client *SAPVirtualInstancesClient) BeginDelete(ctx context.Context, resourceGroupName string, sapVirtualInstanceName string, options *SAPVirtualInstancesClientBeginDeleteOptions) (*runtime.Poller[SAPVirtualInstancesClientDeleteResponse], error)

BeginDelete - Deletes a Virtual Instance for SAP solutions resource and its child resources, that is the associated Central Services Instance, Application Server Instances and Database Instance. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • sapVirtualInstanceName - The name of the Virtual Instances for SAP solutions resource
  • options - SAPVirtualInstancesClientBeginDeleteOptions contains the optional parameters for the SAPVirtualInstancesClient.BeginDelete method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPVirtualInstances_Delete.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPVirtualInstancesClient("6d875e77-e412-4d7d-9af4-8895278b4443", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginDelete(ctx, "test-rg", "X00", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.OperationStatusResult = armworkloads.OperationStatusResult{
	// 	Name: to.Ptr("1e4193c3-206e-4916-b124-1da16175eb0e"),
	// 	EndTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T03:38:07.000Z"); return t}()),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/operations/locations/centralus/1e4193c3-206e-4916-b124-1da16175eb0e"),
	// 	StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T03:36:07.000Z"); return t}()),
	// 	Status: to.Ptr("Succeeded"),
	// }
}
Output:

func (*SAPVirtualInstancesClient) BeginStart added in v0.2.0

func (client *SAPVirtualInstancesClient) BeginStart(ctx context.Context, resourceGroupName string, sapVirtualInstanceName string, options *SAPVirtualInstancesClientBeginStartOptions) (*runtime.Poller[SAPVirtualInstancesClientStartResponse], error)

BeginStart - Starts the SAP application, that is the Central Services instance and Application server instances. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • sapVirtualInstanceName - The name of the Virtual Instances for SAP solutions resource
  • options - SAPVirtualInstancesClientBeginStartOptions contains the optional parameters for the SAPVirtualInstancesClient.BeginStart method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPVirtualInstances_Start.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPVirtualInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginStart(ctx, "test-rg", "X00", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.OperationStatusResult = armworkloads.OperationStatusResult{
	// 	Name: to.Ptr("1e4193c3-206e-4916-b124-1da16175eb0e"),
	// 	EndTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T03:38:07.000Z"); return t}()),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/operations/locations/centralus/1e4193c3-206e-4916-b124-1da16175eb0e"),
	// 	StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T03:36:07.000Z"); return t}()),
	// 	Status: to.Ptr("Succeeded"),
	// }
}
Output:

func (*SAPVirtualInstancesClient) BeginStop added in v0.2.0

func (client *SAPVirtualInstancesClient) BeginStop(ctx context.Context, resourceGroupName string, sapVirtualInstanceName string, options *SAPVirtualInstancesClientBeginStopOptions) (*runtime.Poller[SAPVirtualInstancesClientStopResponse], error)

BeginStop - Stops the SAP Application, that is the Application server instances and Central Services instance. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • sapVirtualInstanceName - The name of the Virtual Instances for SAP solutions resource
  • options - SAPVirtualInstancesClientBeginStopOptions contains the optional parameters for the SAPVirtualInstancesClient.BeginStop method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPVirtualInstances_Stop.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPVirtualInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := client.BeginStop(ctx, "test-rg", "X00", &armworkloads.SAPVirtualInstancesClientBeginStopOptions{Body: &armworkloads.StopRequest{
		SoftStopTimeoutSeconds: to.Ptr[int64](0),
	},
	})
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	res, err := poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.OperationStatusResult = armworkloads.OperationStatusResult{
	// 	Name: to.Ptr("1e4193c3-206e-4916-b124-1da16175eb0e"),
	// 	EndTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T03:38:07.000Z"); return t}()),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/operations/locations/centralus/1e4193c3-206e-4916-b124-1da16175eb0e"),
	// 	StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T03:36:07.000Z"); return t}()),
	// 	Status: to.Ptr("Succeeded"),
	// }
}
Output:

func (*SAPVirtualInstancesClient) Get added in v0.2.0

func (client *SAPVirtualInstancesClient) Get(ctx context.Context, resourceGroupName string, sapVirtualInstanceName string, options *SAPVirtualInstancesClientGetOptions) (SAPVirtualInstancesClientGetResponse, error)

Get - Gets a Virtual Instance for SAP solutions resource If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • sapVirtualInstanceName - The name of the Virtual Instances for SAP solutions resource
  • options - SAPVirtualInstancesClientGetOptions contains the optional parameters for the SAPVirtualInstancesClient.Get method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPVirtualInstances_Get.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPVirtualInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := client.Get(ctx, "test-rg", "X00", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPVirtualInstance = armworkloads.SAPVirtualInstance{
	// 	Name: to.Ptr("X00"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armworkloads.SAPVirtualInstanceProperties{
	// 		Configuration: &armworkloads.DeploymentConfiguration{
	// 			ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeployment),
	// 			AppLocation: to.Ptr("eastus"),
	// 			InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
	// 				AppResourceGroup: to.Ptr("X00-RG"),
	// 				DeploymentType: to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
	// 				ApplicationServer: &armworkloads.ApplicationServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](10),
	// 					SubnetID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/vnet1/subnets/subnetId3"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSH: &armworkloads.SSHConfiguration{
	// 									PublicKeys: []*armworkloads.SSHPublicKey{
	// 										{
	// 											KeyData: to.Ptr("ssh-rsa public key"),
	// 									}},
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_D8s_v3"),
	// 					},
	// 				},
	// 				CentralServer: &armworkloads.CentralServerConfiguration{
	// 					InstanceCount: to.Ptr[int64](1),
	// 					SubnetID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/vnet1/subnets/subnetId1"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSH: &armworkloads.SSHConfiguration{
	// 									PublicKeys: []*armworkloads.SSHPublicKey{
	// 										{
	// 											KeyData: to.Ptr("ssh-rsa public key"),
	// 									}},
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_D8s_v3"),
	// 					},
	// 				},
	// 				DatabaseServer: &armworkloads.DatabaseConfiguration{
	// 					DatabaseType: to.Ptr(armworkloads.SAPDatabaseTypeHANA),
	// 					InstanceCount: to.Ptr[int64](1),
	// 					SubnetID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/vnet1/subnets/subnetId2"),
	// 					VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
	// 						ImageReference: &armworkloads.ImageReference{
	// 							Offer: to.Ptr("RHEL-SAP"),
	// 							Publisher: to.Ptr("RedHat"),
	// 							SKU: to.Ptr("7.4"),
	// 							Version: to.Ptr("7.4.2019062505"),
	// 						},
	// 						OSProfile: &armworkloads.OSProfile{
	// 							AdminUsername: to.Ptr("{your-username}"),
	// 							OSConfiguration: &armworkloads.LinuxConfiguration{
	// 								OSType: to.Ptr(armworkloads.OSTypeLinux),
	// 								DisablePasswordAuthentication: to.Ptr(true),
	// 								SSH: &armworkloads.SSHConfiguration{
	// 									PublicKeys: []*armworkloads.SSHPublicKey{
	// 										{
	// 											KeyData: to.Ptr("ssh-rsa public key"),
	// 									}},
	// 								},
	// 							},
	// 						},
	// 						VMSize: to.Ptr("Standard_D8s_v3"),
	// 					},
	// 				},
	// 			},
	// 			SoftwareConfiguration: &armworkloads.ServiceInitiatedSoftwareConfiguration{
	// 				SoftwareInstallationType: to.Ptr(armworkloads.SAPSoftwareInstallationTypeServiceInitiated),
	// 				BomURL: to.Ptr("https://myaccount.blob.core.windows.net/mycontainer/myblob"),
	// 				SapBitsStorageAccountID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/ajgupt-test/providers/Microsoft.Storage/storageAccounts/ajguptsavnet"),
	// 				SapFqdn: to.Ptr("sapsystem.contoso.net"),
	// 				SoftwareVersion: to.Ptr("SAP S/4HANA 2020 FPS01"),
	// 			},
	// 		},
	// 		Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
	// 		Health: to.Ptr(armworkloads.SAPHealthStateHealthy),
	// 		ManagedResourceGroupConfiguration: &armworkloads.ManagedRGConfiguration{
	// 			Name: to.Ptr("mrg-x00-6d875e77-e412-4d7d-9af4-8895278b4443"),
	// 		},
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		SapProduct: to.Ptr(armworkloads.SAPProductTypeS4HANA),
	// 		State: to.Ptr(armworkloads.SAPVirtualInstanceStateRegistrationComplete),
	// 		Status: to.Ptr(armworkloads.SAPVirtualInstanceStatusRunning),
	// 	},
	// }
}
Output:

func (*SAPVirtualInstancesClient) NewListByResourceGroupPager added in v0.2.0

NewListByResourceGroupPager - Gets all Virtual Instances for SAP solutions resources in a Resource Group.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • options - SAPVirtualInstancesClientListByResourceGroupOptions contains the optional parameters for the SAPVirtualInstancesClient.NewListByResourceGroupPager method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPVirtualInstances_ListByResourceGroup.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPVirtualInstancesClient("6d875e77-e412-4d7d-9af4-8895278b4443", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	pager := client.NewListByResourceGroupPager("test-rg", nil)
	for pager.More() {
		page, err := pager.NextPage(ctx)
		if err != nil {
			log.Fatalf("failed to advance page: %v", err)
		}
		for _, v := range page.Value {
			// You could use page here. We use blank identifier for just demo purposes.
			_ = v
		}
		// If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
		// page.SAPVirtualInstanceList = armworkloads.SAPVirtualInstanceList{
		// 	Value: []*armworkloads.SAPVirtualInstance{
		// 		{
		// 			Name: to.Ptr("X00"),
		// 			Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances"),
		// 			ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00"),
		// 			SystemData: &armworkloads.SystemData{
		// 				CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
		// 				CreatedBy: to.Ptr("user@xyz.com"),
		// 				CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
		// 				LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
		// 				LastModifiedBy: to.Ptr("user@xyz.com"),
		// 				LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
		// 			},
		// 			Location: to.Ptr("westcentralus"),
		// 			Tags: map[string]*string{
		// 			},
		// 			Properties: &armworkloads.SAPVirtualInstanceProperties{
		// 				Configuration: &armworkloads.DeploymentConfiguration{
		// 					ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeployment),
		// 					AppLocation: to.Ptr("eastus"),
		// 					InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
		// 						AppResourceGroup: to.Ptr("X00-RG"),
		// 						DeploymentType: to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
		// 						ApplicationServer: &armworkloads.ApplicationServerConfiguration{
		// 							InstanceCount: to.Ptr[int64](10),
		// 							SubnetID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/vnet1/subnets/subnetId3"),
		// 							VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
		// 								ImageReference: &armworkloads.ImageReference{
		// 									Offer: to.Ptr("RHEL-SAP"),
		// 									Publisher: to.Ptr("RedHat"),
		// 									SKU: to.Ptr("7.4"),
		// 									Version: to.Ptr("7.4.2019062505"),
		// 								},
		// 								OSProfile: &armworkloads.OSProfile{
		// 									AdminUsername: to.Ptr("{your-username}"),
		// 									OSConfiguration: &armworkloads.LinuxConfiguration{
		// 										OSType: to.Ptr(armworkloads.OSTypeLinux),
		// 										DisablePasswordAuthentication: to.Ptr(true),
		// 										SSH: &armworkloads.SSHConfiguration{
		// 											PublicKeys: []*armworkloads.SSHPublicKey{
		// 												{
		// 													KeyData: to.Ptr("ssh-rsa public key"),
		// 											}},
		// 										},
		// 									},
		// 								},
		// 								VMSize: to.Ptr("Standard_D8s_v3"),
		// 							},
		// 						},
		// 						CentralServer: &armworkloads.CentralServerConfiguration{
		// 							InstanceCount: to.Ptr[int64](1),
		// 							SubnetID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/vnet1/subnets/subnetId1"),
		// 							VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
		// 								ImageReference: &armworkloads.ImageReference{
		// 									Offer: to.Ptr("RHEL-SAP"),
		// 									Publisher: to.Ptr("RedHat"),
		// 									SKU: to.Ptr("7.4"),
		// 									Version: to.Ptr("7.4.2019062505"),
		// 								},
		// 								OSProfile: &armworkloads.OSProfile{
		// 									AdminUsername: to.Ptr("{your-username}"),
		// 									OSConfiguration: &armworkloads.LinuxConfiguration{
		// 										OSType: to.Ptr(armworkloads.OSTypeLinux),
		// 										DisablePasswordAuthentication: to.Ptr(true),
		// 										SSH: &armworkloads.SSHConfiguration{
		// 											PublicKeys: []*armworkloads.SSHPublicKey{
		// 												{
		// 													KeyData: to.Ptr("ssh-rsa public key"),
		// 											}},
		// 										},
		// 									},
		// 								},
		// 								VMSize: to.Ptr("Standard_D8s_v3"),
		// 							},
		// 						},
		// 						DatabaseServer: &armworkloads.DatabaseConfiguration{
		// 							DatabaseType: to.Ptr(armworkloads.SAPDatabaseTypeHANA),
		// 							InstanceCount: to.Ptr[int64](1),
		// 							SubnetID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/vnet1/subnets/subnetId2"),
		// 							VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
		// 								ImageReference: &armworkloads.ImageReference{
		// 									Offer: to.Ptr("RHEL-SAP"),
		// 									Publisher: to.Ptr("RedHat"),
		// 									SKU: to.Ptr("7.4"),
		// 									Version: to.Ptr("7.4.2019062505"),
		// 								},
		// 								OSProfile: &armworkloads.OSProfile{
		// 									AdminUsername: to.Ptr("{your-username}"),
		// 									OSConfiguration: &armworkloads.LinuxConfiguration{
		// 										OSType: to.Ptr(armworkloads.OSTypeLinux),
		// 										DisablePasswordAuthentication: to.Ptr(true),
		// 										SSH: &armworkloads.SSHConfiguration{
		// 											PublicKeys: []*armworkloads.SSHPublicKey{
		// 												{
		// 													KeyData: to.Ptr("ssh-rsa public key"),
		// 											}},
		// 										},
		// 									},
		// 								},
		// 								VMSize: to.Ptr("Standard_D8s_v3"),
		// 							},
		// 						},
		// 					},
		// 					SoftwareConfiguration: &armworkloads.ServiceInitiatedSoftwareConfiguration{
		// 						SoftwareInstallationType: to.Ptr(armworkloads.SAPSoftwareInstallationTypeServiceInitiated),
		// 						BomURL: to.Ptr("https://myaccount.blob.core.windows.net/mycontainer/myblob"),
		// 						SapBitsStorageAccountID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/ajgupt-test/providers/Microsoft.Storage/storageAccounts/ajguptsavnet"),
		// 						SapFqdn: to.Ptr("sapsystem.contoso.net"),
		// 						SoftwareVersion: to.Ptr("SAP S/4HANA 2020 FPS01"),
		// 					},
		// 				},
		// 				Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
		// 				Health: to.Ptr(armworkloads.SAPHealthStateHealthy),
		// 				ManagedResourceGroupConfiguration: &armworkloads.ManagedRGConfiguration{
		// 					Name: to.Ptr("mrg-x00-6d875e77-e412-4d7d-9af4-8895278b4443"),
		// 				},
		// 				ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
		// 				SapProduct: to.Ptr(armworkloads.SAPProductTypeS4HANA),
		// 				State: to.Ptr(armworkloads.SAPVirtualInstanceStateRegistrationComplete),
		// 				Status: to.Ptr(armworkloads.SAPVirtualInstanceStatusRunning),
		// 			},
		// 		},
		// 		{
		// 			Name: to.Ptr("X01"),
		// 			Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances"),
		// 			ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X01"),
		// 			SystemData: &armworkloads.SystemData{
		// 				CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
		// 				CreatedBy: to.Ptr("user@xyz.com"),
		// 				CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
		// 				LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
		// 				LastModifiedBy: to.Ptr("user@xyz.com"),
		// 				LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
		// 			},
		// 			Location: to.Ptr("westcentralus"),
		// 			Tags: map[string]*string{
		// 			},
		// 			Properties: &armworkloads.SAPVirtualInstanceProperties{
		// 				Configuration: &armworkloads.DeploymentConfiguration{
		// 					ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeployment),
		// 					AppLocation: to.Ptr("eastus"),
		// 					InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
		// 						AppResourceGroup: to.Ptr("X00-RG"),
		// 						DeploymentType: to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
		// 						ApplicationServer: &armworkloads.ApplicationServerConfiguration{
		// 							InstanceCount: to.Ptr[int64](10),
		// 							SubnetID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/vnet1/subnets/subnetId3"),
		// 							VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
		// 								ImageReference: &armworkloads.ImageReference{
		// 									Offer: to.Ptr("RHEL-SAP"),
		// 									Publisher: to.Ptr("RedHat"),
		// 									SKU: to.Ptr("7.4"),
		// 									Version: to.Ptr("7.4.2019062505"),
		// 								},
		// 								OSProfile: &armworkloads.OSProfile{
		// 									AdminUsername: to.Ptr("{your-username}"),
		// 									OSConfiguration: &armworkloads.LinuxConfiguration{
		// 										OSType: to.Ptr(armworkloads.OSTypeLinux),
		// 										DisablePasswordAuthentication: to.Ptr(true),
		// 										SSH: &armworkloads.SSHConfiguration{
		// 											PublicKeys: []*armworkloads.SSHPublicKey{
		// 												{
		// 													KeyData: to.Ptr("ssh-rsa public key"),
		// 											}},
		// 										},
		// 									},
		// 								},
		// 								VMSize: to.Ptr("Standard_D8s_v3"),
		// 							},
		// 						},
		// 						CentralServer: &armworkloads.CentralServerConfiguration{
		// 							InstanceCount: to.Ptr[int64](1),
		// 							SubnetID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/vnet1/subnets/subnetId1"),
		// 							VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
		// 								ImageReference: &armworkloads.ImageReference{
		// 									Offer: to.Ptr("RHEL-SAP"),
		// 									Publisher: to.Ptr("RedHat"),
		// 									SKU: to.Ptr("7.4"),
		// 									Version: to.Ptr("7.4.2019062505"),
		// 								},
		// 								OSProfile: &armworkloads.OSProfile{
		// 									AdminUsername: to.Ptr("{your-username}"),
		// 									OSConfiguration: &armworkloads.LinuxConfiguration{
		// 										OSType: to.Ptr(armworkloads.OSTypeLinux),
		// 										DisablePasswordAuthentication: to.Ptr(true),
		// 										SSH: &armworkloads.SSHConfiguration{
		// 											PublicKeys: []*armworkloads.SSHPublicKey{
		// 												{
		// 													KeyData: to.Ptr("ssh-rsa public key"),
		// 											}},
		// 										},
		// 									},
		// 								},
		// 								VMSize: to.Ptr("Standard_D8s_v3"),
		// 							},
		// 						},
		// 						DatabaseServer: &armworkloads.DatabaseConfiguration{
		// 							DatabaseType: to.Ptr(armworkloads.SAPDatabaseTypeHANA),
		// 							InstanceCount: to.Ptr[int64](1),
		// 							SubnetID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/vnet1/subnets/subnetId2"),
		// 							VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
		// 								ImageReference: &armworkloads.ImageReference{
		// 									Offer: to.Ptr("RHEL-SAP"),
		// 									Publisher: to.Ptr("RedHat"),
		// 									SKU: to.Ptr("7.4"),
		// 									Version: to.Ptr("7.4.2019062505"),
		// 								},
		// 								OSProfile: &armworkloads.OSProfile{
		// 									AdminUsername: to.Ptr("{your-username}"),
		// 									OSConfiguration: &armworkloads.LinuxConfiguration{
		// 										OSType: to.Ptr(armworkloads.OSTypeLinux),
		// 										DisablePasswordAuthentication: to.Ptr(true),
		// 										SSH: &armworkloads.SSHConfiguration{
		// 											PublicKeys: []*armworkloads.SSHPublicKey{
		// 												{
		// 													KeyData: to.Ptr("ssh-rsa public key"),
		// 											}},
		// 										},
		// 									},
		// 								},
		// 								VMSize: to.Ptr("Standard_D8s_v3"),
		// 							},
		// 						},
		// 					},
		// 					SoftwareConfiguration: &armworkloads.ServiceInitiatedSoftwareConfiguration{
		// 						SoftwareInstallationType: to.Ptr(armworkloads.SAPSoftwareInstallationTypeServiceInitiated),
		// 						BomURL: to.Ptr("https://myaccount.blob.core.windows.net/mycontainer/myblob"),
		// 						SapBitsStorageAccountID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/ajgupt-test/providers/Microsoft.Storage/storageAccounts/ajguptsavnet"),
		// 						SapFqdn: to.Ptr("sapsystem.contoso.net"),
		// 						SoftwareVersion: to.Ptr("SAP S/4HANA 2020 FPS01"),
		// 					},
		// 				},
		// 				Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
		// 				Health: to.Ptr(armworkloads.SAPHealthStateHealthy),
		// 				ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
		// 				SapProduct: to.Ptr(armworkloads.SAPProductTypeS4HANA),
		// 				State: to.Ptr(armworkloads.SAPVirtualInstanceStateRegistrationComplete),
		// 				Status: to.Ptr(armworkloads.SAPVirtualInstanceStatusRunning),
		// 			},
		// 	}},
		// }
	}
}
Output:

func (*SAPVirtualInstancesClient) NewListBySubscriptionPager added in v0.2.0

NewListBySubscriptionPager - Gets all Virtual Instances for SAP solutions resources in a Subscription.

Generated from API version 2022-11-01-preview

  • options - SAPVirtualInstancesClientListBySubscriptionOptions contains the optional parameters for the SAPVirtualInstancesClient.NewListBySubscriptionPager method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPVirtualInstances_ListBySubscription.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPVirtualInstancesClient("6d875e77-e412-4d7d-9af4-8895278b4443", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	pager := client.NewListBySubscriptionPager(nil)
	for pager.More() {
		page, err := pager.NextPage(ctx)
		if err != nil {
			log.Fatalf("failed to advance page: %v", err)
		}
		for _, v := range page.Value {
			// You could use page here. We use blank identifier for just demo purposes.
			_ = v
		}
		// If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
		// page.SAPVirtualInstanceList = armworkloads.SAPVirtualInstanceList{
		// 	Value: []*armworkloads.SAPVirtualInstance{
		// 		{
		// 			Name: to.Ptr("X00"),
		// 			Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances"),
		// 			ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00"),
		// 			SystemData: &armworkloads.SystemData{
		// 				CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
		// 				CreatedBy: to.Ptr("user@xyz.com"),
		// 				CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
		// 				LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
		// 				LastModifiedBy: to.Ptr("user@xyz.com"),
		// 				LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
		// 			},
		// 			Location: to.Ptr("westcentralus"),
		// 			Tags: map[string]*string{
		// 			},
		// 			Properties: &armworkloads.SAPVirtualInstanceProperties{
		// 				Configuration: &armworkloads.DeploymentConfiguration{
		// 					ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeployment),
		// 					AppLocation: to.Ptr("eastus"),
		// 					InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
		// 						AppResourceGroup: to.Ptr("X00-RG"),
		// 						DeploymentType: to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
		// 						ApplicationServer: &armworkloads.ApplicationServerConfiguration{
		// 							InstanceCount: to.Ptr[int64](10),
		// 							SubnetID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/vnet1/subnets/subnetId3"),
		// 							VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
		// 								ImageReference: &armworkloads.ImageReference{
		// 									Offer: to.Ptr("RHEL-SAP"),
		// 									Publisher: to.Ptr("RedHat"),
		// 									SKU: to.Ptr("7.4"),
		// 									Version: to.Ptr("7.4.2019062505"),
		// 								},
		// 								OSProfile: &armworkloads.OSProfile{
		// 									AdminUsername: to.Ptr("{your-username}"),
		// 									OSConfiguration: &armworkloads.LinuxConfiguration{
		// 										OSType: to.Ptr(armworkloads.OSTypeLinux),
		// 										DisablePasswordAuthentication: to.Ptr(true),
		// 										SSH: &armworkloads.SSHConfiguration{
		// 											PublicKeys: []*armworkloads.SSHPublicKey{
		// 												{
		// 													KeyData: to.Ptr("ssh-rsa public key"),
		// 											}},
		// 										},
		// 									},
		// 								},
		// 								VMSize: to.Ptr("Standard_D8s_v3"),
		// 							},
		// 						},
		// 						CentralServer: &armworkloads.CentralServerConfiguration{
		// 							InstanceCount: to.Ptr[int64](1),
		// 							SubnetID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/vnet1/subnets/subnetId1"),
		// 							VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
		// 								ImageReference: &armworkloads.ImageReference{
		// 									Offer: to.Ptr("RHEL-SAP"),
		// 									Publisher: to.Ptr("RedHat"),
		// 									SKU: to.Ptr("7.4"),
		// 									Version: to.Ptr("7.4.2019062505"),
		// 								},
		// 								OSProfile: &armworkloads.OSProfile{
		// 									AdminUsername: to.Ptr("{your-username}"),
		// 									OSConfiguration: &armworkloads.LinuxConfiguration{
		// 										OSType: to.Ptr(armworkloads.OSTypeLinux),
		// 										DisablePasswordAuthentication: to.Ptr(true),
		// 										SSH: &armworkloads.SSHConfiguration{
		// 											PublicKeys: []*armworkloads.SSHPublicKey{
		// 												{
		// 													KeyData: to.Ptr("ssh-rsa public key"),
		// 											}},
		// 										},
		// 									},
		// 								},
		// 								VMSize: to.Ptr("Standard_D8s_v3"),
		// 							},
		// 						},
		// 						DatabaseServer: &armworkloads.DatabaseConfiguration{
		// 							DatabaseType: to.Ptr(armworkloads.SAPDatabaseTypeHANA),
		// 							InstanceCount: to.Ptr[int64](1),
		// 							SubnetID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/vnet1/subnets/subnetId2"),
		// 							VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
		// 								ImageReference: &armworkloads.ImageReference{
		// 									Offer: to.Ptr("RHEL-SAP"),
		// 									Publisher: to.Ptr("RedHat"),
		// 									SKU: to.Ptr("7.4"),
		// 									Version: to.Ptr("7.4.2019062505"),
		// 								},
		// 								OSProfile: &armworkloads.OSProfile{
		// 									AdminUsername: to.Ptr("{your-username}"),
		// 									OSConfiguration: &armworkloads.LinuxConfiguration{
		// 										OSType: to.Ptr(armworkloads.OSTypeLinux),
		// 										DisablePasswordAuthentication: to.Ptr(true),
		// 										SSH: &armworkloads.SSHConfiguration{
		// 											PublicKeys: []*armworkloads.SSHPublicKey{
		// 												{
		// 													KeyData: to.Ptr("ssh-rsa public key"),
		// 											}},
		// 										},
		// 									},
		// 								},
		// 								VMSize: to.Ptr("Standard_D8s_v3"),
		// 							},
		// 						},
		// 					},
		// 					SoftwareConfiguration: &armworkloads.ServiceInitiatedSoftwareConfiguration{
		// 						SoftwareInstallationType: to.Ptr(armworkloads.SAPSoftwareInstallationTypeServiceInitiated),
		// 						BomURL: to.Ptr("https://myaccount.blob.core.windows.net/mycontainer/myblob"),
		// 						SapBitsStorageAccountID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/ajgupt-test/providers/Microsoft.Storage/storageAccounts/ajguptsavnet"),
		// 						SapFqdn: to.Ptr("sapsystem.contoso.net"),
		// 						SoftwareVersion: to.Ptr("SAP S/4HANA 2020 FPS01"),
		// 					},
		// 				},
		// 				Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
		// 				Health: to.Ptr(armworkloads.SAPHealthStateHealthy),
		// 				ManagedResourceGroupConfiguration: &armworkloads.ManagedRGConfiguration{
		// 					Name: to.Ptr("mrg-x00-6d875e77-e412-4d7d-9af4-8895278b4443"),
		// 				},
		// 				ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
		// 				SapProduct: to.Ptr(armworkloads.SAPProductTypeS4HANA),
		// 				State: to.Ptr(armworkloads.SAPVirtualInstanceStateRegistrationComplete),
		// 				Status: to.Ptr(armworkloads.SAPVirtualInstanceStatusRunning),
		// 			},
		// 		},
		// 		{
		// 			Name: to.Ptr("X01"),
		// 			Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances"),
		// 			ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X01"),
		// 			SystemData: &armworkloads.SystemData{
		// 				CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
		// 				CreatedBy: to.Ptr("user@xyz.com"),
		// 				CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
		// 				LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
		// 				LastModifiedBy: to.Ptr("user@xyz.com"),
		// 				LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
		// 			},
		// 			Location: to.Ptr("westcentralus"),
		// 			Tags: map[string]*string{
		// 			},
		// 			Properties: &armworkloads.SAPVirtualInstanceProperties{
		// 				Configuration: &armworkloads.DeploymentConfiguration{
		// 					ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeployment),
		// 					AppLocation: to.Ptr("eastus"),
		// 					InfrastructureConfiguration: &armworkloads.ThreeTierConfiguration{
		// 						AppResourceGroup: to.Ptr("X00-RG"),
		// 						DeploymentType: to.Ptr(armworkloads.SAPDeploymentTypeThreeTier),
		// 						ApplicationServer: &armworkloads.ApplicationServerConfiguration{
		// 							InstanceCount: to.Ptr[int64](10),
		// 							SubnetID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/vnet1/subnets/subnetId3"),
		// 							VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
		// 								ImageReference: &armworkloads.ImageReference{
		// 									Offer: to.Ptr("RHEL-SAP"),
		// 									Publisher: to.Ptr("RedHat"),
		// 									SKU: to.Ptr("7.4"),
		// 									Version: to.Ptr("7.4.2019062505"),
		// 								},
		// 								OSProfile: &armworkloads.OSProfile{
		// 									AdminUsername: to.Ptr("{your-username}"),
		// 									OSConfiguration: &armworkloads.LinuxConfiguration{
		// 										OSType: to.Ptr(armworkloads.OSTypeLinux),
		// 										DisablePasswordAuthentication: to.Ptr(true),
		// 										SSH: &armworkloads.SSHConfiguration{
		// 											PublicKeys: []*armworkloads.SSHPublicKey{
		// 												{
		// 													KeyData: to.Ptr("ssh-rsa public key"),
		// 											}},
		// 										},
		// 									},
		// 								},
		// 								VMSize: to.Ptr("Standard_D8s_v3"),
		// 							},
		// 						},
		// 						CentralServer: &armworkloads.CentralServerConfiguration{
		// 							InstanceCount: to.Ptr[int64](1),
		// 							SubnetID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/vnet1/subnets/subnetId1"),
		// 							VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
		// 								ImageReference: &armworkloads.ImageReference{
		// 									Offer: to.Ptr("RHEL-SAP"),
		// 									Publisher: to.Ptr("RedHat"),
		// 									SKU: to.Ptr("7.4"),
		// 									Version: to.Ptr("7.4.2019062505"),
		// 								},
		// 								OSProfile: &armworkloads.OSProfile{
		// 									AdminUsername: to.Ptr("{your-username}"),
		// 									OSConfiguration: &armworkloads.LinuxConfiguration{
		// 										OSType: to.Ptr(armworkloads.OSTypeLinux),
		// 										DisablePasswordAuthentication: to.Ptr(true),
		// 										SSH: &armworkloads.SSHConfiguration{
		// 											PublicKeys: []*armworkloads.SSHPublicKey{
		// 												{
		// 													KeyData: to.Ptr("ssh-rsa public key"),
		// 											}},
		// 										},
		// 									},
		// 								},
		// 								VMSize: to.Ptr("Standard_D8s_v3"),
		// 							},
		// 						},
		// 						DatabaseServer: &armworkloads.DatabaseConfiguration{
		// 							DatabaseType: to.Ptr(armworkloads.SAPDatabaseTypeHANA),
		// 							InstanceCount: to.Ptr[int64](1),
		// 							SubnetID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Networks/virtualNetworks/vnet1/subnets/subnetId2"),
		// 							VirtualMachineConfiguration: &armworkloads.VirtualMachineConfiguration{
		// 								ImageReference: &armworkloads.ImageReference{
		// 									Offer: to.Ptr("RHEL-SAP"),
		// 									Publisher: to.Ptr("RedHat"),
		// 									SKU: to.Ptr("7.4"),
		// 									Version: to.Ptr("7.4.2019062505"),
		// 								},
		// 								OSProfile: &armworkloads.OSProfile{
		// 									AdminUsername: to.Ptr("{your-username}"),
		// 									OSConfiguration: &armworkloads.LinuxConfiguration{
		// 										OSType: to.Ptr(armworkloads.OSTypeLinux),
		// 										DisablePasswordAuthentication: to.Ptr(true),
		// 										SSH: &armworkloads.SSHConfiguration{
		// 											PublicKeys: []*armworkloads.SSHPublicKey{
		// 												{
		// 													KeyData: to.Ptr("ssh-rsa public key"),
		// 											}},
		// 										},
		// 									},
		// 								},
		// 								VMSize: to.Ptr("Standard_D8s_v3"),
		// 							},
		// 						},
		// 					},
		// 					SoftwareConfiguration: &armworkloads.ServiceInitiatedSoftwareConfiguration{
		// 						SoftwareInstallationType: to.Ptr(armworkloads.SAPSoftwareInstallationTypeServiceInitiated),
		// 						BomURL: to.Ptr("https://myaccount.blob.core.windows.net/mycontainer/myblob"),
		// 						SapBitsStorageAccountID: to.Ptr("/subscriptions/49d64d54-e966-4c46-a868-1999802b762c/resourceGroups/ajgupt-test/providers/Microsoft.Storage/storageAccounts/ajguptsavnet"),
		// 						SapFqdn: to.Ptr("sapsystem.contoso.net"),
		// 						SoftwareVersion: to.Ptr("SAP S/4HANA 2020 FPS01"),
		// 					},
		// 				},
		// 				Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
		// 				Health: to.Ptr(armworkloads.SAPHealthStateHealthy),
		// 				ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
		// 				SapProduct: to.Ptr(armworkloads.SAPProductTypeS4HANA),
		// 				State: to.Ptr(armworkloads.SAPVirtualInstanceStateRegistrationComplete),
		// 				Status: to.Ptr(armworkloads.SAPVirtualInstanceStatusRunning),
		// 			},
		// 	}},
		// }
	}
}
Output:

func (*SAPVirtualInstancesClient) Update added in v0.2.0

Update - Updates a Virtual Instance for SAP solutions resource If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • sapVirtualInstanceName - The name of the Virtual Instances for SAP solutions resource
  • body - Request body to update a Virtual Instance for SAP solutions resource.
  • options - SAPVirtualInstancesClientUpdateOptions contains the optional parameters for the SAPVirtualInstancesClient.Update method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/sapvirtualinstances/SAPVirtualInstances_Update.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSAPVirtualInstancesClient("8e17e36c-42e9-4cd5-a078-7b44883414e0", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := client.Update(ctx, "test-rg", "X00", armworkloads.UpdateSAPVirtualInstanceRequest{
		Identity: &armworkloads.UserAssignedServiceIdentity{
			Type: to.Ptr(armworkloads.ManagedServiceIdentityTypeNone),
		},
		Tags: map[string]*string{
			"key1": to.Ptr("svi1"),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SAPVirtualInstance = armworkloads.SAPVirtualInstance{
	// 	Name: to.Ptr("X00"),
	// 	Type: to.Ptr("Microsoft.Workloads/sapVirtualInstances"),
	// 	ID: to.Ptr("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.Workloads/sapVirtualInstances/X00"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Location: to.Ptr("westcentralus"),
	// 	Tags: map[string]*string{
	// 		"key1": to.Ptr("svi1"),
	// 	},
	// 	Identity: &armworkloads.UserAssignedServiceIdentity{
	// 		Type: to.Ptr(armworkloads.ManagedServiceIdentityTypeNone),
	// 	},
	// 	Properties: &armworkloads.SAPVirtualInstanceProperties{
	// 		Configuration: &armworkloads.DeploymentConfiguration{
	// 			ConfigurationType: to.Ptr(armworkloads.SAPConfigurationTypeDeployment),
	// 		},
	// 		Environment: to.Ptr(armworkloads.SAPEnvironmentTypeProd),
	// 		Health: to.Ptr(armworkloads.SAPHealthStateUnknown),
	// 		ManagedResourceGroupConfiguration: &armworkloads.ManagedRGConfiguration{
	// 			Name: to.Ptr("mrg-x00-6d875e77-e412-4d7d-9af4-8895278b4443"),
	// 		},
	// 		ProvisioningState: to.Ptr(armworkloads.SapVirtualInstanceProvisioningStateSucceeded),
	// 		SapProduct: to.Ptr(armworkloads.SAPProductTypeS4HANA),
	// 		State: to.Ptr(armworkloads.SAPVirtualInstanceStateInfrastructureDeploymentPending),
	// 		Status: to.Ptr(armworkloads.SAPVirtualInstanceStatusStarting),
	// 	},
	// }
}
Output:

type SAPVirtualInstancesClientBeginCreateOptions added in v0.2.0

type SAPVirtualInstancesClientBeginCreateOptions struct {
	// Resumes the LRO from the provided token.
	ResumeToken string
}

SAPVirtualInstancesClientBeginCreateOptions contains the optional parameters for the SAPVirtualInstancesClient.BeginCreate method.

type SAPVirtualInstancesClientBeginDeleteOptions added in v0.2.0

type SAPVirtualInstancesClientBeginDeleteOptions struct {
	// Resumes the LRO from the provided token.
	ResumeToken string
}

SAPVirtualInstancesClientBeginDeleteOptions contains the optional parameters for the SAPVirtualInstancesClient.BeginDelete method.

type SAPVirtualInstancesClientBeginStartOptions added in v0.2.0

type SAPVirtualInstancesClientBeginStartOptions struct {
	// Resumes the LRO from the provided token.
	ResumeToken string
}

SAPVirtualInstancesClientBeginStartOptions contains the optional parameters for the SAPVirtualInstancesClient.BeginStart method.

type SAPVirtualInstancesClientBeginStopOptions added in v0.2.0

type SAPVirtualInstancesClientBeginStopOptions struct {
	// The Virtual Instance for SAP solutions resource stop request body.
	Body *StopRequest
	// Resumes the LRO from the provided token.
	ResumeToken string
}

SAPVirtualInstancesClientBeginStopOptions contains the optional parameters for the SAPVirtualInstancesClient.BeginStop method.

type SAPVirtualInstancesClientCreateResponse added in v0.2.0

type SAPVirtualInstancesClientCreateResponse struct {
	SAPVirtualInstance
}

SAPVirtualInstancesClientCreateResponse contains the response from method SAPVirtualInstancesClient.BeginCreate.

type SAPVirtualInstancesClientDeleteResponse added in v0.2.0

type SAPVirtualInstancesClientDeleteResponse struct {
	OperationStatusResult
}

SAPVirtualInstancesClientDeleteResponse contains the response from method SAPVirtualInstancesClient.BeginDelete.

type SAPVirtualInstancesClientGetOptions added in v0.2.0

type SAPVirtualInstancesClientGetOptions struct {
}

SAPVirtualInstancesClientGetOptions contains the optional parameters for the SAPVirtualInstancesClient.Get method.

type SAPVirtualInstancesClientGetResponse added in v0.2.0

type SAPVirtualInstancesClientGetResponse struct {
	SAPVirtualInstance
}

SAPVirtualInstancesClientGetResponse contains the response from method SAPVirtualInstancesClient.Get.

type SAPVirtualInstancesClientListByResourceGroupOptions added in v0.2.0

type SAPVirtualInstancesClientListByResourceGroupOptions struct {
}

SAPVirtualInstancesClientListByResourceGroupOptions contains the optional parameters for the SAPVirtualInstancesClient.NewListByResourceGroupPager method.

type SAPVirtualInstancesClientListByResourceGroupResponse added in v0.2.0

type SAPVirtualInstancesClientListByResourceGroupResponse struct {
	SAPVirtualInstanceList
}

SAPVirtualInstancesClientListByResourceGroupResponse contains the response from method SAPVirtualInstancesClient.NewListByResourceGroupPager.

type SAPVirtualInstancesClientListBySubscriptionOptions added in v0.2.0

type SAPVirtualInstancesClientListBySubscriptionOptions struct {
}

SAPVirtualInstancesClientListBySubscriptionOptions contains the optional parameters for the SAPVirtualInstancesClient.NewListBySubscriptionPager method.

type SAPVirtualInstancesClientListBySubscriptionResponse added in v0.2.0

type SAPVirtualInstancesClientListBySubscriptionResponse struct {
	SAPVirtualInstanceList
}

SAPVirtualInstancesClientListBySubscriptionResponse contains the response from method SAPVirtualInstancesClient.NewListBySubscriptionPager.

type SAPVirtualInstancesClientStartResponse added in v0.2.0

type SAPVirtualInstancesClientStartResponse struct {
	OperationStatusResult
}

SAPVirtualInstancesClientStartResponse contains the response from method SAPVirtualInstancesClient.BeginStart.

type SAPVirtualInstancesClientStopResponse added in v0.2.0

type SAPVirtualInstancesClientStopResponse struct {
	OperationStatusResult
}

SAPVirtualInstancesClientStopResponse contains the response from method SAPVirtualInstancesClient.BeginStop.

type SAPVirtualInstancesClientUpdateOptions added in v0.2.0

type SAPVirtualInstancesClientUpdateOptions struct {
}

SAPVirtualInstancesClientUpdateOptions contains the optional parameters for the SAPVirtualInstancesClient.Update method.

type SAPVirtualInstancesClientUpdateResponse added in v0.2.0

type SAPVirtualInstancesClientUpdateResponse struct {
	SAPVirtualInstance
}

SAPVirtualInstancesClientUpdateResponse contains the response from method SAPVirtualInstancesClient.Update.

type SSHConfiguration added in v0.2.0

type SSHConfiguration struct {
	// The list of SSH public keys used to authenticate with linux based VMs.
	PublicKeys []*SSHPublicKey `json:"publicKeys,omitempty"`
}

SSHConfiguration - SSH configuration for Linux based VMs running on Azure

func (SSHConfiguration) MarshalJSON added in v0.2.0

func (s SSHConfiguration) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SSHConfiguration.

func (*SSHConfiguration) UnmarshalJSON added in v0.2.0

func (s *SSHConfiguration) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SSHConfiguration.

type SSHKeyPair added in v0.2.0

type SSHKeyPair struct {
	// SSH private key.
	PrivateKey *string `json:"privateKey,omitempty"`

	// SSH public key
	PublicKey *string `json:"publicKey,omitempty"`
}

SSHKeyPair - The SSH Key-pair used to authenticate with the VM. The key needs to be at least 2048-bit and in ssh-rsa format. For creating ssh keys, see Create SSH keys on Linux and Mac for Linux VMs in Azure [https://docs.microsoft.com/azure/virtual-machines/linux/create-ssh-keys-detailed].

func (SSHKeyPair) MarshalJSON added in v0.2.0

func (s SSHKeyPair) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SSHKeyPair.

func (*SSHKeyPair) UnmarshalJSON added in v0.2.0

func (s *SSHKeyPair) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SSHKeyPair.

type SSHPublicKey added in v0.2.0

type SSHPublicKey struct {
	// SSH public key certificate used to authenticate with the VM through ssh. The key needs to be at least 2048-bit and in ssh-rsa
	// format.
	// For creating ssh keys, see Create SSH keys on Linux and Mac for Linux VMs in Azure [https://docs.microsoft.com/azure/virtual-machines/linux/create-ssh-keys-detailed].
	KeyData *string `json:"keyData,omitempty"`
}

SSHPublicKey - Contains information about SSH certificate public key and the path on the Linux VM where the public key is placed.

func (SSHPublicKey) MarshalJSON added in v0.2.0

func (s SSHPublicKey) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SSHPublicKey.

func (*SSHPublicKey) UnmarshalJSON added in v0.2.0

func (s *SSHPublicKey) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SSHPublicKey.

type SSLPreference added in v0.3.0

type SSLPreference string

SSLPreference - Gets or sets certificate preference if secure communication is enabled.

const (
	SSLPreferenceDisabled          SSLPreference = "Disabled"
	SSLPreferenceRootCertificate   SSLPreference = "RootCertificate"
	SSLPreferenceServerCertificate SSLPreference = "ServerCertificate"
)

func PossibleSSLPreferenceValues added in v0.3.0

func PossibleSSLPreferenceValues() []SSLPreference

PossibleSSLPreferenceValues returns the possible values for the SSLPreference const type.

type SapLandscapeMonitor added in v0.3.0

type SapLandscapeMonitor struct {
	// Sap Landscape Monitor properties
	Properties *SapLandscapeMonitorProperties `json:"properties,omitempty"`

	// READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
	ID *string `json:"id,omitempty" azure:"ro"`

	// READ-ONLY; The name of the resource
	Name *string `json:"name,omitempty" azure:"ro"`

	// READ-ONLY; Azure Resource Manager metadata containing createdBy and modifiedBy information.
	SystemData *SystemData `json:"systemData,omitempty" azure:"ro"`

	// READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
	Type *string `json:"type,omitempty" azure:"ro"`
}

SapLandscapeMonitor - configuration associated with SAP Landscape Monitor Dashboard.

func (SapLandscapeMonitor) MarshalJSON added in v0.3.0

func (s SapLandscapeMonitor) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SapLandscapeMonitor.

func (*SapLandscapeMonitor) UnmarshalJSON added in v0.3.0

func (s *SapLandscapeMonitor) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SapLandscapeMonitor.

type SapLandscapeMonitorClient added in v0.3.0

type SapLandscapeMonitorClient struct {
	// contains filtered or unexported fields
}

SapLandscapeMonitorClient contains the methods for the SapLandscapeMonitor group. Don't use this type directly, use NewSapLandscapeMonitorClient() instead.

func NewSapLandscapeMonitorClient added in v0.3.0

func NewSapLandscapeMonitorClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*SapLandscapeMonitorClient, error)

NewSapLandscapeMonitorClient creates a new instance of SapLandscapeMonitorClient with the specified values.

  • subscriptionID - The ID of the target subscription.
  • credential - used to authorize requests. Usually a credential from azidentity.
  • options - pass nil to accept the default values.

func (*SapLandscapeMonitorClient) Create added in v0.3.0

func (client *SapLandscapeMonitorClient) Create(ctx context.Context, resourceGroupName string, monitorName string, sapLandscapeMonitorParameter SapLandscapeMonitor, options *SapLandscapeMonitorClientCreateOptions) (SapLandscapeMonitorClientCreateResponse, error)

Create - Creates a SAP Landscape Monitor Dashboard for the specified subscription, resource group, and resource name. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • monitorName - Name of the SAP monitor resource.
  • sapLandscapeMonitorParameter - Request body representing a configuration for Sap Landscape Monitor Dashboard
  • options - SapLandscapeMonitorClientCreateOptions contains the optional parameters for the SapLandscapeMonitorClient.Create method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/workloadmonitor/SapLandscapeMonitor_Create.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSapLandscapeMonitorClient("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := client.Create(ctx, "myResourceGroup", "mySapMonitor", armworkloads.SapLandscapeMonitor{
		Properties: &armworkloads.SapLandscapeMonitorProperties{
			Grouping: &armworkloads.SapLandscapeMonitorPropertiesGrouping{
				Landscape: []*armworkloads.SapLandscapeMonitorSidMapping{
					{
						Name: to.Ptr("Prod"),
						TopSid: []*string{
							to.Ptr("SID1"),
							to.Ptr("SID2")},
					}},
				SapApplication: []*armworkloads.SapLandscapeMonitorSidMapping{
					{
						Name: to.Ptr("ERP1"),
						TopSid: []*string{
							to.Ptr("SID1"),
							to.Ptr("SID2")},
					}},
			},
			TopMetricsThresholds: []*armworkloads.SapLandscapeMonitorMetricThresholds{
				{
					Name:   to.Ptr("Instance Availability"),
					Green:  to.Ptr[float32](90),
					Red:    to.Ptr[float32](50),
					Yellow: to.Ptr[float32](75),
				}},
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SapLandscapeMonitor = armworkloads.SapLandscapeMonitor{
	// 	Name: to.Ptr("default"),
	// 	Type: to.Ptr("Microsoft.Workloads/monitors/sapLandscapeMonitor"),
	// 	ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/monitors/myMonitor/sapLandscapeMonitor/default"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Properties: &armworkloads.SapLandscapeMonitorProperties{
	// 		Grouping: &armworkloads.SapLandscapeMonitorPropertiesGrouping{
	// 			Landscape: []*armworkloads.SapLandscapeMonitorSidMapping{
	// 				{
	// 					Name: to.Ptr("Prod"),
	// 					TopSid: []*string{
	// 						to.Ptr("SID1"),
	// 						to.Ptr("SID2")},
	// 				}},
	// 				SapApplication: []*armworkloads.SapLandscapeMonitorSidMapping{
	// 					{
	// 						Name: to.Ptr("ERP1"),
	// 						TopSid: []*string{
	// 							to.Ptr("SID1"),
	// 							to.Ptr("SID2")},
	// 					}},
	// 				},
	// 				TopMetricsThresholds: []*armworkloads.SapLandscapeMonitorMetricThresholds{
	// 					{
	// 						Name: to.Ptr("Instance Availability"),
	// 						Green: to.Ptr[float32](90),
	// 						Red: to.Ptr[float32](50),
	// 						Yellow: to.Ptr[float32](75),
	// 				}},
	// 			},
	// 		}
}
Output:

func (*SapLandscapeMonitorClient) Delete added in v0.3.0

Delete - Deletes a SAP Landscape Monitor Dashboard with the specified subscription, resource group, and SAP monitor name. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • monitorName - Name of the SAP monitor resource.
  • options - SapLandscapeMonitorClientDeleteOptions contains the optional parameters for the SapLandscapeMonitorClient.Delete method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/workloadmonitor/SapLandscapeMonitor_Delete.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSapLandscapeMonitorClient("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	_, err = client.Delete(ctx, "myResourceGroup", "mySapMonitor", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
}
Output:

func (*SapLandscapeMonitorClient) Get added in v0.3.0

Get - Gets configuration values for Single Pane Of Glass for SAP monitor for the specified subscription, resource group, and resource name. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • monitorName - Name of the SAP monitor resource.
  • options - SapLandscapeMonitorClientGetOptions contains the optional parameters for the SapLandscapeMonitorClient.Get method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/workloadmonitor/SapLandscapeMonitor_Get.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSapLandscapeMonitorClient("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := client.Get(ctx, "myResourceGroup", "mySapMonitor", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SapLandscapeMonitor = armworkloads.SapLandscapeMonitor{
	// 	Name: to.Ptr("default"),
	// 	Type: to.Ptr("Microsoft.Workloads/monitors/sapLandscapeMonitor"),
	// 	ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/monitors/myMonitor/sapLandscapeMonitor/default"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Properties: &armworkloads.SapLandscapeMonitorProperties{
	// 		Grouping: &armworkloads.SapLandscapeMonitorPropertiesGrouping{
	// 			Landscape: []*armworkloads.SapLandscapeMonitorSidMapping{
	// 				{
	// 					Name: to.Ptr("Prod"),
	// 					TopSid: []*string{
	// 						to.Ptr("SID1"),
	// 						to.Ptr("SID2")},
	// 				}},
	// 				SapApplication: []*armworkloads.SapLandscapeMonitorSidMapping{
	// 					{
	// 						Name: to.Ptr("ERP1"),
	// 						TopSid: []*string{
	// 							to.Ptr("SID1"),
	// 							to.Ptr("SID2")},
	// 					}},
	// 				},
	// 				TopMetricsThresholds: []*armworkloads.SapLandscapeMonitorMetricThresholds{
	// 					{
	// 						Name: to.Ptr("Instance Availability"),
	// 						Green: to.Ptr[float32](90),
	// 						Red: to.Ptr[float32](50),
	// 						Yellow: to.Ptr[float32](75),
	// 				}},
	// 			},
	// 		}
}
Output:

func (*SapLandscapeMonitorClient) List added in v0.3.0

List - Gets configuration values for Single Pane Of Glass for SAP monitor for the specified subscription, resource group, and resource name. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • monitorName - Name of the SAP monitor resource.
  • options - SapLandscapeMonitorClientListOptions contains the optional parameters for the SapLandscapeMonitorClient.List method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/workloadmonitor/SapLandscapeMonitor_List.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSapLandscapeMonitorClient("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := client.List(ctx, "myResourceGroup", "mySapMonitor", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SapLandscapeMonitorListResult = armworkloads.SapLandscapeMonitorListResult{
	// 	Value: []*armworkloads.SapLandscapeMonitor{
	// 		{
	// 			Name: to.Ptr("default"),
	// 			Type: to.Ptr("Microsoft.Workloads/monitors/sapLandscapeMonitor"),
	// 			ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/monitors/myMonitor/sapLandscapeMonitor/default"),
	// 			SystemData: &armworkloads.SystemData{
	// 				CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 				CreatedBy: to.Ptr("user@xyz.com"),
	// 				CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 				LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 				LastModifiedBy: to.Ptr("user@xyz.com"),
	// 				LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 			},
	// 			Properties: &armworkloads.SapLandscapeMonitorProperties{
	// 				Grouping: &armworkloads.SapLandscapeMonitorPropertiesGrouping{
	// 					Landscape: []*armworkloads.SapLandscapeMonitorSidMapping{
	// 						{
	// 							Name: to.Ptr("Prod"),
	// 							TopSid: []*string{
	// 								to.Ptr("SID1"),
	// 								to.Ptr("SID2")},
	// 						}},
	// 						SapApplication: []*armworkloads.SapLandscapeMonitorSidMapping{
	// 							{
	// 								Name: to.Ptr("ERP1"),
	// 								TopSid: []*string{
	// 									to.Ptr("SID1"),
	// 									to.Ptr("SID2")},
	// 							}},
	// 						},
	// 						TopMetricsThresholds: []*armworkloads.SapLandscapeMonitorMetricThresholds{
	// 							{
	// 								Name: to.Ptr("Instance Availability"),
	// 								Green: to.Ptr[float32](90),
	// 								Red: to.Ptr[float32](50),
	// 								Yellow: to.Ptr[float32](75),
	// 						}},
	// 					},
	// 				},
	// 				{
	// 					Name: to.Ptr("default"),
	// 					Type: to.Ptr("Microsoft.Workloads/monitors/sapLandscapeMonitor"),
	// 					ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/monitors/myMonitor/sapLandscapeMonitor/default"),
	// 					SystemData: &armworkloads.SystemData{
	// 						CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 						CreatedBy: to.Ptr("user@xyz.com"),
	// 						CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 						LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 						LastModifiedBy: to.Ptr("user@xyz.com"),
	// 						LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 					},
	// 					Properties: &armworkloads.SapLandscapeMonitorProperties{
	// 						Grouping: &armworkloads.SapLandscapeMonitorPropertiesGrouping{
	// 							Landscape: []*armworkloads.SapLandscapeMonitorSidMapping{
	// 								{
	// 									Name: to.Ptr("Prod"),
	// 									TopSid: []*string{
	// 										to.Ptr("SID1"),
	// 										to.Ptr("SID2")},
	// 								}},
	// 								SapApplication: []*armworkloads.SapLandscapeMonitorSidMapping{
	// 									{
	// 										Name: to.Ptr("ERP1"),
	// 										TopSid: []*string{
	// 											to.Ptr("SID1"),
	// 											to.Ptr("SID2")},
	// 									}},
	// 								},
	// 								TopMetricsThresholds: []*armworkloads.SapLandscapeMonitorMetricThresholds{
	// 									{
	// 										Name: to.Ptr("Instance Availability"),
	// 										Green: to.Ptr[float32](90),
	// 										Red: to.Ptr[float32](50),
	// 										Yellow: to.Ptr[float32](75),
	// 								}},
	// 							},
	// 					}},
	// 				}
}
Output:

func (*SapLandscapeMonitorClient) Update added in v0.3.0

func (client *SapLandscapeMonitorClient) Update(ctx context.Context, resourceGroupName string, monitorName string, sapLandscapeMonitorParameter SapLandscapeMonitor, options *SapLandscapeMonitorClientUpdateOptions) (SapLandscapeMonitorClientUpdateResponse, error)

Update - Patches the SAP Landscape Monitor Dashboard for the specified subscription, resource group, and SAP monitor name. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2022-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • monitorName - Name of the SAP monitor resource.
  • sapLandscapeMonitorParameter - Request body representing a configuration for Sap Landscape Monitor Dashboard
  • options - SapLandscapeMonitorClientUpdateOptions contains the optional parameters for the SapLandscapeMonitorClient.Update method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/630ec444f8dd7c09b9cdd5fa99951f8a0d1ad41f/specification/workloads/resource-manager/Microsoft.Workloads/preview/2022-11-01-preview/examples/workloadmonitor/SapLandscapeMonitor_Update.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/workloads/armworkloads"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	client, err := armworkloads.NewSapLandscapeMonitorClient("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := client.Update(ctx, "myResourceGroup", "mySapMonitor", armworkloads.SapLandscapeMonitor{
		Properties: &armworkloads.SapLandscapeMonitorProperties{
			Grouping: &armworkloads.SapLandscapeMonitorPropertiesGrouping{
				Landscape: []*armworkloads.SapLandscapeMonitorSidMapping{
					{
						Name: to.Ptr("Prod"),
						TopSid: []*string{
							to.Ptr("SID1"),
							to.Ptr("SID2")},
					}},
				SapApplication: []*armworkloads.SapLandscapeMonitorSidMapping{
					{
						Name: to.Ptr("ERP1"),
						TopSid: []*string{
							to.Ptr("SID1"),
							to.Ptr("SID2")},
					}},
			},
			TopMetricsThresholds: []*armworkloads.SapLandscapeMonitorMetricThresholds{
				{
					Name:   to.Ptr("Instance Availability"),
					Green:  to.Ptr[float32](90),
					Red:    to.Ptr[float32](50),
					Yellow: to.Ptr[float32](75),
				}},
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.SapLandscapeMonitor = armworkloads.SapLandscapeMonitor{
	// 	Name: to.Ptr("default"),
	// 	Type: to.Ptr("Microsoft.Workloads/monitors/sapLandscapeMonitor"),
	// 	ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Workloads/monitors/myMonitor/sapLandscapeMonitor/default"),
	// 	SystemData: &armworkloads.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		CreatedBy: to.Ptr("user@xyz.com"),
	// 		CreatedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T15:10:46.196Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("user@xyz.com"),
	// 		LastModifiedByType: to.Ptr(armworkloads.CreatedByTypeUser),
	// 	},
	// 	Properties: &armworkloads.SapLandscapeMonitorProperties{
	// 		Grouping: &armworkloads.SapLandscapeMonitorPropertiesGrouping{
	// 			Landscape: []*armworkloads.SapLandscapeMonitorSidMapping{
	// 				{
	// 					Name: to.Ptr("Prod"),
	// 					TopSid: []*string{
	// 						to.Ptr("SID1"),
	// 						to.Ptr("SID2")},
	// 				}},
	// 				SapApplication: []*armworkloads.SapLandscapeMonitorSidMapping{
	// 					{
	// 						Name: to.Ptr("ERP1"),
	// 						TopSid: []*string{
	// 							to.Ptr("SID1"),
	// 							to.Ptr("SID2")},
	// 					}},
	// 				},
	// 				TopMetricsThresholds: []*armworkloads.SapLandscapeMonitorMetricThresholds{
	// 					{
	// 						Name: to.Ptr("Instance Availability"),
	// 						Green: to.Ptr[float32](90),
	// 						Red: to.Ptr[float32](50),
	// 						Yellow: to.Ptr[float32](75),
	// 				}},
	// 			},
	// 		}
}
Output:

type SapLandscapeMonitorClientCreateOptions added in v0.3.0

type SapLandscapeMonitorClientCreateOptions struct {
}

SapLandscapeMonitorClientCreateOptions contains the optional parameters for the SapLandscapeMonitorClient.Create method.

type SapLandscapeMonitorClientCreateResponse added in v0.3.0

type SapLandscapeMonitorClientCreateResponse struct {
	SapLandscapeMonitor
}

SapLandscapeMonitorClientCreateResponse contains the response from method SapLandscapeMonitorClient.Create.

type SapLandscapeMonitorClientDeleteOptions added in v0.3.0

type SapLandscapeMonitorClientDeleteOptions struct {
}

SapLandscapeMonitorClientDeleteOptions contains the optional parameters for the SapLandscapeMonitorClient.Delete method.

type SapLandscapeMonitorClientDeleteResponse added in v0.3.0

type SapLandscapeMonitorClientDeleteResponse struct {
}

SapLandscapeMonitorClientDeleteResponse contains the response from method SapLandscapeMonitorClient.Delete.

type SapLandscapeMonitorClientGetOptions added in v0.3.0

type SapLandscapeMonitorClientGetOptions struct {
}

SapLandscapeMonitorClientGetOptions contains the optional parameters for the SapLandscapeMonitorClient.Get method.

type SapLandscapeMonitorClientGetResponse added in v0.3.0

type SapLandscapeMonitorClientGetResponse struct {
	SapLandscapeMonitor
}

SapLandscapeMonitorClientGetResponse contains the response from method SapLandscapeMonitorClient.Get.

type SapLandscapeMonitorClientListOptions added in v0.3.0

type SapLandscapeMonitorClientListOptions struct {
}

SapLandscapeMonitorClientListOptions contains the optional parameters for the SapLandscapeMonitorClient.List method.

type SapLandscapeMonitorClientListResponse added in v0.3.0

type SapLandscapeMonitorClientListResponse struct {
	SapLandscapeMonitorListResult
}

SapLandscapeMonitorClientListResponse contains the response from method SapLandscapeMonitorClient.List.

type SapLandscapeMonitorClientUpdateOptions added in v0.3.0

type SapLandscapeMonitorClientUpdateOptions struct {
}

SapLandscapeMonitorClientUpdateOptions contains the optional parameters for the SapLandscapeMonitorClient.Update method.

type SapLandscapeMonitorClientUpdateResponse added in v0.3.0

type SapLandscapeMonitorClientUpdateResponse struct {
	SapLandscapeMonitor
}

SapLandscapeMonitorClientUpdateResponse contains the response from method SapLandscapeMonitorClient.Update.

type SapLandscapeMonitorListResult added in v0.3.0

type SapLandscapeMonitorListResult struct {
	// The URL to get the next set of SAP Landscape Monitor Dashboard.
	NextLink *string `json:"nextLink,omitempty"`

	// The list of Sap Landscape Monitor configuration.
	Value []*SapLandscapeMonitor `json:"value,omitempty"`
}

SapLandscapeMonitorListResult - The response from the List SAP Landscape Monitor Dashboard operation.

func (SapLandscapeMonitorListResult) MarshalJSON added in v0.3.0

func (s SapLandscapeMonitorListResult) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SapLandscapeMonitorListResult.

func (*SapLandscapeMonitorListResult) UnmarshalJSON added in v0.3.0

func (s *SapLandscapeMonitorListResult) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SapLandscapeMonitorListResult.

type SapLandscapeMonitorMetricThresholds added in v0.3.0

type SapLandscapeMonitorMetricThresholds struct {
	// Gets or sets the threshold value for Green.
	Green *float32 `json:"green,omitempty"`

	// Gets or sets the name of the threshold.
	Name *string `json:"name,omitempty"`

	// Gets or sets the threshold value for Red.
	Red *float32 `json:"red,omitempty"`

	// Gets or sets the threshold value for Yellow.
	Yellow *float32 `json:"yellow,omitempty"`
}

SapLandscapeMonitorMetricThresholds - Gets or sets the Threshold Values for Top Metrics Health.

func (SapLandscapeMonitorMetricThresholds) MarshalJSON added in v0.3.0

func (s SapLandscapeMonitorMetricThresholds) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SapLandscapeMonitorMetricThresholds.

func (*SapLandscapeMonitorMetricThresholds) UnmarshalJSON added in v0.3.0

func (s *SapLandscapeMonitorMetricThresholds) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SapLandscapeMonitorMetricThresholds.

type SapLandscapeMonitorProperties added in v0.3.0

type SapLandscapeMonitorProperties struct {
	// Gets or sets the SID groupings by landscape and Environment.
	Grouping *SapLandscapeMonitorPropertiesGrouping `json:"grouping,omitempty"`

	// Gets or sets the list Top Metric Thresholds for SAP Landscape Monitor Dashboard
	TopMetricsThresholds []*SapLandscapeMonitorMetricThresholds `json:"topMetricsThresholds,omitempty"`

	// READ-ONLY; State of provisioning of the SAP monitor.
	ProvisioningState *SapLandscapeMonitorProvisioningState `json:"provisioningState,omitempty" azure:"ro"`
}

SapLandscapeMonitorProperties - Gets or sets the properties for Sap Landscape Monitor Dashboard.

func (SapLandscapeMonitorProperties) MarshalJSON added in v0.3.0

func (s SapLandscapeMonitorProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SapLandscapeMonitorProperties.

func (*SapLandscapeMonitorProperties) UnmarshalJSON added in v0.3.0

func (s *SapLandscapeMonitorProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SapLandscapeMonitorProperties.

type SapLandscapeMonitorPropertiesGrouping added in v0.3.0

type SapLandscapeMonitorPropertiesGrouping struct {
	// Gets or sets the list of landscape to SID mappings.
	Landscape []*SapLandscapeMonitorSidMapping `json:"landscape,omitempty"`

	// Gets or sets the list of Sap Applications to SID mappings.
	SapApplication []*SapLandscapeMonitorSidMapping `json:"sapApplication,omitempty"`
}

SapLandscapeMonitorPropertiesGrouping - Gets or sets the SID groupings by landscape and Environment.

func (SapLandscapeMonitorPropertiesGrouping) MarshalJSON added in v0.3.0

func (s SapLandscapeMonitorPropertiesGrouping) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SapLandscapeMonitorPropertiesGrouping.

func (*SapLandscapeMonitorPropertiesGrouping) UnmarshalJSON added in v0.3.0

func (s *SapLandscapeMonitorPropertiesGrouping) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SapLandscapeMonitorPropertiesGrouping.

type SapLandscapeMonitorProvisioningState added in v0.3.0

type SapLandscapeMonitorProvisioningState string

SapLandscapeMonitorProvisioningState - State of provisioning of the SAP monitor.

const (
	SapLandscapeMonitorProvisioningStateAccepted  SapLandscapeMonitorProvisioningState = "Accepted"
	SapLandscapeMonitorProvisioningStateCanceled  SapLandscapeMonitorProvisioningState = "Canceled"
	SapLandscapeMonitorProvisioningStateCreated   SapLandscapeMonitorProvisioningState = "Created"
	SapLandscapeMonitorProvisioningStateFailed    SapLandscapeMonitorProvisioningState = "Failed"
	SapLandscapeMonitorProvisioningStateSucceeded SapLandscapeMonitorProvisioningState = "Succeeded"
)

func PossibleSapLandscapeMonitorProvisioningStateValues added in v0.3.0

func PossibleSapLandscapeMonitorProvisioningStateValues() []SapLandscapeMonitorProvisioningState

PossibleSapLandscapeMonitorProvisioningStateValues returns the possible values for the SapLandscapeMonitorProvisioningState const type.

type SapLandscapeMonitorSidMapping added in v0.3.0

type SapLandscapeMonitorSidMapping struct {
	// Gets or sets the name of the grouping.
	Name *string `json:"name,omitempty"`

	// Gets or sets the list of SID's.
	TopSid []*string `json:"topSid,omitempty"`
}

SapLandscapeMonitorSidMapping - Gets or sets the mapping for SID to Environment/Applications.

func (SapLandscapeMonitorSidMapping) MarshalJSON added in v0.3.0

func (s SapLandscapeMonitorSidMapping) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SapLandscapeMonitorSidMapping.

func (*SapLandscapeMonitorSidMapping) UnmarshalJSON added in v0.3.0

func (s *SapLandscapeMonitorSidMapping) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SapLandscapeMonitorSidMapping.

type SapNetWeaverProviderInstanceProperties

type SapNetWeaverProviderInstanceProperties struct {
	// REQUIRED; The provider type. For example, the value can be SapHana.
	ProviderType *string `json:"providerType,omitempty"`

	// Gets or sets the blob URI to SSL certificate for the SAP system.
	SSLCertificateURI *string `json:"sslCertificateUri,omitempty"`

	// Gets or sets certificate preference if secure communication is enabled.
	SSLPreference *SSLPreference `json:"sslPreference,omitempty"`

	// Gets or sets the SAP Client ID.
	SapClientID *string `json:"sapClientId,omitempty"`

	// Gets or sets the list of HostFile Entries
	SapHostFileEntries []*string `json:"sapHostFileEntries,omitempty"`

	// Gets or sets the target virtual machine IP Address/FQDN.
	SapHostname *string `json:"sapHostname,omitempty"`

	// Gets or sets the instance number of SAP NetWeaver.
	SapInstanceNr *string `json:"sapInstanceNr,omitempty"`

	// Sets the SAP password.
	SapPassword *string `json:"sapPassword,omitempty"`

	// Gets or sets the key vault URI to secret with the SAP password.
	SapPasswordURI *string `json:"sapPasswordUri,omitempty"`

	// Gets or sets the SAP HTTP port number.
	SapPortNumber *string `json:"sapPortNumber,omitempty"`

	// Gets or sets the SAP System Identifier
	SapSid *string `json:"sapSid,omitempty"`

	// Gets or sets the SAP user name.
	SapUsername *string `json:"sapUsername,omitempty"`
}

SapNetWeaverProviderInstanceProperties - Gets or sets the provider properties.

func (*SapNetWeaverProviderInstanceProperties) GetProviderSpecificProperties

func (s *SapNetWeaverProviderInstanceProperties) GetProviderSpecificProperties() *ProviderSpecificProperties

GetProviderSpecificProperties implements the ProviderSpecificPropertiesClassification interface for type SapNetWeaverProviderInstanceProperties.

func (SapNetWeaverProviderInstanceProperties) MarshalJSON

func (s SapNetWeaverProviderInstanceProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SapNetWeaverProviderInstanceProperties.

func (*SapNetWeaverProviderInstanceProperties) UnmarshalJSON

func (s *SapNetWeaverProviderInstanceProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SapNetWeaverProviderInstanceProperties.

type SapVirtualInstanceProvisioningState added in v0.2.0

type SapVirtualInstanceProvisioningState string

SapVirtualInstanceProvisioningState - Defines the provisioning states.

const (
	SapVirtualInstanceProvisioningStateCreating  SapVirtualInstanceProvisioningState = "Creating"
	SapVirtualInstanceProvisioningStateDeleting  SapVirtualInstanceProvisioningState = "Deleting"
	SapVirtualInstanceProvisioningStateFailed    SapVirtualInstanceProvisioningState = "Failed"
	SapVirtualInstanceProvisioningStateSucceeded SapVirtualInstanceProvisioningState = "Succeeded"
	SapVirtualInstanceProvisioningStateUpdating  SapVirtualInstanceProvisioningState = "Updating"
)

func PossibleSapVirtualInstanceProvisioningStateValues added in v0.2.0

func PossibleSapVirtualInstanceProvisioningStateValues() []SapVirtualInstanceProvisioningState

PossibleSapVirtualInstanceProvisioningStateValues returns the possible values for the SapVirtualInstanceProvisioningState const type.

type ServiceInitiatedSoftwareConfiguration added in v0.2.0

type ServiceInitiatedSoftwareConfiguration struct {
	// REQUIRED; The URL to the SAP Build of Materials(BOM) file.
	BomURL *string `json:"bomUrl,omitempty"`

	// REQUIRED; The SSH private key.
	SSHPrivateKey *string `json:"sshPrivateKey,omitempty"`

	// REQUIRED; The SAP bits storage account id.
	SapBitsStorageAccountID *string `json:"sapBitsStorageAccountId,omitempty"`

	// REQUIRED; The FQDN to set for the SAP system during install.
	SapFqdn *string `json:"sapFqdn,omitempty"`

	// REQUIRED; The SAP software installation Type.
	SoftwareInstallationType *SAPSoftwareInstallationType `json:"softwareInstallationType,omitempty"`

	// REQUIRED; The software version to install.
	SoftwareVersion *string `json:"softwareVersion,omitempty"`

	// Gets or sets the HA software configuration.
	HighAvailabilitySoftwareConfiguration *HighAvailabilitySoftwareConfiguration `json:"highAvailabilitySoftwareConfiguration,omitempty"`
}

ServiceInitiatedSoftwareConfiguration - The SAP Software configuration Input when the software is to be installed by service.

func (*ServiceInitiatedSoftwareConfiguration) GetSoftwareConfiguration added in v0.2.0

func (s *ServiceInitiatedSoftwareConfiguration) GetSoftwareConfiguration() *SoftwareConfiguration

GetSoftwareConfiguration implements the SoftwareConfigurationClassification interface for type ServiceInitiatedSoftwareConfiguration.

func (ServiceInitiatedSoftwareConfiguration) MarshalJSON added in v0.2.0

func (s ServiceInitiatedSoftwareConfiguration) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ServiceInitiatedSoftwareConfiguration.

func (*ServiceInitiatedSoftwareConfiguration) UnmarshalJSON added in v0.2.0

func (s *ServiceInitiatedSoftwareConfiguration) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ServiceInitiatedSoftwareConfiguration.

type SharedStorageResourceNames added in v0.3.0

type SharedStorageResourceNames struct {
	// The full name of the shared storage account. If it is not provided, it will be defaulted to {SID}nfs{guid of 15 chars}.
	SharedStorageAccountName *string `json:"sharedStorageAccountName,omitempty"`

	// The full name of private end point for the shared storage account. If it is not provided, it will be defaulted to {storageAccountName}_pe
	SharedStorageAccountPrivateEndPointName *string `json:"sharedStorageAccountPrivateEndPointName,omitempty"`
}

SharedStorageResourceNames - The resource names object for shared storage.

func (SharedStorageResourceNames) MarshalJSON added in v0.3.0

func (s SharedStorageResourceNames) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SharedStorageResourceNames.

func (*SharedStorageResourceNames) UnmarshalJSON added in v0.3.0

func (s *SharedStorageResourceNames) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SharedStorageResourceNames.

type SingleServerConfiguration added in v0.2.0

type SingleServerConfiguration struct {
	// REQUIRED; The application resource group where SAP system resources will be deployed.
	AppResourceGroup *string `json:"appResourceGroup,omitempty"`

	// REQUIRED; The type of SAP deployment, single server or Three tier.
	DeploymentType *SAPDeploymentType `json:"deploymentType,omitempty"`

	// REQUIRED; The subnet id.
	SubnetID *string `json:"subnetId,omitempty"`

	// REQUIRED; Gets or sets the virtual machine configuration.
	VirtualMachineConfiguration *VirtualMachineConfiguration `json:"virtualMachineConfiguration,omitempty"`

	// The set of custom names to be used for underlying azure resources that are part of the SAP system.
	CustomResourceNames SingleServerCustomResourceNamesClassification `json:"customResourceNames,omitempty"`

	// The database type.
	DatabaseType *SAPDatabaseType `json:"databaseType,omitempty"`

	// Gets or sets the disk configuration.
	DbDiskConfiguration *DiskConfiguration `json:"dbDiskConfiguration,omitempty"`

	// Network configuration for the server
	NetworkConfiguration *NetworkConfiguration `json:"networkConfiguration,omitempty"`
}

SingleServerConfiguration - Gets or sets the single server configuration.

func (*SingleServerConfiguration) GetInfrastructureConfiguration added in v0.2.0

func (s *SingleServerConfiguration) GetInfrastructureConfiguration() *InfrastructureConfiguration

GetInfrastructureConfiguration implements the InfrastructureConfigurationClassification interface for type SingleServerConfiguration.

func (SingleServerConfiguration) MarshalJSON added in v0.2.0

func (s SingleServerConfiguration) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SingleServerConfiguration.

func (*SingleServerConfiguration) UnmarshalJSON added in v0.2.0

func (s *SingleServerConfiguration) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SingleServerConfiguration.

type SingleServerCustomResourceNames added in v0.3.0

type SingleServerCustomResourceNames struct {
	// REQUIRED; The pattern type to be used for resource naming.
	NamingPatternType *NamingPatternType `json:"namingPatternType,omitempty"`
}

SingleServerCustomResourceNames - The resource-names input to specify custom names for underlying azure resources that are part of a single server SAP system.

func (*SingleServerCustomResourceNames) GetSingleServerCustomResourceNames added in v0.3.0

func (s *SingleServerCustomResourceNames) GetSingleServerCustomResourceNames() *SingleServerCustomResourceNames

GetSingleServerCustomResourceNames implements the SingleServerCustomResourceNamesClassification interface for type SingleServerCustomResourceNames.

func (SingleServerCustomResourceNames) MarshalJSON added in v0.3.0

func (s SingleServerCustomResourceNames) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SingleServerCustomResourceNames.

func (*SingleServerCustomResourceNames) UnmarshalJSON added in v0.3.0

func (s *SingleServerCustomResourceNames) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SingleServerCustomResourceNames.

type SingleServerCustomResourceNamesClassification added in v0.3.0

type SingleServerCustomResourceNamesClassification interface {
	// GetSingleServerCustomResourceNames returns the SingleServerCustomResourceNames content of the underlying type.
	GetSingleServerCustomResourceNames() *SingleServerCustomResourceNames
}

SingleServerCustomResourceNamesClassification provides polymorphic access to related types. Call the interface's GetSingleServerCustomResourceNames() method to access the common type. Use a type switch to determine the concrete type. The possible types are: - *SingleServerCustomResourceNames, *SingleServerFullResourceNames

type SingleServerFullResourceNames added in v0.3.0

type SingleServerFullResourceNames struct {
	// REQUIRED; The pattern type to be used for resource naming.
	NamingPatternType *NamingPatternType `json:"namingPatternType,omitempty"`

	// The resource names object for virtual machine and related resources.
	VirtualMachine *VirtualMachineResourceNames `json:"virtualMachine,omitempty"`
}

SingleServerFullResourceNames - The resource name object where the specified values will be full resource names of the corresponding resources in a single server SAP system.

func (*SingleServerFullResourceNames) GetSingleServerCustomResourceNames added in v0.3.0

func (s *SingleServerFullResourceNames) GetSingleServerCustomResourceNames() *SingleServerCustomResourceNames

GetSingleServerCustomResourceNames implements the SingleServerCustomResourceNamesClassification interface for type SingleServerFullResourceNames.

func (SingleServerFullResourceNames) MarshalJSON added in v0.3.0

func (s SingleServerFullResourceNames) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SingleServerFullResourceNames.

func (*SingleServerFullResourceNames) UnmarshalJSON added in v0.3.0

func (s *SingleServerFullResourceNames) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SingleServerFullResourceNames.

type SingleServerRecommendationResult added in v0.2.0

type SingleServerRecommendationResult struct {
	// REQUIRED; The type of SAP deployment, single server or Three tier.
	DeploymentType *SAPDeploymentType `json:"deploymentType,omitempty"`

	// The recommended VM SKU for single server.
	VMSKU *string `json:"vmSku,omitempty"`
}

SingleServerRecommendationResult - The recommended configuration for a single server SAP system.

func (*SingleServerRecommendationResult) GetSAPSizingRecommendationResult added in v0.2.0

func (s *SingleServerRecommendationResult) GetSAPSizingRecommendationResult() *SAPSizingRecommendationResult

GetSAPSizingRecommendationResult implements the SAPSizingRecommendationResultClassification interface for type SingleServerRecommendationResult.

func (SingleServerRecommendationResult) MarshalJSON added in v0.2.0

func (s SingleServerRecommendationResult) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SingleServerRecommendationResult.

func (*SingleServerRecommendationResult) UnmarshalJSON added in v0.2.0

func (s *SingleServerRecommendationResult) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SingleServerRecommendationResult.

type SkipFileShareConfiguration added in v0.3.0

type SkipFileShareConfiguration struct {
	// REQUIRED; The type of file share config.
	ConfigurationType *ConfigurationType `json:"configurationType,omitempty"`
}

SkipFileShareConfiguration - Gets or sets the skip file share configuration

func (*SkipFileShareConfiguration) GetFileShareConfiguration added in v0.3.0

func (s *SkipFileShareConfiguration) GetFileShareConfiguration() *FileShareConfiguration

GetFileShareConfiguration implements the FileShareConfigurationClassification interface for type SkipFileShareConfiguration.

func (SkipFileShareConfiguration) MarshalJSON added in v0.3.0

func (s SkipFileShareConfiguration) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SkipFileShareConfiguration.

func (*SkipFileShareConfiguration) UnmarshalJSON added in v0.3.0

func (s *SkipFileShareConfiguration) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SkipFileShareConfiguration.

type SoftwareConfiguration added in v0.2.0

type SoftwareConfiguration struct {
	// REQUIRED; The SAP software installation Type.
	SoftwareInstallationType *SAPSoftwareInstallationType `json:"softwareInstallationType,omitempty"`
}

SoftwareConfiguration - The SAP Software configuration Input.

func (*SoftwareConfiguration) GetSoftwareConfiguration added in v0.2.0

func (s *SoftwareConfiguration) GetSoftwareConfiguration() *SoftwareConfiguration

GetSoftwareConfiguration implements the SoftwareConfigurationClassification interface for type SoftwareConfiguration.

func (SoftwareConfiguration) MarshalJSON added in v0.2.0

func (s SoftwareConfiguration) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SoftwareConfiguration.

func (*SoftwareConfiguration) UnmarshalJSON added in v0.2.0

func (s *SoftwareConfiguration) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SoftwareConfiguration.

type SoftwareConfigurationClassification added in v0.2.0

type SoftwareConfigurationClassification interface {
	// GetSoftwareConfiguration returns the SoftwareConfiguration content of the underlying type.
	GetSoftwareConfiguration() *SoftwareConfiguration
}

SoftwareConfigurationClassification provides polymorphic access to related types. Call the interface's GetSoftwareConfiguration() method to access the common type. Use a type switch to determine the concrete type. The possible types are: - *ExternalInstallationSoftwareConfiguration, *SAPInstallWithoutOSConfigSoftwareConfiguration, *ServiceInitiatedSoftwareConfiguration, - *SoftwareConfiguration

type StopRequest added in v0.2.0

type StopRequest struct {
	// This parameter defines how long (in seconds) the soft shutdown waits until the RFC/HTTP clients no longer consider the
	// server for calls with load balancing. Value 0 means that the kernel does not
	// wait, but goes directly into the next shutdown state, i.e. hard stop.
	SoftStopTimeoutSeconds *int64 `json:"softStopTimeoutSeconds,omitempty"`
}

StopRequest - Stop SAP instance(s) request body.

func (StopRequest) MarshalJSON added in v0.2.0

func (s StopRequest) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type StopRequest.

func (*StopRequest) UnmarshalJSON added in v0.2.0

func (s *StopRequest) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type StopRequest.

type StorageConfiguration added in v0.3.0

type StorageConfiguration struct {
	// The properties of the transport directory attached to the VIS. The default for transportFileShareConfiguration is the createAndMount
	// flow if storage configuration is missing.
	TransportFileShareConfiguration FileShareConfigurationClassification `json:"transportFileShareConfiguration,omitempty"`
}

StorageConfiguration - Gets or sets the storage configuration.

func (StorageConfiguration) MarshalJSON added in v0.3.0

func (s StorageConfiguration) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type StorageConfiguration.

func (*StorageConfiguration) UnmarshalJSON added in v0.3.0

func (s *StorageConfiguration) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type StorageConfiguration.

type StorageInformation added in v0.3.0

type StorageInformation struct {
	// READ-ONLY
	ID *string `json:"id,omitempty" azure:"ro"`
}

StorageInformation - Storage details of all the Storage accounts attached to the VM. For e.g. NFS on AFS Shared Storage.

func (StorageInformation) MarshalJSON added in v0.3.0

func (s StorageInformation) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type StorageInformation.

func (*StorageInformation) UnmarshalJSON added in v0.3.0

func (s *StorageInformation) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type StorageInformation.

type SystemData

type SystemData struct {
	// The timestamp of resource creation (UTC).
	CreatedAt *time.Time `json:"createdAt,omitempty"`

	// The identity that created the resource.
	CreatedBy *string `json:"createdBy,omitempty"`

	// The type of identity that created the resource.
	CreatedByType *CreatedByType `json:"createdByType,omitempty"`

	// The timestamp of resource last modification (UTC)
	LastModifiedAt *time.Time `json:"lastModifiedAt,omitempty"`

	// The identity that last modified the resource.
	LastModifiedBy *string `json:"lastModifiedBy,omitempty"`

	// The type of identity that last modified the resource.
	LastModifiedByType *CreatedByType `json:"lastModifiedByType,omitempty"`
}

SystemData - Metadata pertaining to creation and last modification of the resource.

func (SystemData) MarshalJSON

func (s SystemData) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SystemData.

func (*SystemData) UnmarshalJSON

func (s *SystemData) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SystemData.

type Tags

type Tags struct {
	// Tags field of the resource.
	Tags map[string]*string `json:"tags,omitempty"`
}

Tags field of the resource.

func (Tags) MarshalJSON

func (t Tags) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type Tags.

func (*Tags) UnmarshalJSON added in v0.2.0

func (t *Tags) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type Tags.

type ThreeTierConfiguration added in v0.2.0

type ThreeTierConfiguration struct {
	// REQUIRED; The application resource group where SAP system resources will be deployed.
	AppResourceGroup *string `json:"appResourceGroup,omitempty"`

	// REQUIRED; The application server configuration.
	ApplicationServer *ApplicationServerConfiguration `json:"applicationServer,omitempty"`

	// REQUIRED; The central server configuration.
	CentralServer *CentralServerConfiguration `json:"centralServer,omitempty"`

	// REQUIRED; The database configuration.
	DatabaseServer *DatabaseConfiguration `json:"databaseServer,omitempty"`

	// REQUIRED; The type of SAP deployment, single server or Three tier.
	DeploymentType *SAPDeploymentType `json:"deploymentType,omitempty"`

	// The set of custom names to be used for underlying azure resources that are part of the SAP system.
	CustomResourceNames ThreeTierCustomResourceNamesClassification `json:"customResourceNames,omitempty"`

	// The high availability configuration.
	HighAvailabilityConfig *HighAvailabilityConfiguration `json:"highAvailabilityConfig,omitempty"`

	// Network configuration common to all servers
	NetworkConfiguration *NetworkConfiguration `json:"networkConfiguration,omitempty"`

	// The storage configuration.
	StorageConfiguration *StorageConfiguration `json:"storageConfiguration,omitempty"`
}

ThreeTierConfiguration - Gets or sets the three tier SAP configuration.

func (*ThreeTierConfiguration) GetInfrastructureConfiguration added in v0.2.0

func (t *ThreeTierConfiguration) GetInfrastructureConfiguration() *InfrastructureConfiguration

GetInfrastructureConfiguration implements the InfrastructureConfigurationClassification interface for type ThreeTierConfiguration.

func (ThreeTierConfiguration) MarshalJSON added in v0.2.0

func (t ThreeTierConfiguration) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ThreeTierConfiguration.

func (*ThreeTierConfiguration) UnmarshalJSON added in v0.2.0

func (t *ThreeTierConfiguration) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ThreeTierConfiguration.

type ThreeTierCustomResourceNames added in v0.3.0

type ThreeTierCustomResourceNames struct {
	// REQUIRED; The pattern type to be used for resource naming.
	NamingPatternType *NamingPatternType `json:"namingPatternType,omitempty"`
}

ThreeTierCustomResourceNames - The resource-names input to specify custom names for underlying azure resources that are part of a three tier SAP system.

func (*ThreeTierCustomResourceNames) GetThreeTierCustomResourceNames added in v0.3.0

func (t *ThreeTierCustomResourceNames) GetThreeTierCustomResourceNames() *ThreeTierCustomResourceNames

GetThreeTierCustomResourceNames implements the ThreeTierCustomResourceNamesClassification interface for type ThreeTierCustomResourceNames.

func (ThreeTierCustomResourceNames) MarshalJSON added in v0.3.0

func (t ThreeTierCustomResourceNames) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ThreeTierCustomResourceNames.

func (*ThreeTierCustomResourceNames) UnmarshalJSON added in v0.3.0

func (t *ThreeTierCustomResourceNames) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ThreeTierCustomResourceNames.

type ThreeTierCustomResourceNamesClassification added in v0.3.0

type ThreeTierCustomResourceNamesClassification interface {
	// GetThreeTierCustomResourceNames returns the ThreeTierCustomResourceNames content of the underlying type.
	GetThreeTierCustomResourceNames() *ThreeTierCustomResourceNames
}

ThreeTierCustomResourceNamesClassification provides polymorphic access to related types. Call the interface's GetThreeTierCustomResourceNames() method to access the common type. Use a type switch to determine the concrete type. The possible types are: - *ThreeTierCustomResourceNames, *ThreeTierFullResourceNames

type ThreeTierFullResourceNames added in v0.3.0

type ThreeTierFullResourceNames struct {
	// REQUIRED; The pattern type to be used for resource naming.
	NamingPatternType *NamingPatternType `json:"namingPatternType,omitempty"`

	// The full resource names object for application layer resources. The number of entries in this list should be equal to the
	// number VMs to be created for application layer.
	ApplicationServer *ApplicationServerFullResourceNames `json:"applicationServer,omitempty"`

	// The full resource names object for central server layer resources.
	CentralServer *CentralServerFullResourceNames `json:"centralServer,omitempty"`

	// The full resource names object for database layer resources. The number of entries in this list should be equal to the
	// number VMs to be created for database layer.
	DatabaseServer *DatabaseServerFullResourceNames `json:"databaseServer,omitempty"`

	// The resource names object for shared storage.
	SharedStorage *SharedStorageResourceNames `json:"sharedStorage,omitempty"`
}

ThreeTierFullResourceNames - The resource name object where the specified values will be full resource names of the corresponding resources in a three tier SAP system.

func (*ThreeTierFullResourceNames) GetThreeTierCustomResourceNames added in v0.3.0

func (t *ThreeTierFullResourceNames) GetThreeTierCustomResourceNames() *ThreeTierCustomResourceNames

GetThreeTierCustomResourceNames implements the ThreeTierCustomResourceNamesClassification interface for type ThreeTierFullResourceNames.

func (ThreeTierFullResourceNames) MarshalJSON added in v0.3.0

func (t ThreeTierFullResourceNames) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ThreeTierFullResourceNames.

func (*ThreeTierFullResourceNames) UnmarshalJSON added in v0.3.0

func (t *ThreeTierFullResourceNames) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ThreeTierFullResourceNames.

type ThreeTierRecommendationResult added in v0.2.0

type ThreeTierRecommendationResult struct {
	// REQUIRED; The type of SAP deployment, single server or Three tier.
	DeploymentType *SAPDeploymentType `json:"deploymentType,omitempty"`

	// The application server instance count.
	ApplicationServerInstanceCount *int64 `json:"applicationServerInstanceCount,omitempty"`

	// The application server VM SKU.
	ApplicationServerVMSKU *string `json:"applicationServerVmSku,omitempty"`

	// The central server instance count.
	CentralServerInstanceCount *int64 `json:"centralServerInstanceCount,omitempty"`

	// The central server VM SKU.
	CentralServerVMSKU *string `json:"centralServerVmSku,omitempty"`

	// The database server instance count.
	DatabaseInstanceCount *int64 `json:"databaseInstanceCount,omitempty"`

	// The database VM SKU.
	DbVMSKU *string `json:"dbVmSku,omitempty"`
}

ThreeTierRecommendationResult - The recommended configuration for a three tier SAP system.

func (*ThreeTierRecommendationResult) GetSAPSizingRecommendationResult added in v0.2.0

func (t *ThreeTierRecommendationResult) GetSAPSizingRecommendationResult() *SAPSizingRecommendationResult

GetSAPSizingRecommendationResult implements the SAPSizingRecommendationResultClassification interface for type ThreeTierRecommendationResult.

func (ThreeTierRecommendationResult) MarshalJSON added in v0.2.0

func (t ThreeTierRecommendationResult) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ThreeTierRecommendationResult.

func (*ThreeTierRecommendationResult) UnmarshalJSON added in v0.2.0

func (t *ThreeTierRecommendationResult) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ThreeTierRecommendationResult.

type TrackedResource

type TrackedResource struct {
	// REQUIRED; The geo-location where the resource lives
	Location *string `json:"location,omitempty"`

	// Resource tags.
	Tags map[string]*string `json:"tags,omitempty"`

	// READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
	ID *string `json:"id,omitempty" azure:"ro"`

	// READ-ONLY; The name of the resource
	Name *string `json:"name,omitempty" azure:"ro"`

	// READ-ONLY; Azure Resource Manager metadata containing createdBy and modifiedBy information.
	SystemData *SystemData `json:"systemData,omitempty" azure:"ro"`

	// READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
	Type *string `json:"type,omitempty" azure:"ro"`
}

TrackedResource - The resource model definition for an Azure Resource Manager tracked top level resource which has 'tags' and a 'location'

func (TrackedResource) MarshalJSON

func (t TrackedResource) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type TrackedResource.

func (*TrackedResource) UnmarshalJSON added in v0.2.0

func (t *TrackedResource) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type TrackedResource.

type UpdateMonitorRequest added in v0.2.0

type UpdateMonitorRequest struct {
	// Managed service identity (user assigned identities)
	Identity *UserAssignedServiceIdentity `json:"identity,omitempty"`

	// Gets or sets the Resource tags.
	Tags map[string]*string `json:"tags,omitempty"`
}

UpdateMonitorRequest - Defines the request body for updating SAP monitor resource.

func (UpdateMonitorRequest) MarshalJSON added in v0.2.0

func (u UpdateMonitorRequest) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type UpdateMonitorRequest.

func (*UpdateMonitorRequest) UnmarshalJSON added in v0.2.0

func (u *UpdateMonitorRequest) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type UpdateMonitorRequest.

type UpdateSAPApplicationInstanceRequest added in v0.2.0

type UpdateSAPApplicationInstanceRequest struct {
	// Gets or sets the Resource tags.
	Tags map[string]*string `json:"tags,omitempty"`
}

UpdateSAPApplicationInstanceRequest - Defines the request body for updating SAP Application Instance.

func (UpdateSAPApplicationInstanceRequest) MarshalJSON added in v0.2.0

func (u UpdateSAPApplicationInstanceRequest) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type UpdateSAPApplicationInstanceRequest.

func (*UpdateSAPApplicationInstanceRequest) UnmarshalJSON added in v0.2.0

func (u *UpdateSAPApplicationInstanceRequest) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type UpdateSAPApplicationInstanceRequest.

type UpdateSAPCentralInstanceRequest added in v0.2.0

type UpdateSAPCentralInstanceRequest struct {
	// Gets or sets the Resource tags.
	Tags map[string]*string `json:"tags,omitempty"`
}

UpdateSAPCentralInstanceRequest - Defines the request body for updating SAP Central Instance.

func (UpdateSAPCentralInstanceRequest) MarshalJSON added in v0.2.0

func (u UpdateSAPCentralInstanceRequest) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type UpdateSAPCentralInstanceRequest.

func (*UpdateSAPCentralInstanceRequest) UnmarshalJSON added in v0.2.0

func (u *UpdateSAPCentralInstanceRequest) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type UpdateSAPCentralInstanceRequest.

type UpdateSAPDatabaseInstanceRequest added in v0.2.0

type UpdateSAPDatabaseInstanceRequest struct {
	// Gets or sets the Resource tags.
	Tags map[string]*string `json:"tags,omitempty"`
}

UpdateSAPDatabaseInstanceRequest - Defines the request body for updating SAP Database Instance.

func (UpdateSAPDatabaseInstanceRequest) MarshalJSON added in v0.2.0

func (u UpdateSAPDatabaseInstanceRequest) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type UpdateSAPDatabaseInstanceRequest.

func (*UpdateSAPDatabaseInstanceRequest) UnmarshalJSON added in v0.2.0

func (u *UpdateSAPDatabaseInstanceRequest) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type UpdateSAPDatabaseInstanceRequest.

type UpdateSAPVirtualInstanceRequest added in v0.2.0

type UpdateSAPVirtualInstanceRequest struct {
	// Managed service identity (user assigned identities)
	Identity *UserAssignedServiceIdentity `json:"identity,omitempty"`

	// Gets or sets the Resource tags.
	Tags map[string]*string `json:"tags,omitempty"`
}

UpdateSAPVirtualInstanceRequest - Defines the request body for updating Virtual Instance for SAP.

func (UpdateSAPVirtualInstanceRequest) MarshalJSON added in v0.2.0

func (u UpdateSAPVirtualInstanceRequest) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type UpdateSAPVirtualInstanceRequest.

func (*UpdateSAPVirtualInstanceRequest) UnmarshalJSON added in v0.2.0

func (u *UpdateSAPVirtualInstanceRequest) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type UpdateSAPVirtualInstanceRequest.

type UserAssignedIdentity added in v0.2.0

type UserAssignedIdentity struct {
	// READ-ONLY; The client ID of the assigned identity.
	ClientID *string `json:"clientId,omitempty" azure:"ro"`

	// READ-ONLY; The principal ID of the assigned identity.
	PrincipalID *string `json:"principalId,omitempty" azure:"ro"`
}

UserAssignedIdentity - User assigned identity properties

func (UserAssignedIdentity) MarshalJSON added in v0.2.0

func (u UserAssignedIdentity) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type UserAssignedIdentity.

func (*UserAssignedIdentity) UnmarshalJSON added in v0.2.0

func (u *UserAssignedIdentity) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type UserAssignedIdentity.

type UserAssignedServiceIdentity added in v0.2.0

type UserAssignedServiceIdentity struct {
	// REQUIRED; Type of manage identity
	Type *ManagedServiceIdentityType `json:"type,omitempty"`

	// User assigned identities dictionary
	UserAssignedIdentities map[string]*UserAssignedIdentity `json:"userAssignedIdentities,omitempty"`
}

UserAssignedServiceIdentity - Managed service identity (user assigned identities)

func (UserAssignedServiceIdentity) MarshalJSON added in v0.2.0

func (u UserAssignedServiceIdentity) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type UserAssignedServiceIdentity.

func (*UserAssignedServiceIdentity) UnmarshalJSON added in v0.2.0

func (u *UserAssignedServiceIdentity) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type UserAssignedServiceIdentity.

type VirtualMachineConfiguration added in v0.2.0

type VirtualMachineConfiguration struct {
	// REQUIRED; The image reference.
	ImageReference *ImageReference `json:"imageReference,omitempty"`

	// REQUIRED; The OS profile.
	OSProfile *OSProfile `json:"osProfile,omitempty"`

	// REQUIRED; The virtual machine size.
	VMSize *string `json:"vmSize,omitempty"`
}

VirtualMachineConfiguration - Defines the virtual machine configuration.

func (VirtualMachineConfiguration) MarshalJSON added in v0.2.0

func (v VirtualMachineConfiguration) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type VirtualMachineConfiguration.

func (*VirtualMachineConfiguration) UnmarshalJSON added in v0.2.0

func (v *VirtualMachineConfiguration) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type VirtualMachineConfiguration.

type VirtualMachineResourceNames added in v0.3.0

type VirtualMachineResourceNames struct {
	// The full resource names for virtual machine data disks. This is a dictionary containing list of names of data disks per
	// volume. Currently supported volumes for database layer are ['hana/data',
	// 'hana/log', hana/shared', 'usr/sap', 'os', 'backup']. For application and cs layers, only 'default' volume is supported
	DataDiskNames map[string][]*string `json:"dataDiskNames,omitempty"`

	// The full name for virtual-machine's host (computer name). Currently, ACSS only supports host names which are less than
	// or equal to 13 characters long. If this value is not provided, vmName will be
	// used as host name.
	HostName *string `json:"hostName,omitempty"`

	// The list of network interface name objects for the selected virtual machine. Currently, only one network interface is supported
	// per virtual machine.
	NetworkInterfaces []*NetworkInterfaceResourceNames `json:"networkInterfaces,omitempty"`

	// The full name for OS disk attached to the VM. If this value is not provided, it will be named by ARM as per its default
	// naming standards (prefixed with vm name). There is only one OS disk attached per
	// Virtual Machine.
	OSDiskName *string `json:"osDiskName,omitempty"`

	// The full name for virtual machine. The length of this field can be upto 64 characters. If name is not provided, service
	// uses a default name based on the deployment type. For SingleServer, default name
	// is {SID}vm. In case of HA-AvZone systems, default name will be {SID}{app/ascs/db}z{a/b}vm with an incrementor at the end
	// in case of more than 1 vm per layer. For distributed and HA-AvSet systems,
	// default name will be {SID}{app/ascs/db}vm with an incrementor at the end in case of more than 1 vm per layer.
	VMName *string `json:"vmName,omitempty"`
}

VirtualMachineResourceNames - The resource names object for virtual machine and related resources.

func (VirtualMachineResourceNames) MarshalJSON added in v0.3.0

func (v VirtualMachineResourceNames) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type VirtualMachineResourceNames.

func (*VirtualMachineResourceNames) UnmarshalJSON added in v0.3.0

func (v *VirtualMachineResourceNames) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type VirtualMachineResourceNames.

type WindowsConfiguration added in v0.2.0

type WindowsConfiguration struct {
	// REQUIRED; The OS Type
	OSType *OSType `json:"osType,omitempty"`
}

WindowsConfiguration - Specifies Windows operating system settings on the virtual machine.

func (*WindowsConfiguration) GetOSConfiguration added in v0.2.0

func (w *WindowsConfiguration) GetOSConfiguration() *OSConfiguration

GetOSConfiguration implements the OSConfigurationClassification interface for type WindowsConfiguration.

func (WindowsConfiguration) MarshalJSON added in v0.2.0

func (w WindowsConfiguration) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type WindowsConfiguration.

func (*WindowsConfiguration) UnmarshalJSON added in v0.2.0

func (w *WindowsConfiguration) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type WindowsConfiguration.

type WorkloadMonitorActionType

type WorkloadMonitorActionType string

WorkloadMonitorActionType - Defines the action type of workload operation.

const (
	WorkloadMonitorActionTypeInternal     WorkloadMonitorActionType = "Internal"
	WorkloadMonitorActionTypeNotSpecified WorkloadMonitorActionType = "NotSpecified"
)

func PossibleWorkloadMonitorActionTypeValues

func PossibleWorkloadMonitorActionTypeValues() []WorkloadMonitorActionType

PossibleWorkloadMonitorActionTypeValues returns the possible values for the WorkloadMonitorActionType const type.

type WorkloadMonitorProvisioningState

type WorkloadMonitorProvisioningState string

WorkloadMonitorProvisioningState - State of provisioning of the SAP monitor.

const (
	WorkloadMonitorProvisioningStateAccepted  WorkloadMonitorProvisioningState = "Accepted"
	WorkloadMonitorProvisioningStateCreating  WorkloadMonitorProvisioningState = "Creating"
	WorkloadMonitorProvisioningStateDeleting  WorkloadMonitorProvisioningState = "Deleting"
	WorkloadMonitorProvisioningStateFailed    WorkloadMonitorProvisioningState = "Failed"
	WorkloadMonitorProvisioningStateMigrating WorkloadMonitorProvisioningState = "Migrating"
	WorkloadMonitorProvisioningStateSucceeded WorkloadMonitorProvisioningState = "Succeeded"
	WorkloadMonitorProvisioningStateUpdating  WorkloadMonitorProvisioningState = "Updating"
)

func PossibleWorkloadMonitorProvisioningStateValues

func PossibleWorkloadMonitorProvisioningStateValues() []WorkloadMonitorProvisioningState

PossibleWorkloadMonitorProvisioningStateValues returns the possible values for the WorkloadMonitorProvisioningState const type.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL