# Functions
计算 Pod 的 CPU 和 mem.
ClientIP 尽最大努力实现获取客户端 IP 的算法。 解析 X-Real-IP 和 X-Forwarded-For 以便于反向代理(nginx 或 haproxy)可以正常工作。.
CloneStringMap copy src to dst of type map[string]string.
No description provided by the author
Dumps dump interface as indented json object.
DumpsEventBasic will remove some info from pod spec to reduce log size and sensitive data to be leaked.
No description provided by the author
FormatTime format time to UTC time and with million seconds.
GetClientFromFile create a k8s client from config file.
No description provided by the author
获取数据的 SqlTableName EsTableName TypeName.
获取pod中所有pvc的资源名列表.
GetPulledImageFromEventMessage get image name from pulled event.
GetPullingImageFromEventMessage get image name from pulling event.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
Marshal Marshal object to string of the error message if failed.
No description provided by the author
Creates a new concurrent map.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
ParseTime parse string into time using layout "2006-01-02T15:04:05.000Z".
RandString generate n-length random string.
ReTry try to call a function until success.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
ShouldIgnoreNamespace return true is namespace should be omit.
No description provided by the author
No description provided by the author
TimeDiffInMilliMinutes return time difference in minutes.
No description provided by the author
TimeDiffInSeconds get time difference in unit second.
No description provided by the author
TimeSinceInMinutes return minutes since start.
No description provided by the author
No description provided by the author
# Variables
No description provided by the author
No description provided by the author
No description provided by the author
# Structs
No description provided by the author
No description provided by the author
A "thread" safe string to anything map.
No description provided by the author
No description provided by the author
expired map.
No description provided by the author
No description provided by the author
Used by the Iter & IterBuffered functions to wrap two variables together over a channel,.
# Type aliases
A "thread" safe map of type string:Anything.
Iterator callback,called for every key,value found in maps.
RemoveCb is a callback executed in a map.RemoveCb() call, while Lock is held If returns true, the element will be removed from the map.
Callback to return new element to be inserted into the map It is called while lock is held, therefore it MUST NOT try to access other keys in same map, as it can lead to deadlock since Go sync.RWLock is not reentrant.