Error Info: Array ( [0] => 42S02 [1] => 1146 [2] => Table 'lfinder.key_storage_item' doesn't exist )
in /var/www/lfinder/data/www/yii2.lombardfinder.ru/vendor/yiisoft/yii2/db/Command.php at line 837
$exceptionClass = '\yii\db\Exception'; foreach ($this->exceptionMap as $error => $class) { if (strpos($e->getMessage(), $error) !== false) { $exceptionClass = $class; } } $message = $e->getMessage() . "\nThe SQL being executed was: $rawSql"; $errorInfo = $e instanceof \PDOException ? $e->errorInfo : null; return new $exceptionClass($message, $errorInfo, (int) $e->getCode(), $e); } /** * Returns a value indicating whether a SQL statement is for read purpose. * @param string $sql the SQL statement * @return boolean whether a SQL statement is for read purpose. */ public function isReadQuery($sql) {
$this->pdoStatement->closeCursor(); } Yii::endProfile($token, 'yii\db\Command::query'); } catch (\Exception $e) { Yii::endProfile($token, 'yii\db\Command::query'); throw $this->db->getSchema()->convertException($e, $rawSql); } if (isset($cache, $cacheKey, $info)) { $cache->set($cacheKey, [$result], $info[1], $info[2]); Yii::trace('Saved query result in cache', 'yii\db\Command::query'); }
* @return array|boolean the first row (in terms of an array) of the query result. False is returned if the query * results in nothing. * @throws Exception execution failed */ public function queryOne($fetchMode = null) { return $this->queryInternal('fetch', $fetchMode); } /** * Executes the SQL statement and returns the value of the first column in the first row of data. * This method is best used when only a single value is needed for a query. * @return string|null|boolean the value of the first column in the first row of the query result.
* If this parameter is not given, the `db` application component will be used. * @return array|boolean the first row (in terms of an array) of the query result. False is returned if the query * results in nothing. */ public function one($db = null) { return $this->createCommand($db)->queryOne(); } /** * Returns the query result as a scalar value. * The value returned will be the first column in the first row of the query results. * @param Connection $db the database connection used to generate the SQL statement.
* @return ActiveRecord|array|null a single row of query result. Depending on the setting of [[asArray]], * the query result may be either an array or an ActiveRecord object. Null will be returned * if the query results in nothing. */ public function one($db = null) { $row = parent::one($db); if ($row !== false) { $models = $this->populate([$row]); return reset($models) ?: null; } else { return null; }
* @param $key * @return mixed */ protected function getModel($key) { $query = call_user_func($this->modelClass.'::find'); return $query->where(['key'=>$key])->select(['key', 'value'])->one(); } /** * @param $key * @return array */
public function get($key, $default = null, $cache = true, $cachingDuration = false) { if ($cache) { $cacheKey = $this->getCacheKey($key); $value = ArrayHelper::getValue($this->values, $key, false) ?: Yii::$app->cache->get($cacheKey); if ($value === false) { if ($model = $this->getModel($key)) { $value = $model->value; $this->values[$key] = $value; Yii::$app->cache->set( $cacheKey, $value, $cachingDuration === false ? $this->cachingDuration : $cachingDuration
if (YII_ENV_PROD) { // Maintenance mode $config['bootstrap'] = ['maintenance']; $config['components']['maintenance'] = [ 'class' => 'common\components\maintenance\Maintenance', 'enabled' => function ($app) { return $app->keyStorage->get('frontend.maintenance') === 'enabled'; } ]; // Compressed assets //$config['components']['assetManager'] = [ // 'bundles' => require(__DIR__ . '/assets/_bundles.php')
* Bootstrap method to be called during application bootstrap stage. * @param \yii\web\Application $app the application currently running */ public function bootstrap($app) { if ($this->enabled instanceof \Closure) { $enabled = call_user_func($this->enabled, $app); } else { $enabled = $this->enabled; } if ($enabled) { $this->maintenanceText = $this->maintenanceText ?: Yii::t('common', 'Down to maintenance.'); if ($this->catchAllRoute === null) {
if (!isset($component)) { $component = Yii::createObject($class); } if ($component instanceof BootstrapInterface) { Yii::trace("Bootstrap with " . get_class($component) . '::bootstrap()', __METHOD__); $component->bootstrap($this); } else { Yii::trace("Bootstrap with " . get_class($component), __METHOD__); } } }
protected function bootstrap() { $request = $this->getRequest(); Yii::setAlias('@webroot', dirname($request->getScriptFile())); Yii::setAlias('@web', $request->getBaseUrl()); parent::bootstrap(); } /** * Handles the specified request. * @param Request $request the request to be handled * @return Response the resulting response
/** * @inheritdoc */ public function init() { $this->state = self::STATE_INIT; $this->bootstrap(); } /** * Initializes extensions and executes bootstrap components. * This method is called by [[init()]] after the application has been fully configured. * If you override this method, make sure you also call the parent implementation.
*/ public function __construct($config = []) { if (!empty($config)) { Yii::configure($this, $config); } $this->init(); } /** * Initializes the object. * This method is invoked at the end of the constructor after the object is initialized with the * given configuration.
$this->state = self::STATE_BEGIN; $this->preInit($config); $this->registerErrorHandler($config); Component::__construct($config); } /** * Pre-initializes the application. * This method is called at the beginning of the application constructor. * It initializes several important application properties.
require(__DIR__ . '/common/config/base.php'), require(__DIR__ . '/common/config/web.php'), require(__DIR__ . '/frontend/config/base.php'), require(__DIR__ . '/frontend/config/web.php') ); (new yii\web\Application($config))->run(); $cc = ob_get_contents(); ob_clean();
$_SERVER = [ 'REDIRECT_REDIRECT_HTTPS' => 'on', 'REDIRECT_REDIRECT_UNIQUE_ID' => 'ZiFRpVR4bM4nwhxOPrQzrAAAAAc', 'REDIRECT_REDIRECT_PERL5LIB' => '/usr/share/awstats/lib:/usr/share/awstats/plugins', 'REDIRECT_REDIRECT_STATUS' => '200', 'REDIRECT_HTTPS' => 'on', 'REDIRECT_UNIQUE_ID' => 'ZiFRpVR4bM4nwhxOPrQzrAAAAAc', 'REDIRECT_PERL5LIB' => '/usr/share/awstats/lib:/usr/share/awstats/plugins', 'REDIRECT_HANDLER' => 'application/x-httpd-php5', 'REDIRECT_STATUS' => '200', 'HTTPS' => 'on', 'UNIQUE_ID' => 'ZiFRpVR4bM4nwhxOPrQzrAAAAAc', 'PERL5LIB' => '/usr/share/awstats/lib:/usr/share/awstats/plugins', 'HTTP_HOST' => 'lombardfinder.ru', 'HTTP_X_FORWARDED_PROTO' => 'https', 'HTTP_X_FORWARDED_PORT' => '443', 'HTTP_CONNECTION' => 'close', 'HTTP_ACCEPT' => '*/*', 'HTTP_USER_AGENT' => 'claudebot', 'PATH' => '/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin', 'SERVER_SIGNATURE' => '', 'SERVER_SOFTWARE' => 'Apache/2.4.6 (CentOS) mpm-itk/2.4.7-04 OpenSSL/1.0.2k-fips', 'SERVER_NAME' => 'lombardfinder.ru', 'SERVER_ADDR' => '127.0.0.1', 'SERVER_PORT' => '80', 'REMOTE_ADDR' => '18.222.117.109', 'DOCUMENT_ROOT' => '/var/www/lfinder/data/www/yii2.lombardfinder.ru', 'REQUEST_SCHEME' => 'http', 'CONTEXT_PREFIX' => '/php-bin/', 'CONTEXT_DOCUMENT_ROOT' => '/var/www/php-bin-isp-php56/lfinder/', 'SERVER_ADMIN' => 'webmaster@lombardfinder.ru', 'SCRIPT_FILENAME' => '/var/www/lfinder/data/www/yii2.lombardfinder.ru/lombardfinder/index.php', 'REMOTE_PORT' => '55116', 'REDIRECT_URL' => '/index.php', 'GATEWAY_INTERFACE' => 'CGI/1.1', 'SERVER_PROTOCOL' => 'HTTP/1.0', 'REQUEST_METHOD' => 'GET', 'QUERY_STRING' => '', 'REQUEST_URI' => '/loans/metro/bulvar-dmitria-donskogo/type/mikrozajmy', 'SCRIPT_NAME' => '/index.php', 'ORIG_SCRIPT_FILENAME' => '/var/www/php-bin-isp-php56/lfinder/php', 'ORIG_PATH_INFO' => '/index.php', 'ORIG_PATH_TRANSLATED' => '/var/www/lfinder/data/www/yii2.lombardfinder.ru/lombardfinder/index.php', 'ORIG_SCRIPT_NAME' => '/php-bin/php', 'PHP_SELF' => '/index.php', 'REQUEST_TIME_FLOAT' => 1713459621.639775, 'REQUEST_TIME' => 1713459621, 'YII_DEBUG' => 'true', 'YII_ENV' => 'prod', 'DB_DSN' => 'mysql:host=localhost;port=3306;dbname=lfinder', 'DB_USERNAME' => 'lfinder', 'DB_PASSWORD' => 'XbCEVBNyA9hR6C3k', 'DB_TABLE_PREFIX' => '', 'FRONTEND_URL' => 'https://lombardfinder.ru/', 'BACKEND_URL' => '/backend/web', 'STORAGE_URL' => '/storage/web', 'FRONTEND_COOKIE_VALIDATION_KEY' => 'be81d02ca243314ada4b3bada08c026b', 'BACKEND_COOKIE_VALIDATION_KEY' => 'fe59639f5073d082b503907161720479', 'ADMIN_EMAIL' => 'yii@lombardfinder.ru', 'ROBOT_EMAIL' => 'robot@lombardfinder.ru', 'GITHUB_CLIENT_ID' => 'your-client-id', 'GITHUB_CLIENT_SECRET' => 'your-client-secret', 'FACEBOOK_CLIENT_ID' => 'your-client-id', 'FACEBOOK_CLIENT_SECRET' => 'your-client-secret', 'GLIDE_SIGN_KEY' => 'fe59639f507503907161720479', 'GLIDE_MAX_IMAGE_SIZE' => '4000000', ]; $_ENV = [ 'YII_DEBUG' => 'true', 'YII_ENV' => 'prod', 'DB_DSN' => 'mysql:host=localhost;port=3306;dbname=lfinder', 'DB_USERNAME' => 'lfinder', 'DB_PASSWORD' => 'XbCEVBNyA9hR6C3k', 'DB_TABLE_PREFIX' => '', 'FRONTEND_URL' => 'https://lombardfinder.ru/', 'BACKEND_URL' => '/backend/web', 'STORAGE_URL' => '/storage/web', 'FRONTEND_COOKIE_VALIDATION_KEY' => 'be81d02ca243314ada4b3bada08c026b', 'BACKEND_COOKIE_VALIDATION_KEY' => 'fe59639f5073d082b503907161720479', 'ADMIN_EMAIL' => 'yii@lombardfinder.ru', 'ROBOT_EMAIL' => 'robot@lombardfinder.ru', 'GITHUB_CLIENT_ID' => 'your-client-id', 'GITHUB_CLIENT_SECRET' => 'your-client-secret', 'FACEBOOK_CLIENT_ID' => 'your-client-id', 'FACEBOOK_CLIENT_SECRET' => 'your-client-secret', 'GLIDE_SIGN_KEY' => 'fe59639f507503907161720479', 'GLIDE_MAX_IMAGE_SIZE' => '4000000', ];