I'm evaluating Spring with Hibernate for a new project I'm working on. I've read through a couple of online articles that discuss using the two together including:
But I must be missing something. The articles seem to imply that you need elements in the Spring configuration file for every DAO and every business service object in the system (possibly dozens or hundreds, right?). But the "wiring" for each is almost identical: All DAOs get a session factory, and all service objects get a transaction manager and a reference to the DAO(s).
Doesn't all this mean that the Spring configuration file is extremely redundant and difficult to maintain for a large app? I don't understand how this is "cleaner" than wiring together the objects in code.