Documentation ¶
Index ¶
- func WithRuntimeParams(parent context.Context, params RuntimeParams) context.Context
- type ComponentApply
- type ComponentHealthCheck
- type ComponentRender
- type GenericProviderFn
- type NativeProviderFn
- type OAMGenericProviderFn
- type OAMNativeProviderFn
- type OAMParams
- type Params
- type Returns
- type RuntimeParams
- type WorkloadRender
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func WithRuntimeParams ¶
func WithRuntimeParams(parent context.Context, params RuntimeParams) context.Context
WithRuntimeParams returns a copy of parent in which the runtime params value is set
Types ¶
type ComponentApply ¶
type ComponentApply func(ctx context.Context, comp common.ApplicationComponent, patcher *cue.Value, clusterName string, overrideNamespace string) (*unstructured.Unstructured, []*unstructured.Unstructured, bool, error)
ComponentApply apply oam component.
type ComponentHealthCheck ¶
type ComponentHealthCheck func(ctx context.Context, comp common.ApplicationComponent, patcher *cue.Value, clusterName string, overrideNamespace string) (bool, *unstructured.Unstructured, []*unstructured.Unstructured, error)
ComponentHealthCheck health check oam component.
type ComponentRender ¶
type ComponentRender func(ctx context.Context, comp common.ApplicationComponent, patcher *cue.Value, clusterName string, overrideNamespace string) (*unstructured.Unstructured, []*unstructured.Unstructured, error)
ComponentRender render oam component.
type GenericProviderFn ¶
GenericProviderFn is the provider function
type NativeProviderFn ¶
NativeProviderFn is the legacy native provider function
type OAMGenericProviderFn ¶
OAMGenericProviderFn is the legacy oam provider function
type OAMNativeProviderFn ¶
OAMNativeProviderFn is the legacy oam native provider function
type OAMParams ¶
type OAMParams[T any] struct { Params T RuntimeParams }
OAMParams is the legacy oam input parameters of a provider.
type Params ¶
type Params[T any] struct { Params T `json:"$params"` RuntimeParams }
Params is the input parameters of a provider.
type Returns ¶
type Returns[T any] struct { Returns T `json:"$returns"` }
Returns is the returns of a provider.
type RuntimeParams ¶
type RuntimeParams struct { ComponentApply ComponentApply ComponentRender ComponentRender ComponentHealthCheck ComponentHealthCheck WorkloadRender WorkloadRender App *v1beta1.Application AppLabels map[string]string Appfile *appfile.Appfile Action types.Action ConfigFactory config.Factory KubeHandlers *providertypes.KubeHandlers KubeClient client.Client KubeConfig *rest.Config FieldLabel string }
RuntimeParams is the params for runtime
func RuntimeParamsFrom ¶
func RuntimeParamsFrom(ctx context.Context) RuntimeParams
RuntimeParamsFrom returns the runtime params value stored in ctx, if any.
type WorkloadRender ¶
type WorkloadRender func(ctx context.Context, comp common.ApplicationComponent) (*appfile.Component, error)
WorkloadRender render application component into workload