Hello Martin, always split your code! Of course it depends on how large the project is, but a good practice is to have separate projects for different layers. Some examples:
simple scenario: myproject-web (contains the web app with majority of services and all the pages and components) myproject-persistence (contains dao interfaces, implementations and also model classes) a bit more advanced: myproject-web1 (contains the web app 1 with majority of services and all the pages) myproject-web2 (contains the web app 2 with majority of services and all the pages) myproject-web-components (contains reusable components for all web apps) myproject-persistence-api (contains dao interfaces - dao is not only a code which accesses database(s), but also solr indexes or datagrid for example) myproject-persistence (contains dao implementations and a module service to bootstrap persistence contexts) myproject-model (contains all model classes that is entities) even more advanced: add myproject-model-domain1 (model classes for domain1) myproject-model-domain2 (model classes for domain2) myproject-core (holds services and utility classes for all web apps) myproject-functional-tests (the name implies the purpose) When you have such separation you can share model classes with backend software (in which ever technology it is). You can test each layer separately. For easier installing/deploying artifacts you can cretae myproject-reactor project which only contains pom.xml to buils/install/deploy all projects. If you are serious then you must have jenkins and nexus and follow best practices of creating branches and a proper procedure to release software. There's a lot to it. Hope it helps, borut 2013/10/11 Martin Kersten <martin.kersten...@gmail.com> > Hi, > > I am sitting in front of 1.5 MB of sources and I think about splitting > the project in half. One for the services + entities + utilities the rest > for the web fun. > > It would also allow to test the core only with unit test and barely with > integration tests. Where the web part might be all about integration + > acceptance testing. > > But I am in doubt. the only gain I would have is half the packages at once, > and some separation and shift in thinking. > > Does anyone split projects in core vs web? What is the point in doing so > and why not? > > > Cheers, > > Martin (Kersten), > Köthen >