Code generalization: request db info from other source: remove unused constants

This commit is contained in:
Michael Hohn
2024-10-28 18:45:21 -07:00
committed by =Michael Hohn
parent 52aafd6fc9
commit e7d32861e5
5 changed files with 20 additions and 33 deletions

View File

@@ -5,22 +5,16 @@ import (
"mrvacommander/pkg/common"
)
// xx: afl use
// XX: static types: split by type?
// Restrict the keys / values for ArtifactLocation and centralize the common ones
// here
const (
AF_VAL_BUCKET_RESULTS = "results"
AF_VAL_BUCKET_PACKS = "packs"
AF_KEY_BUCKET = "bucket"
AF_KEY_KEY = "key"
AF_BUCKETNAME_RESULTS = "results"
AF_BUCKETNAME_PACKS = "packs"
)
type ArtifactLocation struct {
// Data is a map of key-value pairs that describe the location of the artifact.
// For example, a simple key-value pair could be "path" -> "/path/to/artifact.tgz".
// Alternatively, a more complex example could be "bucket" -> "example", "key" -> "UNIQUE_ARTIFACT_IDENTIFIER".
// XX: static types
// Data map[string]string `json:"data"`
Key string // location in bucket
Bucket string // which bucket: packs or results
}