getQueuedBuilds(): Periodically stop to handle priority bumps
[?]
Oct 22, 2015, 3:00 PM
RND7XFNHXVORJ6JPEHGS7PCIW7DMOTWMZQPTEMXWLR7CZUQ2VCQQCDependencies
- [2]
ZK76B5ZZLoad the queue in order of global priority - [3]
T5BIOVJEAdd support for tracking custom metrics - [4]
VQISTKOPhydra-queue-runner: Use substitutes - [5]
MHVIT4JYSplit hydra-queue-runner.cc more - [6]
OG3Z3QGCNamespace cleanup - [7]
HJOEIMLRRefactor - [8]
WE5Q2NVIAllow build to be bumped to the front of the queue via the web interface - [9]
ACBS7C6Qhydra-queue-runner: Detect changes to the scheduling shares
Change contents
- replacement in src/hydra-queue-runner/queue-monitor.cc at line 39
getQueuedBuilds(*conn, store, lastBuildId);bool done = getQueuedBuilds(*conn, store, lastBuildId); - replacement in src/hydra-queue-runner/queue-monitor.cc at line 43
conn->await_notification();nrQueueWakeups++;if (done) {conn->await_notification();nrQueueWakeups++;} elseconn->get_notifs(); - replacement in src/hydra-queue-runner/queue-monitor.cc at line 67
void State::getQueuedBuilds(Connection & conn, std::shared_ptr<StoreAPI> store, unsigned int & lastBuildId)bool State::getQueuedBuilds(Connection & conn, std::shared_ptr<StoreAPI> store, unsigned int & lastBuildId) - edit in src/hydra-queue-runner/queue-monitor.cc at line 76
unsigned int newLastBuildId = lastBuildId; - replacement in src/hydra-queue-runner/queue-monitor.cc at line 91
if (id > lastBuildId) lastBuildId = id;if (id > newLastBuildId) newLastBuildId = id; - edit in src/hydra-queue-runner/queue-monitor.cc at line 237
system_time start = std::chrono::system_clock::now(); - edit in src/hydra-queue-runner/queue-monitor.cc at line 260
/* Stop after a certain time to allow priority bumps to beprocessed. */if (std::chrono::system_clock::now() > start + std::chrono::seconds(600)) break; - edit in src/hydra-queue-runner/queue-monitor.cc at line 265
lastBuildId = newBuildsByID.empty() ? newLastBuildId : newBuildsByID.begin()->first - 1;return newBuildsByID.empty(); - replacement in src/hydra-queue-runner/state.hh at line 380
void getQueuedBuilds(Connection & conn, std::shared_ptr<nix::StoreAPI> store, unsigned int & lastBuildId);bool getQueuedBuilds(Connection & conn, std::shared_ptr<nix::StoreAPI> store, unsigned int & lastBuildId);