tirenweb
tirenweb

Reputation: 31739

symfony: about an admin module. The size of the table maybe matters?

I'm getting the error below when I try to show the list of an admin module (as you can see I send two requests: the first at 18:45 and the second at 18:48). The model has 9500 rows in the table.

[Mon Jan 30 18:45:07 2012] [error] [client 127.0.0.1] PHP Fatal 
error:  Maximum execution time of 30 seconds exceeded in /home/javier/ 
eclipse-php/workspace/prueba/lib/vendor/symfony/lib/plugins/ 
sfDoctrinePlugin/lib/vendor/doctrine/Doctrine/Collection.php on line 
473 
[Mon Jan 30 18:45:07 2012] [error] [client 127.0.0.1] PHP Fatal 
error:  Call to a member function shutdown() on a non-object in /home/ 
javier/eclipse-php/workspace/prueba/lib/vendor/symfony/lib/util/ 
sfContext.class.php on line 594 
[Mon Jan 30 18:45:08 2012] [notice] child pid 1340 exit signal 
Segmentation fault (11) 
[Mon Jan 30 18:48:02 2012] [error] [client 127.0.0.1] File does not 
exist: /home/javier/eclipse-php/workspace/prueba/web/favicon.ico 
[Mon Jan 30 18:48:34 2012] [error] [client 127.0.0.1] PHP Fatal 
error:  Maximum execution time of 30 seconds exceeded in /home/javier/ 
eclipse-php/workspace/prueba/lib/vendor/symfony/lib/plugins/ 
sfDoctrinePlugin/lib/vendor/doctrine/Doctrine/Collection.php on line 
473 
[Mon Jan 30 18:48:35 2012] [notice] child pid 1339 exit signal 
Segmentation fault (11) 

I don't have any problem with other admin modules based on other models that have less rows..So what should I do? In /etc/php5/apache2/php.ini I set the memory limit to 4096MB (memory_limit = 4096M).

A clue: this is exactly what is written in line 473 of Collection.php:

        /** 
         * for some weird reason in_array cannot be used here (php 
bug ?) 
         * 
         * if used it results in fatal error : [ nesting level too 
deep ] 
         */ 
        foreach ($this->data as $val) { // line 473 
            if ($val === $record) { 
                return false; 
            } 
        } 

and this is what is written in line 594 in sfContext.class.php:

  /** 
   * Execute the shutdown procedure. 
   * 
   * @return void 
   */ 
  public function shutdown() 
  { 
    // shutdown all factories 
    if($this->has('user')) 
    { 
      $this->getUser()->shutdown();  //line 594 
      $this->getStorage()->shutdown(); 
    } 

Any help?

sf 1.4

Javier

Upvotes: 0

Views: 497

Answers (1)

Harold
Harold

Reputation: 699

I had same problem. I solved with:

filter:
   class: false

In the generator.yml.

I had a too much options in select form in my filter

Upvotes: 2

Related Questions