Documentation
¶
Index ¶
- type Sender
- type Store
- func (s *Store) CleanupExpired(retention time.Duration) int
- func (s *Store) Create(workerID, appID string) Sender
- func (s *Store) HasActive(workerID string) bool
- func (s *Store) HasWorker(workerID string) bool
- func (s *Store) IsEnded(workerID string) bool
- func (s *Store) MarkEnded(workerID string)
- func (s *Store) Subscribe(workerID string) (snapshot []string, live <-chan string, ok bool)
- func (s *Store) WorkerAppID(workerID string) string
- func (s *Store) WorkerIDsByApp(appID string) []WorkerInfo
- type WorkerInfo
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Store ¶
type Store struct {
// contains filtered or unexported fields
}
func (*Store) CleanupExpired ¶
CleanupExpired removes log entries that ended more than `retention` ago.
func (*Store) Create ¶
Create registers a new log stream for a worker. Returns a Sender for writing log lines from the capture goroutine.
func (*Store) HasWorker ¶ added in v0.0.3
HasWorker returns true if the store has a log entry for the given worker ID.
func (*Store) MarkEnded ¶
MarkEnded marks a worker's log stream as ended. Idempotent — safe to call multiple times or on nonexistent workers.
func (*Store) WorkerAppID ¶ added in v0.0.3
WorkerAppID returns the app ID for a worker, or empty string if not found.
func (*Store) WorkerIDsByApp ¶
func (s *Store) WorkerIDsByApp(appID string) []WorkerInfo
WorkerIDsByApp returns worker info for all workers of the given app.
Click to show internal directories.
Click to hide internal directories.