This discussions tend to focus on the two extremes. What are best practices for making monoliths ready for future SOA design - Workers listening on event bus - Database queries abstracted in RepositoryObjects - ServiceObjects isolating domain logic - Specs isolated around concepts - Extracting to plugins (eg vendored gems) if not part of domain logic What are your recommendations?
- avoid code sharing wherever possible. It creates an implicit dependency. (If you have a common library or util file, you've done it wrong. try again.)
- don't merge your trees: (ie: each component in the code should have it's own readme and tests folder.)
- write far more unit tests than functional/integration tests.
(if you separate out components later, those tests can't move with them)
- if you use an ORM or similar, you are probably going to have a very bad time about it (breaks the no-shared code rule)