On May 6, 2009, at 5:52 PM, Woodbury David-R28558 wrote:
> Hi Paul:
>
> I am using embedded Maven 3.0-Snapshot in NB 6.5. I deploy the WAR
> to Tomcat 6.0.18.
>
There are a whole bunch of JavaDoc warnings and:
> [WARN]java.lang.ClassNotFoundException:
> com.sun.jersey.samples.extendedwadl.util.Examples
> [WARN]at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
> [WARN]at java.security.AccessController.doPrivileged(Native Method)
> [WARN]at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
> [WARN]at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
> [WARN]at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
> [WARN]at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
> [WARN]at java.lang.Class.forName0(Native Method)
> [WARN]at java.lang.Class.forName(Class.java:247)
The Examples class cannot be found hence why the SAMPLE_ITEM is not
being included.
Can you try with maven 2.0.9 ?
Paul.
> Here's the build output.
>
> David
>
> WARNING: You are running embedded Maven builds, some build may fail
> due to incompatibilities with latest Maven release.
> To set Maven instance to use for building, click here.
> Scanning for projects... Attempting to resolve a version for
> plugin: org.codehaus.mojo:xslt-maven-plugin using meta-version: LATEST
> Using version: 1.0 of plugin: org.codehaus.mojo:xslt-maven-plugin
> [#generate-sources]
> [jaxb:generate]
> The <includeBindings> setting was not defined, assuming *.xjb.
> schemaDirectory: D:\R28558\jersey-samples-1.0.3\extended-wadl-webapp
> \src\main\xsd
> includeSchemas: [**/*.xsd]
> excludeSchemas: null
> includeBindings: [*.xjb]
> excludeBindings: null
> generatePackage: com.sun.jersey.samples.extendedwadl.model
> generateDirectory: D:\R28558\jersey-samples-1.0.3\extended-wadl-
> webapp\target\generated-sources\xjc
> readOnly: false
> extension: true
> catalog: null
> removeOldOutput: false
> strict: false
> verbose: true
> pom dependency: D:\R28558\jersey-samples-1.0.3\extended-wadl-webapp
> \pom.xml
> Schema dependency: D:\R28558\jersey-samples-1.0.3\extended-wadl-
> webapp\src\main\xsd\schema.xsd
> XJC compile
> build id of XJC is 2.0.2-b01-fcs
> Checking timestamp of D:\R28558\jersey-samples-1.0.3\extended-wadl-
> webapp\src\main\xsd\schema.xsd
> Checking timestamp of D:\R28558\jersey-samples-1.0.3\extended-wadl-
> webapp\pom.xml
> Checking timestamp of D:\R28558\jersey-samples-1.0.3\extended-wadl-
> webapp\src\main\xsd\schema.xsd
> Checking timestamp of D:\R28558\jersey-samples-1.0.3\extended-wadl-
> webapp\target\generated-sources\xjc\com\sun\jersey\samples
> \extendedwadl\model\Item.java
> Checking timestamp of D:\R28558\jersey-samples-1.0.3\extended-wadl-
> webapp\target\generated-sources\xjc\com\sun\jersey\samples
> \extendedwadl\model\Items.java
> Checking timestamp of D:\R28558\jersey-samples-1.0.3\extended-wadl-
> webapp\target\generated-sources\xjc\com\sun\jersey\samples
> \extendedwadl\model\ObjectFactory.java
> Checking timestamp of D:\R28558\jersey-samples-1.0.3\extended-wadl-
> webapp\target\generated-sources\xjc\com\sun\jersey\samples
> \extendedwadl\model\package-info.java
> the last modified time of the inputs is 1241617477671
> the last modified time of the outputs is 1241617706218
> files are up to date
> [#process-resources]
> [resources:resources]
> Using default encoding to copy filtered resources.
> [#compile]
> [compiler:compile]
> Nothing to compile - all classes are up to date
> Setting property: classpath.resource.loader.class =>
> 'org.codehaus.plexus.velocity.ContextClassLoaderResourceLoader'.
> Setting property: velocimacro.messages.on => 'false'.
> Setting property: resource.loader => 'classpath'.
> Setting property: resource.manager.logwhenfound => 'false'.
> **************************************************************
> Starting Jakarta Velocity v1.4
> RuntimeInstance initializing.
> Default Properties File: org\apache\velocity\runtime\defaults
> \velocity.properties
> Default ResourceManager initializing. (class
> org.apache.velocity.runtime.resource.ResourceManagerImpl)
> Resource Loader Instantiated:
> org.codehaus.plexus.velocity.ContextClassLoaderResourceLoader
> ClasspathResourceLoader : initialization starting.
> ClasspathResourceLoader : initialization complete.
> ResourceCache : initialized. (class
> org.apache.velocity.runtime.resource.ResourceCacheImpl)
> Default ResourceManager initialization complete.
> Loaded System Directive: org.apache.velocity.runtime.directive.Literal
> Loaded System Directive: org.apache.velocity.runtime.directive.Macro
> Loaded System Directive: org.apache.velocity.runtime.directive.Parse
> Loaded System Directive: org.apache.velocity.runtime.directive.Include
> Loaded System Directive: org.apache.velocity.runtime.directive.Foreach
> Created: 20 parsers.
> Velocimacro : initialization starting.
> Velocimacro : adding VMs from VM library template :
> VM_global_library.vm
> [ERROR]ResourceManager : unable to find resource
> 'VM_global_library.vm' in any resource loader.
> Velocimacro : error using VM library template
> VM_global_library.vm :
> org.apache.velocity.exception.ResourceNotFoundException: Unable to
> find resource 'VM_global_library.vm'
> Velocimacro : VM library template macro registration complete.
> Velocimacro : allowInline = true : VMs can be defined inline in
> templates
> Velocimacro : allowInlineToOverride = false : VMs defined inline may
> NOT replace previous VM definitions
> Velocimacro : allowInlineLocal = false : VMs defined inline will be
> global in scope if allowed.
> Velocimacro : initialization complete.
> Velocity successfully started.
> [javadoc:javadoc]
> Loading source files for package
> com.sun.jersey.samples.extendedwadl.resources...
> Constructing Javadoc information...
> [WARN]Javadoc Warnings
> [WARN]May 6, 2009 8:49:37 AM
> com.sun.jersey.wadl.resourcedoc.ResourceDoclet
> getSerializedLinkFromTag
> [WARN]INFO: Have classloader: class java.net.URLClassLoader
> [WARN]May 6, 2009 8:49:37 AM
> com.sun.jersey.wadl.resourcedoc.ResourceDoclet
> getSerializedLinkFromTag
> [WARN]INFO: Have thread classloader class
> com.sun.jersey.wadl.resourcedoc.ResourceDoclet$Loader
> [WARN]May 6, 2009 8:49:37 AM
> com.sun.jersey.wadl.resourcedoc.ResourceDoclet
> getSerializedLinkFromTag
> [WARN]INFO: Have system classloader class sun.misc.Launcher
> $AppClassLoader
> [WARN]May 6, 2009 8:49:37 AM
> com.sun.jersey.wadl.resourcedoc.ResourceDoclet
> getSerializedLinkFromTag
> [WARN]SEVERE: Could not get field
> com.sun.jersey.samples.extendedwadl.util.Examples.SAMPLE_ITEM
> [WARN]java.lang.ClassNotFoundException:
> com.sun.jersey.samples.extendedwadl.util.Examples
> [WARN]at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
> [WARN]at java.security.AccessController.doPrivileged(Native Method)
> [WARN]at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
> [WARN]at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
> [WARN]at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
> [WARN]at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
> [WARN]at java.lang.Class.forName0(Native Method)
> [WARN]at java.lang.Class.forName(Class.java:247)
> [WARN]at
> com
> .sun
> .jersey
> .wadl
> .resourcedoc
> .ResourceDoclet.getSerializedLinkFromTag(ResourceDoclet.java:512)
> [WARN]at
> com
> .sun
> .jersey
> .wadl
> .resourcedoc.ResourceDoclet.getSerializedExample(ResourceDoclet.java:
> 422)
> [WARN]at
> com
> .sun
> .jersey
> .wadl
> .resourcedoc
> .ResourceDoclet.addRequestRepresentationDoc(ResourceDoclet.java:370)
> [WARN]at
> com
> .sun
> .jersey.wadl.resourcedoc.ResourceDoclet.start(ResourceDoclet.java:162)
> [WARN]at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> [WARN]at
> sun
> .reflect
> .NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> [WARN]at
> sun
> .reflect
> .DelegatingMethodAccessorImpl
> .invoke(DelegatingMethodAccessorImpl.java:25)
> [WARN]at java.lang.reflect.Method.invoke(Method.java:597)
> [WARN]at
> com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:269)
> [WARN]at
> com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:143)
> [WARN]at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:340)
> [WARN]at com.sun.tools.javadoc.Start.begin(Start.java:128)
> [WARN]at com.sun.tools.javadoc.Main.execute(Main.java:41)
> [WARN]at com.sun.tools.javadoc.Main.main(Main.java:31)
> [WARN]May 6, 2009 8:49:37 AM
> com.sun.jersey.wadl.resourcedoc.ResourceDoclet
> addRequestRepresentationDoc
> [WARN]WARNING: Could not get serialized example for method
> com.sun.jersey.samples.extendedwadl.resources.ItemsResource.createItem
> [WARN]May 6, 2009 8:49:37 AM
> com.sun.jersey.wadl.resourcedoc.ResourceDoclet
> getSerializedLinkFromTag
> [WARN]INFO: Have classloader: class java.net.URLClassLoader
> [WARN]May 6, 2009 8:49:37 AM
> com.sun.jersey.wadl.resourcedoc.ResourceDoclet
> getSerializedLinkFromTag
> [WARN]INFO: Have thread classloader class
> com.sun.jersey.wadl.resourcedoc.ResourceDoclet$Loader
> [WARN]May 6, 2009 8:49:37 AM
> com.sun.jersey.wadl.resourcedoc.ResourceDoclet
> getSerializedLinkFromTag
> [WARN]INFO: Have system classloader class sun.misc.Launcher
> $AppClassLoader
> [WARN]May 6, 2009 8:49:37 AM
> com.sun.jersey.wadl.resourcedoc.ResourceDoclet
> getSerializedLinkFromTag
> [WARN]SEVERE: Could not get field
> com.sun.jersey.samples.extendedwadl.util.Examples.SAMPLE_ITEM
> [WARN]java.lang.ClassNotFoundException:
> com.sun.jersey.samples.extendedwadl.util.Examples
> [WARN]at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
> [WARN]at java.security.AccessController.doPrivileged(Native Method)
> [WARN]at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
> [WARN]at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
> [WARN]at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
> [WARN]at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
> [WARN]at java.lang.Class.forName0(Native Method)
> [WARN]at java.lang.Class.forName(Class.java:247)
> [WARN]at
> com
> .sun
> .jersey
> .wadl
> .resourcedoc
> .ResourceDoclet.getSerializedLinkFromTag(ResourceDoclet.java:512)
> [WARN]at
> com
> .sun
> .jersey
> .wadl
> .resourcedoc.ResourceDoclet.getSerializedExample(ResourceDoclet.java:
> 422)
> [WARN]at
> com
> .sun
> .jersey
> .wadl.resourcedoc.ResourceDoclet.addResponseDoc(ResourceDoclet.java:
> 334)
> [WARN]at
> com
> .sun
> .jersey.wadl.resourcedoc.ResourceDoclet.start(ResourceDoclet.java:164)
> [WARN]at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> [WARN]at
> sun
> .reflect
> .NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> [WARN]at
> sun
> .reflect
> .DelegatingMethodAccessorImpl
> .invoke(DelegatingMethodAccessorImpl.java:25)
> [WARN]at java.lang.reflect.Method.invoke(Method.java:597)
> [WARN]at
> com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:269)
> [WARN]at
> com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:143)
> [WARN]at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:340)
> [WARN]at com.sun.tools.javadoc.Start.begin(Start.java:128)
> [WARN]at com.sun.tools.javadoc.Main.execute(Main.java:41)
> [WARN]at com.sun.tools.javadoc.Main.main(Main.java:31)
> [WARN]May 6, 2009 8:49:38 AM
> com.sun.jersey.wadl.resourcedoc.ResourceDoclet start
> [WARN]INFO: Wrote D:\R28558\jersey-samples-1.0.3\extended-wadl-webapp
> \target\classes/resourcedoc.xml
> [#process-test-resources]
> [resources:testResources]
> Using default encoding to copy filtered resources.
> [#test-compile]
> [compiler:testCompile]
> Nothing to compile - all classes are up to date
> [#test]
> [surefire:test]
> Surefire report directory: D:\R28558\jersey-samples-1.0.3\extended-
> wadl-webapp\target\surefire-reports
> -------------------------------------------------------
> T E S T S
> -------------------------------------------------------
> Running com.sun.jersey.samples.extendedwadl.ExtendedWadlWebappTest
> May 6, 2009 8:49:38 AM
> com
> .sun
> .jersey
> .test.framework.impl.container.grizzly.web.GrizzlyWebContainer start
> INFO: Starting grizzly...
> May 6, 2009 8:49:39 AM
> com.sun.grizzly.http.servlet.ServletContextImpl initListeners
> WARNING: Unable to load listener: null
> May 6, 2009 8:49:42 AM
> com.sun.jersey.api.core.PackagesResourceConfig init
> INFO: Scanning for root resource and provider classes in the packages:
> com.sun.jersey.samples.extendedwadl.resources
> May 6, 2009 8:49:42 AM
> com.sun.jersey.api.core.PackagesResourceConfig init
> INFO: Root resource classes found:
> class com.sun.jersey.samples.extendedwadl.resources.ItemsResource
> May 6, 2009 8:49:42 AM
> com.sun.jersey.api.core.PackagesResourceConfig init
> INFO: Provider classes found:
> May 6, 2009 8:49:43 AM
> com.sun.jersey.api.wadl.config.WadlGeneratorLoader loadWadlGenerator
> INFO: Loading wadlGenerator
> com.sun.jersey.server.wadl.generators.WadlGeneratorApplicationDoc
> May 6, 2009 8:49:43 AM
> com.sun.jersey.api.wadl.config.WadlGeneratorLoader loadWadlGenerator
> INFO: Loading wadlGenerator
> com.sun.jersey.server.wadl.generators.WadlGeneratorGrammarsSupport
> May 6, 2009 8:49:43 AM
> com.sun.jersey.api.wadl.config.WadlGeneratorLoader loadWadlGenerator
> INFO: Loading wadlGenerator
> com
> .sun
> .jersey
> .server.wadl.generators.resourcedoc.WadlGeneratorResourceDocSupport
> Results :
> [#package]
> [war:war]
> Packaging webapp
> Assembling webapp[extended-wadl-webapp] in [D:\R28558\jersey-
> samples-1.0.3\extended-wadl-webapp\target\extended-wadl-webapp]
> Processing war project
> Webapp assembled in[32 msecs]
> Building war: D:\R28558\jersey-samples-1.0.3\extended-wadl-webapp
> \target\extended-wadl-webapp.war
> [xslt:transform]
> # of XML files: 1
> file up-to-date: D:\R28558\jersey-samples-1.0.3\extended-wadl-webapp
> \target\gf-pom-file\pom.xml
> [WARN]DEPRECATED: Binding aggregator mojos to lifecycle phases in
> the POM is considered dangerous.
> [WARN]This feature has been deprecated. Please adjust your POM files
> accordingly.
> [WARN]Offending mojo:
> [WARN]org.apache.maven.plugins:maven-assembly-plugin:2.2-
> beta-1:attached
> [WARN]Project: com.sun.jersey.samples:extended-wadl-webapp:war:1.0.3
> [WARN]POM File: D:\R28558\jersey-samples-1.0.3\extended-wadl-webapp
> \pom.xml
> [assembly:attached]
> Reading assembly descriptor: D:\R28558\jersey-samples-1.0.3\extended-
> wadl-webapp\src\main\assembly\src.xml
> Reading assembly descriptor: D:\R28558\jersey-samples-1.0.3\extended-
> wadl-webapp\src\main\assembly\glassfish.xml
> Building zip: D:\R28558\jersey-samples-1.0.3\extended-wadl-webapp
> \target\extended-wadl-webapp-project.zip
> Building zip: D:\R28558\jersey-samples-1.0.3\extended-wadl-webapp
> \target\extended-wadl-webapp-gf-project.zip
> [#install]
> [install:install]
> Installing D:\R28558\jersey-samples-1.0.3\extended-wadl-webapp\target
> \extended-wadl-webapp.war to D:\Profiles\R28558\.m2\repository\com
> \sun\jersey\samples\extended-wadl-webapp\1.0.3\extended-wadl-
> webapp-1.0.3.war
> Installing D:\R28558\jersey-samples-1.0.3\extended-wadl-webapp\target
> \extended-wadl-webapp-project.zip to D:\Profiles
> \R28558\.m2\repository\com\sun\jersey\samples\extended-wadl-webapp
> \1.0.3\extended-wadl-webapp-1.0.3-project.zip
> Installing D:\R28558\jersey-samples-1.0.3\extended-wadl-webapp\target
> \extended-wadl-webapp-gf-project.zip to D:\Profiles
> \R28558\.m2\repository\com\sun\jersey\samples\extended-wadl-webapp
> \1.0.3\extended-wadl-webapp-1.0.3-gf-project.zip
> ------------------------------------------------------------------------
> BUILD SUCCESSFUL
> ------------------------------------------------------------------------
> Total time: 10 seconds
> Finished at: Wed May 06 08:49:45 MST 2009
> Final Memory: 108M/199M
> ------------------------------------------------------------------------
>
> From: Woodbury David-R28558
> Sent: Tuesday, May 05, 2009 2:35 PM
> To: users_at_jersey.dev.java.net
> Subject: Issue with WADL "@link" Javadoc tag for dynamic content
>
> Hello:
>
> How can I trouble-shoot the @link tag with respect to dynamic content?
>
> I built the extended WADL sample application, included in Jersey
> 1.0.3, and the resulting WADL file did not include content
> associated with the {_at_link Examples#SAMPLE_ITEM} tag.
>
> The information was also missing from the resourcedoc.xml file.
>
> Static content associated with an @link tag does get picked up and
> displayed in the application.wadl.
>
> Thank you for any pointers on this.
>
> David Woodbury
>
>