Archive for January, 2009|Monthly archive page

Lesson Learned: Beware the Middleman

We’ve been purchasing colocation service for our servers for the past year from Advanced Colocation (a reseller).

At the time, we were on a tight budget for both time and money, so we picked them as our service provider because they gave us the best price for 24/7/365 service on a rack with a 100mbps connection to the internet with unlimited bandwidth.

Turns out that the 24/7/365 service is not provided by Advanced Colocation, but by the service provider whose services they are reselling (in our case, Hurricane Electric).  Though Advanced Colocation has no problem letting you think they provide 24/7/365 service.  In fact, they use that as a selling point.

Getting any kind of support from Advanced Colocation is a nightmare.  If you call them, you get voicemail.  If you leave a voicemail asking them to call you, they won’t call you, they’ll email you (a few days later…..).  If you email them, you may, or may not, get a response.

Anyone with any experience running mission critical services can tell you that this type of support just doesn’t cut it.

Getting support from Hurricane Electric, on the other hand, was great.  The support staff at Hurricane Electric bent over backwards to assist us in any way they could, but at certain points their hands were tied because they needed information/action from Advanced Colocation (their customer).

Case in point:

We have an IP address block that we were given for our use.  This IP address block was given to us by Advanced Colocation.  Who, in turn, gets it from Hurricane Electric (who has no idea who Advanced Colocation gives it to).

Recently we experienced 5 days of downtime because Advanced Colocation gave our IP address block to another customer……..can you believe this?!

To compound the problem, it took 4 days just to get in contact with anyone at Advanced Colocation!

And when I finally did get a hold of someone, they were just like, “sorry, our mistake, but you’ll have to wait for the other customer to stop using the IP address block….”

Just disgusting!

Hurricane Electric, on the other hand, had been trying very, very hard to help me with the problem, but couldn’t because it was an issue with our reseller.  If we’d been purchasing directly from Hurricane Electric, not only do I think that this problem never would have happened, but (if it did happen) it would have been fixed immediately, not 5 days later….

The solution:

To me, there was only one solution: dump Advanced Colocation and purchase service directly from Hurricane Electric.

That’s what we’re doing now and Hurricane Electric’s service and support has been wonderful!

Advanced Colocation?  They are giving us problems canceling our contract.  Surprise, surprise.

They want us to pay an extra month of service and be grateful that they don’t make us pay for an extra year of service (which is the term of the contract).  Never mind the fact that they broke the contract when they GAVE OUR SERVICE TO ANOTHER CUSTOMER!  This is not a piece of networking hardware failing or other service interruption.  This is taking our internet connection and giving it to another customer.  Service outage?  No.  Failure to provide the agreed upon service? Yes.

Sorry, had to let my rant out….

The bottom line:

When purchasing service from a reseller (or middleman) you need to make sure that their service and support matches your needs (not just the originator’s service and support).

Advanced Colocation is not a quality service provider (or even a reputable one) and should be avoided at all cost…….unless you like companies that jerk you around and expect you to thank them for it.

In my opinion, it’s always better to purchase service directly from the  service originator (if possible) rather than a middleman or reseller.  It will be a better experience.

For my part?  Lesson Learned!

PHP Alternative Syntax

So, I was having a discussion with a fellow developer at work today about the advantages of using PHP’s alternative syntax (details here).

Just so we know where everyone’s coming from, I come from a programming background and my colleage comes from a design background.

Anyway, he came to me asking my opinion on using the alternative syntax in scripts where we have a lot of HTML markup mixed in with the PHP code.  His reasons for wanting to do this?  The same as most proponents for using the alternative syntax…….it’s shorter and is easier to read.

Now I try to be impartial when making coding decisions because, let’s face it, our opinions do not affect how the machines execute our code.  It’s a travesty, but it’s true.  However, I just don’t agree that alternative syntax makes code shorter or easier to read.

Wait, wait.   Give me a chance to demonstrate my reasoning before you condem me.

Let’s look at some example code using the alternative syntax:

<p>What a niffty paragraph</p>
<?php if($a == $b): ?>
<p>Only the cool people see this!</p>
<?php endif; ?>
<p>Wow, aren't paragraphs great?</p>

Now, you might say, “this is super awesome. it’s so easy to see where the if block ends and there’s no separate lines for the PHP start and stop tags.”

However, you can do the same thing with less typing in the normal syntax.

Here’s the same code using the normal syntax:

<p>What a niffty paragraph</p>
<?php if($a == $b){ ?>
<p>Only the cool people see this!</p>
<?php } ?>
<p>Wow, aren't paragraphs great?</p>

As you can see, the normal syntax is shorter than the alternative syntax.  The number of lines are the same, but the number of characters is less.  Multiply this character difference by the number of times you use if, while, for, and switch in your script and you have a noticeably larger script file when using alternative syntax.  Which means?  Yep, it takes longer to execute scripts that use the alternative syntax than scripts that use the normal syntax.  Is this execution time difference big enough to matter?  Well, that’s a personal question that each script owner must answer for themselves.

And as for the readability aspect, any developer that is worth their salt uses an editor that highlights or otherwise shows matching braces.  Want to know where the other one is?  Just click on the one your curious about and the editor will show you the other one.

It is my experience that code is hard to read because the person who wrote it did  not format it properly.

Anyway, that’s just my opinion.  I’m sure everyone else has their own.  Please feel free to discuss.  Who knows, maybe you’ll change my mind ;)