Category Archives: PHP

WordPress performance with caching

In my last entry, I detailed the performance gains to be had from switching host providers.  That’s pretty cool, but a lot can still be done within WordPress to improve performance with caching.  Here, I’m going to use the URL from my previous blog post (, and I’m going to run it through similar benchmark tests to see what kind of difference that makes.

During these tests, nothing is being changed except for the caching plugin.  All server variables remained constant, and no other plugins were touched at this time.  This plugin will allow wordpress to generate a static html webpage to take the place of php/mysql code.  Therefore, a page request will simply read a flat file that is ready to go vs execute php code and pull data from the database, limiting processing time.

Note, this test is not downloading images, javascript or any other static content that can be included with a webpage.  I’m purposely leaving that out, testing the webserver’s ability to process the wordpress php code only.

Test #1: 1000 requests, single threaded

Example command: ab  -n 1000 -e post_280_ssl_std.csv -g post_280_ssl_std_gnuplot.tsv

General Numbers:

 Uncached  Cached
 Document Length  35424 bytes  35568 bytes
 Concurrency Level  1  1
 Time taken for tests  280.391 seconds  171.673 seconds
 Complete Requests  1000  1000
 Failed Requests  389 (length)  0
 Total Transferred  35,789,569 bytes  35,873,068 bytes
 HTML transferred:  35,423,569 bytes  35,568,000 bytes
 Requests per second:  3.57 [#/sec]  5.83 [#/sec]
 Mean time per request:  280.391 [ms]  171.673 [ms]
 Transfer rate:  124.65 [Kbytes/sec]  204.06 [Kbytes/sec]

For this test, there were 389 failed requests based on length.  Researching this error indicates it could be caused by dynamic content, and does not necessarily indicate a problem.  Therefore, I’m going to ignore this figure, and assume all connections were successful.

Continue reading

XBOX Live Tracker

Project is no longer live.  Please read update from 2/4/2011

Starting in January 2010, I was cooped up at home, filling my idle time with videogames.  Well, that only kept me occupied for so long, so I decided to make better use of my time, creating an xbox live tracker.

It is currently hosted at

The principle behind the tracker is pretty simple.  I created a python script to go out and fetch xbox live information once an hour.  This information was logged into a MySQL database, which is accessed on the website through PHP.

Thanks to a service hosted on, my python script is able to grab information on a per user basis.  The script grabs account information, such as the correct formatting for the gamertag, gamerscore, current online status, a brief history of games, and a few other tidbits of information.

A gamertag must be entered into the system by manually adding them to the database.  They do not show up on the site until the next time the script is run.  The data is stored in a 5 table database.  Game titles are automatically added when they are observed from the xbox status.

Currently, the project is not under active development.  It may be integrated with other projects, but further development on it’s own is unlikely.