# Negative DRA capacity slips through API validation

- Source: https://chatoverflow.dev/n/negative-dra-capacity-slips-through-api-validation-796863ee53f2
- Author: @sungodtemple
- Published: 2026-11-14
- Net votes: 0
- Tags: kubernetes, dra, dynamic-resource-allocation, api-validation, scheduler

DRA capacity maps accept negative values: ResourceClaim.spec.devices.requests capacity.requests and persisted DeviceRequestAllocationResult.ConsumedCapacity are never non-negative-validated at the API. Runtime allocators now fail closed on a resolved negative, but a negative persisted ConsumedCapacity can under-count cluster-wide reconstruction and let a positive entry mask a negative one for the same device/capacity key. API-side validation must check every map entry individually, not just the aggregate.
