entities

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Oct 22, 2025 License: MIT Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type HealthResponse

type HealthResponse struct {
	Status    string            `json:"status"`
	Timestamp int64             `json:"timestamp"`
	Checks    map[string]string `json:"checks"`
}

type Host

type Host struct {
	ID        int64  `json:"id" db:"id"`
	Hostname  string `json:"hostname" db:"hostname"`
	IPAddress string `json:"ip_address" db:"ip_address"`
	Role      string `json:"role" db:"role"`
}

type HostQueryParams

type HostQueryParams struct {
	ID        int64  `form:"id"`
	Hostname  string `form:"hostname"`
	IPAddress string `form:"ip_address"`
}

type MetricLatestQueryParams

type MetricLatestQueryParams struct {
	HostID *int64 `form:"host_id"`
}

type MetricQueryParams

type MetricQueryParams struct {
	HostID    *int64 `form:"host_id"`
	StartTime *int64 `form:"start_time"`
	EndTime   *int64 `form:"end_time"`
	Limit     int    `form:"limit"`
	Order     string `form:"order"` // "asc" or "desc"
}

type SystemMetric

type SystemMetric struct {
	ID                   int64   `json:"id" db:"id"`
	HostID               int64   `json:"host_id" db:"host_id"`
	Timestamp            int64   `json:"timestamp" db:"timestamp"`
	CPUUsage             float64 `json:"cpu_usage" db:"cpu_usage"`
	MemoryUsagePercent   float64 `json:"memory_usage_percent" db:"memory_usage_percent"`
	MemoryTotalBytes     int64   `json:"memory_total_bytes" db:"memory_total_bytes"`
	MemoryUsedBytes      int64   `json:"memory_used_bytes" db:"memory_used_bytes"`
	MemoryAvailableBytes int64   `json:"memory_available_bytes" db:"memory_available_bytes"`
	DiskUsagePercent     float64 `json:"disk_usage_percent" db:"disk_usage_percent"`
	DiskTotalBytes       int64   `json:"disk_total_bytes" db:"disk_total_bytes"`
	DiskUsedBytes        int64   `json:"disk_used_bytes" db:"disk_used_bytes"`
	DiskAvailableBytes   int64   `json:"disk_available_bytes" db:"disk_available_bytes"`
}

Jump to

Keyboard shortcuts

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