Hi there,
After a couple of attempts I got the webdoclet working. I´ve used the xdoclet
plugin with a webdoclet task. Please see POM below:
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>xdoclet-maven-plugin</artifactId>
<version>1.0-alpha-2</version>
<executions>
<execution>
<phase>generate-sources</phase>
<goals>
<goal>xdoclet</goal>
</goals>
<configuration>
<tasks>
<webdoclet
destdir="${project.build.directory}/generated-sources/xdoclet">
<fileset dir="${basedir}/src/main/java"
includes="**/*Servlet.java"/>
<deploymentdescriptor
destdir="${project.build.directory}/generated-sources/xdoclet/META-INF"/>
</webdoclet>
</tasks>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
Note that I had to provide the 'destdir' attribute. Hope this can be default in
the future.
Regards,
Dário
-----Original Message-----
From: Dário Luís Coneglian Oliveros
Sent: terça-feira, 6 de dezembro de 2005 15:59
To: Maven Users List
Subject: RE: [m2] new ejbdoclet+webdoclet plugin announcement
Hi Ashley,
I´ve been having problem with the webdoclet plugin and can´t figure out how to
get it working.
Still not sure which plugin to use (xdoclet or webdoclet) nor its respective
repository.
Here´s a snippet of my POM:
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>xdoclet-maven-plugin</artifactId>
<version>1.0-alpha-2</version>
<executions>
<execution>
<phase>generate-sources</phase>
<goals>
<goal>xdoclet</goal>
</goals>
<configuration>
<task><![CDATA[
<webdoclet>
<fileset includes="**/*Servlet.java"/>
<deploymentdescriptor/>
</webdoclet>
]]></task>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
It seems that no action is taken when running 'mvn compile' even though it
displays that task was executed. See output below:
[INFO] [xdoclet:xdoclet {execution: default}]
[INFO] Initializing DocletTasks!!!
[INFO] Executing tasks
[INFO] Executed tasks
Then I tried to change the POM by replacing the plugins section according to
https://svn.codehaus.org/mojo/trunk/mojo/mojo-sandbox/webdoclet-maven-plugin/sample-ear-proj/trading-web/pom.xml.
No success at all. This time the webdoclet-maven-plugin couldn´t be found.
Output
------
Reason: Unable to download the artifact from any repository
org.codehaus.mojo:webdoclet-maven-plugin:1.0-beta-1:pom
------
Any tips ?
Thanks,
Dário
-----Original Message-----
From: Ashley Williams [mailto:[EMAIL PROTECTED]
Sent: sexta-feira, 25 de novembro de 2005 09:03
To: Maven Users List
Subject: Re: [m2] new ejbdoclet+webdoclet plugin announcement
Hi Marcel,
Reading between the lines I think you are asking if you need to have
an ant
installation on your machine - the answer is no, since the plugin
brings in
ant as one of its dependencies.
Some background: everybody has their own theory but mine is that
maven intends
to replace all of the functionality of the ant tasks out there - and
as a long term
goal I see no problem with that. However in the short term I see the
following problems:
1. I need stuff that works well right now and can't wait for months
and years. Even
when we do get maven replacements they won't have had the advantage
of being
extensively user tested for quite some time.
2. Everybody knows ant syntax so familiarity is a big plus for
somebody coming to maven
for the first time. I do wish that even when pure maven replacements
come along they would
retain syntax compatibility with a reasonable subset of ant.
3. With the other ant integration stuff we already have in maven we
don't have the
ability to easily map maven properties to ant attributes (correct me
if I'm wrong). For me this
seemingly small point ends up being a real killer as I personally
find it very troublesome
to supply values such as destDir="{project.output}/generated-sources/
main/java" (see I've
probably got that wrong and I'd have to look it up!!!) by hand and
keep them all synchronized.
4. I create a temporary build file because I really can't get to
grips with the slippery
ant api. Many methods are be private so I'd have to use reflection,
also seeing problems
such as running tasks individually would work but run them as part of
the same build
would fail. Glad to abandon that approach.
---
On balance I do look forward to the ant-maven integration plugins
being retired
but can't see it happening any time soon.
- Ashley
On 25 Nov 2005, at 08:11, Marcel Dullaart wrote:
> Hi Ashley,
>
> sounds good, I'll try-out the webdoclet ASAP.
> Since you create an ant script on the fly, does that mean that
> using your
> xdoclet plugin requires ant?
> Is that a good idea?
>
> Cheers,
> Marcel
> Ashley Williams <[EMAIL PROTECTED]> wrote on 25-11-2005 01:08:04:
>
>> I have placed new ejbdoclet and webdoclet plugins in the sandbox here
>> https://svn.codehaus.org/mojo/trunk/mojo/mojo-sandbox/
>>
>> And to see their use in a sample ear project try the following link:
>> https://svn.codehaus.org/mojo/trunk/mojo/mojo-sandbox/sample-ear-
>> proj/
>>
>> ---
>>
>> Briefly they provide the following features:
>>
>> 1. Familiar ant xdoclet syntax can be used in configuration
>>
>> 2. Maven properties are automatically applied to the ant task - for
>> example
>> you don't have to specify attributes such as destDir="target/
>> generated-sources",
>> because the plugin applies a list of known mappings!
>>
>> 3. Can execute plugins in the same mvn session - eg a pom.xml that
>> kicks off
>> an ejb and then web build won't bomb out.
>>
>> 4. Works by creating an actual build.xml file on the fly.
>>
>> - Ashley
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]