WIP: v1.0.0

This commit is contained in:
Moritz Ruth 2025-03-22 23:10:01 +01:00
parent 5cbab43a23
commit cc84c6ac37
Signed by: moritzruth
GPG key ID: C9BBAB79405EE56D
7 changed files with 369 additions and 306 deletions

View file

@ -1,8 +1,9 @@
create table objects
(
hash text not null,
media_type text not null,
creation_date text not null, -- RFC 3339 format
hash text not null,
size integer not null, -- in bytes
media_type text not null,
creation_date text not null, -- RFC 3339 format
primary key (hash)
) without rowid, strict;
@ -14,3 +15,14 @@ create table object_replicas
primary key (hash, bucket_id),
foreign key (hash) references objects (hash) on delete restrict on update restrict
) strict;
create table uploads
(
id text not null,
current_size integer not null, -- in bytes
total_size integer, -- in bytes, or null if the upload was not started yet
hash text,
primary key (id),
foreign key (hash) references objects (hash) on delete restrict on update restrict
)