syntax = "proto3";

package akash.inventory.v1;

import "gogoproto/gogo.proto";
import "akash/base/v1beta3/attribute.proto";
import "k8s.io/apimachinery/pkg/api/resource/generated.proto";

option go_package = "github.com/akash-network/akash-api/go/inventory/v1";

// ResourcePair to extents resource.Quantity to provide total and available units of the resource
message ResourcePair {
  option (gogoproto.equal) = false;

  k8s.io.apimachinery.pkg.api.resource.Quantity allocatable = 1 [
    (gogoproto.nullable)   = true,
    (gogoproto.customname) = "Allocatable",
    (gogoproto.jsontag)    = "allocatable",
    (gogoproto.moretags)   = "yaml:\"allocatable\""
  ];
  k8s.io.apimachinery.pkg.api.resource.Quantity allocated = 2 [
    (gogoproto.nullable)   = true,
    (gogoproto.customname) = "Allocated",
    (gogoproto.jsontag)    = "allocated",
    (gogoproto.moretags)   = "yaml:\"allocated\""
  ];
  repeated akash.base.v1beta3.Attribute attributes = 3 [
    (gogoproto.nullable)     = false,
    (gogoproto.castrepeated) = "github.com/akash-network/akash-api/go/node/types/v1beta3.Attributes",
    (gogoproto.jsontag)      = "attributes,omitempty",
    (gogoproto.moretags)     = "yaml:\"attributes,omitempty\""
  ];
  k8s.io.apimachinery.pkg.api.resource.Quantity capacity = 4 [
    (gogoproto.nullable)   = true,
    (gogoproto.customname) = "Capacity",
    (gogoproto.jsontag)    = "capacity",
    (gogoproto.moretags)   = "yaml:\"capacity\""
  ];
}
