Browse Source

Updated PR500 benchmark_config with a unique framework name

tfb 12 years ago
parent
commit
e53303c0de

+ 1 - 1
php-symfony2-stripped/benchmark_config

@@ -1,5 +1,5 @@
 {
 {
-  "framework": "symfony2",
+  "framework": "symfony2-stripped",
   "tests": [{
   "tests": [{
     "default": {
     "default": {
       "setup_file": "setup",
       "setup_file": "setup",

+ 23 - 5
php-symfony2/app/SymfonyRequirements.php

@@ -16,7 +16,7 @@
  *
  *
  * ************** CAUTION **************
  * ************** CAUTION **************
  *
  *
- * DO NOT EDIT THIS FILE as it will be overriden by Composer as part of
+ * DO NOT EDIT THIS FILE as it will be overridden by Composer as part of
  * the installation/update process. The original file resides in the
  * the installation/update process. The original file resides in the
  * SensioDistributionBundle.
  * SensioDistributionBundle.
  *
  *
@@ -307,7 +307,7 @@ class RequirementCollection implements IteratorAggregate
     }
     }
 
 
     /**
     /**
-     * Returns all optional recommmendations.
+     * Returns all optional recommendations.
      *
      *
      * @return array Array of Requirement instances
      * @return array Array of Requirement instances
      */
      */
@@ -554,6 +554,20 @@ class SymfonyRequirements extends RequirementCollection
             'Your project might not work properly due to the PHP bug #61453 ("Cannot dump definitions which have method calls"). Install PHP 5.4.1 or newer.'
             'Your project might not work properly due to the PHP bug #61453 ("Cannot dump definitions which have method calls"). Install PHP 5.4.1 or newer.'
         );
         );
 
 
+        $this->addRecommendation(
+            version_compare($installedPhpVersion, '5.4.11', '>='),
+            'When using the logout handler from the Symfony Security Component, you should have at least PHP 5.4.11 due to PHP bug #63379 (as a workaround, you can also set invalidate_session to false in the security logout handler configuration)',
+            'Install PHP 5.4.11 or newer if your project uses the logout handler from the Symfony Security Component.'
+        );
+
+        $this->addRecommendation(
+            (version_compare($installedPhpVersion, '5.3.18', '>=') && version_compare($installedPhpVersion, '5.4.0', '<'))
+            ||
+            version_compare($installedPhpVersion, '5.4.8', '>='),
+            'You should use PHP 5.3.18+ or PHP 5.4.8+ to always get nice error messages for fatal errors in the development environment due to PHP bug #61767/#60909',
+            'Install PHP 5.3.18+ or PHP 5.4.8+ if you want nice error messages for all fatal errors in the development environment.'
+        );
+
         if (null !== $pcreVersion) {
         if (null !== $pcreVersion) {
             $this->addRecommendation(
             $this->addRecommendation(
                 $pcreVersion >= 8.0,
                 $pcreVersion >= 8.0,
@@ -630,11 +644,15 @@ class SymfonyRequirements extends RequirementCollection
         }
         }
 
 
         $accelerator =
         $accelerator =
-            (function_exists('apc_store') && ini_get('apc.enabled'))
+            (extension_loaded('eaccelerator') && ini_get('eaccelerator.enable'))
+            ||
+            (extension_loaded('apc') && ini_get('apc.enabled'))
+            ||
+            (extension_loaded('Zend OPcache') && ini_get('opcache.enable'))
             ||
             ||
-            function_exists('eaccelerator_put') && ini_get('eaccelerator.enable')
+            (extension_loaded('xcache') && ini_get('xcache.cacher'))
             ||
             ||
-            function_exists('xcache_set')
+            (extension_loaded('wincache') && ini_get('wincache.ocenabled'))
         ;
         ;
 
 
         $this->addRecommendation(
         $this->addRecommendation(

+ 7 - 8
php-symfony2/app/bootstrap.php.cache

@@ -234,7 +234,7 @@ return isset($this->scopedServices[$name]);
 }
 }
 public static function camelize($id)
 public static function camelize($id)
 {
 {
-return preg_replace_callback('/(^|_|\.)+(.)/', function ($match) { return ('.'=== $match[1] ?'_':'').strtoupper($match[2]); }, $id);
+return strtr(ucwords(strtr($id, array('_'=>' ','.'=>'_ '))), array(' '=>''));
 }
 }
 public static function underscore($id)
 public static function underscore($id)
 {
 {
@@ -325,13 +325,12 @@ protected $debug;
 protected $booted;
 protected $booted;
 protected $name;
 protected $name;
 protected $startTime;
 protected $startTime;
-protected $classes;
 protected $errorReportingLevel;
 protected $errorReportingLevel;
-const VERSION ='2.2.1';
-const VERSION_ID ='20101';
+const VERSION ='2.2.8';
+const VERSION_ID ='20208';
 const MAJOR_VERSION ='2';
 const MAJOR_VERSION ='2';
 const MINOR_VERSION ='2';
 const MINOR_VERSION ='2';
-const RELEASE_VERSION ='1';
+const RELEASE_VERSION ='8';
 const EXTRA_VERSION ='';
 const EXTRA_VERSION ='';
 public function __construct($environment, $debug)
 public function __construct($environment, $debug)
 {
 {
@@ -340,7 +339,6 @@ $this->debug = (Boolean) $debug;
 $this->booted = false;
 $this->booted = false;
 $this->rootDir = $this->getRootDir();
 $this->rootDir = $this->getRootDir();
 $this->name = $this->getName();
 $this->name = $this->getName();
-$this->classes = array();
 $this->bundles = array();
 $this->bundles = array();
 if ($this->debug) {
 if ($this->debug) {
 $this->startTime = microtime(true);
 $this->startTime = microtime(true);
@@ -352,7 +350,9 @@ public function init()
 ini_set('display_errors', 0);
 ini_set('display_errors', 0);
 if ($this->debug) {
 if ($this->debug) {
 error_reporting(-1);
 error_reporting(-1);
+if (class_exists('Symfony\Component\ClassLoader\DebugClassLoader')) {
 DebugClassLoader::enable();
 DebugClassLoader::enable();
+}
 ErrorHandler::register($this->errorReportingLevel);
 ErrorHandler::register($this->errorReportingLevel);
 if ('cli'!== php_sapi_name()) {
 if ('cli'!== php_sapi_name()) {
 ExceptionHandler::register();
 ExceptionHandler::register();
@@ -876,7 +876,7 @@ if ($relativePath = $file->getRelativePath()) {
 $ns .='\\'.strtr($relativePath,'/','\\');
 $ns .='\\'.strtr($relativePath,'/','\\');
 }
 }
 $r = new \ReflectionClass($ns.'\\'.$file->getBasename('.php'));
 $r = new \ReflectionClass($ns.'\\'.$file->getBasename('.php'));
-if ($r->isSubclassOf('Symfony\\Component\\Console\\Command\\Command') && !$r->isAbstract()) {
+if ($r->isSubclassOf('Symfony\\Component\\Console\\Command\\Command') && !$r->isAbstract() && !$r->getConstructor()->getNumberOfRequiredParameters()) {
 $application->add($r->newInstance());
 $application->add($r->newInstance());
 }
 }
 }
 }
@@ -1078,7 +1078,6 @@ return (string) $var;
 namespace Symfony\Component\HttpKernel\DependencyInjection
 namespace Symfony\Component\HttpKernel\DependencyInjection
 {
 {
 use Symfony\Component\HttpFoundation\Request;
 use Symfony\Component\HttpFoundation\Request;
-use Symfony\Component\HttpFoundation\Response;
 use Symfony\Component\HttpKernel\HttpKernelInterface;
 use Symfony\Component\HttpKernel\HttpKernelInterface;
 use Symfony\Component\HttpKernel\HttpKernel;
 use Symfony\Component\HttpKernel\HttpKernel;
 use Symfony\Component\HttpKernel\Controller\ControllerResolverInterface;
 use Symfony\Component\HttpKernel\Controller\ControllerResolverInterface;

+ 1 - 1
php-symfony2/app/config/parameters.yml

@@ -1,6 +1,6 @@
 parameters:
 parameters:
     database_driver: pdo_mysql
     database_driver: pdo_mysql
-    database_host: 192.168.100.102
+    database_host: tfbdata
     database_port: null
     database_port: null
     database_name: hello_world
     database_name: hello_world
     database_user: benchmarkdbuser
     database_user: benchmarkdbuser

+ 1 - 1
php-symfony2/deploy/nginx.conf

@@ -66,7 +66,7 @@ http {
         #    proxy_pass   http://127.0.0.1;
         #    proxy_pass   http://127.0.0.1;
         #}
         #}
 
 
-        root /home/ubuntu/FrameworkBenchmarks/php-symfony2/web/;
+        root /home/tfb/FrameworkBenchmarks/php-symfony2/web/;
         index  app.php;
         index  app.php;
 
 
         location / {
         location / {