Implement AggregationSourceCollection
This is an intermediate step in setting up aggregation sources. A
future patch will add aggregation sources based on the existence of
satellite configs. For now the collection will always return as 0
members.
Adds the AggregationSourceCollection schema which we previously
ignored.
Tested:
Service Validator passes
Signed-off-by: Carson Labrado <clabrado@google.com>
Change-Id: I65c9231289bf0a9b6392696d55bc3feb0023c694
diff --git a/static/redfish/v1/$metadata/index.xml b/static/redfish/v1/$metadata/index.xml
index 0ef12fa..92bcc09 100644
--- a/static/redfish/v1/$metadata/index.xml
+++ b/static/redfish/v1/$metadata/index.xml
@@ -118,6 +118,9 @@
<edmx:Include Namespace="AggregationService.v1_0_0"/>
<edmx:Include Namespace="AggregationService.v1_0_1"/>
</edmx:Reference>
+ <edmx:Reference Uri="/redfish/v1/schema/AggregationSourceCollection_v1.xml">
+ <edmx:Include Namespace="AggregationSourceCollection"/>
+ </edmx:Reference>
<edmx:Reference Uri="/redfish/v1/schema/Assembly_v1.xml">
<edmx:Include Namespace="Assembly"/>
<edmx:Include Namespace="Assembly.v1_0_0"/>
diff --git a/static/redfish/v1/JsonSchemas/AggregationSourceCollection/AggregationSourceCollection.json b/static/redfish/v1/JsonSchemas/AggregationSourceCollection/AggregationSourceCollection.json
new file mode 100644
index 0000000..64ce2d4
--- /dev/null
+++ b/static/redfish/v1/JsonSchemas/AggregationSourceCollection/AggregationSourceCollection.json
@@ -0,0 +1,99 @@
+{
+ "$id": "http://redfish.dmtf.org/schemas/v1/AggregationSourceCollection.json",
+ "$ref": "#/definitions/AggregationSourceCollection",
+ "$schema": "http://redfish.dmtf.org/schemas/v1/redfish-schema-v1.json",
+ "copyright": "Copyright 2014-2022 DMTF. For the full DMTF copyright policy, see http://www.dmtf.org/about/policies/copyright",
+ "definitions": {
+ "AggregationSourceCollection": {
+ "anyOf": [
+ {
+ "$ref": "http://redfish.dmtf.org/schemas/v1/odata-v4.json#/definitions/idRef"
+ },
+ {
+ "additionalProperties": false,
+ "description": "The collection of AggregationSource resource instances.",
+ "longDescription": "This resource shall represent a resource collection of AggregationSource instances for a Redfish implementation.",
+ "patternProperties": {
+ "^([a-zA-Z_][a-zA-Z0-9_]*)?@(odata|Redfish|Message)\\.[a-zA-Z_][a-zA-Z0-9_]*$": {
+ "description": "This property shall specify a valid odata or Redfish property.",
+ "type": [
+ "array",
+ "boolean",
+ "integer",
+ "number",
+ "null",
+ "object",
+ "string"
+ ]
+ }
+ },
+ "properties": {
+ "@odata.context": {
+ "$ref": "http://redfish.dmtf.org/schemas/v1/odata-v4.json#/definitions/context"
+ },
+ "@odata.etag": {
+ "$ref": "http://redfish.dmtf.org/schemas/v1/odata-v4.json#/definitions/etag"
+ },
+ "@odata.id": {
+ "$ref": "http://redfish.dmtf.org/schemas/v1/odata-v4.json#/definitions/id"
+ },
+ "@odata.type": {
+ "$ref": "http://redfish.dmtf.org/schemas/v1/odata-v4.json#/definitions/type"
+ },
+ "Description": {
+ "anyOf": [
+ {
+ "$ref": "http://redfish.dmtf.org/schemas/v1/Resource.json#/definitions/Description"
+ },
+ {
+ "type": "null"
+ }
+ ],
+ "readonly": true
+ },
+ "Members": {
+ "description": "The members of this collection.",
+ "items": {
+ "$ref": "http://redfish.dmtf.org/schemas/v1/AggregationSource.json#/definitions/AggregationSource"
+ },
+ "longDescription": "This property shall contain an array of links to the members of this collection.",
+ "readonly": true,
+ "type": "array"
+ },
+ "Members@odata.count": {
+ "$ref": "http://redfish.dmtf.org/schemas/v1/odata-v4.json#/definitions/count"
+ },
+ "Members@odata.nextLink": {
+ "$ref": "http://redfish.dmtf.org/schemas/v1/odata-v4.json#/definitions/nextLink"
+ },
+ "Name": {
+ "$ref": "http://redfish.dmtf.org/schemas/v1/Resource.json#/definitions/Name",
+ "readonly": true
+ },
+ "Oem": {
+ "$ref": "http://redfish.dmtf.org/schemas/v1/Resource.json#/definitions/Oem",
+ "description": "The OEM extension property.",
+ "longDescription": "This property shall contain the OEM extensions. All values for properties contained in this object shall conform to the Redfish Specification-described requirements."
+ }
+ },
+ "required": [
+ "Members",
+ "Members@odata.count",
+ "@odata.id",
+ "@odata.type",
+ "Name"
+ ],
+ "type": "object"
+ }
+ ],
+ "deletable": false,
+ "insertable": true,
+ "updatable": false,
+ "uris": [
+ "/redfish/v1/AggregationService/AggregationSources"
+ ]
+ }
+ },
+ "owningEntity": "DMTF",
+ "title": "#AggregationSourceCollection.AggregationSourceCollection"
+}
\ No newline at end of file
diff --git a/static/redfish/v1/schema/AggregationSourceCollection_v1.xml b/static/redfish/v1/schema/AggregationSourceCollection_v1.xml
new file mode 100644
index 0000000..22dde6c
--- /dev/null
+++ b/static/redfish/v1/schema/AggregationSourceCollection_v1.xml
@@ -0,0 +1,69 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!---->
+<!--################################################################################ -->
+<!--# Redfish Schema: AggregationSourceCollection -->
+<!--# -->
+<!--# For a detailed change log, see the README file contained in the DSP8010 bundle, -->
+<!--# available at http://www.dmtf.org/standards/redfish -->
+<!--# Copyright 2014-2022 DMTF. -->
+<!--# For the full DMTF copyright policy, see http://www.dmtf.org/about/policies/copyright -->
+<!--################################################################################ -->
+<!---->
+<edmx:Edmx xmlns:edmx="http://docs.oasis-open.org/odata/ns/edmx" Version="4.0">
+
+ <edmx:Reference Uri="http://docs.oasis-open.org/odata/odata/v4.0/errata03/csd01/complete/vocabularies/Org.OData.Core.V1.xml">
+ <edmx:Include Namespace="Org.OData.Core.V1" Alias="OData"/>
+ </edmx:Reference>
+ <edmx:Reference Uri="http://docs.oasis-open.org/odata/odata/v4.0/errata03/csd01/complete/vocabularies/Org.OData.Capabilities.V1.xml">
+ <edmx:Include Namespace="Org.OData.Capabilities.V1" Alias="Capabilities"/>
+ </edmx:Reference>
+ <edmx:Reference Uri="http://redfish.dmtf.org/schemas/v1/Resource_v1.xml">
+ <edmx:Include Namespace="Resource.v1_0_0"/>
+ </edmx:Reference>
+ <edmx:Reference Uri="http://redfish.dmtf.org/schemas/v1/RedfishExtensions_v1.xml">
+ <edmx:Include Namespace="RedfishExtensions.v1_0_0" Alias="Redfish"/>
+ </edmx:Reference>
+ <edmx:Reference Uri="http://redfish.dmtf.org/schemas/v1/AggregationSource_v1.xml">
+ <edmx:Include Namespace="AggregationSource"/>
+ </edmx:Reference>
+
+ <edmx:DataServices>
+
+ <Schema xmlns="http://docs.oasis-open.org/odata/ns/edm" Namespace="AggregationSourceCollection">
+ <Annotation Term="Redfish.OwningEntity" String="DMTF"/>
+
+ <EntityType Name="AggregationSourceCollection" BaseType="Resource.v1_0_0.ResourceCollection">
+ <Annotation Term="OData.Description" String="The collection of AggregationSource resource instances."/>
+ <Annotation Term="OData.LongDescription" String="This resource shall represent a resource collection of AggregationSource instances for a Redfish implementation."/>
+ <Annotation Term="Capabilities.InsertRestrictions">
+ <Record>
+ <PropertyValue Property="Insertable" Bool="true"/>
+ </Record>
+ </Annotation>
+ <Annotation Term="Capabilities.UpdateRestrictions">
+ <Record>
+ <PropertyValue Property="Updatable" Bool="false"/>
+ </Record>
+ </Annotation>
+ <Annotation Term="Capabilities.DeleteRestrictions">
+ <Record>
+ <PropertyValue Property="Deletable" Bool="false"/>
+ </Record>
+ </Annotation>
+ <Annotation Term="Redfish.Uris">
+ <Collection>
+ <String>/redfish/v1/AggregationService/AggregationSources</String>
+ </Collection>
+ </Annotation>
+ <NavigationProperty Name="Members" Type="Collection(AggregationSource.AggregationSource)">
+ <Annotation Term="OData.Permissions" EnumMember="OData.Permission/Read"/>
+ <Annotation Term="OData.Description" String="The members of this collection."/>
+ <Annotation Term="OData.LongDescription" String="This property shall contain an array of links to the members of this collection."/>
+ <Annotation Term="OData.AutoExpandReferences"/>
+ <Annotation Term="Redfish.Required"/>
+ </NavigationProperty>
+ </EntityType>
+ </Schema>
+
+ </edmx:DataServices>
+</edmx:Edmx>