Commit f48fe03
authored
Poll for new tasks (#176)
- Setting to configure a polling interval for new task to reduce load when there are many workers & tasks. Instead of subscribing to the activity channel, which results in N_WORKERS messages for each task (and then each of them polling for the task), we just poll periodically. Downside is that with polling enabled and few workers it might take up to the polling interval to pick up a new task.
- Setting to disable publishing to the activity channel. This should be only used if all workers are polling.1 parent 6d96607 commit f48fe03
3 files changed
Lines changed: 47 additions & 16 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
285 | 285 | | |
286 | 286 | | |
287 | 287 | | |
288 | | - | |
| 288 | + | |
289 | 289 | | |
290 | 290 | | |
291 | 291 | | |
| |||
361 | 361 | | |
362 | 362 | | |
363 | 363 | | |
364 | | - | |
| 364 | + | |
365 | 365 | | |
366 | 366 | | |
367 | 367 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
195 | 195 | | |
196 | 196 | | |
197 | 197 | | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
198 | 205 | | |
199 | 206 | | |
200 | 207 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
207 | 207 | | |
208 | 208 | | |
209 | 209 | | |
210 | | - | |
| 210 | + | |
| 211 | + | |
211 | 212 | | |
212 | 213 | | |
213 | | - | |
| 214 | + | |
214 | 215 | | |
215 | | - | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
216 | 231 | | |
217 | 232 | | |
218 | 233 | | |
| |||
223 | 238 | | |
224 | 239 | | |
225 | 240 | | |
226 | | - | |
227 | 241 | | |
228 | 242 | | |
229 | 243 | | |
| |||
1091 | 1105 | | |
1092 | 1106 | | |
1093 | 1107 | | |
| 1108 | + | |
| 1109 | + | |
| 1110 | + | |
| 1111 | + | |
| 1112 | + | |
1094 | 1113 | | |
1095 | 1114 | | |
1096 | 1115 | | |
| |||
1125 | 1144 | | |
1126 | 1145 | | |
1127 | 1146 | | |
1128 | | - | |
1129 | | - | |
| 1147 | + | |
| 1148 | + | |
| 1149 | + | |
| 1150 | + | |
| 1151 | + | |
1130 | 1152 | | |
1131 | | - | |
1132 | | - | |
1133 | | - | |
| 1153 | + | |
1134 | 1154 | | |
1135 | 1155 | | |
1136 | 1156 | | |
1137 | 1157 | | |
1138 | 1158 | | |
1139 | | - | |
1140 | | - | |
1141 | | - | |
1142 | | - | |
| 1159 | + | |
| 1160 | + | |
| 1161 | + | |
| 1162 | + | |
| 1163 | + | |
| 1164 | + | |
| 1165 | + | |
1143 | 1166 | | |
1144 | 1167 | | |
1145 | 1168 | | |
| |||
1162 | 1185 | | |
1163 | 1186 | | |
1164 | 1187 | | |
1165 | | - | |
| 1188 | + | |
| 1189 | + | |
1166 | 1190 | | |
0 commit comments