Hello

Welcome to the blog

Setting modules dir as default

When running code from IntelliJ i often run into the issue, that my project file is not located in the same directory as the code. This will mess up code that are looking for locale files since the don’t exists in the project directory. The solution is quite simple and easy, but for some reason it has taken me for ever to find it. You have to go the edit run / debug configuration, and go under the defaults.
Read more →

Repository pattern

Repository pattern The basic idea of the repository pattern is to seperate buisness logic and persistence logic through a list like sematic. The great thing about this, as asposded to the way orm’s does things is that you force the developer to think about when and how do i access data.You just can’t navigate around in the model, and expect some framework to handle it magiccally for you. The idea of a repository teams up well with aggregates.
Read more →

Logging

#Logging I was browsing through our code at Schantz were i do my daytime hacking. I found something that’s not unusual in our code base. To be fair it’s not unusual in most codebases. The issue is logging, and more specific what log level should be used when. So i’ve decided to give you my take on it. Error The error statement should only be used for actual errors. So if the system will fail catastrophically, and there is no known way to recover, a error is written.
Read more →

Aggregates

Building blocks of Domain Driven Design (DDD) This post will describe the main building blocks of domain driven design (Aggregates, Entities and Value Objects) Entities Are objects that are defined by their identity (id). An example of this could be a ticket to a movie, it’s identity is the row / seat number. One of the more common “mistakes” in DDD, is to define to many objects as entities, so be aware of this pitfall.
Read more →