Skip to content

Commit

Permalink
feat: Store execution logs in D1 (#5)
Browse files Browse the repository at this point in the history
* Create a D1 table for execution logs.
* Buffer logs during execution and store them at D1 when finished.
* Update packages with npm audit.
* Add npm script to cat logs of last execution.
*Add git revision as env var.
* Retries to get transactions if error status was flagged over 6 hours ago
  • Loading branch information
pdcalado authored Mar 16, 2023
1 parent a1d968d commit 1ab7d8a
Show file tree
Hide file tree
Showing 4 changed files with 283 additions and 173 deletions.
11 changes: 11 additions & 0 deletions migrations/0002_create_execution_logs_table.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
-- Migration number: 0002 2023-03-07T22:13:50.828Z

DROP TABLE IF EXISTS execution_logs;

CREATE TABLE execution_logs (
revision VARCHAR(20) NOT NULL
created_at DATE NOT NULL,
logs BLOB
);

CREATE INDEX execution_logs_created_at_idx ON execution_logs (created_at);
Loading

0 comments on commit 1ab7d8a

Please sign in to comment.