I have identified below layers to be implemented in my application. According to my knowledge multi layered architecture is prefered for an enterprise application.
- Presentation Layer
- Business Layer
- Data Access Layer
- Service Layer
I have chosen Symfony2 as the framework to be used in the app. Symfony2 has MVC architecture built into it. And the above layers exist as below.
- Presentation Layer => Controller & Views
- Business Layer, Service Layer => Model
- Data Access Layer => Also Model but Doctrine is used.
Model is consisted with Business Layer, Data Access Layer, Service Layer. See the below image that is borrowed from Martin Fowler's book, Patterns of Enterprise Application Architecture.
My problem is,
is there a way to decouple the model into separate Business Layer, Data Access Layer, Service Layer ? How to implement multi Layered architecture in PHP ? Should I use some other framework(If only it supports layered architecture) ?
Update
Below link was helpful
How should a model be structured in MVC?
How to build n-layered web architecture with PHP?
What is difference of developing a website in MVC and 3-Tier or N-tier architecture?
MVC application. How does mult-tier architecture fit in?