attachlink

package
v0.2.63 Latest Latest
Warning

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

Go to latest
Published: Nov 21, 2026 License: MPL-2.0 Imports: 23 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package attachlink is the machine's side of `txco attach`: a personality with no listener. It dials each chassis this machine is attached to, proves its key, and hands every request that comes down the link to the chassis's own `_attach` stack, as an inlet does (chassis/attached).

It runs nothing itself. A request is an envelope into the bus; the stack decides what happens, and `_attach`'s built-in rule runs the command through the owner workspace provider. What goes back up the link is only the envelope's `attach` object, or its `workspace.error`.

It also reports the end of detached jobs. A job started for an async op carries that op's continuation; when the job's exit is on disk the result goes up the link, on this connection or a later one, until the chassis acknowledges it.

OFF unless `attachlink` is in --personalities and --attach-home is set. `txco attach` sets both; a full chassis may too.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Controller

type Controller struct {

	// Say, when set, prints one line for the owner (the terminal `txco
	// attach` runs in). The log gets every line regardless.
	Say func(string)

	// Idle, when set, is called once the last credential this process was
	// serving has been ended by its chassis: there is nothing left to do.
	Idle func()
	// contains filtered or unexported fields
}

Controller runs one link per credential in the attach folder.

func NewController

func NewController(ctx context.Context, pu *processor.Unit) *Controller

NewController constructs (but does not start) the personality.

func (*Controller) Start

func (c *Controller) Start()

Start dials every live credential and begins watching for ended jobs.

func (*Controller) Stop

func (c *Controller) Stop()

Stop ends every link. Detached jobs are not this process's to end: they run on, and their ends are reported after the next start.

Jump to

Keyboard shortcuts

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