Refactor code structure for improved readability and maintainability; optimize performance in key functions.
This commit is contained in:
@@ -0,0 +1,112 @@
|
||||
{
|
||||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||||
"$id": "https://stellaops.io/schemas/offline-bundle/v1",
|
||||
"title": "StellaOps Offline Bundle Manifest",
|
||||
"type": "object",
|
||||
"required": [
|
||||
"bundleId",
|
||||
"schemaVersion",
|
||||
"name",
|
||||
"version",
|
||||
"createdAt",
|
||||
"feeds",
|
||||
"policies",
|
||||
"cryptoMaterials",
|
||||
"totalSizeBytes"
|
||||
],
|
||||
"properties": {
|
||||
"bundleId": { "type": "string" },
|
||||
"schemaVersion": { "type": "string" },
|
||||
"name": { "type": "string" },
|
||||
"version": { "type": "string" },
|
||||
"createdAt": { "type": "string", "format": "date-time" },
|
||||
"expiresAt": { "type": ["string", "null"], "format": "date-time" },
|
||||
"feeds": { "type": "array", "items": { "$ref": "#/$defs/feed" } },
|
||||
"policies": { "type": "array", "items": { "$ref": "#/$defs/policy" } },
|
||||
"cryptoMaterials": { "type": "array", "items": { "$ref": "#/$defs/crypto" } },
|
||||
"catalogs": { "type": "array", "items": { "$ref": "#/$defs/catalog" } },
|
||||
"rekorSnapshot": { "$ref": "#/$defs/rekorSnapshot" },
|
||||
"cryptoProviders": { "type": "array", "items": { "$ref": "#/$defs/cryptoProvider" } },
|
||||
"totalSizeBytes": { "type": "integer" },
|
||||
"bundleDigest": { "type": ["string", "null"] }
|
||||
},
|
||||
"$defs": {
|
||||
"feed": {
|
||||
"type": "object",
|
||||
"required": ["feedId", "name", "version", "relativePath", "digest", "sizeBytes", "snapshotAt", "format"],
|
||||
"properties": {
|
||||
"feedId": { "type": "string" },
|
||||
"name": { "type": "string" },
|
||||
"version": { "type": "string" },
|
||||
"relativePath": { "type": "string" },
|
||||
"digest": { "type": "string" },
|
||||
"sizeBytes": { "type": "integer" },
|
||||
"snapshotAt": { "type": "string", "format": "date-time" },
|
||||
"format": { "type": "string" }
|
||||
}
|
||||
},
|
||||
"policy": {
|
||||
"type": "object",
|
||||
"required": ["policyId", "name", "version", "relativePath", "digest", "sizeBytes", "type"],
|
||||
"properties": {
|
||||
"policyId": { "type": "string" },
|
||||
"name": { "type": "string" },
|
||||
"version": { "type": "string" },
|
||||
"relativePath": { "type": "string" },
|
||||
"digest": { "type": "string" },
|
||||
"sizeBytes": { "type": "integer" },
|
||||
"type": { "type": "string" }
|
||||
}
|
||||
},
|
||||
"crypto": {
|
||||
"type": "object",
|
||||
"required": ["componentId", "name", "relativePath", "digest", "sizeBytes", "type"],
|
||||
"properties": {
|
||||
"componentId": { "type": "string" },
|
||||
"name": { "type": "string" },
|
||||
"relativePath": { "type": "string" },
|
||||
"digest": { "type": "string" },
|
||||
"sizeBytes": { "type": "integer" },
|
||||
"type": { "type": "string" },
|
||||
"expiresAt": { "type": ["string", "null"], "format": "date-time" }
|
||||
}
|
||||
},
|
||||
"catalog": {
|
||||
"type": "object",
|
||||
"required": ["catalogId", "ecosystem", "version", "relativePath", "digest", "sizeBytes", "snapshotAt"],
|
||||
"properties": {
|
||||
"catalogId": { "type": "string" },
|
||||
"ecosystem": { "type": "string" },
|
||||
"version": { "type": "string" },
|
||||
"relativePath": { "type": "string" },
|
||||
"digest": { "type": "string" },
|
||||
"sizeBytes": { "type": "integer" },
|
||||
"snapshotAt": { "type": "string", "format": "date-time" }
|
||||
}
|
||||
},
|
||||
"rekorSnapshot": {
|
||||
"type": ["object", "null"],
|
||||
"properties": {
|
||||
"treeId": { "type": "string" },
|
||||
"treeSize": { "type": "integer" },
|
||||
"rootHash": { "type": "string" },
|
||||
"relativePath": { "type": "string" },
|
||||
"digest": { "type": "string" },
|
||||
"snapshotAt": { "type": "string", "format": "date-time" }
|
||||
}
|
||||
},
|
||||
"cryptoProvider": {
|
||||
"type": "object",
|
||||
"required": ["providerId", "name", "version", "relativePath", "digest", "sizeBytes", "supportedAlgorithms"],
|
||||
"properties": {
|
||||
"providerId": { "type": "string" },
|
||||
"name": { "type": "string" },
|
||||
"version": { "type": "string" },
|
||||
"relativePath": { "type": "string" },
|
||||
"digest": { "type": "string" },
|
||||
"sizeBytes": { "type": "integer" },
|
||||
"supportedAlgorithms": { "type": "array", "items": { "type": "string" } }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user