tasks

package
v0.4.6-beta.5 Latest Latest
Warning

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

Go to latest
Published: Nov 28, 2025 License: MIT Imports: 1 Imported by: 0

Documentation

Overview

Package tasks models remotely-triggered actions and their results for dployr's distributed task system. It defines the Task and Result types, along with the addressing convention ("path:method") for routing tasks to appropriate handlers. Execution and orchestration live in the syncer and executor under internal/system.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Result

type Result struct {
	ID     string `json:"id"`
	Status string `json:"status"` // "done" or "failed"
	Result any    `json:"result,omitempty"`
	Error  string `json:"error,omitempty"`
}

Result represents the outcome of executing a task.

type Task

type Task struct {
	ID      string
	Type    string // TaskAddress format: "path:method" e.g. "system/status:get"
	Payload json.RawMessage
	Status  string
}

Task represents a remotely-triggered action from base.

Jump to

Keyboard shortcuts

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