On Mon, Jul 02, 2001 at 09:40:21PM +0100, Julian Gosnell wrote:
> I've messed around a little with Jetty and JSPs :
> 
> These are things I would try :
> 
> 1. Update to the latest JBoss-Jetty - Scott will be putting it on the
> binaries page soon - if you are in a hurry try :
> 
> 
>http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/~checkout~/jboss/binaries/JBoss-2.4.0BETA_Jetty-3.1.RC5-1.tgz?rev=1.1

I did that. As a side not, this one has the jbossmq problem.

> If the problem persists...

Which it did.

> We need to see a log of what happens when you hit the URL and know what
> version and make of JVM you are running and on what platform.
> We need to see your web.xml.

Where do I find a useful log?

I use JDK1.3.0-C on Windows 98.

See further down for xml files.

> 
> Jetty should load a webdefault.xml file with each WebApp - this is
> configured in jboss/conf/jetty/jboss.jcml, thus :
> 
>  <mbean code="org.jboss.jetty.JettyService"
> name="DefaultDomain:service=Jetty">
>   <attribute name="JettyHome">../../jetty</attribute>
>   <attribute
> name="Configuration">file:../conf/jetty/jetty.xml</attribute>
>   <attribute name="WebDefault">../../jetty/etc/webdefault.xml</attribute>
> 
>   <attribute name="UnpackWars">true</attribute>
>   <attribute name="PublishMBeans">true</attribute>
>  </mbean>

It is there.

> 
> This file gives default mappings for all webapps. You should have the
> following mapping in this file:
> 
>   <servlet-mapping>
>     <servlet-name>JSP</servlet-name>
> 
> <url-pattern>*.jsp,*.jsP,*.jSp,*.jSP,*.Jsp,*.JsP,*.JSp,*.JSP</url-pattern>
> 
>   </servlet-mapping>

Where would I find this? It is not in jboss.jcml and not in jetty.xml

I tried adding it to jboss.jcml, but no difference in observed
behaviour.


I find the following in jetty.xml:
    <Call name="addServlet">
      <Arg>JSP</Arg>
      <Arg>*.jsp,*.jsP,*.jSp,*.jSP,*.Jsp,*.JsP,*.JSp,*.JSP</Arg>
      <Arg>org.apache.jasper.servlet.JspServlet</Arg>
    </Call>   
which is similar ...

> 
> try adding the admin servlet to your jboss/conf/jetty/jboss.jcml, by
> pasting the following in :
> 
>   <Call name="addContext">
>     <Arg>/admin</Arg>
>     <Call name="addServlet">
>       <Arg>Admin</Arg>
>       <Arg>/</Arg>
>       <Arg>com.mortbay.Servlet.AdminServlet</Arg>
>     </Call>
>   </Call>
> 
> just before the final </Configure> - then restart and hit e.g.
> localhost:8080/admin.
> 
> You should see exactly what Servlets Jetty is running. The Contexts in
> which they are running, and their mappings.
> 
> Confirm that there is a JSP mapping for the context of the webapp your
> are deploying.

Not sure how I confirm this. The following is said on the admin page
about /account :

ContextPath=/account/*
WebApplicationContext[/account,file:/D:/java/JBoss/JBoss-2.4.0BETA_Jetty-3.1.RC5-1/jboss/tmp/deploy/Default/account.ear/web1001/]
 [Stop]
ResourceBase=file:/D:/java/JBoss/JBoss-2.4.0BETA_Jetty-3.1.RC5-1/jboss/tmp/deploy/Default/account.ear/web1001/
ClassPath=null
SecurityHandler [Stop]
ServletHandler [Stop]
{}
WebApplicationContext$WebInfProtect [Stop]
ResourceHandler [Stop]


My web.xml looks like this:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE web-app
    PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.2//EN"
    "http://java.sun.com/j2ee/dtds/web-app_2_2.dtd";>

<web-app>
    <login-config>
        <auth-method>BASIC</auth-method>
        <realm-name>JAAS Tutorial Servlets</realm-name>
    </login-config>
    <security-role>
        <description>A user allowed to invoke echo methods</description>
        <role-name>Echo</role-name>
    </security-role>
</web-app>





My application.xml looks like this:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE application 
    PUBLIC '-//Sun Microsystems, Inc.//DTD J2EE Application 1.2//EN' 
    'http://java.sun.com/j2ee/dtds/application_1_2.dtd'>

<application>
     <display-name>My Application</display-name>
       <module>
         <web>
            <web-uri>account.war</web-uri>
            <context-root>/account</context-root>
         </web>
       </module>
</application>


Cheers
        Bent
-- 
Bent Dalager - [EMAIL PROTECTED] - http://www.pvv.org/~bcd
                                    powered by emacs

_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to