Documentation ¶
Index ¶
- type Display
- type ErrorResponse
- type ErrorResponseError
- type HanaProvisioningStatesEnum
- type Operation
- type OperationList
- type OperationsClient
- type OperationsClientListOptions
- type OperationsClientListResponse
- type ProviderInstance
- type ProviderInstanceListResult
- type ProviderInstanceProperties
- type ProviderInstancesClient
- func (client *ProviderInstancesClient) BeginCreate(ctx context.Context, resourceGroupName string, sapMonitorName string, ...) (*armruntime.Poller[ProviderInstancesClientCreateResponse], error)
- func (client *ProviderInstancesClient) BeginDelete(ctx context.Context, resourceGroupName string, sapMonitorName string, ...) (*armruntime.Poller[ProviderInstancesClientDeleteResponse], error)
- func (client *ProviderInstancesClient) Get(ctx context.Context, resourceGroupName string, sapMonitorName string, ...) (ProviderInstancesClientGetResponse, error)
- func (client *ProviderInstancesClient) NewListPager(resourceGroupName string, sapMonitorName string, ...) *runtime.Pager[ProviderInstancesClientListResponse]
- type ProviderInstancesClientBeginCreateOptions
- type ProviderInstancesClientBeginDeleteOptions
- type ProviderInstancesClientCreateResponse
- type ProviderInstancesClientDeleteResponse
- type ProviderInstancesClientGetOptions
- type ProviderInstancesClientGetResponse
- type ProviderInstancesClientListOptions
- type ProviderInstancesClientListResponse
- type ProxyResource
- type Resource
- type SapMonitor
- type SapMonitorListResult
- type SapMonitorProperties
- type SapMonitorsClient
- func (client *SapMonitorsClient) BeginCreate(ctx context.Context, resourceGroupName string, sapMonitorName string, ...) (*armruntime.Poller[SapMonitorsClientCreateResponse], error)
- func (client *SapMonitorsClient) BeginDelete(ctx context.Context, resourceGroupName string, sapMonitorName string, ...) (*armruntime.Poller[SapMonitorsClientDeleteResponse], error)
- func (client *SapMonitorsClient) Get(ctx context.Context, resourceGroupName string, sapMonitorName string, ...) (SapMonitorsClientGetResponse, error)
- func (client *SapMonitorsClient) NewListPager(options *SapMonitorsClientListOptions) *runtime.Pager[SapMonitorsClientListResponse]
- func (client *SapMonitorsClient) Update(ctx context.Context, resourceGroupName string, sapMonitorName string, ...) (SapMonitorsClientUpdateResponse, error)
- type SapMonitorsClientBeginCreateOptions
- type SapMonitorsClientBeginDeleteOptions
- type SapMonitorsClientCreateResponse
- type SapMonitorsClientDeleteResponse
- type SapMonitorsClientGetOptions
- type SapMonitorsClientGetResponse
- type SapMonitorsClientListOptions
- type SapMonitorsClientListResponse
- type SapMonitorsClientUpdateOptions
- type SapMonitorsClientUpdateResponse
- type Tags
- type TrackedResource
Examples ¶
- OperationsClient.NewListPager
- ProviderInstancesClient.BeginCreate
- ProviderInstancesClient.BeginDelete
- ProviderInstancesClient.Get
- ProviderInstancesClient.NewListPager
- SapMonitorsClient.BeginCreate
- SapMonitorsClient.BeginDelete
- SapMonitorsClient.Get
- SapMonitorsClient.NewListPager
- SapMonitorsClient.Update
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Display ¶
type Display struct { // READ-ONLY; The localized friendly description for the operation as shown to the user. This description should be thorough, // yet concise. It will be used in tool-tips and detailed views. Description *string `json:"description,omitempty" azure:"ro"` // READ-ONLY; The localized friendly name for the operation as shown to the user. This name should be concise (to fit in drop // downs), but clear (self-documenting). Use Title Casing and include the entity/resource // to which it applies. Operation *string `json:"operation,omitempty" azure:"ro"` // READ-ONLY; The intended executor of the operation; governs the display of the operation in the RBAC UX and the audit logs // UX. Default value is 'user,system' Origin *string `json:"origin,omitempty" azure:"ro"` // READ-ONLY; The localized friendly form of the resource provider name. This form is also expected to include the publisher/company // responsible. Use Title Casing. Begin with "Microsoft" for 1st party services. Provider *string `json:"provider,omitempty" azure:"ro"` // READ-ONLY; The localized friendly form of the resource type related to this action/operation. This form should match the // public documentation for the resource provider. Use Title Casing. For examples, refer to // the “name” section. Resource *string `json:"resource,omitempty" azure:"ro"` }
Display - Detailed HANA operation information
type ErrorResponse ¶
type ErrorResponse struct { // Describes the error object. Error *ErrorResponseError `json:"error,omitempty"` }
ErrorResponse - Describes the format of Error response.
type ErrorResponseError ¶
type ErrorResponseError struct { // READ-ONLY; Error code Code *string `json:"code,omitempty" azure:"ro"` // READ-ONLY; Error message indicating why the operation failed. Message *string `json:"message,omitempty" azure:"ro"` }
ErrorResponseError - Describes the error object.
type HanaProvisioningStatesEnum ¶
type HanaProvisioningStatesEnum string
HanaProvisioningStatesEnum - State of provisioning of the HanaInstance
const ( HanaProvisioningStatesEnumAccepted HanaProvisioningStatesEnum = "Accepted" HanaProvisioningStatesEnumCreating HanaProvisioningStatesEnum = "Creating" HanaProvisioningStatesEnumDeleting HanaProvisioningStatesEnum = "Deleting" HanaProvisioningStatesEnumFailed HanaProvisioningStatesEnum = "Failed" HanaProvisioningStatesEnumMigrating HanaProvisioningStatesEnum = "Migrating" HanaProvisioningStatesEnumSucceeded HanaProvisioningStatesEnum = "Succeeded" HanaProvisioningStatesEnumUpdating HanaProvisioningStatesEnum = "Updating" )
func PossibleHanaProvisioningStatesEnumValues ¶
func PossibleHanaProvisioningStatesEnumValues() []HanaProvisioningStatesEnum
PossibleHanaProvisioningStatesEnumValues returns the possible values for the HanaProvisioningStatesEnum const type.
type Operation ¶
type Operation struct { // Displayed HANA operation information Display *Display `json:"display,omitempty"` // READ-ONLY; The name of the operation being performed on this particular object. This name should match the action name // that appears in RBAC / the event service. Name *string `json:"name,omitempty" azure:"ro"` }
Operation - HANA operation information
type OperationList ¶
type OperationList struct { // List of HANA operations Value []*Operation `json:"value,omitempty"` }
OperationList - List of HANA operations
func (OperationList) MarshalJSON ¶
func (o OperationList) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type OperationList.
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 ¶ added in v0.4.0
func (client *OperationsClient) NewListPager(options *OperationsClientListOptions) *runtime.Pager[OperationsClientListResponse]
NewListPager - Gets a list of SAP HANA management operations. If the operation fails it returns an *azcore.ResponseError type. options - OperationsClientListOptions contains the optional parameters for the OperationsClient.List method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/hanaonazure/resource-manager/Microsoft.HanaOnAzure/preview/2020-02-07-preview/examples/HanaOperations_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/hanaonazure/armhanaonazure" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) return } ctx := context.Background() client, err := armhanaonazure.NewOperationsClient(cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) return } pager := client.NewListPager(nil) for pager.More() { nextResult, err := pager.NextPage(ctx) if err != nil { log.Fatalf("failed to advance page: %v", err) return } for _, v := range nextResult.Value { // TODO: use page item _ = v } } }
Output:
type OperationsClientListOptions ¶ added in v0.2.0
type OperationsClientListOptions struct { }
OperationsClientListOptions contains the optional parameters for the OperationsClient.List method.
type OperationsClientListResponse ¶ added in v0.2.0
type OperationsClientListResponse struct {
OperationList
}
OperationsClientListResponse contains the response from method OperationsClient.List.
type ProviderInstance ¶
type ProviderInstance struct { // 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; 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 a SAP monitor.
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 ¶
func (p ProviderInstanceListResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ProviderInstanceListResult.
type ProviderInstanceProperties ¶
type ProviderInstanceProperties struct { // A JSON string containing metadata of the provider instance. Metadata *string `json:"metadata,omitempty"` // A JSON string containing the properties of the provider instance. Properties *string `json:"properties,omitempty"` // The type of provider instance. Type *string `json:"type,omitempty"` // READ-ONLY; State of provisioning of the provider instance ProvisioningState *HanaProvisioningStatesEnum `json:"provisioningState,omitempty" azure:"ro"` }
ProviderInstanceProperties - Describes the properties of a provider instance.
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 - Subscription ID which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call. 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, sapMonitorName string, providerInstanceName string, providerInstanceParameter ProviderInstance, options *ProviderInstancesClientBeginCreateOptions) (*armruntime.Poller[ProviderInstancesClientCreateResponse], error)
BeginCreate - Creates a provider instance for the specified subscription, resource group, SapMonitor name, and resource name. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - Name of the resource group. sapMonitorName - 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 ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/hanaonazure/resource-manager/Microsoft.HanaOnAzure/preview/2020-02-07-preview/examples/ProviderInstances_Create.json
package main import ( "context" "log" "time" "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/hanaonazure/armhanaonazure" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) return } ctx := context.Background() client, err := armhanaonazure.NewProviderInstancesClient("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) return } poller, err := client.BeginCreate(ctx, "<resource-group-name>", "<sap-monitor-name>", "<provider-instance-name>", armhanaonazure.ProviderInstance{ Properties: &armhanaonazure.ProviderInstanceProperties{ Type: to.Ptr("<type>"), Metadata: to.Ptr("<metadata>"), Properties: to.Ptr("<properties>"), }, }, &armhanaonazure.ProviderInstancesClientBeginCreateOptions{ResumeToken: ""}) if err != nil { log.Fatalf("failed to finish the request: %v", err) return } res, err := poller.PollUntilDone(ctx, 30*time.Second) if err != nil { log.Fatalf("failed to pull the result: %v", err) return } // TODO: use response item _ = res }
Output:
func (*ProviderInstancesClient) BeginDelete ¶
func (client *ProviderInstancesClient) BeginDelete(ctx context.Context, resourceGroupName string, sapMonitorName string, providerInstanceName string, options *ProviderInstancesClientBeginDeleteOptions) (*armruntime.Poller[ProviderInstancesClientDeleteResponse], error)
BeginDelete - Deletes a provider instance for the specified subscription, resource group, SapMonitor name, and resource name. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - Name of the resource group. sapMonitorName - 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/tree/main/specification/hanaonazure/resource-manager/Microsoft.HanaOnAzure/preview/2020-02-07-preview/examples/ProviderInstances_Delete.json
package main import ( "context" "log" "time" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/hanaonazure/armhanaonazure" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) return } ctx := context.Background() client, err := armhanaonazure.NewProviderInstancesClient("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) return } poller, err := client.BeginDelete(ctx, "<resource-group-name>", "<sap-monitor-name>", "<provider-instance-name>", &armhanaonazure.ProviderInstancesClientBeginDeleteOptions{ResumeToken: ""}) if err != nil { log.Fatalf("failed to finish the request: %v", err) return } _, err = poller.PollUntilDone(ctx, 30*time.Second) if err != nil { log.Fatalf("failed to pull the result: %v", err) return } }
Output:
func (*ProviderInstancesClient) Get ¶
func (client *ProviderInstancesClient) Get(ctx context.Context, resourceGroupName string, sapMonitorName string, providerInstanceName string, options *ProviderInstancesClientGetOptions) (ProviderInstancesClientGetResponse, error)
Get - Gets properties of a provider instance for the specified subscription, resource group, SapMonitor name, and resource name. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - Name of the resource group. sapMonitorName - Name of the SAP monitor resource. providerInstanceName - Name of the provider instance. options - ProviderInstancesClientGetOptions contains the optional parameters for the ProviderInstancesClient.Get method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/hanaonazure/resource-manager/Microsoft.HanaOnAzure/preview/2020-02-07-preview/examples/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/hanaonazure/armhanaonazure" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) return } ctx := context.Background() client, err := armhanaonazure.NewProviderInstancesClient("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) return } res, err := client.Get(ctx, "<resource-group-name>", "<sap-monitor-name>", "<provider-instance-name>", nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) return } // TODO: use response item _ = res }
Output:
func (*ProviderInstancesClient) NewListPager ¶ added in v0.4.0
func (client *ProviderInstancesClient) NewListPager(resourceGroupName string, sapMonitorName 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. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - Name of the resource group. sapMonitorName - Name of the SAP monitor resource. options - ProviderInstancesClientListOptions contains the optional parameters for the ProviderInstancesClient.List method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/hanaonazure/resource-manager/Microsoft.HanaOnAzure/preview/2020-02-07-preview/examples/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/hanaonazure/armhanaonazure" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) return } ctx := context.Background() client, err := armhanaonazure.NewProviderInstancesClient("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) return } pager := client.NewListPager("<resource-group-name>", "<sap-monitor-name>", nil) for pager.More() { nextResult, err := pager.NextPage(ctx) if err != nil { log.Fatalf("failed to advance page: %v", err) return } for _, v := range nextResult.Value { // TODO: use page item _ = v } } }
Output:
type ProviderInstancesClientBeginCreateOptions ¶ added in v0.2.0
type ProviderInstancesClientBeginCreateOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
ProviderInstancesClientBeginCreateOptions contains the optional parameters for the ProviderInstancesClient.BeginCreate method.
type ProviderInstancesClientBeginDeleteOptions ¶ added in v0.2.0
type ProviderInstancesClientBeginDeleteOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
ProviderInstancesClientBeginDeleteOptions contains the optional parameters for the ProviderInstancesClient.BeginDelete method.
type ProviderInstancesClientCreateResponse ¶ added in v0.2.0
type ProviderInstancesClientCreateResponse struct {
ProviderInstance
}
ProviderInstancesClientCreateResponse contains the response from method ProviderInstancesClient.Create.
type ProviderInstancesClientDeleteResponse ¶ added in v0.2.0
type ProviderInstancesClientDeleteResponse struct { }
ProviderInstancesClientDeleteResponse contains the response from method ProviderInstancesClient.Delete.
type ProviderInstancesClientGetOptions ¶ added in v0.2.0
type ProviderInstancesClientGetOptions struct { }
ProviderInstancesClientGetOptions contains the optional parameters for the ProviderInstancesClient.Get method.
type ProviderInstancesClientGetResponse ¶ added in v0.2.0
type ProviderInstancesClientGetResponse struct {
ProviderInstance
}
ProviderInstancesClientGetResponse contains the response from method ProviderInstancesClient.Get.
type ProviderInstancesClientListOptions ¶ added in v0.2.0
type ProviderInstancesClientListOptions struct { }
ProviderInstancesClientListOptions contains the optional parameters for the ProviderInstancesClient.List method.
type ProviderInstancesClientListResponse ¶ added in v0.2.0
type ProviderInstancesClientListResponse struct {
ProviderInstanceListResult
}
ProviderInstancesClientListResponse contains the response from method ProviderInstancesClient.List.
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; 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
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; 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
type SapMonitor ¶
type SapMonitor struct { // REQUIRED; The geo-location where the resource lives Location *string `json:"location,omitempty"` // SAP monitor properties Properties *SapMonitorProperties `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; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string `json:"type,omitempty" azure:"ro"` }
SapMonitor - SAP monitor info on Azure (ARM properties and SAP monitor properties)
func (SapMonitor) MarshalJSON ¶
func (s SapMonitor) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type SapMonitor.
type SapMonitorListResult ¶
type SapMonitorListResult struct { // The URL to get the next set of SAP monitors. NextLink *string `json:"nextLink,omitempty"` // The list of SAP monitors. Value []*SapMonitor `json:"value,omitempty"` }
SapMonitorListResult - The response from the List SAP monitors operation.
func (SapMonitorListResult) MarshalJSON ¶
func (s SapMonitorListResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type SapMonitorListResult.
type SapMonitorProperties ¶
type SapMonitorProperties struct { // The value indicating whether to send analytics to Microsoft EnableCustomerAnalytics *bool `json:"enableCustomerAnalytics,omitempty"` // The ARM ID of the Log Analytics Workspace that is used for monitoring LogAnalyticsWorkspaceArmID *string `json:"logAnalyticsWorkspaceArmId,omitempty"` // The workspace ID of the log analytics workspace to be used for monitoring LogAnalyticsWorkspaceID *string `json:"logAnalyticsWorkspaceId,omitempty"` LogAnalyticsWorkspaceSharedKey *string `json:"logAnalyticsWorkspaceSharedKey,omitempty"` // The subnet which the SAP monitor will be deployed in MonitorSubnet *string `json:"monitorSubnet,omitempty"` // READ-ONLY; The name of the resource group the SAP Monitor resources get deployed into. ManagedResourceGroupName *string `json:"managedResourceGroupName,omitempty" azure:"ro"` // READ-ONLY; State of provisioning of the HanaInstance ProvisioningState *HanaProvisioningStatesEnum `json:"provisioningState,omitempty" azure:"ro"` // READ-ONLY; The version of the payload running in the Collector VM SapMonitorCollectorVersion *string `json:"sapMonitorCollectorVersion,omitempty" azure:"ro"` }
SapMonitorProperties - Describes the properties of a SAP monitor.
type SapMonitorsClient ¶
type SapMonitorsClient struct {
// contains filtered or unexported fields
}
SapMonitorsClient contains the methods for the SapMonitors group. Don't use this type directly, use NewSapMonitorsClient() instead.
func NewSapMonitorsClient ¶
func NewSapMonitorsClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*SapMonitorsClient, error)
NewSapMonitorsClient creates a new instance of SapMonitorsClient with the specified values. subscriptionID - Subscription ID which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call. credential - used to authorize requests. Usually a credential from azidentity. options - pass nil to accept the default values.
func (*SapMonitorsClient) BeginCreate ¶
func (client *SapMonitorsClient) BeginCreate(ctx context.Context, resourceGroupName string, sapMonitorName string, sapMonitorParameter SapMonitor, options *SapMonitorsClientBeginCreateOptions) (*armruntime.Poller[SapMonitorsClientCreateResponse], 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. resourceGroupName - Name of the resource group. sapMonitorName - Name of the SAP monitor resource. sapMonitorParameter - Request body representing a SAP Monitor options - SapMonitorsClientBeginCreateOptions contains the optional parameters for the SapMonitorsClient.BeginCreate method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/hanaonazure/resource-manager/Microsoft.HanaOnAzure/preview/2020-02-07-preview/examples/SapMonitors_Create.json
package main import ( "context" "log" "time" "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/hanaonazure/armhanaonazure" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) return } ctx := context.Background() client, err := armhanaonazure.NewSapMonitorsClient("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) return } poller, err := client.BeginCreate(ctx, "<resource-group-name>", "<sap-monitor-name>", armhanaonazure.SapMonitor{ Location: to.Ptr("<location>"), Tags: map[string]*string{ "key": to.Ptr("value"), }, Properties: &armhanaonazure.SapMonitorProperties{ EnableCustomerAnalytics: to.Ptr(true), LogAnalyticsWorkspaceArmID: to.Ptr("<log-analytics-workspace-arm-id>"), LogAnalyticsWorkspaceID: to.Ptr("<log-analytics-workspace-id>"), LogAnalyticsWorkspaceSharedKey: to.Ptr("<log-analytics-workspace-shared-key>"), MonitorSubnet: to.Ptr("<monitor-subnet>"), }, }, &armhanaonazure.SapMonitorsClientBeginCreateOptions{ResumeToken: ""}) if err != nil { log.Fatalf("failed to finish the request: %v", err) return } res, err := poller.PollUntilDone(ctx, 30*time.Second) if err != nil { log.Fatalf("failed to pull the result: %v", err) return } // TODO: use response item _ = res }
Output:
func (*SapMonitorsClient) BeginDelete ¶
func (client *SapMonitorsClient) BeginDelete(ctx context.Context, resourceGroupName string, sapMonitorName string, options *SapMonitorsClientBeginDeleteOptions) (*armruntime.Poller[SapMonitorsClientDeleteResponse], error)
BeginDelete - Deletes a SAP monitor with the specified subscription, resource group, and monitor name. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - Name of the resource group. sapMonitorName - Name of the SAP monitor resource. options - SapMonitorsClientBeginDeleteOptions contains the optional parameters for the SapMonitorsClient.BeginDelete method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/hanaonazure/resource-manager/Microsoft.HanaOnAzure/preview/2020-02-07-preview/examples/SapMonitors_Delete.json
package main import ( "context" "log" "time" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/hanaonazure/armhanaonazure" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) return } ctx := context.Background() client, err := armhanaonazure.NewSapMonitorsClient("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) return } poller, err := client.BeginDelete(ctx, "<resource-group-name>", "<sap-monitor-name>", &armhanaonazure.SapMonitorsClientBeginDeleteOptions{ResumeToken: ""}) if err != nil { log.Fatalf("failed to finish the request: %v", err) return } _, err = poller.PollUntilDone(ctx, 30*time.Second) if err != nil { log.Fatalf("failed to pull the result: %v", err) return } }
Output:
func (*SapMonitorsClient) Get ¶
func (client *SapMonitorsClient) Get(ctx context.Context, resourceGroupName string, sapMonitorName string, options *SapMonitorsClientGetOptions) (SapMonitorsClientGetResponse, 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. resourceGroupName - Name of the resource group. sapMonitorName - Name of the SAP monitor resource. options - SapMonitorsClientGetOptions contains the optional parameters for the SapMonitorsClient.Get method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/hanaonazure/resource-manager/Microsoft.HanaOnAzure/preview/2020-02-07-preview/examples/SapMonitors_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/hanaonazure/armhanaonazure" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) return } ctx := context.Background() client, err := armhanaonazure.NewSapMonitorsClient("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) return } res, err := client.Get(ctx, "<resource-group-name>", "<sap-monitor-name>", nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) return } // TODO: use response item _ = res }
Output:
func (*SapMonitorsClient) NewListPager ¶ added in v0.4.0
func (client *SapMonitorsClient) NewListPager(options *SapMonitorsClientListOptions) *runtime.Pager[SapMonitorsClientListResponse]
NewListPager - Gets a list of SAP monitors in the specified subscription. The operations returns various properties of each SAP monitor. If the operation fails it returns an *azcore.ResponseError type. options - SapMonitorsClientListOptions contains the optional parameters for the SapMonitorsClient.List method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/hanaonazure/resource-manager/Microsoft.HanaOnAzure/preview/2020-02-07-preview/examples/SapMonitors_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/hanaonazure/armhanaonazure" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) return } ctx := context.Background() client, err := armhanaonazure.NewSapMonitorsClient("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) return } pager := client.NewListPager(nil) for pager.More() { nextResult, err := pager.NextPage(ctx) if err != nil { log.Fatalf("failed to advance page: %v", err) return } for _, v := range nextResult.Value { // TODO: use page item _ = v } } }
Output:
func (*SapMonitorsClient) Update ¶
func (client *SapMonitorsClient) Update(ctx context.Context, resourceGroupName string, sapMonitorName string, tagsParameter Tags, options *SapMonitorsClientUpdateOptions) (SapMonitorsClientUpdateResponse, error)
Update - Patches the Tags field of a SAP monitor for the specified subscription, resource group, and monitor name. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - Name of the resource group. sapMonitorName - Name of the SAP monitor resource. tagsParameter - Request body that only contains the new Tags field options - SapMonitorsClientUpdateOptions contains the optional parameters for the SapMonitorsClient.Update method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/hanaonazure/resource-manager/Microsoft.HanaOnAzure/preview/2020-02-07-preview/examples/SapMonitors_PatchTags_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/hanaonazure/armhanaonazure" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) return } ctx := context.Background() client, err := armhanaonazure.NewSapMonitorsClient("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) return } res, err := client.Update(ctx, "<resource-group-name>", "<sap-monitor-name>", armhanaonazure.Tags{ Tags: map[string]*string{}, }, nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) return } // TODO: use response item _ = res }
Output:
type SapMonitorsClientBeginCreateOptions ¶ added in v0.2.0
type SapMonitorsClientBeginCreateOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
SapMonitorsClientBeginCreateOptions contains the optional parameters for the SapMonitorsClient.BeginCreate method.
type SapMonitorsClientBeginDeleteOptions ¶ added in v0.2.0
type SapMonitorsClientBeginDeleteOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
SapMonitorsClientBeginDeleteOptions contains the optional parameters for the SapMonitorsClient.BeginDelete method.
type SapMonitorsClientCreateResponse ¶ added in v0.2.0
type SapMonitorsClientCreateResponse struct {
SapMonitor
}
SapMonitorsClientCreateResponse contains the response from method SapMonitorsClient.Create.
type SapMonitorsClientDeleteResponse ¶ added in v0.2.0
type SapMonitorsClientDeleteResponse struct { }
SapMonitorsClientDeleteResponse contains the response from method SapMonitorsClient.Delete.
type SapMonitorsClientGetOptions ¶ added in v0.2.0
type SapMonitorsClientGetOptions struct { }
SapMonitorsClientGetOptions contains the optional parameters for the SapMonitorsClient.Get method.
type SapMonitorsClientGetResponse ¶ added in v0.2.0
type SapMonitorsClientGetResponse struct {
SapMonitor
}
SapMonitorsClientGetResponse contains the response from method SapMonitorsClient.Get.
type SapMonitorsClientListOptions ¶ added in v0.2.0
type SapMonitorsClientListOptions struct { }
SapMonitorsClientListOptions contains the optional parameters for the SapMonitorsClient.List method.
type SapMonitorsClientListResponse ¶ added in v0.2.0
type SapMonitorsClientListResponse struct {
SapMonitorListResult
}
SapMonitorsClientListResponse contains the response from method SapMonitorsClient.List.
type SapMonitorsClientUpdateOptions ¶ added in v0.2.0
type SapMonitorsClientUpdateOptions struct { }
SapMonitorsClientUpdateOptions contains the optional parameters for the SapMonitorsClient.Update method.
type SapMonitorsClientUpdateResponse ¶ added in v0.2.0
type SapMonitorsClientUpdateResponse struct {
SapMonitor
}
SapMonitorsClientUpdateResponse contains the response from method SapMonitorsClient.Update.
type Tags ¶
Tags field of the resource.
func (Tags) MarshalJSON ¶
MarshalJSON implements the json.Marshaller interface for type Tags.
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; 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.