aboutsummaryrefslogtreecommitdiff
path: root/pkg/domain/entities
diff options
context:
space:
mode:
authorValentin Rothberg <rothberg@redhat.com>2020-09-24 14:28:10 +0200
committerValentin Rothberg <rothberg@redhat.com>2020-09-24 14:28:10 +0200
commit19b955f0999f7fe9e187e94d60327e4d6ee891c0 (patch)
tree98978a07b57f1b4d4290fd9c4c44a64f7acc41a6 /pkg/domain/entities
parent762b787fbf741eec0e59d81aaebbfc467351ceaa (diff)
downloadpodman-19b955f0999f7fe9e187e94d60327e4d6ee891c0.tar.gz
podman-19b955f0999f7fe9e187e94d60327e4d6ee891c0.tar.bz2
podman-19b955f0999f7fe9e187e94d60327e4d6ee891c0.zip
stats: break out CLI options
Have a clear separation of concerns for the CLI-only options (and their logic) from the backend. The backend logic is now easier to understand (e.g., `stream` instead of `noStream`). Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
Diffstat (limited to 'pkg/domain/entities')
-rw-r--r--pkg/domain/entities/containers.go12
1 files changed, 7 insertions, 5 deletions
diff --git a/pkg/domain/entities/containers.go b/pkg/domain/entities/containers.go
index b6f86785f..7b272f01e 100644
--- a/pkg/domain/entities/containers.go
+++ b/pkg/domain/entities/containers.go
@@ -411,15 +411,17 @@ type ContainerCpReport struct {
// ContainerStatsOptions describes input options for getting
// stats on containers
type ContainerStatsOptions struct {
- All bool
- Format string
- Latest bool
- NoReset bool
- NoStream bool
+ // Operate on the latest known container. Only supported for local
+ // clients.
+ Latest bool
+ // Stream stats.
+ Stream bool
}
// ContainerStatsReport is used for streaming container stats.
type ContainerStatsReport struct {
+ // Error from reading stats.
Error error
+ // Results, set when there is no error.
Stats []define.ContainerStats
}