Documentation ¶
Overview ¶
Package ssmetrics collect metrics from ss
Index ¶
- func AggregateStatistics(localDomainName string, clusterResults map[string]float64, ...) (map[string]float64, error)
- func Alert(metric float64, threshold float64) bool
- func Avg(metrics []map[string]string, key string) (float64, error)
- func Filter(ssMetrics []map[string]string, srcIP string, dstIP string, srcPort string, ...) []map[string]string
- func GetMetricChange(lastMetricValues map[string]float64, currentMetricValues map[string]float64) (map[string]float64, map[string]float64)
- func GetSsMetricResults(runMode pkgcom.RunModeType, localDomainName string, ...) (map[string]float64, error)
- func GetStatisticFromSs() ([]map[string]string, error)
- func Max(metrics []map[string]string, key string) (float64, error)
- func Min(metrics []map[string]string, key string) (float64, error)
- func Rate(metric1 float64, metric2 float64) float64
- func Sum(metrics []map[string]string, key string) (float64, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AggregateStatistics ¶
func AggregateStatistics(localDomainName string, clusterResults map[string]float64, networkResults []map[string]string, aggregationMetrics map[string]string, dstDomain string, MonitorPeriods uint) (map[string]float64, error)
AggregateStatistics aggregate statistics using an aggregation function
func Filter ¶
func Filter(ssMetrics []map[string]string, srcIP string, dstIP string, srcPort string, dstPort string, protoNum string) []map[string]string
Filter filter network flows according to given five-tuple rules
func GetMetricChange ¶
func GetMetricChange(lastMetricValues map[string]float64, currentMetricValues map[string]float64) (map[string]float64, map[string]float64)
GetMetricChange get the change values of metrics
func GetSsMetricResults ¶
func GetSsMetricResults(runMode pkgcom.RunModeType, localDomainName string, clusterAddresses map[string][]string, AggregationMetrics map[string]string, MonitorPeriods uint) (map[string]float64, error)
GetSsMetricResults Get the results of ss statistics after filtering
func GetStatisticFromSs ¶
GetStatisticFromSs get the statistics of network flows from ss
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.