dimanche 22 février 2015

How to make 2 spring projects share the same code base

I have 2 web projects in Spring MVC that are similar and have the same services and models. I want to split the code in order to have a common CORE.


I created a new project (CORE) with all the services and models that are shared and exported it as jar as specified here (Auto-wiring annotations in classes from dependent jars) but the components are not scanned and auto-wired in CHILD projects.


So, my questions are:


What are the other options besides jars to make the auto-wire happen?


What is the best practice to split code base and share the core components in spring projects?


Aucun commentaire:

Enregistrer un commentaire