utils

package
v0.0.0-...-542bf9e Latest Latest
Warning

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

Go to latest
Published: Jan 22, 2019 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CalculateMemLimit

func CalculateMemLimit(maxMemRate float64) int

func DeepCopyStrategy

func DeepCopyStrategy(ori *scheme.Strategy) *scheme.Strategy

func DeepCopyStringMap

func DeepCopyStringMap(params map[string]string) map[string]string

func DeepCopyStringSlice

func DeepCopyStringSlice(params []string) []string

func DictedTagstring

func DictedTagstring(s string) map[string]string

func GetCPULimitNum

func GetCPULimitNum(maxCPURate float64) int

func GetEndpoint

func GetEndpoint(endpoint string) (string, error)

func GetPatAndTimeFormat

func GetPatAndTimeFormat(tf string) (string, string)

根据配置的时间格式,获取对应的正则匹配pattern和time包用的时间格式

func LocalHostname

func LocalHostname() (string, error)

func LocalIP

func LocalIP() (string, error)

func SortedTags

func SortedTags(tags map[string]string) string

Types

This section is empty.

Jump to

Keyboard shortcuts

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