Split and instrument parts of inferior-packages->package-metadata-ids
As parts of it are slow.
This commit is contained in:
parent
e51f87cc7e
commit
6842a432d6
1 changed files with 29 additions and 22 deletions
|
|
@ -400,28 +400,35 @@ WHERE packages.id IN (
|
||||||
package_description_set_id
|
package_description_set_id
|
||||||
package_synopsis_set_id)
|
package_synopsis_set_id)
|
||||||
|
|
||||||
(map (match-lambda*
|
(zip
|
||||||
(((home-page
|
(map (match-lambda
|
||||||
location
|
((home-page rest ...)
|
||||||
package-description-data
|
(if (string? home-page)
|
||||||
package-synopsis-data)
|
home-page
|
||||||
license-set-id)
|
NULL)))
|
||||||
|
package-metadata)
|
||||||
(list (if (string? home-page)
|
(with-time-logging "preparing location ids"
|
||||||
home-page
|
(map (match-lambda
|
||||||
NULL)
|
((_ location rest ...)
|
||||||
(location->location-id
|
(location->location-id
|
||||||
conn
|
conn
|
||||||
location)
|
location)))
|
||||||
license-set-id
|
package-metadata))
|
||||||
(package-description-data->package-description-set-id
|
license-set-ids
|
||||||
conn
|
(with-time-logging "preparing package description set ids"
|
||||||
package-description-data)
|
(map (match-lambda
|
||||||
(package-synopsis-data->package-synopsis-set-id
|
((_ _ package-description-data _)
|
||||||
conn
|
(package-description-data->package-description-set-id
|
||||||
package-synopsis-data))))
|
conn
|
||||||
package-metadata
|
package-description-data)))
|
||||||
license-set-ids)
|
package-metadata))
|
||||||
|
(with-time-logging "preparing package synopsis set ids"
|
||||||
|
(map (match-lambda
|
||||||
|
((_ _ _ package-synopsis-data)
|
||||||
|
(package-synopsis-data->package-synopsis-set-id
|
||||||
|
conn
|
||||||
|
package-synopsis-data)))
|
||||||
|
package-metadata)))
|
||||||
;; There can be duplicated entires in package-metadata, for example where
|
;; There can be duplicated entires in package-metadata, for example where
|
||||||
;; you have one package definition which interits from another, and just
|
;; you have one package definition which interits from another, and just
|
||||||
;; overrides the version and the source, the package_metadata entries for
|
;; overrides the version and the source, the package_metadata entries for
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue