I am using Tomcat 5.0.28 and trying to get my customized valve and realm work but no luck with the following steps. (1) put the jar file containing MyRealm.class and MyValve.class into webapps/myapp/WEB-INF/lib; (2) created a context.xml file in webapps/myapp/META-INF with the following content
    <?xml version="1.0" encoding="utf-8" ?>
     <Context>
          <Valve className="com.mycompany.myapp.MyValve" />
          <Realm className="com.mycompany.myapp.MyRealm" />
     </Context>
(3)Then I restarted Tomcat and debugged it but only found MyValve and MyRealm were not called at all.

I tried to move the context.html to conf/Catalina/localhost and the jar file to server/lib then everything went well. But this is not what I want since the customized Realm and Valve are specific to my application.

I am new to Tomcat and start to get frustrated with this. I thought it should be easy but after googled a lot I still cannot figure out a solution. Any tip will be highly appreciated

Zhiyong

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to