Fork me on GitHub

Mohammad AbuShady Software Developer

Atomicity comes from the greek word ‘a-tomos’ which means undevidable, atomic database transactions means that we want either all the database operations to happen together, or none of them at all, which means that we want them as a single undevidable operation, we would want that because not doing any of the changes at all would be much less harmful than doing the a part of the change.

Continue reading

We’ve all written this kind of code at some point of our lives, a query that requires a join, and adding a condition to the joined table to limit the returned results, but then by doing that you’re adding a dependency, and you are coupling the two models together.

Continue reading

I’ve added an RSS feed for the blog to make it easier for people who are reading this blog - if any - be able to keep track of my posts and find out when the new posts come out, you can access the rss feed from this link or you can just hit the feed button on your browser.

I was helping a fellow developer on his rails project, and I found something interesting in his code, it was a query on how to find if two date intervals are intersecting or not.

Continue reading

Defining law of demeter

The law of demeter simply states that objects should only talk to them selves or objects directly associated to them selves, because otherwise this is considered a dependency and would reduce maintainability and cause tight coupling between objects.

Continue reading