copycompletion

command
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Nov 24, 2026 License: MIT Imports: 10 Imported by: 0 modules, 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

Command copycompletion is the deployable Lambda entrypoint that closes the loop on a dataset copy. A copy runs for hours or days, so no command waits on it; the copy service announces its terminal state on the event bus, an EventBridge rule delivers that here, and the copy record is moved to staged or failed.

It is wiring only: it reads configuration from the environment, constructs clients from the Lambda execution role, and delegates to dataset.CopyCompletionHandler. Matching an event to a copy, deciding what to record, and deciding what is worth retrying all live there, where they are testable without a deployment.

It is handed a copy ledger and nothing else. Recording what a transfer delivered has no business reaching a grant: who may read the data is decided by the commands, from a record this entrypoint cannot see and would have no reason to write.

The handler returns an error only for a failure another attempt could get past, so a non-nil error here is a genuine invitation to retry. An event that names a copy nothing is waiting on, or a copy that has already reported, is not a failure and is logged as nothing to do.

Environment variables (read once at cold start):

SHARE_RECORDS_TABLE_NAME  (required) DynamoDB table holding the ledger, shared with
                          the htsget mechanism.

The execution role needs write access to that table, permission to describe executions of the copy state machine, and read access to the copy service's working bucket -- where the copy retains its summary of what it moved. It deliberately needs no access to any dataset's own bucket or key.

Jump to

Keyboard shortcuts

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