Update DB to use 1MB

This commit is contained in:
Bradley Schofield
2022-03-21 11:52:10 +00:00
parent 2e00acc17b
commit 5dc4a9039f
3 changed files with 9 additions and 8 deletions
+4 -4
View File
@@ -2007,7 +2007,7 @@ $collections = [
'$id' => 'stderr',
'type' => Database::VAR_STRING,
'format' => '',
'size' => 1048576,
'size' => 1000000,
'signed' => true,
'required' => false,
'default' => '',
@@ -2018,7 +2018,7 @@ $collections = [
'$id' => 'stdout',
'type' => Database::VAR_STRING,
'format' => '',
'size' => 1048576,
'size' => 1000000,
'signed' => true,
'required' => false,
'default' => '',
@@ -2124,7 +2124,7 @@ $collections = [
'$id' => 'stdout',
'type' => Database::VAR_STRING,
'format' => '',
'size' => 1048576,
'size' => 1000000,
'signed' => true,
'required' => false,
'default' => null,
@@ -2135,7 +2135,7 @@ $collections = [
'$id' => 'stderr',
'type' => Database::VAR_STRING,
'format' => '',
'size' => 1048576,
'size' => 1000000,
'signed' => true,
'required' => false,
'default' => null,
+4 -4
View File
@@ -283,8 +283,8 @@ App::post('/v1/runtimes')
$endTime = \time();
$container = array_merge($container, [
'status' => 'ready',
'stdout' => \mb_substr(\utf8_encode($stdout), 0, 1048576), // Limit to 1MB
'stderr' => \mb_substr(\utf8_encode($stderr), 0, 1048576), // Limit to 1MB
'stdout' => \mb_strcut(\utf8_encode($stdout), 0, 1000000), // Limit to 1MB
'stderr' => \mb_strcut(\utf8_encode($stderr), 0, 1000000), // Limit to 1MB
'startTime' => $startTime,
'endTime' => $endTime,
'duration' => $endTime - $startTime,
@@ -501,8 +501,8 @@ App::post('/v1/execution')
$execution = [
'status' => $functionStatus,
'statusCode' => $statusCode,
'stdout' => \mb_substr(\utf8_encode($stdout), 0, 1048576), // Limit to 1MB
'stderr' => \mb_substr(\utf8_encode($stderr), 0, 1048576), // Limit to 1MB
'stdout' => \mb_strcut(\utf8_encode($stdout), 0, 1000000), // Limit to 1MB
'stderr' => \mb_strcut(\utf8_encode($stderr), 0, 1000000), // Limit to 1MB
'time' => $executionTime,
];
Submodule
+1
Submodule open-runtimes added at c4f2c21404