File: warning.go

package info (click to toggle)
incus 6.0.4-2
  • links: PTS, VCS
  • area: main
  • in suites: trixie
  • size: 23,864 kB
  • sloc: sh: 16,015; ansic: 3,121; python: 456; makefile: 321; ruby: 51; sql: 50; lisp: 6
file content (65 lines) | stat: -rw-r--r-- 1,711 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
package api

import (
	"time"
)

// Warning represents a warning entry.
//
// swagger:model
//
// API extension: warnings.
type Warning struct {
	WarningPut `yaml:",inline"`

	// UUID of the warning
	// Example: e9e9da0d-2538-4351-8047-46d4a8ae4dbb
	UUID string `json:"uuid" yaml:"uuid"`

	// What cluster member this warning occurred on
	// Example: server01
	Location string `json:"location" yaml:"location"`

	// The project the warning occurred in
	// Example: default
	Project string `json:"project" yaml:"project"`

	// Type type of warning
	// Example: Couldn't find CGroup
	Type string `json:"type" yaml:"type"`

	// The number of times this warning occurred
	// Example: 1
	Count int `json:"count" yaml:"count"`

	// The first time this warning occurred
	// Example: 2021-03-23T17:38:37.753398689-04:00
	FirstSeenAt time.Time `json:"first_seen_at" yaml:"first_seen_at"`

	// The last time this warning occurred
	// Example: 2021-03-23T17:38:37.753398689-04:00
	LastSeenAt time.Time `json:"last_seen_at" yaml:"last_seen_at"`

	// The warning message
	// Example: Couldn't find the CGroup blkio.weight, disk priority will be ignored
	LastMessage string `json:"last_message" yaml:"last_message"`

	// The severity of this warning
	// Example: low
	Severity string `json:"severity" yaml:"severity"`

	// The entity affected by this warning
	// Example: /1.0/instances/c1?project=default
	EntityURL string `json:"entity_url" yaml:"entity_url"`
}

// WarningPut represents the modifiable fields of a warning.
//
// swagger:model
//
// API extension: warnings.
type WarningPut struct {
	// Status of the warning (new, acknowledged, or resolved)
	// Example: new
	Status string `json:"status" yaml:"status"`
}