Rename state.Store to something more greppable

Signed-off-by: Matthew Heon <mheon@redhat.com>
This commit is contained in:
Matthew Heon 2017-04-21 11:03:21 -04:00
parent 16fb71fea0
commit d435433971
3 changed files with 4 additions and 4 deletions

View file

@ -58,7 +58,7 @@ type Server struct {
storageImageServer storage.ImageServer
storageRuntimeServer storage.RuntimeServer
updateLock sync.RWMutex
state state.Store
state state.RuntimeStateStorer
netPlugin ocicni.CNIPlugin
hostportManager hostport.HostPortManager
imageContext *types.SystemContext

View file

@ -26,7 +26,7 @@ type InMemoryState struct {
}
// NewInMemoryState creates a new, empty server state
func NewInMemoryState() Store {
func NewInMemoryState() RuntimeStateStorer {
state := new(InMemoryState)
state.sandboxes = make(map[string]*sandbox.Sandbox)
state.containers = oci.NewMemoryStore()

View file

@ -5,8 +5,8 @@ import (
"github.com/kubernetes-incubator/cri-o/server/sandbox"
)
// Store stores the state of the CRI-O server, including active pods and containers
type Store interface {
// RuntimeStateStorer stores the state of the CRI-O server, including active pods and containers
type RuntimeStateStorer interface {
AddSandbox(s *sandbox.Sandbox) error
HasSandbox(id string) bool
DeleteSandbox(id string) error