How does EGO determine resource allocation when multiple consumers with equal share ratios require the same resource?

EGO takes into account the order of consumers as presented in the consumer tree. If two consumers have the same parent consumer and are configured with the same share ratio, the consumer that is higher in the tree is accorded a higher share ratio relative to the second consumer. This resource allocation model is implemented when the available resources cannot be equally divided among consumers configured with the same share ratio.

For example, imagine the following scenario:

  1. There is only one slot in a resource group.
  2. There are three consumers sharing the resource in the resource group, and all have a share ratio of one, as follows:
    • parent consumer
    • SymTesting (ratio: 1)
    • SymExec (ratio: 1)
    • SampleApplications (ratio: 1)
  3. Since the single resource cannot be divided among these three consumers, SymTesting is considered to have a higher share ratio relative to SymExec and SampleApplications, even though all three consumers have a share ratio of one.
  4. As a result, if SymTesting has demands, EGO will allocate the resource to it, or reclaim the resource from SymExec or SampleApplications if it is being used by either SymExec or SampleApplications.
  5. This relative higher share ratio can also be observed by running the CLI egosh rg command. Note there is one free resource in SymTesting but not in the other two consumers even though they all have the same share ratio (=1).
    C:\ >egosh rg ComputeHosts
    ---------------------------------------------------------------------------
    Name         : ComputeHosts
    Description  :
    ResReq       : select(!mg)
    NHOSTS       : 1
    SLOTS         FREE          ALLOCATED
    1             1             0
    Resource List: user1.noam.corp.platform.com
    
    Detailed Usage Information  : /
      CONSUMER              OWN           SHARE         ALLOCATED     FREE
      SymTesting            0              33.3%        0             1
      SymExec               0              33.3%        0             0
      SampleApplications    0              33.3%        0             0