PMCORE-1224

This commit is contained in:
Paula Quispe
2020-03-02 10:43:34 -04:00
parent 1892106bf0
commit f92bbdae39

View File

@@ -1,6 +1,8 @@
<?php <?php
/** /**
* cron_single.php
*
* @see workflow/engine/bin/cron.php * @see workflow/engine/bin/cron.php
* @see workflow/engine/bin/messageeventcron.php * @see workflow/engine/bin/messageeventcron.php
* @see workflow/engine/bin/timereventcron.php * @see workflow/engine/bin/timereventcron.php
@@ -30,8 +32,6 @@ register_shutdown_function(function () {
} }
}); });
ini_set('memory_limit', '512M');
try { try {
//Verify data //Verify data
if (count($argv) < 7) { if (count($argv) < 7) {
@@ -77,11 +77,12 @@ try {
// Add vendors to autoloader // Add vendors to autoloader
$classLoader->addClass('Bootstrap', PATH_TRUNK . 'gulliver' . PATH_SEP . 'system' . PATH_SEP . 'class.bootstrap.php'); $classLoader->addClass('Bootstrap', PATH_TRUNK . 'gulliver' . PATH_SEP . 'system' . PATH_SEP . 'class.bootstrap.php');
$classLoader->addModelClassPath(PATH_TRUNK . 'workflow' . PATH_SEP . 'engine' . PATH_SEP . 'classes' . PATH_SEP . 'model' . PATH_SEP); $classLoader->addModelClassPath(PATH_TRUNK . 'workflow' . PATH_SEP . 'engine' . PATH_SEP . 'classes' . PATH_SEP . 'model' . PATH_SEP);
// Get the configurations related to the workspace
$arraySystemConfiguration = System::getSystemConfiguration('', '', $workspace); $arraySystemConfiguration = System::getSystemConfiguration('', '', $workspace);
// Define the debug value
$e_all = (defined('E_DEPRECATED')) ? E_ALL & ~E_DEPRECATED : E_ALL; $e_all = (defined('E_DEPRECATED')) ? E_ALL & ~E_DEPRECATED : E_ALL;
$e_all = (defined('E_STRICT')) ? $e_all & ~E_STRICT : $e_all; $e_all = (defined('E_STRICT')) ? $e_all & ~E_STRICT : $e_all;
$e_all = ($arraySystemConfiguration['debug']) ? $e_all : $e_all & ~E_NOTICE; $e_all = ($arraySystemConfiguration['debug']) ? $e_all : $e_all & ~E_NOTICE;
@@ -92,7 +93,9 @@ try {
app()->useStoragePath(realpath(PATH_DATA)); app()->useStoragePath(realpath(PATH_DATA));
app()->make(Kernel::class)->bootstrap(); app()->make(Kernel::class)->bootstrap();
restore_error_handler(); restore_error_handler();
// Do not change any of these settings directly, use env.ini instead // Do not change any of these settings directly, use env.ini instead
ini_set('memory_limit', $arraySystemConfiguration['memory_limit']);
ini_set('display_errors', $arraySystemConfiguration['debug']); ini_set('display_errors', $arraySystemConfiguration['debug']);
ini_set('error_reporting', $e_all); ini_set('error_reporting', $e_all);
ini_set('short_open_tag', 'On'); ini_set('short_open_tag', 'On');
@@ -255,8 +258,7 @@ try {
define('DB_PASS', $DB_PASS); define('DB_PASS', $DB_PASS);
} }
if (!defined('SYS_SKIN')) { if (!defined('SYS_SKIN')) {
$config = System::getSystemConfiguration(); define('SYS_SKIN', $arraySystemConfiguration['default_skin']);
define('SYS_SKIN', $config['default_skin']);
} }
$dateSystem = date('Y-m-d H:i:s'); $dateSystem = date('Y-m-d H:i:s');