session

package
v0.0.5 Latest Latest
Warning

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

Go to latest
Published: Jun 2, 2026 License: MIT Imports: 14 Imported by: 0

Documentation

Overview

Package session implements factory-session lifecycle command behavior.

Index

Constants

This section is empty.

Variables

View Source
var ErrFactorySessionTargetsRequireSelection = errors.New("factory session target selection required")

ErrFactorySessionTargetsRequireSelection is returned when the API reports runnable targets but does not open a session until the operator disambiguates.

Functions

func Create

func Create(cfg CreateConfig) error

Create opens a live factory session on a running host via HTTP.

func Delete

func Delete(cfg DeleteConfig) error

Delete closes one live factory session on a running host via HTTP.

func List

func List(cfg ListConfig) error

List requests live factory sessions from a running host via HTTP.

Types

type CreateConfig

type CreateConfig struct {
	Port           int
	Dir            string
	InitNewFactory bool
	ValidateOnly   bool
	TargetKind     string
	TargetName     string
	JSON           bool
	Verbose        bool
	Debug          bool
	Output         io.Writer
	Diagnostics    io.Writer
}

CreateConfig holds parameters for the session create command.

type DeleteConfig

type DeleteConfig struct {
	Port        int
	SessionID   string
	JSON        bool
	Verbose     bool
	Debug       bool
	Output      io.Writer
	Diagnostics io.Writer
}

DeleteConfig holds parameters for the session delete command.

type DeleteResult

type DeleteResult struct {
	SessionID string `json:"sessionId"`
}

DeleteResult is the CLI JSON confirmation emitted after a successful close.

type ListConfig

type ListConfig struct {
	Port        int
	JSON        bool
	Verbose     bool
	Debug       bool
	Output      io.Writer
	Diagnostics io.Writer
}

ListConfig holds parameters for the session list command.

Jump to

Keyboard shortcuts

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