MongoDB – the pitfalls and how to avoid them

When we first thought about writing this post we were rather tempted to title it „MongoDB – 10 things I hate about you“, but that wouldn’t be fair after all.

We learned the hard way how painful it can be to replace a working MySQL installation with a mongoDB, especially in a large scale project environment, but blaming mongoDB for that would be like blaming a microwave for not being able to prepare an exquisite 3-course menu.
So we won’t (or at least we do not intend to) write your common mongoDB rent, especially because in the end we were able to make it work. But this won’t be a praise on the new hip database either.

Message Queues for web applications with STOMP

Just like human beings, machines need to communicate with each other – and they do this by passing messages around. The simplest form is to use a protocol like TCP and build some sort of API on top of it. But sometimes this just isn’t enough, especially if you want the connection to be reliable and you can’t afford to loose a single message.

Many people tend to implement it with the use of a database. They just save all messages to a table and let the other system fetch those messages and process them. But there are many pitfalls in such implementations and that’s why it’s considered an anti-pattern to use a database for these tasks. Better use a message queue system, these are particularly built for these types of tasks!


Guzzling web services out of the box…

Guzzle has come to a certain fame recently as the framework powering Amazon Web Services new SDK2 for PHP. But what exactly is Guzzle? Guzzle is a framework for building RESTful web service clients. As such it is obviously a very potent HTTP-client library, that presents us with an easy way to send subtly crafted HTTP requests of all flavours to a server and deal with the resulting responses.

But Guzzle is still more than that. Based on a service description file written in JSON – similar to a WSDL-file from the SOAP world – Guzzle builds entire web service clients from scratch and as such relieves us from tedious and repetitive tasks in their implementation.

Development Environments with Vagrant and Puppet


Setting up the infrastructure for new projects can be quite a pain in the ***. Even after the initial setup is done, adding new developers to the team requires a lot of time. Besides explaining the project to the new team member, the project’s development environment has to be installed on the new developer’s computer. This includes setting up virtual machines, web- and database-servers, updating libraries etc.

Many IT companies use the same technologies repeatedly which leaves them with multiple development environments that look very similar but have been set up separately. This problem can be solved by using a configuration management software and a smart tool for handling virtual machines.


Analyze information paths in complex IT-projects —
Use case to visualize several information paths and their impact

My main motivation for writing a blog post about that topic can be summarized in a single sentence

The developers produce software that the customer really needs!

It sounds simple but means that developers require appropriate information in order to deliver output that corresponds exactly to the input that the customer provides, or rather to what the customer really needs. Based on many observations I think the input which is given is influenced by communication paths that vary according to the project.


Grunt – a JavaScript build tool

Build systems have a long tradition in software development infrastructures. They allow for easy automation of tedious tasks that have to be run often while a software product is in development. And there is a great variety of such tasks: compiling source files, running unit tests, gathering metrics from the code and finally deploying it.

This article will introduce Grunt, a build tool for JavaScript projects.

Mayflower and Symfony2

Two weeks ago, I had the chance to attend Symfony Live 2012 in Berlin. At first, I tried to get a ticket by submitting several proposals for talks. This didn’t work out but the organizers were very kind and invited me to attend the conference for free!

A couple of days later, I read about the Symfony2 Framework Certification. I had passed some certifications before (namely Zend Certified Engineer PHP5.3, Oracle Certified Professional (OCP), MySQL 5 Developer, and Scrum Product Owner Certification) and thought this might be a good chance to deepen my Symfony2 knowledge. Mayflower’s reaction to my wish was very positive. In they end, Mayflower covered the certification fee and gave me the chance to be the company’s first Symfony2 Certified Developer.

ACLs and Symfony2

Like most larger PHP frameworks, Symfony2 contains a component that handles all kinds of security topics. Its main two capabilities are authentication and authorization. While making it easy to implement these concepts, the component separates them and executes one after the other. In the first step, the framework determines who the current user is or whether he is who he claims to be respectively (Authentication). Secondly, it evaluates whether he is allowed to perform a certain operation (Authorization).

This article focuses on authorization or – more accurately – Symfony2’s Access Control Lists (ACLs) and how they support the implementation of complex access right models.

Image similarity search with LIRE

Content-based image similarity search — determining the images in a database visually similar to a search image on the basis of pixel data alone — is a hot topic. Applications are numerous. Just recently, has introduced a visual product similarity search for some products, and google has introduced a search-by-image feature.

In addition to hands-on applications, there is a lot of research on the topic. The abilities of university maintained image search engines grow constantly. Unfortunately, implementing current techniques requires a bunch of specialist knowledge and some mathematical sophistication. Fortunately, however, there are effective simple techniques for which there exist open source libraries.

One such library for JAVA is the LIRE API. In this short article, I demonstrate how to implement a basic linear content-based visual image similarity search using this library. Weiterlesen

Development environment for Magento, OXID and Shopware

Developers in smaller and larger e-commerce agencies/shops are often faced with different development environments. Customers who want to evaluate e-commerce platforms like Magento, OXID or Shopware have to handle everything from downloading the packages, their LAMP stack and installing it on-the-go. Of course, you might have your own virtual machine, but for a quick shot you have to create another virtual host etc.

But there’s a solution for that: a vagrant/puppet based development environment for Magento, OXID and Shopware. It consists of a Vagrant build and uses standard puppet recipes for Apache, PHP etc, as well as own (open source) recipes for Magento, OXID and Shopware and installs the appropriate shop system in a box together with a lot of PHP tools.

All you have to do is clone the commerce-dev-environment repository from GitHub and vagrant up :-)

Feature enhancements and Pull Requests are welcome.