Well, sometimes it seems you just need to wait until I posted the solution I
was already working on... ;-)
 
Have Fun
Markus
 
From: Daniel Manzke [mailto:daniel.manzke_at_googlemail.com] 
Sent: Samstag, 7. Februar 2009 18:19
To: users_at_jersey.dev.java.net
Subject: Re: [Jersey] Jersey + WEBDav problem on Tomcat 6
 
Hi,
 
I read your post about using WebDAV and Tomcat6. Due the fact that Markus
(and me)  working on Tomcat 6 Support/Example I tried it, too. But I didn't
get it work.
 
My Tomcat 6 throws an exception:
 
07.02.2009 18:07:11 org.apache.catalina.core.ApplicationContext log
SCHWERWIEGEND: StandardWrapper.Throwable
java.lang.NoSuchMethodError:
com.sun.jersey.spi.inject.InjectableProvider.getScope()Lcom/sun/jersey/spi/s
ervice/ComponentProvider$Scope;
          at
com.sun.jersey.impl.application.InjectableProviderFactory.findInjectableProv
iders(InjectableProviderFactory.java:176)
          at
com.sun.jersey.impl.application.InjectableProviderFactory._getInjectable(Inj
ectableProviderFactory.java:226)
          at
com.sun.jersey.impl.application.InjectableProviderFactory.getInjectable(Inje
ctableProviderFactory.java:204)
          at
com.sun.jersey.impl.application.InjectableProviderFactory.injectResources(In
jectableProviderFactory.java:351)
          at
com.sun.jersey.impl.application.WebApplicationImpl.injectResources(WebApplic
ationImpl.java:314)
 
Could it be that I have a wrong version of Jersey? Is there any example how
to use Jersey/JAX-RS with Tomcat?
 
My web.xml:
 
  <servlet>
          <servlet-name>JAX-RS REST Servlet</servlet-name>
          <servlet-class>
                      com.sun.jersey.spi.container.servlet.ServletContainer
          </servlet-class>
          <init-param>
          <param-name>javax.ws.rs.Application</param-name>
 
<param-value>de.java.dev.webdav.fileserver.tomcat.FileServerApplication</par
am-value>
          </init-param>              
          <load-on-startup>1</load-on-startup>
  </servlet>
 
Which JARs are needed for Tomcat Support? Is it okay, when they are placed
in the WEB-INF/lib?
 
 
 
BR,
Daniel :)
 
2009/2/5 Paul Sandoz <Paul.Sandoz_at_sun.com>
On Feb 5, 2009, at 12:13 PM, Christopher Schmidt wrote:
We are using Grizzly like this:
GrizzlyServerFactory.create("
http://localhost:80/",
RuntimeDelegate.getInstance().createEndpoint(new WebDAVApplication(),
Adapter.class));
 
OK. We need to ascertain if the Jersey servlet is at fault or not (i suspect
not but still...). You can use the Grizzly Web container support as follows:
       Map<String, String> initParams = new HashMap<String, String>();
       initParams.put("javax.ws.rs.Application",
               WebDAVApplication.class.getName());
      GrizzlyWebContainerFactory.create("
http://localhost:80/", params);
The Grizzly Web container will use the Jersey ServletContainer.
Yes, @GET works fine.
OK.
Maybe Tomcat is blocking the PROPFIND method, this would be a configuration
issue.
 
If you add the logging filter as i suggested you can ascertain if the
PROPFIND request is hitting the Jersey ServletContainer or not.
Do I have to do anything special with the Tomcat config?
 
I do not know.
Paul.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe_at_jersey.dev.java.net
For additional commands, e-mail: users-help_at_jersey.dev.java.net
-- 
Mit freundlichen Grüßen
Daniel Manzke