2

I have project like this.

MainProject
|
+- SubProject1
|
+- SubProject2
|
+- SubProject3

And i am trying to execute MVN SITE command. I am able to setup all other section in Project Information Section.

All sub module's POM.XML have SubProject1 entry for this.

that's why i am able to see that module name in Project Modules Section.

But when i am trying to click the submodule link it's looking for HTML file under PARENT PROJECT so something like this.

MainProject/target/site/SubModule1/index.html

Actually that location i don't find anything. So what is the correct approach for MultiModule structure SITE creating ?

Looking for some good multi module material or website to read on this and which can fix my issue. Or if you have guys have any POM.XML to use it please post it here.

Jean-Rémy Revy
  • 5,607
  • 3
  • 39
  • 65
user886614
  • 375
  • 1
  • 4
  • 14

1 Answers1

0

Indeed, the hierarchy in your IDE (Eclipse ?)does not follow the one which will be produced if you run site:deploy (using the distributionManagement section).

When you will generate the site with site:deploy, it will put all elements in (up to apache http server conventions for example) :

/var/htdocs/
 |
 +- /MainProject
    |
    +---/SubProject1
    |   |
    |   +--- /index.html
    |
    +--- /SubProject2
    |   |
    |   +--- /index.html
    |
    +--- /SubProject3
    |   |
    |   +--- /index.html
    |
    +--- /index.html

And you have physically in your workspace :

D:/workspace/
 |
 +- /MainProject
    |
    +---/SubProject1
    |   |
    |   +--- /target
    |   |    |
    |   |    +--- /index.html
    |
    +--- /SubProject2
    |   |
    |   +--- /target
    |   |    |
    |   |    +--- /index.html
    |
    +--- /SubProject3
    |   |
    |   +--- /target
    |   |    |
    |   |    +--- /index.html
    |
    +--- /target
    |    |
    |    +--- /index.html

So, you have one level more between root projects and file than when it's deploy. This structure is not suitable for links which are created aiming a site:deploy :)

If I'm mistaken on your issue, tell me, but it sounds like quite common.

Jean-Rémy Revy
  • 5,607
  • 3
  • 39
  • 65