kubernetes

package
v1.3.0-custom Latest Latest
Warning

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

Go to latest
Published: Nov 23, 2018 License: MPL-2.0 Imports: 58 Imported by: 0

Documentation

Overview

Package transport provides a round tripper capable of caching HTTP responses.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Convert

func Convert(item, out interface{}) error

Convert between two types by converting to/from JSON. Intended to switch between multiple API versions, as they are strict supersets of one another. item and out are pointers to structs

func NewCacheRoundTripper

func NewCacheRoundTripper(cacheDir string, rt http.RoundTripper) http.RoundTripper

NewCacheRoundTripper creates a roundtripper that reads the ETag on response headers and send the If-None-Match header on subsequent corresponding requests.

func Provider

func Provider() terraform.ResourceProvider

Types

type APIGroup

type APIGroup int

func (APIGroup) String

func (g APIGroup) String() string

type AddOperation

type AddOperation struct {
	Path  string      `json:"path"`
	Value interface{} `json:"value"`
	Op    string      `json:"op"`
}

func (*AddOperation) GetPath

func (o *AddOperation) GetPath() string

func (*AddOperation) MarshalJSON

func (o *AddOperation) MarshalJSON() ([]byte, error)

func (*AddOperation) String

func (o *AddOperation) String() string

type CachedDiscoveryClient

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

CachedDiscoveryClient implements the functions that discovery server-supported API groups, versions and resources.

func NewCachedDiscoveryClient

func NewCachedDiscoveryClient(delegate discovery.DiscoveryInterface, cacheDirectory string, ttl time.Duration) *CachedDiscoveryClient

NewCachedDiscoveryClient creates a new DiscoveryClient. cacheDirectory is the directory where discovery docs are held. It must be unique per host:port combination to work well.

func (*CachedDiscoveryClient) Fresh

func (d *CachedDiscoveryClient) Fresh() bool

func (*CachedDiscoveryClient) Invalidate

func (d *CachedDiscoveryClient) Invalidate()

func (*CachedDiscoveryClient) OpenAPISchema

func (d *CachedDiscoveryClient) OpenAPISchema() (*openapi_v2.Document, error)

func (*CachedDiscoveryClient) RESTClient

func (d *CachedDiscoveryClient) RESTClient() restclient.Interface

func (*CachedDiscoveryClient) ServerGroups

func (d *CachedDiscoveryClient) ServerGroups() (*metav1.APIGroupList, error)

func (*CachedDiscoveryClient) ServerPreferredNamespacedResources

func (d *CachedDiscoveryClient) ServerPreferredNamespacedResources() ([]*metav1.APIResourceList, error)

func (*CachedDiscoveryClient) ServerPreferredResources

func (d *CachedDiscoveryClient) ServerPreferredResources() ([]*metav1.APIResourceList, error)

func (*CachedDiscoveryClient) ServerResources

func (d *CachedDiscoveryClient) ServerResources() ([]*metav1.APIResourceList, error)

ServerResources returns the supported resources for all groups and versions.

func (*CachedDiscoveryClient) ServerResourcesForGroupVersion

func (d *CachedDiscoveryClient) ServerResourcesForGroupVersion(groupVersion string) (*metav1.APIResourceList, error)

ServerResourcesForGroupVersion returns the supported resources for a group and version.

func (*CachedDiscoveryClient) ServerVersion

func (d *CachedDiscoveryClient) ServerVersion() (*version.Info, error)

type PatchOperation

type PatchOperation interface {
	MarshalJSON() ([]byte, error)
	GetPath() string
}

type PatchOperations

type PatchOperations []PatchOperation

func (PatchOperations) Equal

func (po PatchOperations) Equal(ops []PatchOperation) bool

func (PatchOperations) MarshalJSON

func (po PatchOperations) MarshalJSON() ([]byte, error)

type RemoveOperation

type RemoveOperation struct {
	Path string `json:"path"`
	Op   string `json:"op"`
}

func (*RemoveOperation) GetPath

func (o *RemoveOperation) GetPath() string

func (*RemoveOperation) MarshalJSON

func (o *RemoveOperation) MarshalJSON() ([]byte, error)

func (*RemoveOperation) String

func (o *RemoveOperation) String() string

type ReplaceOperation

type ReplaceOperation struct {
	Path  string      `json:"path"`
	Value interface{} `json:"value"`
	Op    string      `json:"op"`
}

func (*ReplaceOperation) GetPath

func (o *ReplaceOperation) GetPath() string

func (*ReplaceOperation) MarshalJSON

func (o *ReplaceOperation) MarshalJSON() ([]byte, error)

func (*ReplaceOperation) String

func (o *ReplaceOperation) String() string

Source Files

Jump to

Keyboard shortcuts

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