I concede that the relational model is the worst form of DBMS except for all those other forms that have been tried from time to time.
Bill Karvin – In Support of the Relational Model
I can’t agree more with that statement. Also I find software like CouchDb really interesting, it will not be the way to go. Beneath modeling, the main advantage of relational models is the flexible question startpoint (in terms of SQL it means the basic information you have beforehand to get the rest of what you need). If you know just a little about tree structure, the start point problem will be self-explaining. Accessing an upper node from a sub node just can’t be implemented as fast as accessing a flat structure and there relations.
Filed under Database, Design, Software design & no comments & no trackbacks
Auf media-adventures.de kann man spezifischen Feeds nun auch spezifische Namen geben und diese bearbeiten. Somit heißt dein Blog nicht länger “Any RSS-Feed”, sondern so, wie du es möchtest.
Filed under Media Adventures, RSS & one comment & no trackbacks
Jakub Steiner proposed to use a darkish theme as the GNOME default. This is a really intersting idea and from a QA point of view it sound pretty sensible. The major problem with GTK is, that only known widgets are styled by themes. So hacky custom widgets are not easily themeable. Aside from that I have some concerns, wheither a dark theme would be associated with hacker desktop, the exact opposite of GNOME’s target.
Nevertheless I will try Darkilouche and gm-looks for a while now. I always disliked dark themes, don’t know exactly why but it is time to try again.
GNOME desktop with gm-looks theme
GNOME desktop with Darkilouche theme
Filed under GNOME, Me, Screenshot & two comments & one trackback
In Mental notes to myself the question was asked, if unit testing is enough. Of course not. Unit testing, especially unit testing with PHP tackles a single problem domain. This problem domain is PHP code quality. So once you have good tests for you PHP code you could assume that is works halfway fine. That’s everything. Between good PHP code and a working application there is a huge gap. There we go: JavaScript, user interface and the services your application consumes. If you have connection problems with your payment provider, a unit test does not solve that problem. But the daily execution of unit tests will eventually help you to tackle it. The JavaScript part can be addressed with a JavaScript unit testing framework, such as JsUnit. Testing the user interface and the backend through the user interface, that’s what was called “black box testing”, can be done with Selenium, which is also integrated with PHPUnit.
To write high-quality software, you have to do all of this. There are a lot of excuses, why not to do this, but they are all just excuses. To make you feel worse, this test strategy is even not sufficient, because you also need human testers. They must be really good, they do blackbox testing, find strange wording, unintuitive interfaces, page-as-cage situations, improper avocation at important conversion points, etc. pp. But a good tester is never as cheap as software, also a tester could not be controlled per command (which is good), so the hard problems need to be tackled before.
Filed under JsUnit, PHPUnit, QA, Selenium & three comments & no trackbacks
MediaVentures wächst und wächst. Immer neue Kollegen und Beteiligungen kommen hinzu und es wird ein wenig übersichtlich, all ihre Blogs, Twitter-, Flickr-, etc. Accounts zusammenzusuchen und zu verwalten. Deshalb stelle ich nun ein angepasstes NoseRub unter media-adventures.de zur Verfügung. Dort kann jeder seine persönlichen Resourcen im Netz verwalten. Zugleich können andere ein globales Feed abonieren und bleiben auf dem neuesten Stand. Vielen Dank an Dirk Olbertz für die Hilfe beim Aufsetzen!
Filed under Media Adventures, Media Ventures GmbH, NoseRub & no comments & no trackbacks
Ubuntu does a lot of patching on free software/open source projects. This patches are often really helpful but they were hard to find in the past. This has changed now as there is a location to browse applied patches by packages. Thanks, Ubuntu!
Filed under Linux, Ubuntu & no comments & no trackbacks
Evert: One thing you should be aware of is, that the actual process of collecting the garbage (and freeing the memory) is done after the session handler functions have been called. This means as long as you don’t unset anything important for your session handling in one of your destructors you can even do it without registering your session close function as a shutdown function.
The following snippet demonstrates this pretty well:
<?php
class SessionHandler
{
protected $_resource;
public function __construct()
{
$this->_resource = fopen('/tmp/foo.txt', 'w+');
}
public function session_write()
{
echo __METHOD__ . "(): " . $this->_checkResource();
}
public function session_close()
{
echo __METHOD__ . "(): " . $this->_checkResource();
}
protected function _checkResource()
{
return "Resource exists: " . (is_resource($this->_resource) ? 'true' : 'false') . "\n";
}
}
$handler = new SessionHandler();
$anon = create_function('', '');
session_set_save_handler($anon, array($handler, 'session_close'), $anon, array($handler, 'session_write'), $anon, $anon);
session_start();
... and the output:
$ php sess.php
SessionHandler::session_write(): Resource exists: true
SessionHandler::session_close(): Resource exists: true
Filed under PHP & no comments & no trackbacks
Larry Garfield did a few OOP performance investigations for applying OOP to the Drupal-Project. His observations are pretty clear: all that funky stuff like interceptors, call_user_func_array() and so on is pretty slow compared to straight function calls. I always had the same feeling but converting a feeling into numbers is pretty good. These differences, may they seem huge, should not have such a great influence on your programming habits. Of course, think twice when you use interceptors, same for call_user_func_array(), but this should not stop you using it. Buying an mediocre webserver is cheaper than a developers salary. That’s the simple computation. If you create a component which allows you simply modulate strong and complex business logic which uses all these features, you will be able to produce more maintainable, more stable more rocking solid code. So the computation becomes a no-brainer at all. There are edge cases, where PHP performance matters. But at the end you are always waiting for the RDBMS-response. And – if you need complex algorithms – think on rolling them out as a C-extension for PHP. It is not that hard to build one.
Filed under Perfomance, PHP & no comments & no trackbacks
In reply to Tantek’s thoughts about OpenID reinventing the hCard wheel and in consideration of Queering Gender: the microformat for gender could be a) a range between 0 and 10 (0 is male and 10 is female) or “OTHER” if the range does not fit it al. “XA” for locations etc. is fine. So users can express a little bit more than just “OTHER”.
Filed under Gender, microformats, Sex & eleven comments & no trackbacks