resourcequotausage

package
v0.12.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 16, 2015 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Overview

Package resourcequotausage provides Registry interface and it's REST implementation for storing ResourceQuotaUsage api objects.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type REST

type REST struct {
	// contains filtered or unexported fields
}

REST implements the RESTStorage interface for ResourceQuotaUsage

func NewREST

func NewREST(registry Registry) *REST

NewREST creates a new REST backed by the given registry.

func (*REST) Create

func (b *REST) Create(ctx api.Context, obj runtime.Object) (runtime.Object, error)

Create takes the incoming ResourceQuotaUsage and applies the latest status atomically to a ResourceQuota

func (*REST) New

func (*REST) New() runtime.Object

New returns a new resource observation object

type Registry

type Registry interface {
	// ApplyStatus should update the ResourceQuota.Status with latest observed state.
	// This should be atomic, and idempotent based on the ResourceVersion
	ApplyStatus(ctx api.Context, usage *api.ResourceQuotaUsage) error
}

Registry contains the functions needed to support a ResourceQuotaUsage

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL