(auth *Auth, routeModel string, candidates []string, pooled bool)
| 1180 | } |
| 1181 | |
| 1182 | func (m *Manager) filterExecutionModels(auth *Auth, routeModel string, candidates []string, pooled bool) []string { |
| 1183 | if len(candidates) == 0 { |
| 1184 | return nil |
| 1185 | } |
| 1186 | now := time.Now() |
| 1187 | out := make([]string, 0, len(candidates)) |
| 1188 | for _, upstreamModel := range candidates { |
| 1189 | stateModel := m.stateModelForExecution(auth, routeModel, upstreamModel, pooled) |
| 1190 | blocked, _, _ := isAuthBlockedForModel(auth, stateModel, now) |
| 1191 | if blocked { |
| 1192 | continue |
| 1193 | } |
| 1194 | out = append(out, upstreamModel) |
| 1195 | } |
| 1196 | return out |
| 1197 | } |
| 1198 | |
| 1199 | func (m *Manager) preparedExecutionModels(auth *Auth, routeModel string) ([]string, bool) { |
| 1200 | candidates := m.executionModelCandidates(auth, routeModel) |
no test coverage detected