[forge-issues] [JBoss JIRA] (FORGE-388) Better support for multi-modules projects in FORGE

Serhiy V (Commented) (JIRA) jira-events at lists.jboss.org
Sat Dec 3 04:43:40 EST 2011


    [ https://issues.jboss.org/browse/FORGE-388?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12647802#comment-12647802 ] 

Serhiy V commented on FORGE-388:
--------------------------------

Maybe I am missing something but I was not able to find mentioned options in the prompt. Here is my console output (can't attache screenshot because issue is closed)

{code}
D:\tmp\forge-distribution-1.0.0.Beta3\forge-1.0.0.Beta3\bin>forge
   ____                          _____
  / ___|  ___  __ _ _ __ ___    |  ___|__  _ __ __ _  ___
  \___ \ / _ \/ _` | '_ ` _ \   | |_ / _ \| '__/ _` |/ _ \  \\
   ___) |  __/ (_| | | | | | |  |  _| (_) | | | (_| |  __/  //
  |____/ \___|\__,_|_| |_| |_|  |_|  \___/|_|  \__, |\___|
                                                |___/
  Windows? Really? Okay...

[no project] bin $ new-project --named foo --topLevelPackage com.bar --type pom
 ? Use [D:\/tmp/forge-distribution-1.0.0.Beta3/forge-1.0.0.Beta3/bin/foo] as project directory? [Y/n] y
***SUCCESS*** Created project [foo] in new working directory [D:\/tmp/forge-distribution-1.0.0.Beta3/forge-1.0.0.Beta3/bin/foo]
Wrote D:\/tmp/forge-distribution-1.0.0.Beta3/forge-1.0.0.Beta3/bin/foo
Wrote D:\/tmp/forge-distribution-1.0.0.Beta3/forge-1.0.0.Beta3/bin/foo/pom.xml
[foo] foo $ new-project --named foo-core --topLevelPackage com.bar
 ? Use [D:\/tmp/forge-distribution-1.0.0.Beta3/forge-1.0.0.Beta3/bin/foo/foo-core] as project directory? [Y/n] y
***SUCCESS*** Created project [foo-core] in new working directory [D:\/tmp/forge-distribution-1.0.0.Beta3/forge-1.0.0.Beta3/bin/foo/foo-core]
Wrote D:\/tmp/forge-distribution-1.0.0.Beta3/forge-1.0.0.Beta3/bin/foo/foo-core
Wrote D:\/tmp/forge-distribution-1.0.0.Beta3/forge-1.0.0.Beta3/bin/foo/foo-core/pom.xml
Wrote D:\/tmp/forge-distribution-1.0.0.Beta3/forge-1.0.0.Beta3/bin/foo/foo-core/src/main/java
Wrote D:\/tmp/forge-distribution-1.0.0.Beta3/forge-1.0.0.Beta3/bin/foo/foo-core/src/test/java
Wrote D:\/tmp/forge-distribution-1.0.0.Beta3/forge-1.0.0.Beta3/bin/foo/foo-core/src/main/resources
Wrote D:\/tmp/forge-distribution-1.0.0.Beta3/forge-1.0.0.Beta3/bin/foo/foo-core/src/test/resources
Wrote D:\/tmp/forge-distribution-1.0.0.Beta3/forge-1.0.0.Beta3/bin/foo/foo-core/src/main/resources/META-INF/forge.xml
[foo-core] foo-core $
{code}

I was asked only about project directory. And after I've added second project pom.xml of "foo" project is following 
{code}
<?xml version="1.0" encoding="UTF-8"?>
<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns="http://maven.apache.org/POM/4.0.0"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  <modelVersion>4.0.0</modelVersion>
  <groupId>com.bar</groupId>
  <artifactId>foo</artifactId>
  <version>1.0.0-SNAPSHOT</version>
  <packaging>pom</packaging>
  <repositories>
    <repository>
      <id>JBOSS_NEXUS</id>
      <url>http://repository.jboss.org/nexus/content/groups/public</url>
    </repository>
  </repositories>
  <build>
    <finalName>foo</finalName>
  </build>
</project>
{code}

So it is missing 
{code}
<modules>
        <module>foo-core</module>
</modules>
{code}
and respectively pom.xml of "foo-core" is missing "parent" definition.

Do I need to add some special parameters to the commands?

I really don't want to bother you but I can't find mentioned options or any documentation how to work with them.

Thanks,
Serhiy
                
> Better support for multi-modules projects in FORGE
> --------------------------------------------------
>
>                 Key: FORGE-388
>                 URL: https://issues.jboss.org/browse/FORGE-388
>             Project: Forge
>          Issue Type: Feature Request
>          Components: Forge Build, Maven Integration, Shell
>    Affects Versions: 1.0.0.Beta3
>         Environment: Any
>            Reporter: Serhiy V
>            Assignee: Torben Jaeger
>             Fix For: 1.0.0.Beta4
>
>
> By default "new-project" command creates a simple "war" project with everything inside. This is good for simple projects.  But in real world scenario you will most likely would like to split your project on few modules - e.g. "common", "integration", "business" and "ui".
> How to do this with FORGE? Well, it's still a maven projects so you can manually edit pom.xml files and add necessary dependencies and changes.
> But will FORGE be able to setup JPA in "integration" module (should be packaged as jar) and use it "ui" module which should be packages as war? Same questions with other functionality like ability to have EJBs in "business" and test them with arquillian.
> And what about EAR support?
> I can't find any documentation or samples howto do this with current FORGE. List of all available commands does not return anything that can be used to break projects into modules or add existing projects to the current project as new modules.
> There is a FORGE-120 issue. ButI've just downloaded forge-distribution-1.0.0.Beta3.zip and there is no such functionality there.
> From my point of view it is really important to support complex projects but not just simple  single war projects.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the forge-issues mailing list