From e9d8e82bcf08972d6c16a3e1e0f286d1294cf9e6 Mon Sep 17 00:00:00 2001 From: Sean Whitton Date: Fri, 27 Aug 2021 14:32:59 -0700 Subject: UPLOAD-ALL-PREREQUISITE-DATA: query remote cache contents just once Should improve performance, especially when connection latency is high. We already implicitly assume that only one attempt to upload prerequisite data is going on at once. Signed-off-by: Sean Whitton --- src/data.lisp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'src/data.lisp') diff --git a/src/data.lisp b/src/data.lisp index c78784c..fe96809 100644 --- a/src/data.lisp +++ b/src/data.lisp @@ -342,15 +342,16 @@ CONTINUE-DEPLOY* or CONTINUE-DEPLOY*-PROGRAM." (remote-data-pathname iden1 iden2 version))))) (loop with *data-sources* = (cons (register-data-source :asdf) *data-sources*) + with remote-cached + = (sort-prerequisite-data-cache + (get-remote-cached-prerequisite-data connection)) for (iden1 . iden2) in (get-hostattrs :data) for highest-remote-version = (caddar (remove-if-not (lambda (c) (and (string= (first c) iden1) (string= (second c) iden2))) - (sort-prerequisite-data-cache - (get-remote-cached-prerequisite-data - connection)))) + remote-cached)) for (thunk highest-local-version) = (handler-case (multiple-value-list (%get-data iden1 iden2)) (missing-data () nil)) -- cgit v1.2.3