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

  • Home
  • SEARCH
  • 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 7506535
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 29, 20262026-05-29T22:18:20+00:00 2026-05-29T22:18:20+00:00

I am trying to make a multi module project. I have one module for

  • 0

I am trying to make a multi module project. I have one module for JAR containing models, controller and service classes, and another module for the WAR. I have managed to build the project and generated the outcome, but I am unsure about the structure of my folders.

Currently I have made one Maven module in the same project.

Folders are:

Parent
Module1
Module2

They are all on the same level, is that correct? Or should Module1 and Module2 be inside the Parent folder? And is it possible (or will it happen automagically) to have the produced target to appear in the parent folder instead of in each module? Or maybe there is no need for that.

I am using IntelliJ 11 IDEA.

http://www.sonatype.com/books/mvnex-book/reference/multimodule-sect-intro.html

  • 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-29T22:18:22+00:00Added an answer on May 29, 2026 at 10:18 pm

    Typically people put modules under parent (both logically and in directory structure). But it is not a law. It is just a recommendation.
    Now you have to create 4 pom.xml files:
    one on top level and one per project (parent, module1 and module2). The top level pom should mention all its 3 sub-projects:

    <modules>
        <module>parent</module>     
        <module>module1</module>
        <module>module2</module>        
    </modules>
    

    If module1 and 2 depend on parent (that is at the same level) just say:

    <dependencies>
        <dependency>
            <groupId>com.yourcompany.yourproject</groupId>
            <artifactId>parent</artifactId>
            <version>1.0-SNAPSHOT</version>
        </dependency>
    <dependencies>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Have an options table that i'm trying to make multi lingual with an English
I'm trying to make my C# application multi threaded because sometimes, I get an
Trying to make a web service call to an HTTPS endpoint in my Silverlight
While trying to make one of my python applications a bit more robust in
I am trying to make a multi-dimensional array of characters in ruby, and this
I'm trying to make a multi instance engine in C++ with a wrapper for
I am trying to make multi-weighted graphs. Input is to be made in following
I have a Pyramid app and apache with mod_wsgi and I'm trying to make
I am trying to make a multi user login system for my java program,
I am trying to make a multi-table query that I am not quite sure

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.