{
  "description": "ResourceSliceSpec contains the information published by the driver in one ResourceSlice.",
  "properties": {
    "allNodes": {
      "description": "AllNodes indicates that all nodes have access to the resources in the pool.\n\nExactly one of NodeName, NodeSelector and AllNodes must be set.",
      "type": [
        "boolean",
        "null"
      ]
    },
    "devices": {
      "description": "Devices lists some or all of the devices in this pool.\n\nMust not have more than 128 entries.",
      "items": {
        "description": "Device represents one individual hardware instance that can be selected based on its attributes. Besides the name, exactly one field must be set.",
        "properties": {
          "basic": {
            "description": "BasicDevice defines one device instance.",
            "properties": {
              "attributes": {
                "additionalProperties": {
                  "description": "DeviceAttribute must have exactly one field set.",
                  "properties": {
                    "bool": {
                      "description": "BoolValue is a true/false value.",
                      "type": [
                        "boolean",
                        "null"
                      ]
                    },
                    "int": {
                      "description": "IntValue is a number.",
                      "format": "int64",
                      "type": [
                        "integer",
                        "null"
                      ]
                    },
                    "string": {
                      "description": "StringValue is a string. Must not be longer than 64 characters.",
                      "type": [
                        "string",
                        "null"
                      ]
                    },
                    "version": {
                      "description": "VersionValue is a semantic version according to semver.org spec 2.0.0. Must not be longer than 64 characters.",
                      "type": [
                        "string",
                        "null"
                      ]
                    }
                  },
                  "type": [
                    "object",
                    "null"
                  ]
                },
                "description": "Attributes defines the set of attributes for this device. The name of each attribute must be unique in that set.\n\nThe maximum number of attributes and capacities combined is 32.",
                "type": [
                  "object",
                  "null"
                ]
              },
              "capacity": {
                "additionalProperties": {
                  "description": "DeviceCapacity describes a quantity associated with a device.",
                  "properties": {
                    "value": {
                      "oneOf": [
                        {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        {
                          "type": [
                            "number",
                            "null"
                          ]
                        }
                      ]
                    }
                  },
                  "required": [
                    "value"
                  ],
                  "type": [
                    "object",
                    "null"
                  ]
                },
                "description": "Capacity defines the set of capacities for this device. The name of each capacity must be unique in that set.\n\nThe maximum number of attributes and capacities combined is 32.",
                "type": [
                  "object",
                  "null"
                ]
              }
            },
            "type": [
              "object",
              "null"
            ]
          },
          "name": {
            "description": "Name is unique identifier among all devices managed by the driver in the pool. It must be a DNS label.",
            "type": "string"
          }
        },
        "required": [
          "name"
        ],
        "type": [
          "object",
          "null"
        ]
      },
      "type": [
        "array",
        "null"
      ],
      "x-kubernetes-list-type": "atomic"
    },
    "driver": {
      "description": "Driver identifies the DRA driver providing the capacity information. A field selector can be used to list only ResourceSlice objects with a certain driver name.\n\nMust be a DNS subdomain and should end with a DNS domain owned by the vendor of the driver. This field is immutable.",
      "type": [
        "string",
        "null"
      ]
    },
    "nodeName": {
      "description": "NodeName identifies the node which provides the resources in this pool. A field selector can be used to list only ResourceSlice objects belonging to a certain node.\n\nThis field can be used to limit access from nodes to ResourceSlices with the same node name. It also indicates to autoscalers that adding new nodes of the same type as some old node might also make new resources available.\n\nExactly one of NodeName, NodeSelector and AllNodes must be set. This field is immutable.",
      "type": [
        "string",
        "null"
      ]
    },
    "nodeSelector": {
      "description": "A node selector represents the union of the results of one or more label queries over a set of nodes; that is, it represents the OR of the selectors represented by the node selector terms.",
      "properties": {
        "nodeSelectorTerms": {
          "description": "Required. A list of node selector terms. The terms are ORed.",
          "items": {
            "description": "A null or empty node selector term matches no objects. The requirements of them are ANDed. The TopologySelectorTerm type implements a subset of the NodeSelectorTerm.",
            "properties": {
              "matchExpressions": {
                "description": "A list of node selector requirements by node's labels.",
                "items": {
                  "description": "A node selector requirement is a selector that contains values, a key, and an operator that relates the key and values.",
                  "properties": {
                    "key": {
                      "description": "The label key that the selector applies to.",
                      "type": "string"
                    },
                    "operator": {
                      "description": "Represents a key's relationship to a set of values. Valid operators are In, NotIn, Exists, DoesNotExist. Gt, and Lt.",
                      "type": "string"
                    },
                    "values": {
                      "description": "An array of string values. If the operator is In or NotIn, the values array must be non-empty. If the operator is Exists or DoesNotExist, the values array must be empty. If the operator is Gt or Lt, the values array must have a single element, which will be interpreted as an integer. This array is replaced during a strategic merge patch.",
                      "items": {
                        "type": [
                          "string",
                          "null"
                        ]
                      },
                      "type": [
                        "array",
                        "null"
                      ],
                      "x-kubernetes-list-type": "atomic"
                    }
                  },
                  "required": [
                    "key",
                    "operator"
                  ],
                  "type": [
                    "object",
                    "null"
                  ]
                },
                "type": [
                  "array",
                  "null"
                ],
                "x-kubernetes-list-type": "atomic"
              },
              "matchFields": {
                "description": "A list of node selector requirements by node's fields.",
                "items": {
                  "description": "A node selector requirement is a selector that contains values, a key, and an operator that relates the key and values.",
                  "properties": {
                    "key": {
                      "description": "The label key that the selector applies to.",
                      "type": "string"
                    },
                    "operator": {
                      "description": "Represents a key's relationship to a set of values. Valid operators are In, NotIn, Exists, DoesNotExist. Gt, and Lt.",
                      "type": "string"
                    },
                    "values": {
                      "description": "An array of string values. If the operator is In or NotIn, the values array must be non-empty. If the operator is Exists or DoesNotExist, the values array must be empty. If the operator is Gt or Lt, the values array must have a single element, which will be interpreted as an integer. This array is replaced during a strategic merge patch.",
                      "items": {
                        "type": [
                          "string",
                          "null"
                        ]
                      },
                      "type": [
                        "array",
                        "null"
                      ],
                      "x-kubernetes-list-type": "atomic"
                    }
                  },
                  "required": [
                    "key",
                    "operator"
                  ],
                  "type": [
                    "object",
                    "null"
                  ]
                },
                "type": [
                  "array",
                  "null"
                ],
                "x-kubernetes-list-type": "atomic"
              }
            },
            "type": [
              "object",
              "null"
            ],
            "x-kubernetes-map-type": "atomic"
          },
          "type": "array",
          "x-kubernetes-list-type": "atomic"
        }
      },
      "required": [
        "nodeSelectorTerms"
      ],
      "type": [
        "object",
        "null"
      ],
      "x-kubernetes-map-type": "atomic"
    },
    "pool": {
      "description": "ResourcePool describes the pool that ResourceSlices belong to.",
      "properties": {
        "generation": {
          "description": "Generation tracks the change in a pool over time. Whenever a driver changes something about one or more of the resources in a pool, it must change the generation in all ResourceSlices which are part of that pool. Consumers of ResourceSlices should only consider resources from the pool with the highest generation number. The generation may be reset by drivers, which should be fine for consumers, assuming that all ResourceSlices in a pool are updated to match or deleted.\n\nCombined with ResourceSliceCount, this mechanism enables consumers to detect pools which are comprised of multiple ResourceSlices and are in an incomplete state.",
          "format": "int64",
          "type": "integer"
        },
        "name": {
          "description": "Name is used to identify the pool. For node-local devices, this is often the node name, but this is not required.\n\nIt must not be longer than 253 characters and must consist of one or more DNS sub-domains separated by slashes. This field is immutable.",
          "type": "string"
        },
        "resourceSliceCount": {
          "description": "ResourceSliceCount is the total number of ResourceSlices in the pool at this generation number. Must be greater than zero.\n\nConsumers can use this to check whether they have seen all ResourceSlices belonging to the same pool.",
          "format": "int64",
          "type": "integer"
        }
      },
      "required": [
        "name",
        "generation",
        "resourceSliceCount"
      ],
      "type": [
        "object",
        "null"
      ]
    }
  },
  "required": [
    "driver",
    "pool"
  ],
  "type": "object",
  "$schema": "http://json-schema.org/schema#"
}