sizing

package
v2.0.0 Latest Latest
Warning

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

Go to latest
Published: Jun 14, 2023 License: AGPL-3.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var NodeTypesByProvider = map[string]map[string]NodeType{
	"AWS": {
		"t2.xlarge": {
			// contains filtered or unexported fields
		},
		"t2.2xlarge": {
			// contains filtered or unexported fields
		},
		"t2.4xlarge": {
			// contains filtered or unexported fields
		},
	},
	"GCP": {
		"e2-standard-4": {
			// contains filtered or unexported fields
		},
		"e2-standard-8": {
			// contains filtered or unexported fields
		},
		"e2-standard-16": {
			// contains filtered or unexported fields
		},
	},
	"OVHcloud": {
		"b2-30": {
			// contains filtered or unexported fields
		},
		"b2-60": {
			// contains filtered or unexported fields
		},
		"b2-120": {
			// contains filtered or unexported fields
		},
	},
}
View Source
var StandardRead = NodePod{
	// contains filtered or unexported fields
}
View Source
var StandardWrite = NodePod{
	// contains filtered or unexported fields
}

Functions

This section is empty.

Types

type ClusterSize

type ClusterSize struct {
	TotalNodes         int
	TotalReadReplicas  int
	TotalWriteReplicas int
	TotalCoresRequest  float64
	TotalMemoryRequest int
	// contains filtered or unexported fields
}

type Handler

type Handler struct {
	// contains filtered or unexported fields
}

Handler defines the REST API of the sizing tool.

func NewHandler

func NewHandler(logger log.Logger) *Handler

func (*Handler) Cluster

func (h *Handler) Cluster(w http.ResponseWriter, req *http.Request)

func (*Handler) GenerateHelmValues

func (h *Handler) GenerateHelmValues(w http.ResponseWriter, req *http.Request)

func (*Handler) Nodes

func (h *Handler) Nodes(w http.ResponseWriter, _ *http.Request)

type Loki

type Loki struct {
	AuthEnabled bool `json:"auth_enabled"`
}

type Message

type Message struct {
	NodeType         NodeType
	Ingest           int
	Retention        int
	QueryPerformance QueryPerf
}

type NodePod

type NodePod struct {
	// contains filtered or unexported fields
}

type NodeType

type NodeType struct {
	// contains filtered or unexported fields
}

type Pod

type Pod struct {
	Replicas int `json:"replicas"`
	Rate     int `json:"rate"`
	CPU      struct {
		Request float64 `json:"request"`
		Limit   float64 `json:"limit"`
	} `json:"cpu"`
	Memory struct {
		Request int `json:"request"`
		Limit   int `json:"limit"`
	} `json:"memory"`
}

type QueryPerf

type QueryPerf string
const (
	Basic QueryPerf = "basic"
	Super QueryPerf = "super"
)

type Read

type Read struct {
	Replicas  int       `json:"replicas"`
	Resources Resources `json:"resources"`
}

type Resources

type Resources struct {
	Requests struct {
		CPU    float64 `json:"cpu"`
		Memory int     `json:"memory"`
	} `json:"requests"`
	Limits struct {
		CPU    float64 `json:"cpu"`
		Memory int     `json:"memory"`
	} `json:"limits"`
}

type Values

type Values struct {
	Loki  Loki  `json:"loki"`
	Read  Read  `json:"read"`
	Write Write `json:"write"`
}

type Write

type Write struct {
	Replicas  int       `json:"replicas"`
	Resources Resources `json:"resources"`
}

Jump to

Keyboard shortcuts

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