Documentation ¶
Index ¶
- Constants
- Variables
- type Filter
- type Historian
- func (h *Historian) Close() error
- func (h *Historian) Each(filter *Filter, cb func(item *Item) error) error
- func (h *Historian) EachItem(filter *Filter, exampleItem interface{}, cb func(item interface{}) error) error
- func (h *Historian) Get(id uint64) (*Item, error)
- func (h *Historian) Len() uint
- func (h *Historian) Put(item *Item) error
- type Item
Constants ¶
View Source
const DefaultTTL = 30 * 24 * time.Hour
Variables ¶
View Source
var ErrStop = errors.New("stop")
Indiate when Each should stop executing and return cleanly.
Functions ¶
This section is empty.
Types ¶
type Item ¶
type Item struct { ID uint64 `json:"id"` RecordedAt time.Time `json:"recorded_at"` WorkingDir string `json:"working_dir"` CommandLine string `json:"command_line,omitempty"` ParentPID *int `json:"parent_pid,omitempty"` ExitStatus *int `json:"exit_status,omitempty"` Duration time.Duration `json:"duration,omitempty"` }
TODO: add current working directory for each item (and pass along to slurp)
func (*Item) StringWithOpts ¶
Click to show internal directories.
Click to hide internal directories.