diff options
author | Frederick Muriuki Muriithi | 2025-03-25 12:55:25 -0500 |
---|---|---|
committer | Frederick Muriuki Muriithi | 2025-03-25 12:55:47 -0500 |
commit | d4b7312423d5aef91b264bb21429e79ec65cec7c (patch) | |
tree | cb7e2e5c334acd994b7aa426eae6d22eded9975f /gn_libs/jobs/migrations.py | |
parent | 594a0f9632785a4acb6d99ddd6d5171138339b60 (diff) | |
download | gn-libs-d4b7312423d5aef91b264bb21429e79ec65cec7c.tar.gz |
Update jobs database schema.
Diffstat (limited to 'gn_libs/jobs/migrations.py')
-rw-r--r-- | gn_libs/jobs/migrations.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/gn_libs/jobs/migrations.py b/gn_libs/jobs/migrations.py index cc463e3..86fb958 100644 --- a/gn_libs/jobs/migrations.py +++ b/gn_libs/jobs/migrations.py @@ -38,13 +38,13 @@ def __create_table_jobs_output_streams__(cursor: DbCursor): cursor.execute( """ CREATE TABLE IF NOT EXISTS jobs_standard_outputs( - job_id TEXT PRIMARY KEY, + job_id TEXT NOT NULL, output_stream TEXT, - timestamp TEXT, value TEXT, FOREIGN KEY(job_id) REFERENCES jobs(job_id) ON UPDATE CASCADE ON DELETE RESTRICT, - CHECK (output_stream IN ('stdout', 'stderr')) + CHECK (output_stream IN ('stdout', 'stderr')), + PRIMARY KEY(job_id, output_stream) ) WITHOUT ROWID """) cursor.execute( |