mirror of
https://github.com/penpot/penpot.git
synced 2025-12-23 22:48:40 -05:00
✨ Add tempfile bucket to the storage subsystem
This enables storing temporal files under storage subsystem. The temporal objects (the objects that uses templfile bucket) will always evaluate to "for deletion" after touched garbage collection; and the deletion threshold will be 2 hours (the threshold is always calculated from the instant when the touched garbage collector is running).
This commit is contained in:
@@ -41,6 +41,7 @@
|
||||
"file-object-thumbnail"
|
||||
"file-thumbnail"
|
||||
"profile"
|
||||
"tempfile"
|
||||
"file-data"
|
||||
"file-data-fragment"
|
||||
"file-change"})
|
||||
|
||||
@@ -165,6 +165,7 @@
|
||||
"file-thumbnail" (process-objects! conn has-file-thumbnails-refs? bucket objects)
|
||||
"profile" (process-objects! conn has-profile-refs? bucket objects)
|
||||
"file-data" (process-objects! conn has-file-data-refs? bucket objects)
|
||||
"tempfile" (process-objects! conn (constantly false) bucket objects)
|
||||
(ex/raise :type :internal
|
||||
:code :unexpected-unknown-reference
|
||||
:hint (dm/fmt "unknown reference '%'" bucket))))
|
||||
|
||||
Reference in New Issue
Block a user