KubeCon: What is Kubernetes' dynamic resource allocation, and why does it matter?

KubeCon + CloudNativeCon North America 2023, Chicago – At KubeCon 2023, Priyanka Sharma, the Cloud Native Computing Foundation (CNCF) executive director, did the bravest thing any keynote speaker can do: She ran a live demo. As is so often the case, it failed. It simply didn't run fast enough.

Sharma mentioned, though, that had she built the demo using Kubernetes' new Dynamic Resource Allocation (DRA), it would have been fine because with DRA applications can run very quickly.

Who, when it comes to Kubernetes and cloud-native computing, doesn't like fast? So, what is DRA, and how does it deliver high speed?

Interested in debating and discussing the challenges of multi-cloud management with your peers? Meet up in Sonoma, Calif., from Dec. 6-7 for our Cloud Executive Summit. 

The alpha API DRA feature ups Kubernetes's game by providing a new, flexible way for jobs to call for resources. It makes it possible to:

  • Access the same resource instance in different pods and containers,
  • Attach arbitrary constraints to a resource request to get the exact resource you are looking for,
  • Initialize a resource according to parameters provided by the user.

Sounds pretty basic doesn't it? The key is its adaptability and flexibility. First, DRA lets third-parties set up resources and those resources can be pretty much anything. Instead of static resource assignments, DRA enables you to dynamically request and assign resources to pods and containers.

The DRA then uses a blend of immediate and delayed allocation strategies to allocate these resources. This ensures that resources are judiciously assigned, whether in anticipation of future demand or in response to immediate requirements.

Put it all together and this transforms Kubernetes into an agile orchestrator, capable of dynamically allocating resources to meet the fluctuating needs of workloads.

Say, for example, you're running an e-commerce site and a sale unexpectedly goes virtual and suddenly your site gets hammered by eager buyers. With DRA, your site's software can call for the resources you need dynamically without needing to manually change the code to deal with the unexpected load.

Imagine the possibilities!

The Kubernetes community at Kubecon is abuzz with the possibilities DRA opens up. Not only does it promise more flexible resource management, but it also paves the way for integrating third-party resource drivers, potentially leading to a more comprehensive and efficient system.

True, this feature is still in its alpha stage. Today, it requires explicit enabling and is subject to further evolution as Kubernetes developers receive feedback from the community.

But even now, its potential to streamline resource allocation processes is clear: Faster and more flexible applications. Whether it's for a demo or a mission-critical, front-facing web service.