Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6897585
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T07:11:13+00:00 2026-05-27T07:11:13+00:00

I have multiple projects that depends on the same data model. The latter is

  • 0

I have multiple projects that depends on the same data model. The latter is defined by a Maven project. Let’s take as example two composite projects A and B that include multiple modules each one and that depend on this data model. The project A and B are not related.

What is the best approach in this case? To leave the data model as an independent project with A and B depending on it? Or, to define the data model as a module and to include it in the two composite projects A and B (I don’t know if a module may be shared by many projects)?

Thanks

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T07:11:14+00:00Added an answer on May 27, 2026 at 7:11 am

    The “maven way”, especially since projects A and B are unrelated, would be to create a 3rd project for the shared code. It would have its own artifact id and version (separate from A and B).

    When I do this I use the maven-release-plugin to tag it and deploy it to my Maven repository server (Nexus). If you aren’t working this way you can manually build it and it will go in your local repository. When you build the other projects it will resolve.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

For example, I have a document library that hold contracts for multiple projects. So:
I have read that to build multiple Maven projects in one step (with automatic
When you have multiple projects that all use the same set of JAR libraries,
I have multiple, separate leiningen projects that ostensibly could depend on one-another. Example: ~/projects/mywebapp
We have multiple projects in our system that want to share the same asmx
I have multiple projects that need to pass user login information to common-api project
Many times I have seen Visual Studio solutions which have multiple projects that share
I have a large Java app that is split up into multiple projects. Each
I have a Visual Studio 2008 C++ project that has support for using multiple
I have a project where there are multiple applications that have some common configuration

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.