diagnostics

package
v2.17.3 Latest Latest
Warning

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

Go to latest
Published: Nov 4, 2026 License: BSD-3-Clause Imports: 22 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DiagnosticsService

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

DiagnosticsService gathers Go runtime, memory, and garbage-collector statistics for the diagnostics endpoints. It holds no external dependencies; WebSocket metrics and worker-goroutine counts are merged in at the handler layer to avoid an import cycle with the api/ws package.

func NewDiagnosticsService

func NewDiagnosticsService(actors *francis.Runtime, coordinator *runs.Coordinator, environments *environment.EnvironmentService) *DiagnosticsService

func (*DiagnosticsService) Collect

func (*DiagnosticsService) CollectActors added in v2.15.0

CollectActors reports this process's Francis host, actor types, and run queue.

func (*DiagnosticsService) CollectAllActors added in v2.15.0

func (s *DiagnosticsService) CollectAllActors(ctx context.Context) []system.ActorDiagnostics

CollectAllActors gathers actor diagnostics from the local and every active remote environment.

func (*DiagnosticsService) Goroutines added in v2.16.0

func (s *DiagnosticsService) Goroutines() (system.GoroutineProfile, error)

Goroutines groups the live goroutines by identical stack, largest group first. Records that differ only by pprof labels share a stack and merge into one group.

func (*DiagnosticsService) Profile added in v2.15.0

func (s *DiagnosticsService) Profile(ctx context.Context, name string, seconds, debugLevel int) ([]byte, error)

Profile captures a pprof profile in the given debug format. The CPU profile and execution trace sample for seconds or until ctx ends.

func (*DiagnosticsService) ScanGoroutineLeaks added in v2.9.0

func (s *DiagnosticsService) ScanGoroutineLeaks() (system.GoroutineLeakReport, error)

ScanGoroutineLeaks runs a leak-detection GC and returns the leaked-goroutine pprof text (debug=1). debug=2 would dump every goroutine, not only leaks.

Jump to

Keyboard shortcuts

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