wgactor

package
v0.1.8 Latest Latest
Warning

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

Go to latest
Published: Jan 25, 2026 License: Apache-2.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateActors

func CreateActors(actorCount int, cb func() actor.Worker) []actor.Actor

func NewMonitor added in v0.1.8

func NewMonitor(username, password string, mode MonitorMode, logger *logger.Logger, logInterval time.Duration, outputFolder string) actor.Actor

Types

type Alert added in v0.1.8

type Alert struct {
	Type      string    `json:"type"`
	Message   string    `json:"message"`
	Severity  string    `json:"severity"`
	Timestamp time.Time `json:"timestamp"`
	Action    string    `json:"action"`
}

type DashboardData added in v0.1.8

type DashboardData struct {
	Timestamp       string             `json:"timestamp"`
	CurrentStats    MonitorStats       `json:"currentStats"`
	ProblemRoutines []GoroutineTracker `json:"problemRoutines"`
	MetricsHistory  []MetricPoint      `json:"metricsHistory"`
	Categories      map[string]int     `json:"categories"`
	Alerts          []Alert            `json:"alerts"`
}

type FilterConfig added in v0.1.8

type FilterConfig struct {
	IgnorePatterns      []string      `json:"ignorePatterns"`
	ProblematicPatterns []string      `json:"problematicPatterns"`
	StuckThreshold      time.Duration `json:"stuckThreshold"`
	DeadlockTimeout     time.Duration `json:"deadlockTimeout"`
	MaxHistoryPoints    int           `json:"maxHistoryPoints"`
}

Configuration for filtering patterns

type GoroutineTracker added in v0.1.8

type GoroutineTracker struct {
	ID              string        `json:"id"`
	GoroutineNumber int           `json:"goroutineNumber"`
	FirstSeen       time.Time     `json:"firstSeen"`
	LastSeen        time.Time     `json:"lastSeen"`
	Problem         string        `json:"problem"`
	Location        string        `json:"location"`
	FullStack       string        `json:"fullStack"`
	State           string        `json:"state"`
	StuckDuration   string        `json:"stuckDuration"`
	Severity        string        `json:"severity"`
	RootCause       string        `json:"rootCause"`
	Solution        string        `json:"solution"`
	FunctionName    string        `json:"functionName"`
	LineNumber      string        `json:"lineNumber"`
	BlockedOn       string        `json:"blockedOn"`
	PossibleCauses  []string      `json:"possibleCauses"`
	RealDuration    time.Duration `json:"-"`
	ScansSeen       int           `json:"-"`
	IsActive        bool          `json:"-"`
	WaitingSince    time.Time     `json:"-"`
	LastStackHash   string        `json:"-"`
}

type MetricPoint added in v0.1.8

type MetricPoint struct {
	Timestamp       time.Time     `json:"timestamp"`
	TotalGoroutines int           `json:"totalGoroutines"`
	StuckCount      int           `json:"stuckCount"`
	DeadlockCount   int           `json:"deadlockCount"`
	MemoryMB        float64       `json:"memoryMB"`
	ScanDuration    time.Duration `json:"scanDuration"`
}

type MonitorMode added in v0.1.8

type MonitorMode int
const (
	MonitorModeHTTP MonitorMode = iota
	MonitorModeLog
	MonitorModeFileHTML
	MonitorModeFileJSON
)

type MonitorStats added in v0.1.8

type MonitorStats struct {
	TotalGoroutines int     `json:"totalGoroutines"`
	StuckCount      int     `json:"stuckCount"`
	DeadlockCount   int     `json:"deadlockCount"`
	HealthyCount    int     `json:"healthyCount"`
	MemoryUsage     float64 `json:"memoryUsage"`
	Uptime          string  `json:"uptime"`
	Status          string  `json:"status"`
}

Jump to

Keyboard shortcuts

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