
templates.j2ee.maven2.app.pom.xml.vsl Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of andromda-andromdapp-project-j2ee-maven2
Show all versions of andromda-andromdapp-project-j2ee-maven2
AndroMDA powered J2EE Maven2 Application
The newest version!
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> <modelVersion>4.0.0</modelVersion> <parent> <groupId>$applicationPackage</groupId> <artifactId>$applicationId</artifactId> <version>$applicationVersion</version> </parent> <artifactId>${applicationId}-app</artifactId> <packaging>ear</packaging> <name>$applicationName Application</name> <dependencies> #if ($ejb3 || $ejb) <dependency> #else <!-- If deploying both web and webservice wars, common files can be excluded from war artifacts and referenced as dependencies here --> <!--dependency> #end <groupId>${project.groupId}</groupId> <artifactId>${applicationId}-common</artifactId> <version>${project.version}</version> </dependency> <dependency> <groupId>${project.groupId}</groupId> <artifactId>${applicationId}-core</artifactId> <version>${project.version}</version> <type>ejb</type> #if ($ejb3 || $ejb) </dependency> #else </dependency--> #end #if ($web) <dependency> <groupId>${project.groupId}</groupId> <artifactId>${applicationId}-web</artifactId> <version>${project.version}</version> <type>war</type> </dependency> #end #if ($webservice && !$jsr181Webservice) <dependency> <groupId>${project.groupId}</groupId> <artifactId>${applicationId}-webservice</artifactId> <version>${project.version}</version> <type>war</type> </dependency> #end #if ($workflow) <dependency> <groupId>${project.groupId}</groupId> <artifactId>${applicationId}-workflow</artifactId> <version>${project.version}</version> </dependency> #end <dependency> <groupId>commons-logging</groupId> <artifactId>commons-logging</artifactId> </dependency> #if ($axisVersion.equals("2")) <dependency> <groupId>com.tonicsystems</groupId> <artifactId>jarjar</artifactId> <version>0.6</version> <scope>provided</scope> </dependency> #end #if ($jbossSeam) <dependency> <groupId>org.jboss.seam</groupId> <artifactId>jboss-seam</artifactId> <version>2.2.0.GA</version> <scope>system</scope> <systemPath>${project.basedir}/target/src/resources/lib/jboss-seam.jar</systemPath> </dependency> <dependency> <groupId>com.sun.el</groupId> <artifactId>el-ri</artifactId> <version>1.2</version> <scope>system</scope> <systemPath>${project.basedir}/target/src/resources/lib/el-ri.jar</systemPath> </dependency> <dependency> <groupId>javax.el</groupId> <artifactId>el-api</artifactId> <version>2.2</version> <scope>system</scope> <systemPath>${project.basedir}/target/src/resources/lib/el-api.jar</systemPath> </dependency> #end <dependency> <groupId>log4j</groupId> <artifactId>log4j</artifactId> <scope>provided</scope> </dependency> </dependencies> <build> <finalName>${application.id}-${project.version}</finalName> <resources> <resource> <directory>src/main/config</directory> <targetPath>../</targetPath> <filtering>true</filtering> </resource> <resource> <directory>src/main/application</directory> <targetPath>../${application.id}-${project.version}</targetPath> <filtering>true</filtering> </resource> </resources> <plugins> <plugin> <artifactId>maven-ear-plugin</artifactId> <version>2.8</version> <configuration> <generateApplicationXml>true</generateApplicationXml> <includeJar>false</includeJar> <defaultLibBundleDir>lib</defaultLibBundleDir> <includes>**/*.xml</includes> <excludes>**/jboss-app.xml</excludes> #if ($ejb3) <version>6</version> <ejbVersion>3.0</ejbVersion> #else <version>5</version> #end <archive> <manifest> <addClasspath>true</addClasspath> <useUniqueVersions>false</useUniqueVersions> <addDefaultImplementationEntries>true</addDefaultImplementationEntries> <addDefaultSpecificationEntries>true</addDefaultSpecificationEntries> </manifest> <manifestEntries> <Implementation-Build>${maven.build.timestamp}</Implementation-Build> <url>${project.url}</url> </manifestEntries> </archive> <modules> #if ($jbossSeam) <jarModule> <groupId>com.sun.el</groupId> <artifactId>el-ri</artifactId> <includeInApplicationXml>true</includeInApplicationXml> </jarModule> <jarModule> <groupId>javax.el</groupId> <artifactId>el-api</artifactId> <includeInApplicationXml>true</includeInApplicationXml> </jarModule> <jarModule> <groupId>org.jboss.seam</groupId> <artifactId>jboss-seam</artifactId> <includeInApplicationXml>true</includeInApplicationXml> </jarModule> #end ## JBoss7 gives an error when including non-ejb jar modules in application.xml #if ($ejb3 || $ejb) ## Don't need to reference module from EAR unless using EJBs, already bundled with war project(s) <jarModule> <groupId>${project.groupId}</groupId> <artifactId>${applicationId}-common</artifactId> <includeInApplicationXml>false</includeInApplicationXml> </jarModule> <ejbModule> <groupId>${project.groupId}</groupId> <artifactId>${applicationId}-core</artifactId> </ejbModule> #if ($workflow) <jarModule> <groupId>${project.groupId}</groupId> <artifactId>${applicationId}-workflow</artifactId> <includeInApplicationXml>false</includeInApplicationXml> </jarModule> #end #end #if ($web) <webModule> <groupId>${project.groupId}</groupId> <artifactId>${applicationId}-web</artifactId> <contextRoot>/${application.id}</contextRoot> </webModule> #end #if ($webservice && !$jsr181Webservice) <webModule> <groupId>${project.groupId}</groupId> <artifactId>${project.parent.artifactId}-webservice</artifactId> <contextRoot>/${project.parent.artifactId}-webservice</contextRoot> </webModule> #end </modules> <jboss> <version>5</version> <loader-repository>${project.groupId}:loader=${project.build.finalName}</loader-repository> <loader-repository-config>java2ParentDelegation=false</loader-repository-config> </jboss> </configuration> </plugin> #if ($axisVersion.equals("2")) <!-- remove the 'javax.xml.namespace.QName' class from any jar that bundles it, it causes classloading issues with containers that already have it --> <!-- Commented out because these dependencies should only be bundled with the war, not the ear plugin> <artifactId>maven-antrun-plugin</artifactId> <executions> <execution> <id>remove problem classes</id> <phase>package</phase> <goals> <goal>run</goal> </goals> <configuration> <target> <property name="dependencyClasspath" refid="maven.compile.classpath"/> <taskdef name="jarjar" classname="com.tonicsystems.jarjar.JarJarTask" classpath="${dependencyClasspath}"/> <copy file="${project.basedir}/target/${project.parent.artifactId}-${project.version}/lib/axis2-1.2.jar" tofile="${project.basedir}/target/jarjar/axis2-1.2.jar" failonerror="false"/> <jarjar jarfile="${project.basedir}/target/${project.parent.artifactId}-${project.version}/axis2-1.2.jar"> <zipfileset src="${project.basedir}/target/jarjar/axis2-1.2.jar"/> <zap pattern="javax.xml.namespace.QName"/> </jarjar> <copy file="${project.basedir}/target/${project.parent.artifactId}-${project.version}/lib/stax-api-1.0.1.jar" tofile="${project.basedir}/target/jarjar/stax-api-1.0.1.jar" failonerror="false"/> <jarjar jarfile="${project.basedir}/target/${project.parent.artifactId}-${project.version}/stax-api-1.0.1.jar"> <zipfileset src="${project.basedir}/target/jarjar/stax-api-1.0.1.jar"/> <zap pattern="javax.xml.namespace.QName"/> </jarjar> <copy file="${project.basedir}/target/${project.parent.artifactId}-${project.version}/lib/woden-impl-om-1.0M8.jar" tofile="${project.basedir}/target/jarjar/woden-impl-om-1.0M8.jar" failonerror="false"/> <jarjar jarfile="${project.basedir}/target/${project.parent.artifactId}-${project.version}/woden-impl-om-1.0M8.jar"> <zipfileset src="${project.basedir}/target/jarjar/woden-impl-om-1.0M8.jar"/> <zap pattern="javax.xml.namespace.QName"/> </jarjar> <zip destfile="${project.basedir}/target/${project.parent.artifactId}-${project.version}.ear" basedir="${project.basedir}/target/${project.parent.artifactId}-${project.version}" update="true" /> </target> </configuration> </execution> </executions> </plugin--> #end <plugin> <groupId>org.andromda.maven.plugins</groupId> <artifactId>andromdapp-maven-plugin</artifactId> <version>${andromda.version}</version> <executions> <execution> <goals> <goal>deploy</goal> </goals> </execution> </executions> <configuration> <deployLocation>${jboss.home}/server/default/deploy</deployLocation> <!-- include the generated data source file --> <includes> <include>*ds.xml</include> </includes> </configuration> </plugin> <plugin> <artifactId>maven-source-plugin</artifactId> </plugin> </plugins> </build> <profiles> <!-- This profile here will allow you to specify -Ddeploy=link in order deploy an exploded ear using symbolic links, this allows you to easily edit things like jsp, xhtml, etc and just build the web module without having to deploy the ear --> <profile> <id>link</id> <activation> <property> <name>deploy</name> <value>link</value> </property> </activation> <build> <plugins> <plugin> <groupId>org.andromda.maven.plugins</groupId> <artifactId>andromdapp-maven-plugin</artifactId> <executions> <execution> <goals> <goal>link</goal> </goals> </execution> </executions> <configuration> <deployLocation>${jboss.home}/server/default/deploy</deployLocation> </configuration> </plugin> </plugins> </build> </profile> </profiles> </project>
© 2015 - 2025 Weber Informatics LLC | Privacy Policy