Should we trust the repository when it comes to invariants?
问题 In the application I'm building there are a lot of scenarios where I need to select a group of aggregates on which to perform a specific operation. For instance, I may have to mark a bunch of Reminder aggregates as expired if they meet the expiration policy (there is only one). I have a ReminderExpirationPolicy domain service that is always applied before delivering reminders. This policy does something like: reminderRepository.findRemindersToExpire().forEach(function (reminder) { reminder