Documentation
¶
Index ¶
- Constants
- type HistoryRepo
- type Option
- type Service
- func (s *Service) GetHistory(ctx context.Context, ticketID types.TicketID, historyID types.HistoryID) (*gollem.History, error)
- func (s *Service) GetLatestHistory(ctx context.Context, ticketID types.TicketID) (*gollem.History, error)
- func (s *Service) PutHistory(ctx context.Context, ticketID types.TicketID, historyID types.HistoryID, ...) error
- func (s *Service) PutLatestHistory(ctx context.Context, ticketID types.TicketID, history *gollem.History) error
Constants ¶
View Source
const (
StorageSchemaVersion = "v1"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type HistoryRepo ¶ added in v0.12.0
type HistoryRepo struct {
// contains filtered or unexported fields
}
HistoryRepo implements gollem.HistoryRepository using the storage service. It persists the latest history snapshot for a ticket, keyed by ticket ID. Save errors are handled via errutil but not returned to avoid interrupting agent execution.
func NewHistoryRepo ¶ added in v0.12.0
func NewHistoryRepo(svc *Service, ticketID types.TicketID) *HistoryRepo
NewHistoryRepo creates a new HistoryRepo for the given ticket.
func NewHistoryRepoFromContext ¶ added in v0.12.0
func NewHistoryRepoFromContext(_ context.Context, svc *Service, ticketID types.TicketID) *HistoryRepo
NewHistoryRepoFromContext creates a new HistoryRepo for the given ticket.
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
func New ¶
func New(storageClient interfaces.StorageClient, opts ...Option) *Service
func (*Service) GetHistory ¶
func (*Service) GetLatestHistory ¶ added in v0.12.0
func (s *Service) GetLatestHistory(ctx context.Context, ticketID types.TicketID) (*gollem.History, error)
GetLatestHistory retrieves the latest history snapshot for the given ticket. Returns nil History and nil error if the storage client is not configured.
func (*Service) PutHistory ¶
Click to show internal directories.
Click to hide internal directories.