summaryrefslogtreecommitdiff
path: root/libpod/sql_state.go
diff options
context:
space:
mode:
authorMatthew Heon <matthew.heon@gmail.com>2018-01-18 10:49:01 -0500
committerAtomic Bot <atomic-devel@projectatomic.io>2018-02-09 15:01:34 +0000
commit6214be07c2bf82f90361f058ab0c7178b634ecf9 (patch)
tree34a1e85e4f6bfca99e4207f102c5c0d208a00289 /libpod/sql_state.go
parentbf981fc8738ec5910efd54117677f8eacb7ca37e (diff)
downloadpodman-6214be07c2bf82f90361f058ab0c7178b634ecf9.tar.gz
podman-6214be07c2bf82f90361f058ab0c7178b634ecf9.tar.bz2
podman-6214be07c2bf82f90361f058ab0c7178b634ecf9.zip
Tear out pod containers map. Instead rely on state
This ensures that there is only one canonical place where containers in a pod are stored, in the state itself. Signed-off-by: Matthew Heon <matthew.heon@gmail.com> Closes: #268 Approved by: rhatdan
Diffstat (limited to 'libpod/sql_state.go')
-rw-r--r--libpod/sql_state.go19
1 files changed, 13 insertions, 6 deletions
diff --git a/libpod/sql_state.go b/libpod/sql_state.go
index c10975d47..5c843ad6f 100644
--- a/libpod/sql_state.go
+++ b/libpod/sql_state.go
@@ -839,8 +839,20 @@ func (s *SQLState) HasPod(id string) (bool, error) {
return false, ErrNotImplemented
}
+// PodHasContainer checks if the given pod containers a container with the given
+// ID
+func (s *SQLState) PodHasContainer(pod *Pod, ctrID string) (bool, error) {
+ return false, ErrNotImplemented
+}
+
+// PodContainersByID returns the container IDs of all containers in the given
+// pod
+func (s *SQLState) PodContainersByID(pod *Pod) ([]string, error) {
+ return nil, ErrNotImplemented
+}
+
// PodContainers returns all the containers in a pod given the pod's full ID
-func (s *SQLState) PodContainers(id string) ([]*Container, error) {
+func (s *SQLState) PodContainers(pod *Pod) ([]*Container, error) {
return nil, ErrNotImplemented
}
@@ -856,11 +868,6 @@ func (s *SQLState) RemovePod(pod *Pod) error {
return ErrNotImplemented
}
-// UpdatePod updates a pod from the database
-func (s *SQLState) UpdatePod(pod *Pod) error {
- return ErrNotImplemented
-}
-
// AddContainerToPod adds a container to the given pod
func (s *SQLState) AddContainerToPod(pod *Pod, ctr *Container) error {
return ErrNotImplemented