Documentation
¶
Index ¶
Constants ¶
View Source
const ( HeaderFile = "atlas.json" DiagnosticsFile = "diagnostics.jsonl" ShardsDir = "shards" )
View Source
const ( SchemaVersion = "gonimbus.atlas.v1" HashProfileSHA256 = "sha256" DimensionTemporalDay = "temporal-day" DimensionTemporalInstant = "temporal-instant" DimensionCategorical = "categorical" ClassificationUnknown = "unknown" ClassificationPublic = "0-public" ClassificationConfidential = "1-confidential" ClassificationBlinded = "2-blinded" ClassificationProprietary = "3-proprietary" ClassificationPersonal = "4-personal" ClassificationPrivileged = "5-privileged" ClassificationEyesOnly = "6-eyes-only" CoverageFull = "full" CoverageScoped = "scoped" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BuildOptions ¶
type BuildResult ¶
func Build ¶
func Build(ctx context.Context, opts BuildOptions) (*BuildResult, error)
type Counts ¶
type Counts struct {
ObjectsScanned int64 `json:"objects_scanned"`
RowsWritten int64 `json:"rows_written"`
Diagnostics int64 `json:"diagnostics"`
ReadFailures int64 `json:"read_failures"`
ExtractionFailures int64 `json:"extraction_failures"`
ValidationFailures int64 `json:"validation_failures"`
ArtifactWriteFailure int64 `json:"artifact_write_failures,omitempty"`
}
type DiagnosticRow ¶
type DiagnosticRow struct {
SchemaVersion string `json:"schema_version"`
SourceIndexSetID string `json:"source_index_set_id"`
SourceRunID string `json:"source_run_id"`
StorageKey string `json:"storage_key"`
RelKey string `json:"rel_key"`
Stage string `json:"stage"`
Code string `json:"code"`
Message string `json:"message"`
OccurredAt time.Time `json:"occurred_at"`
}
type DimensionDeclaration ¶
type DimensionRecipe ¶
type DimensionRecipe struct {
Name string `json:"name" yaml:"name"`
Kind string `json:"kind" yaml:"kind"`
From string `json:"from,omitempty" yaml:"from,omitempty"`
Classification string `json:"classification,omitempty" yaml:"classification,omitempty"`
Extractor probe.ExtractorConfig `json:"extractor" yaml:"extractor"`
}
type FieldPolicy ¶
type FieldPolicy struct {
Classification string `json:"classification" yaml:"classification"`
}
type Header ¶
type Header struct {
SchemaVersion string `json:"schema_version"`
AtlasID string `json:"atlas_id"`
CreatedAt time.Time `json:"created_at"`
SourceIndexSetID string `json:"source_index_set_id"`
SourceRunID string `json:"source_run_id"`
BaseURI string `json:"base_uri"`
ScopeDigest string `json:"scope_digest"`
RecipeDigest string `json:"recipe_digest"`
HashProfile string `json:"hash_profile"`
Coverage string `json:"coverage"`
ShardBy []string `json:"shard_by"`
Dimensions []DimensionDeclaration `json:"dimensions"`
SystemFields []SystemFieldDeclaration `json:"system_fields"`
Counts Counts `json:"counts"`
}
func ReadHeader ¶
type ObjectRow ¶
type ObjectRow struct {
SchemaVersion string `json:"schema_version"`
SourceIndexSetID string `json:"source_index_set_id"`
SourceRunID string `json:"source_run_id"`
StorageKey string `json:"storage_key"`
RelKey string `json:"rel_key"`
SourceURI string `json:"source_uri"`
ContentHash string `json:"content_hash"`
HashProfile string `json:"hash_profile"`
Dimensions map[string]string `json:"dimensions"`
Shard map[string]string `json:"shard"`
SizeBytes int64 `json:"size_bytes"`
ETag string `json:"etag,omitempty"`
FirstSeenRunID string `json:"first_seen_run_id"`
FirstSeenAt time.Time `json:"first_seen_at"`
}
type Recipe ¶
type Recipe struct {
Schema string `json:"$schema,omitempty" yaml:"$schema,omitempty"`
Version string `json:"version,omitempty" yaml:"version,omitempty"`
Hash string `json:"hash,omitempty" yaml:"hash,omitempty"`
Coverage string `json:"coverage,omitempty" yaml:"coverage,omitempty"`
Dimensions []DimensionRecipe `json:"dimensions" yaml:"dimensions"`
ShardBy []string `json:"shard_by" yaml:"shard_by"`
SystemFields map[string]FieldPolicy `json:"system_fields,omitempty" yaml:"system_fields,omitempty"`
}
func LoadRecipeFile ¶
func (Recipe) DimensionDeclarations ¶
func (r Recipe) DimensionDeclarations() []DimensionDeclaration
func (Recipe) ProbeConfig ¶
func (Recipe) SystemFieldDeclarations ¶
func (r Recipe) SystemFieldDeclarations() []SystemFieldDeclaration
type SourceObject ¶
type Stats ¶
type Stats struct {
Header Header `json:"header"`
Tier1Keys int64 `json:"tier1_keys"`
Tier2Content int64 `json:"tier2_content"`
Tier3Shards int64 `json:"tier3_shard_content"`
Diagnostics int64 `json:"diagnostics"`
ShardFiles int `json:"shard_files"`
}
func ComputeStats ¶
type SystemFieldDeclaration ¶
type SystemFieldDeclaration struct {
Name string `json:"name"`
Classification string `json:"classification"`
}
func DefaultSystemFields ¶
func DefaultSystemFields() []SystemFieldDeclaration
Click to show internal directories.
Click to hide internal directories.