maven-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Pascal Thivent <pascal.thiv...@gmail.com>
Subject Re: [OT] Re: XDoclet in Maven
Date Sat, 13 Nov 2004 22:18:36 GMT
Actually, the maven xdoclet plugin has all xdoclet required
dependencies in its project.xml so I don't have to manage them
anymore.

Thus, I would recommand more than ever to use the maven-xdoclet-plugin
rather than xdoclet ant tasks directly (for the same reason as
mentionned in a previous mail : maintainability).

On Sat, 13 Nov 2004 20:47:38 -0100, Pascal Thivent
<pascal.thivent@gmail.com> wrote:
> Hi,
> 
> I've upgraded my maven-xdoclet-plugin and my various xdoclet modules
> dependencies to version 1.2.2. EJBs classes and hibernate mappings
> generation works fine.
> 
> Thanks.
> 
> 
> 
> On Sat, 13 Nov 2004 12:47:53 -0000, Eric Pugh <epugh@upstate.com> wrote:
> > Have you tried with the latest and greatest of xdoclet?  1.2.2 was released,
> > and had many improvements and cleanups applied to the Maven plugin.
> >
> >
> >
> > > -----Original Message-----
> > > From: Pascal Thivent [mailto:pascal.thivent@gmail.com]
> > > Sent: Saturday, November 13, 2004 6:32 AM
> > > To: Maven Users List
> > > Subject: Re: XDoclet in Maven
> > >
> > >
> > > Hi,
> > >
> > > in deed, you made a lot of progress since the first mail. Lets try to
> > > tackle all pending issues.
> > >
> > > I'm not using the EjbDocletTask directly but use rather the maven
> > > xdoclet goal. So I have this in my maven.xml :
> > >
> > >     <preGoal name="java:compile">
> > >         <echo>Generates EJB classes and descriptor files</echo>
> > >         <attainGoal name="xdoclet:ejbdoclet"/>
> > >     </preGoal>
> > >
> > > And the following dependency in my project.xml (it's enough for what
> > > i'm doing for now) :
> > >
> > >     <dependency>
> > >       <groupId>xdoclet</groupId>
> > >       <artifactId>xdoclet-ejb-module</artifactId>
> > >       <version>1.2.1</version>
> > >       <type>jar</type>
> > >       <properties>
> > >         <eclipse.dependency>false</eclipse.dependency>
> > >       </properties>
> > >     </dependency>
> > >
> > > And this *works fine* (other potentially required libraries such as
> > > commons-collections, commons-logging, log4j are not mentionned here).
> > >
> > > Anyway, it's also possible to use directly an ant task from maven, as
> > > you are trying to do. I've tried to reproduce you configuration and
> > > replaced the content of my pregoal with :
> > >
> > >     <preGoal name="java:compile">
> > >       <taskdef
> > >        name="ejbdoclet"
> > >        classname="xdoclet.modules.ejb.EjbDocletTask"
> > >        classpathref="maven.dependency.classpath" />
> > >     </preGoal>
> > >
> > > This won't do anything more than adding a task definition to the
> > > current project, you still need to call it then (see for example :
> > > http://tinyurl.com/4xfw7 or xdoclet web site) but it is enough to fix
> > > potential classpath issues.
> > >
> > > When running maven with the dependencies mentionned above, I get the
> > > following trace :
> > >
> > > BUILD FAILED
> > > File...... E:\myprojects\cauldron\modules\biz\maven.xml
> > > Element... taskdef
> > > Line...... 24
> > > Column.... 50
> > > taskdef class xdoclet.modules.ejb.EjbDocletTask cannot be found
> > > Total time: 12 seconds
> > > Finished at: Sat Nov 13 06:53:01 CET 2004
> > >
> > > This is surprising as everything was working fine with the
> > > xdoclet:ejbdoclet goal. I'm for sure missing now some dependencies
> > > that the maven-xdoclet-plugin has. When running maven with the -X
> > > option, I get the  :
> > >
> > > BUILD FAILED
> > > File...... E:\myprojects\cauldron\modules\biz\maven.xml
> > > Element... taskdef
> > > Line...... 24
> > > Column.... 50
> > > taskdef class xdoclet.modules.ejb.EjbDocletTask cannot be found
> > > com.werken.werkz.UnattainableGoalException: Unable to obtain goal
> > > [cauldron:dist
> > > ] -- E:\myprojects\cauldron\modules\biz\maven.xml:24:50:
> > > <taskdef> taskdef class
> > >  xdoclet.modules.ejb.EjbDocletTask cannot be found
> > >
> > > [...]
> > >
> > > --- Nested Exception ---
> > > java.lang.NoClassDefFoundError: xdoclet/DocletTask
> > >
> > > [...]
> > >
> > > No possible doubts, I'm missing some dependencies. Let's try it again
> > > with the following set (after a first try with just xdoclet added, I
> > > saw that xjavadoc was required too) :
> > >
> > >     <dependency>
> > >       <groupId>xdoclet</groupId>
> > >       <artifactId>xdoclet-ejb-module</artifactId>
> > >       <version>1.2.1</version>
> > >       <type>jar</type>
> > >     </dependency>
> > >     <dependency>
> > >       <groupId>xdoclet</groupId>
> > >       <artifactId>xdoclet</artifactId>
> > >       <version>1.2.1</version>
> > >     </dependency>
> > >     <dependency>
> > >       <groupId>xdoclet</groupId>
> > >       <artifactId>xjavadoc</artifactId>
> > >       <version>1.0.3</version>
> > >     </dependency>
> > >
> > > Ok, this time, the EjbDocletTask has been properly loaded, everyting
> > > is fine. Would just have to do some stuff with it now :)
> > >
> > > You should be able to get it wotking too now.
> > >
> > > I don't know if you have any preferences but I suggest to use the
> > > maven-xdoclet-plugin and the xdoclet:ejbdoclet goal directly. The
> > > maven-xodlet-plugin team is already adding the EjbDocletTask
> > > definition so I prefer to not duplicate (and maintain !) this code in
> > > my scripts.
> > >
> > > On Fri, 12 Nov 2004 17:22:17 -0800 (PST), Janos Mucsi
> > > <mucsij@yahoo.com> wrote:
> > > >
> > > > To rephrase my previous question, if the
> > > > ${pom.dependencyClasspath} contains
> > > > xdoclet-ejb-module-1.2.jar which contains
> > > > xdoclet.modules.ejb.EjbDocletTask, then why do I get
> > > > this if my taskdef is like this:
> > > >
> > > > ===================================================
> > > >
> > > >
> > > > <ant:taskdef name="ejbdoclet"
> > > > classname="xdoclet.modules.ejb.EjbDocletTask">
> > > >             <ant:classpath>
> > > >                                 <ant:pathelement
> > > > path="${pom.dependencyClasspath}"/>
> > > >                 <ant:path
> > > > refid="maven.dependency.classpath"/>
> > > >             </ant:classpath>
> > > >         </ant:taskdef>
> > > > =====================================
> > > >
> > > >
> > > > C:\temp\eclipse\PlutoApp\modules\everest-module-registration>maven
> > > > ejb:install
> > > >  __  __
> > > > |  \/  |__ _Apache__ ___
> > > > | |\/| / _` \ V / -_) ' \  ~ intelligent projects ~
> > > > |_|  |_\__,_|\_/\___|_||_|  v. 1.0.1
> > > >
> > > > build:start:
> > > >
> > > > ejb:init:
> > > > java:prepare-filesystem:
> > > >
> > > > java:compile:
> > > >     [echo] java:compile ${pom.dependencyClasspath}=
> > > > C:\Documents and Settings\jm
> > > >
> > > ucsi/.maven/repository\opcert\jars\everest-module-bedrock-1.0.jar;
> > > C:\Documents
> > > > a
> > > > nd
> > > > Settings\jmucsi/.maven/repository\j2ee\jars\j2ee-1.3.1.jar;C:\Documents
> > > > and S
> > > >
> > > ettings\jmucsi/.maven/repository\commons-collections\jars\commons-
> > > collections-3.
> > > > 1.jar;C:\ccviews\USOpCert\source\complib\log4j-1.2.8.jar;C:\Documents
> > > > and Settin
> > > > gs\jmucsi/.maven/repository\xdoclet\jars\xdoclet-1.2.jar;C:\Documents
> > > > and Settin
> > > >
> > > gs\jmucsi/.maven/repository\xdoclet\jars\xdoclet-xdoclet-module-1.
> > > 2.jar;C:\Docum
> > > > ents and
> > > > Settings\jmucsi/.maven/repository\xdoclet\jars\xdoclet-ejb-module-1.2.j
> > > > ar;C:\Documents and
> > > > Settings\jmucsi/.maven/repository\xdoclet\jars\xdoclet-hiber
> > > > nate-module-1.2.jar;C:\Documents and
> > > > Settings\jmucsi/.maven/repository\xdoclet\j
> > > > ars\xdoclet-jboss-module-1.2.jar;
> > > >
> > > >
> > > >
> > > > BUILD FAILED
> > > > File......
> > > > C:\temp\eclipse\PlutoApp\modules\everest-module-registration\maven.xm
> > > > l
> > > > Element... ant:taskdef
> > > > Line...... 9
> > > > Column.... 84
> > > > taskdef class xdoclet.modules.ejb.EjbDocletTask cannot
> > > > be found
> > > >
> > > > __________________________________
> > > > Do you Yahoo!?
> > > > Check out the new Yahoo! Front Page.
> > > > www.yahoo.com
> > > >
> > > > ---------------------------------------------------------------------
> > > > To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> > > > For additional commands, e-mail: users-help@maven.apache.org
> > > >
> > > >
> > >
> > >
> > > --
> > > Pascal
> > >
> > > ---------------------------------------------------------------------
> >
> >
> > > To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> > > For additional commands, e-mail: users-help@maven.apache.org
> >
> >
> 
> --
> Pascal
> 


-- 
Pascal

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Mime
View raw message