costin 01/03/03 19:31:52
Modified: src/share/org/apache/tomcat/core BaseInterceptor.java
ContextManager.java package.html
Log:
Few more changes in the core:
- added the getNote/setNote hooks, will be used later to allow
lazy-evaluation for notes and fix the few remaining request properties
that are not "lazy" ( SSL attributes, etc ), and provide a simple
mechanism to plug encoding modules.
- Fix in ContextManager, make sure the per/context modules are called.
- Removed the dependencies that are no longer valid.
Revision Changes Path
1.43 +7 -10
jakarta-tomcat/src/share/org/apache/tomcat/core/BaseInterceptor.java
Index: BaseInterceptor.java
===================================================================
RCS file:
/home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/core/BaseInterceptor.java,v
retrieving revision 1.42
retrieving revision 1.43
diff -u -r1.42 -r1.43
--- BaseInterceptor.java 2001/02/20 03:17:56 1.42
+++ BaseInterceptor.java 2001/03/04 03:31:52 1.43
@@ -176,16 +176,6 @@
return 0;
}
-// /** New Session notification - called when the servlet
-// asks for a new session. You can do all kind of stuff with
-// this notification - the most important is create a session
-// object. This will be the base for controling the
-// session allocation.
-// */
-// public int newSessionRequest( Request request, Response response) {
-// return 0;
-// }
-
/** The hook for session managers. It'll be called to
* find or create a ServerSession object associated with a request.
*
@@ -263,6 +253,13 @@
return 0;
}
+ public Object getNote( Request request, int id ) {
+ return null;
+ }
+
+ public int setNote( Request request, int id, Object obj ) {
+ return DECLINED;
+ }
/** This callback is called whenever an exception happen.
* If t is null assume this is a "status" report ( 500, 404, etc).
1.171 +7 -4
jakarta-tomcat/src/share/org/apache/tomcat/core/ContextManager.java
Index: ContextManager.java
===================================================================
RCS file:
/home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/core/ContextManager.java,v
retrieving revision 1.170
retrieving revision 1.171
diff -u -r1.170 -r1.171
--- ContextManager.java 2001/02/25 17:47:16 1.170
+++ ContextManager.java 2001/03/04 03:31:52 1.171
@@ -704,7 +704,7 @@
handleError( req, res, ex );
}
finally {
- BaseInterceptor reqI[]= req.getContainer().
+ BaseInterceptor reqI[]= req.getContext().getContainer().
getInterceptors(Container.H_postRequest);
for( int i=0; i< reqI.length; i++ ) {
@@ -807,7 +807,8 @@
handleStatus( req, req.getResponse(), 503 ); // service unavailable
}
- ri=defaultContainer.getInterceptors(Container.H_requestMap);
+ ri=req.getContext().getContainer().
+ getInterceptors(Container.H_requestMap);
for( int i=0; i< ri.length; i++ ) {
if( debug > 1 )
log( "RequestMap " + ri[i] );
@@ -913,7 +914,8 @@
BaseInterceptor ri[];
int status;
- ri=req.getContainer().getInterceptors( Container.H_handleError );
+ ri=req.getContext().getContainer().
+ getInterceptors( Container.H_handleError );
for( int i=0; i< ri.length; i++ ) {
status=ri[i].handleError( req, res, null );
@@ -927,7 +929,8 @@
public final void handleError( Request req, Response res , Throwable t ) {
BaseInterceptor ri[];
int status;
- ri=req.getContainer().getInterceptors( Container.H_handleError );
+ ri=req.getContext().getContainer().
+ getInterceptors( Container.H_handleError );
for( int i=0; i< ri.length; i++ ) {
status=ri[i].handleError( req, res, t );
if( status!=0 ) return;
1.8 +0 -5 jakarta-tomcat/src/share/org/apache/tomcat/core/package.html
Index: package.html
===================================================================
RCS file: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/core/package.html,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -r1.7 -r1.8
--- package.html 2001/02/27 18:21:58 1.7
+++ package.html 2001/03/04 03:31:52 1.8
@@ -94,11 +94,6 @@
<li>org.apache.tomcat.util.http.*</li>
<li>org.apache.tomcat.util.res.StringManager</li>
<li>org.apache.tomcat.util.buf.MessageBytes;</li>
-
-
- <li>org.apache.tomcat.util.threads.TimeStamp: ServerSession/rm </li>
-
- <li>org.apache.tomcat.util.SimplePrincipal - Request/->facade</li>
</ul>
Indirect dependencies:
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]