[arvados] updated: 2.5.0-285-g5dd128f5a

git repository hosting git at public.arvados.org
Wed Mar 15 14:09:00 UTC 2023


Summary of changes:
 lib/controller/localdb/container.go  | 18 ++++++++++++++++--
 services/api/app/models/container.rb |  2 +-
 2 files changed, 17 insertions(+), 3 deletions(-)

       via  5dd128f5a57e704e3b3ea5225130ca85bd3bb84c (commit)
       via  d9b8d0295f1fa1c1690b9fe80ba38f6f665de4e9 (commit)
       via  869497eff961e5d2951e84e8b46d81bbc1d3ec3b (commit)
       via  dcb3df6be978eef367e0d4fda95ccd71e0281749 (commit)
      from  f94ac6e8ad9aec3c781cd71b72fcc5e2c1cedd8d (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.


commit 5dd128f5a57e704e3b3ea5225130ca85bd3bb84c
Merge: f94ac6e8a d9b8d0295
Author: Tom Clegg <tom at curii.com>
Date:   Wed Mar 15 10:08:08 2023 -0400

    Merge branch '20183-update-priority-thread'
    
    closes #20183
    
    Arvados-DCO-1.1-Signed-off-by: Tom Clegg <tom at curii.com>

diff --cc services/api/app/models/container.rb
index 0eaf640b6,569a5841b..3c6c969bd
--- a/services/api/app/models/container.rb
+++ b/services/api/app/models/container.rb
@@@ -131,12 -131,12 +131,12 @@@ class Container < ArvadosMode
    def update_priority!
      return if ![Queued, Locked, Running].include?(state)
      p = ContainerRequest.
-           where('container_uuid=? and priority>0', uuid).
 -        where('container_uuid=? and priority>0 and state=?', uuid, ContainerRequest::Committed).
 -        includes(:requesting_container).
 -        lock(true).
 -        map do |cr|
 -      if cr.requesting_container
 -        cr.requesting_container.priority
++          where('container_uuid=? and priority>0 and state=?', uuid, ContainerRequest::Committed).
 +          select("priority, requesting_container_uuid, created_at").
 +          lock(true).
 +          map do |cr|
 +      if cr.requesting_container_uuid
 +        Container.where(uuid: cr.requesting_container_uuid).pluck(:priority).first
        else
          (cr.priority << 50) - (cr.created_at.to_time.to_f * 1000).to_i
        end

-----------------------------------------------------------------------


hooks/post-receive
-- 




More information about the arvados-commits mailing list