teb

package
v0.0.0-...-d7b55dd Latest Latest
Warning

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

Go to latest
Published: May 9, 2026 License: MIT Imports: 21 Imported by: 0

Documentation

Overview

Package teb contains templates and (templated) tables to format CLI output.

  • Copyright (c) 2018-2026, NVIDIA CORPORATION. All rights reserved.

Package teb contains templates and (templated) tables to format CLI output.

  • Copyright (c) 2026, NVIDIA CORPORATION. All rights reserved.

Package teb contains templates and (templated) tables to format CLI output.

  • Copyright (c) 2018-2026, NVIDIA CORPORATION. All rights reserved.

Package teb contains templates and (templated) tables to format CLI output.

  • Copyright (c) 2018-2026, NVIDIA CORPORATION. All rights reserved.

Package teb contains templates and (templated) tables to format CLI output.

  • Copyright (c) 2018-2025, NVIDIA CORPORATION. All rights reserved.

Package teb contains templates and (templated) tables to format CLI output.

  • Copyright (c) 2018-2025, NVIDIA CORPORATION. All rights reserved.

Package teb contains templates and (templated) tables to format CLI output.

  • Copyright (c) 2023-2026, NVIDIA CORPORATION. All rights reserved.

Package teb contains templates and (templated) tables to format CLI output.

  • Copyright (c) 2018-2026, NVIDIA CORPORATION. All rights reserved.

Package teb contains templates and (templated) tables to format CLI output.

  • Copyright (c) 2018-2026, NVIDIA CORPORATION. All rights reserved.

Package teb contains templates and (templated) tables to format CLI output.

  • Copyright (c) 2024-2025, NVIDIA CORPORATION. All rights reserved.

Package teb contains templates and (templated) tables to format CLI output.

  • Copyright (c) 2023-2026, NVIDIA CORPORATION. All rights reserved.

Package teb contains templates and (templated) tables to format CLI output.

  • Copyright (c) 2018-2026, NVIDIA CORPORATION. All rights reserved.

Package teb contains templates and (templated) tables to format CLI output.

  • Copyright (c) 2018-2026, NVIDIA CORPORATION. All rights reserved.

Package teb contains templates and (templated) tables to format CLI output.

  • Copyright (c) 2018-2026, NVIDIA CORPORATION. All rights reserved.

Package teb contains templates and (templated) tables to format CLI output.

  • Copyright (c) 2018-2026, NVIDIA CORPORATION. All rights reserved.

Index

Constants

View Source
const (
	NotSetVal = "-"

	UnknownStatusVal = "n/a"
)
View Source
const (
	ClusterTotal = "--- Cluster:"
	TargetTotal  = "------- Sum:"
)
View Source
const (
	ScrObjects = iota
	ScrNotIn
	ScrMisplacedNode
	ScrMisplacedMpath
	ScrMissingCp
	ScrSmallSz
	ScrLargeSz
	ScrVchanged
	ScrVremoved

	ScrNumStats // NOTE: must be the last
)
View Source
const (
	SmapTmpl = smapHdr + "{{ range $key, $value := .Smap.Pmap }}" + smapNode + "{{end}}\n" +
		smapHdr + smapBody

	SmapTmplNoHdr = "{{ range $key, $value := .Smap.Pmap }}" + smapNode + "{{end}}\n" + smapBody

	ClusterSummary = indent1 + "CLI Endpoint:\t{{.Endpoint}}\n" +
		indent1 + "Proxies:\t{{FormatProxiesSumm .Smap}}\n" +
		indent1 + "Targets:\t{{FormatTargetsSumm .Smap .NumDisks}}\n" +
		indent1 + "Capacity:\t{{.Capacity}}\n" +
		indent1 + "Cluster Map:\t{{FormatSmap .Smap}}\n" +
		indent1 + "Software:\t{{FormatCluSoft .Version .BuildTime}}\n" +
		indent1 + "Backend:\t{{.Backend}}\n" +
		indent1 + "Deployment:\t{{ ( Deployments .Stst) }}\n" +
		indent1 + "Status:\t{{ ( OnlineStatus .Stst) }}\n" +
		indent1 + "Rebalance:\t{{FormatRebalance .Stst .CluConfig}}\n" +
		indent1 + "Authentication:\t{{if .CluConfig.Auth.Enabled}}enabled{{else}}disabled{{end}}\n" +
		indent1 + "Version:\t{{ ( Versions .Stst) }}\n" +
		indent1 + "Build:\t{{ ( BuildTimes .Stst) }}\n"

	DaemonConfigTmpl      = daemonConfigHdr + daemonConfigBody
	DaemonConfigTmplNoHdr = daemonConfigBody

	PropValTmpl      = propValTmplHdr + PropValTmplNoHdr
	PropValTmplNoHdr = "{{range $p := . }}" + "{{$p.Name}}\t {{$p.Value}}\n" + "{{end}}"

	ObjLockTmpl      = objLockTmplHdr + ObjLockTmplNoHdr
	ObjLockTmplNoHdr = "{{range $o := . }}" + "{{$o.Name}}\t {{$o.Status}}\n" + "{{end}}"

	// 3-column: FEATURE | TAGS | DESCRIPTION
	FeatTagsDescTmplHdr = "FEATURE\t TAGS\t DESCRIPTION\n"
)
View Source
const (
	DownloadListNoHdrTmpl = "{{ range $key, $value := . }}" + downloadListBody + "{{end}}"
	DownloadListTmpl      = downloadListHdr + DownloadListNoHdrTmpl

	DsortListNoHdrTmpl = "{{ range $value := . }}" + dsortListBody + "{{end}}"
	DsortListTmpl      = dsortListHdr + DsortListNoHdrTmpl

	DsortListVerboseTmpl = dsortListHdr +
		"{{ range $value := . }}" + dsortListBody +
		indent1 + "Total Extracted Bytes:\t{{if (eq $value.Bytes 0) }}-{{else}}{{FormatBytesSig $value.Bytes 2}}{{end}}\n" +
		indent1 + "Extraction Time:\t{{if (eq $value.ExtractedDuration 0) }}-{{else}}{{FormatDuration $value.ExtractedDuration}}{{end}}\n" +
		indent1 + "Sorting Time:\t{{if (eq $value.SortingDuration 0) }}-{{else}}{{FormatDuration $value.SortingDuration}}{{end}}\n" +
		indent1 + "Creation Time:\t{{if (eq $value.CreationDuration 0) }}-{{else}}{{FormatDuration $value.CreationDuration}}{{end}}\n" +
		indent1 + "Description:\t{{$value.Metrics.Description}}\n" +
		"{{end}}"
)

extensions: download & dsort

View Source
const (
	ETLListHdr  = "NAME\t STAGE\t XACTION\t OBJECTS\n"
	ETLListBody = "{{$value.Name}}\t {{$value.Stage}}\t {{$value.XactID}}\t " +
		"{{if (eq $value.ObjCount 0) }}-{{else}}{{$value.ObjCount}}{{end}}\n"
	ETLListNoHdrTmpl = "{{ range $value := . }}" + ETLListBody + "{{end}}"
	ETLListTmpl      = ETLListHdr + ETLListNoHdrTmpl

	ETLObjErrorsHdr       = "OBJECT\t ECODE\t ERROR\n"
	ETLObjErrorsBody      = "{{$value.ObjName}}\t {{$value.Ecode}}\t {{$value.Message}}\n"
	ETLObjErrorsNoHdrTmpl = "{{ range $value := . }}" + ETLObjErrorsBody + "{{end}}"
	ETLObjErrorsTmpl      = ETLObjErrorsHdr + ETLObjErrorsNoHdrTmpl
)

ETL

View Source
const (
	XactColTotals = "Total:" // total OBJECTS\t BYTES\t (see "Total:" below)

	XactBucketTmpl      = xactBucketHdr + XactNoHdrBucketTmpl
	XactNoHdrBucketTmpl = "{{range $nodeSnaps := . }}" + xactBucketBodyAll + "{{end}}"

	XactNoBucketTmpl      = xactNoBucketHdr + XactNoHdrNoBucketTmpl
	XactNoHdrNoBucketTmpl = "{{range $nodeSnaps := . }}" + xactNoBucketBodyAll + "{{end}}"

	XactFromToTmpl      = xactFromToHdr + XactNoHdrFromToTmpl
	XactNoHdrFromToTmpl = "{{range $nodeSnaps := . }}" + xactFromToBodyAll + "{{end}}"

	XactECGetTmpl      = xactECGetStatsHdr + XactECGetNoHdrTmpl
	XactECGetNoHdrTmpl = "{{range $nodeSnaps := . }}" + xactECGetBody + "{{end}}"

	XactECPutTmpl      = xactECPutStatsHdr + XactECPutNoHdrTmpl
	XactECPutNoHdrTmpl = "{{range $nodeSnaps := . }}" + xactECPutBody + "{{end}}"

	// rebalance: tx/rx split
	XactRebalanceTmpl      = xactRebalanceHdr + XactRebalanceNoHdrTmpl
	XactRebalanceNoHdrTmpl = "{{range $nodeSnaps := . }}" + xactRebalanceBodyAll + "{{end}}"

	// list objects
	XactListRemoteTmpl      = xactListRemoteHdr + XactListRemoteNoHdrTmpl
	XactListRemoteNoHdrTmpl = "{{range $nodeSnaps := . }}" + xactListRemoteBodyAll + "{{end}}"
)

xactions

View Source
const (
	ListBucketsSummBody = "{{range $k, $v := . }}" +
		"{{FormatBckName $v.Bck}}\t {{FormatBool $v.Info.IsBckPresent}}\t " +
		"{{$v.Info.ObjCount.Present}} {{$v.Info.ObjCount.Remote}}\t " +
		"{{FormatBytesUns $v.Info.TotalSize.OnDisk 2}} {{FormatBytesUns $v.Info.TotalSize.PresentObjs 2}} {{FormatBytesUns $v.Info.TotalSize.RemoteObjs 2}}\t " +
		"{{if (IsFalse $v.Info.IsBckPresent)}}-{{else}}{{$v.Info.UsedPct}}%{{end}}\n" +
		"{{end}}"
	ListBucketsSummTmpl = listBucketsSummHdr + ListBucketsSummBody

	ListBucketsHdrNoSummary  = "NAME\t PRESENT\n"
	ListBucketsBodyNoSummary = "{{range $k, $v := . }}" +
		"{{FormatBckName $v.Bck}}\t {{FormatBool $v.Info.IsBckPresent}}\n" +
		"{{end}}"
	ListBucketsTmplNoSummary = ListBucketsHdrNoSummary + ListBucketsBodyNoSummary

	// Bucket summary templates
	BucketsSummariesTmpl = "NAME\t OBJECTS (cached, remote)\t OBJECT SIZES (min, avg, max)\t TOTAL OBJECT SIZE (cached, remote)\t USAGE(%)\n" +
		BucketsSummariesBody
	BucketsSummariesBody = "{{range $k, $v := . }}" +
		"{{FormatBckName $v.Bck}}\t {{$v.ObjCount.Present}} {{$v.ObjCount.Remote}}\t " +
		"{{FormatMAM $v.ObjSize.Min}} {{FormatMAM $v.ObjSize.Avg}} {{FormatMAM $v.ObjSize.Max}}\t " +
		"{{FormatBytesUns $v.TotalSize.PresentObjs 2}} {{FormatBytesUns $v.TotalSize.RemoteObjs 2}}\t {{$v.UsedPct}}%\n" +
		"{{end}}"

	// For `object put` mass uploader. A caller adds to the template
	// total count and size. That is why the template ends with \t
	MultiPutTmpl = "Files to upload:\nEXTENSION\t COUNT\t SIZE\n" +
		"{{range $k, $v := . }}" +
		"{{$k}}\t {{$v.Cnt}}\t {{FormatBytesSig $v.Size 2}}\n" +
		"{{end}}" +
		"TOTAL\t "

	ExtendedUsageTmpl = "{{if .UsageText}}{{.UsageText}}{{else}}{{.HelpName}}{{if .VisibleFlags}} [command options]{{end}} {{if .ArgsUsage}}{{.ArgsUsage}}{{else}}[arguments...]{{end}}{{end}} - {{.Usage}}\n" +
		"\n\tCOMMANDS:\t" +
		"{{range .VisibleCategories}}" +
		"{{ range $index, $element := .VisibleCommands}}" +
		"{{if $index}}, {{end}}" +
		"{{if ( eq ( Mod $index 13 ) 12 ) }}\n\t\t{{end}}" +
		"{{$element.Name}}" +
		"{{if ( eq $element.Name \"search\" ) }}\n\t\t{{end}}" +
		"{{end}}{{end}}\n" +
		"{{if .VisibleFlags}}\tOPTIONS:\t" +
		"{{ range $index, $flag := .VisibleFlags}}" +
		"{{if $index}}, {{end}}" +
		"--{{FlagName $flag }}" +
		"{{end}}{{end}}\n"

	ShortUsageTmpl = `{{.HelpName}} - {{.Usage}}
   {{.UsageText}}
USAGE:
   {{.HelpName}} {{.ArgsUsage}}

See '--help' and docs/cli for details.`
)
View Source
const (
	AuthNClusterTmpl = "CLUSTER ID\tALIAS\tURLs\n" +
		"{{ range $clu := . }}" +
		"{{ $clu.ID }}\t{{ $clu.Alias }}\t{{ JoinList $clu.URLs }}\n" +
		"{{end}}"

	AuthNRoleTmpl = "ROLE\tDESCRIPTION\n" +
		"{{ range $role := . }}" +
		"{{ $role.Name }}\t{{ $role.Description }}\n" +
		"{{end}}"

	AuthNUserTmpl = "NAME\tROLES\n" +
		"{{ range $user := . }}" +
		"{{ $user.ID }}\t{{ range $i, $role := $user.Roles }}" +
		"{{ if $i }}, {{ end }}{{ $role.Name }}" +
		"{{end}}\n" +
		"{{end}}"

	AuthNUserVerboseTmpl = "Name\t{{ .ID }}\n" +
		"Roles\t{{ range $i, $role := .Roles }}{{ if $i }}, {{ end }}{{ $role.Name }}{{ end }}\n" +
		"{{ range $role := .Roles }}" +
		"{{ if ne (len $role.ClusterACLs) 0 }}" +
		"CLUSTER ID\tALIAS\tPERMISSIONS\n" +
		"{{ range $clu := $role.ClusterACLs }}" +
		"{{ $clu.ID }}\t{{ $clu.Alias }}\t{{ FormatACL $clu.Access }}\n" +
		"{{end}}{{end}}" +
		"{{ if ne (len $role.BucketACLs) 0 }}" +
		"BUCKET\tPERMISSIONS\n" +
		"{{ range $bck := $role.BucketACLs }}" +
		"{{ FormatBckName $bck.Bck }}\t{{ FormatACL $bck.Access }}\n" +
		"{{end}}{{end}}" +
		"{{ end }}"

	AuthNRoleVerboseTmpl = "Role\t{{ .Name }}\n" +
		"Description\t{{ .Description }}\n" +
		"{{ if ne (len .ClusterACLs) 0 }}" +
		"CLUSTER ID\tALIAS\tPERMISSIONS\n" +
		"{{ range $clu := .ClusterACLs }}" +
		"{{ $clu.ID }}\t{{ $clu.Alias }}\t{{ FormatACL $clu.Access }}\n" +
		"{{end}}{{end}}" +
		"{{ if ne (len .BucketACLs) 0 }}" +
		"BUCKET\tPERMISSIONS\n" +
		"{{ range $bck := .BucketACLs }}" +
		"{{ FormatBckName $bck.Bck }}\t{{ FormatACL $bck.Access }}\n" +
		"{{end}}{{end}}"
)
View Source
const (
	NBITmpl = "BUCKET\t NAME\t SIZE\t OBJECTS\t STARTED\t FINISHED\t PREFIX\n" +
		"{{range $v := .}}" +
		"{{$v.Bucket}}\t " +
		"{{$v.Name}}\t " +
		"{{FormatBytesSig $v.Size 2}}\t " +
		"{{if $v.Ntotal}}{{$v.Ntotal}}{{else}}-{{end}}\t " +
		"{{FormatUnixNano $v.Started}}\t " +
		"{{FormatUnixNano $v.Finished}}\t " +
		"{{if $v.Prefix}}{{$v.Prefix}}{{else}}-{{end}}\n" +
		"{{end}}"

	NBITmplVerbose = "BUCKET\t NAME\t OBJECT\t SIZE\t OBJECTS\t CHUNKS\t TARGETS\t SMAP\t STARTED\t FINISHED\t PREFIX\n" +
		"{{range $v := .}}" +
		"{{$v.Bucket}}\t " +
		"{{$v.Name}}\t " +
		"{{$v.ObjName}}\t " +
		"{{FormatBytesSig $v.Size 2}}\t " +
		"{{if $v.Ntotal}}{{$v.Ntotal}}{{else}}-{{end}}\t " +
		"{{if $v.Chunks}}{{$v.Chunks}}{{else}}-{{end}}\t " +
		"{{if $v.Nat}}{{$v.Nat}}{{else}}-{{end}}\t " +
		"{{if $v.SmapVer}}v{{$v.SmapVer}}{{else}}-{{end}}\t " +
		"{{FormatUnixNano $v.Started}}\t " +
		"{{FormatUnixNano $v.Finished}}\t " +
		"{{if $v.Prefix}}{{$v.Prefix}}{{else}}-{{end}}\n" +
		"{{end}}"
)
View Source
const (
	MpathListTmpl = "{{range $p := . }}" +
		"{{ $p.DaemonID }}\n" +
		"{{if and (eq (len $p.Mpl.Available) 0) (eq (len $p.Mpl.Disabled) 0)}}" +
		"\tNo mountpaths\n" +
		"{{else}}" +
		"{{if ne (len $p.Mpl.Available) 0}}" +
		"\tUsed: {{FormatCapPctMAM $p.Tcdf true}}\t " +
		"{{if (IsEqS $p.Tcdf.CsErr \"\")}}{{else}}{{$p.Tcdf.CsErr}}{{end}}\n" +
		"{{range $mp := $p.Mpl.Available }}" +
		"\t\t{{ $mp }} " +

		"{{range $k, $v := $p.Tcdf.Mountpaths}}" +
		"{{if (IsEqS $k $mp)}}{{FormatCDFDisks $v}}{{end}}" +
		"{{end}}\n" +

		"{{end}}{{end}}" +

		"{{if ne (len $p.Mpl.Disabled) 0}}" +
		"\tDisabled:\n" +
		"{{range $mp := $p.Mpl.Disabled }}" +
		"\t\t{{ $mp }}\n" +
		"{{end}}{{end}}" +
		"{{if ne (len $p.Mpl.WaitingDD) 0}}" +
		"\tTransitioning to disabled or detached pending resilver:\n" +
		"{{range $mp := $p.Mpl.WaitingDD }}" +
		"\t\t{{ $mp }}\n" +
		"{{end}}{{end}}" +
		"{{end}}{{end}}"
)

'show mountpath'

View Source
const (
	NodeOnline = "online"
)
View Source
const (
	SearchTmpl = "{{ JoinListNL . }}\n"
)

`search`

Variables

View Source
var (
	ScrCols = [...]string{colObjects, colNotIn, colMisplacedNode, colMisplacedMpath, colMissingCp, colSmallSz, colLargeSz, colVchanged, colVremoved}
	ScrNums = [ScrNumStats]int64{}
)
View Source
var (
	AliasTemplate = "ALIAS\tCOMMAND\n" +
		"=====\t=======\n" +
		"{{range $alias := .}}" +
		"{{ $alias.Name }}\t{{ $alias.Value }}\n" +
		"{{end}}"
)
View Source
var (
	// ObjectPropsMap matches ObjEntry field
	ObjectPropsMap = map[string]string{
		apc.GetPropsName:     "{{FormatEntryNameDAC $obj.Name $obj.Flags}}",
		apc.GetPropsSize:     "{{FormatBytesSig2 $obj.Size 2 $obj.Flags}}",
		apc.GetPropsChecksum: "{{$obj.Checksum}}",
		apc.GetPropsAtime:    "{{$obj.Atime}}",
		apc.GetPropsVersion:  "{{$obj.Version}}",
		apc.GetPropsLocation: "{{$obj.Location}}",
		apc.GetPropsCustom:   "{{FormatObjCustom $obj.Custom}}",
		apc.GetPropsStatus:   "{{FormatLsObjStatus $obj}}",
		apc.GetPropsCopies:   "{{$obj.Copies}}",
		apc.GetPropsCached:   "{{FormatLsObjIsCached $obj}}",
		// contains filtered or unexported fields
	}
)
View Source
var Writer io.Writer

Functions

func FmtBool

func FmtBool(t bool) string

FmtBool returns "yes" if true, else "no"

func FmtChunked

func FmtChunked(count int, maxSize int64) string

func FmtCopies

func FmtCopies(copies int) string

FmtCopies formats an int to a string, where 0 becomes "-"

func FmtDateTime

func FmtDateTime(t time.Time) (s string)

func FmtDuration

func FmtDuration(ns int64, units string) string

func FmtEC

func FmtEC(gen int64, data, parity int, isCopy bool) string

FmtEC formats EC data (DataSlices, ParitySlices, IsECCopy) into a readable string for CLI, e.g. "1:2[encoded]"

func FmtNodeStatus

func FmtNodeStatus(node *meta.Snode) (status string)

func FmtSize

func FmtSize(size int64, units string, digits int) string

func FmtStatValue

func FmtStatValue(name, kind string, value int64, units string) string

(with B, ns, and /s suffix)

func FmtTime

func FmtTime(t time.Time) (s string)

func FmtXactRunFinAbrt

func FmtXactRunFinAbrt(snap *core.Snap) (s string)

func FormatDuration

func FormatDuration(d time.Duration) string

round to an assorted set of multiples

func FuncMapUnits

func FuncMapUnits(units string, datedTime bool) (m template.FuncMap)

func Init

func Init(w io.Writer, noColor bool)

func LsoTemplate

func LsoTemplate(propsList []string, hideHeader, addCachedCol, addStatusCol, addChunkedCol bool) string

func MakeTabCPU

func MakeTabCPU(smap *meta.Smap, pmap, tmap NodeStatusMap) (*Table, *Table)

`ais show cluster cpu` - proxy and target tables USER/SYSTEM/TOTAL jiffies omitted; PROC CPU(%) subsumes them THROTTLED hidden when zero across both maps

func MakeTabMem

func MakeTabMem(smap *meta.Smap, pmap, tmap NodeStatusMap, units string) (*Table, *Table)

`ais show cluster memory` - proxy and target tables SWAP columns hidden together when SwapTotal==0 across both maps PROC SHARED and BUFF/CACHE hidden when all-zero

func Print

func Print(object any, templ string, aux ...Opts) error

main func

func ValidateUnits

func ValidateUnits(units string) error

Types

type ClusterTabOpts

type ClusterTabOpts struct {
	Units      string
	Verbose    bool
	ShowSysCPU bool
	ShowLoad   bool
}

type CntSiz

type CntSiz struct {
	Cnt int64
	Siz int64
}

type DiskStatsHelper

type DiskStatsHelper struct {
	TargetID string
	DiskName string
	Stat     cos.DiskStats
	Tcdf     *fs.Tcdf
}

type ListBucketsHelper

type ListBucketsHelper struct {
	XactID string
	Bck    cmn.Bck
	Props  *cmn.Bprops
	Info   *cmn.BsummResult
}

type NodeStatusMap

type NodeStatusMap map[string]*stats.NodeStatus // by node ID (SID)

type Opts

type Opts struct {
	AltMap  template.FuncMap
	Units   string
	UseJSON bool
}

auxiliary

func Jopts

func Jopts(usejs bool) Opts

type PerfTabCtx

type PerfTabCtx struct {
	Smap          *meta.Smap
	Sid           string           // single target, unless ""
	Metrics       cos.StrKVs       // metric (aka stats) names and kinds
	Regex         *regexp.Regexp   // filter column names (case-insensitive)
	Units         string           // IEC, SI, raw
	Totals        map[string]int64 // per-metric column sums (metric name => cluster-wide total)
	TotalsHdr     string
	DropGroupName string // e.g. "stream"; if non-empty, columns in this group drop the group prefix
	AvgSize       bool   // compute average size on the fly (and show it), e.g.: `get.size/get.n`
	Idle          bool   // currently idle
	NoColor       bool
}

func (*PerfTabCtx) MakeTab

func (c *PerfTabCtx) MakeTab(st NodeStatusMap) (*Table, int, error)

return numNZ (non-zero) metrics OR bad status

type ScrBp

type ScrBp struct {
	Bck    cmn.Bck
	Prefix string
	Stats  [ScrNumStats]CntSiz
	// work
	Line  cos.SB
	Cname string
}

type ScrubHelper

type ScrubHelper struct {
	All []*ScrBp
}

func (*ScrubHelper) MakeTab

func (h *ScrubHelper) MakeTab(units string, haveRemote, allColumns bool) *Table

type SmapHelper

type SmapHelper struct {
	Smap         *meta.Smap
	ExtendedURLs bool
}

type StatsAndStatusHelper

type StatsAndStatusHelper struct {
	Pmap NodeStatusMap
	Tmap NodeStatusMap
}

func (*StatsAndStatusHelper) MakeTabP

func (h *StatsAndStatusHelper) MakeTabP(smap *meta.Smap, opts ClusterTabOpts) *Table

proxy(ies)

func (*StatsAndStatusHelper) MakeTabT

func (h *StatsAndStatusHelper) MakeTabT(smap *meta.Smap, opts ClusterTabOpts) *Table

target(s)

type StatusHelper

type StatusHelper struct {
	Smap      *meta.Smap
	CluConfig *cmn.ClusterConfig
	Stst      StatsAndStatusHelper
	Capacity  string
	Version   string // when all equal
	BuildTime string // ditto
	NumDisks  int
	Backend   string // configured backend providers
	Endpoint  string // cluster endpoint URL
}

type Table

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

func NewDiskTab

func NewDiskTab(dsh []*DiskStatsHelper, smap *meta.Smap, regex *regexp.Regexp, units, totalsHdr string, withCap bool) *Table

func NewMpathCapTab

func NewMpathCapTab(st NodeStatusMap, c *PerfTabCtx, showMpaths bool) *Table

func (*Table) Template

func (t *Table) Template(hideHeader bool) string

Jump to

Keyboard shortcuts

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