inprocess

package
v1.18.0-rc.3 Latest Latest
Warning

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

Go to latest
Published: May 11, 2026 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Overview

Package inprocess creates and configures the in-process workflow executor used for dapr-internal workflows (e.g. MCP tool calls). The executor runs alongside the sidecar rather than dispatching work to an external SDK via gRPC. Subsystems register their orchestrators and activities after resources are loaded (e.g. MCPServers) to ensure the store is populated.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Executor

type Executor struct {
	// contains filtered or unexported fields
}

Executor wraps a task.TaskExecutor and exposes per-subsystem registrars for in-process workflows that run inside the sidecar. Subsystems (MCP today, others later) live in their own files; the Executor is a thin shell that holds the shared task registry and delegates to each subsystem registrar.

func NewExecutor

func NewExecutor() *Executor

NewExecutor creates an in-process executor with an empty registry. Workflows are registered per-resource via subsystem-specific methods (e.g. RegisterMCPServer).

func (*Executor) Backend

func (e *Executor) Backend() backend.Executor

Backend returns the underlying backend.Executor for use by the workflow engine.

func (*Executor) RegisterMCPServer

func (e *Executor) RegisterMCPServer(ctx context.Context, server mcpserverapi.MCPServer, store *compstore.ComponentStore, sec security.Handler) error

RegisterMCPServer eagerly connects to the MCPServer, discovers its tools, and installs per-tool CallTool workflows plus a ListTools workflow into the shared task registry. Called by the processor on initial load and hot-reload.

func (*Executor) Run

func (e *Executor) Run(ctx context.Context) error

Run blocks until ctx is cancelled, then closes every holder.

func (*Executor) UnregisterMCPServer

func (e *Executor) UnregisterMCPServer(serverName string)

UnregisterMCPServer removes the workflows for a deleted MCPServer.

Directories

Path Synopsis
mcp
v1

Jump to

Keyboard shortcuts

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