Documentation
¶
Index ¶
Constants ¶
View Source
const ( InvalidateResultCacheKind = "query.invalidate_result_cache" InvalidateResultCacheSchemaVersion = 1 )
Variables ¶
This section is empty.
Functions ¶
func EnqueueInvalidationTx ¶
func EnqueueInvalidationTx( ctx context.Context, dispatcher *supportjobs.Dispatcher, tx pgx.Tx, owner string, tags []string, ) (*rivertype.JobInsertResult, error)
func Register ¶
func Register( registry *supportjobs.Registry, invalidator queryregistry.SemanticCacheInvalidator, logger *slog.Logger, )
Types ¶
type InvalidateResultCacheArgs ¶
type InvalidateResultCacheArgs struct {
SchemaVersion int `json:"schema_version"`
OwnerExtensionID string `json:"owner_extension_id"`
Tags []string `json:"tags"`
}
InvalidateResultCacheArgs carries only stable owner identity and canonical logical tags. Physical Redis material and exact runtime identity are derived by the Host at execution time and must never enter River rows.
func NewInvalidateResultCacheArgs ¶
func NewInvalidateResultCacheArgs(owner string, tags []string) (InvalidateResultCacheArgs, error)
func (InvalidateResultCacheArgs) Kind ¶
func (InvalidateResultCacheArgs) Kind() string
func (InvalidateResultCacheArgs) QueueOpts ¶
func (InvalidateResultCacheArgs) QueueOpts() supportjobs.EnqueueOptions
type InvalidateResultCacheWorker ¶
type InvalidateResultCacheWorker struct {
river.WorkerDefaults[InvalidateResultCacheArgs]
Invalidator queryregistry.SemanticCacheInvalidator
Logger *slog.Logger
}
func (*InvalidateResultCacheWorker) Work ¶
func (w *InvalidateResultCacheWorker) Work( ctx context.Context, job *river.Job[InvalidateResultCacheArgs], ) error
Click to show internal directories.
Click to hide internal directories.