mirror of
https://github.com/penpot/penpot.git
synced 2026-05-27 10:53:51 +00:00
✨ Don't migrate libraries on accessing them on file data migrations
We don't migrate the libraries for avoid cascade migration; it is not ideal but it reduces the total of the required memory needed for process a single file migration that requires libraries to be loaded.
This commit is contained in:
parent
9563d1b1f6
commit
fa2b0bd67c
@ -612,5 +612,9 @@
|
|||||||
"A helper for preload file libraries"
|
"A helper for preload file libraries"
|
||||||
[{:keys [::db/conn] :as cfg} file]
|
[{:keys [::db/conn] :as cfg} file]
|
||||||
(->> (get-file-libraries conn (:id file))
|
(->> (get-file-libraries conn (:id file))
|
||||||
(into [file] (map #(get-file cfg (:id %))))
|
;; WARNING: we don't migrate the libraries for avoid cascade
|
||||||
|
;; migration; it is not ideal but it reduces the total of the
|
||||||
|
;; required memory needed for process a single file migration
|
||||||
|
;; that requires libraries to be loaded.
|
||||||
|
(into [file] (map #(get-file cfg (:id %) :migrate? false)))
|
||||||
(d/index-by :id)))
|
(d/index-by :id)))
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user