[Toolserver-l] Resource intensive tools

draicone at gmail.com draicone at gmail.com
Sun Jul 1 08:17:53 UTC 2007


Hello all,

I'm in the process of building my first tool on ts, a text copyright
violation checker similar to copyscape.com. However, it is currently so
resource intensive I'm worried I'll crash the toolserver with it. Basically,
it is a PHP script doing the following:

   - 7 includes from disk (this could be reduced to three)
   - 12 HTTP requests to external servers (although all requests are
   fully cached with 24 hour expiration)
   - 12 disk reads (of above requests) regardless of caching
   - 300-350 (approx) regexps (mostly preg_replace() calls)
   - A whole lot of iteration.

A script execution fully cached can run in about 1.5 seconds, but the moment
the script has to go back to the web that increases to anywhere from 10 to
15 seconds. On one of my tests, I even got a "*Fatal error*: Allowed memory
size of 16777216 bytes exhausted (tried to allocate 3492940 bytes)".
Compared to many of the other tools on the server, I was afraid this could
be simply too resource intensive. Can anyone tell me if this would be
appropriate for the toolserver, or if I should host it somewhere else?

-- Draicone
**
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.wikimedia.org/pipermail/toolserver-l/attachments/20070701/71276f29/attachment.htm 


More information about the Toolserver-l mailing list