configurations

package
v0.20231116.1162710 Latest Latest
Warning

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

Go to latest
Published: Nov 16, 2023 License: MPL-2.0 Imports: 12 Imported by: 1

README

github.com/hashicorp/go-azure-sdk/resource-manager/postgresqlhsc/2022-11-08/configurations Documentation

The configurations SDK allows for interaction with the Azure Resource Manager Service postgresqlhsc (API Version 2022-11-08).

This readme covers example usages, but further information on using this SDK can be found in the project root.

Import Path

import "github.com/hashicorp/go-azure-sdk/resource-manager/postgresqlhsc/2022-11-08/configurations"

Client Initialization

client := configurations.NewConfigurationsClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: ConfigurationsClient.Get

ctx := context.TODO()
id := configurations.NewConfigurationID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serverGroupsv2Value", "configurationValue")

read, err := client.Get(ctx, id)
if err != nil {
	// handle the error
}
if model := read.Model; model != nil {
	// do something with the model/response object
}

Example Usage: ConfigurationsClient.GetCoordinator

ctx := context.TODO()
id := configurations.NewCoordinatorConfigurationID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serverGroupsv2Value", "coordinatorConfigurationValue")

read, err := client.GetCoordinator(ctx, id)
if err != nil {
	// handle the error
}
if model := read.Model; model != nil {
	// do something with the model/response object
}

Example Usage: ConfigurationsClient.GetNode

ctx := context.TODO()
id := configurations.NewNodeConfigurationID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serverGroupsv2Value", "nodeConfigurationValue")

read, err := client.GetNode(ctx, id)
if err != nil {
	// handle the error
}
if model := read.Model; model != nil {
	// do something with the model/response object
}

Example Usage: ConfigurationsClient.ListByCluster

ctx := context.TODO()
id := configurations.NewServerGroupsv2ID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serverGroupsv2Value")

// alternatively `client.ListByCluster(ctx, id)` can be used to do batched pagination
items, err := client.ListByClusterComplete(ctx, id)
if err != nil {
	// handle the error
}
for _, item := range items {
	// do something
}

Example Usage: ConfigurationsClient.ListByServer

ctx := context.TODO()
id := configurations.NewServerID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serverGroupsv2Value", "serverValue")

// alternatively `client.ListByServer(ctx, id)` can be used to do batched pagination
items, err := client.ListByServerComplete(ctx, id)
if err != nil {
	// handle the error
}
for _, item := range items {
	// do something
}

Example Usage: ConfigurationsClient.UpdateOnCoordinator

ctx := context.TODO()
id := configurations.NewCoordinatorConfigurationID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serverGroupsv2Value", "coordinatorConfigurationValue")

payload := configurations.ServerConfiguration{
	// ...
}


if err := client.UpdateOnCoordinatorThenPoll(ctx, id, payload); err != nil {
	// handle the error
}

Example Usage: ConfigurationsClient.UpdateOnNode

ctx := context.TODO()
id := configurations.NewNodeConfigurationID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serverGroupsv2Value", "nodeConfigurationValue")

payload := configurations.ServerConfiguration{
	// ...
}


if err := client.UpdateOnNodeThenPoll(ctx, id, payload); err != nil {
	// handle the error
}

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func PossibleValuesForConfigurationDataType

func PossibleValuesForConfigurationDataType() []string

func PossibleValuesForProvisioningState

func PossibleValuesForProvisioningState() []string

func PossibleValuesForServerRole

func PossibleValuesForServerRole() []string

func ValidateConfigurationID

func ValidateConfigurationID(input interface{}, key string) (warnings []string, errors []error)

ValidateConfigurationID checks that 'input' can be parsed as a Configuration ID

func ValidateCoordinatorConfigurationID

func ValidateCoordinatorConfigurationID(input interface{}, key string) (warnings []string, errors []error)

ValidateCoordinatorConfigurationID checks that 'input' can be parsed as a Coordinator Configuration ID

func ValidateNodeConfigurationID

func ValidateNodeConfigurationID(input interface{}, key string) (warnings []string, errors []error)

ValidateNodeConfigurationID checks that 'input' can be parsed as a Node Configuration ID

func ValidateServerGroupsv2ID

func ValidateServerGroupsv2ID(input interface{}, key string) (warnings []string, errors []error)

ValidateServerGroupsv2ID checks that 'input' can be parsed as a Server Groupsv 2 ID

func ValidateServerID

func ValidateServerID(input interface{}, key string) (warnings []string, errors []error)

ValidateServerID checks that 'input' can be parsed as a Server ID

Types

type Configuration

type Configuration struct {
	Id         *string                  `json:"id,omitempty"`
	Name       *string                  `json:"name,omitempty"`
	Properties *ConfigurationProperties `json:"properties,omitempty"`
	SystemData *systemdata.SystemData   `json:"systemData,omitempty"`
	Type       *string                  `json:"type,omitempty"`
}

type ConfigurationDataType

type ConfigurationDataType string
const (
	ConfigurationDataTypeBoolean     ConfigurationDataType = "Boolean"
	ConfigurationDataTypeEnumeration ConfigurationDataType = "Enumeration"
	ConfigurationDataTypeInteger     ConfigurationDataType = "Integer"
	ConfigurationDataTypeNumeric     ConfigurationDataType = "Numeric"
)

func (*ConfigurationDataType) UnmarshalJSON added in v0.20230809.1081239

func (s *ConfigurationDataType) UnmarshalJSON(bytes []byte) error

type ConfigurationId

type ConfigurationId struct {
	SubscriptionId     string
	ResourceGroupName  string
	ServerGroupsv2Name string
	ConfigurationName  string
}

ConfigurationId is a struct representing the Resource ID for a Configuration

func NewConfigurationID

func NewConfigurationID(subscriptionId string, resourceGroupName string, serverGroupsv2Name string, configurationName string) ConfigurationId

NewConfigurationID returns a new ConfigurationId struct

func ParseConfigurationID

func ParseConfigurationID(input string) (*ConfigurationId, error)

ParseConfigurationID parses 'input' into a ConfigurationId

func ParseConfigurationIDInsensitively

func ParseConfigurationIDInsensitively(input string) (*ConfigurationId, error)

ParseConfigurationIDInsensitively parses 'input' case-insensitively into a ConfigurationId note: this method should only be used for API response data and not user input

func (ConfigurationId) ID

func (id ConfigurationId) ID() string

ID returns the formatted Configuration ID

func (ConfigurationId) Segments

func (id ConfigurationId) Segments() []resourceids.Segment

Segments returns a slice of Resource ID Segments which comprise this Configuration ID

func (ConfigurationId) String

func (id ConfigurationId) String() string

String returns a human-readable description of this Configuration ID

type ConfigurationOperationPredicate

type ConfigurationOperationPredicate struct {
	Id   *string
	Name *string
	Type *string
}

func (ConfigurationOperationPredicate) Matches

type ConfigurationProperties

type ConfigurationProperties struct {
	AllowedValues                 *string                        `json:"allowedValues,omitempty"`
	DataType                      *ConfigurationDataType         `json:"dataType,omitempty"`
	Description                   *string                        `json:"description,omitempty"`
	ProvisioningState             *ProvisioningState             `json:"provisioningState,omitempty"`
	RequiresRestart               *bool                          `json:"requiresRestart,omitempty"`
	ServerRoleGroupConfigurations []ServerRoleGroupConfiguration `json:"serverRoleGroupConfigurations"`
}

type ConfigurationsClient

type ConfigurationsClient struct {
	Client *resourcemanager.Client
}

func NewConfigurationsClientWithBaseURI

func NewConfigurationsClientWithBaseURI(sdkApi sdkEnv.Api) (*ConfigurationsClient, error)

func (ConfigurationsClient) Get

Get ...

func (ConfigurationsClient) GetCoordinator

GetCoordinator ...

func (ConfigurationsClient) GetNode

GetNode ...

func (ConfigurationsClient) ListByCluster

ListByCluster ...

func (ConfigurationsClient) ListByClusterComplete

ListByClusterComplete retrieves all the results into a single object

func (ConfigurationsClient) ListByClusterCompleteMatchingPredicate

func (c ConfigurationsClient) ListByClusterCompleteMatchingPredicate(ctx context.Context, id ServerGroupsv2Id, predicate ConfigurationOperationPredicate) (result ListByClusterCompleteResult, err error)

ListByClusterCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (ConfigurationsClient) ListByServer

func (c ConfigurationsClient) ListByServer(ctx context.Context, id ServerId) (result ListByServerOperationResponse, err error)

ListByServer ...

func (ConfigurationsClient) ListByServerComplete

func (c ConfigurationsClient) ListByServerComplete(ctx context.Context, id ServerId) (ListByServerCompleteResult, error)

ListByServerComplete retrieves all the results into a single object

func (ConfigurationsClient) ListByServerCompleteMatchingPredicate

func (c ConfigurationsClient) ListByServerCompleteMatchingPredicate(ctx context.Context, id ServerId, predicate ServerConfigurationOperationPredicate) (result ListByServerCompleteResult, err error)

ListByServerCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (ConfigurationsClient) UpdateOnCoordinator added in v0.20230317.1154451

UpdateOnCoordinator ...

func (ConfigurationsClient) UpdateOnCoordinatorThenPoll added in v0.20230317.1154451

func (c ConfigurationsClient) UpdateOnCoordinatorThenPoll(ctx context.Context, id CoordinatorConfigurationId, input ServerConfiguration) error

UpdateOnCoordinatorThenPoll performs UpdateOnCoordinator then polls until it's completed

func (ConfigurationsClient) UpdateOnNode added in v0.20230317.1154451

UpdateOnNode ...

func (ConfigurationsClient) UpdateOnNodeThenPoll added in v0.20230317.1154451

func (c ConfigurationsClient) UpdateOnNodeThenPoll(ctx context.Context, id NodeConfigurationId, input ServerConfiguration) error

UpdateOnNodeThenPoll performs UpdateOnNode then polls until it's completed

type CoordinatorConfigurationId

type CoordinatorConfigurationId struct {
	SubscriptionId               string
	ResourceGroupName            string
	ServerGroupsv2Name           string
	CoordinatorConfigurationName string
}

CoordinatorConfigurationId is a struct representing the Resource ID for a Coordinator Configuration

func NewCoordinatorConfigurationID

func NewCoordinatorConfigurationID(subscriptionId string, resourceGroupName string, serverGroupsv2Name string, coordinatorConfigurationName string) CoordinatorConfigurationId

NewCoordinatorConfigurationID returns a new CoordinatorConfigurationId struct

func ParseCoordinatorConfigurationID

func ParseCoordinatorConfigurationID(input string) (*CoordinatorConfigurationId, error)

ParseCoordinatorConfigurationID parses 'input' into a CoordinatorConfigurationId

func ParseCoordinatorConfigurationIDInsensitively

func ParseCoordinatorConfigurationIDInsensitively(input string) (*CoordinatorConfigurationId, error)

ParseCoordinatorConfigurationIDInsensitively parses 'input' case-insensitively into a CoordinatorConfigurationId note: this method should only be used for API response data and not user input

func (CoordinatorConfigurationId) ID

ID returns the formatted Coordinator Configuration ID

func (CoordinatorConfigurationId) Segments

Segments returns a slice of Resource ID Segments which comprise this Coordinator Configuration ID

func (CoordinatorConfigurationId) String

func (id CoordinatorConfigurationId) String() string

String returns a human-readable description of this Coordinator Configuration ID

type GetCoordinatorOperationResponse

type GetCoordinatorOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *ServerConfiguration
}

type GetNodeOperationResponse

type GetNodeOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *ServerConfiguration
}

type GetOperationResponse

type GetOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *Configuration
}

type ListByClusterCompleteResult

type ListByClusterCompleteResult struct {
	Items []Configuration
}

type ListByClusterOperationResponse

type ListByClusterOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]Configuration
}

type ListByServerCompleteResult

type ListByServerCompleteResult struct {
	Items []ServerConfiguration
}

type ListByServerOperationResponse

type ListByServerOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]ServerConfiguration
}

type NodeConfigurationId

type NodeConfigurationId struct {
	SubscriptionId        string
	ResourceGroupName     string
	ServerGroupsv2Name    string
	NodeConfigurationName string
}

NodeConfigurationId is a struct representing the Resource ID for a Node Configuration

func NewNodeConfigurationID

func NewNodeConfigurationID(subscriptionId string, resourceGroupName string, serverGroupsv2Name string, nodeConfigurationName string) NodeConfigurationId

NewNodeConfigurationID returns a new NodeConfigurationId struct

func ParseNodeConfigurationID

func ParseNodeConfigurationID(input string) (*NodeConfigurationId, error)

ParseNodeConfigurationID parses 'input' into a NodeConfigurationId

func ParseNodeConfigurationIDInsensitively

func ParseNodeConfigurationIDInsensitively(input string) (*NodeConfigurationId, error)

ParseNodeConfigurationIDInsensitively parses 'input' case-insensitively into a NodeConfigurationId note: this method should only be used for API response data and not user input

func (NodeConfigurationId) ID

func (id NodeConfigurationId) ID() string

ID returns the formatted Node Configuration ID

func (NodeConfigurationId) Segments

func (id NodeConfigurationId) Segments() []resourceids.Segment

Segments returns a slice of Resource ID Segments which comprise this Node Configuration ID

func (NodeConfigurationId) String

func (id NodeConfigurationId) String() string

String returns a human-readable description of this Node Configuration ID

type ProvisioningState

type ProvisioningState string
const (
	ProvisioningStateCanceled   ProvisioningState = "Canceled"
	ProvisioningStateFailed     ProvisioningState = "Failed"
	ProvisioningStateInProgress ProvisioningState = "InProgress"
	ProvisioningStateSucceeded  ProvisioningState = "Succeeded"
)

func (*ProvisioningState) UnmarshalJSON added in v0.20230809.1081239

func (s *ProvisioningState) UnmarshalJSON(bytes []byte) error

type ServerConfiguration

type ServerConfiguration struct {
	Id         *string                        `json:"id,omitempty"`
	Name       *string                        `json:"name,omitempty"`
	Properties *ServerConfigurationProperties `json:"properties,omitempty"`
	SystemData *systemdata.SystemData         `json:"systemData,omitempty"`
	Type       *string                        `json:"type,omitempty"`
}

type ServerConfigurationOperationPredicate

type ServerConfigurationOperationPredicate struct {
	Id   *string
	Name *string
	Type *string
}

func (ServerConfigurationOperationPredicate) Matches

type ServerConfigurationProperties

type ServerConfigurationProperties struct {
	AllowedValues     *string                `json:"allowedValues,omitempty"`
	DataType          *ConfigurationDataType `json:"dataType,omitempty"`
	DefaultValue      *string                `json:"defaultValue,omitempty"`
	Description       *string                `json:"description,omitempty"`
	ProvisioningState *ProvisioningState     `json:"provisioningState,omitempty"`
	RequiresRestart   *bool                  `json:"requiresRestart,omitempty"`
	Source            *string                `json:"source,omitempty"`
	Value             string                 `json:"value"`
}

type ServerGroupsv2Id

type ServerGroupsv2Id struct {
	SubscriptionId     string
	ResourceGroupName  string
	ServerGroupsv2Name string
}

ServerGroupsv2Id is a struct representing the Resource ID for a Server Groupsv 2

func NewServerGroupsv2ID

func NewServerGroupsv2ID(subscriptionId string, resourceGroupName string, serverGroupsv2Name string) ServerGroupsv2Id

NewServerGroupsv2ID returns a new ServerGroupsv2Id struct

func ParseServerGroupsv2ID

func ParseServerGroupsv2ID(input string) (*ServerGroupsv2Id, error)

ParseServerGroupsv2ID parses 'input' into a ServerGroupsv2Id

func ParseServerGroupsv2IDInsensitively

func ParseServerGroupsv2IDInsensitively(input string) (*ServerGroupsv2Id, error)

ParseServerGroupsv2IDInsensitively parses 'input' case-insensitively into a ServerGroupsv2Id note: this method should only be used for API response data and not user input

func (ServerGroupsv2Id) ID

func (id ServerGroupsv2Id) ID() string

ID returns the formatted Server Groupsv 2 ID

func (ServerGroupsv2Id) Segments

func (id ServerGroupsv2Id) Segments() []resourceids.Segment

Segments returns a slice of Resource ID Segments which comprise this Server Groupsv 2 ID

func (ServerGroupsv2Id) String

func (id ServerGroupsv2Id) String() string

String returns a human-readable description of this Server Groupsv 2 ID

type ServerId

type ServerId struct {
	SubscriptionId     string
	ResourceGroupName  string
	ServerGroupsv2Name string
	ServerName         string
}

ServerId is a struct representing the Resource ID for a Server

func NewServerID

func NewServerID(subscriptionId string, resourceGroupName string, serverGroupsv2Name string, serverName string) ServerId

NewServerID returns a new ServerId struct

func ParseServerID

func ParseServerID(input string) (*ServerId, error)

ParseServerID parses 'input' into a ServerId

func ParseServerIDInsensitively

func ParseServerIDInsensitively(input string) (*ServerId, error)

ParseServerIDInsensitively parses 'input' case-insensitively into a ServerId note: this method should only be used for API response data and not user input

func (ServerId) ID

func (id ServerId) ID() string

ID returns the formatted Server ID

func (ServerId) Segments

func (id ServerId) Segments() []resourceids.Segment

Segments returns a slice of Resource ID Segments which comprise this Server ID

func (ServerId) String

func (id ServerId) String() string

String returns a human-readable description of this Server ID

type ServerRole

type ServerRole string
const (
	ServerRoleCoordinator ServerRole = "Coordinator"
	ServerRoleWorker      ServerRole = "Worker"
)

func (*ServerRole) UnmarshalJSON added in v0.20230809.1081239

func (s *ServerRole) UnmarshalJSON(bytes []byte) error

type ServerRoleGroupConfiguration

type ServerRoleGroupConfiguration struct {
	DefaultValue *string    `json:"defaultValue,omitempty"`
	Role         ServerRole `json:"role"`
	Source       *string    `json:"source,omitempty"`
	Value        string     `json:"value"`
}

type UpdateOnCoordinatorOperationResponse added in v0.20230317.1154451

type UpdateOnCoordinatorOperationResponse struct {
	Poller       pollers.Poller
	HttpResponse *http.Response
	OData        *odata.OData
}

type UpdateOnNodeOperationResponse added in v0.20230317.1154451

type UpdateOnNodeOperationResponse struct {
	Poller       pollers.Poller
	HttpResponse *http.Response
	OData        *odata.OData
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL