advancedcluster

package
v1.14.0 Latest Latest
Warning

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

Go to latest
Published: Dec 19, 2023 License: MPL-2.0 Imports: 23 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ErrorClusterSetting            = "error setting `%s` for MongoDB Cluster (%s): %s"
	ErrorAdvancedConfRead          = "error reading Advanced Configuration Option form MongoDB Cluster (%s): %s"
	ErrorClusterAdvancedSetting    = "error setting `%s` for MongoDB ClusterAdvanced (%s): %s"
	ErrorAdvancedClusterListStatus = "error awaiting MongoDB ClusterAdvanced List IDLE: %s"
)

Variables

View Source
var (
	DefaultLabel = matlas.Label{Key: "Infrastructure Tool", Value: "MongoDB Atlas Terraform Provider"}
	DSTagsSchema = schema.Schema{
		Type:     schema.TypeSet,
		Computed: true,
		Elem: &schema.Resource{
			Schema: map[string]*schema.Schema{
				"key": {
					Type:     schema.TypeString,
					Computed: true,
				},
				"value": {
					Type:     schema.TypeString,
					Computed: true,
				},
			},
		},
	}
	RSTagsSchema = schema.Schema{
		Type:     schema.TypeSet,
		Optional: true,
		Elem: &schema.Resource{
			Schema: map[string]*schema.Schema{
				"key": {
					Type:     schema.TypeString,
					Required: true,
				},
				"value": {
					Type:     schema.TypeString,
					Required: true,
				},
			},
		},
	}
)

Functions

func ClusterAdvancedConfigurationSchema

func ClusterAdvancedConfigurationSchema() *schema.Schema

func ClusterAdvancedConfigurationSchemaComputed

func ClusterAdvancedConfigurationSchemaComputed() *schema.Schema

func ClusterConnectionStringsSchema

func ClusterConnectionStringsSchema() *schema.Schema

func ContainsLabelOrKey

func ContainsLabelOrKey(list []matlas.Label, item matlas.Label) bool

func DataSource

func DataSource() *schema.Resource

func ExpandBiConnectorConfig

func ExpandBiConnectorConfig(d *schema.ResourceData) (*matlas.BiConnector, error)

func ExpandLabelSliceFromSetSchema

func ExpandLabelSliceFromSetSchema(d *schema.ResourceData) []matlas.Label

func ExpandProcessArgs

func ExpandProcessArgs(d *schema.ResourceData, p map[string]any) *matlas.ProcessArgs

func ExpandTagSliceFromSetSchema

func ExpandTagSliceFromSetSchema(d *schema.ResourceData) []*matlas.Tag

func FlattenBiConnectorConfig

func FlattenBiConnectorConfig(biConnector *matlas.BiConnector) []any

func FlattenConnectionStrings

func FlattenConnectionStrings(connectionStrings *matlas.ConnectionStrings) []map[string]any

func FlattenLabels

func FlattenLabels(l []matlas.Label) []map[string]any

func FlattenProcessArgs

func FlattenProcessArgs(p *matlas.ProcessArgs) []any

func FlattenTags

func FlattenTags(l *[]*matlas.Tag) []map[string]any

func FormatMongoDBMajorVersion

func FormatMongoDBMajorVersion(val any) string

func HashCodeString

func HashCodeString(s string) int

HashCodeString hashes a string to a unique hashcode.

crc32 returns a uint32, but for our use we need and non negative integer. Here we cast to an integer and invert it if the result is negative.

func HashFunctionForKeyValuePair

func HashFunctionForKeyValuePair(v any) int

func IsSharedTier

func IsSharedTier(instanceSize string) bool

func MigrateBIConnectorConfig

func MigrateBIConnectorConfig(rawState map[string]any) map[string]any

func PluralDataSource

func PluralDataSource() *schema.Resource

func RemoveLabel

func RemoveLabel(list []matlas.Label, item matlas.Label) []matlas.Label

func Resource

func Resource() *schema.Resource

func ResourceClusterListAdvancedRefreshFunc

func ResourceClusterListAdvancedRefreshFunc(ctx context.Context, projectID string, client *matlas.Client) retry.StateRefreshFunc

func ResourceClusterRefreshFunc

func ResourceClusterRefreshFunc(ctx context.Context, name, projectID string, client *matlas.Client) retry.StateRefreshFunc

func ResourceV0

func ResourceV0() *schema.Resource

func UpgradeCluster

func UpgradeCluster(ctx context.Context, conn *matlas.Client, request *matlas.Cluster, projectID, name string, timeout time.Duration) (*matlas.Cluster, *matlas.Response, error)

Types

This section is empty.

Jump to

Keyboard shortcuts

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