-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 4 posts ] 
Author Message
 Post subject: enhance-maven-plugin usage
PostPosted: Fri Dec 06, 2013 3:51 am 
Newbie

Joined: Wed Jun 08, 2011 4:14 am
Posts: 4
Hi,
I want to enhance classes by new enhance-maven-plugin released in version 4.2.8.Final.
I try it with this maven pom.xml snippet
...
Code:
<plugin>
   <groupId>org.hibernate</groupId>
   <artifactId>enhance-maven-plugin</artifactId>
   <version>4.2.8.Final</version>
   <executions>
      <execution>
         <goals>
            <goal>enhance</goal>
         </goals>
      </execution>
   </executions>
</plugin>

...
but it's not working. There is error :
Failed to parse plugin descriptor for org.hibernate:enhance-maven-plugin:4.2.8.Final (D:\.m2\repository\org\hibernate\enhance-maven-plugin\4.2.8.Final\enhance-maven-plugin-4.2.8.Final.jar): No plugin descriptor found at META-INF/maven/plugin.xml -> [Help 1]


How to correctly configure and use it?


Top
 Profile  
 
 Post subject: Re: enhance-maven-plugin usage
PostPosted: Fri Dec 06, 2013 6:58 am 
Newbie

Joined: Wed Jun 08, 2011 4:14 am
Posts: 4
I found that plugin build by gradle generate wrong pom.xml and there is not required content for plugin in META-INF.
When I build project sources by maven with corrected pom.xml, then it is usable in my project but there are build errors.

Quote:
[INFO] --- enhance-maven-plugin:4.2.8.Final:enhance (default) @ core ---
[INFO] Started enhance plugin.....
[ERROR] Unable to delete class file [Revision.class]
[ERROR] Unable to enhance class [data.Address]
org.hibernate.bytecode.enhance.EnhancementException: Unable to enhance persistent attribute [data.Address:country]
at org.hibernate.bytecode.enhance.spi.Enhancer.enhancePersistentAttribute(Enhancer.java:363)
at org.hibernate.bytecode.enhance.spi.Enhancer.enhancePersistentAttributes(Enhancer.java:342)
at org.hibernate.bytecode.enhance.spi.Enhancer.enhanceAsEntity(Enhancer.java:256)
at org.hibernate.bytecode.enhance.spi.Enhancer.enhance(Enhancer.java:242)
at org.hibernate.bytecode.enhance.spi.Enhancer.enhance(Enhancer.java:176)
at org.hibernate.bytecode.enhance.plugins.MavenEnhancePlugin.processEntityClassFile(MavenEnhancePlugin.java:145)
at org.hibernate.bytecode.enhance.plugins.MavenEnhancePlugin.processClassFile(MavenEnhancePlugin.java:132)
at org.hibernate.bytecode.enhance.plugins.MavenEnhancePlugin.execute(MavenEnhancePlugin.java:82)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:106)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:208)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:84)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:59)
at org.apache.maven.lifecycle.internal.LifecycleStarter.singleThreadedBuild(LifecycleStarter.java:183)
at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:161)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:317)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:152)
at org.apache.maven.cli.MavenCli.execute(MavenCli.java:555)
at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:214)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:158)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)
at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)
at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)
at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)
at org.codehaus.classworlds.Launcher.main(Launcher.java:46)
Caused by: javassist.NotFoundException: data.Country
at javassist.ClassPool.get(ClassPool.java:450)
at javassist.bytecode.Descriptor.toCtClass(Descriptor.java:592)
at javassist.bytecode.Descriptor.toCtClass(Descriptor.java:542)
at javassist.CtField.getType(CtField.java:371)
at org.hibernate.bytecode.enhance.spi.Enhancer.resolveAttributeTypeDescriptor(Enhancer.java:1087)
at org.hibernate.bytecode.enhance.spi.Enhancer.enhancePersistentAttribute(Enhancer.java:354)
... 29 more


So, this is my correct pom.xml :

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>org.hibernate</groupId>
  <artifactId>enhance-maven-plugin</artifactId>
  <version>4.2.8.Final</version>
  <packaging>maven-plugin</packaging>
  <name>A Hibernate O/RM Module</name>
  <description>A module of the Hibernate O/RM project</description>
  <url>http://hibernate.org</url>
  <organization>
    <name>Hibernate.org</name>
    <url>http://hibernate.org</url>
  </organization>
  <licenses>
    <license>
      <name>GNU Lesser General Public License</name>
      <url>http://www.gnu.org/licenses/lgpl-2.1.html</url>
      <distribution>repo</distribution>
      <comments>See discussion at http://hibernate.org/license for more details.</comments>
    </license>
  </licenses>
  <developers>
    <developer>
      <id>hibernate-team</id>
      <name>The Hibernate Development Team</name>
      <organization>org.apache.maven.model.Organization@7b14b3af</organization>
      <organizationUrl>http://hibernate.org</organizationUrl>
    </developer>
  </developers>
  <issueManagement>
    <system>jira</system>
    <url>http://opensource.atlassian.com/projects/hibernate/browse/HHH</url>
  </issueManagement>
  <scm>
    <connection>scm:git:http://github.com/hibernate/hibernate-core.git</connection>
    <developerConnection>scm:git:git@github.com:hibernate/hibernate-core.git</developerConnection>
    <url>http://github.com/hibernate/hibernate-core</url>
  </scm>
  <build>
     <plugins>
      <plugin>
         <groupId>org.apache.maven.plugins</groupId>
         <artifactId>maven-compiler-plugin</artifactId>
         <version>3.1</version>
         <configuration>
            <source>1.6</source>
            <target>1.6</target>
            <encoding>UTF-8</encoding>
         </configuration>
      </plugin>
        <plugin>
         <groupId>org.apache.maven.plugins</groupId>
         <artifactId>maven-plugin-plugin</artifactId>
         <version>3.2</version>
         <executions>
            <execution>
               <id>default-descriptor</id>
               <goals>
                  <goal>descriptor</goal>
               </goals>
               <phase>process-classes</phase>
            </execution>
            <execution>
               <id>help-descriptor</id>
               <goals>
                  <goal>helpmojo</goal>
               </goals>
               <phase>process-classes</phase>
            </execution>
         </executions>
        </plugin>
     </plugins>
  </build>
  <dependencies>
    <dependency>
      <groupId>org.jboss.logging</groupId>
      <artifactId>jboss-logging</artifactId>
      <version>3.1.0.GA</version>
      <scope>compile</scope>
      <exclusions>
        <exclusion>
          <artifactId>xml-apis</artifactId>
          <groupId>xml-apis</groupId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>commons-logging</groupId>
      <artifactId>commons-logging-api</artifactId>
      <version>99.0-does-not-exist</version>
      <scope>test</scope>
      <exclusions>
        <exclusion>
          <artifactId>xml-apis</artifactId>
          <groupId>xml-apis</groupId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>org.slf4j</groupId>
      <artifactId>slf4j-log4j12</artifactId>
      <version>1.6.1</version>
      <scope>test</scope>
      <exclusions>
        <exclusion>
          <artifactId>xml-apis</artifactId>
          <groupId>xml-apis</groupId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>org.apache.maven</groupId>
      <artifactId>maven-plugin-api</artifactId>
      <version>3.0.5</version>
      <scope>compile</scope>
      <exclusions>
        <exclusion>
          <artifactId>xml-apis</artifactId>
          <groupId>xml-apis</groupId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>org.slf4j</groupId>
      <artifactId>jcl-over-slf4j</artifactId>
      <version>1.6.1</version>
      <scope>test</scope>
      <exclusions>
        <exclusion>
          <artifactId>xml-apis</artifactId>
          <groupId>xml-apis</groupId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>org.jboss.byteman</groupId>
      <artifactId>byteman-install</artifactId>
      <version>2.1.2</version>
      <scope>test</scope>
      <exclusions>
        <exclusion>
          <artifactId>xml-apis</artifactId>
          <groupId>xml-apis</groupId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>org.jboss.byteman</groupId>
      <artifactId>byteman</artifactId>
      <version>2.1.2</version>
      <scope>test</scope>
      <exclusions>
        <exclusion>
          <artifactId>xml-apis</artifactId>
          <groupId>xml-apis</groupId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>org.hibernate</groupId>
      <artifactId>hibernate-core</artifactId>
      <version>4.2.8.Final</version>
      <scope>compile</scope>
      <exclusions>
        <exclusion>
          <artifactId>xml-apis</artifactId>
          <groupId>xml-apis</groupId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>org.jboss.byteman</groupId>
      <artifactId>byteman-bmunit</artifactId>
      <version>2.1.2</version>
      <scope>test</scope>
      <exclusions>
        <exclusion>
          <artifactId>xml-apis</artifactId>
          <groupId>xml-apis</groupId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>org.javassist</groupId>
      <artifactId>javassist</artifactId>
      <version>3.18.1-GA</version>
      <scope>compile</scope>
      <exclusions>
        <exclusion>
          <artifactId>xml-apis</artifactId>
          <groupId>xml-apis</groupId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>org.slf4j</groupId>
      <artifactId>slf4j-api</artifactId>
      <version>1.6.1</version>
      <scope>test</scope>
      <exclusions>
        <exclusion>
          <artifactId>xml-apis</artifactId>
          <groupId>xml-apis</groupId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>org.apache.maven.plugin-tools</groupId>
      <artifactId>maven-plugin-annotations</artifactId>
      <version>3.2</version>
      <scope>provided</scope>
      <exclusions>
        <exclusion>
          <artifactId>xml-apis</artifactId>
          <groupId>xml-apis</groupId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>org.hibernate.javax.persistence</groupId>
      <artifactId>hibernate-jpa-2.0-api</artifactId>
      <version>1.0.1.Final</version>
      <scope>compile</scope>
      <exclusions>
        <exclusion>
          <artifactId>xml-apis</artifactId>
          <groupId>xml-apis</groupId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>commons-logging</groupId>
      <artifactId>commons-logging</artifactId>
      <version>99.0-does-not-exist</version>
      <scope>test</scope>
      <exclusions>
        <exclusion>
          <artifactId>xml-apis</artifactId>
          <groupId>xml-apis</groupId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>junit</groupId>
      <artifactId>junit</artifactId>
      <version>4.10</version>
      <scope>test</scope>
      <exclusions>
        <exclusion>
          <artifactId>xml-apis</artifactId>
          <groupId>xml-apis</groupId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>com.h2database</groupId>
      <artifactId>h2</artifactId>
      <version>1.2.145</version>
      <scope>test</scope>
      <exclusions>
        <exclusion>
          <artifactId>xml-apis</artifactId>
          <groupId>xml-apis</groupId>
        </exclusion>
      </exclusions>
    </dependency>
  </dependencies>
</project>


Plugin usage :
Code:
<plugin>
   <groupId>org.hibernate</groupId>
   <artifactId>enhance-maven-plugin</artifactId>
   <version>4.2.8.Final</version>
   <executions>
      <execution>
         <phase>process-classes</phase>
         <goals>
            <goal>enhance</goal>
         </goals>
      </execution>
   </executions>
</plugin>


Top
 Profile  
 
 Post subject: Re: enhance-maven-plugin usage
PostPosted: Tue Dec 10, 2013 12:00 pm 
Contributor
Contributor

Joined: Fri Apr 03, 2009 11:07 am
Posts: 11
You'll need to hook the plugin in with the compile phase.

<plugin>
<groupId>org.hibernate</groupId>
<artifactId>enhance-maven-plugin</artifactId>
<version>4.2.8.Final</version>
<executions>
<execution>
<phase>compile</phase>
<goals>
<goal>enhance</goal>
</goals>
</execution>
</executions>
</plugin>


Top
 Profile  
 
 Post subject: Re: enhance-maven-plugin usage
PostPosted: Thu Dec 12, 2013 6:06 am 
Newbie

Joined: Wed Jun 08, 2011 4:14 am
Posts: 4
Hi Jeremy,
problem is not in phase.
When I use EnhancementTask by maven-antrun-plugin on compile phase, code is enhanced with warnings.

Quote:
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-antrun-plugin</artifactId>
<version>1.7</version>
<executions>
<execution>
<id>Enhance domain classes</id>
<configuration>
<target>
<taskdef name="enhance"
classname="org.hibernate.tool.enhance.EnhancementTask">
<classpath>
<path refid="maven.compile.classpath" />
<path refid="maven.plugin.classpath" />
</classpath>
</taskdef>
<enhance>
<fileset dir="${project.build.outputDirectory}">
<include name="entity/*.class" />
</fileset>
</enhance>
</target>
</configuration>
<phase>compile</phase>
<goals>
<goal>run</goal>
</goals>
</execution>
</executions>
</plugin>


Quote:
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Hibernate Enhance by Maven Plugin Test 1.0.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[WARNING] The artifact junit:junit-dep:jar:4.11 has been relocated to junit:junit:jar:4.11
[INFO]
[INFO] --- maven-clean-plugin:2.5:clean (default-clean) @ test-enhance-maven-plugin ---
[INFO] Deleting D:\Vlado\Development\Workspace\test-enhance-maven-plugin\target
[INFO]
[INFO] --- aspectj-maven-plugin:1.5:compile (default) @ test-enhance-maven-plugin ---
[WARNING] advice defined in org.springframework.scheduling.aspectj.AbstractAsyncExecutionAspect has not been applied [Xlint:adviceDidNotMatch]
[WARNING] advice defined in org.springframework.mock.staticmock.AnnotationDrivenStaticEntityMockingControl has not been applied [Xlint:adviceDidNotMatch]
[WARNING] advice defined in org.springframework.mock.staticmock.AbstractMethodMockingControl has not been applied [Xlint:adviceDidNotMatch]
[WARNING] advice defined in org.springframework.mock.staticmock.AbstractMethodMockingControl has not been applied [Xlint:adviceDidNotMatch]
[INFO]
[INFO] --- aspectj-maven-plugin:1.5:test-compile (default) @ test-enhance-maven-plugin ---
[WARNING] advice defined in org.springframework.orm.jpa.aspectj.JpaExceptionTranslatorAspect has not been applied [Xlint:adviceDidNotMatch]
[WARNING] advice defined in org.springframework.scheduling.aspectj.AbstractAsyncExecutionAspect has not been applied [Xlint:adviceDidNotMatch]
[WARNING] advice defined in org.springframework.mock.staticmock.AnnotationDrivenStaticEntityMockingControl has not been applied [Xlint:adviceDidNotMatch]
[WARNING] advice defined in org.springframework.mock.staticmock.AbstractMethodMockingControl has not been applied [Xlint:adviceDidNotMatch]
[WARNING] advice defined in org.springframework.mock.staticmock.AbstractMethodMockingControl has not been applied [Xlint:adviceDidNotMatch]
[INFO]
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) @ test-enhance-maven-plugin ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 5 resources
[INFO]
[INFO] --- maven-compiler-plugin:3.1:compile (default-compile) @ test-enhance-maven-plugin ---
[INFO] Nothing to compile - all classes are up to date
[INFO]
[INFO] --- maven-antrun-plugin:1.7:run (Enhance domain classes) @ test-enhance-maven-plugin ---
[INFO] Executing tasks

main:
[enhance] Starting Hibernate EnhancementTask execution
[enhance] Unable to delete class file [Child.class]
[enhance] Unable to delete class file [Parent.class]
[INFO] Executed tasks
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 3.652s
[INFO] Finished at: Thu Dec 12 10:51:44 CET 2013
[INFO] Final Memory: 17M/222M
[INFO] ------------------------------------------------------------------------


When I use enhance-maven-plugin there are build errors.

Quote:
<plugin>
<groupId>org.hibernate</groupId>
<artifactId>enhance-maven-plugin</artifactId>
<version>${hibernate.version}</version>
<executions>
<execution>
<phase>compile</phase>
<goals>
<goal>enhance</goal>
</goals>
</execution>
</executions>
</plugin>


Quote:
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Hibernate Enhance by Maven Plugin Test 1.0.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[WARNING] The artifact junit:junit-dep:jar:4.11 has been relocated to junit:junit:jar:4.11
[INFO]
[INFO] --- maven-clean-plugin:2.5:clean (default-clean) @ test-enhance-maven-plugin ---
[INFO] Deleting D:\Vlado\Development\Workspace\test-enhance-maven-plugin\target
[INFO]
[INFO] --- aspectj-maven-plugin:1.5:compile (default) @ test-enhance-maven-plugin ---
[WARNING] advice defined in org.springframework.scheduling.aspectj.AbstractAsyncExecutionAspect has not been applied [Xlint:adviceDidNotMatch]
[WARNING] advice defined in org.springframework.mock.staticmock.AnnotationDrivenStaticEntityMockingControl has not been applied [Xlint:adviceDidNotMatch]
[WARNING] advice defined in org.springframework.mock.staticmock.AbstractMethodMockingControl has not been applied [Xlint:adviceDidNotMatch]
[WARNING] advice defined in org.springframework.mock.staticmock.AbstractMethodMockingControl has not been applied [Xlint:adviceDidNotMatch]
[INFO]
[INFO] --- aspectj-maven-plugin:1.5:test-compile (default) @ test-enhance-maven-plugin ---
[WARNING] advice defined in org.springframework.orm.jpa.aspectj.JpaExceptionTranslatorAspect has not been applied [Xlint:adviceDidNotMatch]
[WARNING] advice defined in org.springframework.scheduling.aspectj.AbstractAsyncExecutionAspect has not been applied [Xlint:adviceDidNotMatch]
[WARNING] advice defined in org.springframework.mock.staticmock.AnnotationDrivenStaticEntityMockingControl has not been applied [Xlint:adviceDidNotMatch]
[WARNING] advice defined in org.springframework.mock.staticmock.AbstractMethodMockingControl has not been applied [Xlint:adviceDidNotMatch]
[WARNING] advice defined in org.springframework.mock.staticmock.AbstractMethodMockingControl has not been applied [Xlint:adviceDidNotMatch]
[INFO]
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) @ test-enhance-maven-plugin ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 5 resources
[INFO]
[INFO] --- maven-compiler-plugin:3.1:compile (default-compile) @ test-enhance-maven-plugin ---
[INFO] Nothing to compile - all classes are up to date
[INFO]
[INFO] --- enhance-maven-plugin:4.2.8.Final:enhance (default) @ test-enhance-maven-plugin ---
[INFO] Started enhance plugin.....
[ERROR] Unable to enhance class [entity.Child]
org.hibernate.bytecode.enhance.EnhancementException: Unable to enhance persistent attribute [entity.Child:parent]
at org.hibernate.bytecode.enhance.spi.Enhancer.enhancePersistentAttribute(Enhancer.java:363)
at org.hibernate.bytecode.enhance.spi.Enhancer.enhancePersistentAttributes(Enhancer.java:342)
at org.hibernate.bytecode.enhance.spi.Enhancer.enhanceAsEntity(Enhancer.java:256)
at org.hibernate.bytecode.enhance.spi.Enhancer.enhance(Enhancer.java:242)
at org.hibernate.bytecode.enhance.spi.Enhancer.enhance(Enhancer.java:176)
at org.hibernate.bytecode.enhance.plugins.MavenEnhancePlugin.processEntityClassFile(MavenEnhancePlugin.java:145)
at org.hibernate.bytecode.enhance.plugins.MavenEnhancePlugin.processClassFile(MavenEnhancePlugin.java:132)
at org.hibernate.bytecode.enhance.plugins.MavenEnhancePlugin.execute(MavenEnhancePlugin.java:82)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:106)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:208)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:84)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:59)
at org.apache.maven.lifecycle.internal.LifecycleStarter.singleThreadedBuild(LifecycleStarter.java:183)
at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:161)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:317)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:152)
at org.apache.maven.cli.MavenCli.execute(MavenCli.java:555)
at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:214)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:158)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)
at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)
at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)
at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)
at org.codehaus.classworlds.Launcher.main(Launcher.java:46)
Caused by: javassist.NotFoundException: entity.Parent
at javassist.ClassPool.get(ClassPool.java:450)
at javassist.bytecode.Descriptor.toCtClass(Descriptor.java:592)
at javassist.bytecode.Descriptor.toCtClass(Descriptor.java:542)
at javassist.CtField.getType(CtField.java:371)
at org.hibernate.bytecode.enhance.spi.Enhancer.resolveAttributeTypeDescriptor(Enhancer.java:1087)
at org.hibernate.bytecode.enhance.spi.Enhancer.enhancePersistentAttribute(Enhancer.java:354)
... 29 more
[ERROR] Unable to delete class file [Parent.class]
[INFO] Enhance plugin completed.
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 3.346s
[INFO] Finished at: Thu Dec 12 10:48:52 CET 2013
[INFO] Final Memory: 22M/217M
[INFO] ------------------------------------------------------------------------


I donĀ“t know how to attach the test project, so I can send you it by mail, if you want.
In output there you can see, that there is aspectj plugin used for compile time weaving, but without it, it is the same result.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 4 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.