You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Mark Thomas <ma...@apache.org> on 2009/05/01 10:20:03 UTC

Re: Static resources not found in embedded Tomcat

Marcel Stör wrote:
> All I need for an embedded Tomcat (I'm working with 6.x) are a few
> Tomcat JARs in my classpath, correct?

It depends what functionality you want - you'll probably need most of them.

> I'm asking because I'm seeing a strange behavior here. Access to
> Servlets deployed in the embedded Tomcat succeed, but requests to other
> resources such as JSPs or static CSS files result in 404 errors.
> I have a feeling that I'm missing something in my Tomcat setup. Here's
> my Tomcat launcher class:

That sounds like you haven't configured the JSP servlet or the default servlet.
Take a look at CATALINA_BASE/conf/web.xml - you probably want to include some of
that stuff in your app's web.xml

HTH,

Mark


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


Re: Static resources not found in embedded Tomcat

Posted by Marcel Stör <ma...@frightanic.com>.
On 01.05.2009, at 10:20, Mark Thomas wrote:

> Marcel Stör wrote:
>> All I need for an embedded Tomcat (I'm working with 6.x) are a few
>> Tomcat JARs in my classpath, correct?
>
> It depends what functionality you want - you'll probably need most  
> of them.
>
>> I'm asking because I'm seeing a strange behavior here. Access to
>> Servlets deployed in the embedded Tomcat succeed, but requests to  
>> other
>> resources such as JSPs or static CSS files result in 404 errors.
>> I have a feeling that I'm missing something in my Tomcat setup.  
>> Here's
>> my Tomcat launcher class:
>
> That sounds like you haven't configured the JSP servlet or the  
> default servlet.
> Take a look at CATALINA_BASE/conf/web.xml - you probably want to  
> include some of
> that stuff in your app's web.xml

Oh yes, indeed. Isn't it obvious...gosh.

Regards,
Marcel

-- 
Marcel Stör, http://www.frightanic.com
Blog: http://frightanic.wordpress.com
Couchsurfing: http://www.couchsurfing.com/people/marcelstoer
Skype: marcelstoer


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