You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by "Brett Porter (JIRA)" <ji...@codehaus.org> on 2005/10/24 05:44:12 UTC
[jira] Closed: (MNG-1288) war:exploded removes content of .class files
[ http://jira.codehaus.org/browse/MNG-1288?page=all ]
Brett Porter closed MNG-1288:
-----------------------------
Assign To: Brett Porter
Resolution: Fixed
Fix Version: 2.0.1
applied
> war:exploded removes content of .class files
> --------------------------------------------
>
> Key: MNG-1288
> URL: http://jira.codehaus.org/browse/MNG-1288
> Project: Maven 2
> Type: Bug
> Components: maven-war-plugin
> Environment: WIndowx XP
> Reporter: Victor Yushenko
> Assignee: Brett Porter
> Fix For: 2.0.1
> Attachments: MNG-1288-maven-war-plugin.patch
>
>
> To enable development in MyEclipse I have been configuring maven to build a folder with 'war' extention during the build. This then becomes an expanded folder that I can just copy (actually MyEclipse does it) to jboss for deployment.
> After the build my folder structure looks like this:
> --src
> |-----main
> ...
> --target
> |---testweb.war
> |---css
> |---WEB-INF
> |---- classes
> |---- lib
> |---- jsp
> I also configure compiler to compile files directy into target/${project.build.finalName}.war/WEB-INF/classes (which would be a target/testweb.war/WEB-INF/classes in the example above). This worked great in maven 1.* (I can change any file, eclipse compiles it into the class folder and MyEclipse immidiately deployes it to the JBoss). It also seemed to work for few hours in maven 2 (I only starrted using it today). Now if I do: "mvn package" I get proper exploded war except that all files in the 'classes' folder have 0 size. It seems that compiler creates good class files (and copies resources there) and then war plug-in comes along and wipes content of these files (but not files themselfs):
> Here is a snipped from my pom.xml:
> <build>
> <finalName>testweb.war</finalName>
> <outputDirectory>target/${project.build.finalName}.war/WEB-INF/classes</outputDirectory>
> <directory>target/war</directory>
> <plugins>
> <plugin>
> <groupId>org.apache.maven.plugins</groupId>
> <artifactId>maven-war-plugin</artifactId>
> <configuration>
> <webappDirectory>target/${project.build.finalName}.war</webappDirectory>
> </configuration>
> </plugin>
> </plugins>
> </build>
> As an experimet I did following steps:
> mvn compile - this produced expected results, compiled classes in the WEB-INF/classes folder
> then I did:
> mvn war:exploded - this command copied files from webapp and removed content from files produced by the compiler, so that all *.class files now have 0 bytes size...
> Interestingly enough it seemed to work for few hours and then just stoped. I have rebooted PC just to see and I still get the same result...
> my src\main\webapp\WEB-INF folder does not have classes folder, so I am not sure why war plug-in affects *.class files.
> P.S. I mistakenly created another issue for maven-war (which now I am guessing is only related to maven 1...). MPWAR-51
--
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
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org