We are currently trying to mavenize the existing projects in our company. We have executed a POC and are currently documenting our learnings and guidelines. I have come up the following naming convention for the maven artifacts. Please share your comments on the same
Note: In our company, projectname is always unique
For a single level multi module maven project
Parent (pom)
- groupId : org.companyname.projectname
- artifactId : org.companyname.projectname
- version : x.x.x
eg : org.companyname.projectname:org.companyname.projectname-1.0.0.pom
Modules (jar)
- groupId : org.companyname.projectname
- artifactId : org.companyname.projectname.modulename
- version : x.x.x
eg: org.companyname.projectname:org.companyname.projectname.modulename-1.0.0.jar
For a multi level multi module maven project
Parent (pom)
- groupId : org.companyname.projectname
- artifactId : org.companyname.projectname
- version : x.x.x
eg : org.companyname.projectname:org.companyname.projectname-1.0.0.pom
SubParent (pom)
- groupId : org.companyname.projectname
- artifactId : org.companyname.projectname.subcategory
- version : x.x.x
eg : org.companyname.projectname:org.companyname.projectname.subcategory-1.0.0.pom
Module (jar)
- groupId : org.companyname.projectname
- artifactId : org.companyname.projectname.subcategory.modulename
- version : x.x.x
eg : org.companyname.projectname:org.companyname.projectname.subcategory.modulename-1.0.0.jar