Should Business Interfaces be part of the Model layer?
- by Mik378
In an oriented-services enterprise application, isn't it an antipattern to mix Service APIs (containing interface that external users depends on) with Model objects (entities, custom exceptions objects etc...) ?
According to me, Services should only depends on Model layer but never mixed with it.
In fact, my colleague told me that it doesn't make sense to separate it since client need both. (model and service interfaces)
But I notice that everytime a client asks for some changes, like adding a new method in some interface (means a new service), Model layer has to be also delivered...
Thus, client who has not interested by this "addition" is constrained to be concerned by this update of Model... and in a large enterprise application, this kind of delivery is known to be very risked...
What is the best practice ? Separate services(only interfaces so) and model objects or mix it ?