[aspectwerkz-user] Reg Post Compilation in AW2.0

"Shankaranarayanan G" <[email protected]>
Newsgroups gmane.comp.java.aspectwerkz.user
Message-ID <[email protected]>
Hi,

Is the option -genjp really an optional option . I think it should be made mandatory and the docs needs to be updated accordingly. I tried to post compile my jar files without -genjp,but then i got an error while deploying it. The error was 

java.lang.NoClassDefFoundError: bonus/controller/CustomerBonusTxSL_2__86728660__1714847616__975670146___AW_JoinPoint
        at bonus.controller.CustomerBonusTxSL.<clinit>(CustomerBonusTxSL.java)
        at java.lang.Class.forName0(Native Method)
        at java.lang.Class.forName(Class.java:115)
        at de.dl.ucs.bonus.controller.CustomerBonusTxSL_4goog2_HomeImpl.class$(CustomerBonusTxSL_4goog2_HomeIm

Which mean that it is mandatory for me to use the -genjp option when i do a post-compilation.


Then i tried to post compile my jar file with the -genjp option. I get the following error for some of the jar files.

 [compilejar] D:\CodingStd\jar\bonus-dao.jar
 [compilejar] compile bonus-dao.jar:bonus/dao/CustomerBonusDAO.class
 [compilejar] (genjp) bonus-dao.jar:bonus/dao/CustomerBonusDAO_2_1825420569_2041913682_1331990241___AW_JoinPoint
 [compilejar] (genjp) bonus-dao.jar:bonus/dao/CustomerBonusDAO_2_1825420569__287237707_1331990241___AW_JoinPoint
 [compilejar] (genjp) bonus-dao.jar:bonus/dao/CustomerBonusDAO_2_1825420569_2041913682_1331990241___AW_JoinPoint
 [aspectwerkzc] compilation encountered an error
org.codehaus.aspectwerkz.compiler.CompileException: compile D:\CodingStd\jar\bonus-dao.jar failed
        at org.codehaus.aspectwerkz.compiler.AspectWerkzC.compileJar(AspectWerkzC.java:530)
        at org.codehaus.aspectwerkz.compiler.AspectWerkzC.doCompile(AspectWerkzC.java:295)
        at org.codehaus.aspectwerkz.compiler.AspectWerkzC.compile(AspectWerkzC.java:554)
        at org.codehaus.aspectwerkz.compiler.AspectWerkzC.compile(AspectWerkzC.java:686)
        at org.codehaus.aspectwerkz.compiler.AspectWerkzC.main(AspectWerkzC.java:721)
nested:
java.util.zip.ZipException: duplicate entry: bonus/dao/CustomerBonusDAO_2_1825420569_2041913682_1331990241___AW_JoinPoint.class
        at java.util.zip.ZipOutputStream.putNextEntry(ZipOutputStream.java:160)
        at org.codehaus.aspectwerkz.compiler.AspectWerkzC.compileJar(AspectWerkzC.java:492)
        at org.codehaus.aspectwerkz.compiler.AspectWerkzC.doCompile(AspectWerkzC.java:295)
        at org.codehaus.aspectwerkz.compiler.AspectWerkzC.compile(AspectWerkzC.java:554)
        at org.codehaus.aspectwerkz.compiler.AspectWerkzC.compile(AspectWerkzC.java:686)
        at org.codehaus.aspectwerkz.compiler.AspectWerkzC.main(AspectWerkzC.java:721)
   [backup] Copying 1 file to D:\CodingStd\jar
 [backup] removing backup
   [delete] Deleting 2 files from D:\AOP1\bin\_aspectwerkzc
   [delete] Deleted 1 directory from D:\AOP1\bin\_aspectwerkzc
( 1 s )
FAILED : D:\CodingStd\jar\bonus-dao.jar

I could see that two classes with the same name are being pushed into the jar file, but then why ? is there anyway that i could avoid this exception. Getting pretty desperate with this.

Thanks in advance
Shankar
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.