our thoughts

Design templates for celeb gossip site RumorMill.

Life blood (Part 1)

April 27 2007
by Rachel

Tagged

Life has a way of throwing surprises at you. Just when you think the three month safety window has passed, you learn that your little one’s heart has just stopped. Just when you think you’ll be able to begin to move on after a simple operation, your life hangs in the balance. Just when you think you will be able to recover, you’re told you must have a blood transfusion. Just when you thought you were having a couple of days of work for Easter, two weeks of being told not to lift a finger have gone by.

Sometimes plans have to be thrown out the window and new ones dreamt of when you have strength to dream again.

Thank you for all your kind messages, prayers, flowers and support.

Announcements!

April 9 2007
by Rachel

Tagged

,

I’m proud to announce that my brother Stephen is now working with me and doing a fantastic job coding in WordPress and Drupal. He recently was part of a team that won a bronze medal in Japan at the ACM-ICPC programming competition and has recently completed his degree in computer science and mathematics at Auckland University. It was about time I had someone else to help me which leads me to my second announcement…

I’m also very excited to announce that I’m pregnant! The baby is due in October and things are going well. Thankfully no sickness ever but I am needing an awful lot of sleep (I feel like a hibernating bear at times) and get tired incredibly easily. Will keep you updated.

Digg This Module

April 8 2007
by Rachel

Last week we began noticing a problem on Throng. Some pages were taking a ridiculous time to load (~3 minutes!) all of a sudden. We hadn’t changed any code recently, so checked in with our host, Media Temple. We’ve had a few headaches with them as a host this year as their grid service had some serious growing pains but this time, everything seemed to be OK from their end.

We scratched our heads and tried all sorts of things: we put the site in offline mode and turned off all the ad server code we were using, just in case there was a problem with one of their servers. No change: still 3 minutes to load some pages. And during those 3 minutes, nothing on the page displayed at all. We installed the devel module which helps identify database problems and load times. We added in timers at various parts of the template to find out where the problem was occurring. Still no clues. We turned off lots of modules to see if it was one of those. We tried using Firebug and the Web Developer Toolbar extensions for Firefox to see if it was any of those. We went on the Drupal irc channels and talked to some people who thought it was the host’s problem, not ours. I wasn’t convinced.

Someone gave us a vital clue: a 3 minute time to load sounded like a timeout on an external service of the default of 180 seconds. We finally remembered about the Digg This module that we’d been using for some time on the site, without problem. Turning this off solved the problem!

I wanted to understand why a module like this could suddenly bring a site to its knees and why it happened all of a sudden.

Looking through the module’s code, there is a snippet which interacts with Digg’s API:

function _request_diggthis($url) {
global $digg_story_url;
$request_url = 'http://services.digg.com/stories?link='. $url;
$ch = curl_init($request_url);
curl_setopt($ch, CURLOPT_HEADER, 0);
ob_start();
curl_exec($ch);
$xml = ob_get_clean();
curl_close($ch);
...

After some googling, I found there are others out there who are saying that Digg changed its API last week and it stopped their 3rd party Digg this plugins from working on WordPress as well as on Drupal. If Digg has changed its API and broken a lot of people’s code, then that seems like a big deal to me. Meanwhile, Digg has recently provided more and more ways of having a Digg this button on your site with some simple code.

I’ve submitted an issue for the Digg This module for Drupal and hope that others won’t have the same headaches that we’ve had trying to find the source of the problem!

Elsewhere: Skype MSN Messenger Twitter Facebook