diff --git a/kcidb/db/schema.py b/kcidb/db/schema.py index 254a8817..e9a13df0 100644 --- a/kcidb/db/schema.py +++ b/kcidb/db/schema.py @@ -13,6 +13,10 @@ # Test environment fields ENVIRONMENT_FIELDS = ( + Field( + "origin_url", "STRING", + description="The URL of the environment in the origin CI system", + ), Field( "description", "STRING", description="Human-readable description of the environment", @@ -36,6 +40,10 @@ description="The name of the CI system which submitted " "the revision", ), + Field( + "origin_url", "STRING", + description="The URL of the revision in the origin CI system", + ), Field( "tree_name", "STRING", description="The widely-recognized name of the sub-tree (fork) " @@ -128,6 +136,10 @@ description="The name of the CI system which submitted " "the build", ), + Field( + "origin_url", "STRING", + description="The URL of the build in the origin CI system", + ), Field( "description", "STRING", description="Human-readable description of the build", @@ -199,6 +211,10 @@ description="The name of the CI system which submitted " "the test run", ), + Field( + "origin_url", "STRING", + description="The URL of the test run in the origin CI system", + ), Field( "environment", "RECORD", fields=ENVIRONMENT_FIELDS, description="The environment the test ran in. " diff --git a/kcidb/io/schema/v3.py b/kcidb/io/schema/v3.py index 61d394fb..9ecb01c8 100644 --- a/kcidb/io/schema/v3.py +++ b/kcidb/io/schema/v3.py @@ -119,6 +119,11 @@ "The name of the CI system which submitted the revision", "pattern": f"^{ORIGIN_PATTERN}$", }, + "origin_url": { + "type": "string", + "format": "uri", + "description": "The URL of the revision in the origin CI system", + }, "tree_name": { "type": "string", "description": @@ -265,6 +270,15 @@ "The name of the CI system which submitted the build", "pattern": f"^{ORIGIN_PATTERN}$", }, + "origin_url": { + "type": "string", + "format": "uri", + "description": "The URL of the build in the origin CI system", + "examples": [ + "https://kernelci.org/build/net-next/branch/master/" + "kernel/v5.8-rc4-1414-g4ff91fa0a3ac/", + ], + }, "description": { "type": "string", "description": @@ -389,6 +403,14 @@ "The name of the CI system which submitted the test run", "pattern": f"^{ORIGIN_PATTERN}$", }, + "origin_url": { + "type": "string", + "format": "uri", + "description": "The URL of the test run in the origin CI system", + "examples": [ + "https://kernelci.org/test/case/id/5f0e86fc459ceb8c2885bb39/", + ], + }, "environment": { "type": "object", "description": @@ -397,6 +419,13 @@ "amount of memory/storage/CPUs, for each host; " "process environment variables, etc.", "properties": { + "origin_url": { + "type": "string", + "format": "uri", + "description": + "The URL of the environment in the origin CI system", + "examples": ["https://kernelci.org/soc/allwinner/"], + }, "description": { "type": "string", "description":