[
http://jira.codehaus.org/browse/MECLIPSE-354?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_115168
]
Richard van Nieuwenhoven commented on MECLIPSE-354:
---------------------------------------------------
I would like that, but that would mean synchronizing ~10 different projects and
growing. And synchronizing 2 is already difficult.
And even then, there are still a lot out there that do the stuff differently....
After writing, and reverse engineering a few of what the maven-xxx-plugin does
and how wtp does it differently,
I noticed that some things are very difficult to do in the resources phase and
a peace of cake in a later (package) phase.
Good examples are the application.xml generation and the MANIFEST.MF
generation.
In case of the MANIFEST.MF i tried using the common lib available but for that
we need the dependency resolution of maven finished and when i tried to
activate that,
the eclipse plugin dependency resolution fails.....
When we split the eclipse plugin in two phases a lot of the intelligence of the
eclipse plugin can be deleted. Because in many (now) special cases , it is
"just" a case of
- creating an eclipse source directory (not used by Maven)
- extract all the source and resources in the packaged jar in that directory
excluding all already available (=all generated stuff)
- e.v. adapting the files to eclipse needs
But i know this would be a major change of concept..... still WDYT
> application.xml is not the correct and not the same in the EAR package
> -----------------------------------------------------------------------
>
> Key: MECLIPSE-354
> URL: http://jira.codehaus.org/browse/MECLIPSE-354
> Project: Maven 2.x Eclipse Plugin
> Issue Type: Bug
> Components: RAD support
> Affects Versions: 2.4
> Environment: Windows XP; JDK1.4; RAD6
> Reporter: Olivier Chaumont
>
> When I execute mvn eclipse:rad command on an EAR maven project, the eclipse
> plugin generate the file META-INF/application.xml.
> To generate the content of this file the eclipse plugin read the config of
> the "maven-ear-plugin" in the pom.xml.
> Below the config of the "maven-ear-plugin":
> <plugin>
> <groupId>org.apache.maven.plugins</groupId>
> <artifactId>maven-ear-plugin</artifactId>
> <configuration>
> <displayName>${project.name}</displayName>
> <defaultLibBundleDir>lib</defaultLibBundleDir>
>
> <generateApplicationXml>true</generateApplicationXml>
> <generatedDescriptorLocation>${basedir}/target</generatedDescriptorLocation>
> <modules>
>
> <webModule>
> <groupId>com.bnpparibas.assurance.ic</groupId>
> <artifactId>mypres</artifactId>
>
> <contextRoot>mypres1</contextRoot>
> <bundleFileName>mypres-1.0.war</bundleFileName>
> </webModule>
>
> <webModule>
> <groupId>com.bnpparibas.assurance.ic</groupId>
> <artifactId>mypres</artifactId>
>
> <contextRoot>mypres2</contextRoot>
> <bundleFileName>mypres-1.0.war</bundleFileName>
> </webModule>
>
> <ejbModule>
> <groupId>com.bnpparibas.assurance.ic</groupId>
> <artifactId>Ref_SERV_EJB</artifactId>
> <bundleFileName>myEJB.jar</bundleFileName>
> </ejbModule>
> </modules>
> <finalName>${project.name}-${project.version}</finalName>
> ;</configuration>
> </plugin>
> The generated application.xml file with mvn eclipse:rad :
> <?xml version="1.0" encoding="UTF-8"?>
> <application xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee
> http://java.sun.com/xml/ns/j2ee/application_1_4.xsd"
> xmlns="http://java.sun.com/xml/ns/j2ee"
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" id="Application_ID"
> version="1.4">
> <description/>
> <display-name>myEAR2</display-name>
> <module id="EjbModule_1195818055166">
> <ejb>Ref_SERV_EJB.jar</ejb>
> </module>
> <module id="WebModule_1195818055167">
> <web>
> <web-uri>mypres.war</web-uri>
> <context-root>mypres1</context-root>
> </web>
> </module>
> </application>
> The generated application.xml file with mvn install:
> <?xml version="1.0" encoding="UTF-8"?>
> <!DOCTYPE application PUBLIC
> "-//Sun Microsystems, Inc.//DTD J2EE Application 1.3//EN"
> "http://java.sun.com/dtd/application_1_3.dtd">
> <application>
> <display-name>myEAR2</display-name>
> <module>
> <web>
> <web-uri>mypres-1.0.war</web-uri>
> <context-root>mypres1</context-root>
> </web>
> </module>
> <module>
> <web>
> <web-uri>mypres-1.0.war</web-uri>
> <context-root>mypres2</context-root>
> </web>
> </module>
> <module>
> <ejb>myEJB.jar</ejb>
> </module>
> </application>
> The problem is that the application.xml generated by eclipse plugin and the
> one generated by ear plugin is not the same, and I think ear plugin is good
> one:
> 1- There is one web module in the application.xml file and not two like in
> the pom.xml file.
> 2- The name of the web-uri and the ejb module is not the value of the
> bundleFileName, bit the value of the artifactId.
> 3- The doctype is not the same (it is possible to configure it?)
> Also, I think it would be better that maven-eclipse-plugin doesn't generate
> the application.xml file because maven-ear-plugin do the same thing. Perhaps
> it is possible that maven-eclipse-plugin call maven-ear-plugin code to
> generate it, and so we are sure that the files will be the same.
> Thanks a lot.
> Olivier
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira