Versions in this module Expand all Collapse all v0 v0.3.0 Nov 29, 2026 v0.2.0 Nov 29, 2026 Changes in this version + var ErrAmbiguous = errors.New("more than one segments document defines this segment") + var ErrNoConnection = errors.New("the bootstrap file does not define the connection of the segment") + var ErrNoControlPlane = errors.New("give --segments, or a bootstrap file with a controlPlane section") + var ErrNoInput = errors.New("give at least one id, or --from <file|->") + var ErrNoSegment = errors.New("the segments document does not define this segment") + var ErrNoSegmentsObject = errors.New("the manifest lists no segments object") + var ErrNoStore = errors.New("the connection holds no objects (it must be s3 or file)") + var ErrNoVersionKey = errors.New("the definition has no version.key to bump") + var ErrNotStore = errors.New("the connection of the segment is not a valkey or redis connection") + var ErrSourceConnection = errors.New("no s3 connection for the source") + var ErrStatic = errors.New("the segment is static (no connection): its members are in the document") + func HelpVars() kong.Vars + func Run(ctx context.Context, args []string, streams *helper.Streams, deps *Deps) error + type AddCmd struct + From string + IDs []string + func (cmd *AddCmd) Run(ctx context.Context, parent *Cmd, streams *helper.Streams, deps *Deps) error + type BumpCmd struct + func (cmd *BumpCmd) Run(ctx context.Context, parent *Cmd, streams *helper.Streams, deps *Deps) error + type Cmd struct + Add AddCmd + Bump BumpCmd + Debug bool + Import ImportCmd + Remove RemoveCmd + Stat StatCmd + Sync SyncCmd + type Common struct + Config string + Segment string + Segments string + type Connector func(context.Context, *bootstrap.Connection, bootstrap.LoadOptions) (segmentadmin.Store, error) + type Deps struct + Connect Connector + ConnectionOptions []connection.Option + LookupEnv func(string) (string, bool) + NewS3 func(ctx context.Context, spec *connection.S3Spec, name string) (S3Client, error) + Open func(string) (io.ReadCloser, error) + ReadFile func(string) ([]byte, error) + Stdin io.Reader + func DefaultDeps() Deps + type ImportCmd struct + AllowEmpty bool + BatchSize int + Column int + DryRun bool + Format string + From string + MaxLineBytes int + MaxObjects int + SourceConnection string + TempTTL time.Duration + func (cmd *ImportCmd) Run(ctx context.Context, parent *Cmd, streams *helper.Streams, deps *Deps) error + type RemoveCmd struct + From string + IDs []string + func (cmd *RemoveCmd) Run(ctx context.Context, parent *Cmd, streams *helper.Streams, deps *Deps) error + type S3Client interface + GetObject func(ctx context.Context, in *s3.GetObjectInput, opts ...func(*s3.Options)) (*s3.GetObjectOutput, error) + HeadObject func(ctx context.Context, in *s3.HeadObjectInput, opts ...func(*s3.Options)) (*s3.HeadObjectOutput, error) + ListObjectsV2 func(ctx context.Context, in *s3.ListObjectsV2Input, opts ...func(*s3.Options)) (*s3.ListObjectsV2Output, error) + type S3Objects struct + func NewS3Objects(client S3Client, bucket string) *S3Objects + func (o *S3Objects) Get(ctx context.Context, key, etag string) (segmentadmin.Object, error) + func (o *S3Objects) Head(ctx context.Context, key string) (segmentadmin.ObjectInfo, error) + func (o *S3Objects) List(ctx context.Context, prefix, token string) (segmentadmin.ObjectPage, error) + type StatCmd struct + ScanLimit int + func (cmd *StatCmd) Run(ctx context.Context, parent *Cmd, streams *helper.Streams, deps *Deps) error + type SyncCmd struct + AllowEmpty bool + BatchSize int + Column int + Format string + From string + Interval time.Duration + MaxLineBytes int + MaxObjects int + Once bool + SourceConnection string + TempTTL time.Duration + func (cmd *SyncCmd) Run(ctx context.Context, parent *Cmd, streams *helper.Streams, deps *Deps) error