package
0.23.1
Repository: https://github.com/grafana/grafana-app-sdk.git
Documentation: pkg.go.dev

# Functions

DeepCopyObject is an implementation of the receiver method required for implementing runtime.Object.
DefaultClientConfig returns a ClientConfig using defaults that assume you have used the SDK codegen tooling.
GetTracer returns the trace.Tracer set by SetTracer, or a tracer generated from otel.GetTracerProvider().Tracer("k8s") if none has been set.
NewAdmissionError returns a new SimpleAdmissionError, which implements resource.AdmissionError.
NewClientRegistry returns a new ClientRegistry which will make Client structs using the provided rest.Config.
NewManager creates a new ResourceManager.
NewOpinionatedMutatingAdmissionController creates a pointer to a new OpinionatedMutatingAdmissionController wrapping the provided MutatingAdmissionController.
NewOpinionatedValidatingAdmissionController returns a new OpinionatedValidatingAdmissionController which wraps the provided ValidatingAdmissionController.
NewSchemalessClient creates a new SchemalessClient using the provided rest.Config and ClientConfig.
No description provided by the author
NewServerResponseError creates a new instance of ServerResponseError.
NewWebhookServer creates a new WebhookServer using the provided configuration.
SetTracer sets the tracer used for generating spans for this package.
ValidateNamespace validates that `namespace` is a valid Kubernetes namespace name.

# Constants

AnnotationPrefix is the prefix used in annotations which contain grafana kind metadata.
ErrReasonFieldNotAllowed is the "field not allowed" admission error reason string.

# Structs

Client is a kubernetes-specific implementation of resource.Client, using custom resource definitions.
ClientConfig is the configuration object for creating Clients.
ClientRegistry implements resource.ClientGenerator, and keeps a cache of kubernetes clients based on GroupVersion (the largest unit a kubernetes rest.RESTClient can work with).
CodecDecoder implements runtime.Serializer and works with Untyped* objects to implement runtime.Object.
CustomResourceDefinition is the kubernetes-API-compliant representation of a Custom Resource Definition.
CustomResourceDefinitionAdditionalPrinterColumn is the struct representing an additional printer column in a kubernetes CRD.
CustomResourceDefinitionSelectableField is the struct representing a selectable field in a kubernetes CRD.
CustomResourceDefinitionSpec is the body or spec of a kubernetes Custom Resource Definition.
CustomResourceDefinitionSpecNames is the struct representing the names (kind and plural) of a kubernetes CRD.
CustomResourceDefinitionSpecVersion is the representation of a specific version of a CRD, as part of the overall spec.
GenericJSONDecoder implements runtime.Serializer and works with Untyped* objects to implement runtime.Object.
GenericNegotiatedSerializer implements runtime.NegotiatedSerializer and allows for JSON serialization and deserialization of resource.Object.
No description provided by the author
OpinionatedMutatingAdmissionController is a MutatingAdmissionController which wraps an optional user-defined MutatingAdmissionController with a set of additional changes to the response's UpdatedObject which set metadata and label properties.
OpinionatedValidatingAdmissionController implements resource.ValidatingAdmissionController and performs initial validation on reserved metadata fields which are stores as annotations in kubernetes, ensuring that if any changes are made, they are allowed, before calling the underlying admission validate function.
RawKind represents a raw kubernetes object with basic kind information parsed out of it.
ResourceManager is a struct that implements resource.Manager, allowing a user to manage Schemas as Custom Resource Definitions in kubernetes.
SchemalessClient implements resource.SchemalessClient and allows for working with Schemas as kubernetes Custom Resource Definitions without being tied to a particular Schema (or GroupVerson).
ServerResponseError represents an HTTP error from the kubernetes control plane.
SimpleAdmissionError implements resource.AdmissionError.
TLSConfig describes a set of TLS files.
TypedObjectWrapper wraps a resource.Object in a runtime.Object interface, and exposes a ResourceObject() method to get the wrapped object.
UntypedObjectWrapper wraps bytes which can be marshaled into a resource.Object, but only if provided an example object to marshal into.
UntypedWatchObject implements runtime.Object, and keeps the Object part of a kubernetes watch event as bytes when unmarshaled, so that it can later be marshaled into a concrete type with Into().
WatchResponse wraps a kubernetes watch.Interface in order to implement resource.WatchResponse.
WebhookServer is a kubernetes webhook server, which exposes /validate and /mutate HTTPS endpoints.
WebhookServerConfig is the configuration object for a WebhookServer, used with NewWebhookServer.

# Interfaces

Converter describes a type which can convert a kubernetes kind from one API version to another.