factory

package
v0.11.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 26, 2026 License: BSD-2-Clause Imports: 10 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package factory wires concrete dependencies for the go-version-watcher binary.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateKafkaCompleteSender added in v0.11.0

func CreateKafkaCompleteSender(
	syncProducer libkafka.SyncProducer,
	topicPrefix base.TopicPrefix,
	defaultVault string,
) task.CompleteCommandSender

CreateKafkaCompleteSender constructs a typed complete-task command sender backed by the same Kafka sync producer used for task creation. defaultVault is the Obsidian vault slug substituted into each command's TargetVault when unset (empty = controller default, openclaw).

This is how a one-shot Job closes its own check task: the executor passes the task's identifier as TASK_ID, and a succeeded Job that leaves its task open is suppressed then parked at human_review instead of reaching a terminal state.

func CreateKafkaNotificationSender added in v0.8.0

func CreateKafkaNotificationSender(
	ctx context.Context,
	syncProducer libkafka.SyncProducer,
	topicPrefix base.TopicPrefix,
) notification.NotificationPublishCommandSender

CreateKafkaNotificationSender constructs a typed notification-publish command sender backed by the same Kafka sync producer used for task commands. The CDB sender derives the topic ({branch}-core-notification-v1-request) from core.NotificationV1SchemaID + topicPrefix. ctx feeds the request-ID channel so downstream cancellation propagates.

func CreateKafkaSender

func CreateKafkaSender(
	syncProducer libkafka.SyncProducer,
	topicPrefix base.TopicPrefix,
	defaultVault string,
) task.CreateCommandSender

CreateKafkaSender constructs a typed create-task command sender backed by a Kafka sync producer. defaultVault is the Obsidian vault slug substituted into each command's TargetVault when unset (empty = controller default, openclaw).

func CreateWatcher

func CreateWatcher(
	httpClient *http.Client,
	sender task.CreateCommandSender,
	notificationSender notification.NotificationPublishCommandSender,
	cursorPath string,
	metrics pkg.Metrics,
	cfg pkg.TaskConfig,
	seedVersion string,
) pkg.Watcher

CreateWatcher wires all dependencies and returns a ready-to-use Watcher.

Pure composition — no I/O. The Kafka sync producer and the task sender are constructed by the caller (so it controls connection lifecycle + cleanup).

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL