On Fri, 14 Apr 2006, Allison, Bob wrote: Hi,
> Another possibility is if the EJB classes do not extend the proper class. In > the example you sent, "SIOLManagerSessionBean extends XMLAwareBaseSession"; > does XMLAwareBaseSession extend javax.ejb.SessionBean? You might try > replacing XMLAwareBaseSession with javax.ejb.SessionBean to see if XDoclet > picks up the file for processing. > > Also, you DO NOT need to do anything to have the generated source directory > added to the compile source roots. Yes you do. The default location is target/generated-sources/xdoclet/, so you either have to: 1) make sure destDir points to that location, or 2) add a <generatedsourcesDirectory> tag to the configuration to specify the real location. -- Kenney > > -----Original Message----- > From: Kostis Anagnostopoulos [mailto:[EMAIL PROTECTED] > Sent: Friday, April 14, 2006 06:49 > To: [email protected] > Subject: Re: [mojo-dev] Kostis Anagnostopoulos to dev Mane2 xdoclet plugin > does nothing > > > Thank you Kenney for your interest. > > On 4/14/06, Kenney Westerhof <[EMAIL PROTECTED]> wrote: > > On Fri, 14 Apr 2006, Kostis Anagnostopoulos wrote: > > > > Hi, > > > > This may sound stupid, but do you have any *Bean.java files > > in src/main/java/ ? You sure they're not in src/java/ ? > > Yes, i have. Here is a piece of the ejb class sources: > > ~/work/eclipse/maven2/siol_manager/subproject_ejb $ cat > src/main/java/gr/forthnet/siol/ejb/session/SIOLManagerSessionBean.java: > package gr.forthnet.siol.ejb.session; > > import gr.forthnet.enterprise.framework.ejb.client.registry.RegistryException; > ....... > import org.slf4j.LoggerFactory; > > /** > * @ejb.bean > * name="FORTHnetSIOLManager" > * display-name = "FORTHnet SIOL Manager" > * description = "Provides methods that manage LDAP's In/Out lists > for RADEON concerning FORTHnet Services." > * view-type = "both" > * jndi-name = "gr.forthnet.siol.session.remote.siol_manager" > * local-jndi-name = "gr.forthnet.siol.session.local.siol_manager" > * transaction-type = "Container" > * type = "Stateless" > * > * @ejb.home > * extends = "javax.ejb.EJBHome" > * local-extends = "javax.ejb.EJBLocalHome" > * > * @ejb.interface > * extends = "javax.ejb.EJBObject" > * local-extends = "javax.ejb.EJBLocalObject" > * > * @ejb.util > * generate = "physical" > * > * @ejb.transaction > * type = "NotSupported" > * > * @weblogic.transaction-descriptor > * trans-timeout-seconds = "600" > * > * @weblogic.pool > * max-beans-in-free-pool="5" > * initial-beans-in-free-pool="1" > * > * > * @weblogic.enable-call-by-reference True > * @author <a href="mailto:[EMAIL PROTECTED]">Anagnostopoulos Kostis</a> > * @version $Id: SIOLManagerSessionBean.java,v 1.2.2.2 2006/04/06 > 09:03:39 kana Exp $ > */ > public class SIOLManagerSessionBean extends XMLAwareBaseSession > implements ErrorManagedEJB { > > > Is there something wrong with thes tags ? > Are they not recognized or deprecated ? > > > > > The verbose="true" is correct, btw., to get debug output for XDoclet. > > Running Maven2 with -X will show a lot more output. > > The output includes only the ejbdoclet plugin. I should have posted > the debug output in the first place: > > ..... > [DEBUG] xdoclet:xdoclet-macromedia-module:jar:1.2.3:runtime > (selected for runtime) > [DEBUG] Configuring mojo > 'org.codehaus.mojo:xdoclet-maven-plugin:1.0-alpha-2:xdoclet' --> > [DEBUG] (f) classRealm = [EMAIL PROTECTED] > [DEBUG] (f) generatedSourcesDirectory = > /home/kana/work/eclipse/maven2/siol_manager/subproject_ejb/target/generated-sources/xdoclet > [DEBUG] (f) project = [EMAIL PROTECTED] > [DEBUG] (f) sourceDirectory = > /home/kana/work/eclipse/maven2/siol_manager/subproject_ejb/src/main/java > [DEBUG] (f) tasks = > [DEBUG] -- end configuration -- > [INFO] [xdoclet:xdoclet {execution: default}] > [INFO] Initializing DocletTasks!!! > [INFO] Executing tasks > [DEBUG] getProperty(ns=null, name=ant.reuse.loader, user=false) > 14 Απρ 2006 1:34:50 μμ xdoclet.XDocletMain start > INFO: Running <homeinterface/> > 14 Απρ 2006 1:34:50 μμ xdoclet.XDocletMain start > INFO: Running <localinterface/> > 14 Απρ 2006 1:34:50 μμ xdoclet.XDocletMain start > INFO: Running <localhomeinterface/> > 14 Απρ 2006 1:34:50 μμ xdoclet.XDocletMain start > INFO: Running <remoteinterface/> > 14 Απρ 2006 1:34:50 μμ xdoclet.XDocletMain start > INFO: Running <deploymentdescriptor/> > 14 Απρ 2006 1:34:50 μμ xdoclet.XDocletMain start > INFO: Running <weblogic/> > [INFO] Executed tasks > [DEBUG] > org.apache.maven.plugins:maven-resources-plugin:maven-plugin:2.1:runtime > (selected for runtime) > ..... > > > > > > > > > Next, did you check target/src-ejb-gen? Maybe you need to add > > an <mkdir dir="${.....}/src-ejb-gen"/> right before the ejbdoclet task. > > Yeap, nothing yet. > > > > > > > Btw, the naming suggests you are generating sources. If so, > > you need to add a <sourceRoot> under <configuration> with that directory > > so Maven2 knows where the generated sources are - otherwise they won't be > > compiled. > > But that comes AFTERWARDS the source generation. When i get there i > will try it, > but mind you that > 1. the usage doc does not says so, and > 2. the sources of the 'execute' method of the xdoclet plugin > include the following code: > try > { > System.setProperty( XDOCLET_CP, createClasspath() ); > > initializeDocletMappings(); > > executeTasks( tasks, project ); > > project.addCompileSourceRoot( > generatedSourcesDirectory ); //HERE IT IS > } > catch (Moj..... > > > > > > > The output you get indicates that XDoclet has no sources to process. > > This means that the <fileset> you provided does not contain any files. > > > > Try this: > > > > <fileset dir="${basedir}/src/main/java" includes="**/*.java"/> > > > > Hope some of this helps you.. > > > > -- Kenney > > > > > On 4/14/06, Marcel May <[EMAIL PROTECTED]> wrote: > > > > Kostis Anagnostopoulos wrote: > > > > > Hi to all, > > > > > > > > > > i desperately need help, since i have 2 days working on it and > > > > > nothing yet. > > > > > > > > > > I want to use xdoclet with maven2 (2.0.2 and 2.0.4). > > > > > > > > > > Maven prints info messages when executing the sub-tasks but nothing > > > > > else gets generated: > > > > > ..... > > > > > [INFO] --------------------------------------------------------- make > > > > > ------------------- > > > > > [INFO] Building SIOL EJB > > > > > [INFO] task-segment: [package] > > > > > [INFO] > > > > > ---------------------------------------------------------------------------- > > > > > [INFO] [xdoclet:xdoclet {execution: default}] > > > > > [INFO] Initializing DocletTasks!!! > > > > > [INFO] Executing tasks > > > > > 13 Απρ 2006 7:44:13 μμ xdoclet.XDocletMain start > > > > > INFO: Running <homeinterface/> > > > > > 13 Απρ 2006 7:44:14 μμ xdoclet.XDocletMain start > > > > > INFO: Running <localinterface/> > > > > > 13 Απρ 2006 7:44:14 μμ xdoclet.XDocletMain start > > > > > INFO: Running <localhomeinterface/> > > > > > 13 Απρ 2006 7:44:14 μμ xdoclet.XDocletMain start > > > > > INFO: Running <remoteinterface/> > > > > > 13 Απρ 2006 7:44:14 μμ xdoclet.XDocletMain start > > > > > INFO: Running <deploymentdescriptor/> > > > > > 13 Απρ 2006 7:44:15 μμ xdoclet.XDocletMain start > > > > > INFO: Running <weblogic/> > > > > > [INFO] Executed tasks > > > > > ..... > > > > > > > > > > This is my pom.xml (it is a multiple module project): > > > > > <?xml version="1.0"?> > > > > > <project xmlns="http://maven.apache.org/POM/4.0.0" > > > > > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" > > > > > xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 > > > > > http://maven.apache.org/maven-v4_0_0.xsd"> > > > > > <parent> > > > > > <groupId>gr.forthnet.siol</groupId> > > > > > <artifactId>siol</artifactId> > > > > > <version>1.0</version> > > > > > </parent> > > > > > <modelVersion>4.0.0</modelVersion> > > > > > > > > > > <groupId>gr.forthnet.siol</groupId> > > > > > <artifactId>siol_ejb</artifactId> > > > > > <packaging>ejb</packaging> > > > > > <name>SIOL EJB</name> > > > > > <version>1.0</version> > > > > > > > > > > <build> > > > > > <defaultGoal>install</defaultGoal> > > > > > > > > > > <plugins> > > > > > <plugin> > > > > > > > > > > <groupId>org.apache.maven.plugins</groupId> > > > > > > > > > > <artifactId>maven-compiler-plugin</artifactId> > > > > > <configuration> > > > > > <source>1.4</source> > > > > > <target>1.4</target> > > > > > </configuration> > > > > > </plugin> > > > > > <plugin> > > > > > > > > > > <groupId>org.apache.maven.plugins</groupId> > > > > > > > > > > <artifactId>maven-ejb-plugin</artifactId> > > > > > <configuration> > > > > > > > > > > <generateClient>true</generateClient> > > > > > </configuration> > > > > > </plugin> > > > > > <plugin> > > > > > > > > > > <artifactId>xdoclet-maven-plugin</artifactId> > > > > > <groupId>org.codehaus.mojo</groupId> > > > > > <executions> > > > > > <execution> > > > > > > > > > > <phase>generate-sources</phase> > > > > > <goals> > > > > > > > > > > <goal>xdoclet</goal> > > > > > </goals> > > > > > <configuration> > > > > > <tasks> > > > > > > > > > > <ejbdoclet > > > > > > > > > > destdir="${project.build.directory}/src-ejb-gen" > > > > > > > > > > verbose="true" > > > > > > > > > > excludedTags="@author,@version"> > > > > > > > > > > > > > > > <fileset > > > > > > > > > > dir="${project.build.sourceDirectory}" > > > > > > > > > > includes="*.*" /> > > > > > > > > > > > > > > > > > > You probably meant includes="**/*.java". I think that "*.*" only will > > > > take java sources directly in src/main/java, and not in any > > > > subdirectories (packages). > > > > > > Of course, Marcel, you are right. > > > > > > As i have stated in the other equivalent thread (i had to re-post this > > > mail due to bad title, i deeply apologize for it, in the first place) > > > the pom.xml was just one of the many attempts to make it work. I had > > > already tried the form you suggest, but still got no results. > > > > > > Is there some kind of debugging the actual ant task arguments ? > > > > > > Can i run maven2 in debug mode (through eclipse) and see what actually > > > is happening ? > > > > > > I'm really disappointed because i suggested to our company a > > > transition from maven1 to maven2, and after 2 weeks, i have nothing to > > > show them. Embarrassing, isn't it ? > > > > > > > > > Any help appreciated. > > > > > > > > > > > > > > > <homeinterface > > > > > > > > > > > <packagesubstitution packages="session" > > > > > substituteWith="interfaces" useFirst=" true"/> > > > > > > > > > > </homeinterface> > > > > > > > > > > <localinterface > > > > > > > > > > mergeDir="${project.build.directory}/merge-dir" /> > > > > > > > > > > <localhomeinterface > > > > > > > > > > mergeDir="${project.build.directory}/merge-dir" /> > > > > > > > > > > <remoteinterface > > > > > > > > > > mergeDir="${project.build.directory}/merge-dir" /> > > > > > > > > > > <deploymentdescriptor > > > > > > > > > > destdir="${project.build.outputDirectory}/META-INF" > > > > > > > > > > /> > > > > > > > > > > </ejbdoclet> > > > > > > > > > > </tasks> > > > > > </configuration> > > > > > </execution> > > > > > </executions> > > > > > </plugin> > > > > > </plugins> > > > > > > > > > > </build> > > > > > > > > > > <dependencies> > > > > > ...nothing of interest here. > > > > > </dependencies> > > > > > > > > > > </project> > > > > > > > > > > > > > > > What am i doing wrong ??? > > > > > > > > > > Thank you very much in advance. > > > > > > > > > > Kostis Anagnostopoulos > > > > > > > > > > PS: Subscribed to list after posting once. I hope i din't resend mail > > > > > twice. > > > > > > > > > > > > > > > > > > > > > > > > > > > -- > > > > Marcel May > > > > ConSol* Software GmbH > > > > Tel: +49 89 45841-155 > > > > > > > > > > > > > > Anagnostopoulos Kostis > > > > > > > -- > > Kenney Westerhof > > http://www.neonics.com > > GPG public key: http://www.gods.nl/~forge/kenneyw.key > > > -- Kenney Westerhof http://www.neonics.com GPG public key: http://www.gods.nl/~forge/kenneyw.key
