Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Core Schema Draft #10

Draft
wants to merge 4 commits into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
63 changes: 63 additions & 0 deletions schema/openeox_core_json_schema.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://docs.oasis-open.org/openeox/tbd/openeox_core_json_schema.json",
tschmidtb51 marked this conversation as resolved.
Show resolved Hide resolved
"title": "EOL and EOS Information",
"description": "A draft schema for representing End-of-Life (EOL) and End-of-Support (EOS) information in OpenEoX.",
"type": "object",
"$defs": {
"schema_t": {
"title": "OpenEoX Core schema",
"description": "Specifies the schema the JSON object must be valid against.",
"type": "string",
"enum": [
"https://docs.oasis-open.org/openeox/tbd/openeox_core_json_schema.json"
tschmidtb51 marked this conversation as resolved.
Show resolved Hide resolved
]
}
},
"required": ["$schema", "last_updated", "status"],
"properties": {
"$schema": {
"$ref": "#/$defs/schema_t"
},
"last_updated": {
"title": "Timestamp of last change",
"description": "Contains the RFC 3339 timestamp when the record was last updated.",
"type": "string",
"format": "date-time"
},
"status": {
"title": "List of status",
"description": "Contains a list of status elements.",
"type": "array",
"minItems": 1,
"uniqueItems": true,
"items": {
"title": "Status",
"description": "Contains a single entry in the product lifecycle.",
"type": "object",
"required": ["category", "timestamp"],
"properties": {
"category": {
"title": "Status category",
"description": "Contains the category of the status",
"type": "string",
"enum": ["EndOfLife", "EndOfSupport"]
},
"timestamp": {
"title": "Timestamp",
"description": "Contains the timestamp at which the product enters the category.",
"type": "string",
"oneOf": [
{
"format": "date-time"
},
{
"enum": ["tba"]
}
]
}
}
}
}
}
}
70 changes: 70 additions & 0 deletions schema/openeox_shell_json_schema.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://docs.oasis-open.org/openeox/tbd/openeox_shell_json_schema.json",
tschmidtb51 marked this conversation as resolved.
Show resolved Hide resolved
"title": "EOL and EOS Information",
"description": "A draft schema for representing End-of-Life (EOL) and End-of-Support (EOS) information in OpenEoX.",
"type": "object",
"$defs": {
"productName_t": {
"title": "Product name",
"description": "Contains the name of the product.",
"type": "string",
"minLength": 1
},
"productVersion_t": {
"title": "Product version",
"description": "Contains the version or release of the product.",
"type": "string",
"minLength": 1
},
"supplierName_t": {
"title": "Supplier name",
"description": "Contains the name of the supplier or service provider.",
"type": "string",
"minLength": 1
},
"schema_t": {
"title": "OpenEoX Shell schema",
"description": "Specifies the schema the JSON object must be valid against.",
"type": "string",
"enum": [
"https://docs.oasis-open.org/openeox/tbd/openeox_shell_json_schema.json"
tschmidtb51 marked this conversation as resolved.
Show resolved Hide resolved
]
}
},
"required": [
"$schema",
"statements"
],
"properties": {
"$schema": {
"$ref": "#/$defs/schema_t"
},
"statements": {
"title": "List of statements",
"description": "Contains a list of statement elements.",
"type": "array",
"minItems": 1,
"items": {
"title": "Statement",
"description": "Statements contain the single OpenEoX entries.",
"type": "object",
"required": ["core", "productName", "productVersion", "supplierName"],
"properties": {
"core": {
"$ref": "https://docs.oasis-open.org/openeox/tbd/openeox_core_json_schema.json"
},
"productName": {
"$ref": "#/$defs/productName_t"
},
"productVersion": {
"$ref": "#/$defs/productVersion_t"
},
"supplierName": {
"$ref": "#/$defs/supplierName_t"
}
}
}
}
}
}