Documentation ¶
Index ¶
- type AccessKeyType
- type AccessKeys
- type ActionType
- type AofFrequency
- type Client
- func (client *Client) BeginCreate(ctx context.Context, resourceGroupName string, clusterName string, ...) (*runtime.Poller[ClientCreateResponse], error)
- func (client *Client) BeginDelete(ctx context.Context, resourceGroupName string, clusterName string, ...) (*runtime.Poller[ClientDeleteResponse], error)
- func (client *Client) BeginUpdate(ctx context.Context, resourceGroupName string, clusterName string, ...) (*runtime.Poller[ClientUpdateResponse], error)
- func (client *Client) Get(ctx context.Context, resourceGroupName string, clusterName string, ...) (ClientGetResponse, error)
- func (client *Client) NewListByResourceGroupPager(resourceGroupName string, options *ClientListByResourceGroupOptions) *runtime.Pager[ClientListByResourceGroupResponse]
- func (client *Client) NewListPager(options *ClientListOptions) *runtime.Pager[ClientListResponse]
- type ClientBeginCreateOptions
- type ClientBeginDeleteOptions
- type ClientBeginUpdateOptions
- type ClientCreateResponse
- type ClientDeleteResponse
- type ClientFactory
- func (c *ClientFactory) NewClient() *Client
- func (c *ClientFactory) NewDatabasesClient() *DatabasesClient
- func (c *ClientFactory) NewOperationsClient() *OperationsClient
- func (c *ClientFactory) NewOperationsStatusClient() *OperationsStatusClient
- func (c *ClientFactory) NewPrivateEndpointConnectionsClient() *PrivateEndpointConnectionsClient
- func (c *ClientFactory) NewPrivateLinkResourcesClient() *PrivateLinkResourcesClient
- type ClientGetOptions
- type ClientGetResponse
- type ClientListByResourceGroupOptions
- type ClientListByResourceGroupResponse
- type ClientListOptions
- type ClientListResponse
- type ClientUpdateResponse
- type Cluster
- type ClusterList
- type ClusterProperties
- type ClusterPropertiesEncryption
- type ClusterPropertiesEncryptionCustomerManagedKeyEncryption
- type ClusterPropertiesEncryptionCustomerManagedKeyEncryptionKeyIdentity
- type ClusterUpdate
- type ClusteringPolicy
- type CmkIdentityType
- type Database
- type DatabaseList
- type DatabaseProperties
- type DatabasePropertiesGeoReplication
- type DatabaseUpdate
- type DatabasesClient
- func (client *DatabasesClient) BeginCreate(ctx context.Context, resourceGroupName string, clusterName string, ...) (*runtime.Poller[DatabasesClientCreateResponse], error)
- func (client *DatabasesClient) BeginDelete(ctx context.Context, resourceGroupName string, clusterName string, ...) (*runtime.Poller[DatabasesClientDeleteResponse], error)
- func (client *DatabasesClient) BeginExport(ctx context.Context, resourceGroupName string, clusterName string, ...) (*runtime.Poller[DatabasesClientExportResponse], error)
- func (client *DatabasesClient) BeginFlush(ctx context.Context, resourceGroupName string, clusterName string, ...) (*runtime.Poller[DatabasesClientFlushResponse], error)
- func (client *DatabasesClient) BeginForceUnlink(ctx context.Context, resourceGroupName string, clusterName string, ...) (*runtime.Poller[DatabasesClientForceUnlinkResponse], error)
- func (client *DatabasesClient) BeginImport(ctx context.Context, resourceGroupName string, clusterName string, ...) (*runtime.Poller[DatabasesClientImportResponse], error)
- func (client *DatabasesClient) BeginRegenerateKey(ctx context.Context, resourceGroupName string, clusterName string, ...) (*runtime.Poller[DatabasesClientRegenerateKeyResponse], error)
- func (client *DatabasesClient) BeginUpdate(ctx context.Context, resourceGroupName string, clusterName string, ...) (*runtime.Poller[DatabasesClientUpdateResponse], error)
- func (client *DatabasesClient) Get(ctx context.Context, resourceGroupName string, clusterName string, ...) (DatabasesClientGetResponse, error)
- func (client *DatabasesClient) ListKeys(ctx context.Context, resourceGroupName string, clusterName string, ...) (DatabasesClientListKeysResponse, error)
- func (client *DatabasesClient) NewListByClusterPager(resourceGroupName string, clusterName string, ...) *runtime.Pager[DatabasesClientListByClusterResponse]
- type DatabasesClientBeginCreateOptions
- type DatabasesClientBeginDeleteOptions
- type DatabasesClientBeginExportOptions
- type DatabasesClientBeginFlushOptions
- type DatabasesClientBeginForceUnlinkOptions
- type DatabasesClientBeginImportOptions
- type DatabasesClientBeginRegenerateKeyOptions
- type DatabasesClientBeginUpdateOptions
- type DatabasesClientCreateResponse
- type DatabasesClientDeleteResponse
- type DatabasesClientExportResponse
- type DatabasesClientFlushResponse
- type DatabasesClientForceUnlinkResponse
- type DatabasesClientGetOptions
- type DatabasesClientGetResponse
- type DatabasesClientImportResponse
- type DatabasesClientListByClusterOptions
- type DatabasesClientListByClusterResponse
- type DatabasesClientListKeysOptions
- type DatabasesClientListKeysResponse
- type DatabasesClientRegenerateKeyResponse
- type DatabasesClientUpdateResponse
- type ErrorAdditionalInfo
- type ErrorDetail
- type ErrorResponse
- type EvictionPolicy
- type ExportClusterParameters
- type FlushParameters
- type ForceUnlinkParameters
- type ImportClusterParameters
- type LinkState
- type LinkedDatabase
- type ManagedServiceIdentity
- type ManagedServiceIdentityType
- type Module
- type Operation
- type OperationDisplay
- type OperationListResult
- type OperationStatus
- type OperationsClient
- type OperationsClientListOptions
- type OperationsClientListResponse
- type OperationsStatusClient
- type OperationsStatusClientGetOptions
- type OperationsStatusClientGetResponse
- type Origin
- type Persistence
- type PrivateEndpoint
- type PrivateEndpointConnection
- type PrivateEndpointConnectionListResult
- type PrivateEndpointConnectionProperties
- type PrivateEndpointConnectionProvisioningState
- type PrivateEndpointConnectionsClient
- func (client *PrivateEndpointConnectionsClient) BeginDelete(ctx context.Context, resourceGroupName string, clusterName string, ...) (*runtime.Poller[PrivateEndpointConnectionsClientDeleteResponse], error)
- func (client *PrivateEndpointConnectionsClient) BeginPut(ctx context.Context, resourceGroupName string, clusterName string, ...) (*runtime.Poller[PrivateEndpointConnectionsClientPutResponse], error)
- func (client *PrivateEndpointConnectionsClient) Get(ctx context.Context, resourceGroupName string, clusterName string, ...) (PrivateEndpointConnectionsClientGetResponse, error)
- func (client *PrivateEndpointConnectionsClient) NewListPager(resourceGroupName string, clusterName string, ...) *runtime.Pager[PrivateEndpointConnectionsClientListResponse]
- type PrivateEndpointConnectionsClientBeginDeleteOptions
- type PrivateEndpointConnectionsClientBeginPutOptions
- type PrivateEndpointConnectionsClientDeleteResponse
- type PrivateEndpointConnectionsClientGetOptions
- type PrivateEndpointConnectionsClientGetResponse
- type PrivateEndpointConnectionsClientListOptions
- type PrivateEndpointConnectionsClientListResponse
- type PrivateEndpointConnectionsClientPutResponse
- type PrivateEndpointServiceConnectionStatus
- type PrivateLinkResource
- type PrivateLinkResourceListResult
- type PrivateLinkResourceProperties
- type PrivateLinkResourcesClient
- type PrivateLinkResourcesClientListByClusterOptions
- type PrivateLinkResourcesClientListByClusterResponse
- type PrivateLinkServiceConnectionState
- type Protocol
- type ProvisioningState
- type ProxyResource
- type RdbFrequency
- type RegenerateKeyParameters
- type Resource
- type ResourceState
- type SKU
- type SKUName
- type TLSVersion
- type TrackedResource
- type UserAssignedIdentity
Examples ¶
- Client.BeginCreate
- Client.BeginDelete
- Client.BeginUpdate
- Client.Get
- Client.NewListByResourceGroupPager
- Client.NewListPager
- DatabasesClient.BeginCreate (RedisEnterpriseDatabasesCreate)
- DatabasesClient.BeginCreate (RedisEnterpriseDatabasesCreateWithActiveGeoReplication)
- DatabasesClient.BeginDelete
- DatabasesClient.BeginExport
- DatabasesClient.BeginFlush
- DatabasesClient.BeginForceUnlink
- DatabasesClient.BeginImport
- DatabasesClient.BeginRegenerateKey
- DatabasesClient.BeginUpdate
- DatabasesClient.Get
- DatabasesClient.ListKeys
- DatabasesClient.NewListByClusterPager
- OperationsClient.NewListPager
- OperationsStatusClient.Get
- PrivateEndpointConnectionsClient.BeginDelete
- PrivateEndpointConnectionsClient.BeginPut
- PrivateEndpointConnectionsClient.Get
- PrivateEndpointConnectionsClient.NewListPager
- PrivateLinkResourcesClient.NewListByClusterPager
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AccessKeyType ¶
type AccessKeyType string
AccessKeyType - Which access key to regenerate.
const ( AccessKeyTypePrimary AccessKeyType = "Primary" AccessKeyTypeSecondary AccessKeyType = "Secondary" )
func PossibleAccessKeyTypeValues ¶
func PossibleAccessKeyTypeValues() []AccessKeyType
PossibleAccessKeyTypeValues returns the possible values for the AccessKeyType const type.
type AccessKeys ¶
type AccessKeys struct { // READ-ONLY; The current primary key that clients can use to authenticate PrimaryKey *string // READ-ONLY; The current secondary key that clients can use to authenticate SecondaryKey *string }
AccessKeys - The secret access keys used for authenticating connections to redis
func (AccessKeys) MarshalJSON ¶
func (a AccessKeys) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type AccessKeys.
func (*AccessKeys) UnmarshalJSON ¶
func (a *AccessKeys) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type AccessKeys.
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 AofFrequency ¶
type AofFrequency string
AofFrequency - Sets the frequency at which data is written to disk.
const ( AofFrequencyAlways AofFrequency = "always" AofFrequencyOneS AofFrequency = "1s" )
func PossibleAofFrequencyValues ¶
func PossibleAofFrequencyValues() []AofFrequency
PossibleAofFrequencyValues returns the possible values for the AofFrequency const type.
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client contains the methods for the RedisEnterprise group. Don't use this type directly, use NewClient() instead.
func NewClient ¶
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) BeginCreate ¶
func (client *Client) BeginCreate(ctx context.Context, resourceGroupName string, clusterName string, parameters Cluster, options *ClientBeginCreateOptions) (*runtime.Poller[ClientCreateResponse], error)
BeginCreate - Creates or updates an existing (overwrite/recreate, with potential downtime) cache cluster If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2023-11-01
- resourceGroupName - The name of the resource group. The name is case insensitive.
- clusterName - The name of the RedisEnterprise cluster.
- parameters - Parameters supplied to the Create RedisEnterprise operation.
- options - ClientBeginCreateOptions contains the optional parameters for the Client.BeginCreate method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/d4205894880b989ede35d62d97c8e901ed14fb5a/specification/redisenterprise/resource-manager/Microsoft.Cache/stable/2023-11-01/examples/RedisEnterpriseCreate.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armredisenterprise.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewClient().BeginCreate(ctx, "rg1", "cache1", armredisenterprise.Cluster{ Location: to.Ptr("West US"), Tags: map[string]*string{ "tag1": to.Ptr("value1"), }, Identity: &armredisenterprise.ManagedServiceIdentity{ Type: to.Ptr(armredisenterprise.ManagedServiceIdentityTypeUserAssigned), UserAssignedIdentities: map[string]*armredisenterprise.UserAssignedIdentity{ "/subscriptions/your-subscription/resourceGroups/your-rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/your-identity": {}, }, }, Properties: &armredisenterprise.ClusterProperties{ Encryption: &armredisenterprise.ClusterPropertiesEncryption{ CustomerManagedKeyEncryption: &armredisenterprise.ClusterPropertiesEncryptionCustomerManagedKeyEncryption{ KeyEncryptionKeyIdentity: &armredisenterprise.ClusterPropertiesEncryptionCustomerManagedKeyEncryptionKeyIdentity{ IdentityType: to.Ptr(armredisenterprise.CmkIdentityTypeUserAssignedIdentity), UserAssignedIdentityResourceID: to.Ptr("/subscriptions/your-subscription/resourceGroups/your-rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/your-identity"), }, KeyEncryptionKeyURL: to.Ptr("https://your-kv.vault.azure.net/keys/your-key/your-key-version"), }, }, MinimumTLSVersion: to.Ptr(armredisenterprise.TLSVersionOne2), }, SKU: &armredisenterprise.SKU{ Name: to.Ptr(armredisenterprise.SKUNameEnterpriseFlashF300), Capacity: to.Ptr[int32](3), }, Zones: []*string{ to.Ptr("1"), to.Ptr("2"), to.Ptr("3")}, }, 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.Cluster = armredisenterprise.Cluster{ // Name: to.Ptr("cache1"), // Type: to.Ptr("Microsoft.Cache/redisEnterprise"), // ID: to.Ptr("/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Cache/redisEnterprise/cache1"), // Location: to.Ptr("West US"), // Tags: map[string]*string{ // "tag1": to.Ptr("value1"), // }, // Identity: &armredisenterprise.ManagedServiceIdentity{ // Type: to.Ptr(armredisenterprise.ManagedServiceIdentityTypeUserAssigned), // UserAssignedIdentities: map[string]*armredisenterprise.UserAssignedIdentity{ // "/subscriptions/your-subscription/resourceGroups/your-rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/your-identity": &armredisenterprise.UserAssignedIdentity{ // ClientID: to.Ptr("00000000-0000-0000-0000-000000000000"), // PrincipalID: to.Ptr("00000000-0000-0000-0000-000000000000"), // }, // }, // }, // Properties: &armredisenterprise.ClusterProperties{ // HostName: to.Ptr("cache1.westus.something.azure.net"), // MinimumTLSVersion: to.Ptr(armredisenterprise.TLSVersionOne2), // ProvisioningState: to.Ptr(armredisenterprise.ProvisioningStateSucceeded), // RedisVersion: to.Ptr("5"), // ResourceState: to.Ptr(armredisenterprise.ResourceStateRunning), // }, // SKU: &armredisenterprise.SKU{ // Name: to.Ptr(armredisenterprise.SKUNameEnterpriseFlashF300), // Capacity: to.Ptr[int32](3), // }, // Zones: []*string{ // to.Ptr("1"), // to.Ptr("2"), // to.Ptr("3")}, // }
Output:
func (*Client) BeginDelete ¶
func (client *Client) BeginDelete(ctx context.Context, resourceGroupName string, clusterName string, options *ClientBeginDeleteOptions) (*runtime.Poller[ClientDeleteResponse], error)
BeginDelete - Deletes a RedisEnterprise cache cluster. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2023-11-01
- resourceGroupName - The name of the resource group. The name is case insensitive.
- clusterName - The name of the RedisEnterprise cluster.
- options - ClientBeginDeleteOptions contains the optional parameters for the Client.BeginDelete method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/d4205894880b989ede35d62d97c8e901ed14fb5a/specification/redisenterprise/resource-manager/Microsoft.Cache/stable/2023-11-01/examples/RedisEnterpriseDelete.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armredisenterprise.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewClient().BeginDelete(ctx, "rg1", "cache1", nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } _, err = poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %v", err) }
Output:
func (*Client) BeginUpdate ¶
func (client *Client) BeginUpdate(ctx context.Context, resourceGroupName string, clusterName string, parameters ClusterUpdate, options *ClientBeginUpdateOptions) (*runtime.Poller[ClientUpdateResponse], error)
BeginUpdate - Updates an existing RedisEnterprise cluster If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2023-11-01
- resourceGroupName - The name of the resource group. The name is case insensitive.
- clusterName - The name of the RedisEnterprise cluster.
- parameters - Parameters supplied to the Update RedisEnterprise operation.
- options - ClientBeginUpdateOptions contains the optional parameters for the Client.BeginUpdate method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/d4205894880b989ede35d62d97c8e901ed14fb5a/specification/redisenterprise/resource-manager/Microsoft.Cache/stable/2023-11-01/examples/RedisEnterpriseUpdate.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armredisenterprise.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewClient().BeginUpdate(ctx, "rg1", "cache1", armredisenterprise.ClusterUpdate{ Properties: &armredisenterprise.ClusterProperties{ MinimumTLSVersion: to.Ptr(armredisenterprise.TLSVersionOne2), }, SKU: &armredisenterprise.SKU{ Name: to.Ptr(armredisenterprise.SKUNameEnterpriseFlashF300), Capacity: to.Ptr[int32](9), }, 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.Cluster = armredisenterprise.Cluster{ // Name: to.Ptr("cache1"), // Type: to.Ptr("Microsoft.Cache/redisEnterprise"), // ID: to.Ptr("/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Cache/redisEnterprise/cache1"), // Location: to.Ptr("West US"), // Tags: map[string]*string{ // "tag1": to.Ptr("value1"), // }, // Identity: &armredisenterprise.ManagedServiceIdentity{ // Type: to.Ptr(armredisenterprise.ManagedServiceIdentityTypeNone), // }, // Properties: &armredisenterprise.ClusterProperties{ // Encryption: &armredisenterprise.ClusterPropertiesEncryption{ // }, // HostName: to.Ptr("cache1.westus.something.azure.com"), // MinimumTLSVersion: to.Ptr(armredisenterprise.TLSVersionOne2), // ProvisioningState: to.Ptr(armredisenterprise.ProvisioningStateSucceeded), // RedisVersion: to.Ptr("5"), // ResourceState: to.Ptr(armredisenterprise.ResourceStateUpdating), // }, // SKU: &armredisenterprise.SKU{ // Name: to.Ptr(armredisenterprise.SKUNameEnterpriseFlashF300), // Capacity: to.Ptr[int32](9), // }, // Zones: []*string{ // to.Ptr("1"), // to.Ptr("2"), // to.Ptr("3")}, // }
Output:
func (*Client) Get ¶
func (client *Client) Get(ctx context.Context, resourceGroupName string, clusterName string, options *ClientGetOptions) (ClientGetResponse, error)
Get - Gets information about a RedisEnterprise cluster If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2023-11-01
- resourceGroupName - The name of the resource group. The name is case insensitive.
- clusterName - The name of the RedisEnterprise cluster.
- options - ClientGetOptions contains the optional parameters for the Client.Get method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/d4205894880b989ede35d62d97c8e901ed14fb5a/specification/redisenterprise/resource-manager/Microsoft.Cache/stable/2023-11-01/examples/RedisEnterpriseGet.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armredisenterprise.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewClient().Get(ctx, "rg1", "cache1", 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.Cluster = armredisenterprise.Cluster{ // Name: to.Ptr("cache1"), // Type: to.Ptr("Microsoft.Cache/redisEnterprise"), // ID: to.Ptr("/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Cache/redisEnterprise/cache1"), // Location: to.Ptr("West US"), // Tags: map[string]*string{ // }, // Properties: &armredisenterprise.ClusterProperties{ // HostName: to.Ptr("cache1.westus.something.azure.com"), // MinimumTLSVersion: to.Ptr(armredisenterprise.TLSVersionOne2), // PrivateEndpointConnections: []*armredisenterprise.PrivateEndpointConnection{ // { // ID: to.Ptr("/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Cache/redisEnterprise/cache1/privateEndpointConnections/cachePec"), // Properties: &armredisenterprise.PrivateEndpointConnectionProperties{ // PrivateEndpoint: &armredisenterprise.PrivateEndpoint{ // ID: to.Ptr("/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/privateEndpoints/cachePe"), // }, // PrivateLinkServiceConnectionState: &armredisenterprise.PrivateLinkServiceConnectionState{ // Description: to.Ptr("Please approve my connection"), // ActionsRequired: to.Ptr("None"), // Status: to.Ptr(armredisenterprise.PrivateEndpointServiceConnectionStatusApproved), // }, // }, // }}, // ProvisioningState: to.Ptr(armredisenterprise.ProvisioningStateSucceeded), // RedisVersion: to.Ptr("6"), // ResourceState: to.Ptr(armredisenterprise.ResourceStateRunning), // }, // SKU: &armredisenterprise.SKU{ // Name: to.Ptr(armredisenterprise.SKUNameEnterpriseFlashF300), // Capacity: to.Ptr[int32](3), // }, // Zones: []*string{ // to.Ptr("1"), // to.Ptr("2"), // to.Ptr("3")}, // }
Output:
func (*Client) NewListByResourceGroupPager ¶
func (client *Client) NewListByResourceGroupPager(resourceGroupName string, options *ClientListByResourceGroupOptions) *runtime.Pager[ClientListByResourceGroupResponse]
NewListByResourceGroupPager - Lists all RedisEnterprise clusters in a resource group.
Generated from API version 2023-11-01
- resourceGroupName - The name of the resource group. The name is case insensitive.
- options - ClientListByResourceGroupOptions contains the optional parameters for the Client.NewListByResourceGroupPager method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/d4205894880b989ede35d62d97c8e901ed14fb5a/specification/redisenterprise/resource-manager/Microsoft.Cache/stable/2023-11-01/examples/RedisEnterpriseListByResourceGroup.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armredisenterprise.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } pager := clientFactory.NewClient().NewListByResourceGroupPager("rg1", 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.ClusterList = armredisenterprise.ClusterList{ // Value: []*armredisenterprise.Cluster{ // { // Name: to.Ptr("cache1"), // Type: to.Ptr("Microsoft.Cache/redisEnterprise"), // ID: to.Ptr("/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Cache/redisEnterprise/cache1"), // Location: to.Ptr("West US"), // Tags: map[string]*string{ // }, // Properties: &armredisenterprise.ClusterProperties{ // HostName: to.Ptr("cache1.westus.something.azure.com"), // MinimumTLSVersion: to.Ptr(armredisenterprise.TLSVersionOne2), // ProvisioningState: to.Ptr(armredisenterprise.ProvisioningStateSucceeded), // RedisVersion: to.Ptr("5"), // ResourceState: to.Ptr(armredisenterprise.ResourceStateRunning), // }, // SKU: &armredisenterprise.SKU{ // Name: to.Ptr(armredisenterprise.SKUNameEnterpriseFlashF300), // Capacity: to.Ptr[int32](3), // }, // Zones: []*string{ // to.Ptr("1"), // to.Ptr("2"), // to.Ptr("3")}, // }}, // } }
Output:
func (*Client) NewListPager ¶
func (client *Client) NewListPager(options *ClientListOptions) *runtime.Pager[ClientListResponse]
NewListPager - Gets all RedisEnterprise clusters in the specified subscription.
Generated from API version 2023-11-01
- options - ClientListOptions contains the optional parameters for the Client.NewListPager method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/d4205894880b989ede35d62d97c8e901ed14fb5a/specification/redisenterprise/resource-manager/Microsoft.Cache/stable/2023-11-01/examples/RedisEnterpriseList.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armredisenterprise.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } pager := clientFactory.NewClient().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.ClusterList = armredisenterprise.ClusterList{ // Value: []*armredisenterprise.Cluster{ // { // Name: to.Ptr("cache1"), // Type: to.Ptr("Microsoft.Cache/redisEnterprise"), // ID: to.Ptr("/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Cache/redisEnterprise/cache1"), // Location: to.Ptr("West US"), // Tags: map[string]*string{ // }, // Properties: &armredisenterprise.ClusterProperties{ // HostName: to.Ptr("cache1.westus.something.azure.com"), // MinimumTLSVersion: to.Ptr(armredisenterprise.TLSVersionOne2), // ProvisioningState: to.Ptr(armredisenterprise.ProvisioningStateSucceeded), // RedisVersion: to.Ptr("6"), // ResourceState: to.Ptr(armredisenterprise.ResourceStateRunning), // }, // SKU: &armredisenterprise.SKU{ // Name: to.Ptr(armredisenterprise.SKUNameEnterpriseFlashF300), // Capacity: to.Ptr[int32](3), // }, // }}, // } }
Output:
type ClientBeginCreateOptions ¶
type ClientBeginCreateOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
ClientBeginCreateOptions contains the optional parameters for the Client.BeginCreate method.
type ClientBeginDeleteOptions ¶
type ClientBeginDeleteOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
ClientBeginDeleteOptions contains the optional parameters for the Client.BeginDelete method.
type ClientBeginUpdateOptions ¶
type ClientBeginUpdateOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
ClientBeginUpdateOptions contains the optional parameters for the Client.BeginUpdate method.
type ClientCreateResponse ¶
type ClientCreateResponse struct { // Describes the RedisEnterprise cluster Cluster }
ClientCreateResponse contains the response from method Client.BeginCreate.
type ClientDeleteResponse ¶
type ClientDeleteResponse struct { }
ClientDeleteResponse contains the response from method Client.BeginDelete.
type ClientFactory ¶
type ClientFactory struct {
// contains filtered or unexported fields
}
ClientFactory is a client factory used to create any client in this module. Don't use this type directly, use NewClientFactory instead.
func NewClientFactory ¶
func NewClientFactory(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*ClientFactory, error)
NewClientFactory creates a new instance of ClientFactory with the specified values. The parameter values will be propagated to any client created from this factory.
- 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 (*ClientFactory) NewClient ¶
func (c *ClientFactory) NewClient() *Client
NewClient creates a new instance of Client.
func (*ClientFactory) NewDatabasesClient ¶
func (c *ClientFactory) NewDatabasesClient() *DatabasesClient
NewDatabasesClient creates a new instance of DatabasesClient.
func (*ClientFactory) NewOperationsClient ¶
func (c *ClientFactory) NewOperationsClient() *OperationsClient
NewOperationsClient creates a new instance of OperationsClient.
func (*ClientFactory) NewOperationsStatusClient ¶
func (c *ClientFactory) NewOperationsStatusClient() *OperationsStatusClient
NewOperationsStatusClient creates a new instance of OperationsStatusClient.
func (*ClientFactory) NewPrivateEndpointConnectionsClient ¶
func (c *ClientFactory) NewPrivateEndpointConnectionsClient() *PrivateEndpointConnectionsClient
NewPrivateEndpointConnectionsClient creates a new instance of PrivateEndpointConnectionsClient.
func (*ClientFactory) NewPrivateLinkResourcesClient ¶
func (c *ClientFactory) NewPrivateLinkResourcesClient() *PrivateLinkResourcesClient
NewPrivateLinkResourcesClient creates a new instance of PrivateLinkResourcesClient.
type ClientGetOptions ¶
type ClientGetOptions struct { }
ClientGetOptions contains the optional parameters for the Client.Get method.
type ClientGetResponse ¶
type ClientGetResponse struct { // Describes the RedisEnterprise cluster Cluster }
ClientGetResponse contains the response from method Client.Get.
type ClientListByResourceGroupOptions ¶
type ClientListByResourceGroupOptions struct { }
ClientListByResourceGroupOptions contains the optional parameters for the Client.NewListByResourceGroupPager method.
type ClientListByResourceGroupResponse ¶
type ClientListByResourceGroupResponse struct { // The response of a list-all operation. ClusterList }
ClientListByResourceGroupResponse contains the response from method Client.NewListByResourceGroupPager.
type ClientListOptions ¶
type ClientListOptions struct { }
ClientListOptions contains the optional parameters for the Client.NewListPager method.
type ClientListResponse ¶
type ClientListResponse struct { // The response of a list-all operation. ClusterList }
ClientListResponse contains the response from method Client.NewListPager.
type ClientUpdateResponse ¶
type ClientUpdateResponse struct { // Describes the RedisEnterprise cluster Cluster }
ClientUpdateResponse contains the response from method Client.BeginUpdate.
type Cluster ¶
type Cluster struct { // REQUIRED; The geo-location where the resource lives Location *string // REQUIRED; The SKU to create, which affects price, performance, and features. SKU *SKU // The identity of the resource. Identity *ManagedServiceIdentity // Other properties of the cluster. Properties *ClusterProperties // Resource tags. Tags map[string]*string // The Availability Zones where this cluster will be deployed. Zones []*string // READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string // READ-ONLY; The name of the resource Name *string // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string }
Cluster - Describes the RedisEnterprise cluster
func (Cluster) MarshalJSON ¶
MarshalJSON implements the json.Marshaller interface for type Cluster.
func (*Cluster) UnmarshalJSON ¶
UnmarshalJSON implements the json.Unmarshaller interface for type Cluster.
type ClusterList ¶
type ClusterList struct { // List of clusters. Value []*Cluster // READ-ONLY; The URI to fetch the next page of results. NextLink *string }
ClusterList - The response of a list-all operation.
func (ClusterList) MarshalJSON ¶
func (c ClusterList) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ClusterList.
func (*ClusterList) UnmarshalJSON ¶
func (c *ClusterList) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ClusterList.
type ClusterProperties ¶
type ClusterProperties struct { // Encryption-at-rest configuration for the cluster. Encryption *ClusterPropertiesEncryption // The minimum TLS version for the cluster to support, e.g. '1.2' MinimumTLSVersion *TLSVersion // READ-ONLY; DNS name of the cluster endpoint HostName *string // READ-ONLY; List of private endpoint connections associated with the specified RedisEnterprise cluster PrivateEndpointConnections []*PrivateEndpointConnection // READ-ONLY; Current provisioning status of the cluster ProvisioningState *ProvisioningState // READ-ONLY; Version of redis the cluster supports, e.g. '6' RedisVersion *string // READ-ONLY; Current resource status of the cluster ResourceState *ResourceState }
ClusterProperties - Properties of RedisEnterprise clusters, as opposed to general resource properties like location, tags
func (ClusterProperties) MarshalJSON ¶
func (c ClusterProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ClusterProperties.
func (*ClusterProperties) UnmarshalJSON ¶
func (c *ClusterProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ClusterProperties.
type ClusterPropertiesEncryption ¶
type ClusterPropertiesEncryption struct { // All Customer-managed key encryption properties for the resource. Set this to an empty object to use Microsoft-managed key // encryption. CustomerManagedKeyEncryption *ClusterPropertiesEncryptionCustomerManagedKeyEncryption }
ClusterPropertiesEncryption - Encryption-at-rest configuration for the cluster.
func (ClusterPropertiesEncryption) MarshalJSON ¶
func (c ClusterPropertiesEncryption) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ClusterPropertiesEncryption.
func (*ClusterPropertiesEncryption) UnmarshalJSON ¶
func (c *ClusterPropertiesEncryption) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ClusterPropertiesEncryption.
type ClusterPropertiesEncryptionCustomerManagedKeyEncryption ¶
type ClusterPropertiesEncryptionCustomerManagedKeyEncryption struct { // All identity configuration for Customer-managed key settings defining which identity should be used to auth to Key Vault. KeyEncryptionKeyIdentity *ClusterPropertiesEncryptionCustomerManagedKeyEncryptionKeyIdentity // Key encryption key Url, versioned only. Ex: https://contosovault.vault.azure.net/keys/contosokek/562a4bb76b524a1493a6afe8e536ee78 KeyEncryptionKeyURL *string }
ClusterPropertiesEncryptionCustomerManagedKeyEncryption - All Customer-managed key encryption properties for the resource. Set this to an empty object to use Microsoft-managed key encryption.
func (ClusterPropertiesEncryptionCustomerManagedKeyEncryption) MarshalJSON ¶
func (c ClusterPropertiesEncryptionCustomerManagedKeyEncryption) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ClusterPropertiesEncryptionCustomerManagedKeyEncryption.
func (*ClusterPropertiesEncryptionCustomerManagedKeyEncryption) UnmarshalJSON ¶
func (c *ClusterPropertiesEncryptionCustomerManagedKeyEncryption) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ClusterPropertiesEncryptionCustomerManagedKeyEncryption.
type ClusterPropertiesEncryptionCustomerManagedKeyEncryptionKeyIdentity ¶
type ClusterPropertiesEncryptionCustomerManagedKeyEncryptionKeyIdentity struct { // Only userAssignedIdentity is supported in this API version; other types may be supported in the future IdentityType *CmkIdentityType // User assigned identity to use for accessing key encryption key Url. Ex: /subscriptions//resourceGroups//providers/Microsoft.ManagedIdentity/userAssignedIdentities/myId. UserAssignedIdentityResourceID *string }
ClusterPropertiesEncryptionCustomerManagedKeyEncryptionKeyIdentity - All identity configuration for Customer-managed key settings defining which identity should be used to auth to Key Vault.
func (ClusterPropertiesEncryptionCustomerManagedKeyEncryptionKeyIdentity) MarshalJSON ¶
func (c ClusterPropertiesEncryptionCustomerManagedKeyEncryptionKeyIdentity) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ClusterPropertiesEncryptionCustomerManagedKeyEncryptionKeyIdentity.
func (*ClusterPropertiesEncryptionCustomerManagedKeyEncryptionKeyIdentity) UnmarshalJSON ¶
func (c *ClusterPropertiesEncryptionCustomerManagedKeyEncryptionKeyIdentity) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ClusterPropertiesEncryptionCustomerManagedKeyEncryptionKeyIdentity.
type ClusterUpdate ¶
type ClusterUpdate struct { // The identity of the resource. Identity *ManagedServiceIdentity // Other properties of the cluster. Properties *ClusterProperties // The SKU to create, which affects price, performance, and features. SKU *SKU // Resource tags. Tags map[string]*string }
ClusterUpdate - A partial update to the RedisEnterprise cluster
func (ClusterUpdate) MarshalJSON ¶
func (c ClusterUpdate) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ClusterUpdate.
func (*ClusterUpdate) UnmarshalJSON ¶
func (c *ClusterUpdate) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ClusterUpdate.
type ClusteringPolicy ¶
type ClusteringPolicy string
ClusteringPolicy - Clustering policy - default is OSSCluster. Specified at create time.
const ( ClusteringPolicyEnterpriseCluster ClusteringPolicy = "EnterpriseCluster" ClusteringPolicyOSSCluster ClusteringPolicy = "OSSCluster" )
func PossibleClusteringPolicyValues ¶
func PossibleClusteringPolicyValues() []ClusteringPolicy
PossibleClusteringPolicyValues returns the possible values for the ClusteringPolicy const type.
type CmkIdentityType ¶
type CmkIdentityType string
CmkIdentityType - Only userAssignedIdentity is supported in this API version; other types may be supported in the future
const ( CmkIdentityTypeSystemAssignedIdentity CmkIdentityType = "systemAssignedIdentity" CmkIdentityTypeUserAssignedIdentity CmkIdentityType = "userAssignedIdentity" )
func PossibleCmkIdentityTypeValues ¶
func PossibleCmkIdentityTypeValues() []CmkIdentityType
PossibleCmkIdentityTypeValues returns the possible values for the CmkIdentityType const type.
type Database ¶
type Database struct { // Other properties of the database. Properties *DatabaseProperties // READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string // READ-ONLY; The name of the resource Name *string // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string }
Database - Describes a database on the RedisEnterprise cluster
func (Database) MarshalJSON ¶
MarshalJSON implements the json.Marshaller interface for type Database.
func (*Database) UnmarshalJSON ¶
UnmarshalJSON implements the json.Unmarshaller interface for type Database.
type DatabaseList ¶
type DatabaseList struct { // List of databases Value []*Database // READ-ONLY; The URI to fetch the next page of results. NextLink *string }
DatabaseList - The response of a list-all operation.
func (DatabaseList) MarshalJSON ¶
func (d DatabaseList) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type DatabaseList.
func (*DatabaseList) UnmarshalJSON ¶
func (d *DatabaseList) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type DatabaseList.
type DatabaseProperties ¶
type DatabaseProperties struct { // Specifies whether redis clients can connect using TLS-encrypted or plaintext redis protocols. Default is TLS-encrypted. ClientProtocol *Protocol // Clustering policy - default is OSSCluster. Specified at create time. ClusteringPolicy *ClusteringPolicy // Redis eviction policy - default is VolatileLRU EvictionPolicy *EvictionPolicy // Optional set of properties to configure geo replication for this database. GeoReplication *DatabasePropertiesGeoReplication // Optional set of redis modules to enable in this database - modules can only be added at creation time. Modules []*Module // Persistence settings Persistence *Persistence // TCP port of the database endpoint. Specified at create time. Defaults to an available port. Port *int32 // READ-ONLY; Current provisioning status of the database ProvisioningState *ProvisioningState // READ-ONLY; Current resource status of the database ResourceState *ResourceState }
DatabaseProperties - Properties of RedisEnterprise databases, as opposed to general resource properties like location, tags
func (DatabaseProperties) MarshalJSON ¶
func (d DatabaseProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type DatabaseProperties.
func (*DatabaseProperties) UnmarshalJSON ¶
func (d *DatabaseProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type DatabaseProperties.
type DatabasePropertiesGeoReplication ¶
type DatabasePropertiesGeoReplication struct { // Name for the group of linked database resources GroupNickname *string // List of database resources to link with this database LinkedDatabases []*LinkedDatabase }
DatabasePropertiesGeoReplication - Optional set of properties to configure geo replication for this database.
func (DatabasePropertiesGeoReplication) MarshalJSON ¶
func (d DatabasePropertiesGeoReplication) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type DatabasePropertiesGeoReplication.
func (*DatabasePropertiesGeoReplication) UnmarshalJSON ¶
func (d *DatabasePropertiesGeoReplication) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type DatabasePropertiesGeoReplication.
type DatabaseUpdate ¶
type DatabaseUpdate struct { // Properties of the database. Properties *DatabaseProperties }
DatabaseUpdate - A partial update to the RedisEnterprise database
func (DatabaseUpdate) MarshalJSON ¶
func (d DatabaseUpdate) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type DatabaseUpdate.
func (*DatabaseUpdate) UnmarshalJSON ¶
func (d *DatabaseUpdate) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type DatabaseUpdate.
type DatabasesClient ¶
type DatabasesClient struct {
// contains filtered or unexported fields
}
DatabasesClient contains the methods for the Databases group. Don't use this type directly, use NewDatabasesClient() instead.
func NewDatabasesClient ¶
func NewDatabasesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*DatabasesClient, error)
NewDatabasesClient creates a new instance of DatabasesClient 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 (*DatabasesClient) BeginCreate ¶
func (client *DatabasesClient) BeginCreate(ctx context.Context, resourceGroupName string, clusterName string, databaseName string, parameters Database, options *DatabasesClientBeginCreateOptions) (*runtime.Poller[DatabasesClientCreateResponse], error)
BeginCreate - Creates a database If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2023-11-01
- resourceGroupName - The name of the resource group. The name is case insensitive.
- clusterName - The name of the RedisEnterprise cluster.
- databaseName - The name of the database.
- parameters - Parameters supplied to the create or update database operation.
- options - DatabasesClientBeginCreateOptions contains the optional parameters for the DatabasesClient.BeginCreate method.
Example (RedisEnterpriseDatabasesCreate) ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/d4205894880b989ede35d62d97c8e901ed14fb5a/specification/redisenterprise/resource-manager/Microsoft.Cache/stable/2023-11-01/examples/RedisEnterpriseDatabasesCreate.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armredisenterprise.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewDatabasesClient().BeginCreate(ctx, "rg1", "cache1", "default", armredisenterprise.Database{ Properties: &armredisenterprise.DatabaseProperties{ ClientProtocol: to.Ptr(armredisenterprise.ProtocolEncrypted), ClusteringPolicy: to.Ptr(armredisenterprise.ClusteringPolicyEnterpriseCluster), EvictionPolicy: to.Ptr(armredisenterprise.EvictionPolicyAllKeysLRU), Modules: []*armredisenterprise.Module{ { Name: to.Ptr("RedisBloom"), Args: to.Ptr("ERROR_RATE 0.00 INITIAL_SIZE 400"), }, { Name: to.Ptr("RedisTimeSeries"), Args: to.Ptr("RETENTION_POLICY 20"), }, { Name: to.Ptr("RediSearch"), }}, Persistence: &armredisenterprise.Persistence{ AofEnabled: to.Ptr(true), AofFrequency: to.Ptr(armredisenterprise.AofFrequencyOneS), }, Port: to.Ptr[int32](10000), }, }, 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.Database = armredisenterprise.Database{ // Name: to.Ptr("cache1/default"), // Type: to.Ptr("Microsoft.Cache/redisEnterprise/databases"), // ID: to.Ptr("/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Cache/redisEnterprise/cache1/databases/default"), // Properties: &armredisenterprise.DatabaseProperties{ // ClientProtocol: to.Ptr(armredisenterprise.ProtocolEncrypted), // ClusteringPolicy: to.Ptr(armredisenterprise.ClusteringPolicyEnterpriseCluster), // EvictionPolicy: to.Ptr(armredisenterprise.EvictionPolicyAllKeysLRU), // Modules: []*armredisenterprise.Module{ // { // Name: to.Ptr("RedisBloom"), // Args: to.Ptr("ERROR_RATE 0.00 INITIAL_SIZE 400"), // Version: to.Ptr("1.0.0"), // }, // { // Name: to.Ptr("RedisTimeSeries"), // Args: to.Ptr("RETENTION_POLICY 20"), // Version: to.Ptr("1.0.0"), // }, // { // Name: to.Ptr("RediSearch"), // Args: to.Ptr(""), // Version: to.Ptr("1.0.0"), // }}, // Persistence: &armredisenterprise.Persistence{ // AofEnabled: to.Ptr(true), // AofFrequency: to.Ptr(armredisenterprise.AofFrequencyOneS), // }, // Port: to.Ptr[int32](10000), // ProvisioningState: to.Ptr(armredisenterprise.ProvisioningStateSucceeded), // ResourceState: to.Ptr(armredisenterprise.ResourceStateUpdating), // }, // }
Output:
Example (RedisEnterpriseDatabasesCreateWithActiveGeoReplication) ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/d4205894880b989ede35d62d97c8e901ed14fb5a/specification/redisenterprise/resource-manager/Microsoft.Cache/stable/2023-11-01/examples/RedisEnterpriseDatabasesCreateWithGeoReplication.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armredisenterprise.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewDatabasesClient().BeginCreate(ctx, "rg1", "cache1", "default", armredisenterprise.Database{ Properties: &armredisenterprise.DatabaseProperties{ ClientProtocol: to.Ptr(armredisenterprise.ProtocolEncrypted), ClusteringPolicy: to.Ptr(armredisenterprise.ClusteringPolicyEnterpriseCluster), EvictionPolicy: to.Ptr(armredisenterprise.EvictionPolicyNoEviction), GeoReplication: &armredisenterprise.DatabasePropertiesGeoReplication{ GroupNickname: to.Ptr("groupName"), LinkedDatabases: []*armredisenterprise.LinkedDatabase{ { ID: to.Ptr("/subscriptions/subid1/resourceGroups/rg1/providers/Microsoft.Cache/redisEnterprise/cache1/databases/default"), }, { ID: to.Ptr("/subscriptions/subid2/resourceGroups/rg2/providers/Microsoft.Cache/redisEnterprise/cache2/databases/default"), }}, }, Port: to.Ptr[int32](10000), }, }, 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.Database = armredisenterprise.Database{ // Name: to.Ptr("cache1/default"), // Type: to.Ptr("Microsoft.Cache/redisEnterprise/databases"), // ID: to.Ptr("/subscriptions/subid1/resourceGroups/rg1/providers/Microsoft.Cache/redisEnterprise/cache1/databases/default"), // Properties: &armredisenterprise.DatabaseProperties{ // ClientProtocol: to.Ptr(armredisenterprise.ProtocolEncrypted), // ClusteringPolicy: to.Ptr(armredisenterprise.ClusteringPolicyEnterpriseCluster), // EvictionPolicy: to.Ptr(armredisenterprise.EvictionPolicyNoEviction), // GeoReplication: &armredisenterprise.DatabasePropertiesGeoReplication{ // GroupNickname: to.Ptr("groupName"), // LinkedDatabases: []*armredisenterprise.LinkedDatabase{ // { // ID: to.Ptr("/subscriptions/subid1/resourceGroups/rg1/providers/Microsoft.Cache/redisEnterprise/cache1/databases/default"), // State: to.Ptr(armredisenterprise.LinkStateLinking), // }, // { // ID: to.Ptr("/subscriptions/subid2/resourceGroups/rg2/providers/Microsoft.Cache/redisEnterprise/cache2/databases/default"), // State: to.Ptr(armredisenterprise.LinkStateLinking), // }}, // }, // Port: to.Ptr[int32](10000), // ProvisioningState: to.Ptr(armredisenterprise.ProvisioningStateSucceeded), // ResourceState: to.Ptr(armredisenterprise.ResourceStateUpdating), // }, // }
Output:
func (*DatabasesClient) BeginDelete ¶
func (client *DatabasesClient) BeginDelete(ctx context.Context, resourceGroupName string, clusterName string, databaseName string, options *DatabasesClientBeginDeleteOptions) (*runtime.Poller[DatabasesClientDeleteResponse], error)
BeginDelete - Deletes a single database If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2023-11-01
- resourceGroupName - The name of the resource group. The name is case insensitive.
- clusterName - The name of the RedisEnterprise cluster.
- databaseName - The name of the database.
- options - DatabasesClientBeginDeleteOptions contains the optional parameters for the DatabasesClient.BeginDelete method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/d4205894880b989ede35d62d97c8e901ed14fb5a/specification/redisenterprise/resource-manager/Microsoft.Cache/stable/2023-11-01/examples/RedisEnterpriseDatabasesDelete.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armredisenterprise.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewDatabasesClient().BeginDelete(ctx, "rg1", "cache1", "db1", nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } _, err = poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %v", err) }
Output:
func (*DatabasesClient) BeginExport ¶
func (client *DatabasesClient) BeginExport(ctx context.Context, resourceGroupName string, clusterName string, databaseName string, parameters ExportClusterParameters, options *DatabasesClientBeginExportOptions) (*runtime.Poller[DatabasesClientExportResponse], error)
BeginExport - Exports a database file from target database. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2023-11-01
- resourceGroupName - The name of the resource group. The name is case insensitive.
- clusterName - The name of the RedisEnterprise cluster.
- databaseName - The name of the database.
- parameters - Storage information for exporting into the cluster
- options - DatabasesClientBeginExportOptions contains the optional parameters for the DatabasesClient.BeginExport method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/d4205894880b989ede35d62d97c8e901ed14fb5a/specification/redisenterprise/resource-manager/Microsoft.Cache/stable/2023-11-01/examples/RedisEnterpriseDatabasesExport.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armredisenterprise.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewDatabasesClient().BeginExport(ctx, "rg1", "cache1", "default", armredisenterprise.ExportClusterParameters{ SasURI: to.Ptr("https://contosostorage.blob.core.window.net/urlToBlobContainer?sasKeyParameters"), }, nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } _, err = poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %v", err) }
Output:
func (*DatabasesClient) BeginFlush ¶
func (client *DatabasesClient) BeginFlush(ctx context.Context, resourceGroupName string, clusterName string, databaseName string, parameters FlushParameters, options *DatabasesClientBeginFlushOptions) (*runtime.Poller[DatabasesClientFlushResponse], error)
BeginFlush - Flushes all the keys in this database and also from its linked databases. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2023-11-01
- resourceGroupName - The name of the resource group. The name is case insensitive.
- clusterName - The name of the RedisEnterprise cluster.
- databaseName - The name of the database.
- parameters - Information identifying the databases to be flushed
- options - DatabasesClientBeginFlushOptions contains the optional parameters for the DatabasesClient.BeginFlush method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/d4205894880b989ede35d62d97c8e901ed14fb5a/specification/redisenterprise/resource-manager/Microsoft.Cache/stable/2023-11-01/examples/RedisEnterpriseDatabasesFlush.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armredisenterprise.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewDatabasesClient().BeginFlush(ctx, "rg1", "cache1", "default", armredisenterprise.FlushParameters{ IDs: []*string{ to.Ptr("/subscriptions/subid2/resourceGroups/rg2/providers/Microsoft.Cache/redisEnterprise/cache2/databases/default")}, }, nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } _, err = poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %v", err) }
Output:
func (*DatabasesClient) BeginForceUnlink ¶
func (client *DatabasesClient) BeginForceUnlink(ctx context.Context, resourceGroupName string, clusterName string, databaseName string, parameters ForceUnlinkParameters, options *DatabasesClientBeginForceUnlinkOptions) (*runtime.Poller[DatabasesClientForceUnlinkResponse], error)
BeginForceUnlink - Forcibly removes the link to the specified database resource. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2023-11-01
- resourceGroupName - The name of the resource group. The name is case insensitive.
- clusterName - The name of the RedisEnterprise cluster.
- databaseName - The name of the database.
- parameters - Information identifying the database to be unlinked.
- options - DatabasesClientBeginForceUnlinkOptions contains the optional parameters for the DatabasesClient.BeginForceUnlink method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/d4205894880b989ede35d62d97c8e901ed14fb5a/specification/redisenterprise/resource-manager/Microsoft.Cache/stable/2023-11-01/examples/RedisEnterpriseDatabasesForceUnlink.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armredisenterprise.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewDatabasesClient().BeginForceUnlink(ctx, "rg1", "cache1", "default", armredisenterprise.ForceUnlinkParameters{ IDs: []*string{ to.Ptr("/subscriptions/subid2/resourceGroups/rg2/providers/Microsoft.Cache/redisEnterprise/cache2/databases/default")}, }, nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } _, err = poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %v", err) }
Output:
func (*DatabasesClient) BeginImport ¶
func (client *DatabasesClient) BeginImport(ctx context.Context, resourceGroupName string, clusterName string, databaseName string, parameters ImportClusterParameters, options *DatabasesClientBeginImportOptions) (*runtime.Poller[DatabasesClientImportResponse], error)
BeginImport - Imports database files to target database. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2023-11-01
- resourceGroupName - The name of the resource group. The name is case insensitive.
- clusterName - The name of the RedisEnterprise cluster.
- databaseName - The name of the database.
- parameters - Storage information for importing into the cluster
- options - DatabasesClientBeginImportOptions contains the optional parameters for the DatabasesClient.BeginImport method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/d4205894880b989ede35d62d97c8e901ed14fb5a/specification/redisenterprise/resource-manager/Microsoft.Cache/stable/2023-11-01/examples/RedisEnterpriseDatabasesImport.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armredisenterprise.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewDatabasesClient().BeginImport(ctx, "rg1", "cache1", "default", armredisenterprise.ImportClusterParameters{ SasUris: []*string{ to.Ptr("https://contosostorage.blob.core.window.net/urltoBlobFile1?sasKeyParameters"), to.Ptr("https://contosostorage.blob.core.window.net/urltoBlobFile2?sasKeyParameters")}, }, nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } _, err = poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %v", err) }
Output:
func (*DatabasesClient) BeginRegenerateKey ¶
func (client *DatabasesClient) BeginRegenerateKey(ctx context.Context, resourceGroupName string, clusterName string, databaseName string, parameters RegenerateKeyParameters, options *DatabasesClientBeginRegenerateKeyOptions) (*runtime.Poller[DatabasesClientRegenerateKeyResponse], error)
BeginRegenerateKey - Regenerates the RedisEnterprise database's access keys. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2023-11-01
- resourceGroupName - The name of the resource group. The name is case insensitive.
- clusterName - The name of the RedisEnterprise cluster.
- databaseName - The name of the database.
- parameters - Specifies which key to regenerate.
- options - DatabasesClientBeginRegenerateKeyOptions contains the optional parameters for the DatabasesClient.BeginRegenerateKey method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/d4205894880b989ede35d62d97c8e901ed14fb5a/specification/redisenterprise/resource-manager/Microsoft.Cache/stable/2023-11-01/examples/RedisEnterpriseDatabasesRegenerateKey.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armredisenterprise.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewDatabasesClient().BeginRegenerateKey(ctx, "rg1", "cache1", "default", armredisenterprise.RegenerateKeyParameters{ KeyType: to.Ptr(armredisenterprise.AccessKeyTypePrimary), }, 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.AccessKeys = armredisenterprise.AccessKeys{ // PrimaryKey: to.Ptr("<primaryKey>"), // SecondaryKey: to.Ptr("<secondaryKey>"), // }
Output:
func (*DatabasesClient) BeginUpdate ¶
func (client *DatabasesClient) BeginUpdate(ctx context.Context, resourceGroupName string, clusterName string, databaseName string, parameters DatabaseUpdate, options *DatabasesClientBeginUpdateOptions) (*runtime.Poller[DatabasesClientUpdateResponse], error)
BeginUpdate - Updates a database If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2023-11-01
- resourceGroupName - The name of the resource group. The name is case insensitive.
- clusterName - The name of the RedisEnterprise cluster.
- databaseName - The name of the database.
- parameters - Parameters supplied to the create or update database operation.
- options - DatabasesClientBeginUpdateOptions contains the optional parameters for the DatabasesClient.BeginUpdate method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/d4205894880b989ede35d62d97c8e901ed14fb5a/specification/redisenterprise/resource-manager/Microsoft.Cache/stable/2023-11-01/examples/RedisEnterpriseDatabasesUpdate.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armredisenterprise.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewDatabasesClient().BeginUpdate(ctx, "rg1", "cache1", "default", armredisenterprise.DatabaseUpdate{ Properties: &armredisenterprise.DatabaseProperties{ ClientProtocol: to.Ptr(armredisenterprise.ProtocolEncrypted), EvictionPolicy: to.Ptr(armredisenterprise.EvictionPolicyAllKeysLRU), Persistence: &armredisenterprise.Persistence{ RdbEnabled: to.Ptr(true), RdbFrequency: to.Ptr(armredisenterprise.RdbFrequencyTwelveH), }, }, }, 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.Database = armredisenterprise.Database{ // Name: to.Ptr("cache1/default"), // Type: to.Ptr("Microsoft.Cache/redisEnterprise/databases"), // ID: to.Ptr("/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Cache/redisEnterprise/cache1/databases/default"), // Properties: &armredisenterprise.DatabaseProperties{ // ClientProtocol: to.Ptr(armredisenterprise.ProtocolEncrypted), // ClusteringPolicy: to.Ptr(armredisenterprise.ClusteringPolicyOSSCluster), // EvictionPolicy: to.Ptr(armredisenterprise.EvictionPolicyAllKeysLRU), // Modules: []*armredisenterprise.Module{ // { // Name: to.Ptr("RediSearch"), // Args: to.Ptr(""), // Version: to.Ptr("1.0.0"), // }}, // Persistence: &armredisenterprise.Persistence{ // RdbEnabled: to.Ptr(true), // RdbFrequency: to.Ptr(armredisenterprise.RdbFrequencyTwelveH), // }, // Port: to.Ptr[int32](10000), // ProvisioningState: to.Ptr(armredisenterprise.ProvisioningStateSucceeded), // ResourceState: to.Ptr(armredisenterprise.ResourceStateUpdating), // }, // }
Output:
func (*DatabasesClient) Get ¶
func (client *DatabasesClient) Get(ctx context.Context, resourceGroupName string, clusterName string, databaseName string, options *DatabasesClientGetOptions) (DatabasesClientGetResponse, error)
Get - Gets information about a database in a RedisEnterprise cluster. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2023-11-01
- resourceGroupName - The name of the resource group. The name is case insensitive.
- clusterName - The name of the RedisEnterprise cluster.
- databaseName - The name of the database.
- options - DatabasesClientGetOptions contains the optional parameters for the DatabasesClient.Get method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/d4205894880b989ede35d62d97c8e901ed14fb5a/specification/redisenterprise/resource-manager/Microsoft.Cache/stable/2023-11-01/examples/RedisEnterpriseDatabasesGet.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armredisenterprise.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewDatabasesClient().Get(ctx, "rg1", "cache1", "default", 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.Database = armredisenterprise.Database{ // Name: to.Ptr("cache1/default"), // Type: to.Ptr("Microsoft.Cache/redisEnterprise/databases"), // ID: to.Ptr("/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Cache/redisEnterprise/cache1/databases/default"), // Properties: &armredisenterprise.DatabaseProperties{ // ClientProtocol: to.Ptr(armredisenterprise.ProtocolEncrypted), // ClusteringPolicy: to.Ptr(armredisenterprise.ClusteringPolicyOSSCluster), // EvictionPolicy: to.Ptr(armredisenterprise.EvictionPolicyAllKeysLRU), // Modules: []*armredisenterprise.Module{ // { // Name: to.Ptr("RediSearch"), // Args: to.Ptr(""), // Version: to.Ptr("1.0.0"), // }}, // Persistence: &armredisenterprise.Persistence{ // RdbEnabled: to.Ptr(true), // RdbFrequency: to.Ptr(armredisenterprise.RdbFrequencyTwelveH), // }, // Port: to.Ptr[int32](10000), // ProvisioningState: to.Ptr(armredisenterprise.ProvisioningStateSucceeded), // ResourceState: to.Ptr(armredisenterprise.ResourceStateRunning), // }, // }
Output:
func (*DatabasesClient) ListKeys ¶
func (client *DatabasesClient) ListKeys(ctx context.Context, resourceGroupName string, clusterName string, databaseName string, options *DatabasesClientListKeysOptions) (DatabasesClientListKeysResponse, error)
ListKeys - Retrieves the access keys for the RedisEnterprise database. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2023-11-01
- resourceGroupName - The name of the resource group. The name is case insensitive.
- clusterName - The name of the RedisEnterprise cluster.
- databaseName - The name of the database.
- options - DatabasesClientListKeysOptions contains the optional parameters for the DatabasesClient.ListKeys method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/d4205894880b989ede35d62d97c8e901ed14fb5a/specification/redisenterprise/resource-manager/Microsoft.Cache/stable/2023-11-01/examples/RedisEnterpriseDatabasesListKeys.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armredisenterprise.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewDatabasesClient().ListKeys(ctx, "rg1", "cache1", "default", 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.AccessKeys = armredisenterprise.AccessKeys{ // PrimaryKey: to.Ptr("<primaryKey>"), // SecondaryKey: to.Ptr("<secondaryKey>"), // }
Output:
func (*DatabasesClient) NewListByClusterPager ¶
func (client *DatabasesClient) NewListByClusterPager(resourceGroupName string, clusterName string, options *DatabasesClientListByClusterOptions) *runtime.Pager[DatabasesClientListByClusterResponse]
NewListByClusterPager - Gets all databases in the specified RedisEnterprise cluster.
Generated from API version 2023-11-01
- resourceGroupName - The name of the resource group. The name is case insensitive.
- clusterName - The name of the RedisEnterprise cluster.
- options - DatabasesClientListByClusterOptions contains the optional parameters for the DatabasesClient.NewListByClusterPager method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/d4205894880b989ede35d62d97c8e901ed14fb5a/specification/redisenterprise/resource-manager/Microsoft.Cache/stable/2023-11-01/examples/RedisEnterpriseDatabasesListByCluster.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armredisenterprise.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } pager := clientFactory.NewDatabasesClient().NewListByClusterPager("rg1", "cache1", 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.DatabaseList = armredisenterprise.DatabaseList{ // Value: []*armredisenterprise.Database{ // { // Name: to.Ptr("cache1/default"), // Type: to.Ptr("Microsoft.Cache/redisEnterprise/databases"), // ID: to.Ptr("/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Cache/redisEnterprise/cache1/databases/default"), // Properties: &armredisenterprise.DatabaseProperties{ // ClientProtocol: to.Ptr(armredisenterprise.ProtocolEncrypted), // ClusteringPolicy: to.Ptr(armredisenterprise.ClusteringPolicyOSSCluster), // EvictionPolicy: to.Ptr(armredisenterprise.EvictionPolicyAllKeysLRU), // Modules: []*armredisenterprise.Module{ // { // Name: to.Ptr("RediSearch"), // Args: to.Ptr(""), // Version: to.Ptr("1.0.0"), // }}, // Persistence: &armredisenterprise.Persistence{ // RdbEnabled: to.Ptr(true), // RdbFrequency: to.Ptr(armredisenterprise.RdbFrequencyTwelveH), // }, // Port: to.Ptr[int32](10000), // ProvisioningState: to.Ptr(armredisenterprise.ProvisioningStateSucceeded), // ResourceState: to.Ptr(armredisenterprise.ResourceStateRunning), // }, // }}, // } }
Output:
type DatabasesClientBeginCreateOptions ¶
type DatabasesClientBeginCreateOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
DatabasesClientBeginCreateOptions contains the optional parameters for the DatabasesClient.BeginCreate method.
type DatabasesClientBeginDeleteOptions ¶
type DatabasesClientBeginDeleteOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
DatabasesClientBeginDeleteOptions contains the optional parameters for the DatabasesClient.BeginDelete method.
type DatabasesClientBeginExportOptions ¶
type DatabasesClientBeginExportOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
DatabasesClientBeginExportOptions contains the optional parameters for the DatabasesClient.BeginExport method.
type DatabasesClientBeginFlushOptions ¶
type DatabasesClientBeginFlushOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
DatabasesClientBeginFlushOptions contains the optional parameters for the DatabasesClient.BeginFlush method.
type DatabasesClientBeginForceUnlinkOptions ¶
type DatabasesClientBeginForceUnlinkOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
DatabasesClientBeginForceUnlinkOptions contains the optional parameters for the DatabasesClient.BeginForceUnlink method.
type DatabasesClientBeginImportOptions ¶
type DatabasesClientBeginImportOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
DatabasesClientBeginImportOptions contains the optional parameters for the DatabasesClient.BeginImport method.
type DatabasesClientBeginRegenerateKeyOptions ¶
type DatabasesClientBeginRegenerateKeyOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
DatabasesClientBeginRegenerateKeyOptions contains the optional parameters for the DatabasesClient.BeginRegenerateKey method.
type DatabasesClientBeginUpdateOptions ¶
type DatabasesClientBeginUpdateOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
DatabasesClientBeginUpdateOptions contains the optional parameters for the DatabasesClient.BeginUpdate method.
type DatabasesClientCreateResponse ¶
type DatabasesClientCreateResponse struct { // Describes a database on the RedisEnterprise cluster Database }
DatabasesClientCreateResponse contains the response from method DatabasesClient.BeginCreate.
type DatabasesClientDeleteResponse ¶
type DatabasesClientDeleteResponse struct { }
DatabasesClientDeleteResponse contains the response from method DatabasesClient.BeginDelete.
type DatabasesClientExportResponse ¶
type DatabasesClientExportResponse struct { }
DatabasesClientExportResponse contains the response from method DatabasesClient.BeginExport.
type DatabasesClientFlushResponse ¶
type DatabasesClientFlushResponse struct { }
DatabasesClientFlushResponse contains the response from method DatabasesClient.BeginFlush.
type DatabasesClientForceUnlinkResponse ¶
type DatabasesClientForceUnlinkResponse struct { }
DatabasesClientForceUnlinkResponse contains the response from method DatabasesClient.BeginForceUnlink.
type DatabasesClientGetOptions ¶
type DatabasesClientGetOptions struct { }
DatabasesClientGetOptions contains the optional parameters for the DatabasesClient.Get method.
type DatabasesClientGetResponse ¶
type DatabasesClientGetResponse struct { // Describes a database on the RedisEnterprise cluster Database }
DatabasesClientGetResponse contains the response from method DatabasesClient.Get.
type DatabasesClientImportResponse ¶
type DatabasesClientImportResponse struct { }
DatabasesClientImportResponse contains the response from method DatabasesClient.BeginImport.
type DatabasesClientListByClusterOptions ¶
type DatabasesClientListByClusterOptions struct { }
DatabasesClientListByClusterOptions contains the optional parameters for the DatabasesClient.NewListByClusterPager method.
type DatabasesClientListByClusterResponse ¶
type DatabasesClientListByClusterResponse struct { // The response of a list-all operation. DatabaseList }
DatabasesClientListByClusterResponse contains the response from method DatabasesClient.NewListByClusterPager.
type DatabasesClientListKeysOptions ¶
type DatabasesClientListKeysOptions struct { }
DatabasesClientListKeysOptions contains the optional parameters for the DatabasesClient.ListKeys method.
type DatabasesClientListKeysResponse ¶
type DatabasesClientListKeysResponse struct { // The secret access keys used for authenticating connections to redis AccessKeys }
DatabasesClientListKeysResponse contains the response from method DatabasesClient.ListKeys.
type DatabasesClientRegenerateKeyResponse ¶
type DatabasesClientRegenerateKeyResponse struct { // The secret access keys used for authenticating connections to redis AccessKeys }
DatabasesClientRegenerateKeyResponse contains the response from method DatabasesClient.BeginRegenerateKey.
type DatabasesClientUpdateResponse ¶
type DatabasesClientUpdateResponse struct { // Describes a database on the RedisEnterprise cluster Database }
DatabasesClientUpdateResponse contains the response from method DatabasesClient.BeginUpdate.
type ErrorAdditionalInfo ¶
type ErrorAdditionalInfo struct { // READ-ONLY; The additional info. Info any // READ-ONLY; The additional info type. Type *string }
ErrorAdditionalInfo - The resource management error additional info.
func (ErrorAdditionalInfo) MarshalJSON ¶
func (e ErrorAdditionalInfo) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ErrorAdditionalInfo.
func (*ErrorAdditionalInfo) UnmarshalJSON ¶
func (e *ErrorAdditionalInfo) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ErrorAdditionalInfo.
type ErrorDetail ¶
type ErrorDetail struct { // READ-ONLY; The error additional info. AdditionalInfo []*ErrorAdditionalInfo // READ-ONLY; The error code. Code *string // READ-ONLY; The error details. Details []*ErrorDetail // READ-ONLY; The error message. Message *string // READ-ONLY; The error target. Target *string }
ErrorDetail - The error detail.
func (ErrorDetail) MarshalJSON ¶
func (e ErrorDetail) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ErrorDetail.
func (*ErrorDetail) UnmarshalJSON ¶
func (e *ErrorDetail) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ErrorDetail.
type ErrorResponse ¶
type ErrorResponse struct { // The error object. Error *ErrorDetail }
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 ¶
func (e ErrorResponse) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ErrorResponse.
func (*ErrorResponse) UnmarshalJSON ¶
func (e *ErrorResponse) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ErrorResponse.
type EvictionPolicy ¶
type EvictionPolicy string
EvictionPolicy - Redis eviction policy - default is VolatileLRU
const ( EvictionPolicyAllKeysLFU EvictionPolicy = "AllKeysLFU" EvictionPolicyAllKeysLRU EvictionPolicy = "AllKeysLRU" EvictionPolicyAllKeysRandom EvictionPolicy = "AllKeysRandom" EvictionPolicyNoEviction EvictionPolicy = "NoEviction" EvictionPolicyVolatileLFU EvictionPolicy = "VolatileLFU" EvictionPolicyVolatileLRU EvictionPolicy = "VolatileLRU" EvictionPolicyVolatileRandom EvictionPolicy = "VolatileRandom" EvictionPolicyVolatileTTL EvictionPolicy = "VolatileTTL" )
func PossibleEvictionPolicyValues ¶
func PossibleEvictionPolicyValues() []EvictionPolicy
PossibleEvictionPolicyValues returns the possible values for the EvictionPolicy const type.
type ExportClusterParameters ¶
type ExportClusterParameters struct { // REQUIRED; SAS URI for the target directory to export to SasURI *string }
ExportClusterParameters - Parameters for a Redis Enterprise export operation.
func (ExportClusterParameters) MarshalJSON ¶
func (e ExportClusterParameters) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ExportClusterParameters.
func (*ExportClusterParameters) UnmarshalJSON ¶
func (e *ExportClusterParameters) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ExportClusterParameters.
type FlushParameters ¶
type FlushParameters struct { // The identifiers of all the other database resources in the georeplication group to be flushed. IDs []*string }
FlushParameters - Parameters for a Redis Enterprise active geo-replication flush operation
func (FlushParameters) MarshalJSON ¶
func (f FlushParameters) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type FlushParameters.
func (*FlushParameters) UnmarshalJSON ¶
func (f *FlushParameters) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type FlushParameters.
type ForceUnlinkParameters ¶
type ForceUnlinkParameters struct { // REQUIRED; The resource IDs of the database resources to be unlinked. IDs []*string }
ForceUnlinkParameters - Parameters for a Redis Enterprise Active Geo Replication Force Unlink operation.
func (ForceUnlinkParameters) MarshalJSON ¶
func (f ForceUnlinkParameters) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ForceUnlinkParameters.
func (*ForceUnlinkParameters) UnmarshalJSON ¶
func (f *ForceUnlinkParameters) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ForceUnlinkParameters.
type ImportClusterParameters ¶
type ImportClusterParameters struct { // REQUIRED; SAS URIs for the target blobs to import from SasUris []*string }
ImportClusterParameters - Parameters for a Redis Enterprise import operation.
func (ImportClusterParameters) MarshalJSON ¶
func (i ImportClusterParameters) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ImportClusterParameters.
func (*ImportClusterParameters) UnmarshalJSON ¶
func (i *ImportClusterParameters) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ImportClusterParameters.
type LinkState ¶
type LinkState string
LinkState - State of the link between the database resources.
func PossibleLinkStateValues ¶
func PossibleLinkStateValues() []LinkState
PossibleLinkStateValues returns the possible values for the LinkState const type.
type LinkedDatabase ¶
type LinkedDatabase struct { // Resource ID of a database resource to link with this database. ID *string // READ-ONLY; State of the link between the database resources. State *LinkState }
LinkedDatabase - Specifies details of a linked database resource.
func (LinkedDatabase) MarshalJSON ¶
func (l LinkedDatabase) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type LinkedDatabase.
func (*LinkedDatabase) UnmarshalJSON ¶
func (l *LinkedDatabase) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type LinkedDatabase.
type ManagedServiceIdentity ¶
type ManagedServiceIdentity struct { // REQUIRED; Type of managed service identity (where both SystemAssigned and UserAssigned types are allowed). Type *ManagedServiceIdentityType // The set of user assigned identities associated with the resource. The userAssignedIdentities dictionary keys will be ARM // resource ids in the form: // '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}. // The dictionary values can be empty objects ({}) in // requests. UserAssignedIdentities map[string]*UserAssignedIdentity // READ-ONLY; The service principal ID of the system assigned identity. This property will only be provided for a system assigned // identity. PrincipalID *string // READ-ONLY; The tenant ID of the system assigned identity. This property will only be provided for a system assigned identity. TenantID *string }
ManagedServiceIdentity - Managed service identity (system assigned and/or user assigned identities)
func (ManagedServiceIdentity) MarshalJSON ¶
func (m ManagedServiceIdentity) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ManagedServiceIdentity.
func (*ManagedServiceIdentity) UnmarshalJSON ¶
func (m *ManagedServiceIdentity) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ManagedServiceIdentity.
type ManagedServiceIdentityType ¶
type ManagedServiceIdentityType string
ManagedServiceIdentityType - Type of managed service identity (where both SystemAssigned and UserAssigned types are allowed).
const ( ManagedServiceIdentityTypeNone ManagedServiceIdentityType = "None" ManagedServiceIdentityTypeSystemAssigned ManagedServiceIdentityType = "SystemAssigned" ManagedServiceIdentityTypeSystemAssignedUserAssigned ManagedServiceIdentityType = "SystemAssigned, UserAssigned" ManagedServiceIdentityTypeUserAssigned ManagedServiceIdentityType = "UserAssigned" )
func PossibleManagedServiceIdentityTypeValues ¶
func PossibleManagedServiceIdentityTypeValues() []ManagedServiceIdentityType
PossibleManagedServiceIdentityTypeValues returns the possible values for the ManagedServiceIdentityType const type.
type Module ¶
type Module struct { // REQUIRED; The name of the module, e.g. 'RedisBloom', 'RediSearch', 'RedisTimeSeries' Name *string // Configuration options for the module, e.g. 'ERRORRATE 0.01 INITIALSIZE 400'. Args *string // READ-ONLY; The version of the module, e.g. '1.0'. Version *string }
Module - Specifies configuration of a redis module
func (Module) MarshalJSON ¶
MarshalJSON implements the json.Marshaller interface for type Module.
func (*Module) UnmarshalJSON ¶
UnmarshalJSON implements the json.Unmarshaller interface for type Module.
type Operation ¶
type Operation struct { // Localized display information for this particular operation. Display *OperationDisplay // READ-ONLY; Enum. Indicates the action type. "Internal" refers to actions that are for internal only APIs. ActionType *ActionType // 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 // 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 // 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 }
Operation - Details of a REST API operation, returned from the Resource Provider Operations API
func (Operation) MarshalJSON ¶
MarshalJSON implements the json.Marshaller interface for type Operation.
func (*Operation) UnmarshalJSON ¶
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 // 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 // READ-ONLY; The localized friendly form of the resource provider name, e.g. "Microsoft Monitoring Insights" or "Microsoft // Compute". Provider *string // READ-ONLY; The localized friendly name of the resource type related to this operation. E.g. "Virtual Machines" or "Job // Schedule Collections". Resource *string }
OperationDisplay - Localized display information for this particular operation.
func (OperationDisplay) MarshalJSON ¶
func (o OperationDisplay) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type OperationDisplay.
func (*OperationDisplay) UnmarshalJSON ¶
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 // READ-ONLY; List of operations supported by the resource provider Value []*Operation }
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 ¶
func (o OperationListResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type OperationListResult.
func (*OperationListResult) UnmarshalJSON ¶
func (o *OperationListResult) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type OperationListResult.
type OperationStatus ¶
type OperationStatus struct { // The end time of the operation. EndTime *string // Error response describing why the operation failed. Error *ErrorResponse // The operation's unique id. ID *string // The operation's name. Name *string // The start time of the operation. StartTime *string // The current status of the operation. Status *string }
OperationStatus - The status of a long-running operation.
func (OperationStatus) MarshalJSON ¶
func (o OperationStatus) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type OperationStatus.
func (*OperationStatus) UnmarshalJSON ¶
func (o *OperationStatus) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type OperationStatus.
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 ¶
func (client *OperationsClient) NewListPager(options *OperationsClientListOptions) *runtime.Pager[OperationsClientListResponse]
NewListPager - Lists all of the available REST API operations of the Microsoft.Cache provider.
Generated from API version 2023-11-01
- 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/d4205894880b989ede35d62d97c8e901ed14fb5a/specification/redisenterprise/resource-manager/Microsoft.Cache/stable/2023-11-01/examples/OperationsList.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armredisenterprise.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } pager := clientFactory.NewOperationsClient().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 = armredisenterprise.OperationListResult{ // Value: []*armredisenterprise.Operation{ // { // Name: to.Ptr("Microsoft.Cache/redisEnterprise/read"), // Display: &armredisenterprise.OperationDisplay{ // Description: to.Ptr("View the Redis Enterprise cache's settings and configuration in the management portal"), // Operation: to.Ptr("Manage Redis Enterprise cache (read)"), // Provider: to.Ptr("Microsoft Cache"), // Resource: to.Ptr("Redis Enterprise cache"), // }, // }, // { // Name: to.Ptr("Microsoft.Cache/redisEnterprise/write"), // Display: &armredisenterprise.OperationDisplay{ // Description: to.Ptr("Modify the Redis Enterprise cache's settings and configuration in the management portal"), // Operation: to.Ptr("Manage Redis Enterprise cache (write)"), // Provider: to.Ptr("Microsoft Cache"), // Resource: to.Ptr("Redis Enterprise cache"), // }, // }}, // } }
Output:
type OperationsClientListOptions ¶
type OperationsClientListOptions struct { }
OperationsClientListOptions contains the optional parameters for the OperationsClient.NewListPager method.
type OperationsClientListResponse ¶
type OperationsClientListResponse struct { // A list of REST API operations supported by an Azure Resource Provider. It contains an URL link to get the next set of results. OperationListResult }
OperationsClientListResponse contains the response from method OperationsClient.NewListPager.
type OperationsStatusClient ¶
type OperationsStatusClient struct {
// contains filtered or unexported fields
}
OperationsStatusClient contains the methods for the OperationsStatus group. Don't use this type directly, use NewOperationsStatusClient() instead.
func NewOperationsStatusClient ¶
func NewOperationsStatusClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*OperationsStatusClient, error)
NewOperationsStatusClient creates a new instance of OperationsStatusClient 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 (*OperationsStatusClient) Get ¶
func (client *OperationsStatusClient) Get(ctx context.Context, location string, operationID string, options *OperationsStatusClientGetOptions) (OperationsStatusClientGetResponse, error)
Get - Gets the status of operation. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2023-11-01
- location - The name of Azure region.
- operationID - The ID of an ongoing async operation.
- options - OperationsStatusClientGetOptions contains the optional parameters for the OperationsStatusClient.Get method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/d4205894880b989ede35d62d97c8e901ed14fb5a/specification/redisenterprise/resource-manager/Microsoft.Cache/stable/2023-11-01/examples/OperationsStatusGet.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armredisenterprise.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewOperationsStatusClient().Get(ctx, "West US", "testoperationid", 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.OperationStatus = armredisenterprise.OperationStatus{ // Name: to.Ptr("testoperationid"), // EndTime: to.Ptr("2017-01-01T16:13:13.933Z"), // ID: to.Ptr("/subscriptions/subid/providers/Microsoft.Cache/locations/westus/operationsStatus/testoperationid"), // StartTime: to.Ptr("2017-01-01T13:13:13.933Z"), // Status: to.Ptr("Succeeded"), // }
Output:
type OperationsStatusClientGetOptions ¶
type OperationsStatusClientGetOptions struct { }
OperationsStatusClientGetOptions contains the optional parameters for the OperationsStatusClient.Get method.
type OperationsStatusClientGetResponse ¶
type OperationsStatusClientGetResponse struct { // The status of a long-running operation. OperationStatus }
OperationsStatusClientGetResponse contains the response from method OperationsStatusClient.Get.
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"
func PossibleOriginValues ¶
func PossibleOriginValues() []Origin
PossibleOriginValues returns the possible values for the Origin const type.
type Persistence ¶
type Persistence struct { // Sets whether AOF is enabled. AofEnabled *bool // Sets the frequency at which data is written to disk. AofFrequency *AofFrequency // Sets whether RDB is enabled. RdbEnabled *bool // Sets the frequency at which a snapshot of the database is created. RdbFrequency *RdbFrequency }
Persistence-related configuration for the RedisEnterprise database
func (Persistence) MarshalJSON ¶
func (p Persistence) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type Persistence.
func (*Persistence) UnmarshalJSON ¶
func (p *Persistence) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type Persistence.
type PrivateEndpoint ¶
type PrivateEndpoint struct { // READ-ONLY; The ARM identifier for Private Endpoint ID *string }
PrivateEndpoint - The Private Endpoint resource.
func (PrivateEndpoint) MarshalJSON ¶
func (p PrivateEndpoint) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type PrivateEndpoint.
func (*PrivateEndpoint) UnmarshalJSON ¶
func (p *PrivateEndpoint) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type PrivateEndpoint.
type PrivateEndpointConnection ¶
type PrivateEndpointConnection struct { // Resource properties. Properties *PrivateEndpointConnectionProperties // READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string // READ-ONLY; The name of the resource Name *string // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string }
PrivateEndpointConnection - The Private Endpoint Connection resource.
func (PrivateEndpointConnection) MarshalJSON ¶
func (p PrivateEndpointConnection) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type PrivateEndpointConnection.
func (*PrivateEndpointConnection) UnmarshalJSON ¶
func (p *PrivateEndpointConnection) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type PrivateEndpointConnection.
type PrivateEndpointConnectionListResult ¶
type PrivateEndpointConnectionListResult struct { // Array of private endpoint connections Value []*PrivateEndpointConnection }
PrivateEndpointConnectionListResult - List of private endpoint connection associated with the specified storage account
func (PrivateEndpointConnectionListResult) MarshalJSON ¶
func (p PrivateEndpointConnectionListResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type PrivateEndpointConnectionListResult.
func (*PrivateEndpointConnectionListResult) UnmarshalJSON ¶
func (p *PrivateEndpointConnectionListResult) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type PrivateEndpointConnectionListResult.
type PrivateEndpointConnectionProperties ¶
type PrivateEndpointConnectionProperties struct { // REQUIRED; A collection of information about the state of the connection between service consumer and provider. PrivateLinkServiceConnectionState *PrivateLinkServiceConnectionState // The resource of private end point. PrivateEndpoint *PrivateEndpoint // READ-ONLY; The provisioning state of the private endpoint connection resource. ProvisioningState *PrivateEndpointConnectionProvisioningState }
PrivateEndpointConnectionProperties - Properties of the PrivateEndpointConnectProperties.
func (PrivateEndpointConnectionProperties) MarshalJSON ¶
func (p PrivateEndpointConnectionProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type PrivateEndpointConnectionProperties.
func (*PrivateEndpointConnectionProperties) UnmarshalJSON ¶
func (p *PrivateEndpointConnectionProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type PrivateEndpointConnectionProperties.
type PrivateEndpointConnectionProvisioningState ¶
type PrivateEndpointConnectionProvisioningState string
PrivateEndpointConnectionProvisioningState - The current provisioning state.
const ( PrivateEndpointConnectionProvisioningStateCreating PrivateEndpointConnectionProvisioningState = "Creating" PrivateEndpointConnectionProvisioningStateDeleting PrivateEndpointConnectionProvisioningState = "Deleting" PrivateEndpointConnectionProvisioningStateFailed PrivateEndpointConnectionProvisioningState = "Failed" PrivateEndpointConnectionProvisioningStateSucceeded PrivateEndpointConnectionProvisioningState = "Succeeded" )
func PossiblePrivateEndpointConnectionProvisioningStateValues ¶
func PossiblePrivateEndpointConnectionProvisioningStateValues() []PrivateEndpointConnectionProvisioningState
PossiblePrivateEndpointConnectionProvisioningStateValues returns the possible values for the PrivateEndpointConnectionProvisioningState const type.
type PrivateEndpointConnectionsClient ¶
type PrivateEndpointConnectionsClient struct {
// contains filtered or unexported fields
}
PrivateEndpointConnectionsClient contains the methods for the PrivateEndpointConnections group. Don't use this type directly, use NewPrivateEndpointConnectionsClient() instead.
func NewPrivateEndpointConnectionsClient ¶
func NewPrivateEndpointConnectionsClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*PrivateEndpointConnectionsClient, error)
NewPrivateEndpointConnectionsClient creates a new instance of PrivateEndpointConnectionsClient 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 (*PrivateEndpointConnectionsClient) BeginDelete ¶
func (client *PrivateEndpointConnectionsClient) BeginDelete(ctx context.Context, resourceGroupName string, clusterName string, privateEndpointConnectionName string, options *PrivateEndpointConnectionsClientBeginDeleteOptions) (*runtime.Poller[PrivateEndpointConnectionsClientDeleteResponse], error)
BeginDelete - Deletes the specified private endpoint connection associated with the RedisEnterprise cluster. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2023-11-01
- resourceGroupName - The name of the resource group. The name is case insensitive.
- clusterName - The name of the RedisEnterprise cluster.
- privateEndpointConnectionName - The name of the private endpoint connection associated with the Azure resource
- options - PrivateEndpointConnectionsClientBeginDeleteOptions contains the optional parameters for the PrivateEndpointConnectionsClient.BeginDelete method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/d4205894880b989ede35d62d97c8e901ed14fb5a/specification/redisenterprise/resource-manager/Microsoft.Cache/stable/2023-11-01/examples/RedisEnterpriseDeletePrivateEndpointConnection.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armredisenterprise.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewPrivateEndpointConnectionsClient().BeginDelete(ctx, "rg1", "cache1", "pectest01", nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } _, err = poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %v", err) }
Output:
func (*PrivateEndpointConnectionsClient) BeginPut ¶
func (client *PrivateEndpointConnectionsClient) BeginPut(ctx context.Context, resourceGroupName string, clusterName string, privateEndpointConnectionName string, properties PrivateEndpointConnection, options *PrivateEndpointConnectionsClientBeginPutOptions) (*runtime.Poller[PrivateEndpointConnectionsClientPutResponse], error)
BeginPut - Updates the state of the specified private endpoint connection associated with the RedisEnterprise cluster. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2023-11-01
- resourceGroupName - The name of the resource group. The name is case insensitive.
- clusterName - The name of the RedisEnterprise cluster.
- privateEndpointConnectionName - The name of the private endpoint connection associated with the Azure resource
- properties - The private endpoint connection properties.
- options - PrivateEndpointConnectionsClientBeginPutOptions contains the optional parameters for the PrivateEndpointConnectionsClient.BeginPut method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/d4205894880b989ede35d62d97c8e901ed14fb5a/specification/redisenterprise/resource-manager/Microsoft.Cache/stable/2023-11-01/examples/RedisEnterprisePutPrivateEndpointConnection.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armredisenterprise.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewPrivateEndpointConnectionsClient().BeginPut(ctx, "rg1", "cache1", "pectest01", armredisenterprise.PrivateEndpointConnection{ Properties: &armredisenterprise.PrivateEndpointConnectionProperties{ PrivateLinkServiceConnectionState: &armredisenterprise.PrivateLinkServiceConnectionState{ Description: to.Ptr("Auto-Approved"), Status: to.Ptr(armredisenterprise.PrivateEndpointServiceConnectionStatusApproved), }, }, }, nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } _, err = poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %v", err) }
Output:
func (*PrivateEndpointConnectionsClient) Get ¶
func (client *PrivateEndpointConnectionsClient) Get(ctx context.Context, resourceGroupName string, clusterName string, privateEndpointConnectionName string, options *PrivateEndpointConnectionsClientGetOptions) (PrivateEndpointConnectionsClientGetResponse, error)
Get - Gets the specified private endpoint connection associated with the RedisEnterprise cluster. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2023-11-01
- resourceGroupName - The name of the resource group. The name is case insensitive.
- clusterName - The name of the RedisEnterprise cluster.
- privateEndpointConnectionName - The name of the private endpoint connection associated with the Azure resource
- options - PrivateEndpointConnectionsClientGetOptions contains the optional parameters for the PrivateEndpointConnectionsClient.Get method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/d4205894880b989ede35d62d97c8e901ed14fb5a/specification/redisenterprise/resource-manager/Microsoft.Cache/stable/2023-11-01/examples/RedisEnterpriseGetPrivateEndpointConnection.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armredisenterprise.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewPrivateEndpointConnectionsClient().Get(ctx, "rg1", "cache1", "pectest01", 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.PrivateEndpointConnection = armredisenterprise.PrivateEndpointConnection{ // Name: to.Ptr("pectest01"), // Type: to.Ptr("Microsoft.Cache/redisEnterprise/privateEndpointConnections"), // ID: to.Ptr("/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Cache/redisEnterprise/cache1/privateEndpointConnections/pectest01"), // Properties: &armredisenterprise.PrivateEndpointConnectionProperties{ // PrivateEndpoint: &armredisenterprise.PrivateEndpoint{ // ID: to.Ptr("/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/privateEndpoints/petest01"), // }, // PrivateLinkServiceConnectionState: &armredisenterprise.PrivateLinkServiceConnectionState{ // Description: to.Ptr("Auto-Approved"), // ActionsRequired: to.Ptr("None"), // Status: to.Ptr(armredisenterprise.PrivateEndpointServiceConnectionStatusApproved), // }, // ProvisioningState: to.Ptr(armredisenterprise.PrivateEndpointConnectionProvisioningStateSucceeded), // }, // }
Output:
func (*PrivateEndpointConnectionsClient) NewListPager ¶
func (client *PrivateEndpointConnectionsClient) NewListPager(resourceGroupName string, clusterName string, options *PrivateEndpointConnectionsClientListOptions) *runtime.Pager[PrivateEndpointConnectionsClientListResponse]
NewListPager - Lists all the private endpoint connections associated with the RedisEnterprise cluster.
Generated from API version 2023-11-01
- resourceGroupName - The name of the resource group. The name is case insensitive.
- clusterName - The name of the RedisEnterprise cluster.
- options - PrivateEndpointConnectionsClientListOptions contains the optional parameters for the PrivateEndpointConnectionsClient.NewListPager method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/d4205894880b989ede35d62d97c8e901ed14fb5a/specification/redisenterprise/resource-manager/Microsoft.Cache/stable/2023-11-01/examples/RedisEnterpriseListPrivateEndpointConnections.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armredisenterprise.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } pager := clientFactory.NewPrivateEndpointConnectionsClient().NewListPager("rg1", "cache1", 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.PrivateEndpointConnectionListResult = armredisenterprise.PrivateEndpointConnectionListResult{ // Value: []*armredisenterprise.PrivateEndpointConnection{ // { // Name: to.Ptr("pectest01"), // Type: to.Ptr("Microsoft.Cache/redisEnterprise/privateEndpointConnections"), // ID: to.Ptr("/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Cache/redisEnterprise/cache1/privateEndpointConnections/pectest01"), // Properties: &armredisenterprise.PrivateEndpointConnectionProperties{ // PrivateEndpoint: &armredisenterprise.PrivateEndpoint{ // ID: to.Ptr("/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/privateEndpoints/petest01"), // }, // PrivateLinkServiceConnectionState: &armredisenterprise.PrivateLinkServiceConnectionState{ // Description: to.Ptr("Auto-Approved"), // ActionsRequired: to.Ptr("None"), // Status: to.Ptr(armredisenterprise.PrivateEndpointServiceConnectionStatusApproved), // }, // ProvisioningState: to.Ptr(armredisenterprise.PrivateEndpointConnectionProvisioningStateSucceeded), // }, // }, // { // Name: to.Ptr("pectest01"), // Type: to.Ptr("Microsoft.Cache/redisEnterprise/privateEndpointConnections"), // ID: to.Ptr("/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Cache/redisEnterprise/cache1/privateEndpointConnections/pectest01"), // Properties: &armredisenterprise.PrivateEndpointConnectionProperties{ // PrivateEndpoint: &armredisenterprise.PrivateEndpoint{ // ID: to.Ptr("/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/privateEndpoints/petest01"), // }, // PrivateLinkServiceConnectionState: &armredisenterprise.PrivateLinkServiceConnectionState{ // Description: to.Ptr("Auto-Approved"), // ActionsRequired: to.Ptr("None"), // Status: to.Ptr(armredisenterprise.PrivateEndpointServiceConnectionStatusApproved), // }, // ProvisioningState: to.Ptr(armredisenterprise.PrivateEndpointConnectionProvisioningStateSucceeded), // }, // }}, // } }
Output:
type PrivateEndpointConnectionsClientBeginDeleteOptions ¶
type PrivateEndpointConnectionsClientBeginDeleteOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
PrivateEndpointConnectionsClientBeginDeleteOptions contains the optional parameters for the PrivateEndpointConnectionsClient.BeginDelete method.
type PrivateEndpointConnectionsClientBeginPutOptions ¶
type PrivateEndpointConnectionsClientBeginPutOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
PrivateEndpointConnectionsClientBeginPutOptions contains the optional parameters for the PrivateEndpointConnectionsClient.BeginPut method.
type PrivateEndpointConnectionsClientDeleteResponse ¶
type PrivateEndpointConnectionsClientDeleteResponse struct { }
PrivateEndpointConnectionsClientDeleteResponse contains the response from method PrivateEndpointConnectionsClient.BeginDelete.
type PrivateEndpointConnectionsClientGetOptions ¶
type PrivateEndpointConnectionsClientGetOptions struct { }
PrivateEndpointConnectionsClientGetOptions contains the optional parameters for the PrivateEndpointConnectionsClient.Get method.
type PrivateEndpointConnectionsClientGetResponse ¶
type PrivateEndpointConnectionsClientGetResponse struct { // The Private Endpoint Connection resource. PrivateEndpointConnection }
PrivateEndpointConnectionsClientGetResponse contains the response from method PrivateEndpointConnectionsClient.Get.
type PrivateEndpointConnectionsClientListOptions ¶
type PrivateEndpointConnectionsClientListOptions struct { }
PrivateEndpointConnectionsClientListOptions contains the optional parameters for the PrivateEndpointConnectionsClient.NewListPager method.
type PrivateEndpointConnectionsClientListResponse ¶
type PrivateEndpointConnectionsClientListResponse struct { // List of private endpoint connection associated with the specified storage account PrivateEndpointConnectionListResult }
PrivateEndpointConnectionsClientListResponse contains the response from method PrivateEndpointConnectionsClient.NewListPager.
type PrivateEndpointConnectionsClientPutResponse ¶
type PrivateEndpointConnectionsClientPutResponse struct { // The Private Endpoint Connection resource. PrivateEndpointConnection }
PrivateEndpointConnectionsClientPutResponse contains the response from method PrivateEndpointConnectionsClient.BeginPut.
type PrivateEndpointServiceConnectionStatus ¶
type PrivateEndpointServiceConnectionStatus string
PrivateEndpointServiceConnectionStatus - The private endpoint connection status.
const ( PrivateEndpointServiceConnectionStatusApproved PrivateEndpointServiceConnectionStatus = "Approved" PrivateEndpointServiceConnectionStatusPending PrivateEndpointServiceConnectionStatus = "Pending" PrivateEndpointServiceConnectionStatusRejected PrivateEndpointServiceConnectionStatus = "Rejected" )
func PossiblePrivateEndpointServiceConnectionStatusValues ¶
func PossiblePrivateEndpointServiceConnectionStatusValues() []PrivateEndpointServiceConnectionStatus
PossiblePrivateEndpointServiceConnectionStatusValues returns the possible values for the PrivateEndpointServiceConnectionStatus const type.
type PrivateLinkResource ¶
type PrivateLinkResource struct { // Resource properties. Properties *PrivateLinkResourceProperties // READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string // READ-ONLY; The name of the resource Name *string // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string }
PrivateLinkResource - A private link resource
func (PrivateLinkResource) MarshalJSON ¶
func (p PrivateLinkResource) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type PrivateLinkResource.
func (*PrivateLinkResource) UnmarshalJSON ¶
func (p *PrivateLinkResource) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type PrivateLinkResource.
type PrivateLinkResourceListResult ¶
type PrivateLinkResourceListResult struct { // Array of private link resources Value []*PrivateLinkResource }
PrivateLinkResourceListResult - A list of private link resources
func (PrivateLinkResourceListResult) MarshalJSON ¶
func (p PrivateLinkResourceListResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type PrivateLinkResourceListResult.
func (*PrivateLinkResourceListResult) UnmarshalJSON ¶
func (p *PrivateLinkResourceListResult) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type PrivateLinkResourceListResult.
type PrivateLinkResourceProperties ¶
type PrivateLinkResourceProperties struct { // The private link resource Private link DNS zone name. RequiredZoneNames []*string // READ-ONLY; The private link resource group id. GroupID *string // READ-ONLY; The private link resource required member names. RequiredMembers []*string }
PrivateLinkResourceProperties - Properties of a private link resource.
func (PrivateLinkResourceProperties) MarshalJSON ¶
func (p PrivateLinkResourceProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type PrivateLinkResourceProperties.
func (*PrivateLinkResourceProperties) UnmarshalJSON ¶
func (p *PrivateLinkResourceProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type PrivateLinkResourceProperties.
type PrivateLinkResourcesClient ¶
type PrivateLinkResourcesClient struct {
// contains filtered or unexported fields
}
PrivateLinkResourcesClient contains the methods for the PrivateLinkResources group. Don't use this type directly, use NewPrivateLinkResourcesClient() instead.
func NewPrivateLinkResourcesClient ¶
func NewPrivateLinkResourcesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*PrivateLinkResourcesClient, error)
NewPrivateLinkResourcesClient creates a new instance of PrivateLinkResourcesClient 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 (*PrivateLinkResourcesClient) NewListByClusterPager ¶
func (client *PrivateLinkResourcesClient) NewListByClusterPager(resourceGroupName string, clusterName string, options *PrivateLinkResourcesClientListByClusterOptions) *runtime.Pager[PrivateLinkResourcesClientListByClusterResponse]
NewListByClusterPager - Gets the private link resources that need to be created for a RedisEnterprise cluster.
Generated from API version 2023-11-01
- resourceGroupName - The name of the resource group. The name is case insensitive.
- clusterName - The name of the RedisEnterprise cluster.
- options - PrivateLinkResourcesClientListByClusterOptions contains the optional parameters for the PrivateLinkResourcesClient.NewListByClusterPager method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/d4205894880b989ede35d62d97c8e901ed14fb5a/specification/redisenterprise/resource-manager/Microsoft.Cache/stable/2023-11-01/examples/RedisEnterpriseListPrivateLinkResources.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armredisenterprise.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } pager := clientFactory.NewPrivateLinkResourcesClient().NewListByClusterPager("rg1", "cache1", 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.PrivateLinkResourceListResult = armredisenterprise.PrivateLinkResourceListResult{ // Value: []*armredisenterprise.PrivateLinkResource{ // { // Name: to.Ptr("redisEnterpriseCache"), // Type: to.Ptr("Microsoft.Cache/redisEnterprise/privateLinkResources"), // ID: to.Ptr("/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Cache/redisEnterprise/cache1/privateLinkResources/redisEnterpriseCache"), // Properties: &armredisenterprise.PrivateLinkResourceProperties{ // GroupID: to.Ptr("redisEnterpriseCache"), // RequiredMembers: []*string{ // to.Ptr("redisEnterpriseCache")}, // RequiredZoneNames: []*string{ // to.Ptr("privatelink.redisenterprise.cache.windows.net")}, // }, // }}, // } }
Output:
type PrivateLinkResourcesClientListByClusterOptions ¶
type PrivateLinkResourcesClientListByClusterOptions struct { }
PrivateLinkResourcesClientListByClusterOptions contains the optional parameters for the PrivateLinkResourcesClient.NewListByClusterPager method.
type PrivateLinkResourcesClientListByClusterResponse ¶
type PrivateLinkResourcesClientListByClusterResponse struct { // A list of private link resources PrivateLinkResourceListResult }
PrivateLinkResourcesClientListByClusterResponse contains the response from method PrivateLinkResourcesClient.NewListByClusterPager.
type PrivateLinkServiceConnectionState ¶
type PrivateLinkServiceConnectionState struct { // A message indicating if changes on the service provider require any updates on the consumer. ActionsRequired *string // The reason for approval/rejection of the connection. Description *string // Indicates whether the connection has been Approved/Rejected/Removed by the owner of the service. Status *PrivateEndpointServiceConnectionStatus }
PrivateLinkServiceConnectionState - A collection of information about the state of the connection between service consumer and provider.
func (PrivateLinkServiceConnectionState) MarshalJSON ¶
func (p PrivateLinkServiceConnectionState) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type PrivateLinkServiceConnectionState.
func (*PrivateLinkServiceConnectionState) UnmarshalJSON ¶
func (p *PrivateLinkServiceConnectionState) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type PrivateLinkServiceConnectionState.
type Protocol ¶
type Protocol string
Protocol - Specifies whether redis clients can connect using TLS-encrypted or plaintext redis protocols. Default is TLS-encrypted.
func PossibleProtocolValues ¶
func PossibleProtocolValues() []Protocol
PossibleProtocolValues returns the possible values for the Protocol const type.
type ProvisioningState ¶
type ProvisioningState string
ProvisioningState - Current provisioning status
const ( ProvisioningStateCanceled ProvisioningState = "Canceled" ProvisioningStateCreating ProvisioningState = "Creating" ProvisioningStateDeleting ProvisioningState = "Deleting" ProvisioningStateFailed ProvisioningState = "Failed" ProvisioningStateSucceeded ProvisioningState = "Succeeded" ProvisioningStateUpdating ProvisioningState = "Updating" )
func PossibleProvisioningStateValues ¶
func PossibleProvisioningStateValues() []ProvisioningState
PossibleProvisioningStateValues returns the possible values for the ProvisioningState const type.
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 // READ-ONLY; The name of the resource Name *string // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string }
ProxyResource - The resource model definition for a Azure Resource Manager proxy resource. It will not have tags and a location
func (ProxyResource) MarshalJSON ¶
func (p ProxyResource) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ProxyResource.
func (*ProxyResource) UnmarshalJSON ¶
func (p *ProxyResource) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ProxyResource.
type RdbFrequency ¶
type RdbFrequency string
RdbFrequency - Sets the frequency at which a snapshot of the database is created.
const ( RdbFrequencyOneH RdbFrequency = "1h" RdbFrequencySixH RdbFrequency = "6h" RdbFrequencyTwelveH RdbFrequency = "12h" )
func PossibleRdbFrequencyValues ¶
func PossibleRdbFrequencyValues() []RdbFrequency
PossibleRdbFrequencyValues returns the possible values for the RdbFrequency const type.
type RegenerateKeyParameters ¶
type RegenerateKeyParameters struct { // REQUIRED; Which access key to regenerate. KeyType *AccessKeyType }
RegenerateKeyParameters - Specifies which access keys to reset to a new random value.
func (RegenerateKeyParameters) MarshalJSON ¶
func (r RegenerateKeyParameters) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type RegenerateKeyParameters.
func (*RegenerateKeyParameters) UnmarshalJSON ¶
func (r *RegenerateKeyParameters) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type RegenerateKeyParameters.
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 // READ-ONLY; The name of the resource Name *string // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string }
Resource - Common fields that are returned in the response for all Azure Resource Manager resources
func (Resource) MarshalJSON ¶
MarshalJSON implements the json.Marshaller interface for type Resource.
func (*Resource) UnmarshalJSON ¶
UnmarshalJSON implements the json.Unmarshaller interface for type Resource.
type ResourceState ¶
type ResourceState string
ResourceState - Current resource status
const ( ResourceStateCreateFailed ResourceState = "CreateFailed" ResourceStateCreating ResourceState = "Creating" ResourceStateDeleteFailed ResourceState = "DeleteFailed" ResourceStateDeleting ResourceState = "Deleting" ResourceStateDisableFailed ResourceState = "DisableFailed" ResourceStateDisabled ResourceState = "Disabled" ResourceStateDisabling ResourceState = "Disabling" ResourceStateEnableFailed ResourceState = "EnableFailed" ResourceStateEnabling ResourceState = "Enabling" ResourceStateRunning ResourceState = "Running" ResourceStateScaling ResourceState = "Scaling" ResourceStateScalingFailed ResourceState = "ScalingFailed" ResourceStateUpdateFailed ResourceState = "UpdateFailed" ResourceStateUpdating ResourceState = "Updating" )
func PossibleResourceStateValues ¶
func PossibleResourceStateValues() []ResourceState
PossibleResourceStateValues returns the possible values for the ResourceState const type.
type SKU ¶
type SKU struct { // REQUIRED; The type of RedisEnterprise cluster to deploy. Possible values: (EnterpriseE10, EnterpriseFlashF300 etc.) Name *SKUName // The size of the RedisEnterprise cluster. Defaults to 2 or 3 depending on SKU. Valid values are (2, 4, 6, …) for Enterprise // SKUs and (3, 9, 15, …) for Flash SKUs. Capacity *int32 }
SKU parameters supplied to the create RedisEnterprise operation.
func (SKU) MarshalJSON ¶
MarshalJSON implements the json.Marshaller interface for type SKU.
func (*SKU) UnmarshalJSON ¶
UnmarshalJSON implements the json.Unmarshaller interface for type SKU.
type SKUName ¶
type SKUName string
SKUName - The type of RedisEnterprise cluster to deploy. Possible values: (EnterpriseE10, EnterpriseFlashF300 etc.)
const ( SKUNameEnterpriseE10 SKUName = "Enterprise_E10" SKUNameEnterpriseE100 SKUName = "Enterprise_E100" SKUNameEnterpriseE20 SKUName = "Enterprise_E20" SKUNameEnterpriseE50 SKUName = "Enterprise_E50" SKUNameEnterpriseFlashF1500 SKUName = "EnterpriseFlash_F1500" SKUNameEnterpriseFlashF300 SKUName = "EnterpriseFlash_F300" SKUNameEnterpriseFlashF700 SKUName = "EnterpriseFlash_F700" )
func PossibleSKUNameValues ¶
func PossibleSKUNameValues() []SKUName
PossibleSKUNameValues returns the possible values for the SKUName const type.
type TLSVersion ¶
type TLSVersion string
TLSVersion - The minimum TLS version for the cluster to support, e.g. '1.2'
const ( TLSVersionOne0 TLSVersion = "1.0" TLSVersionOne1 TLSVersion = "1.1" TLSVersionOne2 TLSVersion = "1.2" )
func PossibleTLSVersionValues ¶
func PossibleTLSVersionValues() []TLSVersion
PossibleTLSVersionValues returns the possible values for the TLSVersion const type.
type TrackedResource ¶
type TrackedResource struct { // REQUIRED; The geo-location where the resource lives Location *string // Resource tags. Tags map[string]*string // READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string // READ-ONLY; The name of the resource Name *string // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string }
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 ¶
func (t *TrackedResource) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type TrackedResource.
type UserAssignedIdentity ¶
type UserAssignedIdentity struct { // READ-ONLY; The client ID of the assigned identity. ClientID *string // READ-ONLY; The principal ID of the assigned identity. PrincipalID *string }
UserAssignedIdentity - User assigned identity properties
func (UserAssignedIdentity) MarshalJSON ¶
func (u UserAssignedIdentity) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type UserAssignedIdentity.
func (*UserAssignedIdentity) UnmarshalJSON ¶
func (u *UserAssignedIdentity) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type UserAssignedIdentity.