maven-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Hervé BOUTEMY <herve.bout...@free.fr>
Subject Re: Site generation with modello fails
Date Sun, 07 Oct 2007 19:59:43 GMT
I looked at Modello code (and fixed the "elememt" typo :) )

It seems you didn't define any class as root element, ie a class with 
rootElement="true": this root element is not necessary to generate classes, 
but it is used by xdoc generation to know which class to set at the top of 
the XML document.

Do you confirm?

Hervé

Le samedi 6 octobre 2007, Jörg Schaible a écrit :
> Hi folks,
>
> for whatever reason my site generation for a plugin with modello
> documentation fails. "install" works fine, so there is no general problem
> with the definitions in the mdo, but site generation is borked:
>
> ======== %< ==========
> joehni@paddy ~/src/BerliOS/JsUnit/maven2 $ mvn -X site
> + Error stacktraces are turned on.
> Maven version: 2.0.5
> [DEBUG] Building Maven user-level plugin registry
> from: '/home/joehni/.m2/plugin-registry.xml'
> [DEBUG] Building Maven global-level plugin registry
> from: '/usr/share/maven-bin-2.0/conf/plugin-registry.xml'
> [INFO] Scanning for projects...
> [DEBUG] Searching for parent-POM:
> de.berlios.jsunit:jsunit-parent::1.3-SNAPSHOT of project:
> null:jsunit-maven2-plugin:maven-plugin:null in relative path: ../pom.xml
> [DEBUG] Using parent-POM from the project hierarchy at: '../pom.xml' for
> project: null:jsunit-maven2-plugin:maven-plugin:null
> [INFO]
> ---------------------------------------------------------------------------
>- [INFO] Building JsUnit Maven2 Plugin
> [INFO]    task-segment: [site]
> [INFO]
> ---------------------------------------------------------------------------
>-
>
> ...
>
> [INFO] Velocity successfully started.
> [DEBUG] Configuring
> mojo 'org.codehaus.modello:modello-maven-plugin:1.0-alpha-11:xdoc' -->
> [DEBUG]   (s) basedir = /home/joehni/src/BerliOS/JsUnit/maven2
> [DEBUG]   (s) model = src/main/mdo/jsunit.mdo
> [DEBUG]   (s) outputDirectory
> = /home/joehni/src/BerliOS/JsUnit/maven2/target/generated-site/xdoc
> [DEBUG]   (s) packageWithVersion = false
> [DEBUG]   (s) project = org.apache.maven.project.MavenProject@e3c2e781
> [DEBUG]   (s) version = 1.0.0
> [DEBUG] -- end configuration --
> [INFO] [modello:xdoc {execution: jsunit-site}]
> [INFO]
> outputDirectory:
> /home/joehni/src/BerliOS/JsUnit/maven2/target/generated-site/xdoc [INFO]
> ------------------------------------------------------------------------
> [ERROR] FATAL ERROR
> [INFO]
> ------------------------------------------------------------------------
> [INFO] There aren't root elememt for version 1.0.0.
> [INFO]
> ------------------------------------------------------------------------
> [DEBUG] Trace
> org.codehaus.modello.ModelloRuntimeException: There aren't root elememt for
> version 1.0.0.
>         at org.codehaus.modello.model.Model.getRoot(Model.java:107)
>         at
> org.codehaus.modello.plugin.xdoc.XdocGenerator.generateXdoc(XdocGenerator.j
>ava:127) at
> org.codehaus.modello.plugin.xdoc.XdocGenerator.generate(XdocGenerator.java:
>62) at
> org.codehaus.modello.core.DefaultModelloCore.generate(DefaultModelloCore.ja
>va:277) at
> org.codehaus.modello.maven.AbstractModelloGeneratorMojo.execute(AbstractMod
>elloGeneratorMojo.java:165) at
> org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManag
>er.java:420) at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLif
>ecycleExecutor.java:539) at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycl
>e(DefaultLifecycleExecutor.java:480) at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLife
>cycleExecutor.java:459) at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFai
>lures(DefaultLifecycleExecutor.java:311) at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(Def
>aultLifecycleExecutor.java:278) at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycl
>eExecutor.java:143) at
> org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:330) at
> org.apache.maven.DefaultMaven.execute(DefaultMaven.java:123) at
> org.apache.maven.cli.MavenCli.main(MavenCli.java:272)
>         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>         at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:3
>9) at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImp
>l.java:25) at java.lang.reflect.Method.invoke(Method.java:324)
>         at
> org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
>         at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
>         at
> org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
>         at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
> [INFO]
> ------------------------------------------------------------------------
> ======== %< ==========
>
> I've compared my mdo with others in the Maven source and I found no
> difference. Here's the declaration in the POM:
>
> ======== %< ==========
>     <build>
>         <plugins>
>             <plugin>
>                 <groupId>org.codehaus.modello</groupId>
>                 <artifactId>modello-maven-plugin</artifactId>
>                 <executions>
>                     <execution>
>                         <id>jsunit</id>
>                         <phase>generate-sources</phase>
>                         <goals>
>                             <goal>java</goal>
>                         </goals>
>                         <configuration>
>                             <model>src/main/mdo/jsunit.mdo</model>
>                             <version>1.0.0</version>
>                         </configuration>
>                     </execution>
>                     <execution>
>                         <id>jsunit-site</id>
>                         <phase>pre-site</phase>
>                         <goals>
>                             <goal>xdoc</goal>
>                         </goals>
>                         <configuration>
>                             <model>src/main/mdo/jsunit.mdo</model>
>                             <version>1.0.0</version>
>                         </configuration>
>                     </execution>
>                 </executions>
>             </plugin>
>         </plugins>
>     </build>
> ...
>     <reporting>
>         <plugins>
>             <plugin>
>                 <groupId>org.apache.maven.plugins</groupId>
>                 <artifactId>maven-plugin-plugin</artifactId>
>                 <version>2.2</version>
>             </plugin>
>         </plugins>
>     </reporting>
>
> ======== %< ==========
>
> Any clue, what causes this weird error? What root element it is looking for
> (note the typo "elememt" in the error msg)?
>
> - Jörg
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org



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


Mime
View raw message