frontend

package
v0.55.0 Latest Latest
Warning

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

Go to latest
Published: Mar 7, 2026 License: Apache-2.0 Imports: 28 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewGetResourceWithRedaction added in v0.55.0

func NewGetResourceWithRedaction(
	opts ctrl.Options,
	resourceOpts ctrl.ResourceOptions[datamodel.DynamicResource],
	ucpClient *v20231001preview.ClientFactory,
) (ctrl.Controller, error)

NewGetResourceWithRedaction creates a new GetResourceWithRedaction controller.

func NewListResourcesWithRedaction added in v0.55.0

func NewListResourcesWithRedaction(
	opts ctrl.Options,
	resourceOpts ctrl.ResourceOptions[datamodel.DynamicResource],
	ucpClient *v20231001preview.ClientFactory,
) (ctrl.Controller, error)

NewListResourcesWithRedaction creates a new ListResourcesWithRedaction controller.

Types

type GetResourceWithRedaction added in v0.55.0

type GetResourceWithRedaction struct {
	ctrl.Operation[*datamodel.DynamicResource, datamodel.DynamicResource]
	// contains filtered or unexported fields
}

GetResourceWithRedaction is a custom GET controller that redacts sensitive fields.

func (*GetResourceWithRedaction) Run added in v0.55.0

Run returns the requested resource with sensitive fields redacted.

Design consideration (GET Operation Update): When provisioningState is "Succeeded", the backend has already redacted sensitive data from the database, so we skip the schema fetch and redaction (fast path). For all other states (e.g., "Updating", "Accepted", "Failed"), the resource may still contain encrypted data, so we fetch the schema and redact sensitive fields to prevent exposure.

type ListResourcesWithRedaction added in v0.55.0

type ListResourcesWithRedaction struct {
	ctrl.Operation[*datamodel.DynamicResource, datamodel.DynamicResource]
	// contains filtered or unexported fields
}

ListResourcesWithRedaction is a custom LIST controller that redacts sensitive fields.

func (*ListResourcesWithRedaction) Run added in v0.55.0

Run returns the list of resources with sensitive fields redacted.

type Service

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

Service implements the hosting.Service interface for the UCP frontend API.

func NewService

func NewService(options *dynamicrp.Options) *Service

func (*Service) Name

func (s *Service) Name() string

Name gets this service name.

func (*Service) Run

func (s *Service) Run(ctx context.Context) error

Run sets up a server to listen on a given address, and shuts it down when the context is done. It returns an error if the server fails to start or stops unexpectedly.

Jump to

Keyboard shortcuts

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