cvs commit: jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4 Ajp13Connector.java
hgomez 2003/10/09 03:08:43 Modified:jk/java/org/apache/ajp/tomcat4 Ajp13Connector.java Log: Remote setKeepAlive (set by the native side). Fix #23675 Revision ChangesPath 1.19 +10 -5 jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Connector.java Index: Ajp13Connector.java === RCS file: /home/cvs/jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Connector.java,v retrieving revision 1.18 retrieving revision 1.19 diff -u -r1.18 -r1.19 --- Ajp13Connector.java 18 Sep 2003 16:21:01 - 1.18 +++ Ajp13Connector.java 9 Oct 2003 10:08:43 - 1.19 @@ -888,7 +888,12 @@ else socket.setSoLinger(true, connectionLinger); -socket.setKeepAlive(true); +/* We don't need it since it's the native side which + * will set the connection with keep alive + * if specified in workers.properties. + * + * socket.setKeepAlive(true); + */ /* Warning : * - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
cvs commit: jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4 Ajp13Connector.java
glenn 2002/12/26 18:21:27 Modified:jk/java/org/apache/ajp/tomcat4 Ajp13Connector.java Log: Fix rare case where processor counter was not decremented. Revision ChangesPath 1.17 +5 -4 jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Connector.java Index: Ajp13Connector.java === RCS file: /home/cvs/jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Connector.java,v retrieving revision 1.16 retrieving revision 1.17 diff -u -r1.16 -r1.17 --- Ajp13Connector.java 20 Nov 2002 14:14:20 - 1.16 +++ Ajp13Connector.java 27 Dec 2002 02:21:27 - 1.17 @@ -797,6 +797,7 @@ ((Lifecycle) processor).start(); } catch (LifecycleException e) { logger.log(newProcessor, e); +curProcessors--; return (null); } } -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
cvs commit: jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4 Ajp13Connector.java
hgomez 2002/11/20 06:14:20 Modified:jk/java/org/apache/ajp/tomcat4 Ajp13Connector.java Log: Add Linger support, and add some comments about IP settings for AJP13 Revision ChangesPath 1.16 +64 -6 jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Connector.java Index: Ajp13Connector.java === RCS file: /home/cvs/jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Connector.java,v retrieving revision 1.15 retrieving revision 1.16 diff -u -r1.15 -r1.16 --- Ajp13Connector.java 21 Apr 2002 23:17:48 - 1.15 +++ Ajp13Connector.java 20 Nov 2002 14:14:20 - 1.16 @@ -196,6 +196,13 @@ /** + * Linger value to be used on socket close. + * Note : a value of -1 means no linger used on close. + */ +private int connectionLinger = -1; + + +/** * The port number on which we listen for ajp13 requests. */ private int port = 8009; @@ -309,7 +316,7 @@ /** * Set the connection timeout for this Connector. * - * @param count The new connection timeout + * @param connectionTimeout The new connection timeout */ public void setConnectionTimeout(int connectionTimeout) { @@ -317,6 +324,27 @@ } +/** + * Return the connection linger settings for this Connector. + */ +public int getConnectionLinger() { + + return (connectionLinger); + +} + + +/** + * Set the connection linger for this Connector. + * + * @param connectionLinger The new connection linger + */ +public void setConnectionLinger(int connectionLinger) { + + this.connectionLinger = connectionLinger; + +} + public void setSecret( String s ) { secret=s; } @@ -844,9 +872,39 @@ logger.log(accepted socket, assigning to processor.); } -socket.setSoLinger(true, 100); +/* Warning : + * + * To be able to close more quickly a connection, it's recommanded + * to set linger to a small value. + * + * AJP13 connection SHOULD be closed under webserver responsability and + * in such case it's safe to close socket on Tomcat side without delay, + * which may be also the case for HTTP connectors. + * + * I (henri) recommand to set Linger to 0, making socket closed immediatly + * so the OS will free faster the underlying io descriptor and resources. + * It's very important under heavy load ! + */ + +if (connectionLinger 0) + socket.setSoLinger(false, 0); +else + socket.setSoLinger(true, connectionLinger); + socket.setKeepAlive(true); +/* Warning : + * + * AJP13 shouldn't use socket timeout on tomcat site since + * when Tomcat close a connection after a timeout is reached + * the socket stay in half-closed state until the webserver + * try to send a request to tomcat and detect the socket close + * when it will try to read the reply. + * + * On many Unix platforms the write() call didn't told + * webserver that the socket is closed. + */ + if (connectionTimeout = 0) { socket.setSoTimeout(connectionTimeout); } -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
cvs commit: jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4 Ajp13Connector.java
glenn 02/04/21 16:17:48 Modified:jk/java/org/apache/ajp/tomcat4 Ajp13Connector.java Log: Only start debug thread if debug 0 Revision ChangesPath 1.15 +15 -15 jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Connector.java Index: Ajp13Connector.java === RCS file: /home/cvs/jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Connector.java,v retrieving revision 1.14 retrieving revision 1.15 diff -u -r1.14 -r1.15 --- Ajp13Connector.java 20 Feb 2002 16:12:42 - 1.14 +++ Ajp13Connector.java 21 Apr 2002 23:17:48 - 1.15 @@ -1,7 +1,7 @@ /* - * $Header: /home/cvs/jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Connector.java,v 1.14 2002/02/20 16:12:42 seguin Exp $ - * $Revision: 1.14 $ - * $Date: 2002/02/20 16:12:42 $ + * $Header: /home/cvs/jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Connector.java,v 1.15 2002/04/21 23:17:48 glenn Exp $ + * $Revision: 1.15 $ + * $Date: 2002/04/21 23:17:48 $ * * * @@ -93,7 +93,7 @@ * Implementation of an Ajp13 connector. * * @author Kevin Seguin - * @version $Revision: 1.14 $ $Date: 2002/02/20 16:12:42 $ + * @version $Revision: 1.15 $ $Date: 2002/04/21 23:17:48 $ */ @@ -994,9 +994,11 @@ throw new LifecycleException (sm.getString(ajp13Connector.alreadyStarted)); -debugThread = new DebugThread(); -debugThread.setDaemon(true); -debugThread.start(); +if (debug 0) { +debugThread = new DebugThread(); +debugThread.setDaemon(true); +debugThread.start(); +} threadName = Ajp13Connector[ + port + ]; threadGroup = new ThreadGroup(threadName); @@ -1081,14 +1083,12 @@ } catch (InterruptedException e) { break; } -if (debug 0) { -logger.log(active threads= + threadGroup.activeCount()); -System.out.println(===); -System.out.println(Ajp13Connector active threads= - + threadGroup.activeCount()); -threadGroup.list(); -System.out.println(===); -} +logger.log(active threads= + threadGroup.activeCount()); +System.out.println(===); +System.out.println(Ajp13Connector active threads= + + threadGroup.activeCount()); +threadGroup.list(); +System.out.println(===); } } } -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
cvs commit: jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4 Ajp13Connector.java Ajp13Processor.java
seguin 02/02/20 08:12:42 Modified:jk/java/org/apache/ajp Ajp13.java RequestHandler.java jk/java/org/apache/ajp/tomcat4 Ajp13Connector.java Ajp13Processor.java Added: jk/java/org/apache/ajp Logger.java Log: logging improvements: *) have log messages from ajp classes (Ajp13, RequestHandler, etc.) go to connector's logger (so they get logged to a file with the rest of the connector's log message). *) put all threads created by tomcat4 connector into a thread group and do a ThreadGroup.list() every minute when debug level is 0. (this should probably be made configurable, and perhaps send this info to the log file instead of stdout. baby steps.) these changes were, in part, brought on by bug 5735 in an attempt to debug the problem. Revision ChangesPath 1.24 +2 -10 jakarta-tomcat-connectors/jk/java/org/apache/ajp/Ajp13.java Index: Ajp13.java === RCS file: /home/cvs/jakarta-tomcat-connectors/jk/java/org/apache/ajp/Ajp13.java,v retrieving revision 1.23 retrieving revision 1.24 diff -u -r1.23 -r1.24 --- Ajp13.java6 Feb 2002 18:26:50 - 1.23 +++ Ajp13.java20 Feb 2002 16:12:42 - 1.24 @@ -551,24 +551,16 @@ public void setDebug(int debug) { this.debug = debug; +this.reqHandler.setDebug(debug); } public void setLogger(Logger l) { this.logger = l; +this.reqHandler.setLogger(l); } /** * XXX place holder... */ Logger logger = new Logger(); -public static class Logger { -void log(String msg) { -System.out.println([Ajp13] + msg); -} - -void log(String msg, Throwable t) { -System.out.println([Ajp13] + msg); -t.printStackTrace(System.out); -} -} } 1.12 +12 -2 jakarta-tomcat-connectors/jk/java/org/apache/ajp/RequestHandler.java Index: RequestHandler.java === RCS file: /home/cvs/jakarta-tomcat-connectors/jk/java/org/apache/ajp/RequestHandler.java,v retrieving revision 1.11 retrieving revision 1.12 diff -u -r1.11 -r1.12 --- RequestHandler.java 6 Feb 2002 18:26:50 - 1.11 +++ RequestHandler.java 20 Feb 2002 16:12:42 - 1.12 @@ -583,9 +583,19 @@ return -1; } -private static int debug=0; +private int debug=0; +private Logger logger = new Logger(); + +public void setDebug(int debug) { +this.debug = debug; +} + +public void setLogger(Logger l) { +this.logger = l; +} + void log(String s) { - System.out.println(RequestHandler: + s ); +logger.log([RequestHandler] + s ); } // Servlet Input Support = 1.1 jakarta-tomcat-connectors/jk/java/org/apache/ajp/Logger.java Index: Logger.java === /* * * * The Apache Software License, Version 1.1 * * Copyright (c) 1999 The Apache Software Foundation. All rights * reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * * 1. Redistributions of source code must retain the above copyright *notice, this list of conditions and the following disclaimer. * * 2. Redistributions in binary form must reproduce the above copyright *notice, this list of conditions and the following disclaimer in *the documentation and/or other materials provided with the *distribution. * * 3. The end-user documentation included with the redistribution, if *any, must include the following acknowlegement: * This product includes software developed by the *Apache Software Foundation (http://www.apache.org/). *Alternately, this acknowlegement may appear in the software itself, *if and wherever such third-party acknowlegements normally appear. * * 4. The names The Jakarta Project, Tomcat, and Apache Software *Foundation must not be used to endorse or promote products derived *from this software without prior written permission. For written *permission, please contact [EMAIL PROTECTED] * * 5. Products derived from this software may not be called Apache *nor may Apache appear in their names without prior written *permission of the Apache Group. * * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED *
cvs commit: jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4 Ajp13Connector.java Ajp13Request.java
remm02/02/15 13:13:19 Modified:jk/java/org/apache/ajp/tomcat4 Ajp13Connector.java Ajp13Request.java Log: - Add a 'tomcatAuthentication' flag, which defaults to true. - If the flag is true, Tomcat is 100% responsible of the authentication. If false, the user authenticated by the native webserver will be used. - This new flag will be added in the docs, after reviewing. - I didn't know I would end up contributing stuff to JK ;-) Revision ChangesPath 1.13 +31 -4 jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Connector.java Index: Ajp13Connector.java === RCS file: /home/cvs/jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Connector.java,v retrieving revision 1.12 retrieving revision 1.13 diff -u -r1.12 -r1.13 --- Ajp13Connector.java 7 Feb 2002 00:44:40 - 1.12 +++ Ajp13Connector.java 15 Feb 2002 21:13:19 - 1.13 @@ -1,7 +1,7 @@ /* - * $Header: /home/cvs/jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Connector.java,v 1.12 2002/02/07 00:44:40 costin Exp $ - * $Revision: 1.12 $ - * $Date: 2002/02/07 00:44:40 $ + * $Header: /home/cvs/jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Connector.java,v 1.13 2002/02/15 21:13:19 remm Exp $ + * $Revision: 1.13 $ + * $Date: 2002/02/15 21:13:19 $ * * * @@ -93,7 +93,7 @@ * Implementation of an Ajp13 connector. * * @author Kevin Seguin - * @version $Revision: 1.12 $ $Date: 2002/02/07 00:44:40 $ + * @version $Revision: 1.13 $ $Date: 2002/02/15 21:13:19 $ */ @@ -273,6 +273,14 @@ private String secret = null; + +/** + * Tomcat authentication flag. If true, the authnetication is done by + * Tomcat, otherwise, it is done by the native webserver. + */ +private boolean tomcatAuthentication = true; + + // - Properties @@ -623,6 +631,7 @@ } + /** * Returns the codeService/code with which we are associated. */ @@ -630,12 +639,30 @@ return service; } + /** * Set the codeService/code with which we are associated. */ public void setService(Service service) { this.service = service; } + + +/** + * Get the value of the tomcatAuthentication flag. + */ +public boolean getTomcatAuthentication() { +return tomcatAuthentication; +} + + +/** + * Set the value of the tomcatAuthentication flag. + */ +public void setTomcatAuthentication(boolean tomcatAuthentication) { +this.tomcatAuthentication = tomcatAuthentication; +} + // - Public Methods 1.8 +3 -3 jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Request.java Index: Ajp13Request.java === RCS file: /home/cvs/jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Request.java,v retrieving revision 1.7 retrieving revision 1.8 diff -u -r1.7 -r1.8 --- Ajp13Request.java 15 Feb 2002 00:54:43 - 1.7 +++ Ajp13Request.java 15 Feb 2002 21:13:19 - 1.8 @@ -112,9 +112,9 @@ setServerName(ajp.serverName().toString()); setServerPort(ajp.getServerPort()); -String remoteUser = ajp.remoteUser().toString(); -if ((remoteUser != null) (!(remoteUser.equals( { -setUserPrincipal(new Ajp13Principal(remoteUser)); +if ((!(((Ajp13Connector) connector).getTomcatAuthentication())) + (ajp.remoteUser() != null)) { +setUserPrincipal(new Ajp13Principal(ajp.remoteUser().toString())); } else { setUserPrincipal(null); } -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
cvs commit: jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4 Ajp13Connector.java Ajp13Processor.java
costin 02/02/06 16:44:40 Modified:jk/java/org/apache/ajp/tomcat4 Ajp13Connector.java Ajp13Processor.java Log: Added the 'secret' attribute to Ajp13Connector. If not set, nothing changes in the request processing. If set - tomcat will require a password on incoming connections ( i.e. a secret to be set in the ajp worker ). This is of course a new/experimental feature, not documented, etc - use on your own risk ( I'm still testing it ) ( I'll check in the 3.3 version later, I hope it'll make it in 3.3.1 ) Revision ChangesPath 1.12 +13 -4 jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Connector.java Index: Ajp13Connector.java === RCS file: /home/cvs/jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Connector.java,v retrieving revision 1.11 retrieving revision 1.12 diff -u -r1.11 -r1.12 --- Ajp13Connector.java 10 Jan 2002 02:53:40 - 1.11 +++ Ajp13Connector.java 7 Feb 2002 00:44:40 - 1.12 @@ -1,7 +1,7 @@ /* - * $Header: /home/cvs/jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Connector.java,v 1.11 2002/01/10 02:53:40 seguin Exp $ - * $Revision: 1.11 $ - * $Date: 2002/01/10 02:53:40 $ + * $Header: /home/cvs/jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Connector.java,v 1.12 2002/02/07 00:44:40 costin Exp $ + * $Revision: 1.12 $ + * $Date: 2002/02/07 00:44:40 $ * * * @@ -93,7 +93,7 @@ * Implementation of an Ajp13 connector. * * @author Kevin Seguin - * @version $Revision: 1.11 $ $Date: 2002/01/10 02:53:40 $ + * @version $Revision: 1.12 $ $Date: 2002/02/07 00:44:40 $ */ @@ -271,6 +271,7 @@ */ private Service service = null; +private String secret = null; // - Properties @@ -296,6 +297,14 @@ } +public void setSecret( String s ) { +secret=s; +} + +public String getSecret() { +return secret; +} + /** * Return the accept count for this Connector. 1.7 +23 -4 jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Processor.java Index: Ajp13Processor.java === RCS file: /home/cvs/jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Processor.java,v retrieving revision 1.6 retrieving revision 1.7 diff -u -r1.6 -r1.7 --- Ajp13Processor.java 10 Jan 2002 03:03:59 - 1.6 +++ Ajp13Processor.java 7 Feb 2002 00:44:40 - 1.7 @@ -1,7 +1,7 @@ /* - * $Header: /home/cvs/jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Processor.java,v 1.6 2002/01/10 03:03:59 seguin Exp $ - * $Revision: 1.6 $ - * $Date: 2002/01/10 03:03:59 $ + * $Header: /home/cvs/jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Processor.java,v 1.7 2002/02/07 00:44:40 costin Exp $ + * $Revision: 1.7 $ + * $Date: 2002/02/07 00:44:40 $ * * * @@ -102,7 +102,7 @@ /** * @author Kevin Seguin - * @version $Revision: 1.6 $ $Date: 2002/01/10 03:03:59 $ + * @version $Revision: 1.7 $ $Date: 2002/02/07 00:44:40 $ */ final class Ajp13Processor @@ -360,6 +360,10 @@ } boolean moreRequests = true; +String expectedSecret=connector.getSecret(); + +boolean needAuth= ( expectedSecret != null ); + while (moreRequests !stopped.value()) { int status = 0; @@ -369,6 +373,21 @@ logger.log(process: ajp13.receiveNextRequest, e); } +if( needAuth ) { +String connSecret=ajp13.getSecret(); +if( connSecret == null ) { +logger.log( Connection without password, + +tomcat is configured to require one ); +break; +} +if( ! connSecret.equals(expectedSecret) ) { +logger.log( Connection with wrong password ); +break; +} + +needAuth=false; +} + if (stopped.value()) { if (debug 0) { logger.log(process: received request, but we're stopped); -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: cvs commit: jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4 Ajp13Connector.java Ajp13Processor.java
Any idea how soon? Larry -Original Message- From: [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: Wed 2/6/2002 7:44 PM To: [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] Cc: Subject: cvs commit: jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4 Ajp13Connector.java Ajp13Processor.java costin 02/02/06 16:44:40 Modified:jk/java/org/apache/ajp/tomcat4 Ajp13Connector.java Ajp13Processor.java Log: Added the 'secret' attribute to Ajp13Connector. If not set, nothing changes in the request processing. If set - tomcat will require a password on incoming connections ( i.e. a secret to be set in the ajp worker ). This is of course a new/experimental feature, not documented, etc - use on your own risk ( I'm still testing it ) ( I'll check in the 3.3 version later, I hope it'll make it in 3.3.1 ) msg21451/bin0.bin Description: application/ms-tnef -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: cvs commit: jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4 Ajp13Connector.java Ajp13Processor.java
On Wed, 6 Feb 2002, Larry Isaacs wrote: Any idea how soon? Done. I hope it doesn't delay any plans, the code shouldn't affect any previous behavior. Costin -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
cvs commit: jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4 Ajp13Connector.java
seguin 02/01/09 18:53:40 Modified:jk/java/org/apache/ajp/tomcat4 Ajp13Connector.java Log: if the connector has been stopped, don't reopen server socket when an IOException is thrown. Revision ChangesPath 1.11 +18 -6 jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Connector.java Index: Ajp13Connector.java === RCS file: /home/cvs/jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Connector.java,v retrieving revision 1.10 retrieving revision 1.11 diff -u -r1.10 -r1.11 --- Ajp13Connector.java 20 Dec 2001 17:44:51 - 1.10 +++ Ajp13Connector.java 10 Jan 2002 02:53:40 - 1.11 @@ -1,7 +1,7 @@ /* - * $Header: /home/cvs/jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Connector.java,v 1.10 2001/12/20 17:44:51 jfclere Exp $ - * $Revision: 1.10 $ - * $Date: 2001/12/20 17:44:51 $ + * $Header: /home/cvs/jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Connector.java,v 1.11 2002/01/10 02:53:40 seguin Exp $ + * $Revision: 1.11 $ + * $Date: 2002/01/10 02:53:40 $ * * * @@ -93,7 +93,7 @@ * Implementation of an Ajp13 connector. * * @author Kevin Seguin - * @version $Revision: 1.10 $ $Date: 2001/12/20 17:44:51 $ + * @version $Revision: 1.11 $ $Date: 2002/01/10 02:53:40 $ */ @@ -788,7 +788,8 @@ socket.setSoTimeout(connectionTimeout); } } catch (AccessControlException ace) { -logger.log(socket accept security exception: + ace.getMessage()); +logger.log(socket accept security exception: + + ace.getMessage()); continue; } catch (IOException e) { if (started !stopped) @@ -797,7 +798,18 @@ if (serverSocket != null) { serverSocket.close(); } -serverSocket = open(); +if (stopped) { +if (debug 0) { +logger.log(run(): stopped, so breaking); +} +break; +} else { +if (debug 0) { +logger.log(run(): not stopped, + + so reopening server socket); +} +serverSocket = open(); +} } catch (IOException ex) { // If reopening fails, exit logger.log(socket reopen: , ex); -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
cvs commit: jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4 Ajp13Connector.java Ajp13Processor.java
jfclere 01/12/20 09:44:51 Modified:jk/java/org/apache/ajp/tomcat4 Ajp13Connector.java Ajp13Processor.java Log: Arrange some of the 4.1 incompatibilties... Till where I am able to do it! - Please undo if needed - Revision ChangesPath 1.10 +12 -4 jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Connector.java Index: Ajp13Connector.java === RCS file: /home/cvs/jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Connector.java,v retrieving revision 1.9 retrieving revision 1.10 diff -u -r1.9 -r1.10 --- Ajp13Connector.java 2001/10/31 08:10:29 1.9 +++ Ajp13Connector.java 2001/12/20 17:44:51 1.10 @@ -1,7 +1,7 @@ /* - * $Header: /home/cvs/jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Connector.java,v 1.9 2001/10/31 08:10:29 jfclere Exp $ - * $Revision: 1.9 $ - * $Date: 2001/10/31 08:10:29 $ + * $Header: /home/cvs/jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Connector.java,v 1.10 2001/12/20 17:44:51 jfclere Exp $ + * $Revision: 1.10 $ + * $Date: 2001/12/20 17:44:51 $ * * * @@ -93,7 +93,7 @@ * Implementation of an Ajp13 connector. * * @author Kevin Seguin - * @version $Revision: 1.9 $ $Date: 2001/10/31 08:10:29 $ + * @version $Revision: 1.10 $ $Date: 2001/12/20 17:44:51 $ */ @@ -877,6 +877,14 @@ lifecycle.addLifecycleListener(listener); +} + +/** + * Get the lifecycle listeners associated with this lifecycle. If this + * Lifecycle has no listeners registered, a zero-length array is returned. + */ +public LifecycleListener[] findLifecycleListeners() { +return null; // FIXME: lifecycle.findLifecycleListeners(); } 1.5 +12 -4 jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Processor.java Index: Ajp13Processor.java === RCS file: /home/cvs/jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Processor.java,v retrieving revision 1.4 retrieving revision 1.5 diff -u -r1.4 -r1.5 --- Ajp13Processor.java 2001/11/26 16:56:19 1.4 +++ Ajp13Processor.java 2001/12/20 17:44:51 1.5 @@ -1,7 +1,7 @@ /* - * $Header: /home/cvs/jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Processor.java,v 1.4 2001/11/26 16:56:19 costin Exp $ - * $Revision: 1.4 $ - * $Date: 2001/11/26 16:56:19 $ + * $Header: /home/cvs/jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Processor.java,v 1.5 2001/12/20 17:44:51 jfclere Exp $ + * $Revision: 1.5 $ + * $Date: 2001/12/20 17:44:51 $ * * * @@ -102,7 +102,7 @@ /** * @author Kevin Seguin - * @version $Revision: 1.4 $ $Date: 2001/11/26 16:56:19 $ + * @version $Revision: 1.5 $ $Date: 2001/12/20 17:44:51 $ */ final class Ajp13Processor @@ -486,6 +486,14 @@ lifecycle.addLifecycleListener(listener); +} + +/** + * Get the lifecycle listeners associated with this lifecycle. If this + * Lifecycle has no listeners registered, a zero-length array is returned. + */ +public LifecycleListener[] findLifecycleListeners() { +return null; // FIXME: lifecycle.findLifecycleListeners(); } -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
cvs commit: jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4 Ajp13Connector.java
keith 01/08/27 08:21:43 Modified:jk/java/org/apache/ajp/tomcat4 Ajp13Connector.java Log: Update implementation to reflect Connector interface change. Revision ChangesPath 1.5 +22 -5 jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Connector.java Index: Ajp13Connector.java === RCS file: /home/cvs/jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Connector.java,v retrieving revision 1.4 retrieving revision 1.5 diff -u -r1.4 -r1.5 --- Ajp13Connector.java 2001/07/25 14:49:51 1.4 +++ Ajp13Connector.java 2001/08/27 15:21:43 1.5 @@ -83,6 +83,7 @@ import org.apache.catalina.Logger; import org.apache.catalina.Request; import org.apache.catalina.Response; +import org.apache.catalina.Service; import org.apache.catalina.net.DefaultServerSocketFactory; import org.apache.catalina.net.ServerSocketFactory; import org.apache.catalina.util.LifecycleSupport; @@ -265,7 +266,10 @@ private Ajp13Logger logger = new Ajp13Logger(); - +/** + * The service which which the connector is associated + */ +private Service service = null; // - Properties @@ -610,6 +614,19 @@ } +/** + * Returns the codeService/code with which we are associated. + */ +public Service getService() { + return service; +} + +/** + * Set the codeService/code with which we are associated. + */ +public void setService(Service service) { + this.service = service; +} // - Public Methods
cvs commit: jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4 Ajp13Connector.java
jfclere 01/07/25 07:49:51 Modified:jk/java/org/apache/ajp/tomcat4 Ajp13Connector.java Log: Add initialize method due to changes in catalina/src/share/org/apache/catalina/Connector.java Revision ChangesPath 1.4 +12 -4 jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Connector.java Index: Ajp13Connector.java === RCS file: /home/cvs/jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Connector.java,v retrieving revision 1.3 retrieving revision 1.4 diff -u -r1.3 -r1.4 --- Ajp13Connector.java 2001/05/15 15:22:42 1.3 +++ Ajp13Connector.java 2001/07/25 14:49:51 1.4 @@ -1,7 +1,7 @@ /* - * $Header: /home/cvs/jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Connector.java,v 1.3 2001/05/15 15:22:42 seguin Exp $ - * $Revision: 1.3 $ - * $Date: 2001/05/15 15:22:42 $ + * $Header: /home/cvs/jakarta-tomcat-connectors/jk/java/org/apache/ajp/tomcat4/Ajp13Connector.java,v 1.4 2001/07/25 14:49:51 jfclere Exp $ + * $Revision: 1.4 $ + * $Date: 2001/07/25 14:49:51 $ * * * @@ -92,7 +92,7 @@ * Implementation of an Ajp13 connector. * * @author Kevin Seguin - * @version $Revision: 1.3 $ $Date: 2001/05/15 15:22:42 $ + * @version $Revision: 1.4 $ $Date: 2001/07/25 14:49:51 $ */ @@ -637,6 +637,14 @@ response.setConnector(this); return (response); +} + +/** + * Invoke a pre-startup initialization. This is used to allow connectors + * to bind to restricted ports under Unix operating environments. + * ServerSocket (we start as root and change user? or I miss something?). + */ +public void initialize() throws LifecycleException { }