Wo piepts?

Posted by Mike Haller on Monday, December 31. 2007 at 10:08 in Private
Seit Tagen (und Nächten) höre ich alle paar Minuten ein Piepsen im Hausgang. Es piepst, und ich laufe los, in die Richtung wo ich glaube, dass der Ursprung liegt - runter in den Keller. Ich stehe also im Keller und warte und warte. Aha, es piepst wieder, aber hier ist es nicht. Also in ein anderes Zimmer und wieder warten. Diesmal dauert es mir zu lange und ich warte nicht mehr länger.

Dieses Katz- und Mausspiel ging eine ganze Weile und immer wieder hege ich die Hoffnung, den Störenfried gefunden zu haben und entnehme Batterien aus Fernbedienungen, schalte Rechner aus, Kontrolliere Handy und PDA, beobachte den elektronischen Tacho am Fahrrad etc. nichts hilft - das Piepsen geht weiter. Vermutlich ist es irgendein Gerätchen, was ein Problem hat und Hilfe braucht.

Mit einer Stoppuhr bewaffnet finde ich heraus, dass es meistens 3:20 Minuten dauert, bis es wieder piept. Dann piept es jede Minute, dann wieder alle 6 Minuten. Dann hört es wieder für eine ganze Stunde auf.

Exceeding mail quota

Posted by Mike Haller on Friday, December 28. 2007 at 17:51 in Hosting
One of my customers of my hosting business called me and was really upset. He wasn't receiving any emails any more. I checked the system, the mailserver and the logs and could not find a problem on our site. Then, i checked the customers email accounts manually. He exceeded his quota on his main email account info@foo.bar (i mention that, because it's a catch-all account and thus receives a lot of spam).

I told him that his quota was exceeded and he has to delete old mails to make room for new ones. Unfortunately, he already did that quite regularly. After a talk with the "tech-guy" of the customer, the cause of the problem became pretty obvious: the customer had his own mailserver, which uses fetchmail to gather mails from our mailserver. Our mailserver automatically moves high-level spam into a subfolder of the users mail inbox: "Inbox\Junk". His fetchmail is not configured to retrieve subfolders, so only the inbox was cleared, the Junk folder became bigger and bigger and finally filled the box up to the quota limit.

The user was unaware of that little technical detail, as he also has a "Junk" folder in his mailer application and it was empty according to him.

I solved the problem by automatically deleting mails in the Junk folder which are older than 2 weeks using a simple cron job:



#!/bin/bash

find /var/spool/mail -name ".Junk" -type d | \

xargs -I "%" find % -type f -mtime 14



Flash Element TD 2, Beta v0.17

Posted by Mike Haller on Monday, December 17. 2007 at 00:43
Casual Collective, an online game site, has published a beta version of the Flash Element TD2 game. They also have a cool flash-based multiplayer game called Multiplayer Desktop Tower Defence. I played the game now for two hours and got to level 34.

The goal of the game is to prevent the opponents (the Creeps), to steal your Elements. The Elements are some coloured bubbles
at the end of a maze which the opponents have to walk through, while the player is adding weapon towers to the maze.
The weapons fire at the creeps to shoot them down before they can make the way back to the entry/exit doorway.

How to mock iBatis SqlMapClient

Posted by Mike Haller on Monday, December 3. 2007 at 11:08 in Java
When mocking DAOs accessing stored procedures, declaring the expected results becomes a little bit ugly. That's because the expected results needs to be injected by reference into the IN/OUT parameter object, usually a Map. To make things worse, this Map could be created within the class under test, so you need additional effort to mock that, too.

My solution is based on EasyMock, Spring Framework and Apache iBatis SqlMap for Java.

Shocked

Posted by Mike Haller on Sunday, December 2. 2007 at 14:03 in Java
At work, i had to remove functionality from a project due to specification changes.

Although I have more than 200 unit tests and a coverage of 54%, the removal of the functionality did not trigger any failures.

I'm shocked and disillusioned.

About

My name is Mike Haller and I'm a software developer and architect at Innovations Software Technology in Germany. I love programming, playing games and reading books. I like good food, making photos and learning and mentoring about the craftsmanship of commercial software development.

Quicksearch