From d4900d85f7a5d791f89821713d02d3dd19361044 Mon Sep 17 00:00:00 2001 From: Karen Arutyunov Date: Thu, 22 Feb 2024 11:17:25 +0300 Subject: Add support for tenant-associated service notifications --- monitor/monitor.cxx | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'monitor/monitor.cxx') diff --git a/monitor/monitor.cxx b/monitor/monitor.cxx index 6d6bb99..77f387b 100644 --- a/monitor/monitor.cxx +++ b/monitor/monitor.cxx @@ -675,7 +675,8 @@ namespace brep const auto& bid (bquery::build::id); - bquery bq ((equal (bid.package, id.package) && + bquery bq ((bquery::build::state != "queued" && + equal (bid.package, id.package) && bid.target == bquery::_ref (id.target) && bid.target_config_name == bquery::_ref (id.target_config_name) && @@ -864,8 +865,13 @@ namespace brep b = move (pbs.begin ()->build); } else + { b = db.find (id); + if (b->state == build_state::queued) + b = nullptr; + } + // Note that we consider a build as delayed if it is not // completed in the expected timeframe. So even if the build // task have been issued recently we may still consider the -- cgit v1.1