ae1709dafd
* wip * Start testing * Store host IDs, not hostnames Why? Hostnames can change a lot, and therefore host filtering can be funky. Really, all we want is a unique ID per machine + do not care what it might be. * Mostly just write a fuckload of tests * Add a v0 kv store I can push to * Appending works * Add next() and iterate, test the pointer chain * Fix sig * Make clippy happy and thaw the ICE * Fix tests' * Fix tests * typed builder and cleaner db trait --------- Co-authored-by: Conrad Ludgate <conrad.ludgate@truelayer.com>
15 lines
398 B
SQL
15 lines
398 B
SQL
-- Add migration script here
|
|
create table if not exists records (
|
|
id text primary key,
|
|
parent text unique, -- null if this is the first one
|
|
host text not null,
|
|
|
|
timestamp integer not null,
|
|
tag text not null,
|
|
version text not null,
|
|
data blob not null
|
|
);
|
|
|
|
create index host_idx on records (host);
|
|
create index tag_idx on records (tag);
|
|
create index host_tag_idx on records (host, tag);
|