Documentation
¶
Index ¶
- func BuildCpuUsageAverageQuery(p *PrometheusQueryParams) string
- func BuildDownloadThroughputQuery(p *PrometheusQueryParams) string
- func BuildMemRateQuery(p *PrometheusQueryParams) string
- func BuildMemUsageAverageQuery(p *PrometheusQueryParams) string
- func BuildMemUsageQuery(p *PrometheusQueryParams) string
- func BuildPodsByStatusQuery(p *PrometheusQueryParams) string
- func BuildResourceLimitQuery(p *PrometheusQueryParams) string
- func BuildResourceRequestQuery(p *PrometheusQueryParams) string
- func BuildRunningPodsQuery(p *PrometheusQueryParams) string
- func BuildTotalThroughputQuery(p *PrometheusQueryParams) string
- func BuildUploadThroughputQuery(p *PrometheusQueryParams) string
- func UpdateContainerNameInPrometheusResultList(models *[]PrometheusResult, value string)
- type KubernetesPhase
- type MetricType
- type NwdafPacketCaptureMetric
- type NwdafPacketCaptureResponse
- type PrometheusQueryParams
- type PrometheusResult
- type PrometheusUnit
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BuildCpuUsageAverageQuery ¶
func BuildCpuUsageAverageQuery(p *PrometheusQueryParams) string
CPU Usage Average (OK)
func BuildDownloadThroughputQuery ¶
func BuildDownloadThroughputQuery(p *PrometheusQueryParams) string
DownloadThrough
func BuildMemUsageAverageQuery ¶
func BuildMemUsageAverageQuery(p *PrometheusQueryParams) string
Memory Usage average (OK)
func BuildMemUsageQuery ¶
func BuildMemUsageQuery(p *PrometheusQueryParams) string
Memory Usage (OK)
func BuildPodsByStatusQuery ¶
func BuildPodsByStatusQuery(p *PrometheusQueryParams) string
Pods by Phase
func BuildResourceLimitQuery ¶
func BuildResourceLimitQuery(p *PrometheusQueryParams) string
CPU and Momory resources limit (OK)
func BuildResourceRequestQuery ¶
func BuildResourceRequestQuery(p *PrometheusQueryParams) string
CPU and Memory resources request (OK)
func BuildRunningPodsQuery ¶
func BuildRunningPodsQuery(p *PrometheusQueryParams) string
Pods running
func BuildTotalThroughputQuery ¶
func BuildTotalThroughputQuery(p *PrometheusQueryParams) string
UploadThrough ()
func BuildUploadThroughputQuery ¶
func BuildUploadThroughputQuery(p *PrometheusQueryParams) string
UploadThrough ()
func UpdateContainerNameInPrometheusResultList ¶
func UpdateContainerNameInPrometheusResultList(models *[]PrometheusResult, value string)
Types ¶
type KubernetesPhase ¶
type KubernetesPhase string
const ( KubernetesPhase_PENDING KubernetesPhase = "Pending" KubernetesPhase_RUNNING KubernetesPhase = "Running" KubernetesPhase_SUCCEEDED KubernetesPhase = "Succeeded" KubernetesPhase_FAILED KubernetesPhase = "Failed" KubernetesPhase_UNKNOWN KubernetesPhase = "Unknown" )
type MetricType ¶
type MetricType string
const ( MetricType_CPU_USAGE MetricType = "cpu-usage" MetricType_MEMORY_USAGE MetricType = "mem-usage" MetricType_CPU_USAGE_AVERAGE MetricType = "cpu-average" MetricType_MEMORY_USAGE_AVERAGE MetricType = "mem-average" MetricType_CPU_LIMIT MetricType = "cpu-limit" MetricType_MEMORY_LIMIT MetricType = "men-limit" MetricType_CPU_REQUEST MetricType = "cpu-request" MetricType_MEMORY_REQUEST MetricType = "men-request" MetricType_POD_STATUS MetricType = "pod-status" MetricType_RUNNING_POD MetricType = "running-pod" MetricType_TOTAL_THROUGPUT_AVERAGE MetricType = "throughput-average" MetricType_UPLOAD_THROUGPUT_AVERAGE MetricType = "upload-throughput-average" MetricType_DOWNLOAD_THROUGPUT_AVERAGE MetricType = "download-throughput-average" )
type NwdafPacketCaptureMetric ¶
type NwdafPacketCaptureMetric struct { CpuUsage float64 `json:"cpu_usage" yaml:"cpu_usage" bson:"cpu_usage"` MemUsage float64 `json:"mem_usage" yaml:"mem_usage" bson:"mem_usage"` CpuLimit float64 `json:"cpu_limit" yaml:"cpu_limit" bson:"cpu_limit"` MemLimit float64 `json:"mem_limit" yaml:"mem_limit" bson:"mem_limit"` Timestamp *time.Time `json:"timestamp" yaml:"timestamp" bson:"timestamp"` }
type NwdafPacketCaptureResponse ¶
type NwdafPacketCaptureResponse struct { Metrics []NwdafPacketCaptureMetric `json:"metrics" yaml:"metrics" bson:"metrics"` NfType models.NfType `json:"nfType,omitempty" yaml:"nfType" bson:"nfType" mapstructure:"nfType"` NfService string `json:"nfService,omitempty" yaml:"nfService" bson:"nfService" mapstructure:"nfService"` }
type PrometheusQueryParams ¶
type PrometheusResult ¶
type PrometheusResult struct { Timestamp float64 `json:"timestamp"` Value float64 `json:"value"` MetricType MetricType `json:"metric"` Namespace string `json:"namespace"` Pod string `json:"pod"` Container string `json:"container"` Phase string `json:"phase"` Uid string `json:"uid"` }
func FindPodByContainer ¶
func FindPodByContainer(pods []PrometheusResult, container string) *PrometheusResult
func NewPrometheusResult ¶
func NewPrometheusResult() PrometheusResult
type PrometheusUnit ¶
type PrometheusUnit string
const ( PrometheusUnit_CORE PrometheusUnit = "core" PrometheusUnit_BYTE PrometheusUnit = "byte" )
Source Files
¶
Click to show internal directories.
Click to hide internal directories.