tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Mario Meisenberger" <meisenber...@labor-c.net>
Subject tomcat start
Date Fri, 06 Jul 2001 06:25:49 GMT
hi,


I am new to tomcat but not new to servlets and jserv.
but i cannot get my project to live with tomcat.


CONFIGURATION
=============

Apache
======
htpd.conf
---------
I added the following line
	Include "G:/Programme/ApacheGroup/apache322/conf/mod_jk.conf"

mod_jk
------
I use the auto-conf generated file rename to mod_jk.conf

I only changed the AJP from 12 to 13 within the profiler servlet jkmount

----------------------------
JkMount /*.jsp ajp12
JkMount /servlet/* ajp12

#########################################################
# Auto configuration for the /profiler context starts.
#########################################################

#
# The following line makes apache aware of the location of the /profiler
context
#
Alias /profiler "G:/Programme/ApacheGroup/tomcat322/webapps/labor"
<Directory "G:/Programme/ApacheGroup/tomcat322/webapps/labor">
    Options Indexes FollowSymLinks
</Directory>

#
# The following line mounts all JSP files and the /servlet/ uri to tomcat
#
JkMount /profiler/servlet/* ajp13
JkMount /profiler/*.jsp ajp12

#
# The following line prohibits users from directly accessing WEB-INF
#
<Location "/profiler/WEB-INF/">
    AllowOverride None
    deny from all
</Location>
#
# Use Directory too. On Windows, Location doesn't work unless case matches
#
<Directory "G:/Programme/ApacheGroup/tomcat322/webapps/profiler/WEB-INF/">
    AllowOverride None
    deny from all
</Directory>

#
# The following line prohibits users from directly accessing META-INF
#
<Location "/profiler/META-INF/">
    AllowOverride None
    deny from all
</Location>
#
# Use Directory too. On Windows, Location doesn't work unless case matches
#
<Directory "G:/Programme/ApacheGroup/tomcat322/webapps/profiler/META-INF/">
    AllowOverride None
    deny from all
</Directory>
--------------------------------------


Tomcat
======

Server.xml
----------

I added the following connector

        <Connector className="org.apache.tomcat.service.PoolTcpConnector">
            <Parameter name="handler"
value="org.apache.tomcat.service.connector.Ajp13ConnectionHandler"/>
            <Parameter name="port" value="8009"/>
        </Connector>

I added the following context

        <Context path="/profiler"
                 docBase="webapps/profiler"
                 crossContext="false"
                 debug="0"
                 reloadable="true" >
        </Context>

Web.xml
-------

I changed nothing


MY SERVLET APPLICATION
======================

I generated the following directories in /tomcat322/webapps

/profiler
subdirectories and files
	index.html
	hellol.html
	/META-INF
	/WEB-INF
		/classes
		/web.xml

by the way both static pages work fine when i type
	http://localhost/profiler/
	http://localhost/profiler/hello.html

my own web.xml
--------------

------------------------------------
<?xml version="1.0" encoding="ISO-8859-1"?>

<!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>
    <servlet>
        <servlet-name>
            profiler
        </servlet-name>
        <servlet-class>
            com/labor/profiler/iface/servlets/Pr_BE_Servlet.class
        </servlet-class>
        <init-param>
            <param-name>param1</param-name>
            <param-value>value1</param-value>
        </init-param>
    </servlet>

<!--
        <load-on-startup></load-on-startup>
-->
    </servlet>

    <servlet-mapping>
        <servlet-name>
            profiler
        </servlet-name>
        <url-pattern>
            /profiler/*
        </url-pattern>
    </servlet-mapping>

    <security-constraint>
      <web-resource-collection>
         <web-resource-name>a</web-resource-name>
         <url-pattern>/foo1/*</url-pattern>
         <url-pattern>/bar1/*</url-pattern>
         <http-method>GET</http-method>
         <http-method>POST</http-method>
      </web-resource-collection>

      <web-resource-collection>
         <web-resource-name>a</web-resource-name>
         <url-pattern>/foo2/*</url-pattern>
         <url-pattern>/bar2/*</url-pattern>
      </web-resource-collection>

      <auth-constraint>
         <role-name>manager</role-name>
         <role-name>role1</role-name>
      </auth-constraint>

      <user-data-constraint>
         <transport-guarantee>CONFIDENTIAL</transport-guarantee>
      </user-data-constraint>
    </security-constraint>
</web-app>
------------------------------------



yes thats it ;)

can anyone tell me where to change something to get the thing run?
or simply an error message that tells me anything ;))

thanks in advance

	Mario




Mime
View raw message