File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Ant, Maven and Other Build Tools and the fly likes Maven and Hibernate plugin configuration Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Engineering » Ant, Maven and Other Build Tools
Bookmark "Maven and Hibernate plugin configuration" Watch "Maven and Hibernate plugin configuration" New topic
Author

Maven and Hibernate plugin configuration

Juan Luis Prieto
Greenhorn

Joined: Sep 25, 2009
Posts: 15
Hi,

I am having an estrange behavior when configuring in a pom file a hibernate plugin and the execution goals. I am having this estrange error:


The pom file is the following and the errors appear where I marked in comments:




Can anyone give me a hint of what the error can be?

Thank you in advance.
Peter Johnson
author
Bartender

Joined: May 14, 2008
Posts: 5772
    
    7

Looking at the documentation for the hibernate3-maven-plugin:hbm2cfgxml goal, I see this:

Invokes the execution of the lifecycle phase generate-resources prior to executing itself.


I think that setting hbm2cfgxml to run at the generate-resources causes a possible infinite loop and perhaps that is what Maven is complaining about.

I see in the docs that the hbm2java goal runs during the generate-sources phase by default. Try removing the phases from the goals that have default phases.

Try using different execution ids, perhaps those are causing a conflict with the default ids.

Also, try running with the -X option. At the start of the output there will be a build plan report that identifies all of the plugin goals that will run and what their settings are, perhaps that might give a clue.

Finally, which version of Maven are you running?


JBoss In Action
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Maven and Hibernate plugin configuration
 
Similar Threads
how do i send a email test report from maven
Google Web Toolkit (GWT): Practice
Tomcat and Axis2
Build problem with maven and eclipse web project
Strange problem - works on maven glassfish but not on Tomcat