cbim

package
v0.0.0-...-17071f4 Latest Latest
Warning

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

Go to latest
Published: Feb 23, 2023 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	StrategyHash = "hash"
)

Variables

This section is empty.

Functions

func GenerateYaml

func GenerateYaml(indexSet *couchbasev1beta1.CouchbaseIndexSet, deletingIndexes *[]GlobalSecondaryIndexIdentifier) (string, error)

Types

type GlobalSecondaryIndexIdentifier

type GlobalSecondaryIndexIdentifier struct {
	// Name of the index
	Name string
	// Name of the index's scope
	ScopeName string
	// Name of the index's collection
	CollectionName string
}

Uniquely defines a global secondary index.

func ParseIndexIdentifierString

func ParseIndexIdentifierString(identifier string) (GlobalSecondaryIndexIdentifier, error)

func (GlobalSecondaryIndexIdentifier) IsDefaultCollection

func (identifier GlobalSecondaryIndexIdentifier) IsDefaultCollection() bool

func (GlobalSecondaryIndexIdentifier) ToString

func (identifier GlobalSecondaryIndexIdentifier) ToString() string

type IndexSpec

type IndexSpec struct {
	Type               string         `json:"type,omitempty"`
	Name               string         `json:"name"`
	Scope              *string        `json:"scope,omitempty"`
	Collection         *string        `json:"collection,omitempty"`
	IsPrimary          *bool          `json:"is_primary,omitempty"`
	IndexKey           *[]string      `json:"index_key,omitempty"`
	Condition          *string        `json:"condition,omitempty"`
	RetainDeletedXattr *bool          `json:"retain_deleted_xattr,omitempty"`
	Partition          *PartitionSpec `json:"partition,omitempty"`
	ManualReplica      *bool          `json:"manual_replica,omitempty"`
	NumReplicas        *int           `json:"num_replica,omitempty"`
	Nodes              *[]string      `json:"nodes,omitempty"`
	Lifecycle          *LifecycleSpec `json:"lifecycle,omitempty"`
}

type LifecycleSpec

type LifecycleSpec struct {
	Drop *bool `json:"drop,omitempty"`
}

type PartitionSpec

type PartitionSpec struct {
	Expressions   []string `json:"exprs"`
	Strategy      *string  `json:"strategy,omitempty"`
	NumPartitions *int     `json:"num_partition,omitempty"`
}

Jump to

Keyboard shortcuts

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