One can use a service id to identify a specific implementation for an
interface. But sometimes one may have multiple interfaces for the same
purpose. Wouldn't it be easier to have specify the same service ID among
different interfaces ?

For exmaple:

InterfaceA (Implemented by ImplA, Id: "Users", ImplB, Id: "Managers",
ImplC, Id: "Offices")
InterfaceB (Implemented by ImplX, Id: "Users", ImplY, Id: "Managers",
ImplZ, Id: "Whatever")

So that the interfaces also has a role on pinning the implementation using
the services id, and not the service id only. I'm bringing that up because
I, sometimes, find it a bit messy to specify a unique service id for my
services while they don't even share the same interface.

Reply via email to