<p>We are using Kubernetes and we need to do "Smart partitioning" of data. We want to split the space between 1 to 1000 between n running Pods, 
And each pod should know which part of the space is his to handle (for pooling partitioned tasks).</p>

<p>So for example, if we have 1 pod he will handle the whole space from 1-1000. </p>

<p>When we scale out to 3 pods, each of them will get the same share.</p>

<p>Pod 1 - will handle 1-333</p>

<p>Pod 2 - 334-667</p>

<p>Pod 3 667-1000</p>

<p>Right now the best way that we find to handle this issue is to create a Stateful-set, that pooling the number of running pods and his instance number and decide which part of the space he needs to handle.
Is there a smarter/built-in way in Kubernetes to partition the space between nodes in this manner?</p>

<p>Service fabric has this feature built-in. </p>

Amir Harari
<p>There are <strong>NO</strong> native tools for scaling at the <a href="https://learn.microsoft.com/en-in/azure/service-fabric/service-fabric-concepts-scalability#scaling-at-the-partition-level" rel="nofollow noreferrer">partition level</a> in K8s yet.</p>

<p>Only custom solutions similar to what you have came up with in your original post.</p>
