Add a server side export facility

This commit is contained in:
Brendan Burns
2015-12-01 15:45:29 -08:00
parent bae050ffea
commit a60069b300
43 changed files with 17308 additions and 15231 deletions

View File

@@ -64,6 +64,14 @@ type Lister interface {
List(ctx api.Context, options *unversioned.ListOptions) (runtime.Object, error)
}
// Exporter is an object that knows how to strip a RESTful resource for export
type Exporter interface {
// Export an object. Fields that are not user specified (e.g. Status, ObjectMeta.ResourceVersion) are stripped out
// Returns the stripped object. If 'exact' is true, fields that are specific to the cluster (e.g. namespace) are
// retained, otherwise they are stripped also.
Export(ctx api.Context, name string, opts unversioned.ExportOptions) (runtime.Object, error)
}
// Getter is an object that can retrieve a named RESTful resource.
type Getter interface {
// Get finds a resource in the storage by name and returns it.