2 ms·
> Because you notice that Broadcast-Service happens to already know some other important stuff about all the enregistered clients. Looks like you are trying to
by marcosdumay 4y ago
> Because you notice that Broadcast-Service happens to already know some other important stuff about all the enregistered clients.
Looks like you are trying to get a complete separation of concerns. That's a good practice when modularizing code, but it's not unambiguously good for services, because composing services come with added cost.
On practice that means that if those pieces of information are really important, there will probably exist many services that read them, and trying to reduce that to a single one will break many good qualities your software has elsewhere. Your service having a clear purpose is one of those qualities.