Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type SandboxStore ¶
type SandboxStore interface {
// Save persists a sandbox with the configured TTL.
Save(sandbox domain.Sandbox) error
// Get retrieves a sandbox by namespace+sandboxID. Returns nil, nil if not found.
Get(namespace, sandboxID string) (*domain.Sandbox, error)
// List returns all sandboxes for the given namespace, sorted by claimedAt desc.
List(namespace string) ([]domain.Sandbox, error)
// Close closes the underlying store.
Close() error
}
SandboxStore is the interface for persisting historical Sandbox records.
func NewSandboxStore ¶
func NewSandboxStore(ttl time.Duration) (SandboxStore, error)
NewSandboxStore creates an in-memory buntdb SandboxStore with the given TTL. If ttl <= 0, defaultTTL (24h) is used.
Click to show internal directories.
Click to hide internal directories.