Is it a good idea to not inject Domain Models in Spring. It saves some XML, and what is the use of injecting domain model anyway.
For services and DAO, I want to decouple so I use DI, but Domain Model usually flows all the way from Web to DAO - sort of a vertical layer running through the horizontals.
What do you think? Good or bad? Are there any other recommended best practices to sensibly use Spring instead of adding to XML lines?
I was recommended to use factory pattern at service layer, but then that beats the whole idea behind a DI framework, doesn't it? Factory pattern is a good idea, but that would result in boiler plate code, so it then becomes boiler plate code Vs XML.
Any suggestions on sensibly using Spring on other areas welcome!!