What do you mean by that "Eclipse is just not good in handling package trees " ?
*---------------------* *Muhammad Gelbana* http://www.linkedin.com/in/mgelbana On Sun, Oct 13, 2013 at 3:22 PM, Martin Kersten <[email protected] > wrote: > Thanks for the replies, > > I currently split it in half. Since I use Hibernate/JPA I just split it > in half having a business layer (including the so called persistence layer) > and a web layer. Later on it will be joined by a project housing the rest > API. > > And that is all necessary because Eclipse is just not good in handling > package trees. Same old story for the last 10 years... . > > > So thanks a lot for your replies. > > > Cheers, > > Martin (Kersten), > Germany > > > 2013/10/13 Borut Bolčina <[email protected]> > > > 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 <[email protected]> > > > > > 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 > > > > > >
