aboutsummaryrefslogtreecommitdiff
path: root/guix-data-service
diff options
context:
space:
mode:
authorChristopher Baines <mail@cbaines.net>2024-01-31 20:20:48 +0100
committerChristopher Baines <mail@cbaines.net>2024-01-31 20:20:48 +0100
commitd5e663cc1eeace03ebf2d33eacfa40fbd996d716 (patch)
tree58d9aac2b35ff9ee52ee0e5c53102be3fa69f129 /guix-data-service
parent9779ecf3cd3b10c9ed2bb94c0b459ddfc2d85467 (diff)
downloaddata-service-d5e663cc1eeace03ebf2d33eacfa40fbd996d716.tar
data-service-d5e663cc1eeace03ebf2d33eacfa40fbd996d716.tar.gz
Split up handling of package description data
To hopefully see which part is slow.
Diffstat (limited to 'guix-data-service')
-rw-r--r--guix-data-service/model/package-metadata.scm25
1 files changed, 13 insertions, 12 deletions
diff --git a/guix-data-service/model/package-metadata.scm b/guix-data-service/model/package-metadata.scm
index 17f4e10..77f24c6 100644
--- a/guix-data-service/model/package-metadata.scm
+++ b/guix-data-service/model/package-metadata.scm
@@ -368,12 +368,8 @@ WHERE packages.id IN (
(((id)) id))))
(define (package-description-data->package-description-set-id
- conn descriptions-by-locale)
- (let* ((package-description-ids
- (package-description-data->package-description-ids
- conn
- descriptions-by-locale))
- (package-description-set-id
+ conn package-description-ids)
+ (let* ((package-description-set-id
(exec-query
conn
(string-append
@@ -418,12 +414,17 @@ WHERE packages.id IN (
package-metadata))
license-set-ids
(with-time-logging "preparing package description set ids"
- (map (match-lambda
- ((_ _ package-description-data _)
- (package-description-data->package-description-set-id
- conn
- package-description-data)))
- package-metadata))
+ (map (lambda (package-description-ids)
+ (package-description-data->package-description-set-id
+ conn
+ package-description-ids))
+ (with-time-logging "preparing package description ids"
+ (map (match-lambda
+ ((_ _ package-description-data _)
+ (package-description-data->package-description-ids
+ conn
+ package-description-data)))
+ package-metadata))))
(with-time-logging "preparing package synopsis set ids"
(map (match-lambda
((_ _ _ package-synopsis-data)