(scaleSetID uint)
| 122 | } |
| 123 | |
| 124 | func (i *InstanceCache) GetInstancesForScaleSet(scaleSetID uint) []params.Instance { |
| 125 | i.mux.Lock() |
| 126 | defer i.mux.Unlock() |
| 127 | |
| 128 | var filteredInstances []params.Instance |
| 129 | for _, instance := range i.cache { |
| 130 | if instance.ScaleSetID == scaleSetID { |
| 131 | filteredInstances = append(filteredInstances, instance) |
| 132 | } |
| 133 | } |
| 134 | sortByCreationDate(filteredInstances) |
| 135 | return filteredInstances |
| 136 | } |
| 137 | |
| 138 | func (i *InstanceCache) GetEntityInstances(entityID string) []params.Instance { |
| 139 | pools := GetEntityPools(entityID) |
no test coverage detected