gapi, etcd: Define and implement a string sharing API for the World

This adds a new set of methods to the World API (for sharing data
throughout the cluster) and adds an etcd backed implementation.
This commit is contained in:
James Shubin
2017-03-03 16:26:42 -05:00
parent 1488e5ec4d
commit 203d866643
3 changed files with 139 additions and 0 deletions

View File

@@ -30,6 +30,11 @@ type World interface { // TODO: is there a better name for this interface?
ResExport([]resources.Res) error
// FIXME: should this method take a "filter" data struct instead of many args?
ResCollect(hostnameFilter, kindFilter []string) ([]resources.Res, error)
StrWatch(namespace string) chan error
StrGet(namespace string) (map[string]string, error)
StrSet(namespace, value string) error
StrDel(namespace string) error
}
// Data is the set of input values passed into the GAPI structs via Init.