[wp-trac] [WordPress Trac] #10779: optimised unzip_file() (was: file.php: PHPDoc + optimised unzip_file())

WordPress Trac wp-trac at lists.automattic.com
Tue Nov 17 21:45:48 UTC 2009


#10779: optimised unzip_file()
-------------------------+--------------------------------------------------
 Reporter:  dd32         |       Owner:  dd32                   
     Type:  enhancement  |      Status:  new                    
 Priority:  normal       |   Milestone:  3.0                    
Component:  Filesystem   |     Version:  2.9                    
 Severity:  normal       |    Keywords:  has-patch needs-testing
-------------------------+--------------------------------------------------
Changes (by dd32):

  * keywords:  has-patch => has-patch needs-testing
  * milestone:  2.9 => 3.0


Old description:

> Patch contains 2 sections:
>  * Much improved PHPDoc coverage for filesystem-related functions in
> file.php
>  * Optimised unzip_file() function
>    * Reduced the number of IO operations required (mainly is_dir())
>    * Simplifies logic to make reading easier.
>
> ---
> Also note, I played with extracting a file at a time from the ZIP, and
> writing  to the filesystem directly, While it decreased the memory usage
> from ~12MB to 3MB for  the entire unzip operation, It increased the
> operation time from 5s to 70s, So i've left it to consume memory in order
> to speed things up.

New description:

 Patch contains
  * Optimised unzip_file() function
    * Reduced the number of IO operations required (mainly is_dir())
    * Simplifies logic to make reading easier.

 ---
 Also note, I played with extracting a file at a time from the ZIP, and
 writing  to the filesystem directly, While it decreased the memory usage
 from ~12MB to 3MB for  the entire unzip operation, It increased the
 operation time from 5s to 70s, So i've left it to consume memory in order
 to speed things up.

--

Comment:

 The phpdoc has gone in with another ticket, I forgot i had submitted it
 here already.

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/10779#comment:3>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list