14. November 2008, 16:57, by Leo Büttiker
Users hate your cache
Users don’t like caching! They want to see the changes immediately. Otherwise they get confused and write you bug tickets or flame mails. But if you do not use caching the user comes and make your CPU’s burning. If your site is down you not only get mails from your users, but also from your management.
We worked hard on the right caching strategy over months now. But there are still caches that do not get invalidated right or are cached too long and we still get complaints from our users. So we decided to integrate a feature that allows certain users to invalidate the cache on the server side. The first idea was to add a link to every page that will append a GET-parameter to the site and then avoid the cache.
29. August 2008, 16:55, by Steven Varco
The new filers for our Johnny Project* had just arrived and since our business has “quite a lot” to do with photos, I decided to do a little “unboxing fotostory” again.
The specs of these machines (per machine):
- transtec CALEO 3U
- Quad-Core XEON E5405, 2.0 GHz
- 14 Seagate 1TB SATA-2 Disks, 7200 rpm
- 2 Seagate 146 GB SAS Disk, 15’000 rpm
The three filers cleanly piled up, but still in the box
So, lets open the box!
Of course we all were excited about the inner values of those filers too, so we got them “prepared for surgery” (luckily we didn’t have to use a scalpel for that )
As we can see, there would be “a little bit” of space for RAM extension…
View from the back…
…and from the front. -Looks cute indeed!
But whats even better than one server full of disks…?
Right, THREE SERVERS FULL OF DISKS!
Total Capacity: ~38 TB
The whole environment for our Johnny-Project in the lab.
Left: The Mogile Storage Nodes, Right: The Old new ASUS cache servers
*if you may wonder what’s that mysterious “Johnny Project” im talking about, stay tuned for further blog posts! -We will describe this at a later time.
14. August 2008, 16:45, by Steven Varco
In the beginning of this year, we’ve decided to replace our old mail server, which was pretty at the end of its capacities, dealing with as “little” as 50’000 new mails (sent & received) DAILY for our 1500 mail users.
With also about 800’000 single mails stored, the old mail server ran out of disk space; we surely needed A LOT of disk space and even room for storage expansions.
, 09:07, by Maarten Manders
This week, there was another webtuesday with lightning talks in Zürich. Leo and I each did a little talk:
“StubidDB” by Leo
Leo still dreaming about dumber databases. His own creation StupidDB might sound familiar to you…
“I’m in Ur Browzerz…” by Maarten
Harry had the idea to locate your users based on their history. I tried it out, giving another 8 minutes of fame to an old and well-known hack. The slides can be found here.
7. August 2008, 18:42, by Maarten Manders
All I needed to do was renaming Trevi_Auth to Tilllate_Auth. Sure, it affected some 41 files, but that’s nothing a little bit of search & replace can’t do. The big headache started when I ran the unit tests.
Shuffle Unit Tests = Fail.
It’s absolutely amazing how much you can mess up unit tests just by changing their order! (Trevi_* comes after Tilllate_*) Everyone knows that tests are supposed to be independent. But we all know how it is. People get lazy, mocks are complicated and testing is boring anyway. And don’t forget about that cool pattern called “Singleton” that we’ve all read about in an inflight magazine!
Obviously we can’t do testing right without getting beaten with a stick. So where’s that stick? Is there a way to reset all static variables in PHP? Is there a PHPUnit hack that forks a separate PHP process for each test?
What is your solution to keep your tests from sticking together like spit ? I’m happy to learn about it!
20. July 2008, 18:41, by Silvan Mühlemann
When displaying an e-mail address on a website you obviously want to obfuscate it to avoid it getting harvested by spammers. But which obfuscation method is the best one? I drove a test to find out. Here are the results:
In 2006 I opened nine different e-mail addresses. On this page I published the nine e-mail addresses. But every address has been obfuscated by a different method. I made sure it’s getting indexed by Google by putting a link to that page on the tilllate.com homepage.
Then I waited 1.5 years (see the original post).
For each e-mail address I counted the amount of spam I received. The amount of spam received started by 21MB (for no obfuscation and a total of over 1800 spam mails) and went down to absolutely no spam.
The following three methods are absolutely rock-solid and keep your addresses safe from the harvesters.
22. June 2008, 21:03, by Silvan Mühlemann
If you want to store large amount of volatile data (e.g. log file entries) in a database with a constant storage memory footprint and no maintenance to purge the old entries, a round robin database is the best solution. But how to implement it in MySQL?
Some of the heaviest tables in our database are tables which do some event logging. Let’s look at a table which log the most recent visitors on a member profile. Look at that ugly output:
mysql> SHOW TABLE STATUS like "profile_visits_log" \G;
*************************** 1. row **********************
It grows and grows… And the queries get slower and slower.
This is the case because we are keeping a lot of old, unused data. For example, on my member profile there’s data back to September 2007:
So we have to get rid of that old data. For example we can do it like Xing and store the n most recent entries for each user. Drop the rest:
Now, how do we do that in the most elegant way?
10. June 2008, 15:48, by Leo Büttiker
At 24./25. of September 2008 there will be the OpenExpo in Winterthur. I will be in charge of the PHP booth. I am looking for PHP-Developers, -Evangelists and -Fanboys (and girls) to help me out.
It’s a great opportunity to help spread PHP, meet open source guys or just hang out with other cool PHP guys. Already on the boat are Harry Fuecks (webtuesday organizer, local-hero and PHP-Book-Author), Lukas Smith (PHP Core Dev and Database Expert), Chregu Stocker (PHP Core Dev, liip CEO and Founder), Silvan Mühlemann (PHP-Evangelist, tilllate CTO and Founder) and, well, me.
1. June 2008, 21:15, by Silvan Mühlemann
“unit testing is a test that validates that individual units of source code are working properly”, that’s what Wikipedia says about unit testing. That’s general knowledge.
But what motivates me even more than the increased software quality is that it saves me development time. This sounds odd as you might believe that TDD means writing more code.
Here’s a real-life example:
25. May 2008, 19:28, by Silvan Mühlemann
A refreshing change from my daily routine as tilllate CTO (90% meeting, 10% coding) was my visit at the first Webtuesday Hackday yesterday (Hackday = “a day spent hacking with like minds”, as organizer Harry Fuecks defines it).