I just wanted to share this quote that I’ve read while I was skimming through Enterprise Integration Patterns. This paragraph clearly phrases my thoughts about a Shared Database, also because I’ve been confronted with its downsides for quite some time now.
One of the biggest difficulties with Shared Database is coming up with a suitable design for the shared database. Coming up with a unified schema that can meet the needs of multiple applications is a very difficult exercise, often resulting in a schema that application programmers find difficult to work with. And if the technical difficulties of designing a unified schema aren’t enough, there are also severe political difficulties. If a critical application is likely to suffer delays in order to work with a unified schema, then often there is irresistible pressure to separate. Human conflicts between departments often exacerbate this problem.
This sounds so familiar to me that it isn’t even funny anymore.
To makes things clear, I personally believe that implementing a shared data model for multiple applications is a very bad idea. The same goes for trying to achieve the one and only domain model. The blue book has a solution for that, called the BoundedContext. The solution for a Shared Database is a private data model that should never be shared to the outside world.
So if you have a choice, do the right thing.