aboutsummaryrefslogtreecommitdiff
path: root/libpod/pod.go
diff options
context:
space:
mode:
authorMatthew Heon <matthew.heon@gmail.com>2018-08-22 09:12:40 -0400
committerAtomic Bot <atomic-devel@projectatomic.io>2018-08-24 19:19:43 +0000
commit714dbbda9e1f3ec98d75a07ed4c5442ea6540680 (patch)
tree286da76261791b375441a6d3999f1348c7d1e66e /libpod/pod.go
parentbd080b45305a311542527443e9108c1cfdff3c93 (diff)
downloadpodman-714dbbda9e1f3ec98d75a07ed4c5442ea6540680.tar.gz
podman-714dbbda9e1f3ec98d75a07ed4c5442ea6540680.tar.bz2
podman-714dbbda9e1f3ec98d75a07ed4c5442ea6540680.zip
Swap from FFJSON to easyjson
FFJSON has serialization differences versus stock Go - namely, it does not respect the MarshalText() and UnmarshalText() methods, particularly on []byte, which causes incompatability with pre-FFJSON containers which contained DNS servers. EasyJSON does not have these issues, and might even be slightly faster. Signed-off-by: Matthew Heon <matthew.heon@gmail.com> Closes: #1322 Approved by: mheon
Diffstat (limited to 'libpod/pod.go')
-rw-r--r--libpod/pod.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/libpod/pod.go b/libpod/pod.go
index 9c7a3e3a3..8ac976f6a 100644
--- a/libpod/pod.go
+++ b/libpod/pod.go
@@ -29,6 +29,7 @@ type Pod struct {
}
// PodConfig represents a pod's static configuration
+// easyjson:json
type PodConfig struct {
ID string `json:"id"`
Name string `json:"name"`
@@ -61,6 +62,7 @@ type PodConfig struct {
}
// podState represents a pod's state
+// easyjson:json
type podState struct {
// CgroupPath is the path to the pod's CGroup
CgroupPath string `json:"cgroupPath"`
@@ -71,6 +73,7 @@ type podState struct {
// PodInspect represents the data we want to display for
// podman pod inspect
+// easyjson:json
type PodInspect struct {
Config *PodConfig
State *PodInspectState
@@ -78,12 +81,14 @@ type PodInspect struct {
}
// PodInspectState contains inspect data on the pod's state
+// easyjson:json
type PodInspectState struct {
CgroupPath string `json:"cgroupPath"`
InfraContainerID string `json:"infraContainerID"`
}
// PodContainerInfo keeps information on a container in a pod
+// easyjson:json
type PodContainerInfo struct {
ID string `json:"id"`
State string `json:"state"`