universe

package
v0.0.0-...-f0e5f0d Latest Latest
Warning

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

Go to latest
Published: Jan 17, 2025 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

Certificates hold certificates declared under the current customer

View Source
var KMSConfigs []util.KMSConfig

KMSConfigs hold kms configs declared under the current customer

View Source
var Providers []ybaclient.Provider

Providers hold providers declared under the current customer

Functions

func NewClusterFormat

func NewClusterFormat(source string) formatter.Format

NewClusterFormat for formatting output

func NewFullUniverseFormat

func NewFullUniverseFormat(source string) formatter.Format

NewFullUniverseFormat for formatting output

func NewNodesFormat

func NewNodesFormat(source string) formatter.Format

NewNodesFormat for formatting output

func NewRegionFormat

func NewRegionFormat(source string) formatter.Format

NewRegionFormat for formatting output

func NewUniverseFormat

func NewUniverseFormat(source string) formatter.Format

NewUniverseFormat for formatting output

func NewZoneFormat

func NewZoneFormat(source string) formatter.Format

NewZoneFormat for formatting output

func NodeWrite

func NodeWrite(ctx formatter.Context, nodes []ybaclient.NodeDetailsResp) error

NodeWrite renders the context for a list of Node

func Write

func Write(ctx formatter.Context, universes []ybaclient.UniverseResp) error

Write renders the context for a list of Universes

Types

type ClusterContext

type ClusterContext struct {
	formatter.HeaderContext
	formatter.Context
	// contains filtered or unexported fields
}

ClusterContext for cluster outputs

func NewClusterContext

func NewClusterContext() *ClusterContext

NewClusterContext creates a new context for rendering clusters

func (*ClusterContext) ClusterDedicatedMasters

func (c *ClusterContext) ClusterDedicatedMasters() string

ClusterDedicatedMasters fetches boolean

func (*ClusterContext) ClusterNodes

func (c *ClusterContext) ClusterNodes() string

ClusterNodes fetches num of nodes in the cluster

func (*ClusterContext) ClusterRF

func (c *ClusterContext) ClusterRF() string

ClusterRF fetches replication factor of the cluster

func (*ClusterContext) DiskIops

func (c *ClusterContext) DiskIops() string

DiskIops fetches DiskIops

func (*ClusterContext) InstanceType

func (c *ClusterContext) InstanceType() string

InstanceType fetches instance type

func (*ClusterContext) LinuxVersion

func (c *ClusterContext) LinuxVersion() string

LinuxVersion fetches linux version

func (*ClusterContext) MarshalJSON

func (c *ClusterContext) MarshalJSON() ([]byte, error)

MarshalJSON function

func (*ClusterContext) MasterDiskIops

func (c *ClusterContext) MasterDiskIops() string

MasterDiskIops fetches num vols

func (*ClusterContext) MasterGFlags

func (c *ClusterContext) MasterGFlags() string

MasterGFlags fetches map as string

func (*ClusterContext) MasterInstanceType

func (c *ClusterContext) MasterInstanceType() string

MasterInstanceType fetches instance type

func (*ClusterContext) MasterNumVolumes

func (c *ClusterContext) MasterNumVolumes() string

MasterNumVolumes fetches num vols

func (*ClusterContext) MasterStorageClass

func (c *ClusterContext) MasterStorageClass() string

MasterStorageClass fetches StorageClass

func (*ClusterContext) MasterStorageType

func (c *ClusterContext) MasterStorageType() string

MasterStorageType fetches StorageType

func (*ClusterContext) MasterThroughput

func (c *ClusterContext) MasterThroughput() string

MasterThroughput fetches throughput

func (*ClusterContext) MasterVolumeSize

func (c *ClusterContext) MasterVolumeSize() string

MasterVolumeSize fetches vol size

func (*ClusterContext) NumVolumes

func (c *ClusterContext) NumVolumes() string

NumVolumes fetches no vols

func (*ClusterContext) SetCluster

func (c *ClusterContext) SetCluster(cluster ybaclient.Cluster)

SetCluster initializes the context with the cluster data

func (*ClusterContext) SpecificGFlags

func (c *ClusterContext) SpecificGFlags() string

SpecificGFlags for formatting output

func (*ClusterContext) StorageClass

func (c *ClusterContext) StorageClass() string

StorageClass fetches StorageClass

func (*ClusterContext) StorageType

func (c *ClusterContext) StorageType() string

StorageType fetches StorageType

func (*ClusterContext) TServerGFlags

func (c *ClusterContext) TServerGFlags() string

TServerGFlags fetches map as string

func (*ClusterContext) Throughput

func (c *ClusterContext) Throughput() string

Throughput fetches Throughput

func (*ClusterContext) UUID

func (c *ClusterContext) UUID() string

UUID fetches Cluster UUID

func (*ClusterContext) UserTags

func (c *ClusterContext) UserTags() string

UserTags fetches map as string

func (*ClusterContext) VolumeSize

func (c *ClusterContext) VolumeSize() string

VolumeSize fetches vol size

func (*ClusterContext) Write

func (c *ClusterContext) Write(index int) error

Write populates the output table to be displayed in the command line

type Context

type Context struct {
	formatter.HeaderContext
	formatter.Context
	// contains filtered or unexported fields
}

Context for universe outputs

func NewUniverseContext

func NewUniverseContext() *Context

NewUniverseContext creates a new context for rendering universe

func (*Context) AZOverrides

func (c *Context) AZOverrides() string

AZOverrides for kubernetes universes

func (*Context) AccessKey

func (c *Context) AccessKey() string

AccessKey fetches the Cloud provider used in the universe

func (*Context) CPUArchitecture

func (c *Context) CPUArchitecture() string

CPUArchitecture fetches CPU architecture of the universe

func (*Context) CtoNCert

func (c *Context) CtoNCert() string

CtoNCert fetches cton certificate

func (*Context) CtoNTLS

func (c *Context) CtoNTLS() string

CtoNTLS fetches if ctontls is enabled

func (*Context) DedicatedMasters

func (c *Context) DedicatedMasters() string

DedicatedMasters fetches if master is placed on a dedicated node

func (*Context) EnableYCQL

func (c *Context) EnableYCQL() string

EnableYCQL fetches if ycql is enabled

func (*Context) EnableYSQL

func (c *Context) EnableYSQL() string

EnableYSQL fetches if ysql is enabled

func (*Context) EncryptionRestType

func (c *Context) EncryptionRestType() string

EncryptionRestType fetches type of encrytipn key

func (*Context) KMSConfig

func (c *Context) KMSConfig() string

KMSConfig fetches KMS config name

func (*Context) KMSEnabled

func (c *Context) KMSEnabled() string

KMSEnabled fetches if KMS is enabled or not

func (*Context) LiveNodes

func (c *Context) LiveNodes() string

LiveNodes counts the number of live nodes in the universe

func (*Context) MarshalJSON

func (c *Context) MarshalJSON() ([]byte, error)

MarshalJSON function

func (*Context) Name

func (c *Context) Name() string

Name fetches Universe Name

func (*Context) Nodes

func (c *Context) Nodes() string

Nodes fetches the no. of nodes

func (*Context) NtoNCert

func (c *Context) NtoNCert() string

NtoNCert fetches nton certificate

func (*Context) NtoNTLS

func (c *Context) NtoNTLS() string

NtoNTLS fetches if ntontls is enabled

func (*Context) NumMasters

func (c *Context) NumMasters() string

NumMasters prints number of masters in given universe

func (*Context) NumTservers

func (c *Context) NumTservers() string

NumTservers prints number of tservers in given universe

func (*Context) PricePerDay

func (c *Context) PricePerDay() string

PricePerDay fetches the universe instance price per day

func (*Context) ProviderCode

func (c *Context) ProviderCode() string

ProviderCode fetches the Cloud provider used in the universe

func (*Context) ProviderUUID

func (c *Context) ProviderUUID() string

ProviderUUID fetches the Cloud provider used in the universe

func (*Context) RF

func (c *Context) RF() string

RF fetches replication factor of the primary cluster

func (*Context) State

func (c *Context) State() string

State fetches the state of the universe

func (*Context) UUID

func (c *Context) UUID() string

UUID fetches Universe UUID

func (*Context) UniverseOverrides

func (c *Context) UniverseOverrides() string

UniverseOverrides for kubernetes universes

func (*Context) UseSystemd

func (c *Context) UseSystemd() string

UseSystemd fetches the Cloud provider used in the universe

func (*Context) Version

func (c *Context) Version() string

Version fetches YBDB of the primary cluster

func (*Context) YCQLAuthEnabled

func (c *Context) YCQLAuthEnabled() string

YCQLAuthEnabled fetches password of the primary cluster

func (*Context) YSQLAuthEnabled

func (c *Context) YSQLAuthEnabled() string

YSQLAuthEnabled fetches password of the primary cluster

type FullUniverseContext

type FullUniverseContext struct {
	formatter.HeaderContext
	formatter.Context
	// contains filtered or unexported fields
}

FullUniverseContext to render Universe Details output

func NewFullUniverseContext

func NewFullUniverseContext() *FullUniverseContext

NewFullUniverseContext creates a new context for rendering universe

func (*FullUniverseContext) MarshalJSON

func (fu *FullUniverseContext) MarshalJSON() ([]byte, error)

MarshalJSON function

func (*FullUniverseContext) SetFullUniverse

func (fu *FullUniverseContext) SetFullUniverse(universe ybaclient.UniverseResp)

SetFullUniverse initializes the context with the universe data

func (*FullUniverseContext) Write

func (fu *FullUniverseContext) Write() error

Write populates the output table to be displayed in the command line

type NodeContext

type NodeContext struct {
	formatter.HeaderContext
	formatter.Context
	// contains filtered or unexported fields
}

NodeContext for node outputs

func NewNodeContext

func NewNodeContext() *NodeContext

NewNodeContext creates a new context for rendering node

func (*NodeContext) IP

func (c *NodeContext) IP() string

IP of the node

func (*NodeContext) IsMaster

func (c *NodeContext) IsMaster() string

IsMaster status of the node

func (*NodeContext) IsTserver

func (c *NodeContext) IsTserver() string

IsTserver status of the node

func (*NodeContext) MarshalJSON

func (c *NodeContext) MarshalJSON() ([]byte, error)

MarshalJSON function

func (*NodeContext) MasterState

func (c *NodeContext) MasterState() string

MasterState of the node

func (*NodeContext) NodeName

func (c *NodeContext) NodeName() string

NodeName of the node

func (*NodeContext) NodeUUID

func (c *NodeContext) NodeUUID() string

NodeUUID of the node

func (*NodeContext) State

func (c *NodeContext) State() string

State of the node

type RegionContext

type RegionContext struct {
	formatter.HeaderContext
	formatter.Context
	// contains filtered or unexported fields
}

RegionContext for region outputs

func NewRegionContext

func NewRegionContext() *RegionContext

NewRegionContext creates a new context for rendering regions

func (*RegionContext) Code

func (r *RegionContext) Code() string

Code fetches Region Code

func (*RegionContext) LoadBalancerFQDN

func (r *RegionContext) LoadBalancerFQDN() string

LoadBalancerFQDN fetches FQDN

func (*RegionContext) MarshalJSON

func (r *RegionContext) MarshalJSON() ([]byte, error)

MarshalJSON function

func (*RegionContext) Name

func (r *RegionContext) Name() string

Name fetches Region Name

func (*RegionContext) SetRegion

func (r *RegionContext) SetRegion(region ybaclient.PlacementRegion)

SetRegion initializes the context with the region data

func (*RegionContext) UUID

func (r *RegionContext) UUID() string

UUID fetches Region UUID

func (*RegionContext) Write

func (r *RegionContext) Write(index int) error

Write populates the output table to be displayed in the command line

type ZoneContext

type ZoneContext struct {
	formatter.HeaderContext
	formatter.Context
	// contains filtered or unexported fields
}

ZoneContext for zone outputs

func NewZoneContext

func NewZoneContext() *ZoneContext

NewZoneContext creates a new context for rendering zones

func (*ZoneContext) AzNumNodes

func (z *ZoneContext) AzNumNodes() string

AzNumNodes fetches number of nodes in AZ

func (*ZoneContext) AzRF

func (z *ZoneContext) AzRF() string

AzRF fetches rf in AZ

func (*ZoneContext) MarshalJSON

func (z *ZoneContext) MarshalJSON() ([]byte, error)

MarshalJSON function

func (*ZoneContext) Name

func (z *ZoneContext) Name() string

Name fetches Zone Name

func (*ZoneContext) SetZone

func (z *ZoneContext) SetZone(zone ybaclient.PlacementAZ)

SetZone initializes the context with the zone data

func (*ZoneContext) Subnet

func (z *ZoneContext) Subnet() string

Subnet fetches Zone Subnet

func (*ZoneContext) UUID

func (z *ZoneContext) UUID() string

UUID fetches Zone UUID

func (*ZoneContext) Write

func (z *ZoneContext) Write(index int) error

Write populates the output table to be displayed in the command line

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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