interop

package
v0.6.0 Latest Latest
Warning

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

Go to latest
Published: Dec 4, 2026 License: MIT Imports: 3 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 interop plans explicit transport connections between Ext peers. It is metadata-only: it never discovers, launches, authenticates or retries.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Bridge

type Bridge struct {
	Name     string                `json:"name"`
	Frontend plugin.BackendProfile `json:"frontend"`
	Backend  plugin.BackendProfile `json:"backend"`
}

Bridge declares an installed, reviewed translator. Frontend faces the host; Backend faces the guest. Its public features must not overstate either side.

type Requirements

type Requirements struct {
	Concurrent      bool
	NativeStreaming bool
	NativeCallbacks bool
	// Boundaries are the sandbox boundaries the consumer accepts for the guest
	// (plugin.Boundaries). Empty accepts any, including a guest whose profile
	// states none; otherwise the guest's profile must state one of them.
	Boundaries []string
}

type Route

type Route struct {
	Protocol string                `json:"protocol"`
	Host     plugin.BackendProfile `json:"host"`
	Guest    plugin.BackendProfile `json:"guest"`
	Bridge   string                `json:"bridge,omitempty"`
	// Boundary is the guest's: a bridge does not change where the guest is
	// isolated.
	Boundary        string `json:"boundary,omitempty"`
	Concurrent      bool   `json:"concurrent"`
	NativeStreaming bool   `json:"nativeStreaming"`
	NativeCallbacks bool   `json:"nativeCallbacks"`
}

func Resolve

func Resolve(hosts, guests []plugin.BackendProfile, bridges []Bridge, w Requirements) (Route, error)

Resolve selects direct connections first, then a single declared bridge, in caller preference order. Names identify wire bindings, never source languages. Protocols must match end-to-end; this resolver does not translate versions. Requirements describe native transport features, not domain capabilities such as Ext pull-stream operations (which can run over unary transports), and the sandbox boundaries the consumer accepts. A route that meets the transport requirements but not the boundaries is skipped; when every such route was skipped for its boundary the error is plugin.ErrDenied, else plugin.ErrUnsupported (lib/plugin/testdata/v1/route-cases.json).

Jump to

Keyboard shortcuts

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