Skip to content

Commit

Permalink
Use bigint to store job's result size to increase the limit ~2 GiB to…
Browse files Browse the repository at this point in the history
… ~8 EiB

* I was made aware of this limitation by the following error showing up in
  a cleanup task on OSD:
  ```
  DBIx::Class::Storage::DBI::_dbh_execute(): DBI Exception: DBD::Pg::st execute failed: ERROR:  integer out of range [for Statement "UPDATE jobs SET logs_present = ?, result_size = result_size - 9511751560, t_updated = ? WHERE id = ?" with ParamValues: 1=\'0\', 2=\'2021-03-12 23:23:27\', 3=\'5572530\'] at /usr/share/openqa/script/../lib/OpenQA/Schema/Result/Jobs.pm line 1185
  ```
* Requires 4 more byte per job
* Migration might take a while to execute
  • Loading branch information
Martchus committed Mar 17, 2021
1 parent c6677f1 commit 6999877
Show file tree
Hide file tree
Showing 7 changed files with 5,441 additions and 2 deletions.
18 changes: 18 additions & 0 deletions dbicdh/PostgreSQL/deploy/92/001-auto-__VERSION.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
--
-- Created by SQL::Translator::Producer::PostgreSQL
-- Created on Wed Mar 17 11:36:30 2021
--
;
--
-- Table: dbix_class_deploymenthandler_versions
--
CREATE TABLE dbix_class_deploymenthandler_versions (
id serial NOT NULL,
version character varying(50) NOT NULL,
ddl text,
upgrade_sql text,
PRIMARY KEY (id),
CONSTRAINT dbix_class_deploymenthandler_versions_version UNIQUE (version)
);

;
Loading

0 comments on commit 6999877

Please sign in to comment.