Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Maven project with 180 POMs -- is this a code smell?

We have a large, 15 year-old, monolithic Java/Scala application that we build using Maven 3. The build is complex, having many sub-projects nested hierarchically. It works successfully, but takes 10 minutes (without tests) to do full build. I think we're up to 180 pom.xml files, with a fair number of dependencies.

Of course we're working to extract services that can build, deploy, and run independently -- this will be a multi-year project.

Until then, are there guidelines, best practices, on how to structure the build as projects get larger?

like image 791
Tom Harrison Avatar asked Oct 17 '22 17:10

Tom Harrison


1 Answers

(I think this question is too broad for this format.)

I can recommend the "Working Effectively with Legacy Code" book by Michael Feathers for this kind of situation. It has excellent advice and recipes for dealing with the kind of codebase you describe. I was in a similar situation and found it very useful.

like image 199
Rich Avatar answered Oct 19 '22 09:10

Rich