capability

package
v0.93.0 Latest Latest
Warning

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

Go to latest
Published: Jun 17, 2026 License: GPL-3.0 Imports: 7 Imported by: 0

Documentation

Overview

Package capability implements capability-based execution runtime.

Index

Constants

View Source
const (
	Prefix = "capability:"
)

Prefix identifies tasks that should be handled by the capability runtime.

Variables

This section is empty.

Functions

This section is empty.

Types

type Runtime

type Runtime struct{}

Runtime executes tasks by invoking registered ability capabilities.

func New

func New() *Runtime

New creates a new capability runtime.

func (*Runtime) Close

func (*Runtime) Close() error

Close is a no-op for the capability runtime.

func (*Runtime) HealthCheck

func (*Runtime) HealthCheck(_ context.Context) error

HealthCheck always returns nil because the capability runtime has no external dependencies to verify.

func (*Runtime) Run

func (*Runtime) Run(ctx context.Context, t *types.Task) error

Run parses the task's Run field as "capability:<type>.<operation>", decodes params from the CAPABILITY_PARAMS env var, and invokes the matching ability.

func (*Runtime) Stop

func (*Runtime) Stop(_ context.Context, _ *types.Task) error

Stop is a no-op for the capability runtime since invocations are synchronous.

Jump to

Keyboard shortcuts

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