From 9401f816dd0d9d550fe98a8507224bde51c4b847 Mon Sep 17 00:00:00 2001 From: hongbotian Date: Mon, 30 Nov 2015 02:41:33 -0500 Subject: [PATCH] upload tomcat JIRA: BOTTLENECK-7 Change-Id: I875d474869efd76ca203c30b60ebc0c3ee606d0e Signed-off-by: hongbotian --- rubbos/app/tomcat-connectors-1.2.32-src/BUILD.txt | 34 + rubbos/app/tomcat-connectors-1.2.32-src/LICENSE | 252 + rubbos/app/tomcat-connectors-1.2.32-src/NOTICE | 8 + .../conf/httpd-jk.conf | 127 + .../conf/uriworkermap.properties | 39 + .../conf/workers.properties | 165 + .../conf/workers.properties.minimal | 45 + .../docs/ajp/ajpv13a.html | 654 + .../docs/ajp/ajpv13ext.html | 654 + .../docs/ajp/printer/ajpv13a.html | 653 + .../docs/ajp/printer/ajpv13ext.html | 653 + .../docs/generic_howto/loadbalancers.html | 207 + .../docs/generic_howto/printer/loadbalancers.html | 206 + .../docs/generic_howto/printer/proxy.html | 312 + .../docs/generic_howto/printer/quick.html | 130 + .../docs/generic_howto/printer/timeouts.html | 373 + .../docs/generic_howto/printer/workers.html | 408 + .../docs/generic_howto/proxy.html | 313 + .../docs/generic_howto/quick.html | 131 + .../docs/generic_howto/timeouts.html | 374 + .../docs/generic_howto/workers.html | 409 + .../docs/images/add.gif | Bin 0 -> 1037 bytes .../docs/images/code.gif | Bin 0 -> 394 bytes .../docs/images/design.gif | Bin 0 -> 608 bytes .../docs/images/docs.gif | Bin 0 -> 261 bytes .../docs/images/fix.gif | Bin 0 -> 345 bytes .../docs/images/jakarta-logo.gif | Bin 0 -> 8584 bytes .../docs/images/printer.gif | Bin 0 -> 438 bytes .../docs/images/tomcat.gif | Bin 0 -> 2066 bytes .../docs/images/update.gif | Bin 0 -> 627 bytes .../docs/images/void.gif | Bin 0 -> 43 bytes .../tomcat-connectors-1.2.32-src/docs/index.html | 251 + .../docs/miscellaneous/changelog.html | 2096 ++ .../docs/miscellaneous/doccontrib.html | 249 + .../docs/miscellaneous/faq.html | 281 + .../docs/miscellaneous/jkstatustasks.html | 184 + .../docs/miscellaneous/printer/changelog.html | 2095 ++ .../docs/miscellaneous/printer/doccontrib.html | 248 + .../docs/miscellaneous/printer/faq.html | 280 + .../docs/miscellaneous/printer/jkstatustasks.html | 183 + .../docs/miscellaneous/printer/reporttools.html | 61 + .../docs/miscellaneous/reporttools.html | 62 + .../docs/news/20041100.html | 126 + .../docs/news/20050101.html | 139 + .../docs/news/20060101.html | 80 + .../docs/news/20070301.html | 87 + .../docs/news/20081001.html | 158 + .../docs/news/20090301.html | 63 + .../docs/news/20100101.html | 62 + .../docs/news/20110701.html | 22 + .../docs/news/printer/20041100.html | 125 + .../docs/news/printer/20050101.html | 138 + .../docs/news/printer/20060101.html | 79 + .../docs/news/printer/20070301.html | 86 + .../docs/news/printer/20081001.html | 157 + .../docs/news/printer/20090301.html | 62 + .../docs/news/printer/20100101.html | 61 + .../docs/news/printer/20110701.html | 21 + .../docs/printer/index.html | 250 + .../docs/reference/apache.html | 1011 + .../docs/reference/iis.html | 332 + .../docs/reference/printer/apache.html | 1010 + .../docs/reference/printer/iis.html | 331 + .../docs/reference/printer/status.html | 546 + .../docs/reference/printer/uriworkermap.html | 377 + .../docs/reference/printer/workers.html | 1000 + .../docs/reference/status.html | 547 + .../docs/reference/uriworkermap.html | 378 + .../docs/reference/workers.html | 1001 + .../tomcat-connectors-1.2.32-src/docs/style.css | 73 + .../docs/webserver_howto/apache.html | 1124 + .../docs/webserver_howto/iis.html | 685 + .../docs/webserver_howto/nes.html | 483 + .../docs/webserver_howto/printer/apache.html | 1123 + .../docs/webserver_howto/printer/iis.html | 684 + .../docs/webserver_howto/printer/nes.html | 482 + .../jkstatus/build.properties.default | 22 + .../jkstatus/build.xml | 155 + .../jkstatus/conf/jkstatus-tasks.xml | 41 + .../jkstatus/example/jkstatus.properties.default | 23 + .../jkstatus/example/jkstatus.xml | 111 + .../jkstatus/example/show.txt | 25 + .../jkstatus/example/show.xml | 49 + .../org/apache/jk/status/AbstractJkStatusTask.java | 209 + .../src/share/org/apache/jk/status/JkBalancer.java | 335 + .../org/apache/jk/status/JkBalancerMapping.java | 98 + .../org/apache/jk/status/JkBalancerMember.java | 516 + .../src/share/org/apache/jk/status/JkResult.java | 54 + .../src/share/org/apache/jk/status/JkServer.java | 56 + .../src/share/org/apache/jk/status/JkSoftware.java | 54 + .../src/share/org/apache/jk/status/JkStatus.java | 90 + .../org/apache/jk/status/JkStatusAccessor.java | 133 + .../share/org/apache/jk/status/JkStatusParser.java | 228 + .../org/apache/jk/status/JkStatusResetTask.java | 133 + .../share/org/apache/jk/status/JkStatusTask.java | 735 + .../jk/status/JkStatusUpdateLoadbalancerTask.java | 307 + .../org/apache/jk/status/JkStatusUpdateTask.java | 529 + .../apache/jk/status/JkStatusUpdateWorkerTask.java | 291 + .../org/apache/jk/status/LocalStrings.properties | 15 + .../src/share/org/apache/jk/status/antlib.xml | 34 + .../src/share/org/apache/jk/status/jkstatus.tasks | 22 + .../org/apache/jk/status/mbeans-descriptors.xml | 48 + .../src/share/org/apache/jk/status/package.html | 224 + .../jkstatus/test/build.xml | 120 + .../jkstatus/test/conf/jkstatus.xml | 31 + .../jkstatus/test/conf/log4j.xml | 76 + .../org/apache/jk/status/JkStatusParserTest.java | 63 + .../native/BUILDING.txt | 179 + .../tomcat-connectors-1.2.32-src/native/CHANGES | 1162 + .../tomcat-connectors-1.2.32-src/native/Makefile | 702 + .../native/Makefile.am | 37 + .../native/Makefile.in | 702 + .../app/tomcat-connectors-1.2.32-src/native/NEWS | 638 + .../tomcat-connectors-1.2.32-src/native/README.txt | 45 + .../tomcat-connectors-1.2.32-src/native/STATUS.txt | 67 + .../tomcat-connectors-1.2.32-src/native/TODO.txt | 371 + .../tomcat-connectors-1.2.32-src/native/aclocal.m4 | 6945 +++++ .../native/apache-1.3/Makefile | 114 + .../native/apache-1.3/Makefile.apxs | 42 + .../native/apache-1.3/Makefile.apxs.in | 42 + .../native/apache-1.3/Makefile.in | 114 + .../native/apache-1.3/Makefile.libdir | 4 + .../native/apache-1.3/Makefile.netware | 287 + .../native/apache-1.3/Makefile.tmpl | 53 + .../native/apache-1.3/Makefile.vc | 256 + .../native/apache-1.3/NWGNUmakefile | 44 + .../native/apache-1.3/NWGNUmakefile.mak | 313 + .../native/apache-1.3/libjk.module | 5 + .../native/apache-1.3/mod_jk.c | 3338 +++ .../native/apache-1.3/mod_jk.dsp | 295 + .../native/apache-1.3/mod_jk.exp | 1 + .../native/apache-2.0/.libs/mod_jk.a | Bin 0 -> 2614540 bytes .../native/apache-2.0/.libs/mod_jk.la | 35 + .../native/apache-2.0/.libs/mod_jk.lai | 35 + .../native/apache-2.0/.libs/mod_jk.o | Bin 0 -> 323776 bytes .../native/apache-2.0/.libs/mod_jk.so | Bin 0 -> 1377048 bytes .../native/apache-2.0/Makefile | 99 + .../native/apache-2.0/Makefile.apxs | 45 + .../native/apache-2.0/Makefile.apxs.in | 45 + .../native/apache-2.0/Makefile.in | 99 + .../native/apache-2.0/Makefile.vc | 293 + .../native/apache-2.0/NWGNUmakefile | 332 + .../native/apache-2.0/bldjk.qclsrc | 291 + .../native/apache-2.0/bldjk54.qclsrc | 313 + .../native/apache-2.0/config.m4 | 34 + .../native/apache-2.0/mod_jk.a | Bin 0 -> 2614540 bytes .../native/apache-2.0/mod_jk.c | 3748 +++ .../native/apache-2.0/mod_jk.dsp | 355 + .../native/apache-2.0/mod_jk.la | 35 + .../native/apache-2.0/mod_jk.lo | 12 + .../native/apache-2.0/mod_jk.o | Bin 0 -> 316024 bytes .../native/apache-2.0/mod_jk.so | Bin 0 -> 1377048 bytes .../native/buildconf.sh | 36 + .../native/common/.indent.pro | 18 + .../native/common/.libs/jk_ajp12_worker.o | Bin 0 -> 72992 bytes .../native/common/.libs/jk_ajp13.o | Bin 0 -> 11264 bytes .../native/common/.libs/jk_ajp13_worker.o | Bin 0 -> 35280 bytes .../native/common/.libs/jk_ajp14.o | Bin 0 -> 74416 bytes .../native/common/.libs/jk_ajp14_worker.o | Bin 0 -> 70736 bytes .../native/common/.libs/jk_ajp_common.o | Bin 0 -> 291472 bytes .../native/common/.libs/jk_connect.o | Bin 0 -> 84960 bytes .../native/common/.libs/jk_context.o | Bin 0 -> 19080 bytes .../native/common/.libs/jk_jni_worker.o | Bin 0 -> 16128 bytes .../native/common/.libs/jk_lb_worker.o | Bin 0 -> 172368 bytes .../native/common/.libs/jk_map.o | Bin 0 -> 83792 bytes .../native/common/.libs/jk_md5.o | Bin 0 -> 20208 bytes .../native/common/.libs/jk_msg_buff.o | Bin 0 -> 23520 bytes .../native/common/.libs/jk_pool.o | Bin 0 -> 13048 bytes .../native/common/.libs/jk_shm.o | Bin 0 -> 60272 bytes .../native/common/.libs/jk_sockbuf.o | Bin 0 -> 13680 bytes .../native/common/.libs/jk_status.o | Bin 0 -> 828736 bytes .../native/common/.libs/jk_uri_worker_map.o | Bin 0 -> 126944 bytes .../native/common/.libs/jk_url.o | Bin 0 -> 9312 bytes .../native/common/.libs/jk_util.o | Bin 0 -> 244016 bytes .../native/common/.libs/jk_worker.o | Bin 0 -> 55776 bytes .../native/common/Makefile | 49 + .../native/common/Makefile.in | 49 + .../native/common/ap_snprintf.c | 1178 + .../native/common/ap_snprintf.h | 150 + .../native/common/config.h | 110 + .../native/common/config.h.in | 109 + .../native/common/jk.rc | 74 + .../native/common/jk_ajp12_worker.c | 682 + .../native/common/jk_ajp12_worker.h | 45 + .../native/common/jk_ajp12_worker.lo | 12 + .../native/common/jk_ajp12_worker.o | Bin 0 -> 71160 bytes .../native/common/jk_ajp13.c | 50 + .../native/common/jk_ajp13.h | 126 + .../native/common/jk_ajp13.lo | 12 + .../native/common/jk_ajp13.o | Bin 0 -> 11104 bytes .../native/common/jk_ajp13_worker.c | 94 + .../native/common/jk_ajp13_worker.h | 50 + .../native/common/jk_ajp13_worker.lo | 12 + .../native/common/jk_ajp13_worker.o | Bin 0 -> 35184 bytes .../native/common/jk_ajp14.c | 695 + .../native/common/jk_ajp14.h | 307 + .../native/common/jk_ajp14.lo | 12 + .../native/common/jk_ajp14.o | Bin 0 -> 73016 bytes .../native/common/jk_ajp14_worker.c | 404 + .../native/common/jk_ajp14_worker.h | 52 + .../native/common/jk_ajp14_worker.lo | 12 + .../native/common/jk_ajp14_worker.o | Bin 0 -> 69632 bytes .../native/common/jk_ajp_common.c | 3383 +++ .../native/common/jk_ajp_common.h | 467 + .../native/common/jk_ajp_common.lo | 12 + .../native/common/jk_ajp_common.o | Bin 0 -> 283648 bytes .../native/common/jk_connect.c | 1190 + .../native/common/jk_connect.h | 78 + .../native/common/jk_connect.lo | 12 + .../native/common/jk_connect.o | Bin 0 -> 83736 bytes .../native/common/jk_context.c | 296 + .../native/common/jk_context.h | 138 + .../native/common/jk_context.lo | 12 + .../native/common/jk_context.o | Bin 0 -> 19176 bytes .../native/common/jk_global.h | 405 + .../native/common/jk_jni_worker.c | 1267 + .../native/common/jk_jni_worker.h | 45 + .../native/common/jk_jni_worker.lo | 12 + .../native/common/jk_jni_worker.o | Bin 0 -> 15984 bytes .../native/common/jk_lb_worker.c | 1823 ++ .../native/common/jk_lb_worker.h | 222 + .../native/common/jk_lb_worker.lo | 12 + .../native/common/jk_lb_worker.o | Bin 0 -> 170152 bytes .../native/common/jk_logger.h | 139 + .../native/common/jk_map.c | 889 + .../native/common/jk_map.h | 95 + .../native/common/jk_map.lo | 12 + .../native/common/jk_map.o | Bin 0 -> 90080 bytes .../native/common/jk_md5.c | 475 + .../native/common/jk_md5.h | 84 + .../native/common/jk_md5.lo | 12 + .../native/common/jk_md5.o | Bin 0 -> 20768 bytes .../native/common/jk_msg_buff.c | 382 + .../native/common/jk_msg_buff.h | 154 + .../native/common/jk_msg_buff.lo | 12 + .../native/common/jk_msg_buff.o | Bin 0 -> 24304 bytes .../native/common/jk_mt.h | 150 + .../native/common/jk_nwmain.c | 103 + .../native/common/jk_pool.c | 165 + .../native/common/jk_pool.h | 126 + .../native/common/jk_pool.lo | 12 + .../native/common/jk_pool.o | Bin 0 -> 12968 bytes .../native/common/jk_service.h | 546 + .../native/common/jk_shm.c | 812 + .../native/common/jk_shm.h | 258 + .../native/common/jk_shm.lo | 12 + .../native/common/jk_shm.o | Bin 0 -> 59384 bytes .../native/common/jk_sockbuf.c | 195 + .../native/common/jk_sockbuf.h | 45 + .../native/common/jk_sockbuf.lo | 12 + .../native/common/jk_sockbuf.o | Bin 0 -> 13624 bytes .../native/common/jk_status.c | 5200 ++++ .../native/common/jk_status.h | 44 + .../native/common/jk_status.lo | 12 + .../native/common/jk_status.o | Bin 0 -> 806096 bytes .../native/common/jk_types.h | 69 + .../native/common/jk_types.h.in | 69 + .../native/common/jk_uri_worker_map.c | 1191 + .../native/common/jk_uri_worker_map.h | 208 + .../native/common/jk_uri_worker_map.lo | 12 + .../native/common/jk_uri_worker_map.o | Bin 0 -> 124368 bytes .../native/common/jk_url.c | 124 + .../native/common/jk_url.h | 44 + .../native/common/jk_url.lo | 12 + .../native/common/jk_url.o | Bin 0 -> 9200 bytes .../native/common/jk_util.c | 2253 ++ .../native/common/jk_util.h | 269 + .../native/common/jk_util.lo | 12 + .../native/common/jk_util.o | Bin 0 -> 243024 bytes .../native/common/jk_version.h | 96 + .../native/common/jk_worker.c | 351 + .../native/common/jk_worker.h | 55 + .../native/common/jk_worker.lo | 12 + .../native/common/jk_worker.o | Bin 0 -> 54176 bytes .../native/common/jk_worker_list.h | 98 + .../native/common/list.mk | 27 + .../native/common/list.mk.in | 27 + .../native/common/stamp-h1 | 1 + .../tomcat-connectors-1.2.32-src/native/config.log | 1840 ++ .../native/config.nice | 9 + .../native/config.status | 1277 + .../tomcat-connectors-1.2.32-src/native/configure | 25887 +++++++++++++++++++ .../native/configure.in | 852 + .../native/docs/api/README.txt | 18 + .../native/iis/Makefile.amd64 | 310 + .../native/iis/Makefile.ia64 | 310 + .../native/iis/Makefile.x86 | 304 + .../tomcat-connectors-1.2.32-src/native/iis/README | 43 + .../native/iis/installer/LICENSE.TXT | 201 + .../native/iis/installer/License.rtf | 72 + .../native/iis/installer/bin/README | 1 + .../native/iis/installer/conf/rewrite.properties | 28 + .../iis/installer/conf/uriworkermap.properties | 39 + .../iis/installer/conf/workers.properties.minimal | 45 + .../native/iis/installer/iisfilter.vbs | 120 + .../iis/installer/isapi-redirector-win32-msi.ism | 4773 ++++ .../native/iis/installer/log/README | 1 + .../native/iis/installer/tomcat.ico | Bin 0 -> 21630 bytes .../native/iis/isapi.def | 24 + .../native/iis/isapi.dsp | 307 + .../native/iis/isapi.dsw | 59 + .../native/iis/isapi_install.vbs | 224 + .../native/iis/isapi_redirect.reg | 7 + .../native/iis/jk_isapi_plugin.c | 3495 +++ .../native/iis/pcre/AUTHORS | 6 + .../native/iis/pcre/COPYING | 45 + .../native/iis/pcre/ChangeLog | 1650 ++ .../native/iis/pcre/INSTALL | 185 + .../native/iis/pcre/LICENCE | 45 + .../native/iis/pcre/Makefile.in | 20 + .../native/iis/pcre/NEWS | 201 + .../native/iis/pcre/NON-UNIX-USE | 244 + .../native/iis/pcre/NWGNUmakefile | 267 + .../native/iis/pcre/README | 427 + .../native/iis/pcre/RunTest.in | 192 + .../native/iis/pcre/config.hw | 107 + .../native/iis/pcre/config.in | 107 + .../native/iis/pcre/configure.in | 185 + .../native/iis/pcre/dftables.c | 173 + .../native/iis/pcre/dftables.dsp | 165 + .../native/iis/pcre/dftables.x86 | 109 + .../native/iis/pcre/dll.mk | 60 + .../native/iis/pcre/doc/README_httpd | 6 + .../native/iis/pcre/get.c | 357 + .../native/iis/pcre/install-sh | 251 + .../native/iis/pcre/internal.h | 752 + .../native/iis/pcre/libpcre.def | 34 + .../native/iis/pcre/libpcre.pc.in | 12 + .../native/iis/pcre/libpcreposix.def | 39 + .../native/iis/pcre/maketables.c | 146 + .../native/iis/pcre/makevp.bat | 25 + .../native/iis/pcre/mkinstalldirs | 40 + .../native/iis/pcre/pcre-config.in | 66 + .../native/iis/pcre/pcre.amd64 | 146 + .../native/iis/pcre/pcre.c | 9207 +++++++ .../native/iis/pcre/pcre.def | 22 + .../native/iis/pcre/pcre.dsp | 193 + .../native/iis/pcre/pcre.hw | 239 + .../native/iis/pcre/pcre.ia64 | 147 + .../native/iis/pcre/pcre.in | 239 + .../native/iis/pcre/pcre.x86 | 154 + .../native/iis/pcre/pcredemo.c | 324 + .../native/iis/pcre/pcregrep.c | 673 + .../native/iis/pcre/pcreposix.c | 316 + .../native/iis/pcre/pcreposix.dsp | 154 + .../native/iis/pcre/pcreposix.h | 99 + .../native/iis/pcre/pcretest.c | 1786 ++ .../native/iis/pcre/perltest | 211 + .../native/iis/pcre/perltest8 | 208 + .../native/iis/pcre/pgrep.c | 225 + .../native/iis/pcre/printint.c | 471 + .../native/iis/pcre/study.c | 484 + .../native/iis/pcre/testdata/testinput1 | 3841 +++ .../native/iis/pcre/testdata/testinput2 | 1396 + .../native/iis/pcre/testdata/testinput3 | 65 + .../native/iis/pcre/testdata/testinput4 | 513 + .../native/iis/pcre/testdata/testinput5 | 263 + .../native/iis/pcre/testdata/testinput6 | 517 + .../native/iis/pcre/testdata/testoutput1 | 6274 +++++ .../native/iis/pcre/testdata/testoutput2 | 5607 ++++ .../native/iis/pcre/testdata/testoutput3 | 115 + .../native/iis/pcre/testdata/testoutput4 | 903 + .../native/iis/pcre/testdata/testoutput5 | 1075 + .../native/iis/pcre/testdata/testoutput6 | 1013 + .../native/iis/pcre/ucp.c | 151 + .../native/iis/pcre/ucp.h | 58 + .../native/iis/pcre/ucpinternal.h | 91 + .../native/iis/pcre/ucptable.c | 15105 +++++++++++ .../native/iis/pcre/ucptypetable.c | 93 + .../native/jni/.libs/jk_jnicb.a | Bin 0 -> 365752 bytes .../native/jni/.libs/jk_jnicb.la | 35 + .../native/jni/.libs/jk_jnicb.lai | 35 + .../native/jni/.libs/jk_jnicb.o | Bin 0 -> 16048 bytes .../native/jni/.libs/jk_jnicb.so | Bin 0 -> 251337 bytes .../native/jni/Makefile | 45 + .../native/jni/Makefile.in | 45 + .../native/jni/Makefile.linux | 46 + .../native/jni/Makefile.netware | 266 + .../native/jni/Makefile.solaris | 45 + .../native/jni/jk_jnicb.a | Bin 0 -> 365752 bytes .../native/jni/jk_jnicb.c | 495 + .../native/jni/jk_jnicb.exp | 7 + .../native/jni/jk_jnicb.h | 61 + .../native/jni/jk_jnicb.la | 35 + .../native/jni/jk_jnicb.lo | 12 + .../native/jni/jk_jnicb.o | Bin 0 -> 15784 bytes .../native/jni/jk_jnicb.so | Bin 0 -> 251337 bytes .../native/jni/jni_connect.dsp | 151 + .../tomcat-connectors-1.2.32-src/native/libtool | 7065 +++++ .../native/netscape/Makefile.linux | 59 + .../native/netscape/Makefile.netware | 277 + .../native/netscape/Makefile.solaris | 85 + .../native/netscape/Makefile.vc | 287 + .../native/netscape/README | 31 + .../native/netscape/jk_nsapi_plugin.c | 634 + .../native/netscape/nsapi.dsp | 283 + .../native/nt_service/jk_nt_service.c | 1233 + .../native/nt_service/nt_service.dsp | 199 + .../native/scripts/build/config_vars.mk | 17 + .../native/scripts/build/instdso.sh | 91 + .../native/scripts/build/jk_common.m4 | 160 + .../native/scripts/build/rules.mk | 43 + .../native/scripts/build/unix/config.guess | 1447 ++ .../native/scripts/build/unix/config.sub | 1555 ++ .../native/scripts/build/unix/dummy | 0 .../native/scripts/build/unix/install-sh | 322 + .../native/scripts/build/unix/ltmain.sh | 6426 +++++ .../native/scripts/build/unix/missing | 353 + .../tomcat-connectors-1.2.32-src/support/apache.m4 | 213 + .../support/get_ver.awk | 83 + .../support/jk_apache_static.m4 | 133 + .../tomcat-connectors-1.2.32-src/support/jk_apr.m4 | 320 + .../support/jk_apxs.m4 | 150 + .../support/jk_dominohome.m4 | 74 + .../support/jk_exec.m4 | 91 + .../support/jk_java.m4 | 224 + .../support/jk_pcre.m4 | 40 + .../support/jk_tchome.m4 | 73 + .../tomcat-connectors-1.2.32-src/support/jk_ws.m4 | 229 + .../support/os_apache.m4 | 44 + .../tools/dist/.htaccess | 19 + .../tools/dist/HEADER.html | 20 + .../tools/dist/README.html | 68 + .../tools/dist/binaries/windows/HEADER.html | 12 + .../tools/dist/binaries/windows/README.html | 60 + .../dist/binaries/windows/symbols/HEADER.html | 11 + .../dist/binaries/windows/symbols/README.html | 25 + .../tools/jkbindist.sh | 153 + .../tools/jkrelease.sh | 327 + .../tomcat-connectors-1.2.32-src/tools/lineends.pl | 165 + .../tools/reports/README.txt | 33 + .../tools/reports/tomcat_reports.pl | 431 + .../tools/reports/tomcat_trend.pl | 408 + .../tomcat-connectors-1.2.32-src/tools/signfile.sh | 64 + .../xdocs/ajp/ajpv13a.xml | 698 + .../xdocs/ajp/ajpv13ext.xml | 686 + .../xdocs/ajp/project.xml | 81 + .../tomcat-connectors-1.2.32-src/xdocs/build.xml | 259 + .../tomcat-connectors-1.2.32-src/xdocs/empty.xml | 40 + .../xdocs/generic_howto/loadbalancers.xml | 236 + .../xdocs/generic_howto/project.xml | 81 + .../xdocs/generic_howto/proxy.xml | 347 + .../xdocs/generic_howto/quick.xml | 170 + .../xdocs/generic_howto/timeouts.xml | 407 + .../xdocs/generic_howto/workers.xml | 445 + .../xdocs/images/add.gif | Bin 0 -> 1037 bytes .../xdocs/images/code.gif | Bin 0 -> 394 bytes .../xdocs/images/design.gif | Bin 0 -> 608 bytes .../xdocs/images/docs.gif | Bin 0 -> 261 bytes .../xdocs/images/fix.gif | Bin 0 -> 345 bytes .../xdocs/images/jakarta-logo.gif | Bin 0 -> 8584 bytes .../xdocs/images/printer.gif | Bin 0 -> 438 bytes .../xdocs/images/tomcat.gif | Bin 0 -> 2066 bytes .../xdocs/images/update.gif | Bin 0 -> 627 bytes .../xdocs/images/void.gif | Bin 0 -> 43 bytes .../tomcat-connectors-1.2.32-src/xdocs/index.xml | 297 + .../xdocs/miscellaneous/changelog.xml | 2157 ++ .../xdocs/miscellaneous/doccontrib.xml | 337 + .../xdocs/miscellaneous/faq.xml | 324 + .../xdocs/miscellaneous/jkstatustasks.xml | 218 + .../xdocs/miscellaneous/project.xml | 81 + .../xdocs/miscellaneous/reporttools.xml | 91 + .../xdocs/news/20041100.xml | 161 + .../xdocs/news/20050101.xml | 174 + .../xdocs/news/20060101.xml | 110 + .../xdocs/news/20070301.xml | 117 + .../xdocs/news/20081001.xml | 188 + .../xdocs/news/20090301.xml | 93 + .../xdocs/news/20100101.xml | 93 + .../xdocs/news/20110701.xml | 53 + .../xdocs/news/project.xml | 81 + .../tomcat-connectors-1.2.32-src/xdocs/project.xml | 81 + .../xdocs/reference/apache.xml | 1119 + .../xdocs/reference/iis.xml | 387 + .../xdocs/reference/project.xml | 81 + .../xdocs/reference/status.xml | 584 + .../xdocs/reference/uriworkermap.xml | 422 + .../xdocs/reference/workers.xml | 1155 + .../tomcat-connectors-1.2.32-src/xdocs/style.css | 73 + .../tomcat-connectors-1.2.32-src/xdocs/style.xsl | 710 + .../xdocs/webserver_howto/apache.xml | 1287 + .../xdocs/webserver_howto/iis.xml | 729 + .../xdocs/webserver_howto/nes.xml | 521 + .../xdocs/webserver_howto/project.xml | 81 + 484 files changed, 219092 insertions(+) create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/BUILD.txt create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/LICENSE create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/NOTICE create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/conf/httpd-jk.conf create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/conf/uriworkermap.properties create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/conf/workers.properties create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/conf/workers.properties.minimal create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/ajp/ajpv13a.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/ajp/ajpv13ext.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/ajp/printer/ajpv13a.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/ajp/printer/ajpv13ext.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/loadbalancers.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/printer/loadbalancers.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/printer/proxy.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/printer/quick.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/printer/timeouts.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/printer/workers.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/proxy.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/quick.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/timeouts.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/workers.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/images/add.gif create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/images/code.gif create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/images/design.gif create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/images/docs.gif create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/images/fix.gif create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/images/jakarta-logo.gif create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/images/printer.gif create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/images/tomcat.gif create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/images/update.gif create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/images/void.gif create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/index.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/changelog.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/doccontrib.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/faq.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/jkstatustasks.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/printer/changelog.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/printer/doccontrib.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/printer/faq.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/printer/jkstatustasks.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/printer/reporttools.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/reporttools.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/news/20041100.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/news/20050101.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/news/20060101.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/news/20070301.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/news/20081001.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/news/20090301.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/news/20100101.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/news/20110701.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/news/printer/20041100.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/news/printer/20050101.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/news/printer/20060101.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/news/printer/20070301.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/news/printer/20081001.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/news/printer/20090301.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/news/printer/20100101.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/news/printer/20110701.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/printer/index.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/apache.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/iis.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/printer/apache.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/printer/iis.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/printer/status.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/printer/uriworkermap.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/printer/workers.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/status.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/uriworkermap.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/workers.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/style.css create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/webserver_howto/apache.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/webserver_howto/iis.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/webserver_howto/nes.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/webserver_howto/printer/apache.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/webserver_howto/printer/iis.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/docs/webserver_howto/printer/nes.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/build.properties.default create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/build.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/conf/jkstatus-tasks.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/example/jkstatus.properties.default create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/example/jkstatus.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/example/show.txt create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/example/show.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/AbstractJkStatusTask.java create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkBalancer.java create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkBalancerMapping.java create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkBalancerMember.java create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkResult.java create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkServer.java create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkSoftware.java create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkStatus.java create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkStatusAccessor.java create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkStatusParser.java create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkStatusResetTask.java create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkStatusTask.java create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkStatusUpdateLoadbalancerTask.java create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkStatusUpdateTask.java create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkStatusUpdateWorkerTask.java create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/LocalStrings.properties create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/antlib.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/jkstatus.tasks create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/mbeans-descriptors.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/package.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/test/build.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/test/conf/jkstatus.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/test/conf/log4j.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/test/src/share/org/apache/jk/status/JkStatusParserTest.java create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/BUILDING.txt create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/CHANGES create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/Makefile create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/Makefile.am create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/Makefile.in create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/NEWS create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/README.txt create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/STATUS.txt create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/TODO.txt create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/aclocal.m4 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-1.3/Makefile create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-1.3/Makefile.apxs create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-1.3/Makefile.apxs.in create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-1.3/Makefile.in create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-1.3/Makefile.libdir create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-1.3/Makefile.netware create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-1.3/Makefile.tmpl create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-1.3/Makefile.vc create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-1.3/NWGNUmakefile create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-1.3/NWGNUmakefile.mak create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-1.3/libjk.module create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-1.3/mod_jk.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-1.3/mod_jk.dsp create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-1.3/mod_jk.exp create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-2.0/.libs/mod_jk.a create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-2.0/.libs/mod_jk.la create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-2.0/.libs/mod_jk.lai create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-2.0/.libs/mod_jk.o create mode 100755 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-2.0/.libs/mod_jk.so create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-2.0/Makefile create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-2.0/Makefile.apxs create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-2.0/Makefile.apxs.in create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-2.0/Makefile.in create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-2.0/Makefile.vc create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-2.0/NWGNUmakefile create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-2.0/bldjk.qclsrc create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-2.0/bldjk54.qclsrc create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-2.0/config.m4 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-2.0/mod_jk.a create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-2.0/mod_jk.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-2.0/mod_jk.dsp create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-2.0/mod_jk.la create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-2.0/mod_jk.lo create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-2.0/mod_jk.o create mode 100755 rubbos/app/tomcat-connectors-1.2.32-src/native/apache-2.0/mod_jk.so create mode 100755 rubbos/app/tomcat-connectors-1.2.32-src/native/buildconf.sh create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/.indent.pro create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/.libs/jk_ajp12_worker.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/.libs/jk_ajp13.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/.libs/jk_ajp13_worker.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/.libs/jk_ajp14.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/.libs/jk_ajp14_worker.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/.libs/jk_ajp_common.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/.libs/jk_connect.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/.libs/jk_context.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/.libs/jk_jni_worker.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/.libs/jk_lb_worker.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/.libs/jk_map.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/.libs/jk_md5.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/.libs/jk_msg_buff.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/.libs/jk_pool.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/.libs/jk_shm.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/.libs/jk_sockbuf.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/.libs/jk_status.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/.libs/jk_uri_worker_map.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/.libs/jk_url.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/.libs/jk_util.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/.libs/jk_worker.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/Makefile create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/Makefile.in create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/ap_snprintf.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/ap_snprintf.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/config.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/config.h.in create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk.rc create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_ajp12_worker.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_ajp12_worker.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_ajp12_worker.lo create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_ajp12_worker.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_ajp13.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_ajp13.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_ajp13.lo create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_ajp13.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_ajp13_worker.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_ajp13_worker.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_ajp13_worker.lo create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_ajp13_worker.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_ajp14.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_ajp14.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_ajp14.lo create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_ajp14.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_ajp14_worker.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_ajp14_worker.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_ajp14_worker.lo create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_ajp14_worker.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_ajp_common.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_ajp_common.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_ajp_common.lo create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_ajp_common.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_connect.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_connect.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_connect.lo create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_connect.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_context.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_context.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_context.lo create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_context.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_global.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_jni_worker.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_jni_worker.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_jni_worker.lo create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_jni_worker.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_lb_worker.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_lb_worker.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_lb_worker.lo create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_lb_worker.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_logger.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_map.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_map.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_map.lo create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_map.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_md5.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_md5.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_md5.lo create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_md5.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_msg_buff.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_msg_buff.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_msg_buff.lo create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_msg_buff.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_mt.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_nwmain.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_pool.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_pool.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_pool.lo create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_pool.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_service.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_shm.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_shm.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_shm.lo create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_shm.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_sockbuf.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_sockbuf.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_sockbuf.lo create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_sockbuf.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_status.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_status.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_status.lo create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_status.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_types.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_types.h.in create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_uri_worker_map.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_uri_worker_map.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_uri_worker_map.lo create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_uri_worker_map.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_url.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_url.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_url.lo create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_url.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_util.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_util.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_util.lo create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_util.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_version.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_worker.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_worker.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_worker.lo create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_worker.o create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/jk_worker_list.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/list.mk create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/list.mk.in create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/common/stamp-h1 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/config.log create mode 100755 rubbos/app/tomcat-connectors-1.2.32-src/native/config.nice create mode 100755 rubbos/app/tomcat-connectors-1.2.32-src/native/config.status create mode 100755 rubbos/app/tomcat-connectors-1.2.32-src/native/configure create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/configure.in create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/docs/api/README.txt create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/Makefile.amd64 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/Makefile.ia64 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/Makefile.x86 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/README create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/installer/LICENSE.TXT create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/installer/License.rtf create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/installer/bin/README create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/installer/conf/rewrite.properties create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/installer/conf/uriworkermap.properties create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/installer/conf/workers.properties.minimal create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/installer/iisfilter.vbs create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/installer/isapi-redirector-win32-msi.ism create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/installer/log/README create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/installer/tomcat.ico create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/isapi.def create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/isapi.dsp create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/isapi.dsw create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/isapi_install.vbs create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/isapi_redirect.reg create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/jk_isapi_plugin.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/AUTHORS create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/COPYING create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/ChangeLog create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/INSTALL create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/LICENCE create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/Makefile.in create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/NEWS create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/NON-UNIX-USE create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/NWGNUmakefile create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/README create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/RunTest.in create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/config.hw create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/config.in create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/configure.in create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/dftables.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/dftables.dsp create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/dftables.x86 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/dll.mk create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/doc/README_httpd create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/get.c create mode 100755 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/install-sh create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/internal.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/libpcre.def create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/libpcre.pc.in create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/libpcreposix.def create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/maketables.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/makevp.bat create mode 100755 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/mkinstalldirs create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/pcre-config.in create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/pcre.amd64 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/pcre.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/pcre.def create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/pcre.dsp create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/pcre.hw create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/pcre.ia64 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/pcre.in create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/pcre.x86 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/pcredemo.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/pcregrep.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/pcreposix.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/pcreposix.dsp create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/pcreposix.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/pcretest.c create mode 100755 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/perltest create mode 100755 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/perltest8 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/pgrep.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/printint.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/study.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/testdata/testinput1 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/testdata/testinput2 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/testdata/testinput3 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/testdata/testinput4 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/testdata/testinput5 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/testdata/testinput6 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/testdata/testoutput1 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/testdata/testoutput2 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/testdata/testoutput3 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/testdata/testoutput4 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/testdata/testoutput5 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/testdata/testoutput6 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/ucp.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/ucp.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/ucpinternal.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/ucptable.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/iis/pcre/ucptypetable.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/jni/.libs/jk_jnicb.a create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/jni/.libs/jk_jnicb.la create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/jni/.libs/jk_jnicb.lai create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/jni/.libs/jk_jnicb.o create mode 100755 rubbos/app/tomcat-connectors-1.2.32-src/native/jni/.libs/jk_jnicb.so create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/jni/Makefile create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/jni/Makefile.in create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/jni/Makefile.linux create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/jni/Makefile.netware create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/jni/Makefile.solaris create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/jni/jk_jnicb.a create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/jni/jk_jnicb.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/jni/jk_jnicb.exp create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/jni/jk_jnicb.h create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/jni/jk_jnicb.la create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/jni/jk_jnicb.lo create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/jni/jk_jnicb.o create mode 100755 rubbos/app/tomcat-connectors-1.2.32-src/native/jni/jk_jnicb.so create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/jni/jni_connect.dsp create mode 100755 rubbos/app/tomcat-connectors-1.2.32-src/native/libtool create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/netscape/Makefile.linux create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/netscape/Makefile.netware create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/netscape/Makefile.solaris create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/netscape/Makefile.vc create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/netscape/README create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/netscape/jk_nsapi_plugin.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/netscape/nsapi.dsp create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/nt_service/jk_nt_service.c create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/nt_service/nt_service.dsp create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/scripts/build/config_vars.mk create mode 100755 rubbos/app/tomcat-connectors-1.2.32-src/native/scripts/build/instdso.sh create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/scripts/build/jk_common.m4 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/scripts/build/rules.mk create mode 100755 rubbos/app/tomcat-connectors-1.2.32-src/native/scripts/build/unix/config.guess create mode 100755 rubbos/app/tomcat-connectors-1.2.32-src/native/scripts/build/unix/config.sub create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/scripts/build/unix/dummy create mode 100755 rubbos/app/tomcat-connectors-1.2.32-src/native/scripts/build/unix/install-sh create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/native/scripts/build/unix/ltmain.sh create mode 100755 rubbos/app/tomcat-connectors-1.2.32-src/native/scripts/build/unix/missing create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/support/apache.m4 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/support/get_ver.awk create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/support/jk_apache_static.m4 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/support/jk_apr.m4 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/support/jk_apxs.m4 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/support/jk_dominohome.m4 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/support/jk_exec.m4 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/support/jk_java.m4 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/support/jk_pcre.m4 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/support/jk_tchome.m4 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/support/jk_ws.m4 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/support/os_apache.m4 create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/tools/dist/.htaccess create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/tools/dist/HEADER.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/tools/dist/README.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/tools/dist/binaries/windows/HEADER.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/tools/dist/binaries/windows/README.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/tools/dist/binaries/windows/symbols/HEADER.html create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/tools/dist/binaries/windows/symbols/README.html create mode 100755 rubbos/app/tomcat-connectors-1.2.32-src/tools/jkbindist.sh create mode 100755 rubbos/app/tomcat-connectors-1.2.32-src/tools/jkrelease.sh create mode 100755 rubbos/app/tomcat-connectors-1.2.32-src/tools/lineends.pl create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/tools/reports/README.txt create mode 100755 rubbos/app/tomcat-connectors-1.2.32-src/tools/reports/tomcat_reports.pl create mode 100755 rubbos/app/tomcat-connectors-1.2.32-src/tools/reports/tomcat_trend.pl create mode 100755 rubbos/app/tomcat-connectors-1.2.32-src/tools/signfile.sh create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/ajp/ajpv13a.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/ajp/ajpv13ext.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/ajp/project.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/build.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/empty.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/generic_howto/loadbalancers.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/generic_howto/project.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/generic_howto/proxy.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/generic_howto/quick.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/generic_howto/timeouts.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/generic_howto/workers.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/images/add.gif create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/images/code.gif create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/images/design.gif create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/images/docs.gif create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/images/fix.gif create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/images/jakarta-logo.gif create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/images/printer.gif create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/images/tomcat.gif create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/images/update.gif create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/images/void.gif create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/index.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/miscellaneous/changelog.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/miscellaneous/doccontrib.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/miscellaneous/faq.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/miscellaneous/jkstatustasks.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/miscellaneous/project.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/miscellaneous/reporttools.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/news/20041100.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/news/20050101.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/news/20060101.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/news/20070301.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/news/20081001.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/news/20090301.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/news/20100101.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/news/20110701.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/news/project.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/project.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/reference/apache.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/reference/iis.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/reference/project.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/reference/status.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/reference/uriworkermap.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/reference/workers.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/style.css create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/style.xsl create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/webserver_howto/apache.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/webserver_howto/iis.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/webserver_howto/nes.xml create mode 100644 rubbos/app/tomcat-connectors-1.2.32-src/xdocs/webserver_howto/project.xml diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/BUILD.txt b/rubbos/app/tomcat-connectors-1.2.32-src/BUILD.txt new file mode 100644 index 00000000..a74db433 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/BUILD.txt @@ -0,0 +1,34 @@ + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + +This is a source release of the mod_jk 1.2 web server connector for +Tomcat. Only the web server connector source is included. The Tomcat +side of the connector is available with the normal Tomcat distribution. + +Documentation for how to build mod_jk 1.2 from source and configure +it for your webserver is located in the native/BUILDING.txt file in this +source distribution. + +For the impatient Apache HTTP Server admins: +$> cd native +$> ./configure --with-apxs=/usr/sbin/apxs (or where ever the apxs/apxs2 is) +$> make +$> su -c 'make install' + +For the impatient SunONE admins: +$> cd native +$> ./configure --enable-netscape +$> cd netscape +$> make -f Makefile.solaris diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/LICENSE b/rubbos/app/tomcat-connectors-1.2.32-src/LICENSE new file mode 100644 index 00000000..677f7b83 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/LICENSE @@ -0,0 +1,252 @@ + + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + +TOMCAT CONNECTORS SUBCOMPONENTS: + +The Tomcat Connectors includes a number of subcomponents with +separate copyright notices and license terms. Your use of the source +code for the these subcomponents is subject to the terms and +conditions of the following licenses. + +From native/common/ap_snprintf.c: + + * + * cvt - IEEE floating point formatting routines. + * Derived from UNIX V7, Copyright(C) Caldera International Inc. + * + + Copyright(C) Caldera International Inc. 2001-2002. All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions are + met: + + Redistributions of source code and documentation must retain the above + copyright notice, this list of conditions and the following disclaimer. + + 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. + + All advertising materials mentioning features or use of this software + must display the following acknowledgement: + + This product includes software developed or owned by Caldera + International, Inc. + + Neither the name of Caldera International, Inc. nor the names of other + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + + USE OF THE SOFTWARE PROVIDED FOR UNDER THIS LICENSE BY CALDERA + INTERNATIONAL, INC. AND CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED + WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN + NO EVENT SHALL CALDERA INTERNATIONAL, INC. BE LIABLE FOR ANY DIRECT, + INDIRECT INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, + STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/NOTICE b/rubbos/app/tomcat-connectors-1.2.32-src/NOTICE new file mode 100644 index 00000000..0ce0fd4a --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/NOTICE @@ -0,0 +1,8 @@ +Apache Tomcat Connectors +Copyright 2002-2011 The Apache Software Foundation + +This product includes software developed at +The Apache Software Foundation (http://www.apache.org/). + +This software contains code derived from UNIX V7, Copyright(C) +Caldera International Inc. diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/conf/httpd-jk.conf b/rubbos/app/tomcat-connectors-1.2.32-src/conf/httpd-jk.conf new file mode 100644 index 00000000..4eeec2ee --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/conf/httpd-jk.conf @@ -0,0 +1,127 @@ +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Configuration Example for mod_jk +# used in combination with Apache 2.2.x + +# Change the path and file name of the module, in case +# you have installed it outside of httpd, or using +# a versioned file name. +LoadModule jk_module modules/mod_jk.so + + + + # We need a workers file exactly once + # and in the global server + JkWorkersFile conf/workers.properties + + # Our JK error log + # You can (and should) use rotatelogs here + JkLogFile logs/mod_jk.log + + # Our JK log level (trace,debug,info,warn,error) + JkLogLevel info + + # Our JK shared memory file + JkShmFile logs/mod_jk.shm + + # Define a new log format you can use in any CustomLog in order + # to add mod_jk specific information to your access log. + # LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\" \"%{Cookie}i\" \"%{Set-Cookie}o\" %{pid}P %{tid}P %{JK_LB_FIRST_NAME}n %{JK_LB_LAST_NAME}n ACC %{JK_LB_LAST_ACCESSED}n ERR %{JK_LB_LAST_ERRORS}n BSY %{JK_LB_LAST_BUSY}n %{JK_LB_LAST_STATE}n %D" extended_jk + + # This option will reject all requests, which contain an + # encoded percent sign (%25) or backslash (%5C) in the URL + # If you are sure, that your webapp doesn't use such + # URLs, enable the option to prevent double encoding attacks. + # Since: 1.2.24 + # JkOptions +RejectUnsafeURI + + # After setting JkStripSession to "On", mod_jk will + # strip all ";jsessionid=..." from request URLs it + # does *not* forward to a backend. + # This is useful, if all links in a webapp use + # URLencoded session IDs and parts of the static + # content should be delivered directly by Apache. + # Of course you can also do it with mod_rewrite. + # Since: 1.2.21 + # JkStripSession On + + # Start a separate thread for internal tasks like + # idle connection probing, connection pool resizing + # and load value decay. + # Run these tasks every JkWatchdogInterval seconds. + # Since: 1.2.27 + JkWatchdogInterval 60 + + # Configure access to jk-status and jk-manager + # If you want to make this available in a virtual host, + # either move this block into the virtual host + # or copy it logically there by including "JkMountCopy On" + # in the virtual host. + # Add an appropriate authentication method here! + + # Inside Location we can omit the URL in JkMount + JkMount jk-status + Order deny,allow + Deny from all + Allow from 127.0.0.1 + + + # Inside Location we can omit the URL in JkMount + JkMount jk-manager + Order deny,allow + Deny from all + Allow from 127.0.0.1 + + + # If you want to put all mounts into an external file + # that gets reloaded automatically after changes + # (with a default latency of 1 minute), + # you can define the name of the file here. + # JkMountFile conf/extra/uriworkermap.properties + + # Example for Mounting a context to the worker "balancer" + # The URL syntax "a|b" instantiates two mounts at once, + # the first one is "a", the second one is "ab". + # JkMount /myapp|/* balancer + + # Example for UnMounting requests for all workers + # using a simple URL pattern + # Since: 1.2.26 + # JkUnMount /myapp/static/* * + + # Example for UnMounting requests for a named worker + # JkUnMount /myapp/images/* balancer + + # Example for UnMounting requests using regexps + # SetEnvIf REQUEST_URI "\.(htm|html|css|gif|jpg|js)$" no-jk + + # Example for setting a reply timeout depending on the requets URL + # Since: 1.2.27 + # SetEnvIf Request_URI "/transactions/" JK_REPLY_TIMEOUT=600000 + + # Example for disabling reply timeouts for certain request URLs + # Since: 1.2.27 + # SetEnvIf Request_URI "/reports/" JK_REPLY_TIMEOUT=0 + + # IMPORTANT: Mounts and virtual hosts + # If you are using VirtualHost elements, you + # - can put mounts only used in some virtual host into its VirtualHost element + # - can copy all global mounts to it using "JkMountCopy On" inside the VirtualHost + # - can copy all global mounts to all virtual hosts by putting + # "JkMountCopy All" into the global server + # Since: 1.2.26 + + diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/conf/uriworkermap.properties b/rubbos/app/tomcat-connectors-1.2.32-src/conf/uriworkermap.properties new file mode 100644 index 00000000..facc0e2d --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/conf/uriworkermap.properties @@ -0,0 +1,39 @@ +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# uriworkermap.properties - IIS +# +# This file provides sample mappings for example wlb +# worker defined in workermap.properties.minimal +# The general syntax for this file is: +# [URL]=[Worker name] + +/admin/*=wlb +/manager/*=wlb +/jsp-examples/*=wlb +/servlets-examples/*=wlb +/examples/*=wlb + +# Optionally filter out all .jpeg files inside that context +# For no mapping the url has to start with exclamation (!) + +!/servlets-examples/*.jpeg=wlb + +# +# Mount jkstatus to /jkmanager +# For production servers you will need to +# secure the access to the /jkmanager url +# +/jkmanager=jkstatus diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/conf/workers.properties b/rubbos/app/tomcat-connectors-1.2.32-src/conf/workers.properties new file mode 100644 index 00000000..cd374285 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/conf/workers.properties @@ -0,0 +1,165 @@ +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Note that the distributed version of this file requires modification +# before it is usable. +# +# Reference documentation: http://tomcat.apache.org/connectors-doc/reference/workers.html +# +# As a general note, the characters $( and ) are used internally to define +# macros. Do not use them in your own configuration!!! +# +# Whenever you see a set of lines such as: +# x=value +# y=$(x)\something +# +# the final value for y will be value\something + +# Define two status worker: +# - jk-status for read-only use +# - jk-manager for read/write use +worker.list=jk-status +worker.jk-status.type=status +worker.jk-status.read_only=true + +worker.list=jk-manager +worker.jk-manager.type=status + +# We define a load balancer worker +# with name "balancer" +worker.list=balancer +worker.balancer.type=lb +# error_escalation_time: seconds, default = recover_time/2 (=30) +# Determines, how fast a detected error should switch from +# local error state to global error state +# Since: 1.2.28 +worker.balancer.error_escalation_time=0 + +# - max_reply_timeouts: number, default=0 +# If there are to many reply timeouts, a worker +# is put into the error state, i.e. it will become +# unavailable for all sessions residing on the respective +# Tomcat. The number of tolerated reply timeouts is +# configured with max_reply_timeouts. The number of +# timeouts occuring is divided by 2 once a minute and the +# resulting counter is compared against max_reply_timeouts. +# If you set max_reply_timeouts to N and the errors are +# occuring equally distributed over time, you will +# tolerate N/2 errors per minute. If they occur in a burst +# you will tolerate N errors. +# Since: 1.2.24 +worker.balancer.max_reply_timeouts=10 + + + +# Now we add members to the load balancer +# First member is "node1", most +# attributes are inherited from the +# template "worker.template". +worker.balancer.balance_workers=node1 +worker.node1.reference=worker.template +worker.node1.host=localhost +worker.node1.port=8109 +# Activation allows to configure +# whether this node should actually be used +# A: active (use node fully) +# D: disabled (only use, if sticky session needs this node) +# S: stopped (do not use) +# Since: 1.2.19 +worker.node1.activation=A + +# Second member is "node2", most +# attributes are inherited from the +# template "worker.template". +worker.balancer.balance_workers=node2 +worker.node2.reference=worker.template +worker.node2.host=localhost +worker.node2.port=8209 +# Activation allows to configure +# whether this node should actually be used +# A: active (use node fully) +# D: disabled (only use, if sticky session needs this node) +# S: stopped (do not use) +# Since: 1.2.19 +worker.node2.activation=A + +# Finally we put the parameters +# which should apply to all our ajp13 +# workers into the referenced template +# - Type is ajp13 +worker.template.type=ajp13 + +# - socket_connect_timeout: milliseconds, default=0 +# Since: 1.2.27 +worker.template.socket_connect_timeout=5000 + +# - socket_keepalive: boolean, default=false +# Should we send TCP keepalive packets +# when connection is idle (socket option)? +worker.template.socket_keepalive=true + +# - ping_mode: Character, default=none +# When should we use cping/cpong connection probing? +# C = directly after establishing a new connection +# P = directly before sending each request +# I = in regular intervals for idle connections +# using the watchdog thread +# A = all of the above +# Since: 1.2.27 +worker.template.ping_mode=A + +# - ping_timeout: milliseconds, default=10000 +# Wait timeout for cpong after cping +# Can be overwritten for modes C and P +# Using connect_timeout and prepost_timeout. +# Since: 1.2.27 +worker.template.ping_timeout=10000 + +# - connection_pool_minsize: number, default=connection_pool_size +# Lower pool size when shrinking pool due +# to idle connections +# We want all connections to be closed when +# idle for a long time in order to prevent +# firewall problems. +# Since: 1.2.16 +worker.template.connection_pool_minsize=0 + +# - connection_pool_timeout: seconds, default=0 +# Idle time, before a connection is eligible +# for being closed (pool shrinking). +# This should be the same value as connectionTimeout +# in the Tomcat AJP connector, but there it is +# milliseconds, here seconds. +worker.template.connection_pool_timeout=600 + +# - reply_timeout: milliseconds, default=0 +# Any pause longer than this timeout during waiting +# for a part of the reply will abort handling the request +# in mod_jk. The request will proceed running in +# Tomcat, but the web server resources will be freed +# and an error is send to the client. +# For individual requests, the timeout can be overwritten +# by the Apache environment variable JK_REPLY_TIMEOUT. +# JK_REPLY_TIMEOUT since: 1.2.27 +worker.template.reply_timeout=300000 + +# - recovery_options: number, default=0 +# Bit mask to configure, if a request, which was send +# to a backend successfully, should be retried on another backend +# in case there's a problem with the response. +# Value "3" disables retries, whenever a part of the request was +# successfully send to the backend. +worker.template.recovery_options=3 + diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/conf/workers.properties.minimal b/rubbos/app/tomcat-connectors-1.2.32-src/conf/workers.properties.minimal new file mode 100644 index 00000000..7d7dcdac --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/conf/workers.properties.minimal @@ -0,0 +1,45 @@ +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# workers.properties.minimal - +# +# This file provides minimal jk configuration properties needed to +# connect to Tomcat. +# +# The workers that jk should create and work with +# + +worker.list=wlb,jkstatus + +# +# Defining a worker named ajp13w and of type ajp13 +# Note that the name and the type do not have to match. +# +worker.ajp13w.type=ajp13 +worker.ajp13w.host=localhost +worker.ajp13w.port=8009 + +# +# Defining a load balancer +# + +worker.wlb.type=lb +worker.wlb.balance_workers=ajp13w + +# +# Define status worker +# + +worker.jkstatus.type=status diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/ajp/ajpv13a.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/ajp/ajpv13a.html new file mode 100644 index 00000000..58056035 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/ajp/ajpv13a.html @@ -0,0 +1,654 @@ +The Apache Tomcat Connector - AJP Protocol Reference - AJPv13
Apache TomcatApache Logo

Links

Reference Guide

Generic HowTo

Webserver HowTo

AJP Protocol Reference

Miscellaneous Documentation

News

The Apache Tomcat Connector - AJP Protocol Reference

AJPv13

Printer Friendly Version
print-friendly
version +
Intro
+ +

+The original document was written by +Dan Milstein, danmil@shore.net +on December 2000. The present document is generated out of an xml file +to allow a more easy integration in the Tomcat documentation. + +

+ +

+This describes the Apache JServ Protocol version 1.3 (hereafter +ajp13). There is, apparently, no current documentation of how the +protocol works. This document is an attempt to remedy that, in order to +make life easier for maintainers of JK, and for anyone who wants to +port the protocol somewhere (into jakarta 4.x, for example). +

+ +
author
+ +

+I am not one of the designers of this protocol -- I believe that Gal +Shachor was the original designer. Everything in this document is derived +from the actual implementation I found in the tomcat 3.x code. I hope it +is useful, but I can't make any grand claims to perfect accuracy. I also +don't know why certain design decisions were made. Where I was able, I've +offered some possible justifications for certain choices, but those are +only my guesses. In general, the C code which Shachor wrote is very clean +and comprehensible (if almost totally undocumented). I've cleaned up the +Java code, and I think it's reasonably readable. +

+
Design Goals
+ +

+According to email from Gal Shachor to the jakarta-dev mailing list, +the original goals of JK (and thus ajp13) were to extend +mod_jserv and ajp12 by (I am only including the goals which +relate to communication between the web server and the servlet container): + +

    +
  • Increasing performance (speed, specifically).
  • + +
  • Adding support for SSL, so that isSecure() and + getScheme() will function correctly within the servlet + container. The client certificates and cipher suite will be + available to servlets as request attributes.
  • + +
+

+
Overview of the protocol
+ +

+The ajp13 protocol is packet-oriented. A binary format was +presumably chosen over the more readable plain text for reasons of +performance. The web server communicates with the servlet container over +TCP connections. To cut down on the expensive process of socket creation, +the web server will attempt to maintain persistent TCP connections to the +servlet container, and to reuse a connection for multiple request/response +cycles. +

+Once a connection is assigned to a particular request, it will not be +used for any others until the request-handling cycle has terminated. In +other words, requests are not multiplexed over connections. This makes +for much simpler code at either end of the connection, although it does +cause more connections to be open at once. +

+Once the web server has opened a connection to the servlet container, +the connection can be in one of the following states: +

+

    +
  • Idle
    No request is being handled over this connection.
  • +
  • Assigned
    The connecton is handling a specific request.
  • +
+ +

+Once a connection is assigned to handle a particular request, the basic +request informaton (e.g. HTTP headers, etc) is sent over the connection in +a highly condensed form (e.g. common strings are encoded as integers). +Details of that format are below in Request Packet Structure. If there is a +body to the request (content-length > 0), that is sent in a separate +packet immediately after. +

+At this point, the servlet container is presumably ready to start +processing the request. As it does so, it can send the +following messages back to the web server: + +

    +
  • SEND_HEADERS
    Send a set of headers back to the browser.
  • + +
  • SEND_BODY_CHUNK
    Send a chunk of body data back to the browser.
  • + +
  • GET_BODY_CHUNK
    Get further data from the request if it hasn't all + been transferred yet. This is necessary because the packets have a fixed + maximum size and arbitrary amounts of data can be included the body of a + request (for uploaded files, for example). (Note: this is unrelated to + HTTP chunked tranfer).
  • + +
  • END_RESPONSE
    Finish the request-handling cycle.
  • +
+

+ +Each message is accompanied by a differently formatted packet of data. See +Response Packet Structures below for details. +

+
Basic Packet Structure
+ +

+There is a bit of an XDR heritage to this protocol, but it differs in +lots of ways (no 4 byte alignment, for example). +

+Byte order: I am not clear about the endian-ness of the individual +bytes. I'm guessing the bytes are little-endian, because that's what XDR +specifies, and I'm guessing that sys/socket library is magically making +that so (on the C side). If anyone with a better knowledge of socket calls +can step in, that would be great. +

+There are four data types in the protocol: bytes, booleans, integers and +strings. + +

+
Byte
+
A single byte.
+ +
Boolean
+
A single byte, 1 = true, 0 = false. Using other non-zero values as + true (i.e. C-style) may work in some places, but it won't in + others.
+ +
Integer
+
A number in the range of 0 to 2^16 (32768). Stored in 2 bytes with + the high-order byte first.
+ +
String
+
A variable-sized string (length bounded by 2^16). Encoded with the + length packed into two bytes first, followed by the string (including the + terminating '\0'). Note that the encoded length does not include + the trailing '\0' -- it is like strlen. This is a touch + confusing on the Java side, which is littered with odd autoincrement + statements to skip over these terminators. I believe the reason this was + done was to allow the C code to be extra efficient when reading strings + which the servlet container is sending back -- with the terminating \0 + character, the C code can pass around references into a single buffer, + without copying. If the \0 was missing, the C code would have to copy + things out in order to get its notion of a string. Note a size of -1 + (65535) indicates a null string and no data follow the length in this + case.
+
+

+ +
Packet Size
+

+According to much of the code, the max packet +size is 8 * 1024 bytes (8K). The actual length of the packet is encoded in the +header. +

+
+ +
Packet Headers
+

+Packets sent from the server to the container begin with +0x1234. Packets sent from the container to the server begin +with AB (that's the ASCII code for A followed by the ASCII +code for B). After those first two bytes, there is an integer (encoded as +above) with the length of the payload. Although this might suggest that +the maximum payload could be as large as 2^16, in fact, the code sets the +maximum to be 8K. + + + + + + + + + + + + + + + + + + + + + + + +
Packet Format (Server->Container)
Byte01234...(n+3)
Contents0x120x34Data Length (n)Data
+ + + + + + + + + + + + + + + + + + + + + + +
Packet Format (Container->Server)
Byte01234...(n+3)
ContentsABData Length (n)Data
+

+

+ For most packets, the first byte of the +payload encodes the type of message. The exception is for request body +packets sent from the server to the container -- they are sent with a +standard packet header (0x1234 and then length of the packet), but without +any prefix code after that (this seems like a mistake to me). +

+The web server can send the following messages to the servlet container: + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
CodeType of PacketMeaning
2Forward RequestBegin the request-processing cycle with the following data
7ShutdownThe web server asks the container to shut itself down.
8PingThe web server asks the container to take control (secure login phase).
10CPingThe web server asks the container to respond quickly with a CPong.
noneDataSize (2 bytes) and corresponding body data.
+

+

+To ensure some +basic security, the container will only actually do the Shutdown if the +request comes from the same machine on which it's hosted. +

+

+The first Data packet is send immediatly after the Forward Request by the web server. +

+ +

The servlet container can send the following types of messages to the web +server: + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
CodeType of PacketMeaning
3Send Body ChunkSend a chunk of the body from the servlet container to the web + server (and presumably, onto the browser).
4Send HeadersSend the response headers from the servlet container to the web + server (and presumably, onto the browser).
5End ResponseMarks the end of the response (and thus the request-handling cycle).
6Get Body ChunkGet further data from the request if it hasn't all been transferred + yet.
9CPong ReplyThe reply to a CPing request
+

+

+Each of the above messages has a different internal structure, detailed below. +

+
+
Request Packet Structure
+ +

+For messages from the server to the container of type "Forward Request": +

+

+AJP13_FORWARD_REQUEST :=
+    prefix_code      (byte) 0x02 = JK_AJP13_FORWARD_REQUEST
+    method           (byte)
+    protocol         (string)
+    req_uri          (string)
+    remote_addr      (string)
+    remote_host      (string)
+    server_name      (string)
+    server_port      (integer)
+    is_ssl           (boolean)
+    num_headers      (integer)
+    request_headers *(req_header_name req_header_value)
+    attributes      *(attribut_name attribute_value)
+    request_terminator (byte) OxFF
+
+

+The request_headers have the following structure: +

+

+req_header_name := 
+    sc_req_header_name | (string)  [see below for how this is parsed]
+
+sc_req_header_name := 0xA0xx (integer)
+
+req_header_value := (string)
+
+

+ +The attributes are optional and have the following structure: +

+

+attribute_name := sc_a_name | (sc_a_req_attribute string)
+
+attribute_value := (string)
+
+
+

+Not that the all-important header is "content-length', because it +determines whether or not the container looks for another packet +immediately. +

+Detailed description of the elements of Forward Request. +

+
request_prefix
+

+For all requests, this will be 2. +See above for details on other prefix codes. +

+
+ +
method
+

+The HTTP method, encoded as a single byte: +

+ +

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Command NameCode
OPTIONS1
GET2
HEAD3
POST4
PUT5
DELETE6
TRACE7
PROPFIND8
PROPPATCH9
MKCOL10
COPY11
MOVE12
LOCK13
UNLOCK14
ACL15
REPORT16
VERSION-CONTROL17
CHECKIN18
CHECKOUT19
UNCHECKOUT20
SEARCH21
MKWORKSPACE22
UPDATE23
LABEL24
MERGE25
BASELINE_CONTROL26
MKACTIVITY27
+

+ +

Later version of ajp13, when used with mod_jk2, will transport +additional methods, even if they are not in this list. +

+ +
+ +
protocol, req_uri, remote_addr, remote_host, server_name, server_port, is_ssl
+

+ These are all fairly self-explanatory. Each of these is required, and + will be sent for every request. +

+
+ +
Headers
+

+ The structure of request_headers is the following: + First, the number of headers num_headers is encoded. + Then, a series of header name req_header_name / value + req_header_value pairs follows. + Common header names are encoded as integers, + to save space. If the header name is not in the list of basic headers, + it is encoded normally (as a string, with prefixed length). The list of + common headers sc_req_header_nameand their codes + is as follows (all are case-sensitive): +

+ + + + + + + + + + + + + + + + +
NameCode valueCode name
accept0xA001SC_REQ_ACCEPT
accept-charset0xA002SC_REQ_ACCEPT_CHARSET
accept-encoding0xA003SC_REQ_ACCEPT_ENCODING
accept-language0xA004SC_REQ_ACCEPT_LANGUAGE
authorization0xA005SC_REQ_AUTHORIZATION
connection0xA006SC_REQ_CONNECTION
content-type0xA007SC_REQ_CONTENT_TYPE
content-length0xA008SC_REQ_CONTENT_LENGTH
cookie0xA009SC_REQ_COOKIE
cookie20xA00ASC_REQ_COOKIE2
host0xA00BSC_REQ_HOST
pragma0xA00CSC_REQ_PRAGMA
referer0xA00DSC_REQ_REFERER
user-agent0xA00ESC_REQ_USER_AGENT
+

+ The Java code that reads this grabs the first two-byte integer and if + it sees an '0xA0' in the most significant + byte, it uses the integer in the second byte as an index into an array of + header names. If the first byte is not '0xA0', it assumes that the + two-byte integer is the length of a string, which is then read in. +

+ This works on the assumption that no header names will have length + greater than 0x9999 (==0xA000 - 1), which is perfectly reasonable, though + somewhat arbitrary. (If you, like me, started to think about the cookie + spec here, and about how long headers can get, fear not -- this limit is + on header names not header values. It seems unlikely that + unmanageably huge header names will be showing up in the HTTP spec any time + soon). +

+ Note: The content-length header is extremely + important. If it is present and non-zero, the container assumes that + the request has a body (a POST request, for example), and immediately + reads a separate packet off the input stream to get that body. +

+
+ +
Attributes
+

+ + The attributes prefixed with a ? + (e.g. ?context) are all optional. For each, there is a + single byte code to indicate the type of attribute, and then a string to + give its value. They can be sent in any order (thogh the C code always + sends them in the order listed below). A special terminating code is + sent to signal the end of the list of optional attributes. The list of + byte codes is: +

+ + + + + + + + + + + + + + + + + +
InformationCode ValueNote
?context0x01Not currently implemented
?servlet_path0x02Not currently implemented
?remote_user0x03
?auth_type0x04
?query_string0x05
?route0x06
?ssl_cert0x07
?ssl_cipher0x08
?ssl_session0x09
?req_attribute0x0AName (the name of the attribut follows)
?ssl_key_size0x0B
?secret0x0C
?stored_method0x0D
are_done0xFFrequest_terminator
+ +

+ + The context and servlet_path are not currently + set by the C code, and most of the Java code completely ignores whatever + is sent over for those fields (and some of it will actually break if a + string is sent along after one of those codes). I don't know if this is + a bug or an unimplemented feature or just vestigial code, but it's + missing from both sides of the connection. +

+ The remote_user and auth_type presumably refer + to HTTP-level authentication, and communicate the remote user's username + and the type of authentication used to establish their identity (e.g. Basic, + Digest). I'm not clear on why the password isn't also sent, but I don't + know HTTP authentication inside and out. +

+ The query_string, ssl_cert, + ssl_cipher, and ssl_session refer to the + corresponding pieces of HTTP and HTTPS. +

+ The route, as I understand it, is used to support sticky + sessions -- associating a user's sesson with a particular Tomcat instance + in the presence of multiple, load-balancing servers. I don't know the + details. +

+ Beyond this list of basic attributes, any number of other attributes can + be sent via the req_attribute code (0x0A). A pair of strings + to represent the attribute name and value are sent immediately after each + instance of that code. Environment values are passed in via this method. +

+ Finally, after all the attributes have been sent, the attribute terminator, + 0xFF, is sent. This signals both the end of the list of attributes and + also then end of the Request Packet. +

+
+ +
Response Packet Structure
+ +

+For messages which the container can send back to the server. + +

+AJP13_SEND_BODY_CHUNK := 
+  prefix_code   3
+  chunk_length  (integer)
+  chunk        *(byte)
+
+
+AJP13_SEND_HEADERS :=
+  prefix_code       4
+  http_status_code  (integer)
+  http_status_msg   (string)
+  num_headers       (integer)
+  response_headers *(res_header_name header_value)
+
+res_header_name := 
+    sc_res_header_name | (string)   [see below for how this is parsed]
+
+sc_res_header_name := 0xA0 (byte)
+
+header_value := (string)
+
+AJP13_END_RESPONSE :=
+  prefix_code       5
+  reuse             (boolean)
+
+
+AJP13_GET_BODY_CHUNK :=
+  prefix_code       6
+  requested_length  (integer)
+
+ +

+

+Details: +

+ +
Send Body Chunk
+

+ The chunk is basically binary data, and is sent directly back to the browser. +

+
+ +
Send Headers
+

+ The status code and message are the usual HTTP things (e.g. "200" and "OK"). + The response header names are encoded the same way the request header names are. + See above for details about how the the + codes are distinguished from the strings. The codes for common headers are: +

+ +

+ + + + + + + + + + + + + +
NameCode value
Content-Type0xA001
Content-Language0xA002
Content-Length0xA003
Date0xA004
Last-Modified0xA005
Location0xA006
Set-Cookie0xA007
Set-Cookie20xA008
Servlet-Engine0xA009
Status0xA00A
WWW-Authenticate0xA00B
+ +

+ +

+ After the code or the string header name, the header value is immediately + encoded. +

+ +
+ +
End Response
+

+ Signals the end of this request-handling cycle. If the + reuse flag is true (==1), this TCP connection can now be used to + handle new incoming requests. If reuse is false (anything + other than 1 in the actual C code), the connection should be closed. +

+
+ +
Get Body Chunk
+

+ The container asks for more data from the request (If the body was + too large to fit in the first packet sent over or when the request is + chuncked). + The server will send a body packet back with an amount of data which is + the minimum of the request_length, + the maximum send body size (8186 (8 Kbytes - 6)), and the + number of bytes actually left to send from the request body. +
+ If there is no more data in the body (i.e. the servlet container is + trying to read past the end of the body), the server will send back an + "empty" packet, which is a body packet with a payload length of 0. + (0x12,0x34,0x00,0x00) +

+
+
Questions I Have
+ +

What happens if the request headers > max packet size? There is no +provision to send a second packet of request headers in case there are more +than 8K (I think this is correctly handled for response headers, though I'm +not certain). I don't know if there is a way to get more than 8K worth of +data into that initial set of request headers, but I'll bet there is +(combine long cookies with long ssl information and a lot of environment +variables, and you should hit 8K easily). I think the connector would just +fail before trying to send any headers in this case, but I'm not certain.

+ +

What about authentication? There doesn't seem to be any authentication +of the connection between the web server and the container. This strikes +me as potentially dangerous.

+ +

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/ajp/ajpv13ext.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/ajp/ajpv13ext.html new file mode 100644 index 00000000..187aab19 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/ajp/ajpv13ext.html @@ -0,0 +1,654 @@ +The Apache Tomcat Connector - AJP Protocol Reference - AJPv13 extensions Proposal
Apache TomcatApache Logo

Links

Reference Guide

Generic HowTo

Webserver HowTo

AJP Protocol Reference

Miscellaneous Documentation

News

The Apache Tomcat Connector - AJP Protocol Reference

AJPv13 extensions Proposal

Printer Friendly Version
print-friendly
version +
Introduction
+

+This document is a proposal of evolution of the current +Apache JServ Protocol version 1.3, also known as ajp13. +I'll not cover here the full protocol but only the add-on from ajp13. + +This nth pass include comments from the tomcat-dev list and +misses discovered during developpment. +

+
Missing features in AJP13
+

+ajp13 is a good protocol to link a servlet engine like tomcat to a web server like Apache: + +

    +
  • +use persistants connections to avoid reconnect time at each request +
  • +
  • +encode many http commands to reduce stream size +
  • +
  • +send to servlet engine many info from web server (like SSL certs) +
  • +
+

+But ajp13 lacks support for : +

+
    +
  • + security between web server and servlet engine. + Anybody can connect to an ajp13 port (no login mecanism used) + You could connect, for example with telnet, and keep the remote thread + up by not sending any data (no timeout in connection) +
  • +
  • + context information passed from servlet engine to web server. + Part of the configuration of JK, the web server connector, is to + indicate to the web server which URI to handle. + The mod_jk JkMount directive, told to web server which URI must be + forwarded to servlet engine. + A servlet engine allready knows which URI it handle and TC 3.3 is + allready capable to generate a config file for JK from the list + of available contexts. +
  • +
  • + state update of contexts from servlet engine to web server. + Big site with farm of Tomcat, like ISP and virtuals hosters, + may need to stop a context for admin purposes. In that case the front + web server must know that the context is currently down, to eventually + relay the request to another Tomcat +
  • +
  • + verify state of connection before sending request. + Actually JK send the request to the servlet engine and next wait + for the answer. But one of the beauty of the socket API, is you that + you could write() to a closed connection without any error reporting, + but a read() to a closed connection return you the error code. +
  • +
+ +

+
+ +
Proposed add-ons to AJP13
+

+Let's descrive here the features and add-on that could be added to AJP13. +Since this document is a proposal, a reasonable level of chaos must be expected at first. +Be sure that discussion on tomcat list will help clarify points, add +features but the current list seems to be a 'minimun vital' + +

    + +
  • +Advanced login features at connect time +
  • + +
  • +Basic authorisation system, where a shared secret key is +present in web server and servlet engine. +
  • + +
  • +Basic protocol negociation, just to be sure that if functionnalities are added +to AJP13 in the future, current implementations will still works. +
  • + +
  • +Clean handling of 'Unknown packets' +
  • + +
  • +Extended env vars passed from web-server to servlet engine. +
  • + +
  • +Add extra SSL informations needed by Servlet 2.3 API (like SSL_KEY_SIZE) +
  • + +
+ +

+
+ +
Advanced login
+

+ +

    +
  1. +WEB-SERVER send LOGIN INIT CMD + NEGOCIATION DATA + WEB SERVER INFO +
  2. +
  3. + TOMCAT respond with LOGIN SEED CMD + RANDOM DATA +
  4. +
  5. + WEB-SERVER calculted the MD5 of RANDOM DATA+SECRET DATA +
  6. +
  7. + WEB-SERVER send LOGIN COMP CMD + MD5 (SECRET DATA + RANDOM DATA) +
  8. +
  9. + TOMCAT respond with LOGIN STATUS CMD + NEGOCIED DATA + SERVLET ENGINE INFO +
  10. +
+ +To prevent DOS attack, the servlet engine will wait +the LOGIN CMD only 15/30 seconds and reports the +timeout exception for admins investigation. + +The login command will contains basic protocol +negociation information like compressing ability, +crypto, context info (at start up), context update at +run-time (up/down), level of SSL env vars, AJP protocol +level supported (level1/level2/level3...) + +The Web server info will contain web server info and +connector name (ie Apache 1.3.26 + mod_ssl 2.8.8 + mod_jk 1.2.1 + mod_perl 1.25). + +The servlet engine will mask the negociation mask with it's own +mask (what it can do) and return it when loggin is accepted. + +This will help having a basic AJP13 implementation (level 1) +on a web-server working with a more advanced protocol handler on +the servlet engine side or vice-versa. + +AJP13 was designed to be small and fast and so many +SSL informations present in the web-server are not +forwarded to the servlet engine. + +We add here four negociations flags to provide more +informations on client SSL data (certs), server SSL datas, +crypto used, and misc datas (timeout...). +

+
+ +
Messages Stream
+

+

++----------------+------------------+-----------------+
+| LOGIN INIT CMD | NEGOCIATION DATA | WEB SERVER INFO |
++----------------+------------------+-----------------+
+
++----------------+----------------+
+| LOGIN SEED CMD | MD5 of entropy |
++----------------+----------------+
+
++----------------+----------------------------+
+| LOGIN COMP CMD | MD5 of RANDOM + SECRET KEY |
++----------------+----------------------------+
+
++-----------+---------------+---------------------+
+| LOGOK CMD | NEGOCIED DATA | SERVLET ENGINE INFO |
++-----------+---------------+---------------------+
+
++------------+--------------+
+| LOGNOK CMD | FAILURE CODE |
++------------+--------------+
+
+ +
    +
  • +LOGIN INIT CMD, LOGIN SEED CMD, LOGIN COMP CMD, LOGOK CMD, LOGNOK CMD are 1 byte long. +
  • +
  • +MD5, MD5 of RANDOM + SECRET KEY are 32 chars long. +
  • +
  • +NEGOCIATION DATA, NEGOCIED DATA, FAILURE CODE are 32 bits long. +
  • +
  • +WEB SERVER INFO, SERVLET ENGINE INFO are CString. +
  • +
+ +The secret key will be set by a new propertie in +workers.properties : secretkey +
+worker.ajp13.port=8009
+worker.ajp13.host=localhost
+worker.ajp13.type=ajp13
+worker.ajp13.secretkey=myverysecretkey
+
+

+
+ +
Shutdown feature
+

+AJP13 miss a functionnality of AJP12, which is shutdown command. +A logout will tell servlet engine to shutdown itself. +

++--------------+----------------------------+
+| SHUTDOWN CMD | MD5 of RANDOM + SECRET KEY |
++--------------+----------------------------+
+
++------------+
+| SHUTOK CMD |
++------------+
+
++-------------+--------------+
+| SHUTNOK CMD | FAILURE CODE |
++-------------+--------------+
+
+ +
    +
  • +SHUTDOWN CMD, SHUTOK CMD, SHUTNOK CMD are 1 byte long. +
  • +
  • +MD5 of RANDOM + SECRET KEY are 32 chars long. +
  • +
  • +FAILURE CODE is 32 bits long. +
  • +
+ +

+
+ +
Extended Env Vars feature
+

+NOTA: + +While working on AJP13 in JK, I really discovered "JkEnvVar". +The following "Extended Env Vars feature" description may not +be implemented in extended AJP13 since allready available in original +implementation. + +DESC: + +Many users will want to see some of their web-server env vars +passed to their servlet engine. + +To reduce the network traffic, the web-servlet will send a +table to describing the external vars in a shorter fashion. + +We'll use there a functionnality allready present in AJP13, +attributes list : + +In the AJP13, we've got : + +

+AJP13_FORWARD_REQUEST :=
+    prefix_code      2
+    method           (byte)
+    protocol         (string)
+    req_uri          (string)
+    remote_addr      (string)
+    remote_host      (string)
+    server_name      (string)
+    server_port      (integer)
+    is_ssl           (boolean)
+    num_headers      (integer)
+    request_headers *(req_header_name req_header_value)
+
+    ?context       (byte string)
+    ?servlet_path  (byte string)
+    ?remote_user   (byte string)
+    ?auth_type     (byte string)
+    ?query_string  (byte string)
+    ?route         (byte string)
+    ?ssl_cert      (byte string)
+    ?ssl_cipher    (byte string)
+    ?ssl_session   (byte string)
+
+    ?attributes   *(attribute_name attribute_value)
+    request_terminator (byte)
+
+ +Using short 'web server attribute name' will reduce the +network traffic. + +
++-------------------+---------------------------+-------------------------------+----+
+| EXTENDED VARS CMD | WEB SERVER ATTRIBUTE NAME | SERVLET ENGINE ATTRIBUTE NAME | ES |
++-------------------+---------------------------+-------------------------------+----+
+
+ +ie : + +
+JkExtVars S1 SSL_CLIENT_V_START javax.servlet.request.ssl_start_cert_date
+JkExtVars S2 SSL_CLIENT_V_END   javax.servlet.request.ssl_end_cert_date
+JkExtVars S3 SSL_SESSION_ID     javax.servlet.request.ssl_session_id
+
+
++-------------------+----+-------------------------------------------+
+| EXTENDED VARS CMD | S1 | javax.servlet.request.ssl_start_cert_date |
++-------------------+----+-------------------------------------------+
++----+-----------------------------------------+
+| S2 | javax.servlet.request.ssl_end_cert_date |
++----+-----------------------------------------+
++----+-----------------------------------------+
+| S3 | javax.servlet.request.ssl_end_cert_date |
++----+-----------------------------------------+
+
+ +During transmission in extended AJP13 we'll see attributes name +containing S1, S2, S3 and attributes values of +2001/01/03, 2002/01/03, 0123AFE56. + +This example showed the use of extended SSL vars but +any 'personnal' web-server vars like custom authentification +vars could be reused in the servlet engine. +The cost will be only some more bytes in the AJP traffic. + +
    +
  • +EXTENDED VARS CMD is 1 byte long. +
  • +
  • +WEB SERVER ATTRIBUTE NAME, SERVLET ENGINE ATTRIBUTE NAME are CString. +
  • +
  • +ES is an empty CString. +
  • +
+ +

+
+ +
Context informations forwarding for Servlet engine to Web Server
+

+Just after the LOGON PHASE, the web server will ask for the list of contexts +and URLs/URIs handled by the servlet engine. +It will ease installation in many sites, reduce questions about configuration +on tomcat-user list, and be ready for servlet API 2.3. + +This mode will be activated by a new directive JkAutoMount + +ie: JkAutoMount examples myworker1 /examples/ + +If we want to get ALL the contexts handled by the servlet engine, willcard +could be used : + +ie: JkAutoMount * myworker1 * + +A servlet engine could have many contexts, /examples, /admin, /test. +We may want to use only some contexts for a given worker. It was +done previously, in apache HTTP server for example, by setting by +hand the JkMount accordingly in each [virtual] area of Apache. + +If you web-server support virtual hosting, we'll forward also that +information to servlet engine which will only return contexts for +that virtual host. +In that case the servlet engine will only return the URL/URI matching +these particular virtual server (defined in server.xml). +This feature will help ISP and big sites which mutualize large farm +of Tomcat in load-balancing configuration. + +

++-----------------+-------------------+----------+----------+----+
+| CONTEXT QRY CMD | VIRTUAL HOST NAME | CONTEXTA | CONTEXTB | ES |
++-----------------+-------------------+----------+----------+----+
+
++------------------+-------------------+----------+-------------------+----------+---------------+----+
+| CONTEXT INFO CMD | VIRTUAL HOST NAME | CONTEXTA | URL1 URL2 URL3 ES | CONTEXTB | URL1 URL2 ... | ES |
++------------------+-------------------+----------+-------------------+----------+---------------+----+
+
+ +We'll discover via context-query, the list of URL/MIMES handled by the remove servlet engine +for a list of contextes. +In wildcard mode, CONTEXTA will contains just '*'. + +
    +
  • +CONTEXT QRY CMD and CONTEXT INFO CMD are 1 byte long. +
  • +
  • +VIRTUAL HOST NAME is a CString, ie an array of chars terminated by a null byte (/0). +
  • +
  • +An empty string is just a null byte (/0). +
  • +
  • +ES is an empty CString. Indicate end of URI/URLs or end of CONTEXTs. +
  • +
+ +NB:
+When VirtualMode is not to be used, the VIRTUAL HOST NAME is '*'. +In that case the servlet engine will send all contexts handled. +

+
+ +
Context informations updates from Servlet engine to Web Server
+

+Context update are messages caming from the servlet engine each time a context +is desactivated/reactivated. The update will be in use when the directive JkUpdateMount. +This directive will set the AJP13_CONTEXT_UPDATE_NEG flag. + +ie: JkUpdateMount myworker1 + +

++--------------------+-------------------+----------+--------+----------+--------+----+
+| CONTEXT UPDATE CMD | VIRTUAL HOST NAME | CONTEXTA | STATUS | CONTEXTB | STATUS | ES |
++--------------------+-------------------+----------+--------+----------+--------+----+
+
+ +
    +
  • +CONTEXT UPDATE CMD, STATUS are 1 byte long. +
  • +
  • +VIRTUAL HOST NAME, CONTEXTS are CString. +
  • +
  • +ES is an empty CString. Indicate end of CONTEXTs. +
  • +
+ +NB:
+When VirtualMode is not in use, the VIRTUAL HOST NAME is '*'. +STATUS is one byte indicating if context is UP/DOWN/INVALID +

+
+ +
Context status query to Servlet engine
+

+This query will be used by the web-server to determine if a given +contexts are UP, DOWN or INVALID (and should be removed). + +

++-------------------+--------------------+----------+----------+----+
+| CONTEXT STATE CMD |  VIRTUAL HOST NAME | CONTEXTA | CONTEXTB | ES |
++-------------------+--------------------+----------+----------+----+
+
++-------------------------+-------------------+----------+--------+----------+--------+----+
+| CONTEXT STATE REPLY CMD | VIRTUAL HOST NAME | CONTEXTA | STATUS | CONTEXTB | STATUS | ES |
++-------------------------+-------------------+----------+-------------------+--------+----+
+
+ +
    +
  • +CONTEXT STATE CMD, CONTEXT STATE REPLY CMD, STATUS are 1 byte long. +
  • +
  • +VIRTUAL HOST NAME, CONTEXTs are CString +
  • +
  • +ES is an empty CString +
  • +
+ +NB:
+When VirtualMode is not in use, the VIRTUAL HOST NAME is an empty string. +

+
+ +
Handling of unknown packets
+

+Sometimes even with a well negocied protocol, we may be in a situation +where one end (web server or servlet engine), will receive a message it +couldn't understand. In that case the receiver will send an +'UNKNOW PACKET CMD' with attached the unhandled message. + +

++--------------------+------------------------+-------------------+
+| UNKNOWN PACKET CMD | UNHANDLED MESSAGE SIZE | UNHANDLED MESSAGE |
++--------------------+------------------------+-------------------+
+
+ +Depending on the message, the sender will report an error and if +possible will try to forward the message to another endpoint. + +
    +
  • +UNKNOWN PACKET CMD is 1 byte long. +
  • +
  • +UNHANDLED MESSAGE SIZE is 16bits long. +
  • +
  • +UNHANDLED MESSAGE is an array of byte (length is contained in UNHANDLED MESSAGE SIZE) +
  • +
+ +NB:
+added UNHANDLED MESSAGE SIZE (development) +

+
+ +
Verification of connection before sending request
+

+NOTA: This fonctionality may never be used, since it may slow up the normal process +since requiring on the web-server side an extra IO (read) before forwarding +the request..... + +One of the beauty of socket APIs, is that you could write on a half closed socket. +When servlet engine close the socket, the web server will discover it only at the +next read() to the socket. +Basically, in the AJP13 protocol, the web server send the HTTP HEADER and HTTP BODY +(POST by chunk of 8K) to the servlet engine and then try to receive the reply. +If the connection was broken the web server will learn it only at receive time. + +We could use a buffering scheme but what happen when you use the servlet engine +for upload operations with more than 8ko of datas ? + +The hack in the AJP13 protocol is to add some bytes to read after the end of the +service : + +

+EXAMPLE OF DISCUSSION BETWEEN WEB SERVER AND SERVLET ENGINE
+
+AJP HTTP-HEADER (+ HTTP-POST)   (WEB->SERVLET)
+
+AJP HTTP-REPLY					(SERVLET->WEB)
+
+AJP END OF DISCUSSION			(SERVLET->WEB)
+						
+---> AJP STATUS 				(SERVLET->WEB AJP13)
+
+ +The AJP STATUS will not be read by the servlet engine at the end of +the request/response #N but at the begining of the next session. + +More at that time the web server could also use OS dependants functions +(or better APR functions) to determine if there is also more data +to read. And that datas could be CONTEXT Updates. + +This will avoid the web server sending a request to a +desactivated context. In that case, if the load-balancing is used, +it will search for another servlet engine to handle the request. + +And that feature will help ISP and big sites with farm of tomcat, +to updates their servlet engine without any service interruption. + +
++------------+-------------+
+| STATUS CMD | STATUS DATA |
++------------+-------------+
+
+ +
    +
  • +STATUS CMD and STATUS DATA are one byte long. +
  • +
+

+
+ +
Conclusion
+

+The goal of the extended AJP13 protocol is to overcome some of the original AJP13 limitation. +An easier configuration, a better support for large site and farm of Tomcat, +a simple authentification system and provision for protocol updates. + +Using the stable ajp13 implementation in JK (native) and in servlet +engine (java), it's a reasonable evolution of the well known ajp13. +

+
Commands and IDs in extended AJP13 Index
+

+Index of Commands and ID to be added in AJP13 Protocol +

+ +
Commands IDs
+

+ + + + + + + + + + + + + + + + + +
Command NameCommand Number
AJP13_LOGINIT_CMD0x10
AJP13_LOGSEED_CMD0x11
AJP13_LOGCOMP_CMD0x12
AJP13_LOGOK_CMD0x13
AJP13_LOGNOK_CMD0x14
AJP13_CONTEXT_QRY_CMD0x15
AJP13_CONTEXT_INFO_CMD0x16
AJP13_CONTEXT_UPDATE_CMD0x17
AJP13_STATUS_CMD0x18
AJP13_SHUTDOWN_CMD0x19
AJP13_SHUTOK_CMD0x1A
AJP13_SHUTNOK_CMD0x1B
AJP13_CONTEXT_STATE_CMD0x1C
AJP13_CONTEXT_STATE_REP_CMD0x1D
AJP13_UNKNOW_PACKET_CMD0x1E
+ +

+
+ +
Negociations Flags
+

+ + + + + + + + + + +
Command NameNumberDescription
AJP13_CONTEXT_INFO_NEG0x80000000web-server want context info after login
AJP13_CONTEXT_UPDATE_NEG0x40000000web-server want context updates
AJP13_GZIP_STREAM_NEG0x20000000web-server want compressed stream
AJP13_DES56_STREAM_NEG0x10000000web-server want crypted DES56 stream with secret key
AJP13_SSL_VSERVER_NEG0x08000000Extended info on server SSL vars
AJP13_SSL_VCLIENT_NEG0x04000000Extended info on client SSL vars
AJP13_SSL_VCRYPTO_NEG0x02000000Extended info on crypto SSL vars
AJP13_SSL_VMISC_NEG0x01000000Extended info on misc SSL vars
+ +
+ + + + + + + +
Negociation IDNumberDescription
AJP13_PROTO_SUPPORT_AJPXX_NEG0x00FF0000mask of protocol supported
AJP13_PROTO_SUPPORT_AJP13L1_NEG0x00010000communication could use AJP13 Level 1
AJP13_PROTO_SUPPORT_AJP13L2_NEG0x00020000communication could use AJP13 Level 2
AJP13_PROTO_SUPPORT_AJP13L3_NEG0x00040000communication could use AJP13 Level 3
+ +
+All others flags must be set to 0 since they are reserved for future use. + +

+
+ +
Failure IDs
+

+ + + + + + +
Failure IdNumber
AJP13_BAD_KEY_ERR0xFFFFFFFF
AJP13_ENGINE_DOWN_ERR0xFFFFFFFE
AJP13_RETRY_LATER_ERR0xFFFFFFFD
AJP13_SHUT_AUTHOR_FAILED_ERR0xFFFFFFFC
+

+
+ +
Status
+

+ + + + + +
Failure IdNumber
AJP13_CONTEXT_DOWN0x01
AJP13_CONTEXT_UP0x02
AJP13_CONTEXT_OK0x03
+

+
+ +

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/ajp/printer/ajpv13a.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/ajp/printer/ajpv13a.html new file mode 100644 index 00000000..53cf10a9 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/ajp/printer/ajpv13a.html @@ -0,0 +1,653 @@ +The Apache Tomcat Connector - AJP Protocol Reference - AJPv13
Apache TomcatApache Logo

The Apache Tomcat Connector - AJP Protocol Reference

AJPv13

Intro
+ +

+The original document was written by +Dan Milstein, danmil@shore.net +on December 2000. The present document is generated out of an xml file +to allow a more easy integration in the Tomcat documentation. + +

+ +

+This describes the Apache JServ Protocol version 1.3 (hereafter +ajp13). There is, apparently, no current documentation of how the +protocol works. This document is an attempt to remedy that, in order to +make life easier for maintainers of JK, and for anyone who wants to +port the protocol somewhere (into jakarta 4.x, for example). +

+ +
author
+ +

+I am not one of the designers of this protocol -- I believe that Gal +Shachor was the original designer. Everything in this document is derived +from the actual implementation I found in the tomcat 3.x code. I hope it +is useful, but I can't make any grand claims to perfect accuracy. I also +don't know why certain design decisions were made. Where I was able, I've +offered some possible justifications for certain choices, but those are +only my guesses. In general, the C code which Shachor wrote is very clean +and comprehensible (if almost totally undocumented). I've cleaned up the +Java code, and I think it's reasonably readable. +

+
Design Goals
+ +

+According to email from Gal Shachor to the jakarta-dev mailing list, +the original goals of JK (and thus ajp13) were to extend +mod_jserv and ajp12 by (I am only including the goals which +relate to communication between the web server and the servlet container): + +

    +
  • Increasing performance (speed, specifically).
  • + +
  • Adding support for SSL, so that isSecure() and + getScheme() will function correctly within the servlet + container. The client certificates and cipher suite will be + available to servlets as request attributes.
  • + +
+

+
Overview of the protocol
+ +

+The ajp13 protocol is packet-oriented. A binary format was +presumably chosen over the more readable plain text for reasons of +performance. The web server communicates with the servlet container over +TCP connections. To cut down on the expensive process of socket creation, +the web server will attempt to maintain persistent TCP connections to the +servlet container, and to reuse a connection for multiple request/response +cycles. +

+Once a connection is assigned to a particular request, it will not be +used for any others until the request-handling cycle has terminated. In +other words, requests are not multiplexed over connections. This makes +for much simpler code at either end of the connection, although it does +cause more connections to be open at once. +

+Once the web server has opened a connection to the servlet container, +the connection can be in one of the following states: +

+

    +
  • Idle
    No request is being handled over this connection.
  • +
  • Assigned
    The connecton is handling a specific request.
  • +
+ +

+Once a connection is assigned to handle a particular request, the basic +request informaton (e.g. HTTP headers, etc) is sent over the connection in +a highly condensed form (e.g. common strings are encoded as integers). +Details of that format are below in Request Packet Structure. If there is a +body to the request (content-length > 0), that is sent in a separate +packet immediately after. +

+At this point, the servlet container is presumably ready to start +processing the request. As it does so, it can send the +following messages back to the web server: + +

    +
  • SEND_HEADERS
    Send a set of headers back to the browser.
  • + +
  • SEND_BODY_CHUNK
    Send a chunk of body data back to the browser.
  • + +
  • GET_BODY_CHUNK
    Get further data from the request if it hasn't all + been transferred yet. This is necessary because the packets have a fixed + maximum size and arbitrary amounts of data can be included the body of a + request (for uploaded files, for example). (Note: this is unrelated to + HTTP chunked tranfer).
  • + +
  • END_RESPONSE
    Finish the request-handling cycle.
  • +
+

+ +Each message is accompanied by a differently formatted packet of data. See +Response Packet Structures below for details. +

+
Basic Packet Structure
+ +

+There is a bit of an XDR heritage to this protocol, but it differs in +lots of ways (no 4 byte alignment, for example). +

+Byte order: I am not clear about the endian-ness of the individual +bytes. I'm guessing the bytes are little-endian, because that's what XDR +specifies, and I'm guessing that sys/socket library is magically making +that so (on the C side). If anyone with a better knowledge of socket calls +can step in, that would be great. +

+There are four data types in the protocol: bytes, booleans, integers and +strings. + +

+
Byte
+
A single byte.
+ +
Boolean
+
A single byte, 1 = true, 0 = false. Using other non-zero values as + true (i.e. C-style) may work in some places, but it won't in + others.
+ +
Integer
+
A number in the range of 0 to 2^16 (32768). Stored in 2 bytes with + the high-order byte first.
+ +
String
+
A variable-sized string (length bounded by 2^16). Encoded with the + length packed into two bytes first, followed by the string (including the + terminating '\0'). Note that the encoded length does not include + the trailing '\0' -- it is like strlen. This is a touch + confusing on the Java side, which is littered with odd autoincrement + statements to skip over these terminators. I believe the reason this was + done was to allow the C code to be extra efficient when reading strings + which the servlet container is sending back -- with the terminating \0 + character, the C code can pass around references into a single buffer, + without copying. If the \0 was missing, the C code would have to copy + things out in order to get its notion of a string. Note a size of -1 + (65535) indicates a null string and no data follow the length in this + case.
+
+

+ +
Packet Size
+

+According to much of the code, the max packet +size is 8 * 1024 bytes (8K). The actual length of the packet is encoded in the +header. +

+
+ +
Packet Headers
+

+Packets sent from the server to the container begin with +0x1234. Packets sent from the container to the server begin +with AB (that's the ASCII code for A followed by the ASCII +code for B). After those first two bytes, there is an integer (encoded as +above) with the length of the payload. Although this might suggest that +the maximum payload could be as large as 2^16, in fact, the code sets the +maximum to be 8K. + + + + + + + + + + + + + + + + + + + + + + + +
Packet Format (Server->Container)
Byte01234...(n+3)
Contents0x120x34Data Length (n)Data
+ + + + + + + + + + + + + + + + + + + + + + +
Packet Format (Container->Server)
Byte01234...(n+3)
ContentsABData Length (n)Data
+

+

+ For most packets, the first byte of the +payload encodes the type of message. The exception is for request body +packets sent from the server to the container -- they are sent with a +standard packet header (0x1234 and then length of the packet), but without +any prefix code after that (this seems like a mistake to me). +

+The web server can send the following messages to the servlet container: + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
CodeType of PacketMeaning
2Forward RequestBegin the request-processing cycle with the following data
7ShutdownThe web server asks the container to shut itself down.
8PingThe web server asks the container to take control (secure login phase).
10CPingThe web server asks the container to respond quickly with a CPong.
noneDataSize (2 bytes) and corresponding body data.
+

+

+To ensure some +basic security, the container will only actually do the Shutdown if the +request comes from the same machine on which it's hosted. +

+

+The first Data packet is send immediatly after the Forward Request by the web server. +

+ +

The servlet container can send the following types of messages to the web +server: + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
CodeType of PacketMeaning
3Send Body ChunkSend a chunk of the body from the servlet container to the web + server (and presumably, onto the browser).
4Send HeadersSend the response headers from the servlet container to the web + server (and presumably, onto the browser).
5End ResponseMarks the end of the response (and thus the request-handling cycle).
6Get Body ChunkGet further data from the request if it hasn't all been transferred + yet.
9CPong ReplyThe reply to a CPing request
+

+

+Each of the above messages has a different internal structure, detailed below. +

+
+
Request Packet Structure
+ +

+For messages from the server to the container of type "Forward Request": +

+

+AJP13_FORWARD_REQUEST :=
+    prefix_code      (byte) 0x02 = JK_AJP13_FORWARD_REQUEST
+    method           (byte)
+    protocol         (string)
+    req_uri          (string)
+    remote_addr      (string)
+    remote_host      (string)
+    server_name      (string)
+    server_port      (integer)
+    is_ssl           (boolean)
+    num_headers      (integer)
+    request_headers *(req_header_name req_header_value)
+    attributes      *(attribut_name attribute_value)
+    request_terminator (byte) OxFF
+
+

+The request_headers have the following structure: +

+

+req_header_name := 
+    sc_req_header_name | (string)  [see below for how this is parsed]
+
+sc_req_header_name := 0xA0xx (integer)
+
+req_header_value := (string)
+
+

+ +The attributes are optional and have the following structure: +

+

+attribute_name := sc_a_name | (sc_a_req_attribute string)
+
+attribute_value := (string)
+
+
+

+Not that the all-important header is "content-length', because it +determines whether or not the container looks for another packet +immediately. +

+Detailed description of the elements of Forward Request. +

+
request_prefix
+

+For all requests, this will be 2. +See above for details on other prefix codes. +

+
+ +
method
+

+The HTTP method, encoded as a single byte: +

+ +

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Command NameCode
OPTIONS1
GET2
HEAD3
POST4
PUT5
DELETE6
TRACE7
PROPFIND8
PROPPATCH9
MKCOL10
COPY11
MOVE12
LOCK13
UNLOCK14
ACL15
REPORT16
VERSION-CONTROL17
CHECKIN18
CHECKOUT19
UNCHECKOUT20
SEARCH21
MKWORKSPACE22
UPDATE23
LABEL24
MERGE25
BASELINE_CONTROL26
MKACTIVITY27
+

+ +

Later version of ajp13, when used with mod_jk2, will transport +additional methods, even if they are not in this list. +

+ +
+ +
protocol, req_uri, remote_addr, remote_host, server_name, server_port, is_ssl
+

+ These are all fairly self-explanatory. Each of these is required, and + will be sent for every request. +

+
+ +
Headers
+

+ The structure of request_headers is the following: + First, the number of headers num_headers is encoded. + Then, a series of header name req_header_name / value + req_header_value pairs follows. + Common header names are encoded as integers, + to save space. If the header name is not in the list of basic headers, + it is encoded normally (as a string, with prefixed length). The list of + common headers sc_req_header_nameand their codes + is as follows (all are case-sensitive): +

+ + + + + + + + + + + + + + + + +
NameCode valueCode name
accept0xA001SC_REQ_ACCEPT
accept-charset0xA002SC_REQ_ACCEPT_CHARSET
accept-encoding0xA003SC_REQ_ACCEPT_ENCODING
accept-language0xA004SC_REQ_ACCEPT_LANGUAGE
authorization0xA005SC_REQ_AUTHORIZATION
connection0xA006SC_REQ_CONNECTION
content-type0xA007SC_REQ_CONTENT_TYPE
content-length0xA008SC_REQ_CONTENT_LENGTH
cookie0xA009SC_REQ_COOKIE
cookie20xA00ASC_REQ_COOKIE2
host0xA00BSC_REQ_HOST
pragma0xA00CSC_REQ_PRAGMA
referer0xA00DSC_REQ_REFERER
user-agent0xA00ESC_REQ_USER_AGENT
+

+ The Java code that reads this grabs the first two-byte integer and if + it sees an '0xA0' in the most significant + byte, it uses the integer in the second byte as an index into an array of + header names. If the first byte is not '0xA0', it assumes that the + two-byte integer is the length of a string, which is then read in. +

+ This works on the assumption that no header names will have length + greater than 0x9999 (==0xA000 - 1), which is perfectly reasonable, though + somewhat arbitrary. (If you, like me, started to think about the cookie + spec here, and about how long headers can get, fear not -- this limit is + on header names not header values. It seems unlikely that + unmanageably huge header names will be showing up in the HTTP spec any time + soon). +

+ Note: The content-length header is extremely + important. If it is present and non-zero, the container assumes that + the request has a body (a POST request, for example), and immediately + reads a separate packet off the input stream to get that body. +

+
+ +
Attributes
+

+ + The attributes prefixed with a ? + (e.g. ?context) are all optional. For each, there is a + single byte code to indicate the type of attribute, and then a string to + give its value. They can be sent in any order (thogh the C code always + sends them in the order listed below). A special terminating code is + sent to signal the end of the list of optional attributes. The list of + byte codes is: +

+ + + + + + + + + + + + + + + + + +
InformationCode ValueNote
?context0x01Not currently implemented
?servlet_path0x02Not currently implemented
?remote_user0x03
?auth_type0x04
?query_string0x05
?route0x06
?ssl_cert0x07
?ssl_cipher0x08
?ssl_session0x09
?req_attribute0x0AName (the name of the attribut follows)
?ssl_key_size0x0B
?secret0x0C
?stored_method0x0D
are_done0xFFrequest_terminator
+ +

+ + The context and servlet_path are not currently + set by the C code, and most of the Java code completely ignores whatever + is sent over for those fields (and some of it will actually break if a + string is sent along after one of those codes). I don't know if this is + a bug or an unimplemented feature or just vestigial code, but it's + missing from both sides of the connection. +

+ The remote_user and auth_type presumably refer + to HTTP-level authentication, and communicate the remote user's username + and the type of authentication used to establish their identity (e.g. Basic, + Digest). I'm not clear on why the password isn't also sent, but I don't + know HTTP authentication inside and out. +

+ The query_string, ssl_cert, + ssl_cipher, and ssl_session refer to the + corresponding pieces of HTTP and HTTPS. +

+ The route, as I understand it, is used to support sticky + sessions -- associating a user's sesson with a particular Tomcat instance + in the presence of multiple, load-balancing servers. I don't know the + details. +

+ Beyond this list of basic attributes, any number of other attributes can + be sent via the req_attribute code (0x0A). A pair of strings + to represent the attribute name and value are sent immediately after each + instance of that code. Environment values are passed in via this method. +

+ Finally, after all the attributes have been sent, the attribute terminator, + 0xFF, is sent. This signals both the end of the list of attributes and + also then end of the Request Packet. +

+
+ +
Response Packet Structure
+ +

+For messages which the container can send back to the server. + +

+AJP13_SEND_BODY_CHUNK := 
+  prefix_code   3
+  chunk_length  (integer)
+  chunk        *(byte)
+
+
+AJP13_SEND_HEADERS :=
+  prefix_code       4
+  http_status_code  (integer)
+  http_status_msg   (string)
+  num_headers       (integer)
+  response_headers *(res_header_name header_value)
+
+res_header_name := 
+    sc_res_header_name | (string)   [see below for how this is parsed]
+
+sc_res_header_name := 0xA0 (byte)
+
+header_value := (string)
+
+AJP13_END_RESPONSE :=
+  prefix_code       5
+  reuse             (boolean)
+
+
+AJP13_GET_BODY_CHUNK :=
+  prefix_code       6
+  requested_length  (integer)
+
+ +

+

+Details: +

+ +
Send Body Chunk
+

+ The chunk is basically binary data, and is sent directly back to the browser. +

+
+ +
Send Headers
+

+ The status code and message are the usual HTTP things (e.g. "200" and "OK"). + The response header names are encoded the same way the request header names are. + See above for details about how the the + codes are distinguished from the strings. The codes for common headers are: +

+ +

+ + + + + + + + + + + + + +
NameCode value
Content-Type0xA001
Content-Language0xA002
Content-Length0xA003
Date0xA004
Last-Modified0xA005
Location0xA006
Set-Cookie0xA007
Set-Cookie20xA008
Servlet-Engine0xA009
Status0xA00A
WWW-Authenticate0xA00B
+ +

+ +

+ After the code or the string header name, the header value is immediately + encoded. +

+ +
+ +
End Response
+

+ Signals the end of this request-handling cycle. If the + reuse flag is true (==1), this TCP connection can now be used to + handle new incoming requests. If reuse is false (anything + other than 1 in the actual C code), the connection should be closed. +

+
+ +
Get Body Chunk
+

+ The container asks for more data from the request (If the body was + too large to fit in the first packet sent over or when the request is + chuncked). + The server will send a body packet back with an amount of data which is + the minimum of the request_length, + the maximum send body size (8186 (8 Kbytes - 6)), and the + number of bytes actually left to send from the request body. +
+ If there is no more data in the body (i.e. the servlet container is + trying to read past the end of the body), the server will send back an + "empty" packet, which is a body packet with a payload length of 0. + (0x12,0x34,0x00,0x00) +

+
+
Questions I Have
+ +

What happens if the request headers > max packet size? There is no +provision to send a second packet of request headers in case there are more +than 8K (I think this is correctly handled for response headers, though I'm +not certain). I don't know if there is a way to get more than 8K worth of +data into that initial set of request headers, but I'll bet there is +(combine long cookies with long ssl information and a lot of environment +variables, and you should hit 8K easily). I think the connector would just +fail before trying to send any headers in this case, but I'm not certain.

+ +

What about authentication? There doesn't seem to be any authentication +of the connection between the web server and the container. This strikes +me as potentially dangerous.

+ +

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/ajp/printer/ajpv13ext.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/ajp/printer/ajpv13ext.html new file mode 100644 index 00000000..300f4b3c --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/ajp/printer/ajpv13ext.html @@ -0,0 +1,653 @@ +The Apache Tomcat Connector - AJP Protocol Reference - AJPv13 extensions Proposal
Apache TomcatApache Logo

The Apache Tomcat Connector - AJP Protocol Reference

AJPv13 extensions Proposal

Introduction
+

+This document is a proposal of evolution of the current +Apache JServ Protocol version 1.3, also known as ajp13. +I'll not cover here the full protocol but only the add-on from ajp13. + +This nth pass include comments from the tomcat-dev list and +misses discovered during developpment. +

+
Missing features in AJP13
+

+ajp13 is a good protocol to link a servlet engine like tomcat to a web server like Apache: + +

    +
  • +use persistants connections to avoid reconnect time at each request +
  • +
  • +encode many http commands to reduce stream size +
  • +
  • +send to servlet engine many info from web server (like SSL certs) +
  • +
+

+But ajp13 lacks support for : +

+
    +
  • + security between web server and servlet engine. + Anybody can connect to an ajp13 port (no login mecanism used) + You could connect, for example with telnet, and keep the remote thread + up by not sending any data (no timeout in connection) +
  • +
  • + context information passed from servlet engine to web server. + Part of the configuration of JK, the web server connector, is to + indicate to the web server which URI to handle. + The mod_jk JkMount directive, told to web server which URI must be + forwarded to servlet engine. + A servlet engine allready knows which URI it handle and TC 3.3 is + allready capable to generate a config file for JK from the list + of available contexts. +
  • +
  • + state update of contexts from servlet engine to web server. + Big site with farm of Tomcat, like ISP and virtuals hosters, + may need to stop a context for admin purposes. In that case the front + web server must know that the context is currently down, to eventually + relay the request to another Tomcat +
  • +
  • + verify state of connection before sending request. + Actually JK send the request to the servlet engine and next wait + for the answer. But one of the beauty of the socket API, is you that + you could write() to a closed connection without any error reporting, + but a read() to a closed connection return you the error code. +
  • +
+ +

+
+ +
Proposed add-ons to AJP13
+

+Let's descrive here the features and add-on that could be added to AJP13. +Since this document is a proposal, a reasonable level of chaos must be expected at first. +Be sure that discussion on tomcat list will help clarify points, add +features but the current list seems to be a 'minimun vital' + +

    + +
  • +Advanced login features at connect time +
  • + +
  • +Basic authorisation system, where a shared secret key is +present in web server and servlet engine. +
  • + +
  • +Basic protocol negociation, just to be sure that if functionnalities are added +to AJP13 in the future, current implementations will still works. +
  • + +
  • +Clean handling of 'Unknown packets' +
  • + +
  • +Extended env vars passed from web-server to servlet engine. +
  • + +
  • +Add extra SSL informations needed by Servlet 2.3 API (like SSL_KEY_SIZE) +
  • + +
+ +

+
+ +
Advanced login
+

+ +

    +
  1. +WEB-SERVER send LOGIN INIT CMD + NEGOCIATION DATA + WEB SERVER INFO +
  2. +
  3. + TOMCAT respond with LOGIN SEED CMD + RANDOM DATA +
  4. +
  5. + WEB-SERVER calculted the MD5 of RANDOM DATA+SECRET DATA +
  6. +
  7. + WEB-SERVER send LOGIN COMP CMD + MD5 (SECRET DATA + RANDOM DATA) +
  8. +
  9. + TOMCAT respond with LOGIN STATUS CMD + NEGOCIED DATA + SERVLET ENGINE INFO +
  10. +
+ +To prevent DOS attack, the servlet engine will wait +the LOGIN CMD only 15/30 seconds and reports the +timeout exception for admins investigation. + +The login command will contains basic protocol +negociation information like compressing ability, +crypto, context info (at start up), context update at +run-time (up/down), level of SSL env vars, AJP protocol +level supported (level1/level2/level3...) + +The Web server info will contain web server info and +connector name (ie Apache 1.3.26 + mod_ssl 2.8.8 + mod_jk 1.2.1 + mod_perl 1.25). + +The servlet engine will mask the negociation mask with it's own +mask (what it can do) and return it when loggin is accepted. + +This will help having a basic AJP13 implementation (level 1) +on a web-server working with a more advanced protocol handler on +the servlet engine side or vice-versa. + +AJP13 was designed to be small and fast and so many +SSL informations present in the web-server are not +forwarded to the servlet engine. + +We add here four negociations flags to provide more +informations on client SSL data (certs), server SSL datas, +crypto used, and misc datas (timeout...). +

+
+ +
Messages Stream
+

+

++----------------+------------------+-----------------+
+| LOGIN INIT CMD | NEGOCIATION DATA | WEB SERVER INFO |
++----------------+------------------+-----------------+
+
++----------------+----------------+
+| LOGIN SEED CMD | MD5 of entropy |
++----------------+----------------+
+
++----------------+----------------------------+
+| LOGIN COMP CMD | MD5 of RANDOM + SECRET KEY |
++----------------+----------------------------+
+
++-----------+---------------+---------------------+
+| LOGOK CMD | NEGOCIED DATA | SERVLET ENGINE INFO |
++-----------+---------------+---------------------+
+
++------------+--------------+
+| LOGNOK CMD | FAILURE CODE |
++------------+--------------+
+
+ +
    +
  • +LOGIN INIT CMD, LOGIN SEED CMD, LOGIN COMP CMD, LOGOK CMD, LOGNOK CMD are 1 byte long. +
  • +
  • +MD5, MD5 of RANDOM + SECRET KEY are 32 chars long. +
  • +
  • +NEGOCIATION DATA, NEGOCIED DATA, FAILURE CODE are 32 bits long. +
  • +
  • +WEB SERVER INFO, SERVLET ENGINE INFO are CString. +
  • +
+ +The secret key will be set by a new propertie in +workers.properties : secretkey +
+worker.ajp13.port=8009
+worker.ajp13.host=localhost
+worker.ajp13.type=ajp13
+worker.ajp13.secretkey=myverysecretkey
+
+

+
+ +
Shutdown feature
+

+AJP13 miss a functionnality of AJP12, which is shutdown command. +A logout will tell servlet engine to shutdown itself. +

++--------------+----------------------------+
+| SHUTDOWN CMD | MD5 of RANDOM + SECRET KEY |
++--------------+----------------------------+
+
++------------+
+| SHUTOK CMD |
++------------+
+
++-------------+--------------+
+| SHUTNOK CMD | FAILURE CODE |
++-------------+--------------+
+
+ +
    +
  • +SHUTDOWN CMD, SHUTOK CMD, SHUTNOK CMD are 1 byte long. +
  • +
  • +MD5 of RANDOM + SECRET KEY are 32 chars long. +
  • +
  • +FAILURE CODE is 32 bits long. +
  • +
+ +

+
+ +
Extended Env Vars feature
+

+NOTA: + +While working on AJP13 in JK, I really discovered "JkEnvVar". +The following "Extended Env Vars feature" description may not +be implemented in extended AJP13 since allready available in original +implementation. + +DESC: + +Many users will want to see some of their web-server env vars +passed to their servlet engine. + +To reduce the network traffic, the web-servlet will send a +table to describing the external vars in a shorter fashion. + +We'll use there a functionnality allready present in AJP13, +attributes list : + +In the AJP13, we've got : + +

+AJP13_FORWARD_REQUEST :=
+    prefix_code      2
+    method           (byte)
+    protocol         (string)
+    req_uri          (string)
+    remote_addr      (string)
+    remote_host      (string)
+    server_name      (string)
+    server_port      (integer)
+    is_ssl           (boolean)
+    num_headers      (integer)
+    request_headers *(req_header_name req_header_value)
+
+    ?context       (byte string)
+    ?servlet_path  (byte string)
+    ?remote_user   (byte string)
+    ?auth_type     (byte string)
+    ?query_string  (byte string)
+    ?route         (byte string)
+    ?ssl_cert      (byte string)
+    ?ssl_cipher    (byte string)
+    ?ssl_session   (byte string)
+
+    ?attributes   *(attribute_name attribute_value)
+    request_terminator (byte)
+
+ +Using short 'web server attribute name' will reduce the +network traffic. + +
++-------------------+---------------------------+-------------------------------+----+
+| EXTENDED VARS CMD | WEB SERVER ATTRIBUTE NAME | SERVLET ENGINE ATTRIBUTE NAME | ES |
++-------------------+---------------------------+-------------------------------+----+
+
+ +ie : + +
+JkExtVars S1 SSL_CLIENT_V_START javax.servlet.request.ssl_start_cert_date
+JkExtVars S2 SSL_CLIENT_V_END   javax.servlet.request.ssl_end_cert_date
+JkExtVars S3 SSL_SESSION_ID     javax.servlet.request.ssl_session_id
+
+
++-------------------+----+-------------------------------------------+
+| EXTENDED VARS CMD | S1 | javax.servlet.request.ssl_start_cert_date |
++-------------------+----+-------------------------------------------+
++----+-----------------------------------------+
+| S2 | javax.servlet.request.ssl_end_cert_date |
++----+-----------------------------------------+
++----+-----------------------------------------+
+| S3 | javax.servlet.request.ssl_end_cert_date |
++----+-----------------------------------------+
+
+ +During transmission in extended AJP13 we'll see attributes name +containing S1, S2, S3 and attributes values of +2001/01/03, 2002/01/03, 0123AFE56. + +This example showed the use of extended SSL vars but +any 'personnal' web-server vars like custom authentification +vars could be reused in the servlet engine. +The cost will be only some more bytes in the AJP traffic. + +
    +
  • +EXTENDED VARS CMD is 1 byte long. +
  • +
  • +WEB SERVER ATTRIBUTE NAME, SERVLET ENGINE ATTRIBUTE NAME are CString. +
  • +
  • +ES is an empty CString. +
  • +
+ +

+
+ +
Context informations forwarding for Servlet engine to Web Server
+

+Just after the LOGON PHASE, the web server will ask for the list of contexts +and URLs/URIs handled by the servlet engine. +It will ease installation in many sites, reduce questions about configuration +on tomcat-user list, and be ready for servlet API 2.3. + +This mode will be activated by a new directive JkAutoMount + +ie: JkAutoMount examples myworker1 /examples/ + +If we want to get ALL the contexts handled by the servlet engine, willcard +could be used : + +ie: JkAutoMount * myworker1 * + +A servlet engine could have many contexts, /examples, /admin, /test. +We may want to use only some contexts for a given worker. It was +done previously, in apache HTTP server for example, by setting by +hand the JkMount accordingly in each [virtual] area of Apache. + +If you web-server support virtual hosting, we'll forward also that +information to servlet engine which will only return contexts for +that virtual host. +In that case the servlet engine will only return the URL/URI matching +these particular virtual server (defined in server.xml). +This feature will help ISP and big sites which mutualize large farm +of Tomcat in load-balancing configuration. + +

++-----------------+-------------------+----------+----------+----+
+| CONTEXT QRY CMD | VIRTUAL HOST NAME | CONTEXTA | CONTEXTB | ES |
++-----------------+-------------------+----------+----------+----+
+
++------------------+-------------------+----------+-------------------+----------+---------------+----+
+| CONTEXT INFO CMD | VIRTUAL HOST NAME | CONTEXTA | URL1 URL2 URL3 ES | CONTEXTB | URL1 URL2 ... | ES |
++------------------+-------------------+----------+-------------------+----------+---------------+----+
+
+ +We'll discover via context-query, the list of URL/MIMES handled by the remove servlet engine +for a list of contextes. +In wildcard mode, CONTEXTA will contains just '*'. + +
    +
  • +CONTEXT QRY CMD and CONTEXT INFO CMD are 1 byte long. +
  • +
  • +VIRTUAL HOST NAME is a CString, ie an array of chars terminated by a null byte (/0). +
  • +
  • +An empty string is just a null byte (/0). +
  • +
  • +ES is an empty CString. Indicate end of URI/URLs or end of CONTEXTs. +
  • +
+ +NB:
+When VirtualMode is not to be used, the VIRTUAL HOST NAME is '*'. +In that case the servlet engine will send all contexts handled. +

+
+ +
Context informations updates from Servlet engine to Web Server
+

+Context update are messages caming from the servlet engine each time a context +is desactivated/reactivated. The update will be in use when the directive JkUpdateMount. +This directive will set the AJP13_CONTEXT_UPDATE_NEG flag. + +ie: JkUpdateMount myworker1 + +

++--------------------+-------------------+----------+--------+----------+--------+----+
+| CONTEXT UPDATE CMD | VIRTUAL HOST NAME | CONTEXTA | STATUS | CONTEXTB | STATUS | ES |
++--------------------+-------------------+----------+--------+----------+--------+----+
+
+ +
    +
  • +CONTEXT UPDATE CMD, STATUS are 1 byte long. +
  • +
  • +VIRTUAL HOST NAME, CONTEXTS are CString. +
  • +
  • +ES is an empty CString. Indicate end of CONTEXTs. +
  • +
+ +NB:
+When VirtualMode is not in use, the VIRTUAL HOST NAME is '*'. +STATUS is one byte indicating if context is UP/DOWN/INVALID +

+
+ +
Context status query to Servlet engine
+

+This query will be used by the web-server to determine if a given +contexts are UP, DOWN or INVALID (and should be removed). + +

++-------------------+--------------------+----------+----------+----+
+| CONTEXT STATE CMD |  VIRTUAL HOST NAME | CONTEXTA | CONTEXTB | ES |
++-------------------+--------------------+----------+----------+----+
+
++-------------------------+-------------------+----------+--------+----------+--------+----+
+| CONTEXT STATE REPLY CMD | VIRTUAL HOST NAME | CONTEXTA | STATUS | CONTEXTB | STATUS | ES |
++-------------------------+-------------------+----------+-------------------+--------+----+
+
+ +
    +
  • +CONTEXT STATE CMD, CONTEXT STATE REPLY CMD, STATUS are 1 byte long. +
  • +
  • +VIRTUAL HOST NAME, CONTEXTs are CString +
  • +
  • +ES is an empty CString +
  • +
+ +NB:
+When VirtualMode is not in use, the VIRTUAL HOST NAME is an empty string. +

+
+ +
Handling of unknown packets
+

+Sometimes even with a well negocied protocol, we may be in a situation +where one end (web server or servlet engine), will receive a message it +couldn't understand. In that case the receiver will send an +'UNKNOW PACKET CMD' with attached the unhandled message. + +

++--------------------+------------------------+-------------------+
+| UNKNOWN PACKET CMD | UNHANDLED MESSAGE SIZE | UNHANDLED MESSAGE |
++--------------------+------------------------+-------------------+
+
+ +Depending on the message, the sender will report an error and if +possible will try to forward the message to another endpoint. + +
    +
  • +UNKNOWN PACKET CMD is 1 byte long. +
  • +
  • +UNHANDLED MESSAGE SIZE is 16bits long. +
  • +
  • +UNHANDLED MESSAGE is an array of byte (length is contained in UNHANDLED MESSAGE SIZE) +
  • +
+ +NB:
+added UNHANDLED MESSAGE SIZE (development) +

+
+ +
Verification of connection before sending request
+

+NOTA: This fonctionality may never be used, since it may slow up the normal process +since requiring on the web-server side an extra IO (read) before forwarding +the request..... + +One of the beauty of socket APIs, is that you could write on a half closed socket. +When servlet engine close the socket, the web server will discover it only at the +next read() to the socket. +Basically, in the AJP13 protocol, the web server send the HTTP HEADER and HTTP BODY +(POST by chunk of 8K) to the servlet engine and then try to receive the reply. +If the connection was broken the web server will learn it only at receive time. + +We could use a buffering scheme but what happen when you use the servlet engine +for upload operations with more than 8ko of datas ? + +The hack in the AJP13 protocol is to add some bytes to read after the end of the +service : + +

+EXAMPLE OF DISCUSSION BETWEEN WEB SERVER AND SERVLET ENGINE
+
+AJP HTTP-HEADER (+ HTTP-POST)   (WEB->SERVLET)
+
+AJP HTTP-REPLY					(SERVLET->WEB)
+
+AJP END OF DISCUSSION			(SERVLET->WEB)
+						
+---> AJP STATUS 				(SERVLET->WEB AJP13)
+
+ +The AJP STATUS will not be read by the servlet engine at the end of +the request/response #N but at the begining of the next session. + +More at that time the web server could also use OS dependants functions +(or better APR functions) to determine if there is also more data +to read. And that datas could be CONTEXT Updates. + +This will avoid the web server sending a request to a +desactivated context. In that case, if the load-balancing is used, +it will search for another servlet engine to handle the request. + +And that feature will help ISP and big sites with farm of tomcat, +to updates their servlet engine without any service interruption. + +
++------------+-------------+
+| STATUS CMD | STATUS DATA |
++------------+-------------+
+
+ +
    +
  • +STATUS CMD and STATUS DATA are one byte long. +
  • +
+

+
+ +
Conclusion
+

+The goal of the extended AJP13 protocol is to overcome some of the original AJP13 limitation. +An easier configuration, a better support for large site and farm of Tomcat, +a simple authentification system and provision for protocol updates. + +Using the stable ajp13 implementation in JK (native) and in servlet +engine (java), it's a reasonable evolution of the well known ajp13. +

+
Commands and IDs in extended AJP13 Index
+

+Index of Commands and ID to be added in AJP13 Protocol +

+ +
Commands IDs
+

+ + + + + + + + + + + + + + + + + +
Command NameCommand Number
AJP13_LOGINIT_CMD0x10
AJP13_LOGSEED_CMD0x11
AJP13_LOGCOMP_CMD0x12
AJP13_LOGOK_CMD0x13
AJP13_LOGNOK_CMD0x14
AJP13_CONTEXT_QRY_CMD0x15
AJP13_CONTEXT_INFO_CMD0x16
AJP13_CONTEXT_UPDATE_CMD0x17
AJP13_STATUS_CMD0x18
AJP13_SHUTDOWN_CMD0x19
AJP13_SHUTOK_CMD0x1A
AJP13_SHUTNOK_CMD0x1B
AJP13_CONTEXT_STATE_CMD0x1C
AJP13_CONTEXT_STATE_REP_CMD0x1D
AJP13_UNKNOW_PACKET_CMD0x1E
+ +

+
+ +
Negociations Flags
+

+ + + + + + + + + + +
Command NameNumberDescription
AJP13_CONTEXT_INFO_NEG0x80000000web-server want context info after login
AJP13_CONTEXT_UPDATE_NEG0x40000000web-server want context updates
AJP13_GZIP_STREAM_NEG0x20000000web-server want compressed stream
AJP13_DES56_STREAM_NEG0x10000000web-server want crypted DES56 stream with secret key
AJP13_SSL_VSERVER_NEG0x08000000Extended info on server SSL vars
AJP13_SSL_VCLIENT_NEG0x04000000Extended info on client SSL vars
AJP13_SSL_VCRYPTO_NEG0x02000000Extended info on crypto SSL vars
AJP13_SSL_VMISC_NEG0x01000000Extended info on misc SSL vars
+ +
+ + + + + + + +
Negociation IDNumberDescription
AJP13_PROTO_SUPPORT_AJPXX_NEG0x00FF0000mask of protocol supported
AJP13_PROTO_SUPPORT_AJP13L1_NEG0x00010000communication could use AJP13 Level 1
AJP13_PROTO_SUPPORT_AJP13L2_NEG0x00020000communication could use AJP13 Level 2
AJP13_PROTO_SUPPORT_AJP13L3_NEG0x00040000communication could use AJP13 Level 3
+ +
+All others flags must be set to 0 since they are reserved for future use. + +

+
+ +
Failure IDs
+

+ + + + + + +
Failure IdNumber
AJP13_BAD_KEY_ERR0xFFFFFFFF
AJP13_ENGINE_DOWN_ERR0xFFFFFFFE
AJP13_RETRY_LATER_ERR0xFFFFFFFD
AJP13_SHUT_AUTHOR_FAILED_ERR0xFFFFFFFC
+

+
+ +
Status
+

+ + + + + +
Failure IdNumber
AJP13_CONTEXT_DOWN0x01
AJP13_CONTEXT_UP0x02
AJP13_CONTEXT_OK0x03
+

+
+ +

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/loadbalancers.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/loadbalancers.html new file mode 100644 index 00000000..06a1ee5a --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/loadbalancers.html @@ -0,0 +1,207 @@ +The Apache Tomcat Connector - Generic HowTo - LoadBalancer HowTo
Apache TomcatApache Logo

Links

Reference Guide

Generic HowTo

Webserver HowTo

AJP Protocol Reference

Miscellaneous Documentation

News

The Apache Tomcat Connector - Generic HowTo

LoadBalancer HowTo

Printer Friendly Version
print-friendly
version +
Introduction
+
+

A load balancer is a worker that does not directly communicate with Tomcat. +Instead it is responsible for the management of several "real" workers, +called members or sub workers of the load balancer.

+

+This management includes: +

+
    +
  • +Instantiating the workers in the web server. +
  • +
  • +Using the worker's load-balancing factor, perform weighted load balancing +(distributing load according to defined strengths of the targets). +
  • +
  • +Keeping requests belonging to the same session executing on the same Tomcat +(session stickyness). +
  • +
  • +Identifying failed Tomcat workers, suspending requests to them and instead +falling-back on other workers managed by the load balancer. +
  • +
  • +Providing status and load metrics for the load balancer itself and all +members via the status worker interface. +
  • +
  • +Allowing to dynamically reconfigure load-balancing via the status worker +interface. +
  • +
+

+Workers managed by the same load balancer worker are load-balanced +(based on their configured balancing factors and current request or session load) +and also secured against failure by providing failover to other members of the same +load balancer. So a single Tomcat process death will not "kill" the entire site. +

+

Some of the features provided by a load balancer are even interesting, when +only working with a single member worker (where load balancing is not possible).

+ +
Basic Load Balancer Properties
+

A worker is configured as a load balancer by setting its worker type +to lb. +

+

+The following table specifies some properties used to configure a load balancer worker: +

+
    +
  • balance_workers is a comma separated list of names of the member workers of the +load balancer. These workers are typically of type ajp13. The member workers do +not need to appear in the worker.list property themselves, adding the +load balancer to it suffices.
  • +
  • sticky_session specifies whether requests with SESSION ID's should be routed +back to the same Tomcat instance that created the session. You can set sticky_session to +False when Tomcat is using a session manager which can share session data across +multiple instances of Tomcat - or if your application is stateless. +By default sticky_session is set to True.
  • +
  • lbfactor can be added to each member worker to configure individual +strengths for the members. A higher lbfactor will lead to more +requests being balanced to that worker. The factors must be given by integers and the +load will be distributed proportional to the factors given. Higher factors lead to +more requests.
  • +
+ +
+  # The load balancer worker balance1 will distribute
+  # load to the members worker1 and worker2
+  worker.balance1.type=lb
+  worker.balance1.balance_workers=worker1, worker2
+  worker.worker1.type=ajp13
+  worker.worker1.host=myhost1
+  worker.worker1.port=8009
+  worker.worker2.type=ajp13
+  worker.worker1.host=myhost2
+  worker.worker1.port=8009
+
+ +

+Session stickyness is not implemented using a tracking table for sessions. +Instead each Tomcat instance gets an individual name and adds its name at +the end of the session id. When the load balancer sees a session id, it +finds the name of the Tomcat instance and sends the request via the correct +member worker. For this to work you must set the name of the Tomcat instances +as the value of the jvmRoute attribute in the Engine element of +each Tomcat's server.xml. The name of the Tomcat needs to be equal to the name +of the corresponding load balancer member. In the above example, Tomcat on host +"myhost1" needs jvmRoute="worker1", Tomcat on host "myhost2" +needs jvmRoute="worker2". +

+ +

For a complete reference of all load balancer configuration +attributes, please consult the worker reference. +

+
+ +
Advanced Load Balancer Worker Properties
+

The load balancer supports complex topologies and failover configurations. +Using the member attribute distance you can group members. +The load balancer will always send a request to a member of lowest distance. +Only when all of those are broken, it will balance to the members of the +next higher configured distance. This allows to define priorities between +Tomcat instances in different data center locations. +

+

When working with shared sessions, either by using session replication +or a persisting session manager (e.g. via a database), one often splits +up the Tomcat farm into replication groups. In case of failure of a member, +the load balancer needs to know, which other members share the session. +This is configured using the domain attribute. All workers +with the same domain are assumed to share the sessions.

+

For maintenance purposes you can tell the load balancer to not +allow any new sessions on some members, or even not use them at all. +This is controlled by the member attribute activation. +The value Active allows normal use of a member, disabled +will not create new sessions on it, but still allow sticky requests, +and stopped will no longer send any requests to the member. +Switching the activation from "active" to "disabled" some time before +maintenance will drain the sessions on the worker and minimize disruption. +Depending on the usage pattern of the application, draining will take from +minutes to hours. Switching the worker to stopped immediately before +maintenance will reduce logging of false errors by mod_jk.

+

Finally you can also configure hot spare workers by using +activation set to disabled in combination with +the attribute redirect added to the other workers:

+ +
+  # The advanced router LB worker
+  worker.list=router
+  worker.router.type=lb
+  worker.router.balance_workers=worker1,worker2
+
+  # Define the first member worker
+  worker.worker1.type=ajp13
+  worker.worker1.host=myhost1
+  worker.worker1.port=8009
+  # Define preferred failover node for worker1
+  worker.worker1.redirect=worker2
+
+  # Define the second member worker
+  worker.worker2.type=ajp13
+  worker.worker2.host=myhost2
+  worker.worker2.port=8009
+  # Disable worker2 for all requests except failover
+  worker.worker2.activation=disabled
+
+ +

+The redirect flag on worker1 tells the load balancer +to redirect the requests to worker2 in case that worker1 has a problem. +In all other cases worker2 will not receive any requests, thus acting +like a hot standby. +

+ +

A final note about setting activation to disabled: +The session id coming with a request is send either +as part of the request URL (;jsessionid=...) or via a cookie. +When using bookmarks or browsers that are running since a long time, +it is possible to send a request carrying an old and invalid session id +pointing at a disabled member. +Since the load balancer does not have a list of valid sessions, it will +forward the request to the disabled member. Thus draining takes longer than +expected. To handle such cases, you can add a Servlet filter to your web +application, which checks the request attribute JK_LB_ACTIVATION. +This attribute contains one of the strings "ACT", "DIS" or "STP". If you +detect "DIS" and the session for the request is no longer active, delete the +session cookie and redirect using a self-referential URL. The redirected +request will then no longer carry session information and thus the load +balancer will not send it to the disabled worker. The request attribute +JK_LB_ACTIVATION has been added in version 1.2.32.

+
+ +
Status Worker properties
+

+The status worker does not communicate with Tomcat. +Instead it is responsible for the worker management. It is +especially useful when combined with load balancer workers. +

+
+  # Add the status worker to the worker list
+  worker.list=jkstatus
+  # Define a 'jkstatus' worker using status
+  worker.jkstatus.type=status
+
+

Next thing is to mount the requests to the jkstatus worker. For Apache +web servers use the:

+
+  # Add the jkstatus mount point
+  JkMount /jkmanager/* jkstatus 
+
+

To obtain a higher level of security use the:

+
+  # Enable the JK manager access from localhost only
+ <Location /jkmanager/>
+    JkMount jkstatus
+    Order deny,allow
+    Deny from all
+    Allow from 127.0.0.1
+ </Location>
+
+ +
+ +

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/printer/loadbalancers.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/printer/loadbalancers.html new file mode 100644 index 00000000..22999c94 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/printer/loadbalancers.html @@ -0,0 +1,206 @@ +The Apache Tomcat Connector - Generic HowTo - LoadBalancer HowTo
Apache TomcatApache Logo

The Apache Tomcat Connector - Generic HowTo

LoadBalancer HowTo

Introduction
+
+

A load balancer is a worker that does not directly communicate with Tomcat. +Instead it is responsible for the management of several "real" workers, +called members or sub workers of the load balancer.

+

+This management includes: +

+
    +
  • +Instantiating the workers in the web server. +
  • +
  • +Using the worker's load-balancing factor, perform weighted load balancing +(distributing load according to defined strengths of the targets). +
  • +
  • +Keeping requests belonging to the same session executing on the same Tomcat +(session stickyness). +
  • +
  • +Identifying failed Tomcat workers, suspending requests to them and instead +falling-back on other workers managed by the load balancer. +
  • +
  • +Providing status and load metrics for the load balancer itself and all +members via the status worker interface. +
  • +
  • +Allowing to dynamically reconfigure load-balancing via the status worker +interface. +
  • +
+

+Workers managed by the same load balancer worker are load-balanced +(based on their configured balancing factors and current request or session load) +and also secured against failure by providing failover to other members of the same +load balancer. So a single Tomcat process death will not "kill" the entire site. +

+

Some of the features provided by a load balancer are even interesting, when +only working with a single member worker (where load balancing is not possible).

+ +
Basic Load Balancer Properties
+

A worker is configured as a load balancer by setting its worker type +to lb. +

+

+The following table specifies some properties used to configure a load balancer worker: +

+
    +
  • balance_workers is a comma separated list of names of the member workers of the +load balancer. These workers are typically of type ajp13. The member workers do +not need to appear in the worker.list property themselves, adding the +load balancer to it suffices.
  • +
  • sticky_session specifies whether requests with SESSION ID's should be routed +back to the same Tomcat instance that created the session. You can set sticky_session to +False when Tomcat is using a session manager which can share session data across +multiple instances of Tomcat - or if your application is stateless. +By default sticky_session is set to True.
  • +
  • lbfactor can be added to each member worker to configure individual +strengths for the members. A higher lbfactor will lead to more +requests being balanced to that worker. The factors must be given by integers and the +load will be distributed proportional to the factors given. Higher factors lead to +more requests.
  • +
+ +
+  # The load balancer worker balance1 will distribute
+  # load to the members worker1 and worker2
+  worker.balance1.type=lb
+  worker.balance1.balance_workers=worker1, worker2
+  worker.worker1.type=ajp13
+  worker.worker1.host=myhost1
+  worker.worker1.port=8009
+  worker.worker2.type=ajp13
+  worker.worker1.host=myhost2
+  worker.worker1.port=8009
+
+ +

+Session stickyness is not implemented using a tracking table for sessions. +Instead each Tomcat instance gets an individual name and adds its name at +the end of the session id. When the load balancer sees a session id, it +finds the name of the Tomcat instance and sends the request via the correct +member worker. For this to work you must set the name of the Tomcat instances +as the value of the jvmRoute attribute in the Engine element of +each Tomcat's server.xml. The name of the Tomcat needs to be equal to the name +of the corresponding load balancer member. In the above example, Tomcat on host +"myhost1" needs jvmRoute="worker1", Tomcat on host "myhost2" +needs jvmRoute="worker2". +

+ +

For a complete reference of all load balancer configuration +attributes, please consult the worker reference. +

+
+ +
Advanced Load Balancer Worker Properties
+

The load balancer supports complex topologies and failover configurations. +Using the member attribute distance you can group members. +The load balancer will always send a request to a member of lowest distance. +Only when all of those are broken, it will balance to the members of the +next higher configured distance. This allows to define priorities between +Tomcat instances in different data center locations. +

+

When working with shared sessions, either by using session replication +or a persisting session manager (e.g. via a database), one often splits +up the Tomcat farm into replication groups. In case of failure of a member, +the load balancer needs to know, which other members share the session. +This is configured using the domain attribute. All workers +with the same domain are assumed to share the sessions.

+

For maintenance purposes you can tell the load balancer to not +allow any new sessions on some members, or even not use them at all. +This is controlled by the member attribute activation. +The value Active allows normal use of a member, disabled +will not create new sessions on it, but still allow sticky requests, +and stopped will no longer send any requests to the member. +Switching the activation from "active" to "disabled" some time before +maintenance will drain the sessions on the worker and minimize disruption. +Depending on the usage pattern of the application, draining will take from +minutes to hours. Switching the worker to stopped immediately before +maintenance will reduce logging of false errors by mod_jk.

+

Finally you can also configure hot spare workers by using +activation set to disabled in combination with +the attribute redirect added to the other workers:

+ +
+  # The advanced router LB worker
+  worker.list=router
+  worker.router.type=lb
+  worker.router.balance_workers=worker1,worker2
+
+  # Define the first member worker
+  worker.worker1.type=ajp13
+  worker.worker1.host=myhost1
+  worker.worker1.port=8009
+  # Define preferred failover node for worker1
+  worker.worker1.redirect=worker2
+
+  # Define the second member worker
+  worker.worker2.type=ajp13
+  worker.worker2.host=myhost2
+  worker.worker2.port=8009
+  # Disable worker2 for all requests except failover
+  worker.worker2.activation=disabled
+
+ +

+The redirect flag on worker1 tells the load balancer +to redirect the requests to worker2 in case that worker1 has a problem. +In all other cases worker2 will not receive any requests, thus acting +like a hot standby. +

+ +

A final note about setting activation to disabled: +The session id coming with a request is send either +as part of the request URL (;jsessionid=...) or via a cookie. +When using bookmarks or browsers that are running since a long time, +it is possible to send a request carrying an old and invalid session id +pointing at a disabled member. +Since the load balancer does not have a list of valid sessions, it will +forward the request to the disabled member. Thus draining takes longer than +expected. To handle such cases, you can add a Servlet filter to your web +application, which checks the request attribute JK_LB_ACTIVATION. +This attribute contains one of the strings "ACT", "DIS" or "STP". If you +detect "DIS" and the session for the request is no longer active, delete the +session cookie and redirect using a self-referential URL. The redirected +request will then no longer carry session information and thus the load +balancer will not send it to the disabled worker. The request attribute +JK_LB_ACTIVATION has been added in version 1.2.32.

+
+ +
Status Worker properties
+

+The status worker does not communicate with Tomcat. +Instead it is responsible for the worker management. It is +especially useful when combined with load balancer workers. +

+
+  # Add the status worker to the worker list
+  worker.list=jkstatus
+  # Define a 'jkstatus' worker using status
+  worker.jkstatus.type=status
+
+

Next thing is to mount the requests to the jkstatus worker. For Apache +web servers use the:

+
+  # Add the jkstatus mount point
+  JkMount /jkmanager/* jkstatus 
+
+

To obtain a higher level of security use the:

+
+  # Enable the JK manager access from localhost only
+ <Location /jkmanager/>
+    JkMount jkstatus
+    Order deny,allow
+    Deny from all
+    Allow from 127.0.0.1
+ </Location>
+
+ +
+ +

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/printer/proxy.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/printer/proxy.html new file mode 100644 index 00000000..043fe48a --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/printer/proxy.html @@ -0,0 +1,312 @@ +The Apache Tomcat Connector - Generic HowTo - Reverse Proxy HowTo
Apache TomcatApache Logo

The Apache Tomcat Connector - Generic HowTo

Reverse Proxy HowTo

Introduction
+
+

The Apache module mod_jk and its ISAPI and NSAPI variants connect +a web server to a backend (typically Tomcat) using the AJP protocol. +The web server receives an HTTP(S) request and the module forwards +the request to the backend. This function is usually called a gateway +or a proxy, in the context of HTTP it is called a reverse proxy. +

+
Typical Problems
+
+

A reverse proxy is not totally transparent to the application on +the backend. For instance the host name and port the original client +(e.g. browser) needs to talk to belong to the web server and not to the +backend, so the reverse proxy talks to a different host name and port. +When the application on the backend returns content including +self-referential URLs using its own backend address and port, the +client will usually not be able to use these URLs. +

+

Another example is the client IP address, which for the web server is the +source IP of the incoming connection, whereas for the backend the +connection always comes from the web server. This can be a problem, when +the client IP is used by the backend application e.g. for security reasons. +

+
AJP as a Solution
+
+

Most of these problems are automatically handled by the AJP protocol +and the AJP connectors of the backend. The AJP protocol transports +this communication metadata and the backend connector presents this +metadata whenever the application asks for it using Servlet API methods. +

+

The following list contains the communication metadata handled by AJP +and the ServletRequest/HttpServletRequest API calls which can be used to retrieve them: +

    +
  • local name: getLocalName() and getLocalAddr. +This is also equal to getServerName(), unless a Host header +is contained in the request. In this case the server name is taken from that header. +
  • +
  • local port: getLocalPort() +This is also equal to getServerPort(), unless a Host header +is contained in the request. In this case the server port is taken from that header +if it contains an explicit port, or is equal to the default port of the scheme used. +
  • +
  • client address: getRemoteAddr() +
  • +
  • client port: getRemotePort() +The remote port was initially not supported. It is available when using mod_jk 1.2.32 +with Apache or IIS (not for the NSAPI plugin) together with Tomcat version at least +5.5.28, 6.0.20 or 7.0.0. For older versions, getRemotePort() +will incorrectly return 0 or -1. As a workaround you can forward the remote port by setting +JkEnvVar REMOTE_PORT and then either using +request.getAttribute("REMOTE_PORT") instead of getRemotePort() +or wrapping the request using a filter and overriding getRemotePort() with +request.getAttribute("REMOTE_PORT"). +
  • +
  • client host: getRemoteHost() +
  • +
  • authentication type: getAuthType() +
  • +
  • remote user: getRemoteUser(), +if tomcatAuthentication="false" +
  • +
  • protocol: getProtocol() +
  • +
  • HTTP method: getMethod() +
  • +
  • URI: getRequestURI() +
  • +
  • HTTPS used: isSecure(), getScheme() +
  • +
  • query string: getQueryString() +
  • +
+The following additional SSL-related data will be made available by Apache and forwarded by mod_jk only +if you set SSLOptions +StdEnvVars. For the certificate information you also need +to set SSLOptions +ExportCertData. +
    +
  • SSL cipher: getAttribute(javax.servlet.request.cipher_suite) +
  • +
  • SSL key size: getAttribute(javax.servlet.request.key_size). +Can be disabled using JkOptions -ForwardKeySize. +
  • +
  • SSL client certificate: getAttribute(javax.servlet.request.X509Certificate). +If you want the whole certificate chain, then you need to also set JkOptions ForwardSSLCertChain. +It is likely, that in this case you also need to adjust the maximal AJP packet size +using the worker attribute max_packet_size. +
  • +
  • SSL session ID: getAttribute(javax.servlet.request.ssl_session). +This is for Tomcat, it has not yet been standardized. +
  • +
+

+
Fine Tuning
+
+

In some situations this is not enough though. Assume there is another +less clever reverse proxy in front of your web server, for instance an +HTTP load balancer or similar device which also serves as an SSL accelerator. +

+

Then you are sure that all your clients use HTTPS, but your web server doesn't +know about that. All it can see is requests coming from the accelerator using +plain HTTP. +

+

Another example would be a simple reverse proxy in front of your web server, +so that the client IP address that your web server sees is always the IP address +of this reverse proxy, and not of the original client. Often such reverse proxies +generate an additional HTTP header, like X-Forwareded-for which +contains the original client IP address (or a list of IP addresses, if there are +more cascading reverse proxies in front). It would be nice, if we could use the +content of such a header as the client IP address to pass to the backend. +

+

So we might need to manipulate some of the data that AJP sends to the backend. +When using mod_jk inside Apache httpd you can use several httpd environment +variables to let mod_jk know, which data it should forward. These environment variables +can be set by the httpd directives SetEnv or SetEnvIf, but also in a very flexible +way using mod_rewrite (since httpd 2.x it can not only test against environment +variables, but also set them). +

+

The following list contains all environment variables mod_jk checks, before +sending data to the backend: +

    +
  • JK_LOCAL_NAME: the local name +
  • +
  • JK_LOCAL_PORT: the local port +
  • +
  • JK_REMOTE_HOST: the client host +
  • +
  • JK_REMOTE_ADDR: the client address +
  • +
  • JK_AUTH_TYPE: the authentication type +
  • +
  • JK_REMOTE_USER: the remote user +
  • +
  • HTTPS: On (case-insensitive) to indicate, that HTTPS is used +
  • +
  • SSL_CIPHER: the SSL cipher +
  • +
  • SSL_CIPHER_USEKEYSIZE: the SSL key size +
  • +
  • SSL_CLIENT_CERT: the SSL client certificate +
  • +
  • SSL_CLIENT_CERT_CHAIN_: prefix of variable names, containing +the client cerificate chain +
  • +
  • SSL_SESSION_ID: the SSL session ID +
  • +
+

+

Remember: in general you don't need to set them. The module retrieves the data automatically +from the web server. Only in case you want to change this data, you can overwrite it by +using these variables. +

+

Some of these variables might also be used by other web server modules. All +variables whose name does not begin with "JK" are set directly by Apache httpd. +If you want to change the data, but do not want to negatively influence the behaviour +of other modules, you can change the names of all variables mod_jk uses to private ones. +For the details see the Apache reference page. +

+

All variables, that are not SSL-related have only been introduced in version 1.2.27. +

+

Finally there is a shortcut to forward the local IP of the web server as the remote IP. +This can be useful, e.g. when using the Tomcat remote address valve for allowing connections +only from registered Apache web servers. This feature is activated by setting +JkOptions ForwardLocalAddress. +

+
Tomcat AJP Connector Settings
+
+

As an alternative to using the environment variables described in the previous section +(which do only exist when using Apache httpd), you can also configure Tomcat to overwrite +some of the communications data forwarded by mod_jk. The AJP connector in Tomcat's server.xml +allows to set the following properties: +

    +
  • proxyName: server name as returned by getServerName() +
  • +
  • proxyPort: server port as returned by getServerPort() +
  • +
  • scheme: protocol scheme as returned by getScheme() +
  • +
  • secure: set to "true", if you wish isSecure() to return "true". +
  • +
+Remember: in general you don't need to set those. AJP automatically handles all cases +where the web server running mod_jk knows the right data. +

+
URL Handling
+
+
URL Rewriting
+

Sometimes one want to change path components of the URLs under which an application +is available. Especially if a web application is deployed as some context, say /myapp, +marketing prefers short URLs, so want the application to be directly available under +http://www.mycompany.com/. Although you can deploy the application as the so-called +ROOT context, which will be directly available at "/", admins often prefer not to use +the ROOT context, e.g. because only one application can be the root context (per host). +

+

The procedure to change the URLs in the reverse proxy is tedious, because often +an application produces self-referential URLs, which then include the path components +which you tried to hide to the outside world. Nevertheless, if you absolutely need to do it, +here are the steps. +

+

Case A: You need to make the application available at a simple URL, but it is OK, if +users proceed using the more complex URLs, as long as they don't have to type them in. +That's the easy case, and if this suffices to you, you're lucky. Use a simply RedirectMatch +for Apache httpd: +

+
+RedirectMatch ^/$ http://www.mycompany.com/myapp/
+
+

Your application will then be available under http://www.mycompany.com/, +and each visitor will be immediately redirected to the real URL +http://www.mycompany.com/myapp/ +

+

Case B: You need to hide path components for all requests going to the application. +Here's the recipe for the case, where you want to hide the first path component +/myapp. More complex manipulations are left as an exercise to the reader. +First the solution for the case of Apache httpd: +

+

1. Use mod_rewrite +to add /myapp to all requests before forwarding to the backend: +

+
+# Don't forget the PT flag! (pass through)
+RewriteRule ^/(.*) http://www.mycompany.com/myapp/$1 [PT]
+
+

2. Use mod_headers +to rewrite any HTTP redirects your application might return. Such redirects typically contain +the path components you want to hide, because by the HTTP standard, redirects always need to include +the full URL, and your application is not aware of the fact, that your clients talk to it via +some shortened URL. An HTTP redirect is done with a special response header named Location. +We rewrite the Location headers of our responses: +

+
+# Keep protocol, server and port if present,
+# but insert our webapp name before the rest of the URL
+Header edit Location ^([^/]*//[^/]*)?/(.*)$ $1/myapp/$2 
+
+

3. Use mod_headers again, to rewrite the paths contained in any cookies, +your application might set. Such cookie paths again might contain +the path components you want to hide. +A cookie is set with the HTTP response header named Set-Cookie. +We rewrite the Set-Cookie headers of our responses: +

+
+# Fix the cookie path
+Header edit Set-Cookie "^(.*; Path=/)(.*)" $1/myapp/$2 
+
+

3. Some applications might contain hard coded absolute links. +In this case check, whether you find a configuration item for your web framework +to configure the base URL. If not, your only chance is to parse all response +content bodies and do search and replace. This is fragile and very resource intensive. +If you really need to do this, you can use +mod_proxy_html, +mod_substitute +or mod_sed +for this task. +

+

If you are using Microsoft IIS as a web server, the ISAPI plugin provides a way +of doing the first step with a builtin feature. You define a mapping file for simple prefix +changes like this: +

+
+# Add a context prefix to all requests ...
+/=/myapp/
+# ... or change some prefix ...
+/oldapp/=/myapp/
+
+

and then put the name of the file in the rewrite_rule_file entry of the registry or your +isapi_redirect.properties file. In you uriworkermap.properties file, you +still need to map the URLs as they are before rewriting! +

+

More complex rewrites can be done using the same file, but with regular expressions. A leading +tilde sign '~', indicates, that you are using a regular expression: +

+
+# Use a regular expression rewrite
+~/oldapps([0-9]*)/=/newapps$1/
+
+

There is no support for Steps 2 (rewriting redirect responses) or 3 (rewriting cookie paths). +

+
+
URL Encoding
+

Some types of problems are triggered by the use of encoded URLs +(see percent encoding). +For the same location there exist +a lot of different URLs which are equivalent. The reverse proxy needs to inspect the URL in order +to apply its own authentication rules and to decide, to which backend it should send the request +(or whether it should handle it itself). Therefore the request URL first is normalized: +percent encoded characters are decoded, /./ is replaced by /, +/XXX/../ is replaced by / and similar manipulations of the URL are done. +After that, the web server might apply rewrite rules to further change the URL in less obvious ways. +Finally there is no more way to put the resulting URL in an encoding, which is "similar" to +the one which was used for the original URL. +

+

+For historical reasons, there have been several alternatives, how mod_jk and the ISAPI +plugin encoded the resulting URL before sending it to the backend. They could be chosen via +JkOptions (Apache httpd) or uri_select (ISAPI). None of those historical +encodings are recommended, because they have either negative functionality implications or +pose a security risk. The default encoding since version 1.2.24 is ForwardURIProxy +(Apache httpd) or proxy (ISAPI) and it is strongly recommended to keep the default +and remove all old explicit settings. +

+
+
Request Attributes
+
+

+You can also add more attributes to any request you are forwarding when using Apache httpd. +For this use the JkEnvVar directive (for details see the +Apache reference page). Such request attributes can be +retrieved on the Tomcat side via request.getAttribute(attributeName). +Note that their names will not be listed in request.getAttributeNames()! +

+

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/printer/quick.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/printer/quick.html new file mode 100644 index 00000000..c9d95c9b --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/printer/quick.html @@ -0,0 +1,130 @@ +The Apache Tomcat Connector - Generic HowTo - Quick Start HowTo
Apache TomcatApache Logo

The Apache Tomcat Connector - Generic HowTo

Quick Start HowTo

Introduction
+

+ This document describes the configuration files used by JK on the + Web Server side for the 'impatient': +

    +
  • + workers.properties is a mandatory file used by the webserver and which + is the same for all JK implementations (Apache/IIS/NES). +
  • +
  • + web server add-ons to be set on the webserver side. +
  • +
+

+

+ We'll give here minimum servers configuration and an example workers.properties + to be able to install and check quickly your configuration. +

+
Minimum workers.properties
+

+ Here is a minimum workers.properties, using just ajp13 to connect your Apache webserver + to the Tomcat engine, complete documentation is available in Workers HowTo. +

+

+

+
+  # Define 1 real worker using ajp13
+  worker.list=worker1
+  # Set properties for worker1 (ajp13)
+  worker.worker1.type=ajp13
+  worker.worker1.host=localhost
+  worker.worker1.port=8009
+
+
+

+
Minimum Apache web server configuration
+

+ Here is a minimum information about Apache configuration, a + more complete separate HowTo for Apache is available. +

+

+ You should first have mod_jk.so (unix) or mod_jk.dll (Windows) installed + in your Apache module directory (see your Apache documentation to locate it). +

+

+ Usual locations for modules directory on Unix: +

    +
  • /usr/lib/apache/
  • +
  • /usr/lib/apache2/
  • +
  • /usr/local/apache/libexec/
  • +
+

+

+ Usual locations for modules directory on Windows : +

    +
  • C:\Program Files\Apache Group\Apache\modules\
  • +
  • C:\Program Files\Apache Group\Apache2\modules\
  • +
+

+

+ You'll find a link to prebuilt binaries + here +

+

+ Here is the minimum which should be set in httpd.conf directly or + included from another file: +

+

+ Usual locations for configuration directory on Unix: +

    +
  • /etc/httpd/conf/
  • +
  • /etc/httpd2/conf/
  • +
  • /usr/local/apache/conf/
  • +
+

+

+ Usual locations for configuration directory on Windows : +

    +
  • C:\Program Files\Apache Group\Apache\conf\
  • +
  • C:\Program Files\Apache Group\Apache2\conf\
  • +
+

+

+

+
+  # Load mod_jk module
+  # Update this path to match your modules location
+  LoadModule    jk_module  libexec/mod_jk.so
+  # Declare the module for <IfModule directive> (remove this line on Apache 2.x)
+  AddModule     mod_jk.c
+  # Where to find workers.properties
+  # Update this path to match your conf directory location (put workers.properties next to httpd.conf)
+  JkWorkersFile /etc/httpd/conf/workers.properties
+  # Where to put jk shared memory
+  # Update this path to match your local state directory or logs directory
+  JkShmFile     /var/log/httpd/mod_jk.shm
+  # Where to put jk logs
+  # Update this path to match your logs directory location (put mod_jk.log next to access_log)
+  JkLogFile     /var/log/httpd/mod_jk.log
+  # Set the jk log level [debug/error/info]
+  JkLogLevel    info
+  # Select the timestamp log format
+  JkLogStampFormat "[%a %b %d %H:%M:%S %Y] "
+  # Send everything for context /examples to worker named worker1 (ajp13)
+  JkMount  /examples/* worker1
+
+
+

+
Minimum IIS web server configuration
+

+ A separate HowTo for the IIS web server is available. +

+

+ This paragraph has not been written yet, but you can contribute to it. +

+
Minimum NES/iPlanet/Sun web server configuration
+

+ A separate HowTo for the Netscape/iPlanet/Sun web server is available. +

+ This paragraph has not been written yet, but you can contribute to it. +

+

+
Test your configuration
+

+ (Re)start the web server and browse to the http://localhost/examples/ +

+ +

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/printer/timeouts.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/printer/timeouts.html new file mode 100644 index 00000000..17ab68fe --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/printer/timeouts.html @@ -0,0 +1,373 @@ +The Apache Tomcat Connector - Generic HowTo - Timeouts HowTo
Apache TomcatApache Logo

The Apache Tomcat Connector - Generic HowTo

Timeouts HowTo

Introduction
+
+

Setting communication timeouts is very important to improve the +communication process. They help to detect problems and stabilise +a distributed system. JK can use several different timeout types, which +can be individually configured. For historical reasons, all of them are +disabled by default. This HowTo explains their use and gives +hints how to find appropriate values. +

+

All timeouts can be configured in the workers.properties file. +For a complete reference of all worker configuration +items, please consult the worker reference. +This page assumes, that you are using at least version 1.2.16 of JK. +Dependencies on newer versions will be mentioned where necessary. +

+

+Do not set timeouts to extreme values. Very small timeouts will likely +be counterproductive. +

+

+Long Garbage Collection pauses on the backend do not make a good +fit with some timeouts. Try to optimise your Java memory and GC settings. +

+
JK Timeout Attributes
+
+
CPing/CPong
+

+CPing/CPong is our notion for using small test packets to check the +status of backend connections. JK can use such test packets directly after establishing +a new backend connection (connect mode) and also directly before each request gets +send to a backend (prepost mode). +Starting with version 1.2.27 it can also be used when a connection was idle +for a long time (interval mode). +The maximum waiting time (timeout) for a CPong answer to a CPing and the idle +time in interval mode can be configured. +

+

+The test packets will be answered by the backend very fast with a minimal amount of +needed processing resources. A positive answer tells us, that the backend can be reached +and is actively processing requests. It does not detect, if some context is deployed +and working. The benefit of CPing/CPong is a fast detection of a communication +problem with the backend. The downside is a slightly increased latency. +

+

+The worker attribute ping_mode can be set to a combination of characters +to determine, in which situations test packets are used: +

    +
  • C: connect mode, timeout ping_timeout overwritten by connect_timeout
  • +
  • P: prepost mode, timeout ping_timeout overwritten by prepost_timeout
  • +
  • I: interval mode, timeout ping_timeout, idle time connection_ping_interval
  • +
  • A: all modes
  • +
+

+

+Multiple values must be concatenated without any separator characters. +We recommend using all CPing tests. If your application is very latency sensitive, then +you should only use the combination of connect and interval mode. +

+

+Activating the CPing probing via ping_mode has been added in version 1.2.27. +For older versions only the connect and prepost modes exist and must be activated by +explicitely setting connect_timeout and prepost_timeout. +

+

+The worker attribute ping_timeout sets the default wait timeout +in milliseconds for CPong for all modes. By default the value is "10000" +milliseconds. The value only gets used, if you activate CPing/Cpong probes +via ping_mode. The default value should be fine, except if you experience +very long Java garbage collection pauses. +Depending on your network latency and stability, good custom values +often are between 5000 and 15000 milliseconds. +You can overwrite the timeout used for connect and prepost mode with +connect_timeout and prepost_timeout. +Remember: don't use extremely small values. +

+

+The worker attribute connect_timeout sets the wait timeout +in milliseconds for CPong during connection establishment. You can use it +if you want to overwrite the general timeout set with ping_timeout. +To use connect mode CPing, you need to enable it via ping_mode. +Since JK usually uses persistent connections, opening new connections is a +rare event. We therefore recommend activating connect mode. +Depending on your network latency and stability, good values often +are between 5000 and 15000 milliseconds. +Remember: don't use extremely small values. +

+

+The worker attribute prepost_timeout sets the wait timeout +in milliseconds for CPong before request forwarding. You can use it +if you want to overwrite the general timeout set with ping_timeout. +To use prepost mode CPing, you need to enable it via ping_mode. +Activating this type of CPing/CPong adds a small latency to each +request. Usually this is small enough and the benefit of CPing/CPong is more important. +So in general we also recommend using prepost_timeout. +Depending on your network latency and stability, good values often +are between 5000 and 10000 milliseconds. +Remember: don't use extremely small values. +

+

+Until version 1.2.27 ping_mode and ping_timeout did not +exist and to enable connect or prepost mode CPing you had to set connect_timeout +respectively prepost_timeout to some reasonable positive value. +

+
+ +
Low-Level TCP Timeouts
+

+Some platforms allow to set timeouts for all operations on TCP sockets. +This is available for Linux and Windows, other platforms do not support this, +e.g. Solaris. If your platform supports TCP send and receive timeouts, +you can set them using the worker attribute socket_timeout. +You can not set the two timeouts to different values. +

+

+JK will accept this attribute even if your platform does not support +socket timeouts. In this case setting the attribute will have no effect. +By default the value is "0" and the timeout is disabled. +You can set the attribute to some seconds value (not: milliseconds). +JK will then set the send and the receive timeouts of the backend +connections to this value. The timeout is low-level, it is +used for each read and write operation on the socket individually. +

+

+Using this attribute will make JK react faster to some types of network problems. +Unfortunately socket timeouts have negative side effects, because for most +platforms, there is no good way to recover from such a timeout, once it fired. +For JK there is no way to decide, if this timeout fired because of real network +problems, or only because it didn't receive an answer packet from a backend in time. +So remember: don't use extremely small values. +

+

+For the general case of connection establishment you can use +socket_connect_timeout. It takes a millisecond value and works +on most platforms, even if socket_timeout is not supported. +We recommend using socket_connect_timeout because in some network +failure situations failure detection during connection establishment +can take several minutes due to TCP retransmits. Depending on the quality +of your network a timeout somewhere between 1000 and 5000 milliseconds +should be fine. Note that socket_timeout is in seconds, and +socket_connect_timeout in milliseconds. +

+
+ +
Connection Pools and Idle Timeouts
+

+JK handles backend connections in a connection pool per web server process. +The connections are used in a persistent mode. After a request completed +successfully we keep the connection open and wait for the next +request to forward. The connection pool is able to grow according +to the number of threads that want to forward requests in parallel. +

+

+Most applications have a varying load depending on the hour of the day +or the day of the month. Other reasons for a growing connection pool +would be temporary slowness of backends, leading to an increasing +congestion of the frontends like web servers. Many backends use a dedicated +thread for each incoming connection they handle. So usually one wants the +connection pool to shrink, if the load diminishes. +

+

+JK allows connections in the pool to get closed after some idle time. +This maximum idle time can be configured with the attribute +connection_pool_timeout which is given in units of seconds. +The default value is "0", which disables closing idle connections. +

+

+We generally recommend values around 10 minutes, so setting +connection_pool_timeout to 600 (seconds). If you use this attribute, +please also set the attribute connectionTimeout in the AJP +Connector element of your Tomcat server.xml configuration file to +an analogous value. Caution: connectionTimeout is in milliseconds. +So if you set JK connection_pool_timeout to 600, you should set Tomcat +connectionTimeout to 600000. +

+

+JK connections do not get closed immediately after the timeout passed. +Instead there is an automatic internal maintenance task +running every 60 seconds, that checks the idle status of all connections. +The 60 seconds interval +can be adjusted with the global attribute worker.maintain. We do not +recommend to change this value, because it has a lot of side effects. +Until version 1.2.26, the maintenance task only runs, if requests get +processed. So if your web server has processes that do not receive any +requests for a long time, there is no way to close the idle connections +in its pool. Starting with version 1.2.27 you can configure an independent +watchdog thread when using Apache 2.x with threaded APR or IIS. +

+

+The maximum connection pool size can be configured with the +attribute connection_pool_size. We generally do not recommend +to use this attribute in combination with Apache httpd. For +Apache httpd we automatically detect the number of threads per +process and set the maximum pool size to this value. For IIS we use +a default value of 250 (before version 1.2.20: 10), +for the Sun Web Server the default is "1". +We strongly recommend adjusting this value for IIS and the Sun Web Server +to the number of requests one web server process should +be able to send to a backend in parallel. You should measure how many connections +you need during peak hours without performance problems, and then add some +percentage depending on your growth rate etc. Finally you should check, +whether your web server processes are able to use at least as many threads, +as you configured as the pool size. +

+

+The JK attribute connection_pool_minsize defines, +how many idle connections remain when the pool gets shrunken. +By default this is half of the maximum pool size. +

+
+ +
Firewall Connection Dropping
+

+One particular problem with idle connections comes from firewalls, that +are often deployed between the web server layer and the backend. +Depending on their configuration, they will silently drop +connections from their status table if they are idle for to long. +

+

+From the point of view of JK and of the web server, the other side +simply doesn't answer any traffic. Since TCP is a reliable protocol +it detects the missing TCP ACKs and tries to resend the packets for +a relatively long time, typically several minutes. +

+

+Many firewalls will allow connection closing, even if they dropped +the connection for normal traffic. Therefore you should always use +connection_pool_timeout and +connection_pool_minsize on the JK side +and connectionTimeout on the Tomcat side. +

+

+Furthermore using the boolean attribute socket_keepalive you can +set a standard socket option, that automatically sends TCP keepalive packets +after some idle time on each connection. By default this is set to "False". +If you suspect idle connection drops by firewalls you should set this to +"True". +

+

+Unfortunately the default intervals and algorithms for these packets +are platform specific. You might need to inspect TCP tuning options for +your platform on how to control TCP keepalive. +Often the default intervals are much longer than the firewall timeouts +for idle connections. Nevertheless we recommend talking to your firewall +administration and your platform administration in order to make them agree +on good configuration values for the firewall and the platform TCP tuning. +

+

+In case none of our recommendations help and you are definitively having +problems with idle connection drops, you can disable the use of persistent +connections when using JK together with Apache httpd. For this you set +"JkOptions +DisableReuse" in your Apache httpd configuration. +This will have a huge negative performance impact! +

+
+ +
Reply Timeout
+

+JK can also use a timeout on request replies. This timeout does not +measure the full processing time of the response. Instead it controls, +how much time between consecutive response packets is allowed. +

+

+In most cases, this is what one actually wants. Consider for example +long running downloads. You would not be able to set an effective global +reply timeout, because downloads could last for many minutes. +Most applications though have limited processing time before starting +to return the response. For those applications you could set an explicit +reply timeout. Applications that do not harmonise with reply timeouts +are batch type applications, data warehouse and reporting applications +which are expected to observe long processing times. +

+

+If JK aborts waiting for a response, because a reply timeout fired, +there is no way to stop processing on the backend. Although you free +processing resources in your web server, the request +will continue to run on the backend - without any way to send back a +result once the reply timeout fired. +

+

+JK uses the worker attribute reply_timeout to set reply timeouts. +The default value is "0" (timeout disabled) and you can set it to any +millisecond value. +

+

+In combination with Apache httpd, you can also set a more flexible reply_timeout +using an httpd environment variable. If you set the variable JK_REPLY_TIMEOUT +to some integer value, this value will be used instead of the value in +the worker configuration. This way you can set reply timeouts more flexible +with mod_setenvif and mod_rewrite depending on URI, query string etc. +If the environment variable JK_REPLY_TIMEOUT is not set, or is set to a +negative value, the default reply timeout of the worker will be used. If +JK_REPLY_TIMEOUT contains the value "0", then the reply timeout will be disabled +for the request. +

+

+In combination with a load balancing worker, JK will disable a member +worker of the load balancer if a reply timeout fires. The worker will then +no longer be used until it gets recovered during the next automatic +maintenance task. Starting with JK 1.2.24 you can improve this behaviour using +max_reply_timeouts. This +attribute will allow occasional long running requests without disabling the +worker. Only if those requests happen to often, the worker gets disabled by the +load balancer. +

+
+
Load Balancer Error Detection
+
+
Local and Global Error States
+

+A load balancer worker does not only have the ability to balance load. +It also handles stickyness and failover of requests in case of errors. +When a load balancer detects an error on one of its members, it needs to +decide, whether the error is serious, or only a temporary error or maybe +only related to the actual request that was processed. Temporary errors +are called local errors, serious errors will be called global errors. +

+

+If the load balancer decides that a backend should be put into the global error +state, then the web server will not send any more requests there. If no session +replication is used, this means that all user sessions located on the respective +backend are no longer available. The users will be send to another backend +and will have to login again. So the global error state is not transparent to the +users. The application is still available, but users might loose some work. +

+

+In some cases the decision between local error and global error is easy. +For instance if there is an error sending back the response to the client (browser), +then it is very unlikely that the backend is broken. +So this situation is a typical example of a local error. +

+

+Some situations are harder to decide though. If the load balancer can't establish +a new connection to a backend, it could be because of a temporary overload situation +(so no more free threads in the backend), or because the backend isn't alive any more. +Depending on the details, the right state could either be local error or global error. +

+
+
Error Escalation Time
+

+Until version 1.2.26 most errors were interpreted as global errors. +Starting with version 1.2.27 many errors which were previously interpreted as global +were switched to being local whenever the backend is still busy. Busy means, that +other concurrent requests are send to the same backend (successful or not). +

+

+In many cases there is no perfect way of making the decision +between local and global error. The load balancer simply doesn't have enough information. +In version 1.2.28 you can now tune, how fast the load balancer switches from local error to +global error. If a member of a load balancer stays in local error state for too long, +the load balancer will escalate it into global error state. +

+

+The time tolerated in local error state is controlled by the load balancer attribute +error_escalation_time (in seconds). The default value is half of recover_time, +so unless you changed recover_time the default is 30 seconds. +

+

+Using a smaller value for error_escalation_time will make the load balancer react +faster to serious errors, but also carries the risk of more often loosing sessions +in not so serious situations. You can lower error_escalation_time down to 0 seconds, +which means all local errors which are potentially serious are escalated to global errors +immediately. +

+

+Note that without good basic error detection the whole escalation procedure is useless. +So you should definitely use socket_connect_timeout and activate CPing/CPong +with ping_mode and ping_timeout before thinking about also tuning +error_escalation_time. +

+
+

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/printer/workers.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/printer/workers.html new file mode 100644 index 00000000..3e8c3570 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/printer/workers.html @@ -0,0 +1,408 @@ +The Apache Tomcat Connector - Generic HowTo - Workers HowTo
Apache TomcatApache Logo

The Apache Tomcat Connector - Generic HowTo

Workers HowTo

Introduction
+

+A Tomcat worker is a Tomcat instance that is waiting to execute servlets on behalf of some web server. +For example, we can have a web server such as Apache forwarding servlet requests to a +Tomcat process (the worker) running behind it. +

+

+The scenario described above is a very simple one; +in fact one can configure multiple Tomcat workers to serve servlets on +behalf of a certain web server. +The reasons for such configuration can be: +

+
    +
  • +We want different contexts to be served by different Tomcat workers to provide a +development environment where all the developers share the same web server but own a Tomcat worker of their own. +
  • +
  • +We want different virtual hosts served by different Tomcat processes to provide a +clear separation between sites belonging to different companies. +
  • +
  • +We want to provide load balancing, meaning run multiple Tomcat workers each on a +machine of its own and distribute the requests between them. +
  • +
+ +

+There are probably more reasons for having multiple workers but I guess that this list is enough... +Tomcat workers are defined in a properties file dubbed workers.properties and this tutorial +explains how to work with it. +

+ +

+This document was originally part of Tomcat: A Minimalistic User's Guide written by Gal Shachor, +but has been split off for organisational reasons. +

+
Defining Workers
+

+Defining workers to the Tomcat web server plugin can be done using a properties file +(a sample file named workers.properties is available in the conf/ directory). +

+ +

+the file contains entries of the following form: +

+ +

+worker.list=<a comma separated list of worker names> +

+ +
+  # the list of workers
+  worker.list= worker1, worker2
+
+ +

+When starting up, the web server plugin will instantiate the workers whose name appears in the +worker.list property, these are also the workers to whom you can map requests. The directive can be used multiple times. +

+ +
Workers Type
+

+Each named worker should also have a few entries to provide additional information on his behalf. +This information includes the worker's type and other related worker information. +Currently the following worker types that exists are (JK 1.2.5): +

+ + + + + + + + +
TypeDescription
ajp12This worker knows how to forward requests to out-of-process Tomcat workers using the ajpv12 protocol.
ajp13This worker knows how to forward requests to out-of-process Tomcat workers using the ajpv13 protocol.
jniDEPRECATED: This worker knows how to forward requests to in-process Tomcat workers using JNI.
lbThis is a load-balancing worker; it knows how to provide round-robin based sticky load balancing with a certain level of fault-tolerance.
statusThis is a status worker for managing load balancers.
+ +

+Defining workers of a certain type should be done with the following property format: +

+ +

+worker.worker name.type=<worker type> +Where worker name is the name assigned to the worker and the worker type is one of the four types defined +in the table (a worker name may only contain any space the characters [a-zA-Z0-9\-_]). +

+ +
+  # Defines a worker named "local" that uses the ajpv12 protocol to forward requests to a Tomcat process.
+  worker.local.type=ajp12
+  # Defines a worker named "remote" that uses the ajpv13 protocol to forward requests to a Tomcat process.
+  worker.remote.type=ajp13
+  # Defines a worker named "loadbalancer" that loadbalances several Tomcat processes transparently.
+  worker.loadbalancer.type=lb
+
+ +
+ +
Setting Worker Properties
+

+After defining the workers you can also specify properties for them. +Properties can be specified in the following manner: +

+ +

+worker.<worker name>.<property>=<property value> +

+ +Each worker has a set of properties that you can set as specified in the following subsections: + +
ajp12 Worker properties
+

+The ajp12 has been deprecated with Tomcat 3.3.x and you should use instead +ajp13 which is the only ajp protocol known by Tomcat 4.x and 5 and 5.5 and Tomcat 6. +

+

+The ajp12 typed workers forward requests to out-of-process Tomcat workers +using the ajpv12 protocol over TCP/IP sockets. +

+ +

+the ajp12 worker properties are : +

+ +

+host property sets the host where the Tomcat worker is listening for ajp12 requests. +

+ +

+port property sets the port where the Tomcat worker is listening for ajp12 requests +

+ +

+lbfactor property is used when working with a load balancer worker, this is the load-balancing factor for the worker. +We'll see more on this in the lb worker section. +

+ +
+  # worker "worker1" will talk to Tomcat listening on machine www.x.com at port 8007 using 2 lb factor
+  worker.worker1.host=www.x.com
+  worker.worker1.port=8007
+  worker.worker1.lbfactor=2
+
+ +

+Notes: In the ajpv12 protocol, connections are created, used and then closed at each request. +The default port for ajp12 is 8007 +

+ +
+ +
ajp13 Worker properties
+

+The ajp13 typed workers forward requests to out-of-process Tomcat workers using the ajpv13 protocol over TCP/IP sockets. +The main difference between ajpv12 and ajpv13 are that: +

    +
  • +ajpv13 is a more binary protocol and it tries to compress some of the request data by coding +frequently used strings as small integers. +
  • +
  • +ajpv13 reuses open sockets and leaves them open for future requests (remember when you've got a Firewall between your +web server and Tomcat). +
  • +
  • +ajpv13 has special treatment for SSL information so that the container can implement +SSL related methods such as isSecure(). +
  • +
+ +

+ +

+You should note that Ajp13 is now the only out-process protocol supported by Tomcat 4.0.x, 4.1.x, 5.0.x, 5.5.x and 6. +

+ + +
+  # worker "worker2" will talk to Tomcat listening on machine www2.x.com at port 8009 using 3 lb factor
+  worker.worker2.host=www2.x.com
+  worker.worker2.port=8009
+  worker.worker2.lbfactor=3
+  # worker "worker2" uses connections, which will stay no more than 10mn in the connection pool
+  worker.worker2.connection_pool_timeout=600
+  # worker "worker2" ask operating system to send KEEP-ALIVE signal on the connection
+  worker.worker2.socket_keepalive=1
+  # mount can be used as an alternative to the JkMount directive
+  worker.worker2.mount=/contexta /contexta/* /contextb /contextb/*
+
+ +

+Notes: In the ajpv13 protocol, the default port is 8009 +

+ +
+ +
lb Worker properties
+

+The load-balancing worker does not really communicate with Tomcat workers. +Instead it is responsible for the management of several "real" workers. +This management includes: +

+ +
    +
  • +Instantiating the workers in the web server. +
  • +
  • +Using the worker's load-balancing factor, perform weighed-round-robin load balancing where +high lbfactor means stronger machine (that is going to handle more requests) +
  • +
  • +Keeping requests belonging to the same session executing on the same Tomcat worker. +
  • +
  • +Identifying failed Tomcat workers, suspending requests to them and instead falling-back on +other workers managed by the lb worker. +
  • +
+ +

+The overall result is that workers managed by the same lb worker are load-balanced (based on their lbfactor and current user session) and also fall-backed so a single Tomcat process death will not "kill" the entire site. +The following table specifies some properties that the lb worker can accept: +

    +
  • balance_workers is a comma separated list of workers that the load balancer need to manage. +As long as these workers should only be used via the load balancer worker, +there is no need to also put them into the worker.list property. +This directive can be used multiple times for the same load balancer.
  • +
  • sticky_session specifies whether requests with SESSION ID's should be routed back to the same +Tomcat worker. Set sticky_session to False when Tomcat is using a Session Manager which +can persist session data across multiple instances of Tomcat. By default sticky_session is set to True.
  • +
+

+ +
+  # The worker balance1 while use "real" workers worker1 and worker2
+  worker.balance1.balance_workers=worker1, worker2
+
+ +
+ +
Status Worker properties
+

+The status worker does not communicate with Tomcat. +Instead it is responsible for the load balancer management. +

+
+  # Add the status worker to the worker list
+  worker.list=jkstatus
+  # Define a 'jkstatus' worker using status
+  worker.jkstatus.type=status
+
+

Next thing is to mount the requests to the jkstatus worker. For Apache +web servers use the:

+
+  # Add the jkstatus mount point
+  JkMount /jkmanager/* jkstatus 
+
+

To obtain a higher level of security use the:

+
+  # Enable the JK manager access from localhost only
+ <Location /jkmanager/>
+    JkMount jkstatus
+    Order deny,allow
+    Deny from all
+    Allow from 127.0.0.1
+ </Location>
+
+ +
+ +
Property file macros
+

+You can define "macros" in the property files. +These macros let you define properties and later on use them while +constructing other properties. +

+ +
+  # property example, like a network base address
+  mynet=194.226.31
+  # Using the above macro to simplify the address definitions
+  # for a farm of workers.
+  worker.node1.host=$(mynet).11
+  worker.node2.host=$(mynet).12
+  worker.node3.host=$(mynet).13
+
+ +
+ +
Hierarchical property configuration
+

+Workers can reference configurations of other workers. +If worker "x" references worker "y", then it inherits all +configuration parameters from "y", except for the ones +that have explicitly been set for "x". +

+ +
+  # worker toe defines some default settings
+  worker.toe.type=ajp13
+  worker.toe.socket_keepalive=true
+  worker.toe.connect_timeout=10000
+  worker.toe.recovery_options=7
+  # workers tic and tac inherit those values
+  worker.tic.reference=worker.toe
+  worker.tac.reference=worker.toe
+
+ +

+Please note, that the reference contains +the full prefix to the referenced configuration attributes, +not only the name of the referenced worker. +

+ +

+References can be nested. Be careful to avoid loops! +

+ +

+Attributes which are allowed multiple times for a single worker +can not be merged from a worker and a reference. An attribute +is only inherited from a reference, if it is not already set +for the referring worker. +

+ +

+References are especially useful, when configuring load balancers. +Try to understand the following two stage references: +

+ +
+  # We only use one load balancer
+  worker.list=lb
+  # Let's define some defaults
+  worker.basic.port=8009
+  worker.basic.type=ajp13
+  worker.basic.socket_keepalive=true
+  worker.basic.connect_timeout=10000
+  worker.basic.recovery_options=7
+  # And we use them in two groups
+  worker.lb1.domain=dom1
+  worker.lb1.distance=0
+  worker.lb1.reference=worker.basic
+  worker.lb2.domain=dom2
+  worker.lb2.distance=1
+  worker.lb2.reference=worker.basic
+  # Now we configure the load balancer
+  worker.lb.type=lb
+  worker.lb.method=B
+  worker.lb.balanced_workers=w11,w12,w21,w22
+  worker.w11.host=myhost11
+  worker.w11.reference=worker.lb1
+  worker.w12.host=myhost12
+  worker.w12.reference=worker.lb1
+  worker.w21.host=myhost21
+  worker.w21.reference=worker.lb2
+  worker.w22.host=myhost22
+  worker.w22.reference=worker.lb2
+
+ +
+ +
A sample worker.properties
+

+Since coping with worker.properties on your own is not an easy thing to do, +a sample worker.properties file is bundled along JK. +

+ +

+You could also find here a sample workers.properties defining : +

+ +
    +
  • +An ajp12 worker that used the host localhost and the port 8007 +
  • +
  • +An ajp13 worker that used the host localhost and the port 8008 +
  • +
  • +An lb worker that load balance the ajp12 and ajp13 workers +
  • +
+ +
+  # Define 3 workers, 2 real workers using ajp12, ajp13, the last one being a loadbalancing worker 
+  worker.list=worker1, worker2, worker3
+  # Set properties for worker1 (ajp12)
+  worker.worker1.type=ajp12
+  worker.worker1.host=localhost
+  worker.worker1.port=8007
+  worker.worker1.lbfactor=1
+  # Set properties for worker2 (ajp13)
+  worker.worker2.type=ajp13
+  worker.worker2.host=localhost
+  worker.worker2.port=8009
+  worker.worker2.lbfactor=1
+  worker.worker2.connection_pool_timeout=600
+  worker.worker2.socket_keepalive=1
+  worker.worker2.socket_timeout=60
+  # Set properties for worker3 (lb) which use worker1 and worker2
+  worker.worker3.balance_workers=worker1,worker2
+
+ +

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/proxy.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/proxy.html new file mode 100644 index 00000000..01c82500 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/proxy.html @@ -0,0 +1,313 @@ +The Apache Tomcat Connector - Generic HowTo - Reverse Proxy HowTo
Apache TomcatApache Logo

Links

Reference Guide

Generic HowTo

Webserver HowTo

AJP Protocol Reference

Miscellaneous Documentation

News

The Apache Tomcat Connector - Generic HowTo

Reverse Proxy HowTo

Printer Friendly Version
print-friendly
version +
Introduction
+
+

The Apache module mod_jk and its ISAPI and NSAPI variants connect +a web server to a backend (typically Tomcat) using the AJP protocol. +The web server receives an HTTP(S) request and the module forwards +the request to the backend. This function is usually called a gateway +or a proxy, in the context of HTTP it is called a reverse proxy. +

+
Typical Problems
+
+

A reverse proxy is not totally transparent to the application on +the backend. For instance the host name and port the original client +(e.g. browser) needs to talk to belong to the web server and not to the +backend, so the reverse proxy talks to a different host name and port. +When the application on the backend returns content including +self-referential URLs using its own backend address and port, the +client will usually not be able to use these URLs. +

+

Another example is the client IP address, which for the web server is the +source IP of the incoming connection, whereas for the backend the +connection always comes from the web server. This can be a problem, when +the client IP is used by the backend application e.g. for security reasons. +

+
AJP as a Solution
+
+

Most of these problems are automatically handled by the AJP protocol +and the AJP connectors of the backend. The AJP protocol transports +this communication metadata and the backend connector presents this +metadata whenever the application asks for it using Servlet API methods. +

+

The following list contains the communication metadata handled by AJP +and the ServletRequest/HttpServletRequest API calls which can be used to retrieve them: +

    +
  • local name: getLocalName() and getLocalAddr. +This is also equal to getServerName(), unless a Host header +is contained in the request. In this case the server name is taken from that header. +
  • +
  • local port: getLocalPort() +This is also equal to getServerPort(), unless a Host header +is contained in the request. In this case the server port is taken from that header +if it contains an explicit port, or is equal to the default port of the scheme used. +
  • +
  • client address: getRemoteAddr() +
  • +
  • client port: getRemotePort() +The remote port was initially not supported. It is available when using mod_jk 1.2.32 +with Apache or IIS (not for the NSAPI plugin) together with Tomcat version at least +5.5.28, 6.0.20 or 7.0.0. For older versions, getRemotePort() +will incorrectly return 0 or -1. As a workaround you can forward the remote port by setting +JkEnvVar REMOTE_PORT and then either using +request.getAttribute("REMOTE_PORT") instead of getRemotePort() +or wrapping the request using a filter and overriding getRemotePort() with +request.getAttribute("REMOTE_PORT"). +
  • +
  • client host: getRemoteHost() +
  • +
  • authentication type: getAuthType() +
  • +
  • remote user: getRemoteUser(), +if tomcatAuthentication="false" +
  • +
  • protocol: getProtocol() +
  • +
  • HTTP method: getMethod() +
  • +
  • URI: getRequestURI() +
  • +
  • HTTPS used: isSecure(), getScheme() +
  • +
  • query string: getQueryString() +
  • +
+The following additional SSL-related data will be made available by Apache and forwarded by mod_jk only +if you set SSLOptions +StdEnvVars. For the certificate information you also need +to set SSLOptions +ExportCertData. +
    +
  • SSL cipher: getAttribute(javax.servlet.request.cipher_suite) +
  • +
  • SSL key size: getAttribute(javax.servlet.request.key_size). +Can be disabled using JkOptions -ForwardKeySize. +
  • +
  • SSL client certificate: getAttribute(javax.servlet.request.X509Certificate). +If you want the whole certificate chain, then you need to also set JkOptions ForwardSSLCertChain. +It is likely, that in this case you also need to adjust the maximal AJP packet size +using the worker attribute max_packet_size. +
  • +
  • SSL session ID: getAttribute(javax.servlet.request.ssl_session). +This is for Tomcat, it has not yet been standardized. +
  • +
+

+
Fine Tuning
+
+

In some situations this is not enough though. Assume there is another +less clever reverse proxy in front of your web server, for instance an +HTTP load balancer or similar device which also serves as an SSL accelerator. +

+

Then you are sure that all your clients use HTTPS, but your web server doesn't +know about that. All it can see is requests coming from the accelerator using +plain HTTP. +

+

Another example would be a simple reverse proxy in front of your web server, +so that the client IP address that your web server sees is always the IP address +of this reverse proxy, and not of the original client. Often such reverse proxies +generate an additional HTTP header, like X-Forwareded-for which +contains the original client IP address (or a list of IP addresses, if there are +more cascading reverse proxies in front). It would be nice, if we could use the +content of such a header as the client IP address to pass to the backend. +

+

So we might need to manipulate some of the data that AJP sends to the backend. +When using mod_jk inside Apache httpd you can use several httpd environment +variables to let mod_jk know, which data it should forward. These environment variables +can be set by the httpd directives SetEnv or SetEnvIf, but also in a very flexible +way using mod_rewrite (since httpd 2.x it can not only test against environment +variables, but also set them). +

+

The following list contains all environment variables mod_jk checks, before +sending data to the backend: +

    +
  • JK_LOCAL_NAME: the local name +
  • +
  • JK_LOCAL_PORT: the local port +
  • +
  • JK_REMOTE_HOST: the client host +
  • +
  • JK_REMOTE_ADDR: the client address +
  • +
  • JK_AUTH_TYPE: the authentication type +
  • +
  • JK_REMOTE_USER: the remote user +
  • +
  • HTTPS: On (case-insensitive) to indicate, that HTTPS is used +
  • +
  • SSL_CIPHER: the SSL cipher +
  • +
  • SSL_CIPHER_USEKEYSIZE: the SSL key size +
  • +
  • SSL_CLIENT_CERT: the SSL client certificate +
  • +
  • SSL_CLIENT_CERT_CHAIN_: prefix of variable names, containing +the client cerificate chain +
  • +
  • SSL_SESSION_ID: the SSL session ID +
  • +
+

+

Remember: in general you don't need to set them. The module retrieves the data automatically +from the web server. Only in case you want to change this data, you can overwrite it by +using these variables. +

+

Some of these variables might also be used by other web server modules. All +variables whose name does not begin with "JK" are set directly by Apache httpd. +If you want to change the data, but do not want to negatively influence the behaviour +of other modules, you can change the names of all variables mod_jk uses to private ones. +For the details see the Apache reference page. +

+

All variables, that are not SSL-related have only been introduced in version 1.2.27. +

+

Finally there is a shortcut to forward the local IP of the web server as the remote IP. +This can be useful, e.g. when using the Tomcat remote address valve for allowing connections +only from registered Apache web servers. This feature is activated by setting +JkOptions ForwardLocalAddress. +

+
Tomcat AJP Connector Settings
+
+

As an alternative to using the environment variables described in the previous section +(which do only exist when using Apache httpd), you can also configure Tomcat to overwrite +some of the communications data forwarded by mod_jk. The AJP connector in Tomcat's server.xml +allows to set the following properties: +

    +
  • proxyName: server name as returned by getServerName() +
  • +
  • proxyPort: server port as returned by getServerPort() +
  • +
  • scheme: protocol scheme as returned by getScheme() +
  • +
  • secure: set to "true", if you wish isSecure() to return "true". +
  • +
+Remember: in general you don't need to set those. AJP automatically handles all cases +where the web server running mod_jk knows the right data. +

+
URL Handling
+
+
URL Rewriting
+

Sometimes one want to change path components of the URLs under which an application +is available. Especially if a web application is deployed as some context, say /myapp, +marketing prefers short URLs, so want the application to be directly available under +http://www.mycompany.com/. Although you can deploy the application as the so-called +ROOT context, which will be directly available at "/", admins often prefer not to use +the ROOT context, e.g. because only one application can be the root context (per host). +

+

The procedure to change the URLs in the reverse proxy is tedious, because often +an application produces self-referential URLs, which then include the path components +which you tried to hide to the outside world. Nevertheless, if you absolutely need to do it, +here are the steps. +

+

Case A: You need to make the application available at a simple URL, but it is OK, if +users proceed using the more complex URLs, as long as they don't have to type them in. +That's the easy case, and if this suffices to you, you're lucky. Use a simply RedirectMatch +for Apache httpd: +

+
+RedirectMatch ^/$ http://www.mycompany.com/myapp/
+
+

Your application will then be available under http://www.mycompany.com/, +and each visitor will be immediately redirected to the real URL +http://www.mycompany.com/myapp/ +

+

Case B: You need to hide path components for all requests going to the application. +Here's the recipe for the case, where you want to hide the first path component +/myapp. More complex manipulations are left as an exercise to the reader. +First the solution for the case of Apache httpd: +

+

1. Use mod_rewrite +to add /myapp to all requests before forwarding to the backend: +

+
+# Don't forget the PT flag! (pass through)
+RewriteRule ^/(.*) http://www.mycompany.com/myapp/$1 [PT]
+
+

2. Use mod_headers +to rewrite any HTTP redirects your application might return. Such redirects typically contain +the path components you want to hide, because by the HTTP standard, redirects always need to include +the full URL, and your application is not aware of the fact, that your clients talk to it via +some shortened URL. An HTTP redirect is done with a special response header named Location. +We rewrite the Location headers of our responses: +

+
+# Keep protocol, server and port if present,
+# but insert our webapp name before the rest of the URL
+Header edit Location ^([^/]*//[^/]*)?/(.*)$ $1/myapp/$2 
+
+

3. Use mod_headers again, to rewrite the paths contained in any cookies, +your application might set. Such cookie paths again might contain +the path components you want to hide. +A cookie is set with the HTTP response header named Set-Cookie. +We rewrite the Set-Cookie headers of our responses: +

+
+# Fix the cookie path
+Header edit Set-Cookie "^(.*; Path=/)(.*)" $1/myapp/$2 
+
+

3. Some applications might contain hard coded absolute links. +In this case check, whether you find a configuration item for your web framework +to configure the base URL. If not, your only chance is to parse all response +content bodies and do search and replace. This is fragile and very resource intensive. +If you really need to do this, you can use +mod_proxy_html, +mod_substitute +or mod_sed +for this task. +

+

If you are using Microsoft IIS as a web server, the ISAPI plugin provides a way +of doing the first step with a builtin feature. You define a mapping file for simple prefix +changes like this: +

+
+# Add a context prefix to all requests ...
+/=/myapp/
+# ... or change some prefix ...
+/oldapp/=/myapp/
+
+

and then put the name of the file in the rewrite_rule_file entry of the registry or your +isapi_redirect.properties file. In you uriworkermap.properties file, you +still need to map the URLs as they are before rewriting! +

+

More complex rewrites can be done using the same file, but with regular expressions. A leading +tilde sign '~', indicates, that you are using a regular expression: +

+
+# Use a regular expression rewrite
+~/oldapps([0-9]*)/=/newapps$1/
+
+

There is no support for Steps 2 (rewriting redirect responses) or 3 (rewriting cookie paths). +

+
+
URL Encoding
+

Some types of problems are triggered by the use of encoded URLs +(see percent encoding). +For the same location there exist +a lot of different URLs which are equivalent. The reverse proxy needs to inspect the URL in order +to apply its own authentication rules and to decide, to which backend it should send the request +(or whether it should handle it itself). Therefore the request URL first is normalized: +percent encoded characters are decoded, /./ is replaced by /, +/XXX/../ is replaced by / and similar manipulations of the URL are done. +After that, the web server might apply rewrite rules to further change the URL in less obvious ways. +Finally there is no more way to put the resulting URL in an encoding, which is "similar" to +the one which was used for the original URL. +

+

+For historical reasons, there have been several alternatives, how mod_jk and the ISAPI +plugin encoded the resulting URL before sending it to the backend. They could be chosen via +JkOptions (Apache httpd) or uri_select (ISAPI). None of those historical +encodings are recommended, because they have either negative functionality implications or +pose a security risk. The default encoding since version 1.2.24 is ForwardURIProxy +(Apache httpd) or proxy (ISAPI) and it is strongly recommended to keep the default +and remove all old explicit settings. +

+
+
Request Attributes
+
+

+You can also add more attributes to any request you are forwarding when using Apache httpd. +For this use the JkEnvVar directive (for details see the +Apache reference page). Such request attributes can be +retrieved on the Tomcat side via request.getAttribute(attributeName). +Note that their names will not be listed in request.getAttributeNames()! +

+

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/quick.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/quick.html new file mode 100644 index 00000000..68cad946 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/quick.html @@ -0,0 +1,131 @@ +The Apache Tomcat Connector - Generic HowTo - Quick Start HowTo
Apache TomcatApache Logo

Links

Reference Guide

Generic HowTo

Webserver HowTo

AJP Protocol Reference

Miscellaneous Documentation

News

The Apache Tomcat Connector - Generic HowTo

Quick Start HowTo

Printer Friendly Version
print-friendly
version +
Introduction
+

+ This document describes the configuration files used by JK on the + Web Server side for the 'impatient': +

    +
  • + workers.properties is a mandatory file used by the webserver and which + is the same for all JK implementations (Apache/IIS/NES). +
  • +
  • + web server add-ons to be set on the webserver side. +
  • +
+

+

+ We'll give here minimum servers configuration and an example workers.properties + to be able to install and check quickly your configuration. +

+
Minimum workers.properties
+

+ Here is a minimum workers.properties, using just ajp13 to connect your Apache webserver + to the Tomcat engine, complete documentation is available in Workers HowTo. +

+

+

+
+  # Define 1 real worker using ajp13
+  worker.list=worker1
+  # Set properties for worker1 (ajp13)
+  worker.worker1.type=ajp13
+  worker.worker1.host=localhost
+  worker.worker1.port=8009
+
+
+

+
Minimum Apache web server configuration
+

+ Here is a minimum information about Apache configuration, a + more complete separate HowTo for Apache is available. +

+

+ You should first have mod_jk.so (unix) or mod_jk.dll (Windows) installed + in your Apache module directory (see your Apache documentation to locate it). +

+

+ Usual locations for modules directory on Unix: +

    +
  • /usr/lib/apache/
  • +
  • /usr/lib/apache2/
  • +
  • /usr/local/apache/libexec/
  • +
+

+

+ Usual locations for modules directory on Windows : +

    +
  • C:\Program Files\Apache Group\Apache\modules\
  • +
  • C:\Program Files\Apache Group\Apache2\modules\
  • +
+

+

+ You'll find a link to prebuilt binaries + here +

+

+ Here is the minimum which should be set in httpd.conf directly or + included from another file: +

+

+ Usual locations for configuration directory on Unix: +

    +
  • /etc/httpd/conf/
  • +
  • /etc/httpd2/conf/
  • +
  • /usr/local/apache/conf/
  • +
+

+

+ Usual locations for configuration directory on Windows : +

    +
  • C:\Program Files\Apache Group\Apache\conf\
  • +
  • C:\Program Files\Apache Group\Apache2\conf\
  • +
+

+

+

+
+  # Load mod_jk module
+  # Update this path to match your modules location
+  LoadModule    jk_module  libexec/mod_jk.so
+  # Declare the module for <IfModule directive> (remove this line on Apache 2.x)
+  AddModule     mod_jk.c
+  # Where to find workers.properties
+  # Update this path to match your conf directory location (put workers.properties next to httpd.conf)
+  JkWorkersFile /etc/httpd/conf/workers.properties
+  # Where to put jk shared memory
+  # Update this path to match your local state directory or logs directory
+  JkShmFile     /var/log/httpd/mod_jk.shm
+  # Where to put jk logs
+  # Update this path to match your logs directory location (put mod_jk.log next to access_log)
+  JkLogFile     /var/log/httpd/mod_jk.log
+  # Set the jk log level [debug/error/info]
+  JkLogLevel    info
+  # Select the timestamp log format
+  JkLogStampFormat "[%a %b %d %H:%M:%S %Y] "
+  # Send everything for context /examples to worker named worker1 (ajp13)
+  JkMount  /examples/* worker1
+
+
+

+
Minimum IIS web server configuration
+

+ A separate HowTo for the IIS web server is available. +

+

+ This paragraph has not been written yet, but you can contribute to it. +

+
Minimum NES/iPlanet/Sun web server configuration
+

+ A separate HowTo for the Netscape/iPlanet/Sun web server is available. +

+ This paragraph has not been written yet, but you can contribute to it. +

+

+
Test your configuration
+

+ (Re)start the web server and browse to the http://localhost/examples/ +

+ +

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/timeouts.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/timeouts.html new file mode 100644 index 00000000..67fcf90b --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/timeouts.html @@ -0,0 +1,374 @@ +The Apache Tomcat Connector - Generic HowTo - Timeouts HowTo
Apache TomcatApache Logo

Links

Reference Guide

Generic HowTo

Webserver HowTo

AJP Protocol Reference

Miscellaneous Documentation

News

The Apache Tomcat Connector - Generic HowTo

Timeouts HowTo

Printer Friendly Version
print-friendly
version +
Introduction
+
+

Setting communication timeouts is very important to improve the +communication process. They help to detect problems and stabilise +a distributed system. JK can use several different timeout types, which +can be individually configured. For historical reasons, all of them are +disabled by default. This HowTo explains their use and gives +hints how to find appropriate values. +

+

All timeouts can be configured in the workers.properties file. +For a complete reference of all worker configuration +items, please consult the worker reference. +This page assumes, that you are using at least version 1.2.16 of JK. +Dependencies on newer versions will be mentioned where necessary. +

+

+Do not set timeouts to extreme values. Very small timeouts will likely +be counterproductive. +

+

+Long Garbage Collection pauses on the backend do not make a good +fit with some timeouts. Try to optimise your Java memory and GC settings. +

+
JK Timeout Attributes
+
+
CPing/CPong
+

+CPing/CPong is our notion for using small test packets to check the +status of backend connections. JK can use such test packets directly after establishing +a new backend connection (connect mode) and also directly before each request gets +send to a backend (prepost mode). +Starting with version 1.2.27 it can also be used when a connection was idle +for a long time (interval mode). +The maximum waiting time (timeout) for a CPong answer to a CPing and the idle +time in interval mode can be configured. +

+

+The test packets will be answered by the backend very fast with a minimal amount of +needed processing resources. A positive answer tells us, that the backend can be reached +and is actively processing requests. It does not detect, if some context is deployed +and working. The benefit of CPing/CPong is a fast detection of a communication +problem with the backend. The downside is a slightly increased latency. +

+

+The worker attribute ping_mode can be set to a combination of characters +to determine, in which situations test packets are used: +

    +
  • C: connect mode, timeout ping_timeout overwritten by connect_timeout
  • +
  • P: prepost mode, timeout ping_timeout overwritten by prepost_timeout
  • +
  • I: interval mode, timeout ping_timeout, idle time connection_ping_interval
  • +
  • A: all modes
  • +
+

+

+Multiple values must be concatenated without any separator characters. +We recommend using all CPing tests. If your application is very latency sensitive, then +you should only use the combination of connect and interval mode. +

+

+Activating the CPing probing via ping_mode has been added in version 1.2.27. +For older versions only the connect and prepost modes exist and must be activated by +explicitely setting connect_timeout and prepost_timeout. +

+

+The worker attribute ping_timeout sets the default wait timeout +in milliseconds for CPong for all modes. By default the value is "10000" +milliseconds. The value only gets used, if you activate CPing/Cpong probes +via ping_mode. The default value should be fine, except if you experience +very long Java garbage collection pauses. +Depending on your network latency and stability, good custom values +often are between 5000 and 15000 milliseconds. +You can overwrite the timeout used for connect and prepost mode with +connect_timeout and prepost_timeout. +Remember: don't use extremely small values. +

+

+The worker attribute connect_timeout sets the wait timeout +in milliseconds for CPong during connection establishment. You can use it +if you want to overwrite the general timeout set with ping_timeout. +To use connect mode CPing, you need to enable it via ping_mode. +Since JK usually uses persistent connections, opening new connections is a +rare event. We therefore recommend activating connect mode. +Depending on your network latency and stability, good values often +are between 5000 and 15000 milliseconds. +Remember: don't use extremely small values. +

+

+The worker attribute prepost_timeout sets the wait timeout +in milliseconds for CPong before request forwarding. You can use it +if you want to overwrite the general timeout set with ping_timeout. +To use prepost mode CPing, you need to enable it via ping_mode. +Activating this type of CPing/CPong adds a small latency to each +request. Usually this is small enough and the benefit of CPing/CPong is more important. +So in general we also recommend using prepost_timeout. +Depending on your network latency and stability, good values often +are between 5000 and 10000 milliseconds. +Remember: don't use extremely small values. +

+

+Until version 1.2.27 ping_mode and ping_timeout did not +exist and to enable connect or prepost mode CPing you had to set connect_timeout +respectively prepost_timeout to some reasonable positive value. +

+
+ +
Low-Level TCP Timeouts
+

+Some platforms allow to set timeouts for all operations on TCP sockets. +This is available for Linux and Windows, other platforms do not support this, +e.g. Solaris. If your platform supports TCP send and receive timeouts, +you can set them using the worker attribute socket_timeout. +You can not set the two timeouts to different values. +

+

+JK will accept this attribute even if your platform does not support +socket timeouts. In this case setting the attribute will have no effect. +By default the value is "0" and the timeout is disabled. +You can set the attribute to some seconds value (not: milliseconds). +JK will then set the send and the receive timeouts of the backend +connections to this value. The timeout is low-level, it is +used for each read and write operation on the socket individually. +

+

+Using this attribute will make JK react faster to some types of network problems. +Unfortunately socket timeouts have negative side effects, because for most +platforms, there is no good way to recover from such a timeout, once it fired. +For JK there is no way to decide, if this timeout fired because of real network +problems, or only because it didn't receive an answer packet from a backend in time. +So remember: don't use extremely small values. +

+

+For the general case of connection establishment you can use +socket_connect_timeout. It takes a millisecond value and works +on most platforms, even if socket_timeout is not supported. +We recommend using socket_connect_timeout because in some network +failure situations failure detection during connection establishment +can take several minutes due to TCP retransmits. Depending on the quality +of your network a timeout somewhere between 1000 and 5000 milliseconds +should be fine. Note that socket_timeout is in seconds, and +socket_connect_timeout in milliseconds. +

+
+ +
Connection Pools and Idle Timeouts
+

+JK handles backend connections in a connection pool per web server process. +The connections are used in a persistent mode. After a request completed +successfully we keep the connection open and wait for the next +request to forward. The connection pool is able to grow according +to the number of threads that want to forward requests in parallel. +

+

+Most applications have a varying load depending on the hour of the day +or the day of the month. Other reasons for a growing connection pool +would be temporary slowness of backends, leading to an increasing +congestion of the frontends like web servers. Many backends use a dedicated +thread for each incoming connection they handle. So usually one wants the +connection pool to shrink, if the load diminishes. +

+

+JK allows connections in the pool to get closed after some idle time. +This maximum idle time can be configured with the attribute +connection_pool_timeout which is given in units of seconds. +The default value is "0", which disables closing idle connections. +

+

+We generally recommend values around 10 minutes, so setting +connection_pool_timeout to 600 (seconds). If you use this attribute, +please also set the attribute connectionTimeout in the AJP +Connector element of your Tomcat server.xml configuration file to +an analogous value. Caution: connectionTimeout is in milliseconds. +So if you set JK connection_pool_timeout to 600, you should set Tomcat +connectionTimeout to 600000. +

+

+JK connections do not get closed immediately after the timeout passed. +Instead there is an automatic internal maintenance task +running every 60 seconds, that checks the idle status of all connections. +The 60 seconds interval +can be adjusted with the global attribute worker.maintain. We do not +recommend to change this value, because it has a lot of side effects. +Until version 1.2.26, the maintenance task only runs, if requests get +processed. So if your web server has processes that do not receive any +requests for a long time, there is no way to close the idle connections +in its pool. Starting with version 1.2.27 you can configure an independent +watchdog thread when using Apache 2.x with threaded APR or IIS. +

+

+The maximum connection pool size can be configured with the +attribute connection_pool_size. We generally do not recommend +to use this attribute in combination with Apache httpd. For +Apache httpd we automatically detect the number of threads per +process and set the maximum pool size to this value. For IIS we use +a default value of 250 (before version 1.2.20: 10), +for the Sun Web Server the default is "1". +We strongly recommend adjusting this value for IIS and the Sun Web Server +to the number of requests one web server process should +be able to send to a backend in parallel. You should measure how many connections +you need during peak hours without performance problems, and then add some +percentage depending on your growth rate etc. Finally you should check, +whether your web server processes are able to use at least as many threads, +as you configured as the pool size. +

+

+The JK attribute connection_pool_minsize defines, +how many idle connections remain when the pool gets shrunken. +By default this is half of the maximum pool size. +

+
+ +
Firewall Connection Dropping
+

+One particular problem with idle connections comes from firewalls, that +are often deployed between the web server layer and the backend. +Depending on their configuration, they will silently drop +connections from their status table if they are idle for to long. +

+

+From the point of view of JK and of the web server, the other side +simply doesn't answer any traffic. Since TCP is a reliable protocol +it detects the missing TCP ACKs and tries to resend the packets for +a relatively long time, typically several minutes. +

+

+Many firewalls will allow connection closing, even if they dropped +the connection for normal traffic. Therefore you should always use +connection_pool_timeout and +connection_pool_minsize on the JK side +and connectionTimeout on the Tomcat side. +

+

+Furthermore using the boolean attribute socket_keepalive you can +set a standard socket option, that automatically sends TCP keepalive packets +after some idle time on each connection. By default this is set to "False". +If you suspect idle connection drops by firewalls you should set this to +"True". +

+

+Unfortunately the default intervals and algorithms for these packets +are platform specific. You might need to inspect TCP tuning options for +your platform on how to control TCP keepalive. +Often the default intervals are much longer than the firewall timeouts +for idle connections. Nevertheless we recommend talking to your firewall +administration and your platform administration in order to make them agree +on good configuration values for the firewall and the platform TCP tuning. +

+

+In case none of our recommendations help and you are definitively having +problems with idle connection drops, you can disable the use of persistent +connections when using JK together with Apache httpd. For this you set +"JkOptions +DisableReuse" in your Apache httpd configuration. +This will have a huge negative performance impact! +

+
+ +
Reply Timeout
+

+JK can also use a timeout on request replies. This timeout does not +measure the full processing time of the response. Instead it controls, +how much time between consecutive response packets is allowed. +

+

+In most cases, this is what one actually wants. Consider for example +long running downloads. You would not be able to set an effective global +reply timeout, because downloads could last for many minutes. +Most applications though have limited processing time before starting +to return the response. For those applications you could set an explicit +reply timeout. Applications that do not harmonise with reply timeouts +are batch type applications, data warehouse and reporting applications +which are expected to observe long processing times. +

+

+If JK aborts waiting for a response, because a reply timeout fired, +there is no way to stop processing on the backend. Although you free +processing resources in your web server, the request +will continue to run on the backend - without any way to send back a +result once the reply timeout fired. +

+

+JK uses the worker attribute reply_timeout to set reply timeouts. +The default value is "0" (timeout disabled) and you can set it to any +millisecond value. +

+

+In combination with Apache httpd, you can also set a more flexible reply_timeout +using an httpd environment variable. If you set the variable JK_REPLY_TIMEOUT +to some integer value, this value will be used instead of the value in +the worker configuration. This way you can set reply timeouts more flexible +with mod_setenvif and mod_rewrite depending on URI, query string etc. +If the environment variable JK_REPLY_TIMEOUT is not set, or is set to a +negative value, the default reply timeout of the worker will be used. If +JK_REPLY_TIMEOUT contains the value "0", then the reply timeout will be disabled +for the request. +

+

+In combination with a load balancing worker, JK will disable a member +worker of the load balancer if a reply timeout fires. The worker will then +no longer be used until it gets recovered during the next automatic +maintenance task. Starting with JK 1.2.24 you can improve this behaviour using +max_reply_timeouts. This +attribute will allow occasional long running requests without disabling the +worker. Only if those requests happen to often, the worker gets disabled by the +load balancer. +

+
+
Load Balancer Error Detection
+
+
Local and Global Error States
+

+A load balancer worker does not only have the ability to balance load. +It also handles stickyness and failover of requests in case of errors. +When a load balancer detects an error on one of its members, it needs to +decide, whether the error is serious, or only a temporary error or maybe +only related to the actual request that was processed. Temporary errors +are called local errors, serious errors will be called global errors. +

+

+If the load balancer decides that a backend should be put into the global error +state, then the web server will not send any more requests there. If no session +replication is used, this means that all user sessions located on the respective +backend are no longer available. The users will be send to another backend +and will have to login again. So the global error state is not transparent to the +users. The application is still available, but users might loose some work. +

+

+In some cases the decision between local error and global error is easy. +For instance if there is an error sending back the response to the client (browser), +then it is very unlikely that the backend is broken. +So this situation is a typical example of a local error. +

+

+Some situations are harder to decide though. If the load balancer can't establish +a new connection to a backend, it could be because of a temporary overload situation +(so no more free threads in the backend), or because the backend isn't alive any more. +Depending on the details, the right state could either be local error or global error. +

+
+
Error Escalation Time
+

+Until version 1.2.26 most errors were interpreted as global errors. +Starting with version 1.2.27 many errors which were previously interpreted as global +were switched to being local whenever the backend is still busy. Busy means, that +other concurrent requests are send to the same backend (successful or not). +

+

+In many cases there is no perfect way of making the decision +between local and global error. The load balancer simply doesn't have enough information. +In version 1.2.28 you can now tune, how fast the load balancer switches from local error to +global error. If a member of a load balancer stays in local error state for too long, +the load balancer will escalate it into global error state. +

+

+The time tolerated in local error state is controlled by the load balancer attribute +error_escalation_time (in seconds). The default value is half of recover_time, +so unless you changed recover_time the default is 30 seconds. +

+

+Using a smaller value for error_escalation_time will make the load balancer react +faster to serious errors, but also carries the risk of more often loosing sessions +in not so serious situations. You can lower error_escalation_time down to 0 seconds, +which means all local errors which are potentially serious are escalated to global errors +immediately. +

+

+Note that without good basic error detection the whole escalation procedure is useless. +So you should definitely use socket_connect_timeout and activate CPing/CPong +with ping_mode and ping_timeout before thinking about also tuning +error_escalation_time. +

+
+

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/workers.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/workers.html new file mode 100644 index 00000000..37f32ee7 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/generic_howto/workers.html @@ -0,0 +1,409 @@ +The Apache Tomcat Connector - Generic HowTo - Workers HowTo
Apache TomcatApache Logo

Links

Reference Guide

Generic HowTo

Webserver HowTo

AJP Protocol Reference

Miscellaneous Documentation

News

The Apache Tomcat Connector - Generic HowTo

Workers HowTo

Printer Friendly Version
print-friendly
version +
Introduction
+

+A Tomcat worker is a Tomcat instance that is waiting to execute servlets on behalf of some web server. +For example, we can have a web server such as Apache forwarding servlet requests to a +Tomcat process (the worker) running behind it. +

+

+The scenario described above is a very simple one; +in fact one can configure multiple Tomcat workers to serve servlets on +behalf of a certain web server. +The reasons for such configuration can be: +

+
    +
  • +We want different contexts to be served by different Tomcat workers to provide a +development environment where all the developers share the same web server but own a Tomcat worker of their own. +
  • +
  • +We want different virtual hosts served by different Tomcat processes to provide a +clear separation between sites belonging to different companies. +
  • +
  • +We want to provide load balancing, meaning run multiple Tomcat workers each on a +machine of its own and distribute the requests between them. +
  • +
+ +

+There are probably more reasons for having multiple workers but I guess that this list is enough... +Tomcat workers are defined in a properties file dubbed workers.properties and this tutorial +explains how to work with it. +

+ +

+This document was originally part of Tomcat: A Minimalistic User's Guide written by Gal Shachor, +but has been split off for organisational reasons. +

+
Defining Workers
+

+Defining workers to the Tomcat web server plugin can be done using a properties file +(a sample file named workers.properties is available in the conf/ directory). +

+ +

+the file contains entries of the following form: +

+ +

+worker.list=<a comma separated list of worker names> +

+ +
+  # the list of workers
+  worker.list= worker1, worker2
+
+ +

+When starting up, the web server plugin will instantiate the workers whose name appears in the +worker.list property, these are also the workers to whom you can map requests. The directive can be used multiple times. +

+ +
Workers Type
+

+Each named worker should also have a few entries to provide additional information on his behalf. +This information includes the worker's type and other related worker information. +Currently the following worker types that exists are (JK 1.2.5): +

+ + + + + + + + +
TypeDescription
ajp12This worker knows how to forward requests to out-of-process Tomcat workers using the ajpv12 protocol.
ajp13This worker knows how to forward requests to out-of-process Tomcat workers using the ajpv13 protocol.
jniDEPRECATED: This worker knows how to forward requests to in-process Tomcat workers using JNI.
lbThis is a load-balancing worker; it knows how to provide round-robin based sticky load balancing with a certain level of fault-tolerance.
statusThis is a status worker for managing load balancers.
+ +

+Defining workers of a certain type should be done with the following property format: +

+ +

+worker.worker name.type=<worker type> +Where worker name is the name assigned to the worker and the worker type is one of the four types defined +in the table (a worker name may only contain any space the characters [a-zA-Z0-9\-_]). +

+ +
+  # Defines a worker named "local" that uses the ajpv12 protocol to forward requests to a Tomcat process.
+  worker.local.type=ajp12
+  # Defines a worker named "remote" that uses the ajpv13 protocol to forward requests to a Tomcat process.
+  worker.remote.type=ajp13
+  # Defines a worker named "loadbalancer" that loadbalances several Tomcat processes transparently.
+  worker.loadbalancer.type=lb
+
+ +
+ +
Setting Worker Properties
+

+After defining the workers you can also specify properties for them. +Properties can be specified in the following manner: +

+ +

+worker.<worker name>.<property>=<property value> +

+ +Each worker has a set of properties that you can set as specified in the following subsections: + +
ajp12 Worker properties
+

+The ajp12 has been deprecated with Tomcat 3.3.x and you should use instead +ajp13 which is the only ajp protocol known by Tomcat 4.x and 5 and 5.5 and Tomcat 6. +

+

+The ajp12 typed workers forward requests to out-of-process Tomcat workers +using the ajpv12 protocol over TCP/IP sockets. +

+ +

+the ajp12 worker properties are : +

+ +

+host property sets the host where the Tomcat worker is listening for ajp12 requests. +

+ +

+port property sets the port where the Tomcat worker is listening for ajp12 requests +

+ +

+lbfactor property is used when working with a load balancer worker, this is the load-balancing factor for the worker. +We'll see more on this in the lb worker section. +

+ +
+  # worker "worker1" will talk to Tomcat listening on machine www.x.com at port 8007 using 2 lb factor
+  worker.worker1.host=www.x.com
+  worker.worker1.port=8007
+  worker.worker1.lbfactor=2
+
+ +

+Notes: In the ajpv12 protocol, connections are created, used and then closed at each request. +The default port for ajp12 is 8007 +

+ +
+ +
ajp13 Worker properties
+

+The ajp13 typed workers forward requests to out-of-process Tomcat workers using the ajpv13 protocol over TCP/IP sockets. +The main difference between ajpv12 and ajpv13 are that: +

    +
  • +ajpv13 is a more binary protocol and it tries to compress some of the request data by coding +frequently used strings as small integers. +
  • +
  • +ajpv13 reuses open sockets and leaves them open for future requests (remember when you've got a Firewall between your +web server and Tomcat). +
  • +
  • +ajpv13 has special treatment for SSL information so that the container can implement +SSL related methods such as isSecure(). +
  • +
+ +

+ +

+You should note that Ajp13 is now the only out-process protocol supported by Tomcat 4.0.x, 4.1.x, 5.0.x, 5.5.x and 6. +

+ + +
+  # worker "worker2" will talk to Tomcat listening on machine www2.x.com at port 8009 using 3 lb factor
+  worker.worker2.host=www2.x.com
+  worker.worker2.port=8009
+  worker.worker2.lbfactor=3
+  # worker "worker2" uses connections, which will stay no more than 10mn in the connection pool
+  worker.worker2.connection_pool_timeout=600
+  # worker "worker2" ask operating system to send KEEP-ALIVE signal on the connection
+  worker.worker2.socket_keepalive=1
+  # mount can be used as an alternative to the JkMount directive
+  worker.worker2.mount=/contexta /contexta/* /contextb /contextb/*
+
+ +

+Notes: In the ajpv13 protocol, the default port is 8009 +

+ +
+ +
lb Worker properties
+

+The load-balancing worker does not really communicate with Tomcat workers. +Instead it is responsible for the management of several "real" workers. +This management includes: +

+ +
    +
  • +Instantiating the workers in the web server. +
  • +
  • +Using the worker's load-balancing factor, perform weighed-round-robin load balancing where +high lbfactor means stronger machine (that is going to handle more requests) +
  • +
  • +Keeping requests belonging to the same session executing on the same Tomcat worker. +
  • +
  • +Identifying failed Tomcat workers, suspending requests to them and instead falling-back on +other workers managed by the lb worker. +
  • +
+ +

+The overall result is that workers managed by the same lb worker are load-balanced (based on their lbfactor and current user session) and also fall-backed so a single Tomcat process death will not "kill" the entire site. +The following table specifies some properties that the lb worker can accept: +

    +
  • balance_workers is a comma separated list of workers that the load balancer need to manage. +As long as these workers should only be used via the load balancer worker, +there is no need to also put them into the worker.list property. +This directive can be used multiple times for the same load balancer.
  • +
  • sticky_session specifies whether requests with SESSION ID's should be routed back to the same +Tomcat worker. Set sticky_session to False when Tomcat is using a Session Manager which +can persist session data across multiple instances of Tomcat. By default sticky_session is set to True.
  • +
+

+ +
+  # The worker balance1 while use "real" workers worker1 and worker2
+  worker.balance1.balance_workers=worker1, worker2
+
+ +
+ +
Status Worker properties
+

+The status worker does not communicate with Tomcat. +Instead it is responsible for the load balancer management. +

+
+  # Add the status worker to the worker list
+  worker.list=jkstatus
+  # Define a 'jkstatus' worker using status
+  worker.jkstatus.type=status
+
+

Next thing is to mount the requests to the jkstatus worker. For Apache +web servers use the:

+
+  # Add the jkstatus mount point
+  JkMount /jkmanager/* jkstatus 
+
+

To obtain a higher level of security use the:

+
+  # Enable the JK manager access from localhost only
+ <Location /jkmanager/>
+    JkMount jkstatus
+    Order deny,allow
+    Deny from all
+    Allow from 127.0.0.1
+ </Location>
+
+ +
+ +
Property file macros
+

+You can define "macros" in the property files. +These macros let you define properties and later on use them while +constructing other properties. +

+ +
+  # property example, like a network base address
+  mynet=194.226.31
+  # Using the above macro to simplify the address definitions
+  # for a farm of workers.
+  worker.node1.host=$(mynet).11
+  worker.node2.host=$(mynet).12
+  worker.node3.host=$(mynet).13
+
+ +
+ +
Hierarchical property configuration
+

+Workers can reference configurations of other workers. +If worker "x" references worker "y", then it inherits all +configuration parameters from "y", except for the ones +that have explicitly been set for "x". +

+ +
+  # worker toe defines some default settings
+  worker.toe.type=ajp13
+  worker.toe.socket_keepalive=true
+  worker.toe.connect_timeout=10000
+  worker.toe.recovery_options=7
+  # workers tic and tac inherit those values
+  worker.tic.reference=worker.toe
+  worker.tac.reference=worker.toe
+
+ +

+Please note, that the reference contains +the full prefix to the referenced configuration attributes, +not only the name of the referenced worker. +

+ +

+References can be nested. Be careful to avoid loops! +

+ +

+Attributes which are allowed multiple times for a single worker +can not be merged from a worker and a reference. An attribute +is only inherited from a reference, if it is not already set +for the referring worker. +

+ +

+References are especially useful, when configuring load balancers. +Try to understand the following two stage references: +

+ +
+  # We only use one load balancer
+  worker.list=lb
+  # Let's define some defaults
+  worker.basic.port=8009
+  worker.basic.type=ajp13
+  worker.basic.socket_keepalive=true
+  worker.basic.connect_timeout=10000
+  worker.basic.recovery_options=7
+  # And we use them in two groups
+  worker.lb1.domain=dom1
+  worker.lb1.distance=0
+  worker.lb1.reference=worker.basic
+  worker.lb2.domain=dom2
+  worker.lb2.distance=1
+  worker.lb2.reference=worker.basic
+  # Now we configure the load balancer
+  worker.lb.type=lb
+  worker.lb.method=B
+  worker.lb.balanced_workers=w11,w12,w21,w22
+  worker.w11.host=myhost11
+  worker.w11.reference=worker.lb1
+  worker.w12.host=myhost12
+  worker.w12.reference=worker.lb1
+  worker.w21.host=myhost21
+  worker.w21.reference=worker.lb2
+  worker.w22.host=myhost22
+  worker.w22.reference=worker.lb2
+
+ +
+ +
A sample worker.properties
+

+Since coping with worker.properties on your own is not an easy thing to do, +a sample worker.properties file is bundled along JK. +

+ +

+You could also find here a sample workers.properties defining : +

+ +
    +
  • +An ajp12 worker that used the host localhost and the port 8007 +
  • +
  • +An ajp13 worker that used the host localhost and the port 8008 +
  • +
  • +An lb worker that load balance the ajp12 and ajp13 workers +
  • +
+ +
+  # Define 3 workers, 2 real workers using ajp12, ajp13, the last one being a loadbalancing worker 
+  worker.list=worker1, worker2, worker3
+  # Set properties for worker1 (ajp12)
+  worker.worker1.type=ajp12
+  worker.worker1.host=localhost
+  worker.worker1.port=8007
+  worker.worker1.lbfactor=1
+  # Set properties for worker2 (ajp13)
+  worker.worker2.type=ajp13
+  worker.worker2.host=localhost
+  worker.worker2.port=8009
+  worker.worker2.lbfactor=1
+  worker.worker2.connection_pool_timeout=600
+  worker.worker2.socket_keepalive=1
+  worker.worker2.socket_timeout=60
+  # Set properties for worker3 (lb) which use worker1 and worker2
+  worker.worker3.balance_workers=worker1,worker2
+
+ +

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/images/add.gif b/rubbos/app/tomcat-connectors-1.2.32-src/docs/images/add.gif new file mode 100644 index 0000000000000000000000000000000000000000..0774d074e5e48291bdacfacb086506e6be117e51 GIT binary patch literal 1037 zcmZ?wbhEHb6k!lyc+SA^9|->a|M&0T|Nno1n4h0tnTz4o;>0&glV!LWO;{KX^ykTP zGrU;!o~1phVTD*cK_!)em>kR#mn&Z^0eO_xlSoe_rhTdU2{GAH%zidEYmsygkrvrz1CG(e()%elNK2f9s9cY)lOA zFHHY+vFYoj2~vCv9}m?1K3M+d$V54A1}%N3>6>p)KJ;Ph^-o+33=fX46z69#)mMIU zX`LuPvyQH3L))$XdH+|R`pLj3#K*_?|NDPF1}|^fSwWhMt)w~)6|3?yj#iYvY3u#U zz+k?5_Z0?4&i}vuGc&jbXzljryOSdOKilYUx!k$z`*f|fsunnK;giFW)5K{fr5eq4b7~gYAGEP z7#KS_xkU;zCM1>#7e(d>$#qP^BWE~tBtO4mJmGb}q literal 0 HcmV?d00001 diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/images/code.gif b/rubbos/app/tomcat-connectors-1.2.32-src/docs/images/code.gif new file mode 100644 index 0000000000000000000000000000000000000000..d27307b5c09467c2e45bbfcd1ff74989eb2e7d65 GIT binary patch literal 394 zcmZ?wbhEHb6k!lySjxcg|NsAg|Na>m7<~Bf;lYCk`uh5YhK2_Y90&`0TwMGlHulx| z^XKp1zrTO~{%OFIr0wCGk>*L_#l_fx07^78uf_y0eALxXeY&ZVS$tf_gsW5<=_ z#~&LR{Wx~~@qq*T{{8>o&~U}u`>TV)%Z7#qKR>_t`1lhio=8gm&d$CqCiY|X>Z2Pr zZ1DH@->~lav}tGl|Nm=XU^H>*6ylK%0}z1x!oarPp`pM-N2)dikZ=q-8iKhfFV&ot-Z?#bsK$q(mDRr`$3(c`=?^VUbBf3LBO?F*3FB z2rH&5?cP|btfH!>&Z(iPC8xdDk6A}sSMT=aD<1m#3{1+}>>KXh^JOqF2nv4n;e)*V JgAa}j)&TJ-upR&a literal 0 HcmV?d00001 diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/images/design.gif b/rubbos/app/tomcat-connectors-1.2.32-src/docs/images/design.gif new file mode 100644 index 0000000000000000000000000000000000000000..f5db0a9fc783924486176ce157924fba53df73fc GIT binary patch literal 608 zcmZ?wbhEHb6k!lyIL5&6|NsAgK=A*+y}iAiot?eCt%HMuEs*J8ujLw+y7Ptq{{K!J zf7q}4X0-UF?)+zRlW&T4U*v2)!e6yXwRo0{SJEe-5&!>cxrG=mdLiwZn4h0tkeBaZ zXTN^^`uFeOe|Y!)!-o&&&!6AFfB%LJ8x|~BuzKPA|Ns7#x-xkKyruV1%sHz7ZzCM7sKSh-eh--RQa&hK1ucJ=HF%O;;& z(71m>$AyWdcbfMc+`Vw!lBw%v)-7nyom8CNS*TU6fAIXF^#?X=1X{Rn{hEX8E?l^< zY2Dfj=YX!b$S}x&4#+*AxL{yE+Q87%#Ms=-#MIW++}hp8(Az(WfqCjw7G_pfW;S+? zK29!f9$r3v0YM>Q5mB)&afwAsB$uyTEw!$TO?uDXeKN9r%yRNakI5@2C^8>9BCn*Z zBB!dVrgo-TU7hjpQ4LKkZEYR#ysImZEe>aVg^r Vos(-!G%qcgJt^mrj0gvVH2@9_)ye<> literal 0 HcmV?d00001 diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/images/docs.gif b/rubbos/app/tomcat-connectors-1.2.32-src/docs/images/docs.gif new file mode 100644 index 0000000000000000000000000000000000000000..d64a4a18c405e2c10ab791363f9f7acd16f3d433 GIT binary patch literal 261 zcmZ?wbhEHb6k!lyXklRZ|NsBLfBy^&3_g7L@ZiA%eSLjHL&F0H4xB%K{{H>@`}gm^ zaN)w=|Nrz24bGiAckjXd0|)l~`~Sb8p~273FFrp0;lqa;Hf-?s_kVc*!TptFK^W zYAveoFcA_K5zXln5UZ$U78jG4CN@JuQj&p5NQ}L2!9raIDJdi4wVO8!3NGHP$Y2cs DYrJfE literal 0 HcmV?d00001 diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/images/fix.gif b/rubbos/app/tomcat-connectors-1.2.32-src/docs/images/fix.gif new file mode 100644 index 0000000000000000000000000000000000000000..d59ad642ba46c0bc1af17ebd2485722e92d6c70e GIT binary patch literal 345 zcmZ?wbhEHb6k!lySjxcg|NsAg|NhCz$;r#h*Vot2pFe-Xgb57|4F?V!*sx)Pf`Wp- zzyHC52YafE7nQ{H_?deNa@Yt7|Ns5_|Np=BjScHJZqShyb`oKj>}~Xa{jy+g9z6-E ze;_me7)uCF^D_FsZh9ae>;K=s{^BeQRBRf^&21nd@qhh{Kt8trzduj* zHV)$93F2e56B6$9w|uc@qp`Ti|35%m2ml=hAOQJ=fvwJ=K|nx4s{h22qR1Gdx!wm8 zv|72?TbvF$Sny2pWe}U_A+XHvXu`zQIrE#HnF2E`LX!mA98j7>H; OF){5sba63^6 literal 0 HcmV?d00001 diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/images/jakarta-logo.gif b/rubbos/app/tomcat-connectors-1.2.32-src/docs/images/jakarta-logo.gif new file mode 100644 index 0000000000000000000000000000000000000000..049cf822952a03141b4bf46a65324e7985a38618 GIT binary patch literal 8584 zcmWldhd#!PG412aE=M1OPZ3E-ofvZe$+dp_7+Ne~UKn zz3KiN)@5rVpas3}o}6wKQgz0{J5=nz=8M2QjP^Hg=(3U9=F;(Wy!wil^S3mYTz&g9 zD1|18gP(-K8yg#Uea+p;8RO*%CvhqXrsjcU=ZbviuJ+)=BG%R3Rv)K>1rqkVUkU?` zpB%m$nNV2ej#n=iiHNo|>hBJCxwvR9=@O>v-=DFxqC?!Ru@sa#jI^NG(vo}_vnlqh`fl2-r)@^-* zVW&ddm;rMb9(V*482F%$I65(csxjERSn-r(T=+ zB^Z09o^@DS5+1}kPbU=SIog@1>2v9)e?&Oo@pziJX)9VgK*g{Ur~S0OeRfvR)5D7} zcDsG{L`C|E2U;GD`{<hgz!~+p852K^0nr469KXzD)an9@Pr%1PigoH1O*21Z0?d@&7HizBu#uZ_{ zcZ-w0eEG7G?hp^g-wqF^sTf6=M4r;I%ySB#PS4Fvb5FyErCU2xdIzXU?h7&x9l8JD z?%l$BX~}H%#lhA}!Q_)%aXl6;h)H!%4LP}^W}P8&z8PfZonCl-bw(y*-t+&>4Ij`;GZ+hyHqD!_KQ+aQ{cSKN3bR0GQEY2V&Y z>Qe92-8@<(Z4mWpyt`$rjA~c7^C@R){F0{EjlhYXwr4f8klgyEw&ohCf)lNBNv`d` zUxl*p3NC#eu6CywJCz-+8Y+>|qFZ{h&x@pTypP-{dU8I}H*2il!Ry-{9UD?`OOVl( z*&+^bc-j86r>@7KRkY%t;vG#Ak9?yxGLmPUNY;13o0=ycn0iP6Gf;KN`qNJ#05I4V z`na~csqi%o(J}1#*zI61RJzt#d&KaP#>sp%!>hGP%EaqR!#=>^>QmCm4n~i9Lt(hf zu6mCT7b=Dut--F(To==WzHdJCD@qcs|K+K;R|fxaJpa^8ok#9osf@HpM-roEjv7D;QpWvCPeB!s@bP+Klhq1-~h zq?V|(xNzL^VURkcHz?BQV0md>WJ)#FFe4xOF^9-eV$|D_#cKj99CGG@sF?E&G@D`_ z`%hVv{FDDU2||2`DzYUfh?>VPlK(LcIBqnXSE0OWSg6`0vNi5$SeO!e5_lc&RmyGl zS$y4Cm2j^RY@Py1C5Ww|F||vZGi`=@1)WQi@~j0GgxG^%qbQ;{a|v}+=z&m-41J8; zzmt|pHWU7m@bOI{$1iIB&b&)kF|UO2i@E?1qJO&_F3@?u7M5@LdIX_r(;K+zVlq3D zwPqtLpA};s-TC=Fp{u{S#b%#`n48&Zr(8L@_n-g8SpN0I;x<%4_SPLhtO`^HyIQw- zkl0bnBC_nJ@-aPG&V7}WW3Ah|a$~d!&IO-*O@>)7>_zto`ZK4Lf75CEtcoWmpa-q1 zA-c&&8H8dVzi#!qA}%{gJ2#<}DAjYf7RAmy=SdyT!)v+@pHjKy7wjyzJ1G)og&Fq< zgVns6351D+W;vdJ)ju)0m-~wLt{~9C0}ph(+h?m1xdyOqiRUtRw{5oa+ow)bt{Ger zSJ`$1%K>agxJoY3tOxoxS#Kc1w%(GXoZch#-VRGyQz&l~6YrksmC!X!J;hh&6xYgJ zSln3uI&S7h8FJ;22MDdndJtX>wbk6j(=Gi|WaQ_C+ZyMH*WXr&lzpJ@E*v-a2=;wK z1%gX6@iX4JM-J+I55gTvSqPyVnues6vp?puUv+pPD1k8dSXqSFIy=K$K1_2)MIjWa zuQc1I>qxQ5h**GBCM{d2@1M#3bz@{;ozxmoe~B8#|JHDw7<#CFTVY+)*kbytMsTli zj*1TM`1?I3X%FCDj!5~gFzeKm4J`QCRGM&93)S@tYD>)BYh+G)lv`cTl1`0B+Nn%1 zvgm~l*rIROy@T8gvlto5t%5cix*e_nbkL7#!dkIxC}Ho0<=2Mp(iEuhBc^$`H-#`2 zVh9dpjVcgRA_^ceO;4EPF-mQ%Fo|@nG z#HS{>8g=?$r+jPS6TRF@w^8w~Vh6bqLl_P5u!D)-B$CR@FuUMxJ#^_0q?pGLJ$ohK=I2%$+YZv{ z85T8Uu0;Hk8R)cl$`}#U1X_;f>I*&Peov`{7+An>i(z=8p(!H%{hS_|?#ULsB4pvr zpZaWD9QG@*CC-yBKNL_40-Ee<^KU87xm6@9II<1rxX+n71uF&|JP z-Uu80cR`{FnGD1Gby$l}LUQbURZK@lc6xD(>;#yjxEX;v&g0&RG~HvLR^pKUT`iQ) z+?gjgvN66iJD3{Q5oRi0dJ6llUE^}A`*|rPEn)|8^i%HDLI;oq&&wI5=KEuM(D!7K zQ6YwmcXUMmhozniy^92i0Wq`5&Shql5q5m|roG=&Ps6AF<2vAHMXLGv#Mk@t$;2U_ zs8X*BflFChiTUo6U^Vs6sa2>o_i~n`arfsOUc{UIC5!#*q3**v4}EQx7LiPFmNgo2 zbP|>|l*cJ%^8Qeq=4I^LG08JagYGg+A!)8x z7V^RHQAhQ>9;^tNuzu^Ta2!97ZSMWF%5^G1ay&t=quLx-TEr04jm_-!wYYp$sqaY0b%pl@nIWjok#16!8RjPf2K6wPxB^g{MMqe)+;>% zwv8-XGx;#dIHr7Qzp1W%p`*i2=AG~>^YVMsT!QEK8$coyS?3yS;``v8LgGyrnruUq zNop3kmEYsPN9gUeS(w)-D)kg z`^bZ;(gctD&C;o?QPn!0zp{?9>`Ou1$M$ZDlDE9nf{-u8AiN91X8s|64eofEm8Uco zB(@ild|r`XV3W><>*w&5H?|6onl_Q6B2agVdOkR)`uyeg`;H9EJ3NCf4V*?vJeK>l z^3cLvbx&ekX4@;RtHuW7t@C)0zqe|;@*?#!YUp0A{W}S&zHIgV#O>dO23eV#V!+je zM-2z%Co&dZ&l1kYJwE!acwdLGNmGE#qG5Asgk*qNagXvhjdHU+N+J*Wj*5TFIyS)} z&M{F+WAGsw1{@AajR%?l)Nl_lmVhHL@ttg)0T#A~p)g+_s!t^p@rX|Zc(bEyx(9Qg zx7`1#u_&~@qA@scLNE#eH@f3jsp;*!TlEx@~E9(us6P7 z;R2*Z5YbPFHRNFSYPsR3ScL6O)IW?^2@}d&puh|nNkN-LuN77VK`5z>l9h2TKfSj-+Eq29$zAQ_>?3X!O&|@uIwze|DK69mXRyFt_8!J*J zRmP`A8sgwVHboC^#v^C|$#NF)|)< z2;qF=uWa=FC#cM9OuG*1TU{$uf+CJ zlYj1Bhz0Z4gi33GP9&XZ0su`Ud985fDy z$7ySWF)Z>A7SPI|oD&kOg;*(n(j1%cw}1;!(c4rk$@Ex_AHkZBbz+b*LD++8!tGI1 z@Hw)&kdPJ+tS~WiK^P@YeG&_0#>D9QDV%#u>I9HV5QUWq`^F6oWx#$4u&U+O^~pi! z^&C#~ZQ%?vW+L&OPXzRwB(DvmW@PULbQ}-&MgK0;LdIU4m@E3(Z<`i%*4n5EvO9tg z!s>XVt75%V{J~y`Zso}|;5v&$fjI+U-Vck+%f+azT%=SHsR{#IKv8b5(r~GC%OWtRvJ2v57%M0++h=vX%uT&;5mR_WbL{3C> z*gN77gD@ei=#fC&H^%Je;k3)u{#|*HHs7EXv&q zb(SjTFF*m$C47ZEQ9{Z&29P8M`$qK&h0t;kDg=ay0O%4Px_?R3s{dl?-~Hkqk+nA6 z91BrDeQ-n>yv0zU2Ouspl~F8;8VXem-0}tP%mH_t*!Z5+mf9w^UlDQwAe4P474tp3 z8H76m!Y>-EwU!iolW>KF9&FyP#06Mlm`6;?X#{E!zzomgCL!`si1O(__y?Hy>dlOC zkl+ttUhs$qHzBQ={;JeRpQ6nS`2KMPk2GN_V?xC-THnF^HX|B3Ng!V=Bu;Pk%?q)N z08%r^C)VcIivew{C~F$Yk9RBuB-WUc4O!@(QA(IsxsD(@Ego&vzQ3JISbbWcQRNxJ zAtd%HU){X&kneE@z@2#sm*gQFtAP>5qqen2rmt9QKhn$|i2kku-eqE984BT> zX1K3#{DtML+VNSXSYjx!_g_d%>3+<-%tOozDHuNXt04LpaI2aRpJGijiU?geMAsq_ z(4iP|*-gcCK8rwzKtHEa<{`%+PI4z2(F}y_e}xubKV&SRT=I*xX5vS7uXN4>A$;Oh zu8u(!;oBzJh)?>102^T;|74Los4xvSPrczq%EK2F5sEzx#Q|X1EXoca-ylTN`FI@$ zaG44J2%shaWSo%LpK#xJ?N|yQzCy$7vL^xqNZU-*wxH$8$^n-PgkyiBwmHc?1j0Rw zb1u<1Z?HmMh-l*7MzQhoK>YyEByBrDiHDjAP?uSt#A(FCL!OCWc7f|qyhK}SpwKGz7WXWm(%+(j> zvWPO_z+_m6DiE#=yw>nQm8O6)0X^C<>?c$2gO9*9rW$vqRyAm9qiA{Kf2LX@6a|Rr z5B3-HLd##_LKqDVLSqF}^i(W4gh6TLztNUJOar&Ns@@vo;W~^DpHHI;xx@v47`FNL zn=-nMiT1M~-8P0>7^9qkf_@$_o)DVJM@~hn=dn;vJ&X31sN`h^+ysPIF_E8{fE9qZ zVFJ-mql^dYM_YVZx^F#B^d+0;!wy7lVKHA7ujq3e^9w#U;alj8S7k*Q~YO#T3>L(c<*?~_m5dvf?%o2nn zxV_>cYpD{epuwt|UX?a^Q+0-9tSEX_cj{;QBU}EYb}Vt2gBNn}AVk@La0y&x*EjM6 zK*I~{1spi^@|ts(GCAEJGxL19mjt@4giVFM8BWnpzSPLC`=6I^mH*G3cgS@7HUlHYs^ zFKV}&?|NR!VJ>OJofXpr0XS!Q{R!{)O*2mh`4kn|1(LoxW*ZiXmhcgB5Lz5WXS2!B z9t#y`FfyOfIklxe-+gaN58ZnrMV*SNZ8H$}L;%XKPlzKpUZEyHuR}`bm*t3N zo7L)+%8Jq>edU_75B;)&pNz+Ni#16bde-%Y91KKB48&EkBW$hKq*1~!M~>%-N2b20 z(dXqi7dn&mwE5%lu&_V{L%;V6J>jo2>&%aDNG*Ambr=j zeJeDsk@B?du*h_SL3ulraZ#NMMaBssE6=*`-5;e|{Ci^~bj%J{=RHm*)9U=;jLVjf zme_R%#XZ85yjK>(m0V-=5ViUMmp81R%?bw;vBIGSRS@D9B|yln5?vM1JOCcJbVdti zy6x1!(=95wsa^VVLbFwe;EcDMEss=F0I;5FTKRLgu6TUcZ|!KRF3zRA4*R5j0EiOT zQUv0od&VWj%sj7iW@lDZwVv|7XlmOBBLIa-@zv2Xz+;cts(jv+-XNDOmT6z+zCEi7 zG@2Ebn2Qa3(X^iZ)icwU7HC&%()D8rVHw3>XXD4Is+sSi`Y~{Q+2)}&Xk)d`A7eiQx-ycV=eG`3vE%DbE8Ycun)*-{u0}cJ=*}O)by?Se%6f$;(=5VAJk*}+ey%^* zQso@4i)}Id!@bmkza5^9;5s>!$3D3pCVy_u;s|J8aXqKPYz0)S47JW1tv4`sY^y$z z;*kraP~aZ&Fzo?Y9c+*thW?-4`f|SR2rj7nmKf~k$*e;+GCev5W%gPc3dILU?Q3Ln zj0zr#_7i`bo@Ht_-ZfwA+_#W_O=JI|J(E?%94uGfcv|J6mN<}~TVi~b{8AXv@$Y!* z=BQNd`?ky@^ld{)c0_SA``fz`sXb6#Gt<8$U2RLLxwrk3RTBK~hWQMxe_kjyPAgSV=bEIOVkog4rPs}2NOy6e===VWxGrA7mZ4DT z+Gl$MW)gWrz?J#0u;r)i5IXVCL??JdumtZVY-asc4a}yb)wDF8HS~C)+_1j#Mzs+NUI*P zOP48X>{^)0fr%O^F3QzI3^!#x+^uL;kyP=^#Vp-{22<~J{k2wc8G!0IfG|TzhCVO7 zP=h`ps8LNGBB<<%6qxXCpe;K_FmBzpgkq4@fE|OEW|dm}_xUyTdz08K%)?s(d3waW zSg{vEJ+R5=DKleVeHB6ssVlWMIZA$lpah+XAsd^HCAn^9o6WT-whQgiScV9upDX$q z3zHRr0E9GG6z%6ICE0!Z7K~AO{(7dNgGx>e>ug&81OMat=!yqAA5d^%Nd>;$5(qt5 z=Dmp1PF(gBPQ+(~yliy@O((7xm(ZLEUYdvmHHWF4N)_11{(tk@eASyTsVYq9yqQx4 z7<1PToGF=uR7lFunaoq%)q|ry#nZ%Xl!iYYLl5)hPYSYRCTXLKobD_MZ7Q+l%jmUr z&K_m3iw2iwkxksH&|;k&`MS+;D@$fx%<>ZAt0|=W()o2rU49^JP|)$_cpDp?$cE ziXv`~hJ1|1!@e}%92XfNBjD}JcrCY=M`OfhNXntVgFfSt8YS1DSw5;V1kWe5(g@<3 z^RBaPx&XthNWXYk^Mt1Emfz*)+E}WFXHtgt^_0M}{^t7ywWGx9xw-(`eL$KMCh<19 zLW-ZzDP??JIfY8VGlnGPuo&4B88ER|%DqO|Y`F*#G%hkqWC zSY~2;xf!tPGk`(AUMQ+I*rNTDI$DSG`&JTL(Jl;ac9&)1m9J_q%7OOT3gNg-rU;rl z4kVS6Z+*F0IxJRUtSRnW)|qMh!)?SJJ=0|qwSG@oD=WdqGgtp$8|Qoh0qDzksBs}w z;*|9DD9t&KD{xN*ar|{hv`v$C-)cz1dYfaTUX$ZX{llfeBTeyV1i^K5SPLJaxK{P&JTT0Fe z3fp44D!!s3L>JCQ?iVSDLB3cxpFB5Kea+}#lK6a{_LM<<2{Y@S6J8c*jcFA;^7npV zXug?bd4m`GDA4lVrMbA4KT^LqMp8ed@5DRxd3?-z@$2x=X?wNO?%Wu#h3t;a)8bB% z%`KICKPKs+urqLc$1=DW5v#EdW!gc_a1M2>O^1bbkBvg8@p5E$V5Rnk%~*TDQ9Aoo zf!z+5f?%bpJ)qfK`8Q_imv-(B-IEB54#cuMQiWqF9z#-(JjQBom{S|`bLHM_Ng`eM z5AzEL!hG65GLXKvf}v#{=wj&Vh6)O6~g@_dra{RS!SGz6-Z1Fj%Acx>;AR% zVBmgBa8G4Y(l1rK_?@I%7%qGC?($#X Zi_RYUd+g+2--d3(NZ%FJU@*Yq{{T+YGx7ic literal 0 HcmV?d00001 diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/images/printer.gif b/rubbos/app/tomcat-connectors-1.2.32-src/docs/images/printer.gif new file mode 100644 index 0000000000000000000000000000000000000000..5021187b064c981bfa6688696d7144557468aaeb GIT binary patch literal 438 zcmZ?wbhEHbRA7*0IP#z2KM*i5+`E78+VyMa&YwHSV0i5Kv8~&-E?u^C&b&EOrcG&S zYbh=)PM*h*oS4i2RBAAXfq~(`fdfF27@+u*g^__lh(QOW7-S~{>;DBReJP%LD^{+1 zWwb0OW|y(&kV>k zoOo=K^QXOuJ0Hm{NahgWnfSbCS&!m_J#TnkY(62tR9SRN+sgHj0JFEIS?oy@Hx34C E05v70Bme*a literal 0 HcmV?d00001 diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/images/tomcat.gif b/rubbos/app/tomcat-connectors-1.2.32-src/docs/images/tomcat.gif new file mode 100644 index 0000000000000000000000000000000000000000..f2aa6f863e43e3924a35854c556a9c1b6d125cba GIT binary patch literal 2066 zcmb7-`9Bkk1AuqiW)t(qMA~Goi7YF;%8Fr3&3&wxJJ;MtNiUNrOkuHPUPq1)l@X~Z zSI&?*UMjqVP^8{^du89x`~45z=ZELF=kr+6ERBr4a{*@oT>yYYA{ndHhDb^Md=smN zQ?WW_7!m4O&3Da=BIf4iyng+9d;3eHNHiky*&2;#;p+kZBly1||1Wg^^}kO5RD#20 z`vn!Buc`O3*9z6WO@Gd3)SFXI{AetRNN|8>!?2NvYP|guFVQi7j|M{LmbEp@UwR`S zK-e07+VI0>itQD`FWXSiihOTqGW@#|)W`Q&k{Tiw8kU-1re^Pa<%S^$f{wMyh)iL^ zp&(BU=WJfi9Str7EX)^p6*AEtFwN4;ie?WexSkpB#?5bSY3{TT!oWB4K~QNgR6j`S z@j#cD71n!q6bvQ5&g4YtPx+liJJPvF51Cy^wQ4c( z$fbHW--q9)&#u-k#1*T6^NlK(>W|%YtOoz$iW+DNh)#N@Gq-FEg~f230$6j%@Ve=^ zn#XR94uy?DGa3p#L!%e}ULl-^=Td^@JEwcpYWzc^o~cU@Px~aNe8SY8)YH!qhE_ya z5D9GCZNONSLem%xV}7jbYp&hGEhco(^_r(3NNq;q3@JL6#VGBYyMB?lv+(Ae)LVjO z3K^|67-k7fI0f20B;qh2Du-F_N()VcX=l*s**a>KM+(`xN;s_asvYTo`{GW5m=o$9 zJ*>}@+Y*@Wz*EXI!g9dAu07q|0&>UR8xvd@osMUbXb& zn-5I~oefi`WhkJFQ-j#)BldF{7O@(WRf05EUY1ykQWg!xZBhWprv??wfe0P-_&k=9 zj=^a@mjW0(8sY@5;}SX=I#eIaN$kdfoF%!ko(Ggt_TuA^#>JXbhp6;Y(1%LxJ`t4{ zxdZ%!c^7Q+@#)}S!5hx7@x@Q=l3)W}C*c!EqD#_vn*;d!+Yl!aed8#MDHpGN?a3vr zoe>~9Z)U9{Ms0NICF*YOLT#L&KTPG3>O6-8jiG<+6ztvceF?J|$Z4)rU87sIzF#}g z`ORU8Q(Y&WX1z`hQl|GV$(vnrMFt{~fS*;s?@>SdX9vgX@D~!PbxRdQ>8%ayz~>+6 zQR<`8*hcuGF*m?R@zJ29P#+YeshDuWlU#8*#;LV8A%3uFwrKh8GEVUWxc$S zSjir`eS~hr?i9A~e%&IObwFzu7kTXGL=(p51(|%1inzV?Ve9(U^jB*i&(O$KH=YhN zGq4fau2S<0z50zh;NKKvzfpdsv}=dQe0;bA2*vIn_7}kB4kbdp4@| zbm9QXjy0&7nza3Edu0RNM9V`x3={PfhTr^&Kdv>fEbh#oM){s9CKynX8P0%od8+mg zxViNcHH5;ZrbJflBQWf+uVQ=iwPx%l!bcZ)W!&hI=V&DFe)M!hM{~PT?iO117d6%H zbW1(;00-l&a`>(hLLI`uL$H23sAW>}EG@}>T9z=cXr^aFy3At2Mt0v9pj&UqyfZJ- zG^4%5cw@BMaUEO8Rq~d1>P-M-W&pm~&na0+5smMob7_NuSxmv_KRuR^mNt1Ud#*m# z%^^fBVgxLiThV!Q&~CU2FnKfWTprda>I)|HXx+gXdYO(X);#F)qSl>T0k$%SEljyl zm?05YdwYfS{BVcx6VuOhB`5D@%bj98zoaFLL-E=T4=Gnq`N#C($uEQDj9p_Joxl~& zSSfPc7Y5jOGD1w zPX1PQ#KdzS(|tquOD5(vFGfoT1k(ujh(d!)&t1+D893W*Ct16Ngc{0+tGkV`Iuk4I z{E=Dv81f0Chp(_`?E`9eHJgj+2^(Mq%T9ZA!Mj)C{k~e>S;5pc8N6f5%=zyxF5a*1 z5jWV>1fPx?w-qO^p)-WaJQq#C`_T``ge2<&4av8|RhBB23U$;k1I^1wz$#U_+FZTN zD}xImjf$E3Tdn=4aE9q+Io2+OuxqcZjYhoL&fs(Qe=v!Bg~mX`jMK}=sYDv1`MSk@ z@$qKnG=8dI)QqO!+W^AV%1*5`$9rmlAs(j{hRvW;a`J8iJ^Xu$(t=Y}iGAd@^41hH z^Ou;<*(0<6^ix`_XtffJ(E%??UI#22%=xC=6>r?<&->hvbnpomksf}<FHYidn+`U2X=qZRq`VR#7O*Z%?iw2vkL literal 0 HcmV?d00001 diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/images/update.gif b/rubbos/app/tomcat-connectors-1.2.32-src/docs/images/update.gif new file mode 100644 index 0000000000000000000000000000000000000000..31e22abbc7a2e24b20b978e9be9bce91d4d97728 GIT binary patch literal 627 zcmZ?wbhEHb6k!lyIL5&6|NsAgK=A*+y}iAiot?eCt%HMuEs*J8ujLw+y7Ptq{{K!J zf7q}4X0-UF?)+zRlW&T4U*v2)!e6yXwRo0{SJEe-5&!>cxrG=mdLiwZn4h0tkeBaZ zXTN^^`uFeOe|Y!)!-o&&&!6AFfB%LJ8x|~BprD}e|KI zixKbaBa2L3t=6qucmCpq-3N9pT)$}Y+DUZ_>hmV#r_`iKsYvtb2q@R8MedK$FEQlQ z=a5vD+;`!~rt>?OoLxQp!m`Qd7Budkz+leWabaTVo#u#BStWN`r`%g8s3p4R;O>R% zmP}nYvu;6q?xf=E&O#{_89^-(t#bYP8*L_qrri462hSf`e_+E#pd0tCUvqFBkFL=A zvs*7*xUgy6+SLo^E6dAWI0y8^MUY>q3UnBN02CJt>^B-1nwl7!o0*u}x|&The Apache Tomcat Connector - Documentation Index
Apache TomcatApache Logo

Links

Reference Guide

Generic HowTo

Webserver HowTo

AJP Protocol Reference

Miscellaneous Documentation

News

The Apache Tomcat Connector

Documentation Index

Printer Friendly Version
print-friendly
version +
Introduction
+ +

This is the top-level entry point of the documentation bundle for the +Apache Tomcat Connectors + +

+

Select one of the links from the navigation menu (to the left) to drill +down to the more detailed documentation that is available. Each available +manual is described in more detail below.

+ +
Headlines
+
+ +
Reference Guide
+
+
    +
  • workers.properties +

    A Tomcat worker is a Tomcat instance that is waiting to execute servlets +on behalf of some web server. For example, we can have a web server such as Apache +forwarding servlet requests to a Tomcat process (the worker) running behind it. +

    +

    This page contains detailed description of all workers.properties +directives. +

    +
  • + +
  • uriworkermap.properties +

    +The forwarding of requests from the web server to tomcat gets configured by defining mapping rules. +The so-called uriworkermap file is a mechanism of defining those rules. +

    +
  • + +
  • Status Worker +

    +The status worker is a builtin management worker. It displays state information +and can also be used to dynamically reconfigure JK. +

    +
  • + +
  • Apache +

    This page contains detailed description of all directives related to +Apache web server. +

    +
  • + +
  • IIS +

    This page contains detailed description of all IIS directives. +

    +
  • + +
+
Generic HowTo
+
+
    + +
  • Quick Start +

    This page describes the configuration files used by JK on the +Web Server side for the 'impatients'. +

    +
  • +
  • All about workers +

    This page contains an overview about the various aspects of defining +and using workers. +

    +
  • +
  • Timeouts +

    This page describes the possible timeout settings you can use. +

    +
  • +
  • Load Balancing +

    This page contains an introduction on load balancing with JK. +

    +
  • +
  • Reverse Proxy +

    This page contains an introduction to reverse proxies, how JK +handles this situation and how you can influence the JK proxying behaviour. +

    +
  • + +
+
Webserver HowTo
+
+

These pages contain detailed descriptions of how to build and +install JK for the various web servers. +

+ +
AJP Protocol Reference
+
+
    +
  • AJPv13 +

    This page describes the Apache JServ Protocol version 1.3 (hereafter +ajp13). +

    +
  • +
  • AJPv13 Extension Proposal +

    This page describes an extension proposal for ajp13. +

    +
  • +
+ +
Miscellaneous documentation
+
+ + +
News
+
+

Release news from various years. +

+ + +

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/changelog.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/changelog.html new file mode 100644 index 00000000..bbf266fb --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/changelog.html @@ -0,0 +1,2096 @@ +The Apache Tomcat Connector - Miscellaneous Documentation - Changelog
Apache TomcatApache Logo

Links

Reference Guide

Generic HowTo

Webserver HowTo

AJP Protocol Reference

Miscellaneous Documentation

News

The Apache Tomcat Connector - Miscellaneous Documentation

Changelog

Printer Friendly Version
print-friendly
version +
Preface
+

+ This is the Changelog for Tomcat Connectors. This changelog + does not contain all updates and fixes to the Tomcat connectors (yet). + It should contain fixes made only after November 10th 2004, when the + new documentation project for JK was started. +

+
Changes between 1.2.31 and 1.2.32
+
+
Native
+ + + + + + + + + + + + + + +
fix + 51417: Fix worker busy detection by querying the + worker endpoint. Abandoned connections can leave a worker + in busy state without decrementing busy counter. (mturk) +
fix + 50339: Fix whitespace trimming when parsing attribute + lists. (rjung) +
fix + 41263: Support Servlet API getRemotePort(). + Works for Tomcat 5.5.28, 6.0.20 and 7.0.0 and Apache and ISAPI + plugins. (rjung) +
fix + 41923: AJP: Close AJP connection to Tomcat on client write + error when recovery_options 4 is specified, aborting the response + write on the Tomcat side. (timw) +
update + AJP: Cap the lingering bytes that will be read + when shutting down an AJP socket at 32k to prevent CPU spikes + in the web server when a client aborts on a large response body. + Also reduce total linger time to 2s. (timw) +
fix + 50839: AJP: Fix 30sec CPU spike due to incorrect counting + of lingering bytes causing a busy loop when a client aborts + connection during a response write. + Fixes regression in 1.2.31. (timw) +
add + LB: Forward worker activation state as request attribute + "JK_LB_ACTIVATION". Possible values are "ACT" (active), + "DIS" (disabled) and "STP" (stopped). (rjung) +
fix + HTTPD: Forward WWW-Authenticate from backend when status is 401 + and server generated error pages are used. (rjung) +
fix + 50363: IIS: Prevent chunk encoding of empty message + bodies for 204, 205 and 304 responses. (timw) +
fix + 50975: IIS: Fix hanging of Transfer-Encoding: chunked + requests when Content-Length header is present in request as well. + Also addresses situation where IIS appears to create a Content-Length + header for a small chunk encoded request when none was present in the + original request. (timw) +
fix + 47679: IIS: stop truncation of request headers when + ISAPI redirector used as an extension without the corresponding + filter installed. (timw) +
fix + NSAPI: Use lower case header names for responses. + Otherwise the web server might add chunked transfer encoding header + in addition to our content length header. +
update + Docs: Improve load balancer documentation. (rjung) +
+
+
Changes between 1.2.30 and 1.2.31
+
+
Native
+ + + + + + + + + + + + + + +
fix + 49413: AJP13: Drop flush packets send by the backend + after the response has been finished. (rjung) +
update + AJP: Log the local and remote socket address. (mturk) +
update + Watchdog: Move the maintain workers outside the critical + section allowing other threads to use the connection + pool during maintenance. (mturk) +
update + Common: Add svn revision to init log message. (rjung) +
fix + Common: Don't destroy errno during trace logging. (rjung) +
update + Apache: Add support for Apache 2.3/2.4. (rjung) +
update + Apache: Added version number resource for mod_jk.so on Windows. (timw) +
update + 48501: IIS: Added rotatelogs style log rotation to ISAPI + Redirector. (timw) +
fix + 38895: IIS: Use RAW headers instead of CGI headers by default + to prevent conversion of underscores '_' to hyphens '-' in header names. + Old behaviour can be enabled by defining USE_CGI_HEADERS. (timw) +
fix + 49511: IIS: Do not override IIS log information when subsequent + requests on a keep-alive connection are not mapped into the ISAPI Redirector. (timw) +
fix + Docs: Document SSLOptions needed for SSL information forwarding. (rjung) +
update + Docs: Grammar and style improvements and clarification about serving + static content by IIS. + Patch provided by André Warnier. (rjung) +
fix + Docs: Update subversion paths used in docs. (rjung) +
+
+
Changes between 1.2.28 and 1.2.30
+
+
Native
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
update + Apache: Improve compatibility with Apache 2.3. (rjung) +
fix + 46632: Apache: Do not register child cleanup for + our pools. (mturk) +
fix + 46893: Apache: Log warning only if JkShmSize was actually + set in the configuration. (mturk) +
update + IIS: Include optional chunking support. Off by default. (mturk) +
fix + 48763: IIS: Do not send Content-Length when using chunked encoding + or length larger 4GB. (mturk) +
fix + 48223: IIS: Propagate correct backend error code to IIS. (rjung) +
fix + 47867: IIS: crash during startup, when compiled with VS2008 + and workers.properties contains unsupported properties. + Patch provided by Indrek Juhani (rjung) +
fix + 47628: IIS: Fix deadlock when restarting the Application Pool + caused by not releasing the critical section lock. + Patch provided by Bret Prucha. (mturk) +
fix + IIS/NSAPI: Correct log file flushing after each line. (mturk) +
add + NSAPI: Add Microsoft Visual C++ Makefile. (mturk) +
update + AJP: Improve socket shutdown handling. (mturk) +
update + AJP: Ensure we never reuse a non reusable socket. (mturk) +
update + AJP: Tolerate a single excess packet when waiting for cpong. (mturk) +
update + AJP: Check protocol correctness more strictly. (mturk) +
update + 48410: AJP: Use poll instead select so we can work with more + then 1024 sockets. (mturk) +
fix + 46503: AJP/Status: Garbage data in worker domain and route. (mturk) +
fix + 48276: AJP: When worker contact cannot be resolved mark the + worker as disabled instead failing to start the server. (mturk) +
fix + 48169: AJP: Improve CGI interoperability by closing all + sockets during EXEC. (mturk) +
add + Status: Add number of open backend connections to status worker. + This feature is experimental, the displayed value might not be + accurate. (mturk) +
update + 47224: Status: When address gets changed invalidate + all opened sockets in the endpoint cache. This will cause new + backend connections to get opened using new address. (mturk) +
fix + 48305: Status: Do not show "secret" property when + doing dump. (mturk) +
fix + 45610: Status: Don't accept requests with + empty value for sub worker parameter. (rjung) +
fix + 45610: Status: Fix erroneous unsetting of + sticky_session and sticky_session_force when updating other + load balancer attributes via the status worker. (rjung) +
fix + 47222: Status: Add ping_timeout to the shared memory + and allow dynamic configuration. (mturk) +
fix + Status: Remove duplicate "errors" line in property view of + AJP13 workers that are part of a load balancer. (rjung) +
fix + LB: Fix route logging. (rjung) +
update + Logging: Automatically detect size of thread id for logging. (rjung) +
update + Logging: Add optional log file locking for Windows when defining + JK_LOG_LOCKING. (mturk) +
update + Configuration: Update example configuration. (rjung) +
update + Docs: Update information about tools needed to create a release. (rjung) +
fix + 47983: Docs: Fix typo in example config + which breaks startup. (rjung) +
update + Build: Force copy of automake files. (rjung) +
update + Build: Tomcat code repository structure cleanup reflected in documentation + and build script. (rjung, mturk) +
+
+
Changes between 1.2.27 and 1.2.28
+
+
Native
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
add + Apache: Add more environment variables to overwrite request + information. Useful in case a proxy is in front of Apache and sends + us original request information e.g. via custom headers. (rjung) +
update + Apache: No longer preallocate entries for JK request log. (rjung) +
fix + 46352: Apache: Fix crash when using SetHandler jakarta-servlet + in VHost without any JkMount. Crash due to incorrect initialization + of mount extensions. (rjung) +
fix + Apache: JkWatchdogInterval had wrong interval calculation + causing a 10 times higher watchdog interval then configured. (mturk) +
fix + Apache: Activate forwarding of SSL key size by default. (rjung) +
fix + 46169: Apache 1.3: Backport use_server_errors mount extension. (rjung) +
fix + 46763: Apache 2.0: Survive the log mutex during graceful + restart. Patch provided by Eiji Takahashi. (mturk) +
fix + 46416: Apache 2.0 on Windows: Include mstcipip.h even if + the apr doesn't include it. (mturk) +
update + IIS: Update uriworkermap.properties file on + a regular interval. This requires both worker_mount_reload + and watchdog_interval to be defined. (mturk) +
update + IIS: Remove obsolete entries from registry file. (mturk) +
fix + 46579: IIS: Use local environment table instead environment + variables for setting the JKISAPI_PATH and JKISAPI_NAME. (mturk) +
update + LB: Add new property error_escalation_time to fine tune + escalation of local errors to global errors. (rjung) +
update + LB: If the sticky session affinity mark contains a dot, treat the + part before the dot as the domain name. This allows to have full node + session affinity with domain failover. (mturk) +
fix + LB: make forced recovery work with local error states. (rjung) +
fix + LB: Only update error state and error time, if we actually have a new state. (rjung) +
fix + LB: Set global worker state to error when we reach max_reply_timeouts, + or fail_on_status triggered hard error. (rjung) +
update + AJP: Add a new error type JK_AJP_PROTOCOL_ERROR. (mturk) +
update + AJP: Allow worker ports lower or equal to 1024. (rjung) +
update + AJP: Improve some AJP error log messages. (mturk) +
update + Status: Allow changing worker address and port of AJP workers. + The address is resolved on next request for that worker. (mturk) +
update + Status: Allow update actions to show error messages in the result page. (rjung) +
update + Status: Refactor update actions. (rjung) +
update + Status: Do not redirect to the show or list page, if an error occured + during an action. (rjung) +
update + Status: Include error time in display. (rjung) +
update + Status: Remove redundant port information from worker display. + Rename address column and remove its explanation from the legend. (rjung) +
update + Status: Optimize forced uriworkermap.properties reload. (mturk) +
fix + Status: Fix crash in text display. (rjung) +
fix + Status: Show - Edit - Show always ends in single lb member show, + even when started from all members lb show. (rjung) +
fix + Status: Wildcards in sub worker names were broken for update actions. (rjung) +
fix + Status: Add use_server_errors to map display. (rjung) +
update + SHM: Move locking into the data pull and push methods. (rjung) +
update + JNI: Deprecate JNI workers. (rjung) +
fix + Netware: Missing define for MAX_PATH. Patch by Guenter Knauf. (rjung) +
update + Docs: Add a new HowTo page about reverse proxies. (rjung) +
update + Docs: Add an explanation of local error states to the timeouts documentation. (rjung) +
update + Docs: Clarify relation between socket_timeout and socket_connect_timeout. (rjung) +
update + Docs: Clarify IIS URL rewrite feature. (rjung) +
fix + 46834,46734: Docs: Fix a couple of missing or broken links. (markt,rjung) +
fix + Docs: Add 2008 news to main page and menues. (mturk, rjung) +
+
+
Changes between 1.2.26 and 1.2.27
+
+
Native
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
fix + 46109: Decay reply_timeouts even when lb method is + busyness. Also reset reply_timeouts during forced recovery. (rjung) +
update + AJP13: Recycle connection if previous request didn't complete. (mturk) +
update + Maintain should not run multiple times in parallel. (mturk) +
fix + Apache: Fix small memory leak during restart. (mturk) +
update + Improve signal handling during socket shutdown. (mturk) +
add + URI Map: Add debug dump function for uri worker map. (rjung) +
update + Add revision number to version info for non-release builds. (rjung) +
add + IIS: Optionally allow chunked encoding for responses. + At the moment only usable, if build with ISAPI_ALLOW_CHUNKING + defined. Based on patch by Tim Whittington. (rjung) +
update + IIS: Optionally use raw headers instead of CGI + headers. Fixes problem "underscore=dash" problem in + header names. At the moment only available, if build with USE_RAW_HEADERS + defined. (rjung) +
update + IIS: Optionally improve IIS 5.1 compatibility. + At the moment only available, if build with AUTOMATIC_AUTH_NOTIFICATION + defined. Based on patch by Tim Whittington. (rjung) +
fix + IIS: Fix memory corruption due to parallel initialization + by multiple threads. (rjung) +
update + Windows: Use non-default socket keepalive interval. (mturk) +
add + IIS: Add environment variables JKISAPI_PATH and JKISAPI_NAME. (mturk) +
add + Added socket_connect_timeout directive for setting the + connect timeout for the socket. This enables to have low + connection timeout but higher operational timeouts. (mturk) +
fix + AJP13: + [CVE-2008-5519] + Always send initial POST packet even if the client + disconnected after sending request but before providing + POST data. In that case or in case the client broke the + connection in a middle of read send an zero size packet + informing container about broken client connection. (mturk) +
add + AJP13: Added connection_acquire_timeout directive for setting the + absolute timeout the worker will wait for a free endpoint. (mturk) +
update + Apache: Allow to set path parameter used when doing JkStripSession. (mturk) +
update + Refactor retries implementation and change semantics of retries attributes. (mturk) +
update + Status: Allow showing only a single member for a load balancer. (rjung) +
update + Status: Add display of seconds since last statistics reset and access and + transfer rates. (rjung) +
add + AJP13: Add a configurable retry_interval time. (rjung) +
update + Documentation: Enhance description of connection_pool_size. (rjung) +
update + IIS: Refactor error page generation. (mturk) +
fix + IIS: SERVER_NAME variable can be the same for + multiple different server instances if requests + are handled according to the ip:port combination. + Use INSTANCE_ID variable to which the request + belongs instead. (mturk) +
add + Allow forwarding server error pages. This can be done + on per-uri basis using new use_server_errors extension. + (mturk) +
add + Added session_cookie and session_path for configuring + default session identifiers. (mturk) +
update + Use max_packet_size also as TCP send and receive buffer size. (mturk) +
update + Apache: Do not allow Apache to start in multi-threaded mode if mod_jk + was only build for single threaded server (prefork). (mturk) +
fix + 45812: Add done() service method that + causes sending EOS bucket for Apache httpd 2.x. + This allows filter chain to work properly. (mturk) +
add + Added connection_ping_interval, ping_timeout and ping_mode directives. + (mturk) +
fix + Apache: Use correct ld flags provided by apxs when building module. + Prevents some crashes on AIX for httpd 1.3 module. (rjung) +
fix + Documentation: "val" attribute numbering in status worker + needs to start with 0 instead of 1. (rjung) +
update + Documentation: Remove JNI parameters from sample configuration + in the workers generic howto. (rjung) +
fix + 45026: For Apache httpd 2.x add "Unknown Reason" + as the reason phrase, if we get an empty one from the backend. + Otherwise httpd 2.x returns status 500. (rjung) +
fix + Build: Fix Cygwin build. (rjung) +
update + Documentation: Add info to docs, that variables sent via JkEnvVar + are not listed in request.getAttributeNames(). (rjung) +
add + Add watchdog background thread for Apache 2.x and IIS + doing internal maintenance (idle connection checks, backend probing). + See JkWatchdogInternal (Apache) and watchdog_interval (IIS). (mturk) +
update + Change log level of some messages from error to info. (mturk) +
fix + Documentation: Fix docs for worker attribute "secret". (rjung) +
update + Detect correct plugin name for various web servers via additional + preprocessor defines. (rjung) +
fix + LB: Do not put loadbalancer node in error state if there is opened + channel. This fixes the bug when new connection fails due to + busyness, causing opened connections fail stickyness. + This brings back per-node busy counter and private state array + for each request. We can mark the state as error for failover to + work while still operating and reporting node as OK if there are + opened working connections. (mturk) +
fix + 44738: Fix merging of JkOption ForwardURI* between virtual hosts. + Patch contributed by Toshihiro Sasajima. (rjung) +
add + URI Map: Add extension attributes to uri worker map. + Allowed are reply_timeout, active/disabled/stopped + and fail_on_status. + Usage currently only implemented for httpd and IIS. (rjung+mturk) +
fix + URI Map: Make dynamic reloading atomic and free memory + not needed any longer. (rjung) +
add + Configure: Don't use post httpd 2.2.0 API functions when building + with new --enable-api-compatibility configure switch. (rjung) +
fix + Apache: JkAutoAlias does not work in combination with JkMountCopy + if there are no JkMount in virtual host. (rjung) +
update + LB: Optimize state macros to improve performance. (rjung) +
add + Apache: Allow dynamic setting of reply timeout using the environment + variable JK_REPLY_TIMEOUT. (rjung) +
add + Status: Add manageability for ajp parameters of ajp + workers and ajp lb members. (rjung) +
update + Status: Change parameter names of update action to + make them more easily distinguishable from other parameters. (rjung) +
add + Status: Add ajp worker statistics also for + workers, that are not lb members. (rjung) +
update + AJP: Refactor factories, move ajp13/ajp14 common parts into + ajp_factory. (rjung) +
update + Status: Only sync shm worker config values of the workers + for which we changed values. (rjung) +
fix + Status: Set lb_factor instead of distance. (rjung) +
update + Status: Minor layout changes, use drop down instead of multiple + text links. (rjung) +
update + SHM: Use local copies of read mostly attributes of lb sub workers + in lb and status worker. (rjung) +
update + Status: Add "dump" action to dump our initial configuration. (rjung) +
update + Status: Use property table to decide which cmd action uses which + output elements. (rjung) +
update + Common: Include original configuration map in worker_env + to make it available for workers, e.g. the status worker. (rjung) +
update + LB: Refactor "route" return for httpd note. Don't use a + member of the worker_record, because that's not thread safe. (rjung) +
update + Common: Refactor "retries", remove from service and jk_worker, + move into ajp worker instead. (rjung) +
update + SHM: Use distinct structs for lb and ajp13 in shm. + Improves type safety and saves a few bytes. (rjung) +
update + SHM: Remove unused attributes. (rjung) +
update + SHM: Automatically determine shm size for all web servers. (rjung) +
update + SHM: Make open/attach logging consistent for all web servers. (rjung) +
update + Status: Include server local time in output. (rjung) +
fix + 44116: Fix handling of multiple JSESSIONID cookies. (rjung) +
fix + 37850: Use thread safe localtime_r where appropriate. (rjung) +
fix + Use thread safe strtok_r on more platforms, especially AIX. (rjung) +
update + Status: Improve XSS hardening. (rjung) +
update + 35303: Move initialization of service members with defaults from + web server specific code to our generic jk_init_ws_service() function. (rjung) +
fix + 36385: Add missing prepost CPing/CPong directly after connect + in case prepost CPing is used, but no connect CPing. (rjung) +
update + 37322: Apache: Enhance robustness of message formating + in jk_error_exit(). (rjung) +
fix + 44147: Multiple load balancing workers problem. (rjung) +
+
+
Changes between 1.2.25 and 1.2.26
+
+
Native
+ + + + + + + + + + + + + + + + + + + + + + + + + + +
fix + 42003: Allocate memory instead using fixed size from + the stack. (mturk) +
fix + 43229: Load balancer does not do fail over after + reply timeouts. (rjung) +
fix + JKStatus: Repair detailed Apache httpd version display. + This was broken for httpd version 2.2.4+. (rjung) +
update + LB/AJP: Refactoring of jk_connect.c, jk_ajp_common.c, + jk_lb_worker.c (rjung) +
fix + Configure: Repair broken apxs auto-detection. (rjung) +
update + Configure: Remove trace logging from compiled code + via new --disable-trace configure switch. (rjung) +
update + Common: Maintain idle connections in decreasing (LRU) + slot order. (rjung) +
update + Apache: Create JK_WORKER_ROUTE and JK_REQUEST_DURATION notes for + access log even if no JkRequestLogFormat is set. (rjung) +
update + JKStatus: Enhance URI to worker map listing for Apache httpd. + We now list maps for all virtual servers and not only + the one, in which JKStatus itself was called. (rjung) +
update + JKStatus: Enhance URI to worker map listing. + Update stale uriworkermap.properties immediately. (rjung) +
fix + 43873: Fix small memory leak occuring during httpd restart. (rjung) +
update + Common: Allow '*' for the worker name in exclusion rules (resp. JkUnMount) + which will override all workers. (rjung) +
fix + 42038: Correct overlay of mounts and unmounts for IIS. (rjung) +
fix + 43684: Replace JkMountFile by JkMountFileReload in + uriworkermap.properties docs. (rjung) +
update + Apache: Add new value "All" for JkMountCopy. (rjung) +
fix + 43516: Memory leak for Apache httpd module + of size 8KB for every virtual host without JK directive + after each restart. (rjung) +
update + Apache: Cleanup init and destroy of server configuration. (rjung) +
update + Apache: Remove global configuration items from per server + configuration. (rjung) +
update + Apache: Remove unused attributes secret_key and + automount/JkAutoMount. (rjung) +
update + Cleanup of jk_uri_worker_map. (rjung) +
update + Documentation: Small additions to JkShmFile documentation. + Contributed by Gerhardus Geldenhuis. (rjung) +
fix + AJP13: Ignore flush packets before we received the response headers. (rjung) +
fix + Fix crash during startup when using worker configuration inheritance + (attribute "reference") and log level debug. (rjung) +
fix + AJP13: Match header names exactly against pre defined constants. Avoid + possible confusion with custom header names using a standard header name + as a prefix. (rjung) +
fix + jkstatus: Fix correct parameter validation at JkStatusUpdateTask and + JkStatusUpdateLoadbalancerTask ant tasks. Reported by Christian Mittendorf. (pero) +
+
+
Changes between 1.2.24 and 1.2.25
+
+
Native
+ + + + + + + + + + + + + + + + + +
update + IIS: Fix shm shutdown behaviour. (rjung) +
update + General: fail_on_status used in a load balancer can optionally + do fail over without putting the failed worker in error state. (rjung) +
update + NSAPI: Improve build description for Unix. (rjung) +
update + NSAPI: Add initialization startup message containing JK version. (rjung) +
fix + General: Declare static functions as static. (jim) +
update + Documentation: Clarify fail_on_status behaviour. (rjung) +
fix + General: Do fail_on_status before returning the response headers. (rjung) +
update + NSAPI: Fix shm shutdown behaviour. (rjung) +
update + NSAPI: Set return status even if request ended with an error. (rjung) +
update + NSAPI: Allow using without shm_file on WIN32 and Netware. (rjung) +
fix + NSAPI: Fix Crash of nsapi for log level debug and unset refect_unsafe. (rjung) +
update + NSAPI: Improve Solaris and Linux Makefiles for nsapi build. (rjung) +
fix + Build: Improve pid_t type detection during configure on Solaris. (rjung) +
update + Build: Experimental build support for gcc on WIN32 and Netware. (fuankg) +
update + Build: Makefile optimizations for Apache httpd 1.3/Netware . (fuankg) +
fix + General: Fix missing flush bug introduced in 1.2.24. (rjung) +
+
+
Changes between 1.2.23 and 1.2.24
+
+
Native
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
update + Documentation: Improved workers.properties description in the + reference guide. (rjung) +
update + Documentation: Add a HowTo about the various timeouts. rjung) +
update + Logging: add milliseconds to the default timestamp format, + if we have gettimeofday(). (rjung) +
update + Apache: add milliseconds (%Q) and microseconds (%q) as possible + JkLogStampFormat conversion specifiers. This does not use strftime(), + but needs gettimeofday(). (rjung) +
update + IIS & Sun: Log service failures also, if return code is negative. (rjung) +
fix + 42849: Abort startup of Apache httpd 1.3 in case + mod_jk initialization failed. We already do the same + for Apache httpd 2.x. (rjung) +
fix + 42849: Refuse to operate with IIS in case the + initialization failed. Instead requesting isapi_redirect.dll + 500 will be returned to the user. This is as closest as it + can get to Apache Httpd where we refuse to start the server + in case of fatal initialization errors. (mturk) +
fix + Load Balancer: Fix a deadlock in lb worker, which was exposed on Solaris + for threaded Apache MPMs. (rjung) +
update + Logging: handle LWP IDs as 32 Bit unsigned. Try to make + it work, although pthread IDs are opaque. (rjung) +
update + JkStatus: Added manipulation of max_reply_timeouts. (rjung) +
update + LB, Status: Add feature max_reply_timeouts, to make lb tolerant against + occasional long running requests. (rjung) +
update + JkStatus: Added OK/IDLE as the successor of N/A. (rjung) +
update + Status worker: Renamed runtime states. All states have a major + state (OK or ERR) and a substate. Changed the name N/A to OK/IDLE. + Added docs about the meaning of the states to the status worker + page in the reference guide. + No new states have been added to code. (rjung) +
update + Common: Add recovery options for recovering idempotent http methods + HEAD and GET. (rjung) +
fix + Correct documentation for worker attributes retries and + recovery_options. (rjung) +
fix + Make writing log lines and line endings more atomic. (rjung) +
update + Common: Refactored and unified jk_map_read_prop* and jk_map_load_prop* + for all use cases. (rjung) +
update + Common/Apache/IIS/Netscape: Add an option to check decoded URLs for + potentially malicious constructions. (rjung) +
update + IIS: Document auth_complete and uri_select. (rjung) +
update + Apache/IIS/Netscape: Change the default forwarding encoding to the new + proxy method. (jfclere, rjung) +
update + Common: Optionally reencode URIs before forwarding to the backend. + Based on the URI reencoding done bei httpd mod_proxy. (jfclere, rjung) +
update + Common: auto-detect correct print format for pid_t. + This fixes at least compiler warnings on Solaris. (rjung) +
fix + 42608: Handle Content-length as unsigned 64Bit + to allow for huge up- and downloads. (rjung) +
update + Apache: Add forwarding uri to debug log. (rjung) +
update + Docs: Clarify relation between worker names and jvmRoute for load balancing. (rjung) +
fix + Use initial zero timeout for jk_is_socket_connected. The resulting + detection is the same but offers a huge performance increase + with mod_jk. In most cases the Operating System does not favor + the 1 microsecond timeout, but it rather rounds that up to much + higher value (frequency of interrupt timer which on most systems + defaults to 100Hz). + Patch provided by David McLaughlin. (mturk) +
update + NSAPI: Check correct log file and shm file configuration during startup. (rjung) +
fix + NSAPI: Add support for the general options concerning retries, flushing + and connection persistance. (rjung) +
fix + NSAPI: fix crashes due to use of mount attribute in workers.properties. + Changed initialization order. (rjung) +
fix + Improved handling of libtool and discrepancies between CC env variable and + CC used during apache build by configure script. (rjung) +
fix + Always build with thread support, unless flag --enable-prefork + is set during for configure. (rjung) +
update + Use snprintf/vsnprintf from ap_snprintf.c for platforms other + than Windows, which might lack snprintf/vsnprintf implementations + when NOT build for Apache httpd 2.x/APR (e.g. Sub Web Server) + or without using configure. (fuankg) +
update + Imported ap_snprintf() from Apache 1.3. (fuankg) +
fix + Fix incorrect log object cleanup during statup, + leading to crashes at least on iSeries. (rjung) +
update + Add jk_stat() and jk_file_exists() as wrapper functions. + i5/OS V5R4 expects filename in ASCII for fopen but requires them + in EBCDIC for stat(). (hgomez) +
update + i5/OS (AS/400) V5R4 port where Apache 2.0 modules should now use UTF8. (hgomez) +
update + Docs: Add comments on i5/OS build for V5R4 and previous releases. (hgomez) +
+
+
Changes between 1.2.22 and 1.2.23
+
+
Native
+ + +
update + [CVE-2007-0450] + and + [CVE-2007-1860]: + Change the default value of JkOptions to ForwardURICompatUnparsed. + The old default value was ForwardURICompat. + This should make URL interpretation between Apache httpd and + Tomcat consistent (prevent double decoding problems). (rjung) +
+
+
Changes between 1.2.21 and 1.2.22
+
+
Native
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
fix + Refactor line endings logging to make it correct for all + platforms and webservers. (mturk) +
update + Added command line windows make files. (mturk) +
update + Allow fail_on_status directive to be multi line. (mturk) +
fix + 42076: Fix name of new option from ForwardCertChain to + ForwardSSLCertChain as documented. (rjung) +
fix + Docs: Fix a couple of typos, change format of a few tables, + fix links to news pages. (rjung) +
fix + Fix correct URL for TC 6 examples in new IIS rewrite.properties + configuration example file. (rjung) +
fix + Add svn properties to several files. (rjung) +
update + Add TC 6 examples to uriworkermap.properties in config examples. (rjung) +
update + Allow multiple status codes for fail_on_status directive. + The status codes can be delimited by space or comma characters. (mturk) +
update + IIS. Added pcre like regular expressions for url rewrite rules. (mturk) +
fix + 41922: Apache 1.3. Enable JkEnvVar. (mturk) +
update + Apache. Add --enable-flock configure parameter for explicit + compilation of faster flock() system calls for OS supporting + those calls. By default the fcntl system call for locking will + be used that is a little bit slower but it can work on NFS + mounted volumes as well. (mturk) +
fix + 41562: Add Debug logging for read from client in ISAPI Redirector. + Contributed by Tim Whittington. (mturk) +
update + Apache. Add ForwardSSLCertChain JkOption. + Contributed by Patrik Schnellmann. (mturk) +
fix + IIS. Do not forbid access to web-inf or meta-inf if there is + no mapped worker. This allows to have resource with those names + that are outside mapped contexts. (mturk) +
update + Apache. Use process id for creating shared memory name and delete shared + memory and shared memory lock files on exit. (mturk) +
fix + IIS. Fix Keep-Alive regression introduced in 1.2.21. (mturk) +
update + Delete unused check for empty init_map during startup. (rjung) +
fix + 41770: Fix startup error if no JkWorkersFile is used. (rjung) +
update + Use JK_TRUE/JK_FALSE instead of OK/!OK as return values in init_jk(). (rjung) +
update + Minor adjustments to apache startup log messages (when to use STDERR, remove + deprecated NOERRNO flag, shm warning and warnings for usage of default files). (rjung) +
update + Replace APR precompiler directive by httpd mpm_query to detect MPM threading. + Add a debug log message about auto-detected pool size. (rjung) +
fix + Make MMN check easier to understand and a little more precise + (for new ap_get_server_banner()/ap_get_server_description()). + We use the new API only for Apache httpd 2.3. This way our binaries are not + tightly coupled to a minor 2.0 version, and we don't use ap_get_server_banner() + any way. (rjung) +
fix + Use the full description string ap_get_server_description() instead of + the truncated info from ap_get_server_banner(), because this info gets used internally + (status worker display and ajp14 backend communication) and is not send back to the + normal user. (rjung) +
fix + 41757: Document the "--enable-prefork" flag of configure. (rjung) +
update + Enhance log messages for failures when parsing attribute maps. (rjung) +
fix + Correct log message during worker initialization, in case remote host could not be + resolved. We logged the default host name "localhost" instead of the configured one. (rjung) +
fix + 41770: Fix the second part of the bug: local_worker and local_worker_only + is missing from the list of deprecated attributes (and not supported either), so prevents + the web server from startup. (rjung) +
+
+
Changes between 1.2.20 and 1.2.21
+
+
Native
+ + + + + + + + + + + + + + + + + + + + + + + + + + +
fix + [CVE-2007-0774]: + A denial of service and critical remote code execution vulnerability. + Caused by buffer overflow in map_uri_to_worker() when URL were longer that 4095 bytes. + Reported by ZDI (www.zerodayintiative.com). + Please note this issue only affected versions 1.2.19 and 1.2.20 of the + Apache Tomcat JK Web Server Connector and not previous versions. + Tomcat 5.5.20 and Tomcat 4.1.34 + included a vulnerable version in their source packages. + Other versions of Tomcat were not affected. +
add + Check the worker. parameters and don't start if the parameter is not a valid one. (jfclere) +
add + 41439: Allow session IDs to get stripped off URLs of static + content in Apache by adding JkStripSession + directive (configurable per vhost). (mturk) +
add + Change semantics of empty defaults for JkEnvVar variables. + Until 1.2.19: not allowed. In 1.2.20: send variables as empty strings, if + neither set to non empty in config, nor during runtime. + Starting with 1.2.21: If config has no second argument only send + variable if set (even when set to empty string) during runtime. + Allows good combination with condition attribute in tomcat access log. (rjung) +
fix + 41610: Fix incorrect detection of missing Content-Length + header leading to duplicate headers. Contributed by Boris Maras. (rjung) +
fix + Better build support for SunONE (Netscape/iPlanet) webservers. (jim) +
add + Add warning if duplicate map keys are read and are not allowed, + e.g. when parsing uriworkermap.properties. (rjung) +
fix + Don't concat worker names, if uriworkermap.properties has a duplicate + pattern, instead overwrite the worker. (rjung) +
fix + Log deprecation message even in duplication case. (rjung) +
fix + uriworkermap.properties: Fix off-by-one problem when deleting + URL mapping during reloading of uriworkermap.properties. (rjung) +
add + 41439: Allow session IDs to get stripped off URLs of static + content in IIS (configurable). (rjung) +
add + 41333: Refactoring isapi_plugin configuration reading. (rjung) +
add + 41332: Add some more errno logging and unify the format. (rjung) +
add + JkStatus: Improved logging by adding status worker name to messages. + Added messages to the recover worker action. (rjung) +
add + JkStatus: Refactoring searching for workers and sub workers. (rjung) +
add + 41318: Add configuration to make status worker user + name checks case insensitive. (rjung) +
add + JkStatus: Add estimated time until next global maintenance to other + mime types and adopt jkstatus ant task. (rjung) +
add + JkStatus: Show estimated time until next global maintenance. + Change displayed time until next recovery to a min/max pair. (rjung) +
add + JkStatus: Allow a user of a read/write status worker to switch it + to and from read_only mode temporarily. (rjung) +
fix + JkStatus: Do not show read/write commands in a read_only status worker. (rjung) +
add + JkStatus: Allow lb sub workers in error state to be marked for recovery + administratively from the status worker. (rjung) +
add + Load Balancer: Do not try to recover multiple times in parallel. + Use additional runtime states "PROBE" and "FORCED". (rjung) +
fix + JkStatus: Improve data synchronization between different processes. (rjung) +
fix + 41381: Fix segfault in feature fail_on_status + (wrong order of log arguments). Patch by Juri Haberland. (rjung) +
fix + Use correct windows line endings for log file on WIN32 platform. (rjung) +
+
+
Changes between 1.2.19 and 1.2.20
+
+
Native
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
add + JkStatus Ant Task documentation page. (pero/rjung) +
add + JkStatus Ant Tasks: Add new tasks for update and reset. (pero) +
update + JkStatus Ant Tasks: Update for new xml status format. (pero) +
update + Allow integer and string values when setting enumeration/boolean + attributes via status worker update action. (rjung) +
add + Docs: New reference guide page for status worker. (rjung) +
update + Docs: Renaming the config dir to reference and using the title + Reference Guide in the docs. (rjung) +
update + Added retry_on_status for workers directive. (mturk) +
update + Status Worker: Add directive to make property prefix + and good/bad rule configurable. (rjung) +
update + Status Worker: Omit lb members when att=nosw. (rjung) +
update + Status Worker: New command cmd=version for a short version output. (rjung) +
update + Status Worker: New output stype mime=prop produces property lists. (rjung) +
fix + Apache: Fix incorrect handling of JkEnvVar when Vars are set multiple times. (rjung) +
update + Renamed jvm_route to route. Deprecated jvm_route, but still use it as fallback + when parsing the worker configuration. (rjung) +
update + IIS: Make uriworkermap file reload check interval configurable. (mturk) +
update + Apache: Make uriworkermap file reload check interval configurable. (rjung) +
update + Status Worker: Add directives for customizing the XML + output (ns, xmlns, doctype). (mturk) +
add + Docs: New page with description of uriworkermap. (rjung) +
update + Docs: Added short description of max_packet_size to worker + reference. (rjung) +
update + Status Worker: All functions accessible also for xml and txt + mime types (list, show, update, reset). (rjung) +
update + Status Worker: New global health indicators for load balancers + named bad (error, recovering or stopped), degraded (busy or disabled) + and good (the rest, active and OK or N/A). (rjung) +
update + Status Worker: New edit page, to change one attribute for all + members of a load balancer. (rjung) +
update + Status Worker: Standard logging for status worker. (rjung) +
update + Status Worker: code refactoring. (rjung) +
update + Status Worker: New attribute user (list) denies access, if + the request user in the sense of remote_user is not in this list. + Empty list = no deny (rjung) +
update + Status Worker: New attribute read_only disables the parts + of the status worker, that change states and configurations. (rjung) +
fix + 36121: Don't change main uri when mod_jk serves + included uri. (markt) +
update + Apache VHosts: Merge JkOptions +base - -base + +vhost - -vhost. (rjung) +
update + Apache Docs: Adding requirements, context information, default values and + inheritance rules to the Apache config documentation. (rjung) +
update + Status Worker: Add source type to status worker, remove the redundant "context" + column in the map listing (context=uri). (rjung) +
update + uriworkermap: On reload of the file, all old entries from the previous file + version get deleted, before the new ones are being read. (rjung) +
fix + Keep normal maps and exclusion maps internally separate. Don't treat them + as the same when adding a rule. (rjung) +
update + Status Worker: Display mapping rules also for non-lb workers and in global view. (rjung) +
update + Apache VHosts: Use the vhost log files instead of the main log. (rjung) +
update + Apache VHosts: Allow individual timestamp formats by refactoring the formatting + method. (rjung) +
update + Apache VHosts: Adding all missing config items to the virtual host level. + Don't overwrite the settings from the global server, but inherit them + in case they are not set in the virtual host. (rjung) +
update + Apache: remove unnecessary function names from log messages. (rjung) +
update + Apache: add a default log file location and a message, if the default gets used. (rjung) +
update + Apache: add missing JK_IS_DEBUG_LEVEL() (rjung) +
update + Apache VHosts: Allow JkWorkersFile, JKWorkerProperty, JkShmFile and JkShmFileSize + only in global virtual server. (rjung) +
update + Add some more jk_close_socket() and reduce log level for some info messages. (rjung) +
update + Load Balancer: Added the Sessions strategy. Contributed by Takayuki Kaneko. (rjung) +
update + Docs: Minor enhancements and syncing with more recent versions. (rjung) +
fix + 40997: Separate uri mappings from their '!' + counterpart when checking for duplicates in uriworkermap + reloading. (rjung) +
fix + 40877: Make sure the shared memory is reset on + attach for multiple web server child processes. (mturk) +
update + IIS: Added shm_size property to be able to deal with over 64 + workers configurations. (mturk) +
update + IIS: Increase default thread count to 250, so its the same as Apache Httpd + default configuration. (mturk) +
fix + 40966: Fix socket descriptor checks on windows. (mturk) +
fix + 40965: Initialize missing service parameters. (mturk) +
fix + 40938: Fix releasing of rewrite map. + Thanks to Chris Adams for spotting that. (mturk) +
update + Apache: Added +FlushHeader JkOptions. (mturk) +
update + Added explicit flush when AJP body packet size is zero. (mturk) +
fix + 40856: Fixing case sensitivity bug in URL mapping. (rjung) +
fix + 40793: Documentation: Improvements to Apache HowTo provided by + Paul Charles Leddy. (markt) +
fix + 40774: Fixing wrong recursion termination. This one restricted the + "reference" feature unintentionally to 20 workers. (rjung) +
fix + 40716: Adding "reference" feature to IIS and Netscape. (rjung) +
fix + Documentation: Corrected SetEnvIf syntax in JK_WORKER_NAME example. (rjung) +
fix + Documentation: Added forgotten STATE and ACTIVATION notes for load balancer logging in Apache. (rjung) +
update + Apache: Use instdso.sh instead libtool: libtool does not work on HP-UX for example. (jfclere) +
+
+
Changes between 1.2.18 and 1.2.19
+
+
Native
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
update + Docs: Add SetHandler and new env var to Apache config docs. (rjung) +
update + Apache 1.3: Backport "no-jk" feature. (rjung) +
update + Apache: Add an environment variable to make SetHandler "jakarta-servlet" more + useful. The variable is JK_WORKER_NAME, but can be changed by the + new directive JkWorkerIndicator. (rjung) +
fix + LB: Don't use single worker shortcut, if the single worker is being diabled. (rjung) +
fix + Status worker: Add short explanation of activation and error states to legend. (rjung) +
fix + Docs: Add meaning of zero timeout values for various timeouts + in workers.properties. (rjung) +
fix + LB: Cleanup of Mladens forced recovery. (rjung) +
fix + LB: Do not change lb_value for recovering workers to max, if + we are using BUSYNESS method. (rjung) +
fix + Apache: Since 1.2.14 mod_jk failed to detect client abort. (rjung) +
fix + Docs: Corrected description of JkEnvVar. (rjung) +
fix + Solaris: Detect filio.h in configure to make the new connection detection + build on solaris (r432825). (rjung) +
update + Add feature to force the recovery of workers that are + member of loadbalancer if all the members are in error + state. This fixes the time gap where 503 was returned + caused by recovery_timeout although the backend was + ready to handle the requests. (mturk) +
update + Docs: Seperate deprecated directives in their own table. (rjung) +
update + Docs: Allow "-" and "_" in worker names. (rjung) +
update + Allow multiple lines with attributes "balance_workers" and "mount". (rjung) +
fix + Make jk_is_some_property match more precisely. (rjung) +
update + JkStatus: Make refresh interval changeable. (rjung) +
fix + JkStatus: Adjust display of recover time wrt. global maintenance. (rjung) +
update + LB: Resetting worker state from OK to NA, if worker has been idle + too long. (rjung) +
fix + Avoid compiler warnings concerning the use of lb_*_type arrays. + Use functions instead. (rjung) +
update + Added %R JkRequestLogFormat option for Apache 1 and Apache 2. (mturk) +
update + Allow changing jvm Route from status manager. (mturk) +
fix + Do not retun 400 if Tomcat fails in the midle of the post + request. Return 500 insted. (mturk) +
update + LB: Combine ok/error/recovering/busy runtime states into a single scalar. (rjung) +
update + LB: Combine active/disabled/stopped configuration states into a single scalar. (rjung) +
update + LB: Add several Apache notes to enable standard logging for load balancer results. (rjung) +
update + LB: Reorganisation of the main load balancer service loop. (rjung) +
update + Implement hierarchical worker configuration via attribute "reference". (rjung) +
update + Log deprecated properties. (rjung) +
fix + IIS: Fix simple_rewrite for the cases where the + rewritten url is larger then the original one. (mturk) +
update + New JkOption "DisableReuse" to disable connection persistence. (jim) +
update + LB: Move sessionid retrieval out of get_most_suitable_worker into service. (rjung) +
update + Code cleanup for all service methods (use TRACE, JK_LOG_NULL_PARAMS, null pointer checks). (rjung) +
update + JKSTATUS: add refresh link. No refresh for updates. Redirect to list view after update. (rjung) +
update + Add new hook add_log_items into servers. (rjung) +
update + APACHE httpd: Rename apache logging notes. (rjung) +
update + LB: Rename lock and method constants. Add constants for defaults. (rjung) +
fix + Default log level should be INFO and not DEBUG. + Default log level should be the same for all server types. (rjung) +
fix + Make rewrite_rule_map and log_level as non mandatory + directives for isapi_redirect. (mturk) +
fix + 40107: Rewrite is_socket_connected function. + Non blocking socket is not used any more. (mturk) +
update + Allow building with VS2005 without too many warnings. (mturk) +
fix + Decide by MMN, which piped log API we should use. + mod_jk 1.2.18 broke compilation with Apache 1.3 pre 1.3.28. (rjung) +
+
+
Changes between 1.2.17 and 1.2.18
+
+
Native
+ + + +
fix + Using socklen_t in getsockopt. Also introducing jk_sock_t. (mturk) +
update + Allow recovery wait time below 60 seconds (new minimum is 1 second). (mturk) +
+
+
Changes between 1.2.16 and JK 1.2.17
+
+
Native
+ + + +
fix + Fix hanging jk status worker when certain attributes are being updated + due to double locking. (rjung) +
update + Allow JkMount to behave like uriworkermap.properties + by parsing pipe symbol as two directive marker. (mturk) +
+
+
Changes between 1.2.15 and JK 1.2.16
+
+
Native
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
update + Added simple rewrite capability for IIS. Although simple it + will fulfill most needs. (mturk) +
update + Added RECOVER_ABORT_IF_CLIENTERROR recovery_option that closes + the connection if client connection is broken during the request. (mturk) +
update + Renamed cache_timeout directive to connection_pool_timeout. (mturk) +
update + Added connection_pool_minsize directive. (mturk) +
update + Deprecate recycle_timeout directive. (mturk) +
update + Corrected some HTML syntax bugs in output of status worker. (rjung) +
update + Added the refresh=n parameter to the status worker. It will update the display every n seconds. (rjung) +
update + Balancer: Add attribute distance to balanced workers to express preferences between workers. (rjung) +
update + Balancer: Add attribute jvm_route to balanced workers to be able to use the same target in different balancers. (rjung) +
update + Status: Add lb_mult to status. (rjung) +
update + Balancer: Make different balancing strategies work in a similar way (use lb_value, use decay during global maintenance, use integer factors for weights. (rjung) +
update + Balancer: Improve locking. (rjung) +
update + Balancer: Workers start slower after recovering. (rjung) +
update + Balancer: Make different balancing strategies work in a similar way (use lb_value, use decay during global maintenance, use integer factors lb_mult for weights). (rjung) +
update + Balancer: Move recovery check to global maintenance. (rjung) +
update + Balancer: Add global maintenance method, that is called in only one process. (rjung) +
update + Extend our use of autoconf to find a 32Bit and a 64Bit unsigned type and their printf formats. (rjung) +
update + Logging: piped loggers for JkLogFile and Apache 1.3. (rjung) +
update + Logging: Add PID to log lines for each log level apart from REQUEST. (rjung) +
update + Logging: flush buffered logs to keep lines in correct order. Output final newline together with log message. (rjung) +
update + Reducing shm size. (rjung) +
update + Only log removing of old worker, when we actually do it. (rjung) +
fix + 37469: Fix shared memory close for forked childs. + The shared memory will be closed by the parent process. (mturk) +
fix + 37332: Fix potential misuse of buffer length with + snprintf functions. (mturk) +
fix + 38859: + [CVE-2006-7197] + Protect mod_jk against buggy or malicious + AJP servers in the backend. Patch provided by Ruediger Pluem. (mturk) +
fix + 38889: Use worker map sorting depending on the path + elements, to comply with Servlet spec. Patch provided by + Steve Revilak. (mturk) +
update + 36138: Added Busyness lb method. Patch provided + by Chris Lamprecht. (mturk) +
fix + Fix pessimistic locking mode. The patch correctly handles the + burst load, by syncing the access to the shared memory data. (mturk) +
fix + 38806: Reclycle worker even if it is disabled. + This fixes hot-standby workers in error state. (mturk) +
fix + 37167: Allow building with BSD-ish like make. (mturk) +
fix + ISAPI plugin (isapi_redirect.dll) did not provide correct request data + for IIS + to include in the IIS log. (markt) +
+
+
Changes between 1.2.14 and 1.2.15
+
+
Native
+ + + +
fix + Fix AJP13 Cookie2 parsing. Cookie2 was always send as Cookie. + Patch provided by Andre Gebers. (mturk) +
fix + 35862: NSAPI plugin attempts to read freed memory and attempts to + dereference a null pointer. Patch provided by Brian Kavanagh. (markt) +
+
+
Changes between 1.2.13 and 1.2.14
+
+
Native
+ + + + + + + +
fix + Fix lb for worker mpm's with cachesize set to lower number then + ThreadsPerChild is. If retries is set to value larger then 3 sleep for + 100 ms on each attempt. This enables to tune the connection cache, + and serialize incoming connections instead returning busy if connection + count is larger then cachesize. (mturk) +
fix + 36525: Solaris core dump. (mturk) +
fix + 36102: Worker actions do not persist. (mturk) +
fix + 35864: Status worker doesn't list workers. + Patch provided by Martin Goldhahn. (mturk) +
fix + 35809: JkMountCopy don't work for Apache 2.0 Patch provided by + Christophe Dubach. (mturk) +
fix + 35298: Multiple JK/ISAPI redirectors on a single IIS site are not supported + Patch provided by Tim Whittington. (mturk) +
+
+
Changes between 1.2.12 and 1.2.13
+
+
Native
+ + + + + + + + + + +
fix + 34397: Emergency was handled as Error. (jfclere) +
fix + 34474: // in URL were not handled correctly with Apache-1.3. (jfclere) +
fix + Use 64 bits int for transferred/read bytes. +
update + Added JkOptions +FlushPackets used to optimize memory + usage when sending large data. (mturk) +
update + Added lock directive for load balancer that allows more acurate + load balancing in case of burst load. (mturk) +
update + Added worker.maintain directive to allow customizing default 10 + second timeout. On busy servers this value needs to be set on + higher value. (mturk) +
fix + Fix for NetWare compiler to deal with different types between AP13 + and AP2 SDKs. (fuankg) +
update + Emit much more legible user.dmp crash analysis output for WIN32. (wrowe) +
fix + 34558: Fix first failover request. (mturk) +
+
+
Changes between 1.2.11 and 1.2.12
+
+
Native
+ + + + +
update + Added ForwardLocallAddres JkOptions flag for passing local instead remote + address. Useful for remote addr valve. (mturk) +
fixFix that worker not used, when stopped flag is true. (pero) +
update + Add loadbalance default worker secret attribute to the documentation (pero) +
+
+
Changes between 1.2.10 and 1.2.11
+
+
Native
+ + + + + + + + + + + + + + + + +
fixBackport SC_M_JK_STORED from JK2 for passing arbitrary + methods instead failing the request. (mturk) +
fixAdded missing SEARCH and ACL http methods. (mturk) +
update + Add worker secret attribute to the documentation (pero) +
update + Add a stopped flag to worker configuration. Set flag True and + complete traffic to worker is stopped. + Also update the Ant JkStatusUpdateTask at Tomcat 5.5.10 release. + Only usefull in a replicated session cluster.(pero) +
updateAdded worker maintain function that will maintain all + the workers instead just the current one. This enables to recycle + the connections on all workers. (mturk) +
updateUse shutdown when recycling connections instead hard + breaking the socket. (mturk) +
updateAdd unique directives checking. The directives if + unique are now overwritten instead concatenated. (mturk) +
updateAllow multiple worker.list directives. (mturk) +
fix + 34577: For IIS log original request instead loging + the request for ISAPI extension. (mturk) +
fix + 34558: Make sure the returned status codes are the same + for ajp and lb workers. (mturk) +
fix + 34423: Use APR_USE_FLOCK_SERIALIZE for setting log lock + on platforms like FreeBSD. Patch provided by Allan Saddi. (mturk) +
fix + 33843: Fix obtaining LDFLAGS that were used for building + Apache HTTPD. Patch provided by Beat Kneubuehl. (mturk) +
fix + 34358: Enable load balancer method configuration. (glenn) +
fix + 34357: In some situations Apache 2 mod_jk could segfault + when the JkAutoAlias directive is used. (glenn) +
update + Add --enable-prefork to the documentation (pero) +
+
+
Changes between 1.2.9 and 1.2.10
+
+
Native
+ + + + + + + + + + + + + + + + +
updateSet default shared memory to 64K instead 1M. (mturk) +
fixDo not mark the worker in error state if headers are + larger then AJP13 limit. (mturk) +
update + On Series you should use the latest PTF for Apache 2.0 + (which is now 2.0.52) and ad minima SI17402/SI17061 or cumulative + including them. (hgomez) +
update + Change the xml status format to xml attribute syntax (pero) +
fix + 33248: Fix builds where apxs defines multiple + directories for APR includes. (mturk) +
fix + 32696: Return 404 instead 403 when WEB-INF is requested + to comply with Servlet spec. (mturk) +
updateAdded ANT task for managing jkstatus. (pero) +
update + If socket_timeout is set, check if socket is alive before + sending any request to Tomcat. (mturk) +
update + Added JkMountFile for Apache web servers. This file can contain + uri mappings in the form (/url=worker), and is checked for + updates at regular 60 second interval. (mturk) +
update + Added status worker for managing worker runtime data using + web page. (mturk) +
update + Added load balancer method directive that is used for setting + the algorithm used for balancing workers. Method can be either + Request (default) or Traffic. (mturk) +
update + Added shared memory to allow dynamic configuration. Shared memory + is needed only for unix platform and web servers having multiple + child processes. For Apache web server two new directives has been + added (JkShmFile and JkShmSize). (mturk) +
update + Added textupdate mode to status worker to handle remote updates + from ant tasks.(pero) +
fix + 33562: Fix Reply_timeout when recovery_options + is larger than 1. Patch provided by Takashi Satou. (mturk) +
fix + 33308: Fix segfaults when ForwardDirectories is enabled + with Apache 1.3 +
+
+
Changes between 1.2.7 and 1.2.8
+
+
Native
+ + + + + + + + + + + + + + + +
update + Allow anyone to debug and diagnose stack dumps using windbg or any + other debugging tool, and (if they add the .pdb files to their + installation) to make sense of dr watson logs. + Patch provided by William A. Rowe (wrowe) +
fix + Fix in_addr_t usage by using the real struct ignoring typedef. + Patch provided by William A. Rowe (wrowe) +
fix + Fix url rewriting by restoring the in place uri from which the + jsessionid was removed. (mturk) +
update + Make load balancer algorithm thread safe by introducing mutex + to the load balancer worker. (mturk) +
fix + Fix sending error pages for IIS to client by adding Content-Type header + using correct api function call. (mturk) +
fix + 32696: Prevent IIS from crushing when web-inf url was requested. (mturk) +
update + Use default cachesize for servers that support discovering the number of + threads per child process. (mturk). +
fix + Fix Apache content-length header parsing using case insensitive compare. (billbarker) +
fix + Fix parsing AJP headers using case insensitive compare. (mturk) +
fix + Use infinite socket timeout if socket_timeout is set to zero or less then zero. (mturk) +
update + Change balanced_workers to balance_workers but keep + backward compatibility preserving the old directive. (mturk). +
fix + Fix ajp initialization for workers with cache_size set to zero. (mturk) +
update + 32317: Making mod_jk replication aware (Clustering Support). + Patch provided by Rainer Jung. (mturk). +
fix + 31132: Core dump when JkLogFile is missing from conf. (mturk) +
+
+
Changes between 1.2.6 and 1.2.7
+
+
Native
+ + + + + + + + + + + +
update + Added new property named recover_time that can be used to change the + default 60 second recover time. (mturk) +
update + Added custom retries for worker, so we don't depend on default setting. + If set to a number grater then 3, it will sleep for 100ms on retry greater + then 3 and then try again. (mturk) +
update + Added JkWorkerProperty directive that enables omiting workers.properties file. + For example: JkWorkerProperty worker.ajp13a.port=8009. (mturk) +
fix + Check all JSESSIONID cookies for a valid jvmRoute. If you have multiple Tomcats + with overlapping domains, then you can get multiple cookies without a defined order. + This will route correctly as long as the different domains don't have any + Tomcats in common. (billbarker) +
update + Added JkUnMount directive for negative mappings that works as opposite to JkMount directives. + It is used for blocking of particular URL or content type. (mturk) +
update + Added wildchar match uri mappings. One can now use JkMount to + map /app/*/servlet/* or /app?/*/*.jsp. (mturk) +
update + Rewrite the logging by adding Trace options. (mturk) +
update + Added socket_timeout property that sets the timeout + for the socket itself. (mturk) +
fix + Changed socket_timeout property to recycle_timeout. This better + explains what the directive actually does. (mturk) +
fix + Changed the load balancer algorithm. + The idea behind this new scheduler is the following: + lbfactor is how much we expect this worker to work, + or the worker's work quota. + lbstatus is how urgent this worker has to work to fulfill its quota + of work. We distribute each worker's work quota to the worker, and then look + which of them needs to work most urgently (biggest lbstatus). This + worker is then selected for work, and its lbstatus reduced by the + total work quota we distributed to all workers. Thus the sum of all + lbstatus does not change.(*) + If some workers are disabled, the others will + still be scheduled correctly. (mturk) +
+
+
JK 2
+

JK2 has been put in maintainer mode and no further development will take place. +The reason for shutting down JK2 development was the lack of developers interest. +Other reason was lack of users interest in adopting JK2, caused by configuration +complexity when compared to JK. +

+

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/doccontrib.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/doccontrib.html new file mode 100644 index 00000000..06a25b5b --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/doccontrib.html @@ -0,0 +1,249 @@ +The Apache Tomcat Connector - Miscellaneous Documentation - How to Contribute to the Documentation
Apache TomcatApache Logo

Links

Reference Guide

Generic HowTo

Webserver HowTo

AJP Protocol Reference

Miscellaneous Documentation

News

The Apache Tomcat Connector - Miscellaneous Documentation

How to Contribute to the Documentation

Printer Friendly Version
print-friendly
version +
Introduction
+

+ This document describes how you can easily contribute to the +documentation. I'm going to try to make it easy for everyone to help out with +the documentation of Tomcat, more specifically the documentation for the +connectors. This is written from a windows user perspective as I believe they +will most benefit from it. For people using Unix it should be easy for them to +apply these steps. Just substitute Unix syntax where needed. +

+

+ The documentation is produced using xml with xsl style sheets. This +effectivly seperates the content of the documents from the style, so all that +contributers need to worry about the content. It is much easier to use than +html. +

+

+ It's all really quite simple. Here is what you will need: +

    +
  • +A recent version of Ant +
  • +
  • +The source code for the connectors from subversion +
  • +
  • +Any ascii text editor +
  • +
+

+
Getting Started Step by Step
+

+ After you get these tools they are simple to set up. +

+
STEP 1. Get Ant
+

+ Install Ant. The only advice I +have is to choose a simple installation path. Now set an environment variable +for ANT_HOME, and then add the location of the Ant/bin directory to your PATH +variable. Consult your Operating system documentation for information on how +to do this. When you are finished verify that you can run ant from the command +line. +

+

+ Ant is used to build the documentation, among other things, and it must be +able to see a file called build.xml. This file is located in the +xdocs directory. In the +build.xml file there is a target named all that will be used to build +the docs. +

+
+
STEP 2. Get the sources
+

+ Get the sources for +tomcat-connectors +from the subversion repository. If you'll +be editing from a windows platform you will need a windows subversion client. There +are several available. I like turtoiseSVN. +Unix users should install the subversion client of their choice, +if they don't already have one. +

+

+ You are ready to download the sources now. Change directory to the +location where you want your repository to be. For simplicity we will call this +your SVN_HOME. Mine is located in C:\build. +

+

+ Run the following command to checkout the sources for the first time. +You should only need to do this once. +


C:\build\>svn checkout http://svn.apache.org/repos/asf/tomcat/jk/trunk/ +tomcat-connectors

+

+

+ You should now be watching all the downloads come in. Now that you have +the sources on your machine the hard part is over. From now on, to update your +sources all you have to do is cd into any directory in your repository and run +the svn update command. +

To update your xdocs directory simply cd into the xdocs directory +and:
C:\build\tomcat-connectors\>cd xdocs
C:\build\tomcat-connectors\xdocs\>svn update

+

+
+
STEP 3. Test your build environment
+

+ Open a command prompt window and cd to the directory where you downloaded +the source. Now cd into the xdocs directory so that Ant can see the +build.xml file. Then from a command prompt, run the following: +


C:\build\tomcat-connectors>cd xdocs
C:\build\tomcat-connectors\xdocs>ant all

+

. +

+ You should see the ant compiler messages scrolling by rapidly and then stop +with the following: +

[style] Transforming into C:\build\tomcat-connectors\build\docs\news\printer>
[style] Processing C:\build\tomcat-connectors\xdocs\news\20041100.xml +to
C:\build\tomcat-connectors\build\docs\news/20041100.html
[style] Loading stylesheet C:\build\tomcat-connectors\xdocs\style.xsl
[style] Processing C:\build\tomcat-connectors\xdocs\news\20050101.xml +to
C:\build\tomcat-connectors\build\docs\news/20050101.html
[style] Processing C:\build\tomcat-connectors\xdocs\news\20060101.xml +to
C:\build\tomcat-connectors\build\docs\news/20060101.html
[style] Transforming into C:\build\tomcat-connectors\build\docs>
[style] Processing C:\build\tomcat-connectors\xdocs\index.xml +to
C:\build\tomcat-connectors\build\docs\index.html
[style] Loading stylesheet C:\build\tomcat-connectors\xdocs\style.xsl

BUILD SUCCESSFUL
Total time: 10 seconds
C:\build\tomcat-connectors>

+

+

+ All the xml files present in the xdocs directory structure were transformed +to html and copied to the SVN_HOME\tomcat-connectors\build\docs +directory. Open one of the +html files in your browser and see how it looks. +

+
+
STEP 4. The editing process.
+

+ I find it easier to use two windows while doing my updates. One I call my +build window. I keep this one in the SVN_HOME\tomcat-connectors\xdocs +directory and I only run two commands in this window: +


First I run
ant clean
Then I run
ant all

+

+

+ My second window I call my edit window and I keep that one in the +SVN_HOME\tomcat-connectors\xdocs directory where I'm doing my +edits, diffs and svn updates. +

+

+ Before you start editing you should always update your local repository to +prevent conflicts. +

You only need to update the xdocs directory
C:\build\tomcat-connectors>cd xdocs
C:\build\tomcat-connectors\xdocs>
C:\build\tomcat-connectors\xdocs>svn update

+

+

+ Now that your repository is up to date you can begin editing. Find +something in the documentation to edit. When you find something remember the +name of the file. In your edit window find and edit the xml source file +with the same name. After you are done return to the build window, and +in the SVN_HOME\tomcat-connectors\xdocs directory run: +


C:\build\tomcat-connectors\xdocs> ant clean

+

+

+ This will delete all the previous html files and make the area ready for +updated material. Now to make fresh documents that incorporate your changes +run: +


C:\build\tomcat-connectors\xdocs>ant all

+

+

+ Use your browser to view the edits you just made, they will be in the +SVN_HOME\tomcat-connectors\build\docs sub-tree. If it looks +good and is ready to go, +all that is left to do is to create a patch and submit it. +

+
+
STEP 5. Creating a patch and submitting it.
+

+ From your edit window cd into the directory that contains the xml +file you are working on, and run the svn update command. For example, +to produce a diff of the index.xml file and call it patch.txt, you +would cd into the directory containing the index.xml file and: +

C:\build\tomcat-connectors\xdocs\>svn diff index.xml > +patch.txt.

+

+

+ Now that you have your patch you are ready to send it in. +

+

+ Patches to the documentation are handled just like a bug report. You +should submit your patches to http://issues.apache.org/bugzilla/ + and include a good one line subject. If this is your first time to use the +bug database then you should read http://issues.apach +e.org/bugzilla/bugwritinghelp.html. You will need to create a user +account. At the web site paste your patch into the web form and don't forget +to describe what it is your patch is for. Sooner or later a someone with +commit privileges will review your suggestion. +

+
+
Subversion Basics
+

+ After you have checked out the sources the first time it is much easier to +use subversion. You can cd into any directory of the repository and run svn +update to get the latest sources for that directory. For editing +purposes you should always update your repository before you start editing to +reduce conflicts. +

+

+ You will need to run svn diff to generate patches for submission. +Again cd into the directory containing the file you are editing and run svn +diff name_of_the_file_you_edited > patch.txt to generate a patch for +submission. +

+

+ Pay attention to the terminal window during the update. +

+

+ Lines begining with a A indicate files that have been added. +

+

+ Lines begining with a D indicate files that have been deleted. +

+

+ Lines begining with a U mean the local copy was patched to update it +to the current version in the master repository. +

+

+ Lines begining with a G mean your local copy is different from the +master copy, and the changes were successfully merged into your copy. +

+

+ Lines begining with a C mean there was a conflict in merging the +changes and you need to review the file and merge the changes manually. Search +for >>>> and merge the changes. +

+

+ Lines begining with a ? indicate files that reside on your local +system which are not part of the repository. You will normally see this when +you are creating new files for submission. +

+
Updating Web site
+

+ Only Committers are able to update the web site (http://tomcat.apache.org/connectors-doc/). + To do it: +

    +
  • Connect to people.apache.org.
  • +
  • umask 002
  • +
  • Copy the changed files to /www/tomcat.apache.org/connectors-doc/.
  • +
  • or use ant from a checkout tomcat/jk/trunk/xdocs repository:
    + ant -Dbuild.dir=/www/tomcat.apache.org -Ddist.name=connectors-doc +
  • +
  • The changes need around 4 hours to be synced to tomcat.apache.org.
  • +
+

+
Guides and Resources
+

+ A little help to get you started if you need it +

+ +

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/faq.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/faq.html new file mode 100644 index 00000000..92bdfb2c --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/faq.html @@ -0,0 +1,281 @@ +The Apache Tomcat Connector - Miscellaneous Documentation - FAQ
Apache TomcatApache Logo

Links

Reference Guide

Generic HowTo

Webserver HowTo

AJP Protocol Reference

Miscellaneous Documentation

News

The Apache Tomcat Connector - Miscellaneous Documentation

FAQ

Printer Friendly Version
print-friendly
version +
General
+

+General Informations and FAQ about JK +

+
Where can I get help/support for JK ?
+

+The primary mechanism for support is through the JK +documentation included in the doc directory. +Documentation is also available on the Apache Tomcat web site devoted to the + +Apache Tomcat Connectors Project +For additional help, the best resource is the Tomcat Users Discussion list. +You should start by searching + +the mail list archive +before you post questions to the list. +If you are unable to locate the answer to your question in the archive, +you can post questions about JK to the user list for assistance. +Make sure that you include the version of your Webserver, +that you are using as well as the platform you are running on +and go + +here +to determine how to subscribe to tomcat mailing list. +

+
+ +
I can't find JK anywhere. Where is it?
+

+Now that JK moved to the tomcat-connectors repository, +the source and the binaries for JK can be downloaded from a mirror at the + +Tomcat Connectors (mod_jk, mod_jk2) Downloads page. +

+
+ +
What's the difference between JK and mod_jk ?
+
+

+JK is a project covering web-servers to Tomcat connectors, +whereas mod_jk is the Apache module developed in JK. +

+ +

+IIS webserversupport is implemented on JK, using a redirector +called isapi redirector. +

+ +

+Netscape/SunONE/Sun webserverwebserver support is implemented on JK, using a redirector +called nsapi redirector. +

+ +
+ +
Where can I get more information ?
+

+For JK 1.2.x, you should read : +

+ + + +

+For more detailed information, have a look at the Reference Guide. +You could also try searching the mailing list archives for "JK" or look at the source. +

+
+ +
Which protocol should I use? Ajp12 or Ajp13?
+

+Ajp13 is a newer protocol, it's faster, and it works better with SSL. +You almost certainly want to use it now that ajp12 is deprecated. +

+

+Also ajp13 is supported by all Apache Tomcat including 3.2.x , 3.3.x, 4.0.x, 4.1.x, 5.0.x, 5.5.x +and the new tomcat 6. +

+ +

+Others Servlet engines like jetty have support for Ajp13. +

+
+ +
I've got a firewall between my web server and Tomcat which drops ajp13 connections after some time
+

+Ajp13 uses persistant connections where the traffic could be null if there is no request to be sent to Tomcat. +Firewalls use to drop inactive connections and will make your web server and Tomcat think the connection is valid. +

+

+Starting with JK 1.2.0, a socket_keepalive property as been added to ajp13 settings, and you should take a look at +it in Workers HowTo and +workers.properties reference. +If nothing else helps, you can try JkOptions +DisableReuse, but this will have strong performance implications. +

+
+ +
Under heavy load, I've got many threads in Tomcat even if my Apache Web Server handles much of the load
+

+Under heavy load, Apache Web Server creates many children to handle the load, +which will in turn create many connections +to Tomcat to forward the requests they should handle. +Apache Web Server will normally kill the children/threads when the load decreases. +But if the load is still there and even if only Apache handles the requests, +ie static contents, the children are kept and with them all the ajp13 connections, +even if they are no more used. +

+

+To close connections after some time of inactivity you can use connection_pool_timeout, +for more informations refer to workers.properties reference. +

+
+ +
Apache
+

+Informations and FAQ about mod_jk and Apache Web Servers. +

+
Whenever I restart Tomcat, Apache locks up!
+

+The Ajp13 protocol keeps an open socket between Tomcat and Apache. +Release of mod_jk present in J-T-C handles the network failure. +But with very ancient releases of mod_jk, you may have to restart Apache as well. +

+
+ +
Why do there exist two files mod_jk.so (-eapi ad -noeapi) in download directories for Apache 1.3?
+

+Many versions of Apache use a modified API, known at Extended API, developed for use with the +mod_ssl module. Starting with Apache 2.0 there is no more difference. +

+ +

+For example, Apache 1.3 present in certains recent Linux distributions include the +mod_ssl module. +

+ +

+So if you got such 'Extended Apache', you need to use mod_jk.so-eapi. +

+ +

+You should use mod_jk.so-noeapi only for 'Standard Apache' (ie without mod_ssl). +

+ +

+It's wise to avoid using EAPI modules on STD API Apache or to use standard API modules on EAPI Apache. +Allways be sure to have the mod_jk.so witch match your version of Apache +

+
+ +
What's that message about 'garbled DSO ?'
+

+It's related to Apache EAPI, the message 'mod_jk.so is garbled - perhaps this is not an Apache module DSO ?' +just told you, that your're trying to install a mod_jk.so DSO module that was compiled on an Apache using EAPI, +like apache-mod_ssl or apache from Redhat distro 6.2/7.0 but your system use the standard apache with normal API. +

+
+ +
And the message about 'module might crash under EAPI!
+

+Also related to EAPI, the message '[warn] Loaded DSO /usr/lib/apache/mod_jk.so uses plain Apache 1.3 API, +this module might crash under EAPI! (please recompile it with -DEAPI)', the mod_jk.so was compiled under normal +Apache with standard API and you try to install the module on an Apache using EAPI. +

+
+ +
APXS is getting an error during the build of mod_jk, like rc=0 or rc=255. I tried all of the steps in the build section, what do I do now ?
+

+APXS is a Perl script that is created when you build the Apache web server from source. +Chances are that if you are getting these errors and you obtained Apache as a binary distribution, +that APXS is not configured correctly for your system. +Your best bet is to get the Apache source from http://httpd.apache.org and build it yourself. +Use the following for a basic build (read the Apache docs for other options): +

[user@host] ~ $ cd /usr/local/src
[user@host] ~ $ gzip -dc apache_1.3.19.tar.gz|tar xvf -
[user@host] ~ $ cd apache_1.3.19
[user@host] ~ $ ./configure --prefix=/usr/local/apache \
[user@host] ~ $ --enable-module=most \
[user@host] ~ $ --enable-shared=max
[user@host] ~ $ make
[user@host] ~ $ make install

+

+

+Note: The above steps assume that you downloaded the Apache source and placed it in your /usr/local/src directory. +

+
+ +
Apache 2.0 complains about incorrect module version
+

+Since Apache 2.0 API still change often, the Apache 2.0 teams decide to put in headers of compiled modules the +Apache 2.0 version used to compile the module. This check is called Magic Module Number bump. +

+

+At start time Apache 2.0 check that version in modules headers and stop if it detect that a module was compiled +for another Apache 2.0 version. As such you should allways use modules compiled for the same Apache 2.0 version. +This check may be removed if the future. +

+
+ +
Does it work for Apache 2.2?
+

+mod_jk works well with Apache 2.2. You need a binary module compiled for version 2.2 of the Apache web server. +A binary compiled for version 2.0 will not work. +

+

+Important parts of the functionality of mod_jk have been reimplemented as Apache httpd modules mod_proxy_ajp +and mod_proxy_balancer. These are part of the standard distributoin of Apache 2.2. The new modules do not contain +all features of mod_jk, but you get them automatically with every Apache 2.2. +

+
+ +
JNI doesn't work with Apache 1.3
+

JNI workers have been deprecated. They will likely not work. Do not use them.

+

+JNI support requires a multi-threaded environment which is not the general case for Apache 1.3. +You should verify if Apache 1.3 has been build with thread support and if not you could add the +the pthreads library to your httpd.conf file. +

+ +
+  # Add pthread to Apache in httpd.conf
+  LoadModule "/usr/lib/libpthreads.so"
+
+ +

+Also keep in mind that JNI is suited for multi-threaded servers and you should consider upgrading +to Apache 2.x to support JNI. +

+
+ +
JNI report that JVM couldn't be started under Linux
+

JNI workers have been deprecated. They will likely not work. Do not use them.

+

+Under Linux, you should set some environment variables BEFORE launching your Apache server : +

+ +

export LD_LIBRARY_PATH=$jre/bin:$jre/bin/classic:$LD_LIBRARY_PATH

+ +

+Also some Linux distributions have enabled a GLIBC feature called 'floating stacks' which may not works with kernel +less than 2.4.10 on SMP machines. You should disable floating stacks by exporting an environment variable : +

+ +

export LD_ASSUME_KERNEL=2.2.5

+ +

+You could have to update your service scripts, ie /etc/rc.d/init.d/httpd, to set these env vars +before your httpd server starts. +

+
+ +
Mixed errors when building via configure
+

+configure assume you have some GNU tools already installed and configured for your system, and ad minima libtool. +

+

+Also some systems may have mixed cc and gcc setup which may make you puzzled when trying to link an Apache built with native +c compiler with a jk/jk2 build with gcc. +

+

+In case the make processing doesn't work as expected, you should use a GNU make gmake. +

+
+ +

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/jkstatustasks.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/jkstatustasks.html new file mode 100644 index 00000000..f610c968 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/jkstatustasks.html @@ -0,0 +1,184 @@ +The Apache Tomcat Connector - Miscellaneous Documentation - Status Worker Ant Tasks
Apache TomcatApache Logo

Links

Reference Guide

Generic HowTo

Webserver HowTo

AJP Protocol Reference

Miscellaneous Documentation

News

The Apache Tomcat Connector - Miscellaneous Documentation

Status Worker Ant Tasks

Printer Friendly Version
print-friendly
version +
Introduction
+

Since version 1.2.19 the JK release contains additional ant tasks. +They can be used to manage the JK web server plugins via the special status worker. +

+
Manage JK with remote Ant Tasks
+ +
Simple antlib integration
+

+

+<?xml version="1.0" encoding="UTF-8"?>
+
+<project name="modjk-status" 
+         xmlns:jk="urn:org-apache-jk-status"
+         default="status" basedir=".">
+
+	<property name="profile" value=""/>
+	<property file="jkstatus${profile}.properties"/>
+	<property file="jkstatus.properties.default"/>
+
+    <path id="jkstatus.classpath">
+      <fileset dir="${catalina.home}/bin">
+          <include name="commons-logging-api-*.jar"/>
+      </fileset>
+      <pathelement location="${catalina.home}/server/lib/catalina-ant.jar"/>
+      <pathelement location="../dist/tomcat-jkstatus-ant.jar"/>
+      <pathelement location="${catalina.home}/server/lib/tomcat-util.jar"/>
+    </path>
+
+    <typedef resource="org/apache/jk/status/antlib.xml"       
+           uri="urn:org-apache-jk-status" classpathref="jkstatus.classpath"/> 
+           
+    <target name="status" >       
+ 	    <jk:status url="${jkstatus.url}" 
+	                username="${jkstatus.username}"
+	                password="${jkstatus.password}"
+	                resultproperty="worker"
+	      	        echo="off"
+	                failOnError="off"/>
+	    <echoproperties prefix="worker" />
+    </target>
+</project>    
+
+

+
+ +
Test Result
+

+

+[echoproperties] #Ant properties
+[echoproperties] #Sun Dec 10 20:40:21 CET 2006
+[echoproperties] worker.node01.lbmult=1
+[echoproperties] worker.loadbalancer.lock=Optimistic
+[echoproperties] worker.node02.transferred=0
+[echoproperties] worker.loadbalancer.sticky_session=false
+[echoproperties] worker.node01.distance=0
+[echoproperties] worker.node01.client_errors=0
+[echoproperties] worker.node02.lbmult=1
+[echoproperties] worker.node01.port=7309
+[echoproperties] worker.node01.elected=0
+[echoproperties] worker.loadbalancer.good=2
+[echoproperties] worker.loadbalancer.method=Sessions
+[echoproperties] worker.server.port=2090
+[echoproperties] worker.loadbalancer.map.2.type=Wildchar
+[echoproperties] worker.node02.route=node02
+[echoproperties] worker.node01.route=node01
+[echoproperties] worker.node01.lbvalue=0
+[echoproperties] worker.node01.lbfactor=1
+[echoproperties] worker.node01.max_busy=0
+[echoproperties] worker.node01.busy=0
+[echoproperties] worker.node01.redirect=
+[echoproperties] worker.node02.distance=0
+[echoproperties] worker.loadbalancer.name=loadbalancer
+[echoproperties] worker.loadbalancer.sticky_session_force=false
+[echoproperties] worker.node02.state=N/A
+[echoproperties] worker.node01.state=N/A
+[echoproperties] worker.node01.transferred=0
+[echoproperties] worker.loadbalancer.map.length=2
+[echoproperties] worker.node01.type=ajp13
+[echoproperties] worker.node01.address=127.0.0.1\:7309
+[echoproperties] worker.result.type=OK
+[echoproperties] worker.loadbalancer.member_count=2
+[echoproperties] worker.loadbalancer.map_count=2
+[echoproperties] worker.loadbalancer.mtime_to_maintenance_min=12
+[echoproperties] worker.loadbalancer.mtime_to_maintenance_max=75
+[echoproperties] worker.node02.lbfactor=1
+[echoproperties] worker.node02.max_busy=0
+[echoproperties] worker.jk_version=mod_jk/1.2.21-dev
+[echoproperties] worker.loadbalancer.bad=0
+[echoproperties] worker.node02.redirect=
+[echoproperties] worker.node01.host=localhost
+[echoproperties] worker.node02.activation=ACT
+[echoproperties] worker.loadbalancer.map.1.source=JkMount
+[echoproperties] worker.loadbalancer.retries=2
+[echoproperties] worker.node02.elected=0
+[echoproperties] worker.loadbalancer.map.2.source=JkMount
+[echoproperties] worker.node02.port=7409
+[echoproperties] worker.loadbalancer.length=2
+[echoproperties] worker.node02.lbvalue=0
+[echoproperties] worker.loadbalancer.degraded=0
+[echoproperties] worker.loadbalancer.map.1.type=Wildchar
+[echoproperties] worker.loadbalancer.map.2.uri=/myapps*
+[echoproperties] worker.node02.client_errors=0
+[echoproperties] worker.length=1
+[echoproperties] worker.node01.domain=d20
+[echoproperties] worker.loadbalancer.recover_time=60
+[echoproperties] worker.server.name=localhost
+[echoproperties] worker.node02.domain=
+[echoproperties] worker.result.message=Action finished
+[echoproperties] worker.node02.busy=0
+[echoproperties] worker.node01.readed=0
+[echoproperties] worker.node01.errors=0
+[echoproperties] worker.node02.address=127.0.0.1\:7409
+[echoproperties] worker.node02.readed=0
+[echoproperties] worker.loadbalancer.busy=0
+[echoproperties] worker.web_server=Apache/2.0.59 (Unix) mod_jk/1.2.21-dev
+[echoproperties] worker.node02.errors=0
+[echoproperties] worker.node02.type=ajp13
+[echoproperties] worker.loadbalancer.map.1.uri=/ClusterTest*
+[echoproperties] worker.node01.activation=ACT
+[echoproperties] worker.loadbalancer.max_busy=0
+[echoproperties] worker.loadbalancer.type=lb
+[echoproperties] worker.node02.host=localhost
+
+

+
+ +
Update Load Balancer
+

+

+     <target name="updatelb" >       
+ 	    <jk:updateloadbalancer url="${jkstatus.url}" 
+	                username="${jkstatus.username}"
+	                password="${jkstatus.password}"
+	                loadbalancer="loadbalancer"
+	                method="Busyness"
+	                retries="2"
+	                recoverWaitTime="60"
+	                lock="Optimistic"
+	                forceStickySession="false"
+	                stickySession="false"/>
+     </target>
+
+

+
+ +
Update Worker
+

+

+     <target name="updatew" >       
+ 	    <jk:updateworker url="${jkstatus.url}" 
+	                username="${jkstatus.username}"
+	                password="${jkstatus.password}"
+	                loadbalancer="loadbalancer"
+	      	        worker="node01"
+	                lbfactor="2"
+	                activation="Active"
+	                redirect=""
+	                domain=""
+	                route="node01"
+	                distance="0"/>
+     </target>
+
+

+
+ +
Reset Worker
+

+

+     <target name="reset" >       
+ 	    <jk:reset url="${jkstatus.url}" 
+	                username="${jkstatus.username}"
+	                password="${jkstatus.password}"
+	                loadbalancer="loadbalancer"
+	      	        worker="node01"
+	                />
+     </target>
+
+

+
+ +

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/printer/changelog.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/printer/changelog.html new file mode 100644 index 00000000..ff2105a0 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/printer/changelog.html @@ -0,0 +1,2095 @@ +The Apache Tomcat Connector - Miscellaneous Documentation - Changelog
Apache TomcatApache Logo

The Apache Tomcat Connector - Miscellaneous Documentation

Changelog

Preface
+

+ This is the Changelog for Tomcat Connectors. This changelog + does not contain all updates and fixes to the Tomcat connectors (yet). + It should contain fixes made only after November 10th 2004, when the + new documentation project for JK was started. +

+
Changes between 1.2.31 and 1.2.32
+
+
Native
+ + + + + + + + + + + + + + +
fix + 51417: Fix worker busy detection by querying the + worker endpoint. Abandoned connections can leave a worker + in busy state without decrementing busy counter. (mturk) +
fix + 50339: Fix whitespace trimming when parsing attribute + lists. (rjung) +
fix + 41263: Support Servlet API getRemotePort(). + Works for Tomcat 5.5.28, 6.0.20 and 7.0.0 and Apache and ISAPI + plugins. (rjung) +
fix + 41923: AJP: Close AJP connection to Tomcat on client write + error when recovery_options 4 is specified, aborting the response + write on the Tomcat side. (timw) +
update + AJP: Cap the lingering bytes that will be read + when shutting down an AJP socket at 32k to prevent CPU spikes + in the web server when a client aborts on a large response body. + Also reduce total linger time to 2s. (timw) +
fix + 50839: AJP: Fix 30sec CPU spike due to incorrect counting + of lingering bytes causing a busy loop when a client aborts + connection during a response write. + Fixes regression in 1.2.31. (timw) +
add + LB: Forward worker activation state as request attribute + "JK_LB_ACTIVATION". Possible values are "ACT" (active), + "DIS" (disabled) and "STP" (stopped). (rjung) +
fix + HTTPD: Forward WWW-Authenticate from backend when status is 401 + and server generated error pages are used. (rjung) +
fix + 50363: IIS: Prevent chunk encoding of empty message + bodies for 204, 205 and 304 responses. (timw) +
fix + 50975: IIS: Fix hanging of Transfer-Encoding: chunked + requests when Content-Length header is present in request as well. + Also addresses situation where IIS appears to create a Content-Length + header for a small chunk encoded request when none was present in the + original request. (timw) +
fix + 47679: IIS: stop truncation of request headers when + ISAPI redirector used as an extension without the corresponding + filter installed. (timw) +
fix + NSAPI: Use lower case header names for responses. + Otherwise the web server might add chunked transfer encoding header + in addition to our content length header. +
update + Docs: Improve load balancer documentation. (rjung) +
+
+
Changes between 1.2.30 and 1.2.31
+
+
Native
+ + + + + + + + + + + + + + +
fix + 49413: AJP13: Drop flush packets send by the backend + after the response has been finished. (rjung) +
update + AJP: Log the local and remote socket address. (mturk) +
update + Watchdog: Move the maintain workers outside the critical + section allowing other threads to use the connection + pool during maintenance. (mturk) +
update + Common: Add svn revision to init log message. (rjung) +
fix + Common: Don't destroy errno during trace logging. (rjung) +
update + Apache: Add support for Apache 2.3/2.4. (rjung) +
update + Apache: Added version number resource for mod_jk.so on Windows. (timw) +
update + 48501: IIS: Added rotatelogs style log rotation to ISAPI + Redirector. (timw) +
fix + 38895: IIS: Use RAW headers instead of CGI headers by default + to prevent conversion of underscores '_' to hyphens '-' in header names. + Old behaviour can be enabled by defining USE_CGI_HEADERS. (timw) +
fix + 49511: IIS: Do not override IIS log information when subsequent + requests on a keep-alive connection are not mapped into the ISAPI Redirector. (timw) +
fix + Docs: Document SSLOptions needed for SSL information forwarding. (rjung) +
update + Docs: Grammar and style improvements and clarification about serving + static content by IIS. + Patch provided by André Warnier. (rjung) +
fix + Docs: Update subversion paths used in docs. (rjung) +
+
+
Changes between 1.2.28 and 1.2.30
+
+
Native
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
update + Apache: Improve compatibility with Apache 2.3. (rjung) +
fix + 46632: Apache: Do not register child cleanup for + our pools. (mturk) +
fix + 46893: Apache: Log warning only if JkShmSize was actually + set in the configuration. (mturk) +
update + IIS: Include optional chunking support. Off by default. (mturk) +
fix + 48763: IIS: Do not send Content-Length when using chunked encoding + or length larger 4GB. (mturk) +
fix + 48223: IIS: Propagate correct backend error code to IIS. (rjung) +
fix + 47867: IIS: crash during startup, when compiled with VS2008 + and workers.properties contains unsupported properties. + Patch provided by Indrek Juhani (rjung) +
fix + 47628: IIS: Fix deadlock when restarting the Application Pool + caused by not releasing the critical section lock. + Patch provided by Bret Prucha. (mturk) +
fix + IIS/NSAPI: Correct log file flushing after each line. (mturk) +
add + NSAPI: Add Microsoft Visual C++ Makefile. (mturk) +
update + AJP: Improve socket shutdown handling. (mturk) +
update + AJP: Ensure we never reuse a non reusable socket. (mturk) +
update + AJP: Tolerate a single excess packet when waiting for cpong. (mturk) +
update + AJP: Check protocol correctness more strictly. (mturk) +
update + 48410: AJP: Use poll instead select so we can work with more + then 1024 sockets. (mturk) +
fix + 46503: AJP/Status: Garbage data in worker domain and route. (mturk) +
fix + 48276: AJP: When worker contact cannot be resolved mark the + worker as disabled instead failing to start the server. (mturk) +
fix + 48169: AJP: Improve CGI interoperability by closing all + sockets during EXEC. (mturk) +
add + Status: Add number of open backend connections to status worker. + This feature is experimental, the displayed value might not be + accurate. (mturk) +
update + 47224: Status: When address gets changed invalidate + all opened sockets in the endpoint cache. This will cause new + backend connections to get opened using new address. (mturk) +
fix + 48305: Status: Do not show "secret" property when + doing dump. (mturk) +
fix + 45610: Status: Don't accept requests with + empty value for sub worker parameter. (rjung) +
fix + 45610: Status: Fix erroneous unsetting of + sticky_session and sticky_session_force when updating other + load balancer attributes via the status worker. (rjung) +
fix + 47222: Status: Add ping_timeout to the shared memory + and allow dynamic configuration. (mturk) +
fix + Status: Remove duplicate "errors" line in property view of + AJP13 workers that are part of a load balancer. (rjung) +
fix + LB: Fix route logging. (rjung) +
update + Logging: Automatically detect size of thread id for logging. (rjung) +
update + Logging: Add optional log file locking for Windows when defining + JK_LOG_LOCKING. (mturk) +
update + Configuration: Update example configuration. (rjung) +
update + Docs: Update information about tools needed to create a release. (rjung) +
fix + 47983: Docs: Fix typo in example config + which breaks startup. (rjung) +
update + Build: Force copy of automake files. (rjung) +
update + Build: Tomcat code repository structure cleanup reflected in documentation + and build script. (rjung, mturk) +
+
+
Changes between 1.2.27 and 1.2.28
+
+
Native
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
add + Apache: Add more environment variables to overwrite request + information. Useful in case a proxy is in front of Apache and sends + us original request information e.g. via custom headers. (rjung) +
update + Apache: No longer preallocate entries for JK request log. (rjung) +
fix + 46352: Apache: Fix crash when using SetHandler jakarta-servlet + in VHost without any JkMount. Crash due to incorrect initialization + of mount extensions. (rjung) +
fix + Apache: JkWatchdogInterval had wrong interval calculation + causing a 10 times higher watchdog interval then configured. (mturk) +
fix + Apache: Activate forwarding of SSL key size by default. (rjung) +
fix + 46169: Apache 1.3: Backport use_server_errors mount extension. (rjung) +
fix + 46763: Apache 2.0: Survive the log mutex during graceful + restart. Patch provided by Eiji Takahashi. (mturk) +
fix + 46416: Apache 2.0 on Windows: Include mstcipip.h even if + the apr doesn't include it. (mturk) +
update + IIS: Update uriworkermap.properties file on + a regular interval. This requires both worker_mount_reload + and watchdog_interval to be defined. (mturk) +
update + IIS: Remove obsolete entries from registry file. (mturk) +
fix + 46579: IIS: Use local environment table instead environment + variables for setting the JKISAPI_PATH and JKISAPI_NAME. (mturk) +
update + LB: Add new property error_escalation_time to fine tune + escalation of local errors to global errors. (rjung) +
update + LB: If the sticky session affinity mark contains a dot, treat the + part before the dot as the domain name. This allows to have full node + session affinity with domain failover. (mturk) +
fix + LB: make forced recovery work with local error states. (rjung) +
fix + LB: Only update error state and error time, if we actually have a new state. (rjung) +
fix + LB: Set global worker state to error when we reach max_reply_timeouts, + or fail_on_status triggered hard error. (rjung) +
update + AJP: Add a new error type JK_AJP_PROTOCOL_ERROR. (mturk) +
update + AJP: Allow worker ports lower or equal to 1024. (rjung) +
update + AJP: Improve some AJP error log messages. (mturk) +
update + Status: Allow changing worker address and port of AJP workers. + The address is resolved on next request for that worker. (mturk) +
update + Status: Allow update actions to show error messages in the result page. (rjung) +
update + Status: Refactor update actions. (rjung) +
update + Status: Do not redirect to the show or list page, if an error occured + during an action. (rjung) +
update + Status: Include error time in display. (rjung) +
update + Status: Remove redundant port information from worker display. + Rename address column and remove its explanation from the legend. (rjung) +
update + Status: Optimize forced uriworkermap.properties reload. (mturk) +
fix + Status: Fix crash in text display. (rjung) +
fix + Status: Show - Edit - Show always ends in single lb member show, + even when started from all members lb show. (rjung) +
fix + Status: Wildcards in sub worker names were broken for update actions. (rjung) +
fix + Status: Add use_server_errors to map display. (rjung) +
update + SHM: Move locking into the data pull and push methods. (rjung) +
update + JNI: Deprecate JNI workers. (rjung) +
fix + Netware: Missing define for MAX_PATH. Patch by Guenter Knauf. (rjung) +
update + Docs: Add a new HowTo page about reverse proxies. (rjung) +
update + Docs: Add an explanation of local error states to the timeouts documentation. (rjung) +
update + Docs: Clarify relation between socket_timeout and socket_connect_timeout. (rjung) +
update + Docs: Clarify IIS URL rewrite feature. (rjung) +
fix + 46834,46734: Docs: Fix a couple of missing or broken links. (markt,rjung) +
fix + Docs: Add 2008 news to main page and menues. (mturk, rjung) +
+
+
Changes between 1.2.26 and 1.2.27
+
+
Native
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
fix + 46109: Decay reply_timeouts even when lb method is + busyness. Also reset reply_timeouts during forced recovery. (rjung) +
update + AJP13: Recycle connection if previous request didn't complete. (mturk) +
update + Maintain should not run multiple times in parallel. (mturk) +
fix + Apache: Fix small memory leak during restart. (mturk) +
update + Improve signal handling during socket shutdown. (mturk) +
add + URI Map: Add debug dump function for uri worker map. (rjung) +
update + Add revision number to version info for non-release builds. (rjung) +
add + IIS: Optionally allow chunked encoding for responses. + At the moment only usable, if build with ISAPI_ALLOW_CHUNKING + defined. Based on patch by Tim Whittington. (rjung) +
update + IIS: Optionally use raw headers instead of CGI + headers. Fixes problem "underscore=dash" problem in + header names. At the moment only available, if build with USE_RAW_HEADERS + defined. (rjung) +
update + IIS: Optionally improve IIS 5.1 compatibility. + At the moment only available, if build with AUTOMATIC_AUTH_NOTIFICATION + defined. Based on patch by Tim Whittington. (rjung) +
fix + IIS: Fix memory corruption due to parallel initialization + by multiple threads. (rjung) +
update + Windows: Use non-default socket keepalive interval. (mturk) +
add + IIS: Add environment variables JKISAPI_PATH and JKISAPI_NAME. (mturk) +
add + Added socket_connect_timeout directive for setting the + connect timeout for the socket. This enables to have low + connection timeout but higher operational timeouts. (mturk) +
fix + AJP13: + [CVE-2008-5519] + Always send initial POST packet even if the client + disconnected after sending request but before providing + POST data. In that case or in case the client broke the + connection in a middle of read send an zero size packet + informing container about broken client connection. (mturk) +
add + AJP13: Added connection_acquire_timeout directive for setting the + absolute timeout the worker will wait for a free endpoint. (mturk) +
update + Apache: Allow to set path parameter used when doing JkStripSession. (mturk) +
update + Refactor retries implementation and change semantics of retries attributes. (mturk) +
update + Status: Allow showing only a single member for a load balancer. (rjung) +
update + Status: Add display of seconds since last statistics reset and access and + transfer rates. (rjung) +
add + AJP13: Add a configurable retry_interval time. (rjung) +
update + Documentation: Enhance description of connection_pool_size. (rjung) +
update + IIS: Refactor error page generation. (mturk) +
fix + IIS: SERVER_NAME variable can be the same for + multiple different server instances if requests + are handled according to the ip:port combination. + Use INSTANCE_ID variable to which the request + belongs instead. (mturk) +
add + Allow forwarding server error pages. This can be done + on per-uri basis using new use_server_errors extension. + (mturk) +
add + Added session_cookie and session_path for configuring + default session identifiers. (mturk) +
update + Use max_packet_size also as TCP send and receive buffer size. (mturk) +
update + Apache: Do not allow Apache to start in multi-threaded mode if mod_jk + was only build for single threaded server (prefork). (mturk) +
fix + 45812: Add done() service method that + causes sending EOS bucket for Apache httpd 2.x. + This allows filter chain to work properly. (mturk) +
add + Added connection_ping_interval, ping_timeout and ping_mode directives. + (mturk) +
fix + Apache: Use correct ld flags provided by apxs when building module. + Prevents some crashes on AIX for httpd 1.3 module. (rjung) +
fix + Documentation: "val" attribute numbering in status worker + needs to start with 0 instead of 1. (rjung) +
update + Documentation: Remove JNI parameters from sample configuration + in the workers generic howto. (rjung) +
fix + 45026: For Apache httpd 2.x add "Unknown Reason" + as the reason phrase, if we get an empty one from the backend. + Otherwise httpd 2.x returns status 500. (rjung) +
fix + Build: Fix Cygwin build. (rjung) +
update + Documentation: Add info to docs, that variables sent via JkEnvVar + are not listed in request.getAttributeNames(). (rjung) +
add + Add watchdog background thread for Apache 2.x and IIS + doing internal maintenance (idle connection checks, backend probing). + See JkWatchdogInternal (Apache) and watchdog_interval (IIS). (mturk) +
update + Change log level of some messages from error to info. (mturk) +
fix + Documentation: Fix docs for worker attribute "secret". (rjung) +
update + Detect correct plugin name for various web servers via additional + preprocessor defines. (rjung) +
fix + LB: Do not put loadbalancer node in error state if there is opened + channel. This fixes the bug when new connection fails due to + busyness, causing opened connections fail stickyness. + This brings back per-node busy counter and private state array + for each request. We can mark the state as error for failover to + work while still operating and reporting node as OK if there are + opened working connections. (mturk) +
fix + 44738: Fix merging of JkOption ForwardURI* between virtual hosts. + Patch contributed by Toshihiro Sasajima. (rjung) +
add + URI Map: Add extension attributes to uri worker map. + Allowed are reply_timeout, active/disabled/stopped + and fail_on_status. + Usage currently only implemented for httpd and IIS. (rjung+mturk) +
fix + URI Map: Make dynamic reloading atomic and free memory + not needed any longer. (rjung) +
add + Configure: Don't use post httpd 2.2.0 API functions when building + with new --enable-api-compatibility configure switch. (rjung) +
fix + Apache: JkAutoAlias does not work in combination with JkMountCopy + if there are no JkMount in virtual host. (rjung) +
update + LB: Optimize state macros to improve performance. (rjung) +
add + Apache: Allow dynamic setting of reply timeout using the environment + variable JK_REPLY_TIMEOUT. (rjung) +
add + Status: Add manageability for ajp parameters of ajp + workers and ajp lb members. (rjung) +
update + Status: Change parameter names of update action to + make them more easily distinguishable from other parameters. (rjung) +
add + Status: Add ajp worker statistics also for + workers, that are not lb members. (rjung) +
update + AJP: Refactor factories, move ajp13/ajp14 common parts into + ajp_factory. (rjung) +
update + Status: Only sync shm worker config values of the workers + for which we changed values. (rjung) +
fix + Status: Set lb_factor instead of distance. (rjung) +
update + Status: Minor layout changes, use drop down instead of multiple + text links. (rjung) +
update + SHM: Use local copies of read mostly attributes of lb sub workers + in lb and status worker. (rjung) +
update + Status: Add "dump" action to dump our initial configuration. (rjung) +
update + Status: Use property table to decide which cmd action uses which + output elements. (rjung) +
update + Common: Include original configuration map in worker_env + to make it available for workers, e.g. the status worker. (rjung) +
update + LB: Refactor "route" return for httpd note. Don't use a + member of the worker_record, because that's not thread safe. (rjung) +
update + Common: Refactor "retries", remove from service and jk_worker, + move into ajp worker instead. (rjung) +
update + SHM: Use distinct structs for lb and ajp13 in shm. + Improves type safety and saves a few bytes. (rjung) +
update + SHM: Remove unused attributes. (rjung) +
update + SHM: Automatically determine shm size for all web servers. (rjung) +
update + SHM: Make open/attach logging consistent for all web servers. (rjung) +
update + Status: Include server local time in output. (rjung) +
fix + 44116: Fix handling of multiple JSESSIONID cookies. (rjung) +
fix + 37850: Use thread safe localtime_r where appropriate. (rjung) +
fix + Use thread safe strtok_r on more platforms, especially AIX. (rjung) +
update + Status: Improve XSS hardening. (rjung) +
update + 35303: Move initialization of service members with defaults from + web server specific code to our generic jk_init_ws_service() function. (rjung) +
fix + 36385: Add missing prepost CPing/CPong directly after connect + in case prepost CPing is used, but no connect CPing. (rjung) +
update + 37322: Apache: Enhance robustness of message formating + in jk_error_exit(). (rjung) +
fix + 44147: Multiple load balancing workers problem. (rjung) +
+
+
Changes between 1.2.25 and 1.2.26
+
+
Native
+ + + + + + + + + + + + + + + + + + + + + + + + + + +
fix + 42003: Allocate memory instead using fixed size from + the stack. (mturk) +
fix + 43229: Load balancer does not do fail over after + reply timeouts. (rjung) +
fix + JKStatus: Repair detailed Apache httpd version display. + This was broken for httpd version 2.2.4+. (rjung) +
update + LB/AJP: Refactoring of jk_connect.c, jk_ajp_common.c, + jk_lb_worker.c (rjung) +
fix + Configure: Repair broken apxs auto-detection. (rjung) +
update + Configure: Remove trace logging from compiled code + via new --disable-trace configure switch. (rjung) +
update + Common: Maintain idle connections in decreasing (LRU) + slot order. (rjung) +
update + Apache: Create JK_WORKER_ROUTE and JK_REQUEST_DURATION notes for + access log even if no JkRequestLogFormat is set. (rjung) +
update + JKStatus: Enhance URI to worker map listing for Apache httpd. + We now list maps for all virtual servers and not only + the one, in which JKStatus itself was called. (rjung) +
update + JKStatus: Enhance URI to worker map listing. + Update stale uriworkermap.properties immediately. (rjung) +
fix + 43873: Fix small memory leak occuring during httpd restart. (rjung) +
update + Common: Allow '*' for the worker name in exclusion rules (resp. JkUnMount) + which will override all workers. (rjung) +
fix + 42038: Correct overlay of mounts and unmounts for IIS. (rjung) +
fix + 43684: Replace JkMountFile by JkMountFileReload in + uriworkermap.properties docs. (rjung) +
update + Apache: Add new value "All" for JkMountCopy. (rjung) +
fix + 43516: Memory leak for Apache httpd module + of size 8KB for every virtual host without JK directive + after each restart. (rjung) +
update + Apache: Cleanup init and destroy of server configuration. (rjung) +
update + Apache: Remove global configuration items from per server + configuration. (rjung) +
update + Apache: Remove unused attributes secret_key and + automount/JkAutoMount. (rjung) +
update + Cleanup of jk_uri_worker_map. (rjung) +
update + Documentation: Small additions to JkShmFile documentation. + Contributed by Gerhardus Geldenhuis. (rjung) +
fix + AJP13: Ignore flush packets before we received the response headers. (rjung) +
fix + Fix crash during startup when using worker configuration inheritance + (attribute "reference") and log level debug. (rjung) +
fix + AJP13: Match header names exactly against pre defined constants. Avoid + possible confusion with custom header names using a standard header name + as a prefix. (rjung) +
fix + jkstatus: Fix correct parameter validation at JkStatusUpdateTask and + JkStatusUpdateLoadbalancerTask ant tasks. Reported by Christian Mittendorf. (pero) +
+
+
Changes between 1.2.24 and 1.2.25
+
+
Native
+ + + + + + + + + + + + + + + + + +
update + IIS: Fix shm shutdown behaviour. (rjung) +
update + General: fail_on_status used in a load balancer can optionally + do fail over without putting the failed worker in error state. (rjung) +
update + NSAPI: Improve build description for Unix. (rjung) +
update + NSAPI: Add initialization startup message containing JK version. (rjung) +
fix + General: Declare static functions as static. (jim) +
update + Documentation: Clarify fail_on_status behaviour. (rjung) +
fix + General: Do fail_on_status before returning the response headers. (rjung) +
update + NSAPI: Fix shm shutdown behaviour. (rjung) +
update + NSAPI: Set return status even if request ended with an error. (rjung) +
update + NSAPI: Allow using without shm_file on WIN32 and Netware. (rjung) +
fix + NSAPI: Fix Crash of nsapi for log level debug and unset refect_unsafe. (rjung) +
update + NSAPI: Improve Solaris and Linux Makefiles for nsapi build. (rjung) +
fix + Build: Improve pid_t type detection during configure on Solaris. (rjung) +
update + Build: Experimental build support for gcc on WIN32 and Netware. (fuankg) +
update + Build: Makefile optimizations for Apache httpd 1.3/Netware . (fuankg) +
fix + General: Fix missing flush bug introduced in 1.2.24. (rjung) +
+
+
Changes between 1.2.23 and 1.2.24
+
+
Native
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
update + Documentation: Improved workers.properties description in the + reference guide. (rjung) +
update + Documentation: Add a HowTo about the various timeouts. rjung) +
update + Logging: add milliseconds to the default timestamp format, + if we have gettimeofday(). (rjung) +
update + Apache: add milliseconds (%Q) and microseconds (%q) as possible + JkLogStampFormat conversion specifiers. This does not use strftime(), + but needs gettimeofday(). (rjung) +
update + IIS & Sun: Log service failures also, if return code is negative. (rjung) +
fix + 42849: Abort startup of Apache httpd 1.3 in case + mod_jk initialization failed. We already do the same + for Apache httpd 2.x. (rjung) +
fix + 42849: Refuse to operate with IIS in case the + initialization failed. Instead requesting isapi_redirect.dll + 500 will be returned to the user. This is as closest as it + can get to Apache Httpd where we refuse to start the server + in case of fatal initialization errors. (mturk) +
fix + Load Balancer: Fix a deadlock in lb worker, which was exposed on Solaris + for threaded Apache MPMs. (rjung) +
update + Logging: handle LWP IDs as 32 Bit unsigned. Try to make + it work, although pthread IDs are opaque. (rjung) +
update + JkStatus: Added manipulation of max_reply_timeouts. (rjung) +
update + LB, Status: Add feature max_reply_timeouts, to make lb tolerant against + occasional long running requests. (rjung) +
update + JkStatus: Added OK/IDLE as the successor of N/A. (rjung) +
update + Status worker: Renamed runtime states. All states have a major + state (OK or ERR) and a substate. Changed the name N/A to OK/IDLE. + Added docs about the meaning of the states to the status worker + page in the reference guide. + No new states have been added to code. (rjung) +
update + Common: Add recovery options for recovering idempotent http methods + HEAD and GET. (rjung) +
fix + Correct documentation for worker attributes retries and + recovery_options. (rjung) +
fix + Make writing log lines and line endings more atomic. (rjung) +
update + Common: Refactored and unified jk_map_read_prop* and jk_map_load_prop* + for all use cases. (rjung) +
update + Common/Apache/IIS/Netscape: Add an option to check decoded URLs for + potentially malicious constructions. (rjung) +
update + IIS: Document auth_complete and uri_select. (rjung) +
update + Apache/IIS/Netscape: Change the default forwarding encoding to the new + proxy method. (jfclere, rjung) +
update + Common: Optionally reencode URIs before forwarding to the backend. + Based on the URI reencoding done bei httpd mod_proxy. (jfclere, rjung) +
update + Common: auto-detect correct print format for pid_t. + This fixes at least compiler warnings on Solaris. (rjung) +
fix + 42608: Handle Content-length as unsigned 64Bit + to allow for huge up- and downloads. (rjung) +
update + Apache: Add forwarding uri to debug log. (rjung) +
update + Docs: Clarify relation between worker names and jvmRoute for load balancing. (rjung) +
fix + Use initial zero timeout for jk_is_socket_connected. The resulting + detection is the same but offers a huge performance increase + with mod_jk. In most cases the Operating System does not favor + the 1 microsecond timeout, but it rather rounds that up to much + higher value (frequency of interrupt timer which on most systems + defaults to 100Hz). + Patch provided by David McLaughlin. (mturk) +
update + NSAPI: Check correct log file and shm file configuration during startup. (rjung) +
fix + NSAPI: Add support for the general options concerning retries, flushing + and connection persistance. (rjung) +
fix + NSAPI: fix crashes due to use of mount attribute in workers.properties. + Changed initialization order. (rjung) +
fix + Improved handling of libtool and discrepancies between CC env variable and + CC used during apache build by configure script. (rjung) +
fix + Always build with thread support, unless flag --enable-prefork + is set during for configure. (rjung) +
update + Use snprintf/vsnprintf from ap_snprintf.c for platforms other + than Windows, which might lack snprintf/vsnprintf implementations + when NOT build for Apache httpd 2.x/APR (e.g. Sub Web Server) + or without using configure. (fuankg) +
update + Imported ap_snprintf() from Apache 1.3. (fuankg) +
fix + Fix incorrect log object cleanup during statup, + leading to crashes at least on iSeries. (rjung) +
update + Add jk_stat() and jk_file_exists() as wrapper functions. + i5/OS V5R4 expects filename in ASCII for fopen but requires them + in EBCDIC for stat(). (hgomez) +
update + i5/OS (AS/400) V5R4 port where Apache 2.0 modules should now use UTF8. (hgomez) +
update + Docs: Add comments on i5/OS build for V5R4 and previous releases. (hgomez) +
+
+
Changes between 1.2.22 and 1.2.23
+
+
Native
+ + +
update + [CVE-2007-0450] + and + [CVE-2007-1860]: + Change the default value of JkOptions to ForwardURICompatUnparsed. + The old default value was ForwardURICompat. + This should make URL interpretation between Apache httpd and + Tomcat consistent (prevent double decoding problems). (rjung) +
+
+
Changes between 1.2.21 and 1.2.22
+
+
Native
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
fix + Refactor line endings logging to make it correct for all + platforms and webservers. (mturk) +
update + Added command line windows make files. (mturk) +
update + Allow fail_on_status directive to be multi line. (mturk) +
fix + 42076: Fix name of new option from ForwardCertChain to + ForwardSSLCertChain as documented. (rjung) +
fix + Docs: Fix a couple of typos, change format of a few tables, + fix links to news pages. (rjung) +
fix + Fix correct URL for TC 6 examples in new IIS rewrite.properties + configuration example file. (rjung) +
fix + Add svn properties to several files. (rjung) +
update + Add TC 6 examples to uriworkermap.properties in config examples. (rjung) +
update + Allow multiple status codes for fail_on_status directive. + The status codes can be delimited by space or comma characters. (mturk) +
update + IIS. Added pcre like regular expressions for url rewrite rules. (mturk) +
fix + 41922: Apache 1.3. Enable JkEnvVar. (mturk) +
update + Apache. Add --enable-flock configure parameter for explicit + compilation of faster flock() system calls for OS supporting + those calls. By default the fcntl system call for locking will + be used that is a little bit slower but it can work on NFS + mounted volumes as well. (mturk) +
fix + 41562: Add Debug logging for read from client in ISAPI Redirector. + Contributed by Tim Whittington. (mturk) +
update + Apache. Add ForwardSSLCertChain JkOption. + Contributed by Patrik Schnellmann. (mturk) +
fix + IIS. Do not forbid access to web-inf or meta-inf if there is + no mapped worker. This allows to have resource with those names + that are outside mapped contexts. (mturk) +
update + Apache. Use process id for creating shared memory name and delete shared + memory and shared memory lock files on exit. (mturk) +
fix + IIS. Fix Keep-Alive regression introduced in 1.2.21. (mturk) +
update + Delete unused check for empty init_map during startup. (rjung) +
fix + 41770: Fix startup error if no JkWorkersFile is used. (rjung) +
update + Use JK_TRUE/JK_FALSE instead of OK/!OK as return values in init_jk(). (rjung) +
update + Minor adjustments to apache startup log messages (when to use STDERR, remove + deprecated NOERRNO flag, shm warning and warnings for usage of default files). (rjung) +
update + Replace APR precompiler directive by httpd mpm_query to detect MPM threading. + Add a debug log message about auto-detected pool size. (rjung) +
fix + Make MMN check easier to understand and a little more precise + (for new ap_get_server_banner()/ap_get_server_description()). + We use the new API only for Apache httpd 2.3. This way our binaries are not + tightly coupled to a minor 2.0 version, and we don't use ap_get_server_banner() + any way. (rjung) +
fix + Use the full description string ap_get_server_description() instead of + the truncated info from ap_get_server_banner(), because this info gets used internally + (status worker display and ajp14 backend communication) and is not send back to the + normal user. (rjung) +
fix + 41757: Document the "--enable-prefork" flag of configure. (rjung) +
update + Enhance log messages for failures when parsing attribute maps. (rjung) +
fix + Correct log message during worker initialization, in case remote host could not be + resolved. We logged the default host name "localhost" instead of the configured one. (rjung) +
fix + 41770: Fix the second part of the bug: local_worker and local_worker_only + is missing from the list of deprecated attributes (and not supported either), so prevents + the web server from startup. (rjung) +
+
+
Changes between 1.2.20 and 1.2.21
+
+
Native
+ + + + + + + + + + + + + + + + + + + + + + + + + + +
fix + [CVE-2007-0774]: + A denial of service and critical remote code execution vulnerability. + Caused by buffer overflow in map_uri_to_worker() when URL were longer that 4095 bytes. + Reported by ZDI (www.zerodayintiative.com). + Please note this issue only affected versions 1.2.19 and 1.2.20 of the + Apache Tomcat JK Web Server Connector and not previous versions. + Tomcat 5.5.20 and Tomcat 4.1.34 + included a vulnerable version in their source packages. + Other versions of Tomcat were not affected. +
add + Check the worker. parameters and don't start if the parameter is not a valid one. (jfclere) +
add + 41439: Allow session IDs to get stripped off URLs of static + content in Apache by adding JkStripSession + directive (configurable per vhost). (mturk) +
add + Change semantics of empty defaults for JkEnvVar variables. + Until 1.2.19: not allowed. In 1.2.20: send variables as empty strings, if + neither set to non empty in config, nor during runtime. + Starting with 1.2.21: If config has no second argument only send + variable if set (even when set to empty string) during runtime. + Allows good combination with condition attribute in tomcat access log. (rjung) +
fix + 41610: Fix incorrect detection of missing Content-Length + header leading to duplicate headers. Contributed by Boris Maras. (rjung) +
fix + Better build support for SunONE (Netscape/iPlanet) webservers. (jim) +
add + Add warning if duplicate map keys are read and are not allowed, + e.g. when parsing uriworkermap.properties. (rjung) +
fix + Don't concat worker names, if uriworkermap.properties has a duplicate + pattern, instead overwrite the worker. (rjung) +
fix + Log deprecation message even in duplication case. (rjung) +
fix + uriworkermap.properties: Fix off-by-one problem when deleting + URL mapping during reloading of uriworkermap.properties. (rjung) +
add + 41439: Allow session IDs to get stripped off URLs of static + content in IIS (configurable). (rjung) +
add + 41333: Refactoring isapi_plugin configuration reading. (rjung) +
add + 41332: Add some more errno logging and unify the format. (rjung) +
add + JkStatus: Improved logging by adding status worker name to messages. + Added messages to the recover worker action. (rjung) +
add + JkStatus: Refactoring searching for workers and sub workers. (rjung) +
add + 41318: Add configuration to make status worker user + name checks case insensitive. (rjung) +
add + JkStatus: Add estimated time until next global maintenance to other + mime types and adopt jkstatus ant task. (rjung) +
add + JkStatus: Show estimated time until next global maintenance. + Change displayed time until next recovery to a min/max pair. (rjung) +
add + JkStatus: Allow a user of a read/write status worker to switch it + to and from read_only mode temporarily. (rjung) +
fix + JkStatus: Do not show read/write commands in a read_only status worker. (rjung) +
add + JkStatus: Allow lb sub workers in error state to be marked for recovery + administratively from the status worker. (rjung) +
add + Load Balancer: Do not try to recover multiple times in parallel. + Use additional runtime states "PROBE" and "FORCED". (rjung) +
fix + JkStatus: Improve data synchronization between different processes. (rjung) +
fix + 41381: Fix segfault in feature fail_on_status + (wrong order of log arguments). Patch by Juri Haberland. (rjung) +
fix + Use correct windows line endings for log file on WIN32 platform. (rjung) +
+
+
Changes between 1.2.19 and 1.2.20
+
+
Native
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
add + JkStatus Ant Task documentation page. (pero/rjung) +
add + JkStatus Ant Tasks: Add new tasks for update and reset. (pero) +
update + JkStatus Ant Tasks: Update for new xml status format. (pero) +
update + Allow integer and string values when setting enumeration/boolean + attributes via status worker update action. (rjung) +
add + Docs: New reference guide page for status worker. (rjung) +
update + Docs: Renaming the config dir to reference and using the title + Reference Guide in the docs. (rjung) +
update + Added retry_on_status for workers directive. (mturk) +
update + Status Worker: Add directive to make property prefix + and good/bad rule configurable. (rjung) +
update + Status Worker: Omit lb members when att=nosw. (rjung) +
update + Status Worker: New command cmd=version for a short version output. (rjung) +
update + Status Worker: New output stype mime=prop produces property lists. (rjung) +
fix + Apache: Fix incorrect handling of JkEnvVar when Vars are set multiple times. (rjung) +
update + Renamed jvm_route to route. Deprecated jvm_route, but still use it as fallback + when parsing the worker configuration. (rjung) +
update + IIS: Make uriworkermap file reload check interval configurable. (mturk) +
update + Apache: Make uriworkermap file reload check interval configurable. (rjung) +
update + Status Worker: Add directives for customizing the XML + output (ns, xmlns, doctype). (mturk) +
add + Docs: New page with description of uriworkermap. (rjung) +
update + Docs: Added short description of max_packet_size to worker + reference. (rjung) +
update + Status Worker: All functions accessible also for xml and txt + mime types (list, show, update, reset). (rjung) +
update + Status Worker: New global health indicators for load balancers + named bad (error, recovering or stopped), degraded (busy or disabled) + and good (the rest, active and OK or N/A). (rjung) +
update + Status Worker: New edit page, to change one attribute for all + members of a load balancer. (rjung) +
update + Status Worker: Standard logging for status worker. (rjung) +
update + Status Worker: code refactoring. (rjung) +
update + Status Worker: New attribute user (list) denies access, if + the request user in the sense of remote_user is not in this list. + Empty list = no deny (rjung) +
update + Status Worker: New attribute read_only disables the parts + of the status worker, that change states and configurations. (rjung) +
fix + 36121: Don't change main uri when mod_jk serves + included uri. (markt) +
update + Apache VHosts: Merge JkOptions +base - -base + +vhost - -vhost. (rjung) +
update + Apache Docs: Adding requirements, context information, default values and + inheritance rules to the Apache config documentation. (rjung) +
update + Status Worker: Add source type to status worker, remove the redundant "context" + column in the map listing (context=uri). (rjung) +
update + uriworkermap: On reload of the file, all old entries from the previous file + version get deleted, before the new ones are being read. (rjung) +
fix + Keep normal maps and exclusion maps internally separate. Don't treat them + as the same when adding a rule. (rjung) +
update + Status Worker: Display mapping rules also for non-lb workers and in global view. (rjung) +
update + Apache VHosts: Use the vhost log files instead of the main log. (rjung) +
update + Apache VHosts: Allow individual timestamp formats by refactoring the formatting + method. (rjung) +
update + Apache VHosts: Adding all missing config items to the virtual host level. + Don't overwrite the settings from the global server, but inherit them + in case they are not set in the virtual host. (rjung) +
update + Apache: remove unnecessary function names from log messages. (rjung) +
update + Apache: add a default log file location and a message, if the default gets used. (rjung) +
update + Apache: add missing JK_IS_DEBUG_LEVEL() (rjung) +
update + Apache VHosts: Allow JkWorkersFile, JKWorkerProperty, JkShmFile and JkShmFileSize + only in global virtual server. (rjung) +
update + Add some more jk_close_socket() and reduce log level for some info messages. (rjung) +
update + Load Balancer: Added the Sessions strategy. Contributed by Takayuki Kaneko. (rjung) +
update + Docs: Minor enhancements and syncing with more recent versions. (rjung) +
fix + 40997: Separate uri mappings from their '!' + counterpart when checking for duplicates in uriworkermap + reloading. (rjung) +
fix + 40877: Make sure the shared memory is reset on + attach for multiple web server child processes. (mturk) +
update + IIS: Added shm_size property to be able to deal with over 64 + workers configurations. (mturk) +
update + IIS: Increase default thread count to 250, so its the same as Apache Httpd + default configuration. (mturk) +
fix + 40966: Fix socket descriptor checks on windows. (mturk) +
fix + 40965: Initialize missing service parameters. (mturk) +
fix + 40938: Fix releasing of rewrite map. + Thanks to Chris Adams for spotting that. (mturk) +
update + Apache: Added +FlushHeader JkOptions. (mturk) +
update + Added explicit flush when AJP body packet size is zero. (mturk) +
fix + 40856: Fixing case sensitivity bug in URL mapping. (rjung) +
fix + 40793: Documentation: Improvements to Apache HowTo provided by + Paul Charles Leddy. (markt) +
fix + 40774: Fixing wrong recursion termination. This one restricted the + "reference" feature unintentionally to 20 workers. (rjung) +
fix + 40716: Adding "reference" feature to IIS and Netscape. (rjung) +
fix + Documentation: Corrected SetEnvIf syntax in JK_WORKER_NAME example. (rjung) +
fix + Documentation: Added forgotten STATE and ACTIVATION notes for load balancer logging in Apache. (rjung) +
update + Apache: Use instdso.sh instead libtool: libtool does not work on HP-UX for example. (jfclere) +
+
+
Changes between 1.2.18 and 1.2.19
+
+
Native
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
update + Docs: Add SetHandler and new env var to Apache config docs. (rjung) +
update + Apache 1.3: Backport "no-jk" feature. (rjung) +
update + Apache: Add an environment variable to make SetHandler "jakarta-servlet" more + useful. The variable is JK_WORKER_NAME, but can be changed by the + new directive JkWorkerIndicator. (rjung) +
fix + LB: Don't use single worker shortcut, if the single worker is being diabled. (rjung) +
fix + Status worker: Add short explanation of activation and error states to legend. (rjung) +
fix + Docs: Add meaning of zero timeout values for various timeouts + in workers.properties. (rjung) +
fix + LB: Cleanup of Mladens forced recovery. (rjung) +
fix + LB: Do not change lb_value for recovering workers to max, if + we are using BUSYNESS method. (rjung) +
fix + Apache: Since 1.2.14 mod_jk failed to detect client abort. (rjung) +
fix + Docs: Corrected description of JkEnvVar. (rjung) +
fix + Solaris: Detect filio.h in configure to make the new connection detection + build on solaris (r432825). (rjung) +
update + Add feature to force the recovery of workers that are + member of loadbalancer if all the members are in error + state. This fixes the time gap where 503 was returned + caused by recovery_timeout although the backend was + ready to handle the requests. (mturk) +
update + Docs: Seperate deprecated directives in their own table. (rjung) +
update + Docs: Allow "-" and "_" in worker names. (rjung) +
update + Allow multiple lines with attributes "balance_workers" and "mount". (rjung) +
fix + Make jk_is_some_property match more precisely. (rjung) +
update + JkStatus: Make refresh interval changeable. (rjung) +
fix + JkStatus: Adjust display of recover time wrt. global maintenance. (rjung) +
update + LB: Resetting worker state from OK to NA, if worker has been idle + too long. (rjung) +
fix + Avoid compiler warnings concerning the use of lb_*_type arrays. + Use functions instead. (rjung) +
update + Added %R JkRequestLogFormat option for Apache 1 and Apache 2. (mturk) +
update + Allow changing jvm Route from status manager. (mturk) +
fix + Do not retun 400 if Tomcat fails in the midle of the post + request. Return 500 insted. (mturk) +
update + LB: Combine ok/error/recovering/busy runtime states into a single scalar. (rjung) +
update + LB: Combine active/disabled/stopped configuration states into a single scalar. (rjung) +
update + LB: Add several Apache notes to enable standard logging for load balancer results. (rjung) +
update + LB: Reorganisation of the main load balancer service loop. (rjung) +
update + Implement hierarchical worker configuration via attribute "reference". (rjung) +
update + Log deprecated properties. (rjung) +
fix + IIS: Fix simple_rewrite for the cases where the + rewritten url is larger then the original one. (mturk) +
update + New JkOption "DisableReuse" to disable connection persistence. (jim) +
update + LB: Move sessionid retrieval out of get_most_suitable_worker into service. (rjung) +
update + Code cleanup for all service methods (use TRACE, JK_LOG_NULL_PARAMS, null pointer checks). (rjung) +
update + JKSTATUS: add refresh link. No refresh for updates. Redirect to list view after update. (rjung) +
update + Add new hook add_log_items into servers. (rjung) +
update + APACHE httpd: Rename apache logging notes. (rjung) +
update + LB: Rename lock and method constants. Add constants for defaults. (rjung) +
fix + Default log level should be INFO and not DEBUG. + Default log level should be the same for all server types. (rjung) +
fix + Make rewrite_rule_map and log_level as non mandatory + directives for isapi_redirect. (mturk) +
fix + 40107: Rewrite is_socket_connected function. + Non blocking socket is not used any more. (mturk) +
update + Allow building with VS2005 without too many warnings. (mturk) +
fix + Decide by MMN, which piped log API we should use. + mod_jk 1.2.18 broke compilation with Apache 1.3 pre 1.3.28. (rjung) +
+
+
Changes between 1.2.17 and 1.2.18
+
+
Native
+ + + +
fix + Using socklen_t in getsockopt. Also introducing jk_sock_t. (mturk) +
update + Allow recovery wait time below 60 seconds (new minimum is 1 second). (mturk) +
+
+
Changes between 1.2.16 and JK 1.2.17
+
+
Native
+ + + +
fix + Fix hanging jk status worker when certain attributes are being updated + due to double locking. (rjung) +
update + Allow JkMount to behave like uriworkermap.properties + by parsing pipe symbol as two directive marker. (mturk) +
+
+
Changes between 1.2.15 and JK 1.2.16
+
+
Native
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
update + Added simple rewrite capability for IIS. Although simple it + will fulfill most needs. (mturk) +
update + Added RECOVER_ABORT_IF_CLIENTERROR recovery_option that closes + the connection if client connection is broken during the request. (mturk) +
update + Renamed cache_timeout directive to connection_pool_timeout. (mturk) +
update + Added connection_pool_minsize directive. (mturk) +
update + Deprecate recycle_timeout directive. (mturk) +
update + Corrected some HTML syntax bugs in output of status worker. (rjung) +
update + Added the refresh=n parameter to the status worker. It will update the display every n seconds. (rjung) +
update + Balancer: Add attribute distance to balanced workers to express preferences between workers. (rjung) +
update + Balancer: Add attribute jvm_route to balanced workers to be able to use the same target in different balancers. (rjung) +
update + Status: Add lb_mult to status. (rjung) +
update + Balancer: Make different balancing strategies work in a similar way (use lb_value, use decay during global maintenance, use integer factors for weights. (rjung) +
update + Balancer: Improve locking. (rjung) +
update + Balancer: Workers start slower after recovering. (rjung) +
update + Balancer: Make different balancing strategies work in a similar way (use lb_value, use decay during global maintenance, use integer factors lb_mult for weights). (rjung) +
update + Balancer: Move recovery check to global maintenance. (rjung) +
update + Balancer: Add global maintenance method, that is called in only one process. (rjung) +
update + Extend our use of autoconf to find a 32Bit and a 64Bit unsigned type and their printf formats. (rjung) +
update + Logging: piped loggers for JkLogFile and Apache 1.3. (rjung) +
update + Logging: Add PID to log lines for each log level apart from REQUEST. (rjung) +
update + Logging: flush buffered logs to keep lines in correct order. Output final newline together with log message. (rjung) +
update + Reducing shm size. (rjung) +
update + Only log removing of old worker, when we actually do it. (rjung) +
fix + 37469: Fix shared memory close for forked childs. + The shared memory will be closed by the parent process. (mturk) +
fix + 37332: Fix potential misuse of buffer length with + snprintf functions. (mturk) +
fix + 38859: + [CVE-2006-7197] + Protect mod_jk against buggy or malicious + AJP servers in the backend. Patch provided by Ruediger Pluem. (mturk) +
fix + 38889: Use worker map sorting depending on the path + elements, to comply with Servlet spec. Patch provided by + Steve Revilak. (mturk) +
update + 36138: Added Busyness lb method. Patch provided + by Chris Lamprecht. (mturk) +
fix + Fix pessimistic locking mode. The patch correctly handles the + burst load, by syncing the access to the shared memory data. (mturk) +
fix + 38806: Reclycle worker even if it is disabled. + This fixes hot-standby workers in error state. (mturk) +
fix + 37167: Allow building with BSD-ish like make. (mturk) +
fix + ISAPI plugin (isapi_redirect.dll) did not provide correct request data + for IIS + to include in the IIS log. (markt) +
+
+
Changes between 1.2.14 and 1.2.15
+
+
Native
+ + + +
fix + Fix AJP13 Cookie2 parsing. Cookie2 was always send as Cookie. + Patch provided by Andre Gebers. (mturk) +
fix + 35862: NSAPI plugin attempts to read freed memory and attempts to + dereference a null pointer. Patch provided by Brian Kavanagh. (markt) +
+
+
Changes between 1.2.13 and 1.2.14
+
+
Native
+ + + + + + + +
fix + Fix lb for worker mpm's with cachesize set to lower number then + ThreadsPerChild is. If retries is set to value larger then 3 sleep for + 100 ms on each attempt. This enables to tune the connection cache, + and serialize incoming connections instead returning busy if connection + count is larger then cachesize. (mturk) +
fix + 36525: Solaris core dump. (mturk) +
fix + 36102: Worker actions do not persist. (mturk) +
fix + 35864: Status worker doesn't list workers. + Patch provided by Martin Goldhahn. (mturk) +
fix + 35809: JkMountCopy don't work for Apache 2.0 Patch provided by + Christophe Dubach. (mturk) +
fix + 35298: Multiple JK/ISAPI redirectors on a single IIS site are not supported + Patch provided by Tim Whittington. (mturk) +
+
+
Changes between 1.2.12 and 1.2.13
+
+
Native
+ + + + + + + + + + +
fix + 34397: Emergency was handled as Error. (jfclere) +
fix + 34474: // in URL were not handled correctly with Apache-1.3. (jfclere) +
fix + Use 64 bits int for transferred/read bytes. +
update + Added JkOptions +FlushPackets used to optimize memory + usage when sending large data. (mturk) +
update + Added lock directive for load balancer that allows more acurate + load balancing in case of burst load. (mturk) +
update + Added worker.maintain directive to allow customizing default 10 + second timeout. On busy servers this value needs to be set on + higher value. (mturk) +
fix + Fix for NetWare compiler to deal with different types between AP13 + and AP2 SDKs. (fuankg) +
update + Emit much more legible user.dmp crash analysis output for WIN32. (wrowe) +
fix + 34558: Fix first failover request. (mturk) +
+
+
Changes between 1.2.11 and 1.2.12
+
+
Native
+ + + + +
update + Added ForwardLocallAddres JkOptions flag for passing local instead remote + address. Useful for remote addr valve. (mturk) +
fixFix that worker not used, when stopped flag is true. (pero) +
update + Add loadbalance default worker secret attribute to the documentation (pero) +
+
+
Changes between 1.2.10 and 1.2.11
+
+
Native
+ + + + + + + + + + + + + + + + +
fixBackport SC_M_JK_STORED from JK2 for passing arbitrary + methods instead failing the request. (mturk) +
fixAdded missing SEARCH and ACL http methods. (mturk) +
update + Add worker secret attribute to the documentation (pero) +
update + Add a stopped flag to worker configuration. Set flag True and + complete traffic to worker is stopped. + Also update the Ant JkStatusUpdateTask at Tomcat 5.5.10 release. + Only usefull in a replicated session cluster.(pero) +
updateAdded worker maintain function that will maintain all + the workers instead just the current one. This enables to recycle + the connections on all workers. (mturk) +
updateUse shutdown when recycling connections instead hard + breaking the socket. (mturk) +
updateAdd unique directives checking. The directives if + unique are now overwritten instead concatenated. (mturk) +
updateAllow multiple worker.list directives. (mturk) +
fix + 34577: For IIS log original request instead loging + the request for ISAPI extension. (mturk) +
fix + 34558: Make sure the returned status codes are the same + for ajp and lb workers. (mturk) +
fix + 34423: Use APR_USE_FLOCK_SERIALIZE for setting log lock + on platforms like FreeBSD. Patch provided by Allan Saddi. (mturk) +
fix + 33843: Fix obtaining LDFLAGS that were used for building + Apache HTTPD. Patch provided by Beat Kneubuehl. (mturk) +
fix + 34358: Enable load balancer method configuration. (glenn) +
fix + 34357: In some situations Apache 2 mod_jk could segfault + when the JkAutoAlias directive is used. (glenn) +
update + Add --enable-prefork to the documentation (pero) +
+
+
Changes between 1.2.9 and 1.2.10
+
+
Native
+ + + + + + + + + + + + + + + + +
updateSet default shared memory to 64K instead 1M. (mturk) +
fixDo not mark the worker in error state if headers are + larger then AJP13 limit. (mturk) +
update + On Series you should use the latest PTF for Apache 2.0 + (which is now 2.0.52) and ad minima SI17402/SI17061 or cumulative + including them. (hgomez) +
update + Change the xml status format to xml attribute syntax (pero) +
fix + 33248: Fix builds where apxs defines multiple + directories for APR includes. (mturk) +
fix + 32696: Return 404 instead 403 when WEB-INF is requested + to comply with Servlet spec. (mturk) +
updateAdded ANT task for managing jkstatus. (pero) +
update + If socket_timeout is set, check if socket is alive before + sending any request to Tomcat. (mturk) +
update + Added JkMountFile for Apache web servers. This file can contain + uri mappings in the form (/url=worker), and is checked for + updates at regular 60 second interval. (mturk) +
update + Added status worker for managing worker runtime data using + web page. (mturk) +
update + Added load balancer method directive that is used for setting + the algorithm used for balancing workers. Method can be either + Request (default) or Traffic. (mturk) +
update + Added shared memory to allow dynamic configuration. Shared memory + is needed only for unix platform and web servers having multiple + child processes. For Apache web server two new directives has been + added (JkShmFile and JkShmSize). (mturk) +
update + Added textupdate mode to status worker to handle remote updates + from ant tasks.(pero) +
fix + 33562: Fix Reply_timeout when recovery_options + is larger than 1. Patch provided by Takashi Satou. (mturk) +
fix + 33308: Fix segfaults when ForwardDirectories is enabled + with Apache 1.3 +
+
+
Changes between 1.2.7 and 1.2.8
+
+
Native
+ + + + + + + + + + + + + + + +
update + Allow anyone to debug and diagnose stack dumps using windbg or any + other debugging tool, and (if they add the .pdb files to their + installation) to make sense of dr watson logs. + Patch provided by William A. Rowe (wrowe) +
fix + Fix in_addr_t usage by using the real struct ignoring typedef. + Patch provided by William A. Rowe (wrowe) +
fix + Fix url rewriting by restoring the in place uri from which the + jsessionid was removed. (mturk) +
update + Make load balancer algorithm thread safe by introducing mutex + to the load balancer worker. (mturk) +
fix + Fix sending error pages for IIS to client by adding Content-Type header + using correct api function call. (mturk) +
fix + 32696: Prevent IIS from crushing when web-inf url was requested. (mturk) +
update + Use default cachesize for servers that support discovering the number of + threads per child process. (mturk). +
fix + Fix Apache content-length header parsing using case insensitive compare. (billbarker) +
fix + Fix parsing AJP headers using case insensitive compare. (mturk) +
fix + Use infinite socket timeout if socket_timeout is set to zero or less then zero. (mturk) +
update + Change balanced_workers to balance_workers but keep + backward compatibility preserving the old directive. (mturk). +
fix + Fix ajp initialization for workers with cache_size set to zero. (mturk) +
update + 32317: Making mod_jk replication aware (Clustering Support). + Patch provided by Rainer Jung. (mturk). +
fix + 31132: Core dump when JkLogFile is missing from conf. (mturk) +
+
+
Changes between 1.2.6 and 1.2.7
+
+
Native
+ + + + + + + + + + + +
update + Added new property named recover_time that can be used to change the + default 60 second recover time. (mturk) +
update + Added custom retries for worker, so we don't depend on default setting. + If set to a number grater then 3, it will sleep for 100ms on retry greater + then 3 and then try again. (mturk) +
update + Added JkWorkerProperty directive that enables omiting workers.properties file. + For example: JkWorkerProperty worker.ajp13a.port=8009. (mturk) +
fix + Check all JSESSIONID cookies for a valid jvmRoute. If you have multiple Tomcats + with overlapping domains, then you can get multiple cookies without a defined order. + This will route correctly as long as the different domains don't have any + Tomcats in common. (billbarker) +
update + Added JkUnMount directive for negative mappings that works as opposite to JkMount directives. + It is used for blocking of particular URL or content type. (mturk) +
update + Added wildchar match uri mappings. One can now use JkMount to + map /app/*/servlet/* or /app?/*/*.jsp. (mturk) +
update + Rewrite the logging by adding Trace options. (mturk) +
update + Added socket_timeout property that sets the timeout + for the socket itself. (mturk) +
fix + Changed socket_timeout property to recycle_timeout. This better + explains what the directive actually does. (mturk) +
fix + Changed the load balancer algorithm. + The idea behind this new scheduler is the following: + lbfactor is how much we expect this worker to work, + or the worker's work quota. + lbstatus is how urgent this worker has to work to fulfill its quota + of work. We distribute each worker's work quota to the worker, and then look + which of them needs to work most urgently (biggest lbstatus). This + worker is then selected for work, and its lbstatus reduced by the + total work quota we distributed to all workers. Thus the sum of all + lbstatus does not change.(*) + If some workers are disabled, the others will + still be scheduled correctly. (mturk) +
+
+
JK 2
+

JK2 has been put in maintainer mode and no further development will take place. +The reason for shutting down JK2 development was the lack of developers interest. +Other reason was lack of users interest in adopting JK2, caused by configuration +complexity when compared to JK. +

+

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/printer/doccontrib.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/printer/doccontrib.html new file mode 100644 index 00000000..6c9c92c1 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/printer/doccontrib.html @@ -0,0 +1,248 @@ +The Apache Tomcat Connector - Miscellaneous Documentation - How to Contribute to the Documentation
Apache TomcatApache Logo

The Apache Tomcat Connector - Miscellaneous Documentation

How to Contribute to the Documentation

Introduction
+

+ This document describes how you can easily contribute to the +documentation. I'm going to try to make it easy for everyone to help out with +the documentation of Tomcat, more specifically the documentation for the +connectors. This is written from a windows user perspective as I believe they +will most benefit from it. For people using Unix it should be easy for them to +apply these steps. Just substitute Unix syntax where needed. +

+

+ The documentation is produced using xml with xsl style sheets. This +effectivly seperates the content of the documents from the style, so all that +contributers need to worry about the content. It is much easier to use than +html. +

+

+ It's all really quite simple. Here is what you will need: +

    +
  • +A recent version of Ant +
  • +
  • +The source code for the connectors from subversion +
  • +
  • +Any ascii text editor +
  • +
+

+
Getting Started Step by Step
+

+ After you get these tools they are simple to set up. +

+
STEP 1. Get Ant
+

+ Install Ant. The only advice I +have is to choose a simple installation path. Now set an environment variable +for ANT_HOME, and then add the location of the Ant/bin directory to your PATH +variable. Consult your Operating system documentation for information on how +to do this. When you are finished verify that you can run ant from the command +line. +

+

+ Ant is used to build the documentation, among other things, and it must be +able to see a file called build.xml. This file is located in the +xdocs directory. In the +build.xml file there is a target named all that will be used to build +the docs. +

+
+
STEP 2. Get the sources
+

+ Get the sources for +tomcat-connectors +from the subversion repository. If you'll +be editing from a windows platform you will need a windows subversion client. There +are several available. I like turtoiseSVN. +Unix users should install the subversion client of their choice, +if they don't already have one. +

+

+ You are ready to download the sources now. Change directory to the +location where you want your repository to be. For simplicity we will call this +your SVN_HOME. Mine is located in C:\build. +

+

+ Run the following command to checkout the sources for the first time. +You should only need to do this once. +


C:\build\>svn checkout http://svn.apache.org/repos/asf/tomcat/jk/trunk/ +tomcat-connectors

+

+

+ You should now be watching all the downloads come in. Now that you have +the sources on your machine the hard part is over. From now on, to update your +sources all you have to do is cd into any directory in your repository and run +the svn update command. +

To update your xdocs directory simply cd into the xdocs directory +and:
C:\build\tomcat-connectors\>cd xdocs
C:\build\tomcat-connectors\xdocs\>svn update

+

+
+
STEP 3. Test your build environment
+

+ Open a command prompt window and cd to the directory where you downloaded +the source. Now cd into the xdocs directory so that Ant can see the +build.xml file. Then from a command prompt, run the following: +


C:\build\tomcat-connectors>cd xdocs
C:\build\tomcat-connectors\xdocs>ant all

+

. +

+ You should see the ant compiler messages scrolling by rapidly and then stop +with the following: +

[style] Transforming into C:\build\tomcat-connectors\build\docs\news\printer>
[style] Processing C:\build\tomcat-connectors\xdocs\news\20041100.xml +to
C:\build\tomcat-connectors\build\docs\news/20041100.html
[style] Loading stylesheet C:\build\tomcat-connectors\xdocs\style.xsl
[style] Processing C:\build\tomcat-connectors\xdocs\news\20050101.xml +to
C:\build\tomcat-connectors\build\docs\news/20050101.html
[style] Processing C:\build\tomcat-connectors\xdocs\news\20060101.xml +to
C:\build\tomcat-connectors\build\docs\news/20060101.html
[style] Transforming into C:\build\tomcat-connectors\build\docs>
[style] Processing C:\build\tomcat-connectors\xdocs\index.xml +to
C:\build\tomcat-connectors\build\docs\index.html
[style] Loading stylesheet C:\build\tomcat-connectors\xdocs\style.xsl

BUILD SUCCESSFUL
Total time: 10 seconds
C:\build\tomcat-connectors>

+

+

+ All the xml files present in the xdocs directory structure were transformed +to html and copied to the SVN_HOME\tomcat-connectors\build\docs +directory. Open one of the +html files in your browser and see how it looks. +

+
+
STEP 4. The editing process.
+

+ I find it easier to use two windows while doing my updates. One I call my +build window. I keep this one in the SVN_HOME\tomcat-connectors\xdocs +directory and I only run two commands in this window: +


First I run
ant clean
Then I run
ant all

+

+

+ My second window I call my edit window and I keep that one in the +SVN_HOME\tomcat-connectors\xdocs directory where I'm doing my +edits, diffs and svn updates. +

+

+ Before you start editing you should always update your local repository to +prevent conflicts. +

You only need to update the xdocs directory
C:\build\tomcat-connectors>cd xdocs
C:\build\tomcat-connectors\xdocs>
C:\build\tomcat-connectors\xdocs>svn update

+

+

+ Now that your repository is up to date you can begin editing. Find +something in the documentation to edit. When you find something remember the +name of the file. In your edit window find and edit the xml source file +with the same name. After you are done return to the build window, and +in the SVN_HOME\tomcat-connectors\xdocs directory run: +


C:\build\tomcat-connectors\xdocs> ant clean

+

+

+ This will delete all the previous html files and make the area ready for +updated material. Now to make fresh documents that incorporate your changes +run: +


C:\build\tomcat-connectors\xdocs>ant all

+

+

+ Use your browser to view the edits you just made, they will be in the +SVN_HOME\tomcat-connectors\build\docs sub-tree. If it looks +good and is ready to go, +all that is left to do is to create a patch and submit it. +

+
+
STEP 5. Creating a patch and submitting it.
+

+ From your edit window cd into the directory that contains the xml +file you are working on, and run the svn update command. For example, +to produce a diff of the index.xml file and call it patch.txt, you +would cd into the directory containing the index.xml file and: +

C:\build\tomcat-connectors\xdocs\>svn diff index.xml > +patch.txt.

+

+

+ Now that you have your patch you are ready to send it in. +

+

+ Patches to the documentation are handled just like a bug report. You +should submit your patches to http://issues.apache.org/bugzilla/ + and include a good one line subject. If this is your first time to use the +bug database then you should read http://issues.apach +e.org/bugzilla/bugwritinghelp.html. You will need to create a user +account. At the web site paste your patch into the web form and don't forget +to describe what it is your patch is for. Sooner or later a someone with +commit privileges will review your suggestion. +

+
+
Subversion Basics
+

+ After you have checked out the sources the first time it is much easier to +use subversion. You can cd into any directory of the repository and run svn +update to get the latest sources for that directory. For editing +purposes you should always update your repository before you start editing to +reduce conflicts. +

+

+ You will need to run svn diff to generate patches for submission. +Again cd into the directory containing the file you are editing and run svn +diff name_of_the_file_you_edited > patch.txt to generate a patch for +submission. +

+

+ Pay attention to the terminal window during the update. +

+

+ Lines begining with a A indicate files that have been added. +

+

+ Lines begining with a D indicate files that have been deleted. +

+

+ Lines begining with a U mean the local copy was patched to update it +to the current version in the master repository. +

+

+ Lines begining with a G mean your local copy is different from the +master copy, and the changes were successfully merged into your copy. +

+

+ Lines begining with a C mean there was a conflict in merging the +changes and you need to review the file and merge the changes manually. Search +for >>>> and merge the changes. +

+

+ Lines begining with a ? indicate files that reside on your local +system which are not part of the repository. You will normally see this when +you are creating new files for submission. +

+
Updating Web site
+

+ Only Committers are able to update the web site (http://tomcat.apache.org/connectors-doc/). + To do it: +

    +
  • Connect to people.apache.org.
  • +
  • umask 002
  • +
  • Copy the changed files to /www/tomcat.apache.org/connectors-doc/.
  • +
  • or use ant from a checkout tomcat/jk/trunk/xdocs repository:
    + ant -Dbuild.dir=/www/tomcat.apache.org -Ddist.name=connectors-doc +
  • +
  • The changes need around 4 hours to be synced to tomcat.apache.org.
  • +
+

+
Guides and Resources
+

+ A little help to get you started if you need it +

+ +

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/printer/faq.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/printer/faq.html new file mode 100644 index 00000000..8daeac64 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/printer/faq.html @@ -0,0 +1,280 @@ +The Apache Tomcat Connector - Miscellaneous Documentation - FAQ
Apache TomcatApache Logo

The Apache Tomcat Connector - Miscellaneous Documentation

FAQ

General
+

+General Informations and FAQ about JK +

+
Where can I get help/support for JK ?
+

+The primary mechanism for support is through the JK +documentation included in the doc directory. +Documentation is also available on the Apache Tomcat web site devoted to the + +Apache Tomcat Connectors Project +For additional help, the best resource is the Tomcat Users Discussion list. +You should start by searching + +the mail list archive +before you post questions to the list. +If you are unable to locate the answer to your question in the archive, +you can post questions about JK to the user list for assistance. +Make sure that you include the version of your Webserver, +that you are using as well as the platform you are running on +and go + +here +to determine how to subscribe to tomcat mailing list. +

+
+ +
I can't find JK anywhere. Where is it?
+

+Now that JK moved to the tomcat-connectors repository, +the source and the binaries for JK can be downloaded from a mirror at the + +Tomcat Connectors (mod_jk, mod_jk2) Downloads page. +

+
+ +
What's the difference between JK and mod_jk ?
+
+

+JK is a project covering web-servers to Tomcat connectors, +whereas mod_jk is the Apache module developed in JK. +

+ +

+IIS webserversupport is implemented on JK, using a redirector +called isapi redirector. +

+ +

+Netscape/SunONE/Sun webserverwebserver support is implemented on JK, using a redirector +called nsapi redirector. +

+ +
+ +
Where can I get more information ?
+

+For JK 1.2.x, you should read : +

+ + + +

+For more detailed information, have a look at the Reference Guide. +You could also try searching the mailing list archives for "JK" or look at the source. +

+
+ +
Which protocol should I use? Ajp12 or Ajp13?
+

+Ajp13 is a newer protocol, it's faster, and it works better with SSL. +You almost certainly want to use it now that ajp12 is deprecated. +

+

+Also ajp13 is supported by all Apache Tomcat including 3.2.x , 3.3.x, 4.0.x, 4.1.x, 5.0.x, 5.5.x +and the new tomcat 6. +

+ +

+Others Servlet engines like jetty have support for Ajp13. +

+
+ +
I've got a firewall between my web server and Tomcat which drops ajp13 connections after some time
+

+Ajp13 uses persistant connections where the traffic could be null if there is no request to be sent to Tomcat. +Firewalls use to drop inactive connections and will make your web server and Tomcat think the connection is valid. +

+

+Starting with JK 1.2.0, a socket_keepalive property as been added to ajp13 settings, and you should take a look at +it in Workers HowTo and +workers.properties reference. +If nothing else helps, you can try JkOptions +DisableReuse, but this will have strong performance implications. +

+
+ +
Under heavy load, I've got many threads in Tomcat even if my Apache Web Server handles much of the load
+

+Under heavy load, Apache Web Server creates many children to handle the load, +which will in turn create many connections +to Tomcat to forward the requests they should handle. +Apache Web Server will normally kill the children/threads when the load decreases. +But if the load is still there and even if only Apache handles the requests, +ie static contents, the children are kept and with them all the ajp13 connections, +even if they are no more used. +

+

+To close connections after some time of inactivity you can use connection_pool_timeout, +for more informations refer to workers.properties reference. +

+
+ +
Apache
+

+Informations and FAQ about mod_jk and Apache Web Servers. +

+
Whenever I restart Tomcat, Apache locks up!
+

+The Ajp13 protocol keeps an open socket between Tomcat and Apache. +Release of mod_jk present in J-T-C handles the network failure. +But with very ancient releases of mod_jk, you may have to restart Apache as well. +

+
+ +
Why do there exist two files mod_jk.so (-eapi ad -noeapi) in download directories for Apache 1.3?
+

+Many versions of Apache use a modified API, known at Extended API, developed for use with the +mod_ssl module. Starting with Apache 2.0 there is no more difference. +

+ +

+For example, Apache 1.3 present in certains recent Linux distributions include the +mod_ssl module. +

+ +

+So if you got such 'Extended Apache', you need to use mod_jk.so-eapi. +

+ +

+You should use mod_jk.so-noeapi only for 'Standard Apache' (ie without mod_ssl). +

+ +

+It's wise to avoid using EAPI modules on STD API Apache or to use standard API modules on EAPI Apache. +Allways be sure to have the mod_jk.so witch match your version of Apache +

+
+ +
What's that message about 'garbled DSO ?'
+

+It's related to Apache EAPI, the message 'mod_jk.so is garbled - perhaps this is not an Apache module DSO ?' +just told you, that your're trying to install a mod_jk.so DSO module that was compiled on an Apache using EAPI, +like apache-mod_ssl or apache from Redhat distro 6.2/7.0 but your system use the standard apache with normal API. +

+
+ +
And the message about 'module might crash under EAPI!
+

+Also related to EAPI, the message '[warn] Loaded DSO /usr/lib/apache/mod_jk.so uses plain Apache 1.3 API, +this module might crash under EAPI! (please recompile it with -DEAPI)', the mod_jk.so was compiled under normal +Apache with standard API and you try to install the module on an Apache using EAPI. +

+
+ +
APXS is getting an error during the build of mod_jk, like rc=0 or rc=255. I tried all of the steps in the build section, what do I do now ?
+

+APXS is a Perl script that is created when you build the Apache web server from source. +Chances are that if you are getting these errors and you obtained Apache as a binary distribution, +that APXS is not configured correctly for your system. +Your best bet is to get the Apache source from http://httpd.apache.org and build it yourself. +Use the following for a basic build (read the Apache docs for other options): +

[user@host] ~ $ cd /usr/local/src
[user@host] ~ $ gzip -dc apache_1.3.19.tar.gz|tar xvf -
[user@host] ~ $ cd apache_1.3.19
[user@host] ~ $ ./configure --prefix=/usr/local/apache \
[user@host] ~ $ --enable-module=most \
[user@host] ~ $ --enable-shared=max
[user@host] ~ $ make
[user@host] ~ $ make install

+

+

+Note: The above steps assume that you downloaded the Apache source and placed it in your /usr/local/src directory. +

+
+ +
Apache 2.0 complains about incorrect module version
+

+Since Apache 2.0 API still change often, the Apache 2.0 teams decide to put in headers of compiled modules the +Apache 2.0 version used to compile the module. This check is called Magic Module Number bump. +

+

+At start time Apache 2.0 check that version in modules headers and stop if it detect that a module was compiled +for another Apache 2.0 version. As such you should allways use modules compiled for the same Apache 2.0 version. +This check may be removed if the future. +

+
+ +
Does it work for Apache 2.2?
+

+mod_jk works well with Apache 2.2. You need a binary module compiled for version 2.2 of the Apache web server. +A binary compiled for version 2.0 will not work. +

+

+Important parts of the functionality of mod_jk have been reimplemented as Apache httpd modules mod_proxy_ajp +and mod_proxy_balancer. These are part of the standard distributoin of Apache 2.2. The new modules do not contain +all features of mod_jk, but you get them automatically with every Apache 2.2. +

+
+ +
JNI doesn't work with Apache 1.3
+

JNI workers have been deprecated. They will likely not work. Do not use them.

+

+JNI support requires a multi-threaded environment which is not the general case for Apache 1.3. +You should verify if Apache 1.3 has been build with thread support and if not you could add the +the pthreads library to your httpd.conf file. +

+ +
+  # Add pthread to Apache in httpd.conf
+  LoadModule "/usr/lib/libpthreads.so"
+
+ +

+Also keep in mind that JNI is suited for multi-threaded servers and you should consider upgrading +to Apache 2.x to support JNI. +

+
+ +
JNI report that JVM couldn't be started under Linux
+

JNI workers have been deprecated. They will likely not work. Do not use them.

+

+Under Linux, you should set some environment variables BEFORE launching your Apache server : +

+ +

export LD_LIBRARY_PATH=$jre/bin:$jre/bin/classic:$LD_LIBRARY_PATH

+ +

+Also some Linux distributions have enabled a GLIBC feature called 'floating stacks' which may not works with kernel +less than 2.4.10 on SMP machines. You should disable floating stacks by exporting an environment variable : +

+ +

export LD_ASSUME_KERNEL=2.2.5

+ +

+You could have to update your service scripts, ie /etc/rc.d/init.d/httpd, to set these env vars +before your httpd server starts. +

+
+ +
Mixed errors when building via configure
+

+configure assume you have some GNU tools already installed and configured for your system, and ad minima libtool. +

+

+Also some systems may have mixed cc and gcc setup which may make you puzzled when trying to link an Apache built with native +c compiler with a jk/jk2 build with gcc. +

+

+In case the make processing doesn't work as expected, you should use a GNU make gmake. +

+
+ +

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/printer/jkstatustasks.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/printer/jkstatustasks.html new file mode 100644 index 00000000..ed0d0cfa --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/printer/jkstatustasks.html @@ -0,0 +1,183 @@ +The Apache Tomcat Connector - Miscellaneous Documentation - Status Worker Ant Tasks
Apache TomcatApache Logo

The Apache Tomcat Connector - Miscellaneous Documentation

Status Worker Ant Tasks

Introduction
+

Since version 1.2.19 the JK release contains additional ant tasks. +They can be used to manage the JK web server plugins via the special status worker. +

+
Manage JK with remote Ant Tasks
+ +
Simple antlib integration
+

+

+<?xml version="1.0" encoding="UTF-8"?>
+
+<project name="modjk-status" 
+         xmlns:jk="urn:org-apache-jk-status"
+         default="status" basedir=".">
+
+	<property name="profile" value=""/>
+	<property file="jkstatus${profile}.properties"/>
+	<property file="jkstatus.properties.default"/>
+
+    <path id="jkstatus.classpath">
+      <fileset dir="${catalina.home}/bin">
+          <include name="commons-logging-api-*.jar"/>
+      </fileset>
+      <pathelement location="${catalina.home}/server/lib/catalina-ant.jar"/>
+      <pathelement location="../dist/tomcat-jkstatus-ant.jar"/>
+      <pathelement location="${catalina.home}/server/lib/tomcat-util.jar"/>
+    </path>
+
+    <typedef resource="org/apache/jk/status/antlib.xml"       
+           uri="urn:org-apache-jk-status" classpathref="jkstatus.classpath"/> 
+           
+    <target name="status" >       
+ 	    <jk:status url="${jkstatus.url}" 
+	                username="${jkstatus.username}"
+	                password="${jkstatus.password}"
+	                resultproperty="worker"
+	      	        echo="off"
+	                failOnError="off"/>
+	    <echoproperties prefix="worker" />
+    </target>
+</project>    
+
+

+
+ +
Test Result
+

+

+[echoproperties] #Ant properties
+[echoproperties] #Sun Dec 10 20:40:21 CET 2006
+[echoproperties] worker.node01.lbmult=1
+[echoproperties] worker.loadbalancer.lock=Optimistic
+[echoproperties] worker.node02.transferred=0
+[echoproperties] worker.loadbalancer.sticky_session=false
+[echoproperties] worker.node01.distance=0
+[echoproperties] worker.node01.client_errors=0
+[echoproperties] worker.node02.lbmult=1
+[echoproperties] worker.node01.port=7309
+[echoproperties] worker.node01.elected=0
+[echoproperties] worker.loadbalancer.good=2
+[echoproperties] worker.loadbalancer.method=Sessions
+[echoproperties] worker.server.port=2090
+[echoproperties] worker.loadbalancer.map.2.type=Wildchar
+[echoproperties] worker.node02.route=node02
+[echoproperties] worker.node01.route=node01
+[echoproperties] worker.node01.lbvalue=0
+[echoproperties] worker.node01.lbfactor=1
+[echoproperties] worker.node01.max_busy=0
+[echoproperties] worker.node01.busy=0
+[echoproperties] worker.node01.redirect=
+[echoproperties] worker.node02.distance=0
+[echoproperties] worker.loadbalancer.name=loadbalancer
+[echoproperties] worker.loadbalancer.sticky_session_force=false
+[echoproperties] worker.node02.state=N/A
+[echoproperties] worker.node01.state=N/A
+[echoproperties] worker.node01.transferred=0
+[echoproperties] worker.loadbalancer.map.length=2
+[echoproperties] worker.node01.type=ajp13
+[echoproperties] worker.node01.address=127.0.0.1\:7309
+[echoproperties] worker.result.type=OK
+[echoproperties] worker.loadbalancer.member_count=2
+[echoproperties] worker.loadbalancer.map_count=2
+[echoproperties] worker.loadbalancer.mtime_to_maintenance_min=12
+[echoproperties] worker.loadbalancer.mtime_to_maintenance_max=75
+[echoproperties] worker.node02.lbfactor=1
+[echoproperties] worker.node02.max_busy=0
+[echoproperties] worker.jk_version=mod_jk/1.2.21-dev
+[echoproperties] worker.loadbalancer.bad=0
+[echoproperties] worker.node02.redirect=
+[echoproperties] worker.node01.host=localhost
+[echoproperties] worker.node02.activation=ACT
+[echoproperties] worker.loadbalancer.map.1.source=JkMount
+[echoproperties] worker.loadbalancer.retries=2
+[echoproperties] worker.node02.elected=0
+[echoproperties] worker.loadbalancer.map.2.source=JkMount
+[echoproperties] worker.node02.port=7409
+[echoproperties] worker.loadbalancer.length=2
+[echoproperties] worker.node02.lbvalue=0
+[echoproperties] worker.loadbalancer.degraded=0
+[echoproperties] worker.loadbalancer.map.1.type=Wildchar
+[echoproperties] worker.loadbalancer.map.2.uri=/myapps*
+[echoproperties] worker.node02.client_errors=0
+[echoproperties] worker.length=1
+[echoproperties] worker.node01.domain=d20
+[echoproperties] worker.loadbalancer.recover_time=60
+[echoproperties] worker.server.name=localhost
+[echoproperties] worker.node02.domain=
+[echoproperties] worker.result.message=Action finished
+[echoproperties] worker.node02.busy=0
+[echoproperties] worker.node01.readed=0
+[echoproperties] worker.node01.errors=0
+[echoproperties] worker.node02.address=127.0.0.1\:7409
+[echoproperties] worker.node02.readed=0
+[echoproperties] worker.loadbalancer.busy=0
+[echoproperties] worker.web_server=Apache/2.0.59 (Unix) mod_jk/1.2.21-dev
+[echoproperties] worker.node02.errors=0
+[echoproperties] worker.node02.type=ajp13
+[echoproperties] worker.loadbalancer.map.1.uri=/ClusterTest*
+[echoproperties] worker.node01.activation=ACT
+[echoproperties] worker.loadbalancer.max_busy=0
+[echoproperties] worker.loadbalancer.type=lb
+[echoproperties] worker.node02.host=localhost
+
+

+
+ +
Update Load Balancer
+

+

+     <target name="updatelb" >       
+ 	    <jk:updateloadbalancer url="${jkstatus.url}" 
+	                username="${jkstatus.username}"
+	                password="${jkstatus.password}"
+	                loadbalancer="loadbalancer"
+	                method="Busyness"
+	                retries="2"
+	                recoverWaitTime="60"
+	                lock="Optimistic"
+	                forceStickySession="false"
+	                stickySession="false"/>
+     </target>
+
+

+
+ +
Update Worker
+

+

+     <target name="updatew" >       
+ 	    <jk:updateworker url="${jkstatus.url}" 
+	                username="${jkstatus.username}"
+	                password="${jkstatus.password}"
+	                loadbalancer="loadbalancer"
+	      	        worker="node01"
+	                lbfactor="2"
+	                activation="Active"
+	                redirect=""
+	                domain=""
+	                route="node01"
+	                distance="0"/>
+     </target>
+
+

+
+ +
Reset Worker
+

+

+     <target name="reset" >       
+ 	    <jk:reset url="${jkstatus.url}" 
+	                username="${jkstatus.username}"
+	                password="${jkstatus.password}"
+	                loadbalancer="loadbalancer"
+	      	        worker="node01"
+	                />
+     </target>
+
+

+
+ +

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/printer/reporttools.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/printer/reporttools.html new file mode 100644 index 00000000..9e265bba --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/printer/reporttools.html @@ -0,0 +1,61 @@ +The Apache Tomcat Connector - Miscellaneous Documentation - Reporting Tools
Apache TomcatApache Logo

The Apache Tomcat Connector - Miscellaneous Documentation

Reporting Tools

Reporting Tools
+

+The mod_jk source distribution contains two perl scripts in the +tools/reports directory which can be used to analyze the mod_jk +logs, save statistical data, and generate report graphs. +

+ +

tomcat_trend.pl log_dir archive_dir

+

+Script for analyzing mod_jk.log data when logging tomcat request data using +the JkRequestLogFormat Apache mod_jk configuration. +Generates statistics for request latency and errors. Archives the generated +data to files for later use in long term trend graphs and reports. +

+ +

tomcat_reports.pl archive_dir reports_dir

+

+Script for generating reports and graphs using statistical data generated +by the tomcat_trend.pl script. + +The following graphs are created: +

    +
  • tomcat_request.png - Long term trend graph of total number of tomcat + requests handled.
  • +
  • tomcat_median.png - Long term overall trend graph of tomcat request + latency median.
  • +
  • tomcat_deviation.png - Long term overall trend graph of tomcat request + mean and standard deviation.
  • +
  • tomcat_error.png - Long term trend graph of requests rejected by tomcat. + Shows requests rejected when tomcat has no request processors available. + Can be an indicator that tomcat is overloaded or having other scaling + problems.
  • +
  • tomcat_client.png - Long term trend graph of requests forward to tomcat + which were aborted by the remote client (browser). You will normally see + some aborted requests. High numbers of these can be an indicator that + tomcat is overloaded or there are requests which have very high latency.
  • +
+

+ +

+A great deal of statistical data is generated but at this time +only long term trend graphs are being created and no reports. +This is only a start. Many more graphs and reports could be +generated from the data. Please consider contributing back any +new reports or graphs you create. Thanks. +

+ +

+These perl scripts depend upon the following perl modules and libraries: +

    +
  • GD 1.8.x graphics library + http://www.boutell.com/gd/
  • +
  • GD 1.4.x perl module
  • +
  • GD Graph perl module
  • +
  • GD TextUtil perl module
  • +
  • StatisticsDescriptive perl module
  • +
+

+

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/reporttools.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/reporttools.html new file mode 100644 index 00000000..36ac4b6d --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/miscellaneous/reporttools.html @@ -0,0 +1,62 @@ +The Apache Tomcat Connector - Miscellaneous Documentation - Reporting Tools
Apache TomcatApache Logo

Links

Reference Guide

Generic HowTo

Webserver HowTo

AJP Protocol Reference

Miscellaneous Documentation

News

The Apache Tomcat Connector - Miscellaneous Documentation

Reporting Tools

Printer Friendly Version
print-friendly
version +
Reporting Tools
+

+The mod_jk source distribution contains two perl scripts in the +tools/reports directory which can be used to analyze the mod_jk +logs, save statistical data, and generate report graphs. +

+ +

tomcat_trend.pl log_dir archive_dir

+

+Script for analyzing mod_jk.log data when logging tomcat request data using +the JkRequestLogFormat Apache mod_jk configuration. +Generates statistics for request latency and errors. Archives the generated +data to files for later use in long term trend graphs and reports. +

+ +

tomcat_reports.pl archive_dir reports_dir

+

+Script for generating reports and graphs using statistical data generated +by the tomcat_trend.pl script. + +The following graphs are created: +

    +
  • tomcat_request.png - Long term trend graph of total number of tomcat + requests handled.
  • +
  • tomcat_median.png - Long term overall trend graph of tomcat request + latency median.
  • +
  • tomcat_deviation.png - Long term overall trend graph of tomcat request + mean and standard deviation.
  • +
  • tomcat_error.png - Long term trend graph of requests rejected by tomcat. + Shows requests rejected when tomcat has no request processors available. + Can be an indicator that tomcat is overloaded or having other scaling + problems.
  • +
  • tomcat_client.png - Long term trend graph of requests forward to tomcat + which were aborted by the remote client (browser). You will normally see + some aborted requests. High numbers of these can be an indicator that + tomcat is overloaded or there are requests which have very high latency.
  • +
+

+ +

+A great deal of statistical data is generated but at this time +only long term trend graphs are being created and no reports. +This is only a start. Many more graphs and reports could be +generated from the data. Please consider contributing back any +new reports or graphs you create. Thanks. +

+ +

+These perl scripts depend upon the following perl modules and libraries: +

    +
  • GD 1.8.x graphics library + http://www.boutell.com/gd/
  • +
  • GD 1.4.x perl module
  • +
  • GD Graph perl module
  • +
  • GD TextUtil perl module
  • +
  • StatisticsDescriptive perl module
  • +
+

+

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/20041100.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/20041100.html new file mode 100644 index 00000000..c292e775 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/20041100.html @@ -0,0 +1,126 @@ +The Apache Tomcat Connector - News - 2004 News and Status
Apache TomcatApache Logo

Links

Reference Guide

Generic HowTo

Webserver HowTo

AJP Protocol Reference

Miscellaneous Documentation

News

The Apache Tomcat Connector - News

2004 News and Status

Printer Friendly Version
print-friendly
version +
2004 News & Status
+
+ + +

17 December - JK-1.2.8 released

+
+

The Apache Jakarta Tomcat team is proud to announce the immediate availability +of Jakarta Tomcat Connectors 1.2.8. +

+

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs during testing this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ +

17 December - JK-1.2.8-rc-1 released

+
+

The Apache Jakarta Tomcat team is proud to announce the immediate availability +of Jakarta Tomcat Connectors 1.2.8-rc-1 (Relase Canditate 1). +

+

+We expect it to be ratified as a Stable release when the vote takes place +in the next week. +

+

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs during testing this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ +

13 December - JK-1.2.7-beta-3 released

+
+

The Apache Jakarta Tomcat team is proud to announce the immediate availability +of Jakarta Tomcat Connectors 1.2.7-beta-3. The release contains a fix to few configuration +problems detected with JK-1.2.7-beta-2 version. +

+

+We expect it to be ratified as a Stable release when the vote takes place +in the next week. +

+

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs during testing this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ +

7 December - JK-1.2.7-beta-2 released

+
+

The Apache Jakarta Tomcat team is proud to announce the immediate availability +of Jakarta Tomcat Connectors 1.2.7-beta-2. The release contains a fix to few compilation +problems detected with JK-1.2.7-beta version. This release also introduces a new +domain concept clustering support. See 32317 for details. +

+

+We expect it to be ratified as a Stable release when the vote takes place +in the next two weeks. +

+

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs during testing this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ + +

30 November - JK-1.2.7-beta released

+
+

The Apache Jakarta Tomcat team is proud to announce the immediate availability +of Jakarta Tomcat Connectors 1.2.7-beta. The release contains a significant number +of bug fixes and new features. +

+

+We expect it to be ratified as a Stable release when the vote takes place +in the next two weeks. +

+

+ Please see the ChangeLog for a full list of changes. +

+

+Since release 1.2.7 the socket_timeout property has been renamed to +recycle_timeout. +The socket_timeout now sets the real timeout for socket operations. +

+

If you find any bugs during testing this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+ +
+ + +

15 November - JK2 is officially unsupported

+
+

JK2 has been put in maintainer mode and no further development will take place. +The reason for shutting down JK2 development was the lack of developers interest. +Other reason was lack of users interest in adopting JK2, caused by configuration +complexity when compared to JK. +

+

The latest official JK2 release is 2.0.4. +

+

JK2 will have it's successor within core Apache2.1/2.2 distribution. +We have developed new proxy_ajp that is an addition to +the mod_proxy and uses Tomcat's AJP protocol stack. It is developped in httpd-2.1 +and integrated in it. We have also developed a new proxy_balancer module +for load balancing http and ajp protocol stacks. +

+

JK will be fully supported for all other web servers. The next JK release is +planned for the end of November. Lots of code from JK2 has been ported to JK +

+
+ +

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/20050101.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/20050101.html new file mode 100644 index 00000000..21c7f801 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/20050101.html @@ -0,0 +1,139 @@ +The Apache Tomcat Connector - News - 2005 News and Status
Apache TomcatApache Logo

Links

Reference Guide

Generic HowTo

Webserver HowTo

AJP Protocol Reference

Miscellaneous Documentation

News

The Apache Tomcat Connector - News

2005 News and Status

Printer Friendly Version
print-friendly
version +
2005 News & Status
+
+ + +

8 November - JK-1.2.15 released

+
+

The Apache Tomcat team is proud to announce the immediate availability +of Jakarta Tomcat Connectors 1.2.15. This is Stable release and it contains +few bug fixes found in 1.2.14 version. +

+

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ + +

13 July - JK-1.2.14 released

+
+

The Apache Tomcat team is proud to announce the immediate availability +of Jakarta Tomcat Connectors 1.2.14. This is Stable release and it contains +few bug fixes found in 1.2.13 version. +

+

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ +

7 May - JK-1.2.13 released

+
+

The Apache Jakarta Tomcat team is proud to announce the immediate availability +of Jakarta Tomcat Connectors 1.2.13. This is development release and contains +few bug fixes found in 1.2.12 version. +

+

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ +

7 May - JK-1.2.12 released

+
+

The Apache Jakarta Tomcat team is proud to announce the immediate availability +of Jakarta Tomcat Connectors 1.2.12 The release contains a significant number +of bug fixes and new features. +

+

+We expect it to be ratified as a Stable release when the vote takes place +in the next week. +

+

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ +

29 April - JK-1.2.11 released

+
+

The Apache Jakarta Tomcat team is proud to announce the immediate availability +of Jakarta Tomcat Connectors 1.2.11 The release contains a significant number +of bug fixes and new features. +

+

+This version has not been released. +

+

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ +

30 March - JK-1.2.10 released

+
+

The Apache Jakarta Tomcat team is proud to announce the immediate availability +of Jakarta Tomcat Connectors 1.2.10 The release contains a significant number +of bug fixes and new features. +

+

+We expect it to be ratified as a Stable release when the vote takes place +in the next two weeks. +

+

+ Please see the ChangeLog for a full list of changes. +

+

+Since release 1.2.10 the JkShmFile property has been added for +Apache 1.3.x and Apache 2.x web servers on UNIX and LINUX platforms. +Load balancer will not work properly if this directive is not present. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ +

18 March - JK-1.2.9-beta released

+
+

The Apache Jakarta Tomcat team is proud to announce the immediate availability +of Jakarta Tomcat Connectors 1.2.9-beta. The release contains a significant number +of bug fixes and new features. +

+

+We expect it to be ratified as a Stable release when the vote takes place +in the next two weeks. +

+

+ Please see the ChangeLog for a full list of changes. +

+

+Since release 1.2.9 the JkShmFile property has been added for +Apache 1.3.x and Apache 2.x web servers on UNIX and LINUX platforms. +Load balancer will not work properly if this directive is not present. +

+

If you find any bugs during testing this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ +

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/20060101.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/20060101.html new file mode 100644 index 00000000..06958caa --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/20060101.html @@ -0,0 +1,80 @@ +The Apache Tomcat Connector - News - 2006 News and Status
Apache TomcatApache Logo

Links

Reference Guide

Generic HowTo

Webserver HowTo

AJP Protocol Reference

Miscellaneous Documentation

News

The Apache Tomcat Connector - News

2006 News and Status

Printer Friendly Version
print-friendly
version +
2006 News & Status
+
+ +

10 December - JK-1.2.20 released

+
+

The Apache Tomcat team is proud to announce the immediate availability +of Tomcat Connectors 1.2.20. This is a stable release adding new features +and a few bug fixes to version 1.2.19. +Furthermore the documentation has been reorganised. +

+

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ + +

17 September - JK-1.2.19 released

+
+

The Apache Tomcat team is proud to announce the immediate availability +of Tomcat Connectors 1.2.19. This is a stable release adding some features +and a few bug fixes to version 1.2.18. +Furthermore the non-functional code trees for isapi and domino have been removed. +

+

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ + +

13 July - JK-1.2.18 released

+
+

The Apache Tomcat team is proud to announce the immediate availability +of Tomcat Connectors 1.2.18. This is a stable release adding +a few bug fixes to the not released 1.2.17 version. +

+

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ + +

JK-1.2.17 not released

+
+

Version 1.2.17 of Tomcat Connectors 1.2.17 has not been released +due to a bug in the types chosen for socket arguments. +

+

+ Please see the ChangeLog for a full list of changes. +

+
+ + +

JK-1.2.16 not released

+
+

Version 1.2.16 of Tomcat Connectors 1.2.16 has not been released +due to a bug in the jk status worker. This version adds some features +and a few bug fixes to the 1.2.15 version. Furthermore some worker attributes +have been deprecated. +

+

+ Please see the ChangeLog for a full list of changes. +

+
+ +

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/20070301.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/20070301.html new file mode 100644 index 00000000..a3b43d26 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/20070301.html @@ -0,0 +1,87 @@ +The Apache Tomcat Connector - News - 2007 News and Status
Apache TomcatApache Logo

Links

Reference Guide

Generic HowTo

Webserver HowTo

AJP Protocol Reference

Miscellaneous Documentation

News

The Apache Tomcat Connector - News

2007 News and Status

Printer Friendly Version
print-friendly
version +
2007 News & Status
+
+ +

21 December - JK-1.2.26 released

+
+

The Apache Tomcat team is proud to announce the immediate availability +of Tomcat Connectors 1.2.26. This is a stable release adding few new features +and some bug fixes. +

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ +

7 August - JK-1.2.25 released

+
+

The Apache Tomcat team is proud to announce the immediate availability +of Tomcat Connectors 1.2.25. This is a stable release adding new features +and a few bug fixes. +

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ +

27 July - JK-1.2.24 released

+
+

This release has been withdrawn. +

+
+ +

18 May - JK-1.2.23 released

+
+

The Apache Tomcat team is proud to announce the immediate availability +of Tomcat Connectors 1.2.23. This is a stable release adding new features +and a few bug fixes to version 1.2.23. +

+It fixes an Important vulnerability. +

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ +

17 April - JK-1.2.22 released

+
+

The Apache Tomcat team is proud to announce the immediate availability +of Tomcat Connectors 1.2.22. This is a stable release adding new features +and a few bug fixes to version 1.2.22. +

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ +

1 March - JK-1.2.21 released

+
+

The Apache Tomcat team is proud to announce the immediate availability +of Tomcat Connectors 1.2.21. This is a stable release adding new features +and a few bug fixes to version 1.2.20. +

+It fixes a Critical vulnerability introduced in version 1.2.19 +

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ +

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/20081001.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/20081001.html new file mode 100644 index 00000000..1a263074 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/20081001.html @@ -0,0 +1,158 @@ +The Apache Tomcat Connector - News - 2008 News and Status
Apache TomcatApache Logo

Links

Reference Guide

Generic HowTo

Webserver HowTo

AJP Protocol Reference

Miscellaneous Documentation

News

The Apache Tomcat Connector - News

2008 News and Status

Printer Friendly Version
print-friendly
version +
2008 News & Status
+
+
28 October - JK-1.2.27 released
+ +
+

The Apache Tomcat team is proud to announce the immediate availability +of Tomcat Connectors 1.2.27. This is a stable release adding lots of new features +and some bug fixes. +

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. +

+

+The most important new features in this version are: +

+

Watchdog Thread for Periodic Tasks

+

+The connector has to run some periodic tasks independant of +request processing. Examples are probing or closing down idle backend +connections, adjusting load numbers and recovering workers from error state. +

+

+Before version 1.2.27 these tasks were done inside the request processing loop. +When a new request came in and the task was due, the thread handling the +request first executed the internal task and then handled the request. +If there were no requests coming in, the tasks would not run. If any of +the tasks took unexpectedly long, the response time of the request waiting +for the finishing of the task went up. +

+

+Starting with this release you can configure a separate watchdog thread inside +the web server to run all those tasks independantly of request processing. +This new feature is avaliable for the connector when used with Apache httpd 2.x +or with Microsoft IIS. To keep the behaviour of the new version consistent +with previous releases, this feature is turned off by default. +You can activate the watchdog thread via +JkWatchdogInterval +for Apache or +watchdog_interval +for IIS. +

+

Connection Probing

+

+In previous releases connection probing (checking whether connections still work) +could only be done immediately after a new connection was established and +directly before sending each request. Since we now have the watchdog +thread available, we also added a periodic probing option, which you +can activate with the worker attribute +ping_mode. +This will also be useful as a protection against the infamous firewall +idle connection drop. +

+

+The older attributes connect_timeout and prepost_timeout +still exist and work the same way they did in previous releases. +Since there are now three different probing options, we recommend to migrate +your configuration to the newer attributes ping_mode, +ping_timeout and connection_ping_interval. +

+

Mount Extensions

+

+Usually one defines workers and mounts for the connector. +A worker defines a backend we want to talk to and the configuration parameters of the +communication, connection pools etc. The mounts define which URIs we want to forward to +which worker (so we also call a mount an URI map rule). +In version 1.2.27 you can overwrite certain worker parameter per mount. +

+

+One easy to understand example is reply timeouts. Until this release you had to specify +a reply timeout for the whole worker. But reply times depend a lot on the type of +request. So normally you want to define a general reply timeout and +for some special URLs you need to relax the reply timeout, because you know those +URLs take much longer to process (like e.g. reporting or other compute intensive tasks). +

+

+Another possible case is the activation status. You might use a load balancer worker to +forward requests to certain webapps in a farm of Tomcat nodes. If you wanted +to update some webapp on one node, you previously had to stop forwarding requests for +all webapps on this Tomcat node. What was not possible until now, was stopping forwarding +requests restricted to the webapp and the node you wanted to update. +

+

+Starting with this release, you can add so-called +rule extensions +to your uriworkermap file to influence worker parameters per mount. This will +work for all Apache versions and for IIS. Remember, that +the uriworkermap file automatically gets reloaded after changes without web server +restart. +

+

Improved IIS support

+

+We improved IIS support im various ways. It is now possible to use +multiple IIS 6 application pools with the ISAPI redirector. +

+

+Furthermore some improvements were added as compile time features. +The most notable one is chunked encoding support, which was a major +refactoring and is therefore still considered experimental. You can +download binaries with and without chunked encoding support. In future +versions, chunked encoding will likely be availabe in all builds. +

+

+Another new feature is an elegant way of configuring error page redirects. +All new features are documented on the documentation page about +configuring IIS. +

+

Enhanced Status Worker

+

+The +status worker +now can also manage and show statistics for AJP workers that +are not part of a load balancer. Other improvements are the new dump +action, the integration of the new configuration attributes, showing average +request and transfer rates since the last statistics reset and the ability to +display only a single member of a load balancer. +

+

+Unfortunately we had to change +some request parameters +used for the update action of the status worker. +

+

Miscellaneous Improvements

+

+Further enhancements are: +

    +
  • +Configurable session stickyness indicator: cookie name and URL path +parameter name can be freely chosen instead of the servlet spec compliant +JSESSIONID and ;jsessionid. +
  • +
  • +Automatically determining the size of the shared memory segment needed +to accommodate all workers. +
  • +
  • +New connection establishment timeout socket_connect_timeout. +
  • +
  • +New timeout connection_acquire_timeout for acquiring a free connection from +the pool. +
  • +
  • +Improved retry handling by adjusting the meaning of the attribute retries for +AJP workers and for load balancers and by adding the new retry_interval. +
  • +
  • +Allowing the web server to provide error pages instead of Tomcat. +
  • +
+

+
+

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/20090301.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/20090301.html new file mode 100644 index 00000000..f8ac8584 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/20090301.html @@ -0,0 +1,63 @@ +The Apache Tomcat Connector - News - 2009 News and Status
Apache TomcatApache Logo

Links

Reference Guide

Generic HowTo

Webserver HowTo

AJP Protocol Reference

Miscellaneous Documentation

News

The Apache Tomcat Connector - News

2009 News and Status

Printer Friendly Version
print-friendly
version +
2009 News & Status
+
+
22 March - JK-1.2.28 released
+ +
+

The Apache Tomcat team is proud to announce the immediate availability +of Tomcat Connectors 1.2.28. This is a stable release concentrating mainly on +some bug fixes. +

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. +

+

+The most important new features in this version are: +

+

Better Error Detection for Load Balancer Workers

+

+Local and global error states have been improved. You can fine tune the +behaviour with the new "error_escalation_time" attribute +(see the timeouts documentation). +

+

Dynamic Address and Port Change Using the Status Worker

+

+The status worker now allows you to change the address and the port +of an AJP13 worker on the fly. You can e.g. provision dummy workers with a port +equal to "0", which will be automatically put into stopped mode during startup. +Later, when you want to actually use thse workers, you set their address and +port to the final values. +

+

+Note that already existing connections will go on using the old +address and port. This will be improved in future versions. +

+

New Data in Status Worker Display

+

+The status worker display now also contains the timestamp of the last +worker errors. +

+

Improved Proxy Flexibility

+

+You can now overwrite more request metadata before the request gets send to the backend. +This is helpful in case there are other reverse proxies in front of your web server. +A new documentation page explains this in detail. +

+

Improved IIS Support

+

+IIS support has been improved especially when using mutltiple application pools. +Furthermore you can now configure the ISAPI plugin to update the uriworkermap.properies +file on a regular interval using the watchdog thread. +

+

JNI Worker Deprecation

+

+Workers of type jni are broken since a long time. Since there is no more +use for them, they have been deprecated now, and will be removed in a future release. +

+
+

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/20100101.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/20100101.html new file mode 100644 index 00000000..8fb89125 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/20100101.html @@ -0,0 +1,62 @@ +The Apache Tomcat Connector - News - 2010 News and Status
Apache TomcatApache Logo

Links

Reference Guide

Generic HowTo

Webserver HowTo

AJP Protocol Reference

Miscellaneous Documentation

News

The Apache Tomcat Connector - News

2010 News and Status

Printer Friendly Version
print-friendly
version +
2010 News & Status
+
+
1 November - JK-1.2.31 released
+ +
+

The Apache Tomcat team is proud to announce the immediate availability + of Tomcat Connectors 1.2.31. This is a stable release concentrating mainly on + some bug fixes. +

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the + Bugzilla + Bug Report. +

+
+ +
+
1 March - JK-1.2.30 released
+ +
+

The Apache Tomcat team is proud to announce the immediate availability +of Tomcat Connectors 1.2.30. This is a stable release concentrating mainly on +some bug fixes. +

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. +

+
+ +
+
1 March - JK-1.2.29 withdrawn
+ +
+

Tomcat Connectors 1.2.29 has been withdrawn because of regression inside +Microsoft IIS connector. +

+
+ +
+
26 February - JK-1.2.29 released
+ +
+

The Apache Tomcat team is proud to announce the immediate availability +of Tomcat Connectors 1.2.29. This is a stable release concentrating mainly on +some bug fixes. +

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. +

+ +
+

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/20110701.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/20110701.html new file mode 100644 index 00000000..3a03fd0d --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/20110701.html @@ -0,0 +1,22 @@ +The Apache Tomcat Connector - News - 2011 News and Status
Apache TomcatApache Logo

Links

Reference Guide

Generic HowTo

Webserver HowTo

AJP Protocol Reference

Miscellaneous Documentation

News

The Apache Tomcat Connector - News

2011 News and Status

Printer Friendly Version
print-friendly
version +
2011 News & Status
+
+ +
8 July - JK-1.2.32 released
+ +
+

The Apache Tomcat team is proud to announce the immediate availability + of Tomcat Connectors 1.2.32. This is a stable release concentrating mainly on + some bug fixes. +

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the + Bugzilla + Bug Report. +

+
+ +

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/printer/20041100.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/printer/20041100.html new file mode 100644 index 00000000..88151b57 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/printer/20041100.html @@ -0,0 +1,125 @@ +The Apache Tomcat Connector - News - 2004 News and Status
Apache TomcatApache Logo

The Apache Tomcat Connector - News

2004 News and Status

2004 News & Status
+
+ + +

17 December - JK-1.2.8 released

+
+

The Apache Jakarta Tomcat team is proud to announce the immediate availability +of Jakarta Tomcat Connectors 1.2.8. +

+

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs during testing this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ +

17 December - JK-1.2.8-rc-1 released

+
+

The Apache Jakarta Tomcat team is proud to announce the immediate availability +of Jakarta Tomcat Connectors 1.2.8-rc-1 (Relase Canditate 1). +

+

+We expect it to be ratified as a Stable release when the vote takes place +in the next week. +

+

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs during testing this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ +

13 December - JK-1.2.7-beta-3 released

+
+

The Apache Jakarta Tomcat team is proud to announce the immediate availability +of Jakarta Tomcat Connectors 1.2.7-beta-3. The release contains a fix to few configuration +problems detected with JK-1.2.7-beta-2 version. +

+

+We expect it to be ratified as a Stable release when the vote takes place +in the next week. +

+

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs during testing this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ +

7 December - JK-1.2.7-beta-2 released

+
+

The Apache Jakarta Tomcat team is proud to announce the immediate availability +of Jakarta Tomcat Connectors 1.2.7-beta-2. The release contains a fix to few compilation +problems detected with JK-1.2.7-beta version. This release also introduces a new +domain concept clustering support. See 32317 for details. +

+

+We expect it to be ratified as a Stable release when the vote takes place +in the next two weeks. +

+

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs during testing this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ + +

30 November - JK-1.2.7-beta released

+
+

The Apache Jakarta Tomcat team is proud to announce the immediate availability +of Jakarta Tomcat Connectors 1.2.7-beta. The release contains a significant number +of bug fixes and new features. +

+

+We expect it to be ratified as a Stable release when the vote takes place +in the next two weeks. +

+

+ Please see the ChangeLog for a full list of changes. +

+

+Since release 1.2.7 the socket_timeout property has been renamed to +recycle_timeout. +The socket_timeout now sets the real timeout for socket operations. +

+

If you find any bugs during testing this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+ +
+ + +

15 November - JK2 is officially unsupported

+
+

JK2 has been put in maintainer mode and no further development will take place. +The reason for shutting down JK2 development was the lack of developers interest. +Other reason was lack of users interest in adopting JK2, caused by configuration +complexity when compared to JK. +

+

The latest official JK2 release is 2.0.4. +

+

JK2 will have it's successor within core Apache2.1/2.2 distribution. +We have developed new proxy_ajp that is an addition to +the mod_proxy and uses Tomcat's AJP protocol stack. It is developped in httpd-2.1 +and integrated in it. We have also developed a new proxy_balancer module +for load balancing http and ajp protocol stacks. +

+

JK will be fully supported for all other web servers. The next JK release is +planned for the end of November. Lots of code from JK2 has been ported to JK +

+
+ +

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/printer/20050101.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/printer/20050101.html new file mode 100644 index 00000000..35ef948f --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/printer/20050101.html @@ -0,0 +1,138 @@ +The Apache Tomcat Connector - News - 2005 News and Status
Apache TomcatApache Logo

The Apache Tomcat Connector - News

2005 News and Status

2005 News & Status
+
+ + +

8 November - JK-1.2.15 released

+
+

The Apache Tomcat team is proud to announce the immediate availability +of Jakarta Tomcat Connectors 1.2.15. This is Stable release and it contains +few bug fixes found in 1.2.14 version. +

+

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ + +

13 July - JK-1.2.14 released

+
+

The Apache Tomcat team is proud to announce the immediate availability +of Jakarta Tomcat Connectors 1.2.14. This is Stable release and it contains +few bug fixes found in 1.2.13 version. +

+

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ +

7 May - JK-1.2.13 released

+
+

The Apache Jakarta Tomcat team is proud to announce the immediate availability +of Jakarta Tomcat Connectors 1.2.13. This is development release and contains +few bug fixes found in 1.2.12 version. +

+

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ +

7 May - JK-1.2.12 released

+
+

The Apache Jakarta Tomcat team is proud to announce the immediate availability +of Jakarta Tomcat Connectors 1.2.12 The release contains a significant number +of bug fixes and new features. +

+

+We expect it to be ratified as a Stable release when the vote takes place +in the next week. +

+

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ +

29 April - JK-1.2.11 released

+
+

The Apache Jakarta Tomcat team is proud to announce the immediate availability +of Jakarta Tomcat Connectors 1.2.11 The release contains a significant number +of bug fixes and new features. +

+

+This version has not been released. +

+

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ +

30 March - JK-1.2.10 released

+
+

The Apache Jakarta Tomcat team is proud to announce the immediate availability +of Jakarta Tomcat Connectors 1.2.10 The release contains a significant number +of bug fixes and new features. +

+

+We expect it to be ratified as a Stable release when the vote takes place +in the next two weeks. +

+

+ Please see the ChangeLog for a full list of changes. +

+

+Since release 1.2.10 the JkShmFile property has been added for +Apache 1.3.x and Apache 2.x web servers on UNIX and LINUX platforms. +Load balancer will not work properly if this directive is not present. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ +

18 March - JK-1.2.9-beta released

+
+

The Apache Jakarta Tomcat team is proud to announce the immediate availability +of Jakarta Tomcat Connectors 1.2.9-beta. The release contains a significant number +of bug fixes and new features. +

+

+We expect it to be ratified as a Stable release when the vote takes place +in the next two weeks. +

+

+ Please see the ChangeLog for a full list of changes. +

+

+Since release 1.2.9 the JkShmFile property has been added for +Apache 1.3.x and Apache 2.x web servers on UNIX and LINUX platforms. +Load balancer will not work properly if this directive is not present. +

+

If you find any bugs during testing this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ +

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/printer/20060101.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/printer/20060101.html new file mode 100644 index 00000000..9ee056e2 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/printer/20060101.html @@ -0,0 +1,79 @@ +The Apache Tomcat Connector - News - 2006 News and Status
Apache TomcatApache Logo

The Apache Tomcat Connector - News

2006 News and Status

2006 News & Status
+
+ +

10 December - JK-1.2.20 released

+
+

The Apache Tomcat team is proud to announce the immediate availability +of Tomcat Connectors 1.2.20. This is a stable release adding new features +and a few bug fixes to version 1.2.19. +Furthermore the documentation has been reorganised. +

+

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ + +

17 September - JK-1.2.19 released

+
+

The Apache Tomcat team is proud to announce the immediate availability +of Tomcat Connectors 1.2.19. This is a stable release adding some features +and a few bug fixes to version 1.2.18. +Furthermore the non-functional code trees for isapi and domino have been removed. +

+

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ + +

13 July - JK-1.2.18 released

+
+

The Apache Tomcat team is proud to announce the immediate availability +of Tomcat Connectors 1.2.18. This is a stable release adding +a few bug fixes to the not released 1.2.17 version. +

+

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ + +

JK-1.2.17 not released

+
+

Version 1.2.17 of Tomcat Connectors 1.2.17 has not been released +due to a bug in the types chosen for socket arguments. +

+

+ Please see the ChangeLog for a full list of changes. +

+
+ + +

JK-1.2.16 not released

+
+

Version 1.2.16 of Tomcat Connectors 1.2.16 has not been released +due to a bug in the jk status worker. This version adds some features +and a few bug fixes to the 1.2.15 version. Furthermore some worker attributes +have been deprecated. +

+

+ Please see the ChangeLog for a full list of changes. +

+
+ +

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/printer/20070301.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/printer/20070301.html new file mode 100644 index 00000000..c6a84044 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/printer/20070301.html @@ -0,0 +1,86 @@ +The Apache Tomcat Connector - News - 2007 News and Status
Apache TomcatApache Logo

The Apache Tomcat Connector - News

2007 News and Status

2007 News & Status
+
+ +

21 December - JK-1.2.26 released

+
+

The Apache Tomcat team is proud to announce the immediate availability +of Tomcat Connectors 1.2.26. This is a stable release adding few new features +and some bug fixes. +

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ +

7 August - JK-1.2.25 released

+
+

The Apache Tomcat team is proud to announce the immediate availability +of Tomcat Connectors 1.2.25. This is a stable release adding new features +and a few bug fixes. +

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ +

27 July - JK-1.2.24 released

+
+

This release has been withdrawn. +

+
+ +

18 May - JK-1.2.23 released

+
+

The Apache Tomcat team is proud to announce the immediate availability +of Tomcat Connectors 1.2.23. This is a stable release adding new features +and a few bug fixes to version 1.2.23. +

+It fixes an Important vulnerability. +

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ +

17 April - JK-1.2.22 released

+
+

The Apache Tomcat team is proud to announce the immediate availability +of Tomcat Connectors 1.2.22. This is a stable release adding new features +and a few bug fixes to version 1.2.22. +

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ +

1 March - JK-1.2.21 released

+
+

The Apache Tomcat team is proud to announce the immediate availability +of Tomcat Connectors 1.2.21. This is a stable release adding new features +and a few bug fixes to version 1.2.20. +

+It fixes a Critical vulnerability introduced in version 1.2.19 +

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. When entering bug select Native:JK Component. +

+
+ +

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/printer/20081001.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/printer/20081001.html new file mode 100644 index 00000000..c8d5dcf2 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/printer/20081001.html @@ -0,0 +1,157 @@ +The Apache Tomcat Connector - News - 2008 News and Status
Apache TomcatApache Logo

The Apache Tomcat Connector - News

2008 News and Status

2008 News & Status
+
+
28 October - JK-1.2.27 released
+ +
+

The Apache Tomcat team is proud to announce the immediate availability +of Tomcat Connectors 1.2.27. This is a stable release adding lots of new features +and some bug fixes. +

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. +

+

+The most important new features in this version are: +

+

Watchdog Thread for Periodic Tasks

+

+The connector has to run some periodic tasks independant of +request processing. Examples are probing or closing down idle backend +connections, adjusting load numbers and recovering workers from error state. +

+

+Before version 1.2.27 these tasks were done inside the request processing loop. +When a new request came in and the task was due, the thread handling the +request first executed the internal task and then handled the request. +If there were no requests coming in, the tasks would not run. If any of +the tasks took unexpectedly long, the response time of the request waiting +for the finishing of the task went up. +

+

+Starting with this release you can configure a separate watchdog thread inside +the web server to run all those tasks independantly of request processing. +This new feature is avaliable for the connector when used with Apache httpd 2.x +or with Microsoft IIS. To keep the behaviour of the new version consistent +with previous releases, this feature is turned off by default. +You can activate the watchdog thread via +JkWatchdogInterval +for Apache or +watchdog_interval +for IIS. +

+

Connection Probing

+

+In previous releases connection probing (checking whether connections still work) +could only be done immediately after a new connection was established and +directly before sending each request. Since we now have the watchdog +thread available, we also added a periodic probing option, which you +can activate with the worker attribute +ping_mode. +This will also be useful as a protection against the infamous firewall +idle connection drop. +

+

+The older attributes connect_timeout and prepost_timeout +still exist and work the same way they did in previous releases. +Since there are now three different probing options, we recommend to migrate +your configuration to the newer attributes ping_mode, +ping_timeout and connection_ping_interval. +

+

Mount Extensions

+

+Usually one defines workers and mounts for the connector. +A worker defines a backend we want to talk to and the configuration parameters of the +communication, connection pools etc. The mounts define which URIs we want to forward to +which worker (so we also call a mount an URI map rule). +In version 1.2.27 you can overwrite certain worker parameter per mount. +

+

+One easy to understand example is reply timeouts. Until this release you had to specify +a reply timeout for the whole worker. But reply times depend a lot on the type of +request. So normally you want to define a general reply timeout and +for some special URLs you need to relax the reply timeout, because you know those +URLs take much longer to process (like e.g. reporting or other compute intensive tasks). +

+

+Another possible case is the activation status. You might use a load balancer worker to +forward requests to certain webapps in a farm of Tomcat nodes. If you wanted +to update some webapp on one node, you previously had to stop forwarding requests for +all webapps on this Tomcat node. What was not possible until now, was stopping forwarding +requests restricted to the webapp and the node you wanted to update. +

+

+Starting with this release, you can add so-called +rule extensions +to your uriworkermap file to influence worker parameters per mount. This will +work for all Apache versions and for IIS. Remember, that +the uriworkermap file automatically gets reloaded after changes without web server +restart. +

+

Improved IIS support

+

+We improved IIS support im various ways. It is now possible to use +multiple IIS 6 application pools with the ISAPI redirector. +

+

+Furthermore some improvements were added as compile time features. +The most notable one is chunked encoding support, which was a major +refactoring and is therefore still considered experimental. You can +download binaries with and without chunked encoding support. In future +versions, chunked encoding will likely be availabe in all builds. +

+

+Another new feature is an elegant way of configuring error page redirects. +All new features are documented on the documentation page about +configuring IIS. +

+

Enhanced Status Worker

+

+The +status worker +now can also manage and show statistics for AJP workers that +are not part of a load balancer. Other improvements are the new dump +action, the integration of the new configuration attributes, showing average +request and transfer rates since the last statistics reset and the ability to +display only a single member of a load balancer. +

+

+Unfortunately we had to change +some request parameters +used for the update action of the status worker. +

+

Miscellaneous Improvements

+

+Further enhancements are: +

    +
  • +Configurable session stickyness indicator: cookie name and URL path +parameter name can be freely chosen instead of the servlet spec compliant +JSESSIONID and ;jsessionid. +
  • +
  • +Automatically determining the size of the shared memory segment needed +to accommodate all workers. +
  • +
  • +New connection establishment timeout socket_connect_timeout. +
  • +
  • +New timeout connection_acquire_timeout for acquiring a free connection from +the pool. +
  • +
  • +Improved retry handling by adjusting the meaning of the attribute retries for +AJP workers and for load balancers and by adding the new retry_interval. +
  • +
  • +Allowing the web server to provide error pages instead of Tomcat. +
  • +
+

+
+

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/printer/20090301.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/printer/20090301.html new file mode 100644 index 00000000..eb54c79e --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/printer/20090301.html @@ -0,0 +1,62 @@ +The Apache Tomcat Connector - News - 2009 News and Status
Apache TomcatApache Logo

The Apache Tomcat Connector - News

2009 News and Status

2009 News & Status
+
+
22 March - JK-1.2.28 released
+ +
+

The Apache Tomcat team is proud to announce the immediate availability +of Tomcat Connectors 1.2.28. This is a stable release concentrating mainly on +some bug fixes. +

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. +

+

+The most important new features in this version are: +

+

Better Error Detection for Load Balancer Workers

+

+Local and global error states have been improved. You can fine tune the +behaviour with the new "error_escalation_time" attribute +(see the timeouts documentation). +

+

Dynamic Address and Port Change Using the Status Worker

+

+The status worker now allows you to change the address and the port +of an AJP13 worker on the fly. You can e.g. provision dummy workers with a port +equal to "0", which will be automatically put into stopped mode during startup. +Later, when you want to actually use thse workers, you set their address and +port to the final values. +

+

+Note that already existing connections will go on using the old +address and port. This will be improved in future versions. +

+

New Data in Status Worker Display

+

+The status worker display now also contains the timestamp of the last +worker errors. +

+

Improved Proxy Flexibility

+

+You can now overwrite more request metadata before the request gets send to the backend. +This is helpful in case there are other reverse proxies in front of your web server. +A new documentation page explains this in detail. +

+

Improved IIS Support

+

+IIS support has been improved especially when using mutltiple application pools. +Furthermore you can now configure the ISAPI plugin to update the uriworkermap.properies +file on a regular interval using the watchdog thread. +

+

JNI Worker Deprecation

+

+Workers of type jni are broken since a long time. Since there is no more +use for them, they have been deprecated now, and will be removed in a future release. +

+
+

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/printer/20100101.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/printer/20100101.html new file mode 100644 index 00000000..bc57d826 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/printer/20100101.html @@ -0,0 +1,61 @@ +The Apache Tomcat Connector - News - 2010 News and Status
Apache TomcatApache Logo

The Apache Tomcat Connector - News

2010 News and Status

2010 News & Status
+
+
1 November - JK-1.2.31 released
+ +
+

The Apache Tomcat team is proud to announce the immediate availability + of Tomcat Connectors 1.2.31. This is a stable release concentrating mainly on + some bug fixes. +

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the + Bugzilla + Bug Report. +

+
+ +
+
1 March - JK-1.2.30 released
+ +
+

The Apache Tomcat team is proud to announce the immediate availability +of Tomcat Connectors 1.2.30. This is a stable release concentrating mainly on +some bug fixes. +

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. +

+
+ +
+
1 March - JK-1.2.29 withdrawn
+ +
+

Tomcat Connectors 1.2.29 has been withdrawn because of regression inside +Microsoft IIS connector. +

+
+ +
+
26 February - JK-1.2.29 released
+ +
+

The Apache Tomcat team is proud to announce the immediate availability +of Tomcat Connectors 1.2.29. This is a stable release concentrating mainly on +some bug fixes. +

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the +Bugzilla +Bug Report. +

+ +
+

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/printer/20110701.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/printer/20110701.html new file mode 100644 index 00000000..5576fd6c --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/news/printer/20110701.html @@ -0,0 +1,21 @@ +The Apache Tomcat Connector - News - 2011 News and Status
Apache TomcatApache Logo

The Apache Tomcat Connector - News

2011 News and Status

2011 News & Status
+
+ +
8 July - JK-1.2.32 released
+ +
+

The Apache Tomcat team is proud to announce the immediate availability + of Tomcat Connectors 1.2.32. This is a stable release concentrating mainly on + some bug fixes. +

+ Please see the ChangeLog for a full list of changes. +

+

If you find any bugs while using this release, please fill in the + Bugzilla + Bug Report. +

+
+ +

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/printer/index.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/printer/index.html new file mode 100644 index 00000000..5d0e6d83 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/printer/index.html @@ -0,0 +1,250 @@ +The Apache Tomcat Connector - Documentation Index
Apache TomcatApache Logo

The Apache Tomcat Connector

Documentation Index

Introduction
+ +

This is the top-level entry point of the documentation bundle for the +Apache Tomcat Connectors + +

+

Select one of the links from the navigation menu (to the left) to drill +down to the more detailed documentation that is available. Each available +manual is described in more detail below.

+ +
Headlines
+
+ +
Reference Guide
+
+
    +
  • workers.properties +

    A Tomcat worker is a Tomcat instance that is waiting to execute servlets +on behalf of some web server. For example, we can have a web server such as Apache +forwarding servlet requests to a Tomcat process (the worker) running behind it. +

    +

    This page contains detailed description of all workers.properties +directives. +

    +
  • + +
  • uriworkermap.properties +

    +The forwarding of requests from the web server to tomcat gets configured by defining mapping rules. +The so-called uriworkermap file is a mechanism of defining those rules. +

    +
  • + +
  • Status Worker +

    +The status worker is a builtin management worker. It displays state information +and can also be used to dynamically reconfigure JK. +

    +
  • + +
  • Apache +

    This page contains detailed description of all directives related to +Apache web server. +

    +
  • + +
  • IIS +

    This page contains detailed description of all IIS directives. +

    +
  • + +
+
Generic HowTo
+
+
    + +
  • Quick Start +

    This page describes the configuration files used by JK on the +Web Server side for the 'impatients'. +

    +
  • +
  • All about workers +

    This page contains an overview about the various aspects of defining +and using workers. +

    +
  • +
  • Timeouts +

    This page describes the possible timeout settings you can use. +

    +
  • +
  • Load Balancing +

    This page contains an introduction on load balancing with JK. +

    +
  • +
  • Reverse Proxy +

    This page contains an introduction to reverse proxies, how JK +handles this situation and how you can influence the JK proxying behaviour. +

    +
  • + +
+
Webserver HowTo
+
+

These pages contain detailed descriptions of how to build and +install JK for the various web servers. +

+ +
AJP Protocol Reference
+
+
    +
  • AJPv13 +

    This page describes the Apache JServ Protocol version 1.3 (hereafter +ajp13). +

    +
  • +
  • AJPv13 Extension Proposal +

    This page describes an extension proposal for ajp13. +

    +
  • +
+ +
Miscellaneous documentation
+
+ + +
News
+
+

Release news from various years. +

+ + +

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/apache.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/apache.html new file mode 100644 index 00000000..9e7a7aa5 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/apache.html @@ -0,0 +1,1011 @@ +The Apache Tomcat Connector - Reference Guide - Configuring Apache
Apache TomcatApache Logo

Links

Reference Guide

Generic HowTo

Webserver HowTo

AJP Protocol Reference

Miscellaneous Documentation

News

The Apache Tomcat Connector - Reference Guide

Configuring Apache

Printer Friendly Version
print-friendly
version +
Configuration Directives
+

+Most of the directives are allowed once in the global part of the Apache httpd +configuration and once in every <VirtualHost> elements. Exceptions from this rule are +explicitly listed in the table below. +

+

+Most values are inherited from the main server to the virtual hosts. +Since version 1.2.20 they can be overwritten in the virtual hosts. +Exceptions from this rule are again explicitly listed in the table below. +See especially JkMountCopy. +

+

+Warning: If Apache httpd and Tomcat are configured to serve content from +the same filing system location then care must be taken to ensure that httpd is +not able to serve inappropriate content such as the contents of the WEB-INF +directory or JSP source code. +

+

+This could occur if the httpd DocumentRoot +overlaps with a Tomcat Host's appBase or the docBase of any Context. It could +also occur when using the httpd Alias directive with a Tomcat Host's appBase or +the docBase of any Context. +

+

+Here are the all directives supported by Apache: +

+
DirectiveDescription
JkWorkersFile

+The name of a worker file for the Tomcat servlet containers. +
+This directive is only allowed once. It must be put into +the global part of the configuration. +
+If you don't use the JkWorkerProperty directives, then you must +define your workers with a valid JkWorkersFile. There is no default +value. +

JkWorkerProperty

+Enables setting worker properties inside Apache configuration file. +The syntax is the same as in the JkWorkersFile (usually workers.properties). +Simply prefix each line with "JkWorkerProperty" to put it directly into +the Apache httpd config files. +
+This directive is allowed multiple times. +It must be put into the global part of the configuration. +
+If you don't use the JkWorkerProperty directives, then you must +define your workers with a valid JkWorkersFile. There is no default +value. +
+This directive is available in jk1.2.7 version and later. +

JkShmFile

+Shared memory file name. Used only on unix platforms. +The shm file is used by balancer and status workers. +
+This directive is only allowed once. It must be put into +the global part of the configuration. +
+The default value is logs/jk-runtime-status. +It is highly recommended that the shm file be placed on a local +drive and not an NFS share. +

+

+The shared memory contains configuration and runtime information for load balancer +workers and their members. It is need in order that all apache children +

    +
  • share the same status information for load balancing members (OK, ERROR, ...),
  • +
  • share the information about load taken by the individual workers,
  • +
  • share the information for the parts of the configuration, which are changeable +during runtime by status workers.
  • +
+

+
JkShmSize

+Size of the shared memory file name. +
+This directive is only allowed once. It must be put into +the global part of the configuration. +
+The default value depends on the platform. It is usually less than 64KB. +

JkMountFile

+File containing multiple mappings from a context to a Tomcat worker. +It is usually called uriworkermap.properties. +
+For inheritance rules, see: JkMountCopy. +
+There is no default value. +

JkMountFileReload

+This directive configures the reload check interval in seconds. +The JkMountFile is checked periodically for changes. +A changed file gets reloaded automatically. If you set +this directive to "0", reload checking is turned off. +
+The default value is 60 seconds. +
+This directive has been added in version 1.2.20 of mod_jk. +

JkMount

+A mount point from a context to a Tomcat worker. +
+This directive is allowed multiple times. +It is allowed in the global configuration and in VirtualHost. +You can also use it inside Location with a different syntax. +Inside Location, one omits the first argument (path), +which gets inherited from the Location. +
+By default JkMount entries are not inherited from the global +server to other VirtualHosts or between VirtualHosts. +For the complete inheritance rules, see: JkMountCopy. +

JkUnMount

+An exclusion mount point from a context to a Tomcat worker. +All exclusion mounts are checked after mapping a request +to a tomcat worker. If the request maps also to an exclusion, +it will not be forwarded to tomcat, and instead be served locally. +
+This directive is allowed multiple times. +It is allowed in the global configuration and in VirtualHost. +You can also use it inside Location with a different syntax. +Inside Location, one omits the first argument (path), +which gets inherited from the Location. +For inheritance rules, see: JkMountCopy. +
+This directive is available in jk1.2.7 version and later. +

JkAutoAlias

+Automatically Alias webapp context directories into the Apache +document space. +
+Care should be taken to ensure that only static content is served via httpd as a +result of using this directive. Any static content served by httpd will bypass any +security constraints defined in the application's web.xml. +
+For inheritance rules, see: JkMountCopy. +
+There is no default value. +

JkMountCopy

+If this directive is set to "On" in some virtual server, +the mounts from the global server will be copied to this +virtual server, more precisely all mounts defined by JkMount +or JkUnMount. The Mounts defined by JkMountFile and JkAutoAlias +will only be inherited, if the VirtualHost does not define +it's own JkMountFile or JkAutoAlias. +
+If you want all vhost to inherit mounts from the main server, +you can set JkMountCopy to 'All' in the main server. +
+This directive is only allowed inside VirtualHost (with value "On") +and in the global server (with value "All"). +
+The default is Off, so no mounts will be inherited from the global +server to any VirtualHost. +
+Starting with version 1.2.26 you can also set it to "All" in the +global virtual server. This will switch the default to On. +

JkWorkerIndicator

+Name of the Apache environment variable that can be used to set worker names +in combination with SetHandler jakarta-servlet. +
+This directive is only allowed once per virtual server. +It is allowed in the global configuration and in VirtualHost. +
+The default value is JK_WORKER_NAME. +

JkWatchdogInterval

+This directive configures the watchdog thread interval in seconds. +The workers are maintained periodically by a background thread +running periodically every watchdog_interval seconds. Worker maintenance +checks for idle connections, corrects load status and is able +to detect backend health status. +
+The maintenance only happens, if since the last maintenance at +least worker.maintain +seconds have passed. So setting the JkWatchdogInterval +much smaller than worker.maintain is not useful. +
+The default value is 0 seconds, meaning the watchdog thread +will not be created, and the maintenance is done in combination +with normal requests instead. +
+This directive is only allowed once. It must be put into +the global part of the configuration. +
+This directive has been added in version 1.2.27 of mod_jk. +It is available only for httpd 2.x and above using APR libraries +including thread support. +

JkLogFile

+Full or server relative path to the Tomcat Connector module log file. +It will also work with pipe, by using a value of the form "| ...". +
+The default value is logs/mod_jk.log. +
+Pipes are supported for Apache 1.3 only since version 1.2.16. +The default value exists only since version 1.2.20. +

JkLogLevel

+The Tomcat Connector module log level, can be debug, info, warn +error or trace. +
+The default value is info. +

JkLogStampFormat

+The Tomcat Connector module date log format, using an +extended strftime syntax. +This format will be used for the time stamps in the JkLogFile. +The maximum length of the format is 63 characters. +
+Starting with version 1.2.24 of mod_jk you can also use %Q +for adding milliseconds to the log and %q for microseconds. +These conversion specifiers are an extension to strftime. +They will only work on platforms with a gettimeofday() function. +You can use %Q and %q only once in the pattern and also not both +together in the same pattern. +
+The default value is "[%a %b %d %H:%M:%S %Y] " and beginning +with version 1.2.24 on platforms with a gettimeofday() +function it is "[%a %b %d %H:%M:%S.%Q %Y] ". +

JkRequestLogFormat

+Request log format string. See detailed description below. +
+There is no default value. Without defining a value, the request logging +is turned off. +

JkExtractSSL

+Turns on SSL processing and information gathering by mod_jk +
+The default value is On. +
+In order to make SSL data available for mod_jk in Apache, you need to +set SSLOptions +StdEnvVars. For the certificate information you also need +to add SSLOptions +ExportCertData. +

+

+ Specifically, mod_jk will export the following environment variables from + Apache httpd to Tomcat under these request attributes as per the + Servlet Specification 3.0, section 3.8: +

+ + + + + + + + + + + + + + + + + + + + + + + + + + +
Env VarRequest Attribute NameTypeExample
SSL_CIPHER
(or JkKEYSIZEIndicator)
javax.servlet.request.cipher_suitejava.lang.StringDHE-RSA-AES256-SHA
SSL_CIPHER_USEKEYSIZE
(or JkKEYSIZEIndicator)
javax.servlet.request.key_sizejava.lang.Integer256
SSL_SESSION_ID
(or JkSESSIONIndicator)
javax.servlet.request.ssl_sessionjava.lang.String905...32E (a hex string)
SSL_CLIENT_CERT_CHAIN_n
(or JkCERTCHAINPrefixn)
javax.servlet.request.X509Certificatejava.security.X509Certificate[](A chain of certs in ascending order of trust, the first one being + ths client's certificate, the second being the signer of that + certificate, and so on)
+

+ For all other SSL-related variables, use JkEnvVar for each + variable you want. Please note that, like JkEnvVar, these + variables are available from the request attributes, not as + environment variables or as request headers. +

+
JkHTTPSIndicator

+Name of the Apache environment variable that contains SSL indication. +
+The default value is "HTTPS". +

JkCERTSIndicator

+Name of the Apache environment variable that contains SSL client certificates. +
+The default value is "SSL_CLIENT_CERT". +

JkCIPHERIndicator

+Name of the Apache environment variable that contains SSL client cipher. +
+The default value is "SSL_CIPHER". +

JkCERTCHAINPrefix

+Name of the Apache environment (prefix) that contains SSL client chain certificates. +
+The default value is "SSL_CLIENT_CERT_CHAIN_". +

JkSESSIONIndicator

+Name of the Apache environment variable that contains SSL session. +
+The default value is "SSL_SESSION_ID". +

JkKEYSIZEIndicator

+Name of the Apache environment variable that contains SSL key size in use. +
+The default value is "SSL_CIPHER_USEKEYSIZE". +

JkLocalNameIndicator

+Name of the Apache environment variable which can be used to overwrite +the forwarded local name. +Use this only if you need to adjust the data (see the +proxy documentation). +
+The default value is "JK_LOCAL_NAME". +
+This directive has been added in version 1.2.28 of mod_jk. +

JkLocalPortIndicator

+Name of the Apache environment variable which can be used to overwrite +the forwarded local port. +Use this only if you need to adjust the data (see the +proxy documentation). +
+The default value is "JK_LOCAL_PORT". +
+This directive has been added in version 1.2.28 of mod_jk. +

JkRemoteHostIndicator

+Name of the Apache environment variable which can be used to overwrite +the forwarded remote (client) host name. +Use this only if you need to adjust the data (see the +proxy documentation). +
+The default value is "JK_REMOTE_HOST". +
+This directive has been added in version 1.2.28 of mod_jk. +

JkRemoteAddrIndicator

+Name of the Apache environment variable which can be used to overwrite +the forwarded remote (client) IP address. +Use this only if you need to adjust the data (see the +proxy documentation). +
+The default value is "JK_REMOTE_ADDR". +
+This directive has been added in version 1.2.28 of mod_jk. +

JkRemotePortIndicator

+Name of the Apache environment variable which can be used to overwrite +the forwarded remote (client) IP address. +Use this only if you need to adjust the data (see the +proxy documentation). +
+The default value is "JK_REMOTE_PORT". +
+This directive has been added in version 1.2.32 of mod_jk. +

JkRemoteUserIndicator

+Name of the Apache environment variable which can be used to overwrite +the forwarded user name. +Use this only if you need to adjust the data (see the +proxy documentation). +
+The default value is "JK_REMOTE_USER". +
+This directive has been added in version 1.2.28 of mod_jk. +

JkAuthTypeIndicator

+Name of the Apache environment variable which can be used to overwrite +the forwarded authentication type. +Use this only if you need to adjust the data (see the +proxy documentation). +
+The default value is "JK_AUTH_TYPE". +
+This directive has been added in version 1.2.28 of mod_jk. +

JkOptions

+Set one of more options to configure the mod_jk module. See below for +details about this directive. +
+This directive can be used multiple times per virtual server. +
+The default value is "ForwardURIProxy" since version 1.2.24. +It was "ForwardURICompatUnparsed" in version 1.2.23 and +"ForwardURICompat" until version 1.2.22. +

JkEnvVar

+Adds a name and an optional default value of environment variable +that should be sent to servlet-engine as a request attribute. +If the default value is not given explicitly, the variable +will only be send, if it is set during runtime. +
+The default is empty, so no additional variables will be sent. +
+This directive can be used multiple times per virtual server. +The settings will be merged between the global server and any +virtual server. +
+You can retrieve the variables on Tomcat as request attributes +via request.getAttribute(attributeName). Note that the variables +send via JkEnvVar will not be listed in request.getAttributeNames(). +
+Empty default values are supported since version 1.2.20. +Not sending variables with empty defaults and empty runtime value +has been introduced in version 1.2.21. +

JkStripSession

+If this directive is set to On in some virtual server, +the session IDs ;jsessionid=... will be +removed for non matched URLs. +
+This directive is only allowed inside VirtualHost. +
+The default is Off. +
+This directive has been introduced in version 1.2.21. +
With version 1.2.27 and later this directive can have optional +session ID identifier. If not specified it defaults to +;jsessionid. +

+
+
Configuration Directives Types
+

+We'll discuss here the mod_jk directive types. +

+ +
Define workers
+

+JkWorkersFile specify the location where mod_jk will find the workers definitions. +Take a look at Workers documentation for detailed description. + +

+  JkWorkersFile     /etc/httpd/conf/workers.properties
+
+ +
+
+

+ +
+ +
Logging
+

+JkLogFile specify the location where mod_jk is going to place its log file. +

+ +
+  JkLogFile     /var/log/httpd/mod_jk.log
+
+ +

+Since JK 1.2.3 for Apache 2.x and JK 1.2.16 for Apache 1.3 this can also +be used for piped logging: +

+ +
+  JkLogFile     "|/usr/bin/rotatelogs /var/log/httpd/mod_jk.log 86400"
+
+ +

+JkLogLevel +set the log level between : +

+ +
    +
  • +info log will contain standard mod_jk activity (default). +
  • +
  • +warn log will contain non fatal error reports. +
  • +
  • +error log will contain also error reports. +
  • +
  • +debug log will contain all information on mod_jk activity +
  • +
  • +trace log will contain all tracing information on mod_jk activity +
  • +
+ +
  
+  JkLogLevel    info
+
+ +

+info should be your default selection for normal operations. +
+
+

+ +

+JkLogStampFormat will configure the date/time format found on mod_jk log file. +Using the strftime() format string it's set by
+default to "[%a %b %d %H:%M:%S %Y]" +

+ +
+  JkLogStampFormat "[%a %b %d %H:%M:%S %Y] "
+
+ +

+
+
+

+ +

+JkRequestLogFormat will configure the format of mod_jk individual request logging. +Request logging is configured and enabled on a per virtual host basis. +To enable request logging for a virtual host just add a JkRequestLogFormat config. +The syntax of the format string is similar to the Apache LogFormat command, +here is a list of the available request log format options: +

+ +

+
OptionsDescription
%bBytes sent, excluding HTTP headers (CLF format)
%BBytes sent, excluding HTTP headers
%HThe request protocol
%mThe request method
%pThe canonical Port of the server serving the request
%qThe query string (prepended with a ? if a query string exists, otherwise an empty string)
%rFirst line of request
%sRequest HTTP status code
%TRequest duration, elapsed time to handle request in seconds '.' micro seconds
%UThe URL path requested, not including any query string.
%vThe canonical ServerName of the server serving the request
%VThe server name according to the UseCanonicalName setting
%wTomcat worker name
%RReal worker name
+ +

+  JkRequestLogFormat     "%w %V %T"
+
+ +
+
+

+ +

+You can also log mod_jk information using the Apache standard module mod_log_config. +The module sets several notes in the Apache httpd notes table. +Most of them are are only useful in combination with a load balancer worker. +

+ +

+
NoteDescription
JK_WORKER_NAMEName of the worker selected by the URI mapping
JK_WORKER_TYPEType of the worker selected by the URI mapping
JK_WORKER_ROUTEActual worker name selected by the URI mapping (usually a member of the load balancer).
+ Before version 1.2.26 only available if JkRequestLogFormat is set.
JK_REQUEST_DURATIONRequest duration in seconds and microseconds.
+ Before version 1.2.26 only available if JkRequestLogFormat is set.
JK_LB_FIRST_NAMELoad-Balancer: Name of the first worker tried
JK_LB_FIRST_TYPELoad-Balancer: Type of the first worker tried
JK_LB_FIRST_ACCESSEDLoad-Balancer: Access count for the first worker tried
JK_LB_FIRST_READLoad-Balancer: Bytes read for the first worker tried
JK_LB_FIRST_TRANSFERREDLoad-Balancer: Bytes transferred for the first worker tried
JK_LB_FIRST_ERRORSLoad-Balancer: Error count for the first worker tried
JK_LB_FIRST_BUSYLoad-Balancer: Busy count for the first worker tried
JK_LB_FIRST_ACTIVATIONLoad-Balancer: Activation state for the first worker tried
JK_LB_FIRST_STATELoad-Balancer: Error state for the first worker tried
JK_LB_LAST_NAMELoad-Balancer: Name of the last worker tried
JK_LB_LAST_TYPELoad-Balancer: Type of the last worker tried
JK_LB_LAST_ACCESSEDLoad-Balancer: Access count for the last worker tried
JK_LB_LAST_READLoad-Balancer: Bytes read for the last worker tried
JK_LB_LAST_TRANSFERREDLoad-Balancer: Bytes transferred for the last worker tried
JK_LB_LAST_ERRORSLoad-Balancer: Error count for the last worker tried
JK_LB_LAST_BUSYLoad-Balancer: Busy count for the last worker tried
JK_LB_LAST_ACTIVATIONLoad-Balancer: Activation state for the last worker tried
JK_LB_LAST_STATELoad-Balancer: Error state for the last worker tried
+ +

+  LogFormat     "%h %l %u %t \"%r\" %>s %b %{JK_WORKER_NAME}n %{JK_LB_FIRST_NAME}n \
+                 %{JK_LB_FIRST_BUSY}n %{JK_LB_LAST_NAME}n %{JK_LB_LAST_BUSY}n" mod_jk_log
+  CustomLog     logs/access_log     mod_jk_log
+
+ +
+
+

+ +
+ +
Forwarding
+

+The directive JkOptions allow you to set many forwarding options which will enable (+) +or disable (-) following option. Without any leading signs, options will be enabled. +
+
+

+ +

+The four following options +ForwardURIxxx are mutually exclusive. +Exactly one of them is required, a negative sign prefix is not allowed with them. +The default value is "ForwardURIProxy" since version 1.2.24. +It was "ForwardURICompatUnparsed" in version 1.2.23 and +"ForwardURICompat" until version 1.2.22. +You can turn the default off by switching on one of the other two options. +You should leave this at it's default value, unless you have a very good +reason to change it. +
+
+

+ +

+All options are inherited from the global server to virtual hosts. +Options that support enabling (plus options) and disabling (minus options), +are inherited in the following way: +
+
+options(vhost) = plus_options(global) - minus_options(global) + plus_options(vhost) - minus_options(vhost) +
+
+

+ +

+Using JkOptions ForwardURIProxy, the forwarded URI +will be partially reencoded after processing inside Apache httpd and +before forwarding to Tomcat. This will be compatible with local +URL manipulation by mod_rewrite and with URL encoded session ids. + +

+  JkOptions     +ForwardURIProxy
+
+ +
+
+

+ +

+Using JkOptions ForwardURICompatUnparsed, the forwarded URI +will be unparsed. It's spec compliant and secure. +It will always forward the original request URI, so rewriting +URIs with mod_rewrite and then forwarding the rewritten URI +will not work. + +

+  JkOptions     +ForwardURICompatUnparsed
+
+ +
+
+

+ +

+Using JkOptions ForwardURICompat, the forwarded URI will +be decoded by Apache httpd. Encoded characters will be decoded and +explicit path components like ".." will already be resolved. +This is less spec compliant and is not safe if you are using +prefix JkMount. This option will allow to rewrite URIs with +mod_rewrite before forwarding. + +

+  JkOptions     +ForwardURICompat
+
+ +
+
+

+ +

+Using JkOptions ForwardURIEscaped, the forwarded URI will +be the encoded form of the URI used by ForwardURICompat. +Explicit path components like ".." will already be resolved. +This will not work in combination with URL encoded session IDs, +but it will allow to rewrite URIs with mod_rewrite before forwarding. + +

+  JkOptions     +ForwardURIEscaped
+
+ +
+
+

+ +

+JkOptions RejectUnsafeURI will block all +URLs, which contain percent signs '%' or backslashes '\' +after decoding. +
+
+

+

+Most web apps do not use such URLs. Using the option RejectUnsafeURI, you +can block several well known URL encoding attacks. By default, this option +is not set. +

+

+You can also realise such a check with mod_rewrite, which is more powerful +but also slightly more complicated. + +

  
+  JkOptions     +RejectUnsafeURI
+
+ +
+
+

+ +

+JkOptions ForwardDirectories is used in conjunction with DirectoryIndex +directive of Apache web server. As such mod_dir should be available to Apache, +statically or dynamically (DSO) +
+
+

+ +

+When DirectoryIndex is configured, Apache will create sub-requests for +each of the local-url's specified in the directive, to determine if there is a +local file that matches (this is done by stat-ing the file). +

+ +

+If ForwardDirectories is set to false (default) and Apache doesn't find any +files that match, Apache will serve the content of the directory (if directive +Options specifies Indexes for that directory) or a 403 Forbidden response (if +directive Options doesn't specify Indexes for that directory). +

+ +

+If ForwardDirectories is set to true and Apache doesn't find any files that +match, the request will be forwarded to Tomcat for resolution. This is used in +cases when Apache cannot see the index files on the file system for various +reasons: Tomcat is running on a different machine, the JSP file has been +precompiled etc. +

+ +

Note that locally visible files will take precedence over the +ones visible only to Tomcat (i.e. if Apache can see the file, that's the one +that's going to get served). This is important if there is more then one type of +file that Tomcat normally serves - for instance Velocity pages and JSP pages. + +

  
+  JkOptions     +ForwardDirectories
+
+
+
+

+ +

+JkOptions ForwardLocalAddress, you ask mod_jk to send the local address, +of the Apache web server instead remote client address. This can be used by +Tomcat remote address valve for allowing connections only from registered Apache +web servers. + +

  
+  JkOptions     +ForwardLocalAddress
+
+ +
+
+

+ +

+JkOptions FlushPackets, you ask mod_jk to flush Apache's connection +buffer after each AJP packet chunk received from Tomcat. This option can have +a strong performance penalty for Apache and Tomcat as writes are performed +more often than would normally be required (ie: at the end of each +response). + +

  
+  JkOptions     +FlushPackets
+
+ +
+
+

+ +

+JkOptions FlushHeader, you ask mod_jk to flush Apache's connection +buffer after the response headers have been received from Tomcat. + +

  
+  JkOptions     +FlushHeader
+
+ +
+
+

+ +

+JkOptions DisableReuse, you ask mod_jk to close connections immediately +after their use. Normally mod_jk uses persistent connections and pools idle +connections to reuse them, when new requests have to be sent to Tomcat. +

+ +

+Using this option will have a strong performance penalty for Apache and Tomcat. +Use this only as a last resort in case of unfixable network problems. +If a firewall between Apache and Tomcat silently kills idle connections, +try to use the worker attribute socket_keepalive in combination with an appropriate +TCP keepalive value in your OS. + +

  
+  JkOptions     +DisableReuse
+
+ +
+
+

+ +

+JkOptions ForwardKeySize, you ask mod_jk, when using ajp13, to forward also the SSL Key Size as +required by Servlet API 2.3. +This flag shouldn't be set when servlet engine is Tomcat 3.2.x (on by default). + +

  
+  JkOptions     +ForwardKeySize
+
+ +
+
+

+ +

+JkOptions ForwardSSLCertChain, you ask mod_jk, when using ajp13, +to forward SSL certificate chain (off by default). +Mod_jk only passes the SSL_CLIENT_CERT to the AJP connector. This is not a +problem with self-signed certificates or certificates directly signed by the +root CA certificate. However, there's a large number of certificates signed by +an intermediate CA certificate, where this is a significant problem: A servlet +will not have the possibility to validate the client certificate on its own. The +bug would be fixed by passing on the SSL_CLIENT_CERT_CHAIN to Tomcat via the AJP connector. +
+This directive exists only since version 1.2.22. +

  
+  JkOptions     +ForwardSSLCertChain
+
+ +
+
+

+ +

+The directive JkEnvVar allows you to forward environment variables +from Apache server to Tomcat engine. +You can add a default value as a second parameter to the directive. +If the default value is not given explicitly, the variable +will only be send, if it is set during runtime. +
+The variables can be retrieved on the Tomcat side as request attributes +via request.getAttribute(attributeName). +Note that the variables send via JkEnvVar will not be listed +in request.getAttributeNames(). +
+
+The variables are inherited from the global server to virtual hosts. + +

  
+  JkEnvVar     SSL_CLIENT_V_START     undefined
+
+
+
+

+ +
+ +
Assigning URLs to Tomcat
+

+If you have created a custom or local version of mod_jk.conf-local as noted above, +you can change settings such as the workers or URL prefix. +

+

+JkMount directive assign specific URLs to Tomcat. +In general the structure of a JkMount directive is: +

+ +
  
+  JkMount [URL prefix] [Worker name]
+
+ +
+  # send all requests ending in .jsp to worker1
+  JkMount /*.jsp worker1
+  # send all requests ending /servlet to worker1
+  JkMount /*/servlet/ worker1
+  # send all requests jsp requests to files located in /otherworker will go worker2
+  JkMount /otherworker/*.jsp worker2
+
+ +

+You can use the JkMount directive at the top level or inside <VirtualHost> +sections of your httpd.conf file. +

+

JkUnMount directive acts as an opposite to JkMount and blocks access +to a particular URL. The purpose is to be able to filter out the particular content +types from mounted context. The following example mounts /servlet/* +context, but all .gif files that belongs to that context are not served. +

+
+  # send all requests ending with /servlet to worker1
+  JkMount /servlet/* worker1
+  # do not send requests ending with .gif to worker1
+  JkUnMount /servlet/*.gif worker1
+
+

+JkUnMount takes precedence over JkMount directives, meaning that the JK +will first try to mount and then checks, if there is an exclusion defined by a +JkUnMount. A JkUnMount overrides a JkMount only, if the worker names in the +JkMount and in the JkUnMount are the same. +

+

+The following example will block all .gif files although there is a JkMount for them: +

+
+  # do not send requests ending with .gif to worker1
+  JkUnMount /*.gif worker1
+  # The .gif files will not be mounted cause JkUnMount takes
+  # precedence over JkMount directive
+  JkMount /servlet/*.gif worker1
+
+

+Starting with version 1.2.26 of JK you can apply a JkUnMount to any worker, +by using the star character '*' as the worker name in the JkUnMount. +More complex patterns in JkUnMount worker names are not allowed. +

+
+  # Mapping the webapps myapp1 and myapp2:
+  /myapp1/*=worker1
+  /myapp2/*=worker2
+  # Exclude the all subdirectories static for all workers:
+  !/*/static/*=*
+  # Exclude some suffixes for all workers:
+  !*.html=*
+
+

+JkAutoAlias directive automatically Alias webapp context directories into +the Apache document space. It enables Apache to serve a static context while Tomcat +serving dynamic context. This directive is used for convenience so that you don't +have to put an apache Alias directive for each application directory inside Tomcat's +webapp directory. For security reasons is is strongly recommended that JkMount +is used to pass all requests to Tomcat by default and JkUnMount is used to +explicitly exclude static content to be served by httpd. It should also be noted +that content served by httpd will bypass any security constraints defined in the +application's web.xml. +

+
+  # enter the full path to the tomcat webapps directory
+  JkAutoAlias /opt/tomtact/webapps
+
+

The following example shows how to serve a dynamic context by +Tomcat and static using Apache. The webapps directory has to +be accessible by apache.

+ +
+  # enter the full path to the tomcat webapps directory
+  JkAutoAlias /opt/tomtact/webapps
+
+  # Mount 'servlets-examples' directory. It's physical location
+  # is assumed to be in the /opt/tomtact/webapps/servlets-examples
+  # ajp13w is a worker defined in the workers.properties
+  JkMount /servlets-examples/* ajp13w
+
+  # Unmount desired static content from servlets-examples webapp.
+  # This content will be served by the httpd directly.
+  JkUnMount /servlets-examples/*.gif ajp13w
+  JkUnMount /servlets-examples/*.jpg ajp13w
+
+

Note that you can have a single JkAutoAlias directive per virtual +host inside your httpd.conf +

+

+JkWorkerProperty is a new directive available from JK 1.2.7 +version. It is a convenient method for setting directives that are +usually set inside workers.propeties file. The parameter for +that directive is raw line from workers.properties file. +

+
+  # Just like workers.properties but exact line is prefixed
+  # with JkWorkerProperty
+
+  # Minimal jk configuration
+  JkWorkerProperty worker.list=ajp13w
+  JkWorkerProperty worker.ajp13w.type=ajp13
+  JkWorkerProperty worker.ajp13w.host=localhost
+  JkWorkerProperty worker.ajp13w.port=8009   
+
+

+JkMountFile is a new directive available from JK 1.2.9 +version. It is used for dynamic updates of mount points at runtime. +When the mount file is changed, JK will reload it's content. +

+
+  # Load mount points
+
+  JkMountFile conf/uriworkermap.properties
+
+

If the mount point uri starts with an exclamation mark '!' +it defines an exclusion in the same way JkUnMount does. +If the mount point uri starts with minus sign '-' +the mount point will only be disabled. A disabled mount can be reenabled +by deleting the minus sign and waiting for the JkMountFile to reload. +An exclusion can be disabled by prefixing it with a minus sign. +

+
+  # Sample uriworkermap.properties file
+
+  /servlets-examples/*=ajp13w
+  # Do not map .jpeg files
+  !/servlets-examples/*.jpeg=ajp13w
+  # Make jsp examples initially disabled  
+  -/jsp-examples/*=ajp13w
+
+

At run time you can change the content of this file. For example +removing minus signs will enable the previously disabled uri mappings. +You can add any number of new entries at runtime that reflects the newly deployed +applications. Apache will reload the file and update the mount +points within 60 second interval. +

+

+There is no way to delete entries by dynamic reloading, but you can disable or +exclude mappings. +
+
+

+ +
+ +
Using SetHandler and Environment Variables
+

+Alternatively to the mod_jk specific directives, you can also use +SetHandler and environment variables to control, which requests +are being forwarded via which worker. This gives you more flexibility, +but the results might be more difficult to understand. If you mix both +ways of defining the forwards, in general to mod_jk directives will win. +

+

+SetHandler jakarta-servlet forces requests to be handled by mod_jk. +If you neither specify any workers via JkMount and the related directives, +not via the environment variable described below, +the first worker in the list of all worker will be chosen. You can use SetHandler +for example in Location blocks or with Apache 2.2 also in RewriteRule. +

+

+In order to control the worker using SetEnvIf or RewriteRule +for more complex rules, you can set the environment variable JK_WORKER_NAME +to the name of your chosen target worker. This enables you to decide on +the chosen worker in a more flexible way, including dependencies on cookie values. +This feature has been added in version 1.2.19 of mod_jk. +

+

+In order to use another variable than JK_WORKER_NAME, you can set the name +of this variable via the JkWorkerIndicator directive. +

+

+You can also define exclusions from mod_jk forwards by setting the environment +variable no-jk. +

+
+  # Automatically map all encoded urls
+  <Location *;jsessionid=>
+    SetHandler jakarta-servlet
+    SetEnv JK_WORKER_NAME my_worker
+  </Location>
+
+  # Map all subdirs to workers via naming rule
+  # and exclude static content.
+  <Location /apps/>
+    SetHandler jakarta-servlet
+    SetEnvIf REQUEST_URI ^/apps/([^/]*)/ JK_WORKER_NAME=$1
+    SetEnvIf REQUEST_URI ^/apps/([^/]*)/static no-jk
+  </Location>
+
+

+Finally, starting with version 1.2.27 you can use the environment variable +JK_REPLY_TIMEOUT to dynamically set a reply timeout. +

+
+

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/iis.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/iis.html new file mode 100644 index 00000000..e767d281 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/iis.html @@ -0,0 +1,332 @@ +The Apache Tomcat Connector - Reference Guide - Configuring IIS
Apache TomcatApache Logo

Links

Reference Guide

Generic HowTo

Webserver HowTo

AJP Protocol Reference

Miscellaneous Documentation

News

The Apache Tomcat Connector - Reference Guide

Configuring IIS

Printer Friendly Version
print-friendly
version +
Requirements
+

+The Tomcat redirector requires three entities: + +

    +
  • +isapi_redirect.dll - The IIS server plugin, either obtain a pre-built DLL or build it yourself (see the build section). +
  • +
  • +workers.properties - A file that describes the host(s) and port(s) used by the workers (Tomcat processes). +A sample workers.properties can be found under the conf directory. +
  • +
  • +uriworkermap.properties - A file that maps URL-Path patterns to workers. +A sample uriworkermap.properties can be found under the conf directory as well. +
  • +
+

+ +

+The installation includes the following parts: + +

    +
  • +Configuring the ISAPI redirector with a default /examples context and checking that you can serve servlets with IIS. +
  • +
  • +Adding more contexts to the configuration. +
  • +
+

+
Registry settings
+

+ISAPI redirector reads configuration from the registry, create a new registry key named : +

+

+"HKEY_LOCAL_MACHINE\SOFTWARE\Apache Software Foundation\Jakarta Isapi Redirector\1.0" +

+
Key NameDescription
extension_uri

+A string value pointing to the ISAPI extension /jakarta/isapi_redirect.dll +

log_file

+A value pointing to location where log file will be created. +(for example c:\tomcat\logs\isapi.log) +
If one of the log rotation settings (log_rotationtime or log_filesize) are specified then the actual log file name is based on this setting. +If the log file name includes any '%' characters, then it is treated as a format string for strftime(3), +e.g. c:\tomcat\logs\isapi-%Y-%m-%d-%H_%M_%S.log. Otherwise, the suffix .nnnnnnnnnn is automatically added and is the time in seconds. +A full list of format string substitutions can be found in the Apache rotatelogs documentation +

log_level

+A string value for log level +(can be debug, info, warn, error or trace).

+

This directive was added in version 1.2.31

+
log_rotationtime

+The time between log file rotations in seconds. +Setting this to 0 (the default) disables log rotation based on time.

+

This directive was added in version 1.2.31

+
log_filesize

+The maximum log file size in megabytes, after which the log file will be rotated. Setting this to 0 (the default) disables log rotation based on file size. +
The value can have an optional M suffix, i.e. both 5 and 5M will rotate the log file when it grows to 5MB. +
If log_rotationtime is specified, then this setting is ignored. +

worker_file

+A string value which is the full path to workers.properties file +(for example c:\tomcat\conf\workers.properties) +

worker_mount_file

+A string value which is the full path to uriworkermap.properties file +(for example c:\tomcat\conf\uriworkermap.properties) +

rewrite_rule_file

+A string value which is the full path to rewrite.properties file +(for example c:\tomcat\conf\rewrite.properties) +

shm_size

+A DWORD value size of the shared memory. Set this value to be +the number of all defined workers * 400. +(Set this value only if you have more then 64 workers) +

+

This directive has been added in version 1.2.20

+

Starting with version 1.2.27 the size of the shared memory is determined +automatically, even for large numbers of workers. This attribute is not +needed any longer.

+
worker_mount_reload

+A DWORD value specifying the time in seconds upon which the +worker_mount_file will be reloaded. +

+

This directive has been added in version 1.2.20

+
strip_session

+A string value representing a boolean. If it is set to true, +URL session suffixes of the form ";jsessionid=..." get stripped of URLs, +even if the are served locally by the web server. +

+

+A true value can be represented by the string "1" or any string starting +with the letters "T" or "t". A false value will be assumed for "0" +or any string starting with "F" or "f". The default value is false. +

+

This directive has been added in version 1.2.21

+
auth_complete

+A DWORD value representing "0" or "1". This is needed because +of minor incompatibilities with IIS 5.1. +

+

+By default its value is 1, which means we use the SF_NOTIFY_AUTH_COMPLETE +event. If you set this to 0, then we use SF_NOTIFY_PREPROC_HEADERS. +This might be needed for IIS 5.1 when handling requests using the +PUT HTTP method. +

+

This directive has been added in version 1.2.21

+
uri_select

+A string value which influences, how URIs are decoded and re-encoded +between IIS and Tomcat. You should leave this at it's default value, +unless you have a very good reason to change it. +

+

+If the value is "parsed", the forwarded URI +will be decoded and explicit path components like ".." will already +be resolved. This is less spec compliant and is not safe +if you are using prefix forwarding rules. +

+

+If the value is "unparsed", the forwarded URI +will be the original request URI. It's spec compliant and also +the safest option. Rewriting the URI and then forwarding the rewritten +URI will not work. +

+

+If the value is "escaped", the forwarded URI +will be the re-encoded form of the URI used by "parsed". +Explicit path components like ".." will already be resolved. +This will not work in combination with URL encoded session IDs. +

+

+If the value is "proxy", the forwarded URI +will be a partially re-encoded form of the URI used by "parsed". +Explicit path components like ".." will already be resolved. +and problematic are re-encoded. +

+

The default value since version 1.2.24 is "proxy". Before it was "parsed".

+
reject_unsafe

+A string value representing a boolean. If it is set to true, +URLs containing percent signs '%' or backslashes '\' +after decoding will be rejected. +

+

+Most web apps do not use such URLs. By enabling "reject_unsafe" you +can block several well known URL encoding attacks. +

+

+A true value can be represented by the string "1" or any string starting +with the letters "T" or "t". A false value will be assumed for "0" +or any string starting with "F" or "f". The default value is false. +

+

This directive has been added in version 1.2.24

+
watchdog_interval

+A DWORD value representing the watchdog thread interval in seconds. +The workers are maintained periodically by a background thread +running periodically every watchdog_interval seconds. Worker maintenance +checks for idle connections, corrects load status and is able +to detect backend health status. +

+

+The maintenance only happens, if since the last maintenance at +least worker.maintain +seconds have passed. So setting the watchdog_interval +much smaller than worker.maintain is not useful. +

+

+The default value is 0 seconds, meaning the watchdog thread +will not be created, and the maintenance is done in combination +with normal requests instead. +

+

This directive has been added in version 1.2.27

+
error_page

+A string value representing the error page url redirection when +backend returns non-200 response. This directive can be used +to customise the error messages returned from backend server. +

+

The url must point to a valid server url and can contain +format string number (%d) that can be used to +separate the pages by error number. The redirect url in that +case is formatted by replacing %d from +error_page to returned error number. +

+

This directive has been added in version 1.2.27

+
enable_chunked_encoding

+A string value representing a boolean. If it is set to true, +chunked encoding is supported by the server. +

+

+A true value can be represented by the string "1" or any string starting +with the letters "T" or "t". A false value will be assumed for "0" +or any string starting with "F" or "f". The default value is false. +

+

This option is considered experimental and its support +must be compile time enabled. Use isapi_redirect.dll +with chunked support enabled. +

+

This directive has been added in version 1.2.27

+
+
Using a properties file for configuration
+

+The ISAPI redirector can read it's configuration from a properties file instead of the registry. +This has the advantage that you can use multiple ISAPI redirectors with independent configurations on the same server. +The redirector will check for the properties file during initialisation, and use it in preference to the registry if present. +

+

+Create a properties file in the same directory as the ISAPI redirector called isapi_redirect.properties i.e. with the same name as the ISAPI redirector DLL but with a .properties extension. A sample isapi_redirect.properties can be found under the conf directory. +

+

+The property names and values in the properties file are the same as for the registry settings described above. For example: +

+

+

+# Configuration file for the Jakarta ISAPI Redirector
+
+# The path to the ISAPI Redirector Extension, relative to the website
+# This must be in a virtual directory with execute privileges
+extension_uri=/jakarta/isapi_redirect.dll
+
+# Full path to the log file for the ISAPI Redirector
+log_file=c:\tomcat\logs\isapi_redirect.log
+
+# Log level (debug, info, warn, error or trace)
+log_level=info
+
+# Full path to the workers.properties file
+worker_file=c:\tomcat\conf\workers.properties
+
+# Full path to the uriworkermap.properties file
+worker_mount_file=c:\tomcat\conf\uriworkermap.properties
+
+

+

+ Notes: +

    +
  • + Back-slashes - '\' - are not escape characters. +
  • +
  • + Comment lines begin with '#'. +
  • +
+

+

Starting with version 1.2.27 two environment variables are +dynamically added to the environment that can be used inside +.properties files. +

    +
  • JKISAPI_PATH - Full path to the ISAPI Redirector. +
  • +
  • JKISAPI_NAME - Name of the ISAPI Redirector dll without extension +
  • +
+

+

+# Use the logs in the installation path of ISAPI Redirector
+log_file=$(ISAPI_PATH)\$(ISAPI_NAME).log
+

+
Log file rotation
+

+The ISAPI redirector with version 1.2.31 can perform log rotation, with configuration and behaviour similar to the +rotatelogs program provided with Apache HTTP Server. +

+

+To configure log rotation, configure a log_file, and one of the log_rotationtime or log_filesize options. +If both are specified, the log_rotationtime will take precedence, and log_filesize will be ignored. +
For example, to configure daily rotation of the log file: +

+
+# Configuration file for the Jakarta ISAPI Redirector
+...
+
+# Full path to the log file for the ISAPI Redirector
+log_file=c:\tomcat\logs\isapi_redirect.%Y-%m-%d.log
+
+# Log level (debug, info, warn, error or trace)
+log_level=info
+
+# Rotate the log file every day
+log_rotationtime=86400
+
+...
+
+

+Or to configure rotation of the log file when it reaches 5MB in size: +

+
+# Configuration file for the Jakarta ISAPI Redirector
+...
+
+# Full path to the log file for the ISAPI Redirector
+log_file=c:\tomcat\logs\isapi_redirect.%Y-%m-%d-%H.log
+
+# Log level (debug, info, warn, error or trace)
+log_level=info
+
+# Rotate the log file at 5 MB
+log_filesize=5M
+
+...
+
+

+The log will be rotated whenever the configured limit is reached, but only if the log file name would change. If you configure + a log file name with strftime(3) format codes in it, then ensure it specifies the same granularity + as the rotation time configured, e.g. %Y-%m-%d if rotating daily (log_rotationtime=86400). +
See the rotatelogs documentation for more examples. +

+ +
Using a simple rewrite rules
+

+The ISAPI redirector with version 1.2.16 can do a simple URL rewriting. Although not +as powerful as Apache Httpd's mod_rewrite, it allows a simple exchange of request URIs +

+

+The rule is in the form original-url-prefix=forward-url-prefix. For example: +

+
+# Simple rewrite rules, making /jsp-examples
+# and /servlets-examples available under shorter URLs
+/jsp/=/jsp-examples/
+/servlets/=/servlets-examples/
+
+

+You can also use regular expressions, if you prefix the rule with a tilde ~: +

+
+# Complex rewrite rule, adding "-examples"
+# to the first path component of all requests
+~/([^/]*)=/$1-examples
+
+

+Note that uriworkermap.properties must use the URLs before rewriting. +

+

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/printer/apache.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/printer/apache.html new file mode 100644 index 00000000..6524e441 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/printer/apache.html @@ -0,0 +1,1010 @@ +The Apache Tomcat Connector - Reference Guide - Configuring Apache
Apache TomcatApache Logo

The Apache Tomcat Connector - Reference Guide

Configuring Apache

Configuration Directives
+

+Most of the directives are allowed once in the global part of the Apache httpd +configuration and once in every <VirtualHost> elements. Exceptions from this rule are +explicitly listed in the table below. +

+

+Most values are inherited from the main server to the virtual hosts. +Since version 1.2.20 they can be overwritten in the virtual hosts. +Exceptions from this rule are again explicitly listed in the table below. +See especially JkMountCopy. +

+

+Warning: If Apache httpd and Tomcat are configured to serve content from +the same filing system location then care must be taken to ensure that httpd is +not able to serve inappropriate content such as the contents of the WEB-INF +directory or JSP source code. +

+

+This could occur if the httpd DocumentRoot +overlaps with a Tomcat Host's appBase or the docBase of any Context. It could +also occur when using the httpd Alias directive with a Tomcat Host's appBase or +the docBase of any Context. +

+

+Here are the all directives supported by Apache: +

+
DirectiveDescription
JkWorkersFile

+The name of a worker file for the Tomcat servlet containers. +
+This directive is only allowed once. It must be put into +the global part of the configuration. +
+If you don't use the JkWorkerProperty directives, then you must +define your workers with a valid JkWorkersFile. There is no default +value. +

JkWorkerProperty

+Enables setting worker properties inside Apache configuration file. +The syntax is the same as in the JkWorkersFile (usually workers.properties). +Simply prefix each line with "JkWorkerProperty" to put it directly into +the Apache httpd config files. +
+This directive is allowed multiple times. +It must be put into the global part of the configuration. +
+If you don't use the JkWorkerProperty directives, then you must +define your workers with a valid JkWorkersFile. There is no default +value. +
+This directive is available in jk1.2.7 version and later. +

JkShmFile

+Shared memory file name. Used only on unix platforms. +The shm file is used by balancer and status workers. +
+This directive is only allowed once. It must be put into +the global part of the configuration. +
+The default value is logs/jk-runtime-status. +It is highly recommended that the shm file be placed on a local +drive and not an NFS share. +

+

+The shared memory contains configuration and runtime information for load balancer +workers and their members. It is need in order that all apache children +

    +
  • share the same status information for load balancing members (OK, ERROR, ...),
  • +
  • share the information about load taken by the individual workers,
  • +
  • share the information for the parts of the configuration, which are changeable +during runtime by status workers.
  • +
+

+
JkShmSize

+Size of the shared memory file name. +
+This directive is only allowed once. It must be put into +the global part of the configuration. +
+The default value depends on the platform. It is usually less than 64KB. +

JkMountFile

+File containing multiple mappings from a context to a Tomcat worker. +It is usually called uriworkermap.properties. +
+For inheritance rules, see: JkMountCopy. +
+There is no default value. +

JkMountFileReload

+This directive configures the reload check interval in seconds. +The JkMountFile is checked periodically for changes. +A changed file gets reloaded automatically. If you set +this directive to "0", reload checking is turned off. +
+The default value is 60 seconds. +
+This directive has been added in version 1.2.20 of mod_jk. +

JkMount

+A mount point from a context to a Tomcat worker. +
+This directive is allowed multiple times. +It is allowed in the global configuration and in VirtualHost. +You can also use it inside Location with a different syntax. +Inside Location, one omits the first argument (path), +which gets inherited from the Location. +
+By default JkMount entries are not inherited from the global +server to other VirtualHosts or between VirtualHosts. +For the complete inheritance rules, see: JkMountCopy. +

JkUnMount

+An exclusion mount point from a context to a Tomcat worker. +All exclusion mounts are checked after mapping a request +to a tomcat worker. If the request maps also to an exclusion, +it will not be forwarded to tomcat, and instead be served locally. +
+This directive is allowed multiple times. +It is allowed in the global configuration and in VirtualHost. +You can also use it inside Location with a different syntax. +Inside Location, one omits the first argument (path), +which gets inherited from the Location. +For inheritance rules, see: JkMountCopy. +
+This directive is available in jk1.2.7 version and later. +

JkAutoAlias

+Automatically Alias webapp context directories into the Apache +document space. +
+Care should be taken to ensure that only static content is served via httpd as a +result of using this directive. Any static content served by httpd will bypass any +security constraints defined in the application's web.xml. +
+For inheritance rules, see: JkMountCopy. +
+There is no default value. +

JkMountCopy

+If this directive is set to "On" in some virtual server, +the mounts from the global server will be copied to this +virtual server, more precisely all mounts defined by JkMount +or JkUnMount. The Mounts defined by JkMountFile and JkAutoAlias +will only be inherited, if the VirtualHost does not define +it's own JkMountFile or JkAutoAlias. +
+If you want all vhost to inherit mounts from the main server, +you can set JkMountCopy to 'All' in the main server. +
+This directive is only allowed inside VirtualHost (with value "On") +and in the global server (with value "All"). +
+The default is Off, so no mounts will be inherited from the global +server to any VirtualHost. +
+Starting with version 1.2.26 you can also set it to "All" in the +global virtual server. This will switch the default to On. +

JkWorkerIndicator

+Name of the Apache environment variable that can be used to set worker names +in combination with SetHandler jakarta-servlet. +
+This directive is only allowed once per virtual server. +It is allowed in the global configuration and in VirtualHost. +
+The default value is JK_WORKER_NAME. +

JkWatchdogInterval

+This directive configures the watchdog thread interval in seconds. +The workers are maintained periodically by a background thread +running periodically every watchdog_interval seconds. Worker maintenance +checks for idle connections, corrects load status and is able +to detect backend health status. +
+The maintenance only happens, if since the last maintenance at +least worker.maintain +seconds have passed. So setting the JkWatchdogInterval +much smaller than worker.maintain is not useful. +
+The default value is 0 seconds, meaning the watchdog thread +will not be created, and the maintenance is done in combination +with normal requests instead. +
+This directive is only allowed once. It must be put into +the global part of the configuration. +
+This directive has been added in version 1.2.27 of mod_jk. +It is available only for httpd 2.x and above using APR libraries +including thread support. +

JkLogFile

+Full or server relative path to the Tomcat Connector module log file. +It will also work with pipe, by using a value of the form "| ...". +
+The default value is logs/mod_jk.log. +
+Pipes are supported for Apache 1.3 only since version 1.2.16. +The default value exists only since version 1.2.20. +

JkLogLevel

+The Tomcat Connector module log level, can be debug, info, warn +error or trace. +
+The default value is info. +

JkLogStampFormat

+The Tomcat Connector module date log format, using an +extended strftime syntax. +This format will be used for the time stamps in the JkLogFile. +The maximum length of the format is 63 characters. +
+Starting with version 1.2.24 of mod_jk you can also use %Q +for adding milliseconds to the log and %q for microseconds. +These conversion specifiers are an extension to strftime. +They will only work on platforms with a gettimeofday() function. +You can use %Q and %q only once in the pattern and also not both +together in the same pattern. +
+The default value is "[%a %b %d %H:%M:%S %Y] " and beginning +with version 1.2.24 on platforms with a gettimeofday() +function it is "[%a %b %d %H:%M:%S.%Q %Y] ". +

JkRequestLogFormat

+Request log format string. See detailed description below. +
+There is no default value. Without defining a value, the request logging +is turned off. +

JkExtractSSL

+Turns on SSL processing and information gathering by mod_jk +
+The default value is On. +
+In order to make SSL data available for mod_jk in Apache, you need to +set SSLOptions +StdEnvVars. For the certificate information you also need +to add SSLOptions +ExportCertData. +

+

+ Specifically, mod_jk will export the following environment variables from + Apache httpd to Tomcat under these request attributes as per the + Servlet Specification 3.0, section 3.8: +

+ + + + + + + + + + + + + + + + + + + + + + + + + + +
Env VarRequest Attribute NameTypeExample
SSL_CIPHER
(or JkKEYSIZEIndicator)
javax.servlet.request.cipher_suitejava.lang.StringDHE-RSA-AES256-SHA
SSL_CIPHER_USEKEYSIZE
(or JkKEYSIZEIndicator)
javax.servlet.request.key_sizejava.lang.Integer256
SSL_SESSION_ID
(or JkSESSIONIndicator)
javax.servlet.request.ssl_sessionjava.lang.String905...32E (a hex string)
SSL_CLIENT_CERT_CHAIN_n
(or JkCERTCHAINPrefixn)
javax.servlet.request.X509Certificatejava.security.X509Certificate[](A chain of certs in ascending order of trust, the first one being + ths client's certificate, the second being the signer of that + certificate, and so on)
+

+ For all other SSL-related variables, use JkEnvVar for each + variable you want. Please note that, like JkEnvVar, these + variables are available from the request attributes, not as + environment variables or as request headers. +

+
JkHTTPSIndicator

+Name of the Apache environment variable that contains SSL indication. +
+The default value is "HTTPS". +

JkCERTSIndicator

+Name of the Apache environment variable that contains SSL client certificates. +
+The default value is "SSL_CLIENT_CERT". +

JkCIPHERIndicator

+Name of the Apache environment variable that contains SSL client cipher. +
+The default value is "SSL_CIPHER". +

JkCERTCHAINPrefix

+Name of the Apache environment (prefix) that contains SSL client chain certificates. +
+The default value is "SSL_CLIENT_CERT_CHAIN_". +

JkSESSIONIndicator

+Name of the Apache environment variable that contains SSL session. +
+The default value is "SSL_SESSION_ID". +

JkKEYSIZEIndicator

+Name of the Apache environment variable that contains SSL key size in use. +
+The default value is "SSL_CIPHER_USEKEYSIZE". +

JkLocalNameIndicator

+Name of the Apache environment variable which can be used to overwrite +the forwarded local name. +Use this only if you need to adjust the data (see the +proxy documentation). +
+The default value is "JK_LOCAL_NAME". +
+This directive has been added in version 1.2.28 of mod_jk. +

JkLocalPortIndicator

+Name of the Apache environment variable which can be used to overwrite +the forwarded local port. +Use this only if you need to adjust the data (see the +proxy documentation). +
+The default value is "JK_LOCAL_PORT". +
+This directive has been added in version 1.2.28 of mod_jk. +

JkRemoteHostIndicator

+Name of the Apache environment variable which can be used to overwrite +the forwarded remote (client) host name. +Use this only if you need to adjust the data (see the +proxy documentation). +
+The default value is "JK_REMOTE_HOST". +
+This directive has been added in version 1.2.28 of mod_jk. +

JkRemoteAddrIndicator

+Name of the Apache environment variable which can be used to overwrite +the forwarded remote (client) IP address. +Use this only if you need to adjust the data (see the +proxy documentation). +
+The default value is "JK_REMOTE_ADDR". +
+This directive has been added in version 1.2.28 of mod_jk. +

JkRemotePortIndicator

+Name of the Apache environment variable which can be used to overwrite +the forwarded remote (client) IP address. +Use this only if you need to adjust the data (see the +proxy documentation). +
+The default value is "JK_REMOTE_PORT". +
+This directive has been added in version 1.2.32 of mod_jk. +

JkRemoteUserIndicator

+Name of the Apache environment variable which can be used to overwrite +the forwarded user name. +Use this only if you need to adjust the data (see the +proxy documentation). +
+The default value is "JK_REMOTE_USER". +
+This directive has been added in version 1.2.28 of mod_jk. +

JkAuthTypeIndicator

+Name of the Apache environment variable which can be used to overwrite +the forwarded authentication type. +Use this only if you need to adjust the data (see the +proxy documentation). +
+The default value is "JK_AUTH_TYPE". +
+This directive has been added in version 1.2.28 of mod_jk. +

JkOptions

+Set one of more options to configure the mod_jk module. See below for +details about this directive. +
+This directive can be used multiple times per virtual server. +
+The default value is "ForwardURIProxy" since version 1.2.24. +It was "ForwardURICompatUnparsed" in version 1.2.23 and +"ForwardURICompat" until version 1.2.22. +

JkEnvVar

+Adds a name and an optional default value of environment variable +that should be sent to servlet-engine as a request attribute. +If the default value is not given explicitly, the variable +will only be send, if it is set during runtime. +
+The default is empty, so no additional variables will be sent. +
+This directive can be used multiple times per virtual server. +The settings will be merged between the global server and any +virtual server. +
+You can retrieve the variables on Tomcat as request attributes +via request.getAttribute(attributeName). Note that the variables +send via JkEnvVar will not be listed in request.getAttributeNames(). +
+Empty default values are supported since version 1.2.20. +Not sending variables with empty defaults and empty runtime value +has been introduced in version 1.2.21. +

JkStripSession

+If this directive is set to On in some virtual server, +the session IDs ;jsessionid=... will be +removed for non matched URLs. +
+This directive is only allowed inside VirtualHost. +
+The default is Off. +
+This directive has been introduced in version 1.2.21. +
With version 1.2.27 and later this directive can have optional +session ID identifier. If not specified it defaults to +;jsessionid. +

+
+
Configuration Directives Types
+

+We'll discuss here the mod_jk directive types. +

+ +
Define workers
+

+JkWorkersFile specify the location where mod_jk will find the workers definitions. +Take a look at Workers documentation for detailed description. + +

+  JkWorkersFile     /etc/httpd/conf/workers.properties
+
+ +
+
+

+ +
+ +
Logging
+

+JkLogFile specify the location where mod_jk is going to place its log file. +

+ +
+  JkLogFile     /var/log/httpd/mod_jk.log
+
+ +

+Since JK 1.2.3 for Apache 2.x and JK 1.2.16 for Apache 1.3 this can also +be used for piped logging: +

+ +
+  JkLogFile     "|/usr/bin/rotatelogs /var/log/httpd/mod_jk.log 86400"
+
+ +

+JkLogLevel +set the log level between : +

+ +
    +
  • +info log will contain standard mod_jk activity (default). +
  • +
  • +warn log will contain non fatal error reports. +
  • +
  • +error log will contain also error reports. +
  • +
  • +debug log will contain all information on mod_jk activity +
  • +
  • +trace log will contain all tracing information on mod_jk activity +
  • +
+ +
  
+  JkLogLevel    info
+
+ +

+info should be your default selection for normal operations. +
+
+

+ +

+JkLogStampFormat will configure the date/time format found on mod_jk log file. +Using the strftime() format string it's set by
+default to "[%a %b %d %H:%M:%S %Y]" +

+ +
+  JkLogStampFormat "[%a %b %d %H:%M:%S %Y] "
+
+ +

+
+
+

+ +

+JkRequestLogFormat will configure the format of mod_jk individual request logging. +Request logging is configured and enabled on a per virtual host basis. +To enable request logging for a virtual host just add a JkRequestLogFormat config. +The syntax of the format string is similar to the Apache LogFormat command, +here is a list of the available request log format options: +

+ +

+
OptionsDescription
%bBytes sent, excluding HTTP headers (CLF format)
%BBytes sent, excluding HTTP headers
%HThe request protocol
%mThe request method
%pThe canonical Port of the server serving the request
%qThe query string (prepended with a ? if a query string exists, otherwise an empty string)
%rFirst line of request
%sRequest HTTP status code
%TRequest duration, elapsed time to handle request in seconds '.' micro seconds
%UThe URL path requested, not including any query string.
%vThe canonical ServerName of the server serving the request
%VThe server name according to the UseCanonicalName setting
%wTomcat worker name
%RReal worker name
+ +

+  JkRequestLogFormat     "%w %V %T"
+
+ +
+
+

+ +

+You can also log mod_jk information using the Apache standard module mod_log_config. +The module sets several notes in the Apache httpd notes table. +Most of them are are only useful in combination with a load balancer worker. +

+ +

+
NoteDescription
JK_WORKER_NAMEName of the worker selected by the URI mapping
JK_WORKER_TYPEType of the worker selected by the URI mapping
JK_WORKER_ROUTEActual worker name selected by the URI mapping (usually a member of the load balancer).
+ Before version 1.2.26 only available if JkRequestLogFormat is set.
JK_REQUEST_DURATIONRequest duration in seconds and microseconds.
+ Before version 1.2.26 only available if JkRequestLogFormat is set.
JK_LB_FIRST_NAMELoad-Balancer: Name of the first worker tried
JK_LB_FIRST_TYPELoad-Balancer: Type of the first worker tried
JK_LB_FIRST_ACCESSEDLoad-Balancer: Access count for the first worker tried
JK_LB_FIRST_READLoad-Balancer: Bytes read for the first worker tried
JK_LB_FIRST_TRANSFERREDLoad-Balancer: Bytes transferred for the first worker tried
JK_LB_FIRST_ERRORSLoad-Balancer: Error count for the first worker tried
JK_LB_FIRST_BUSYLoad-Balancer: Busy count for the first worker tried
JK_LB_FIRST_ACTIVATIONLoad-Balancer: Activation state for the first worker tried
JK_LB_FIRST_STATELoad-Balancer: Error state for the first worker tried
JK_LB_LAST_NAMELoad-Balancer: Name of the last worker tried
JK_LB_LAST_TYPELoad-Balancer: Type of the last worker tried
JK_LB_LAST_ACCESSEDLoad-Balancer: Access count for the last worker tried
JK_LB_LAST_READLoad-Balancer: Bytes read for the last worker tried
JK_LB_LAST_TRANSFERREDLoad-Balancer: Bytes transferred for the last worker tried
JK_LB_LAST_ERRORSLoad-Balancer: Error count for the last worker tried
JK_LB_LAST_BUSYLoad-Balancer: Busy count for the last worker tried
JK_LB_LAST_ACTIVATIONLoad-Balancer: Activation state for the last worker tried
JK_LB_LAST_STATELoad-Balancer: Error state for the last worker tried
+ +

+  LogFormat     "%h %l %u %t \"%r\" %>s %b %{JK_WORKER_NAME}n %{JK_LB_FIRST_NAME}n \
+                 %{JK_LB_FIRST_BUSY}n %{JK_LB_LAST_NAME}n %{JK_LB_LAST_BUSY}n" mod_jk_log
+  CustomLog     logs/access_log     mod_jk_log
+
+ +
+
+

+ +
+ +
Forwarding
+

+The directive JkOptions allow you to set many forwarding options which will enable (+) +or disable (-) following option. Without any leading signs, options will be enabled. +
+
+

+ +

+The four following options +ForwardURIxxx are mutually exclusive. +Exactly one of them is required, a negative sign prefix is not allowed with them. +The default value is "ForwardURIProxy" since version 1.2.24. +It was "ForwardURICompatUnparsed" in version 1.2.23 and +"ForwardURICompat" until version 1.2.22. +You can turn the default off by switching on one of the other two options. +You should leave this at it's default value, unless you have a very good +reason to change it. +
+
+

+ +

+All options are inherited from the global server to virtual hosts. +Options that support enabling (plus options) and disabling (minus options), +are inherited in the following way: +
+
+options(vhost) = plus_options(global) - minus_options(global) + plus_options(vhost) - minus_options(vhost) +
+
+

+ +

+Using JkOptions ForwardURIProxy, the forwarded URI +will be partially reencoded after processing inside Apache httpd and +before forwarding to Tomcat. This will be compatible with local +URL manipulation by mod_rewrite and with URL encoded session ids. + +

+  JkOptions     +ForwardURIProxy
+
+ +
+
+

+ +

+Using JkOptions ForwardURICompatUnparsed, the forwarded URI +will be unparsed. It's spec compliant and secure. +It will always forward the original request URI, so rewriting +URIs with mod_rewrite and then forwarding the rewritten URI +will not work. + +

+  JkOptions     +ForwardURICompatUnparsed
+
+ +
+
+

+ +

+Using JkOptions ForwardURICompat, the forwarded URI will +be decoded by Apache httpd. Encoded characters will be decoded and +explicit path components like ".." will already be resolved. +This is less spec compliant and is not safe if you are using +prefix JkMount. This option will allow to rewrite URIs with +mod_rewrite before forwarding. + +

+  JkOptions     +ForwardURICompat
+
+ +
+
+

+ +

+Using JkOptions ForwardURIEscaped, the forwarded URI will +be the encoded form of the URI used by ForwardURICompat. +Explicit path components like ".." will already be resolved. +This will not work in combination with URL encoded session IDs, +but it will allow to rewrite URIs with mod_rewrite before forwarding. + +

+  JkOptions     +ForwardURIEscaped
+
+ +
+
+

+ +

+JkOptions RejectUnsafeURI will block all +URLs, which contain percent signs '%' or backslashes '\' +after decoding. +
+
+

+

+Most web apps do not use such URLs. Using the option RejectUnsafeURI, you +can block several well known URL encoding attacks. By default, this option +is not set. +

+

+You can also realise such a check with mod_rewrite, which is more powerful +but also slightly more complicated. + +

  
+  JkOptions     +RejectUnsafeURI
+
+ +
+
+

+ +

+JkOptions ForwardDirectories is used in conjunction with DirectoryIndex +directive of Apache web server. As such mod_dir should be available to Apache, +statically or dynamically (DSO) +
+
+

+ +

+When DirectoryIndex is configured, Apache will create sub-requests for +each of the local-url's specified in the directive, to determine if there is a +local file that matches (this is done by stat-ing the file). +

+ +

+If ForwardDirectories is set to false (default) and Apache doesn't find any +files that match, Apache will serve the content of the directory (if directive +Options specifies Indexes for that directory) or a 403 Forbidden response (if +directive Options doesn't specify Indexes for that directory). +

+ +

+If ForwardDirectories is set to true and Apache doesn't find any files that +match, the request will be forwarded to Tomcat for resolution. This is used in +cases when Apache cannot see the index files on the file system for various +reasons: Tomcat is running on a different machine, the JSP file has been +precompiled etc. +

+ +

Note that locally visible files will take precedence over the +ones visible only to Tomcat (i.e. if Apache can see the file, that's the one +that's going to get served). This is important if there is more then one type of +file that Tomcat normally serves - for instance Velocity pages and JSP pages. + +

  
+  JkOptions     +ForwardDirectories
+
+
+
+

+ +

+JkOptions ForwardLocalAddress, you ask mod_jk to send the local address, +of the Apache web server instead remote client address. This can be used by +Tomcat remote address valve for allowing connections only from registered Apache +web servers. + +

  
+  JkOptions     +ForwardLocalAddress
+
+ +
+
+

+ +

+JkOptions FlushPackets, you ask mod_jk to flush Apache's connection +buffer after each AJP packet chunk received from Tomcat. This option can have +a strong performance penalty for Apache and Tomcat as writes are performed +more often than would normally be required (ie: at the end of each +response). + +

  
+  JkOptions     +FlushPackets
+
+ +
+
+

+ +

+JkOptions FlushHeader, you ask mod_jk to flush Apache's connection +buffer after the response headers have been received from Tomcat. + +

  
+  JkOptions     +FlushHeader
+
+ +
+
+

+ +

+JkOptions DisableReuse, you ask mod_jk to close connections immediately +after their use. Normally mod_jk uses persistent connections and pools idle +connections to reuse them, when new requests have to be sent to Tomcat. +

+ +

+Using this option will have a strong performance penalty for Apache and Tomcat. +Use this only as a last resort in case of unfixable network problems. +If a firewall between Apache and Tomcat silently kills idle connections, +try to use the worker attribute socket_keepalive in combination with an appropriate +TCP keepalive value in your OS. + +

  
+  JkOptions     +DisableReuse
+
+ +
+
+

+ +

+JkOptions ForwardKeySize, you ask mod_jk, when using ajp13, to forward also the SSL Key Size as +required by Servlet API 2.3. +This flag shouldn't be set when servlet engine is Tomcat 3.2.x (on by default). + +

  
+  JkOptions     +ForwardKeySize
+
+ +
+
+

+ +

+JkOptions ForwardSSLCertChain, you ask mod_jk, when using ajp13, +to forward SSL certificate chain (off by default). +Mod_jk only passes the SSL_CLIENT_CERT to the AJP connector. This is not a +problem with self-signed certificates or certificates directly signed by the +root CA certificate. However, there's a large number of certificates signed by +an intermediate CA certificate, where this is a significant problem: A servlet +will not have the possibility to validate the client certificate on its own. The +bug would be fixed by passing on the SSL_CLIENT_CERT_CHAIN to Tomcat via the AJP connector. +
+This directive exists only since version 1.2.22. +

  
+  JkOptions     +ForwardSSLCertChain
+
+ +
+
+

+ +

+The directive JkEnvVar allows you to forward environment variables +from Apache server to Tomcat engine. +You can add a default value as a second parameter to the directive. +If the default value is not given explicitly, the variable +will only be send, if it is set during runtime. +
+The variables can be retrieved on the Tomcat side as request attributes +via request.getAttribute(attributeName). +Note that the variables send via JkEnvVar will not be listed +in request.getAttributeNames(). +
+
+The variables are inherited from the global server to virtual hosts. + +

  
+  JkEnvVar     SSL_CLIENT_V_START     undefined
+
+
+
+

+ +
+ +
Assigning URLs to Tomcat
+

+If you have created a custom or local version of mod_jk.conf-local as noted above, +you can change settings such as the workers or URL prefix. +

+

+JkMount directive assign specific URLs to Tomcat. +In general the structure of a JkMount directive is: +

+ +
  
+  JkMount [URL prefix] [Worker name]
+
+ +
+  # send all requests ending in .jsp to worker1
+  JkMount /*.jsp worker1
+  # send all requests ending /servlet to worker1
+  JkMount /*/servlet/ worker1
+  # send all requests jsp requests to files located in /otherworker will go worker2
+  JkMount /otherworker/*.jsp worker2
+
+ +

+You can use the JkMount directive at the top level or inside <VirtualHost> +sections of your httpd.conf file. +

+

JkUnMount directive acts as an opposite to JkMount and blocks access +to a particular URL. The purpose is to be able to filter out the particular content +types from mounted context. The following example mounts /servlet/* +context, but all .gif files that belongs to that context are not served. +

+
+  # send all requests ending with /servlet to worker1
+  JkMount /servlet/* worker1
+  # do not send requests ending with .gif to worker1
+  JkUnMount /servlet/*.gif worker1
+
+

+JkUnMount takes precedence over JkMount directives, meaning that the JK +will first try to mount and then checks, if there is an exclusion defined by a +JkUnMount. A JkUnMount overrides a JkMount only, if the worker names in the +JkMount and in the JkUnMount are the same. +

+

+The following example will block all .gif files although there is a JkMount for them: +

+
+  # do not send requests ending with .gif to worker1
+  JkUnMount /*.gif worker1
+  # The .gif files will not be mounted cause JkUnMount takes
+  # precedence over JkMount directive
+  JkMount /servlet/*.gif worker1
+
+

+Starting with version 1.2.26 of JK you can apply a JkUnMount to any worker, +by using the star character '*' as the worker name in the JkUnMount. +More complex patterns in JkUnMount worker names are not allowed. +

+
+  # Mapping the webapps myapp1 and myapp2:
+  /myapp1/*=worker1
+  /myapp2/*=worker2
+  # Exclude the all subdirectories static for all workers:
+  !/*/static/*=*
+  # Exclude some suffixes for all workers:
+  !*.html=*
+
+

+JkAutoAlias directive automatically Alias webapp context directories into +the Apache document space. It enables Apache to serve a static context while Tomcat +serving dynamic context. This directive is used for convenience so that you don't +have to put an apache Alias directive for each application directory inside Tomcat's +webapp directory. For security reasons is is strongly recommended that JkMount +is used to pass all requests to Tomcat by default and JkUnMount is used to +explicitly exclude static content to be served by httpd. It should also be noted +that content served by httpd will bypass any security constraints defined in the +application's web.xml. +

+
+  # enter the full path to the tomcat webapps directory
+  JkAutoAlias /opt/tomtact/webapps
+
+

The following example shows how to serve a dynamic context by +Tomcat and static using Apache. The webapps directory has to +be accessible by apache.

+ +
+  # enter the full path to the tomcat webapps directory
+  JkAutoAlias /opt/tomtact/webapps
+
+  # Mount 'servlets-examples' directory. It's physical location
+  # is assumed to be in the /opt/tomtact/webapps/servlets-examples
+  # ajp13w is a worker defined in the workers.properties
+  JkMount /servlets-examples/* ajp13w
+
+  # Unmount desired static content from servlets-examples webapp.
+  # This content will be served by the httpd directly.
+  JkUnMount /servlets-examples/*.gif ajp13w
+  JkUnMount /servlets-examples/*.jpg ajp13w
+
+

Note that you can have a single JkAutoAlias directive per virtual +host inside your httpd.conf +

+

+JkWorkerProperty is a new directive available from JK 1.2.7 +version. It is a convenient method for setting directives that are +usually set inside workers.propeties file. The parameter for +that directive is raw line from workers.properties file. +

+
+  # Just like workers.properties but exact line is prefixed
+  # with JkWorkerProperty
+
+  # Minimal jk configuration
+  JkWorkerProperty worker.list=ajp13w
+  JkWorkerProperty worker.ajp13w.type=ajp13
+  JkWorkerProperty worker.ajp13w.host=localhost
+  JkWorkerProperty worker.ajp13w.port=8009   
+
+

+JkMountFile is a new directive available from JK 1.2.9 +version. It is used for dynamic updates of mount points at runtime. +When the mount file is changed, JK will reload it's content. +

+
+  # Load mount points
+
+  JkMountFile conf/uriworkermap.properties
+
+

If the mount point uri starts with an exclamation mark '!' +it defines an exclusion in the same way JkUnMount does. +If the mount point uri starts with minus sign '-' +the mount point will only be disabled. A disabled mount can be reenabled +by deleting the minus sign and waiting for the JkMountFile to reload. +An exclusion can be disabled by prefixing it with a minus sign. +

+
+  # Sample uriworkermap.properties file
+
+  /servlets-examples/*=ajp13w
+  # Do not map .jpeg files
+  !/servlets-examples/*.jpeg=ajp13w
+  # Make jsp examples initially disabled  
+  -/jsp-examples/*=ajp13w
+
+

At run time you can change the content of this file. For example +removing minus signs will enable the previously disabled uri mappings. +You can add any number of new entries at runtime that reflects the newly deployed +applications. Apache will reload the file and update the mount +points within 60 second interval. +

+

+There is no way to delete entries by dynamic reloading, but you can disable or +exclude mappings. +
+
+

+ +
+ +
Using SetHandler and Environment Variables
+

+Alternatively to the mod_jk specific directives, you can also use +SetHandler and environment variables to control, which requests +are being forwarded via which worker. This gives you more flexibility, +but the results might be more difficult to understand. If you mix both +ways of defining the forwards, in general to mod_jk directives will win. +

+

+SetHandler jakarta-servlet forces requests to be handled by mod_jk. +If you neither specify any workers via JkMount and the related directives, +not via the environment variable described below, +the first worker in the list of all worker will be chosen. You can use SetHandler +for example in Location blocks or with Apache 2.2 also in RewriteRule. +

+

+In order to control the worker using SetEnvIf or RewriteRule +for more complex rules, you can set the environment variable JK_WORKER_NAME +to the name of your chosen target worker. This enables you to decide on +the chosen worker in a more flexible way, including dependencies on cookie values. +This feature has been added in version 1.2.19 of mod_jk. +

+

+In order to use another variable than JK_WORKER_NAME, you can set the name +of this variable via the JkWorkerIndicator directive. +

+

+You can also define exclusions from mod_jk forwards by setting the environment +variable no-jk. +

+
+  # Automatically map all encoded urls
+  <Location *;jsessionid=>
+    SetHandler jakarta-servlet
+    SetEnv JK_WORKER_NAME my_worker
+  </Location>
+
+  # Map all subdirs to workers via naming rule
+  # and exclude static content.
+  <Location /apps/>
+    SetHandler jakarta-servlet
+    SetEnvIf REQUEST_URI ^/apps/([^/]*)/ JK_WORKER_NAME=$1
+    SetEnvIf REQUEST_URI ^/apps/([^/]*)/static no-jk
+  </Location>
+
+

+Finally, starting with version 1.2.27 you can use the environment variable +JK_REPLY_TIMEOUT to dynamically set a reply timeout. +

+
+

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/printer/iis.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/printer/iis.html new file mode 100644 index 00000000..8405bcf5 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/printer/iis.html @@ -0,0 +1,331 @@ +The Apache Tomcat Connector - Reference Guide - Configuring IIS
Apache TomcatApache Logo

The Apache Tomcat Connector - Reference Guide

Configuring IIS

Requirements
+

+The Tomcat redirector requires three entities: + +

    +
  • +isapi_redirect.dll - The IIS server plugin, either obtain a pre-built DLL or build it yourself (see the build section). +
  • +
  • +workers.properties - A file that describes the host(s) and port(s) used by the workers (Tomcat processes). +A sample workers.properties can be found under the conf directory. +
  • +
  • +uriworkermap.properties - A file that maps URL-Path patterns to workers. +A sample uriworkermap.properties can be found under the conf directory as well. +
  • +
+

+ +

+The installation includes the following parts: + +

    +
  • +Configuring the ISAPI redirector with a default /examples context and checking that you can serve servlets with IIS. +
  • +
  • +Adding more contexts to the configuration. +
  • +
+

+
Registry settings
+

+ISAPI redirector reads configuration from the registry, create a new registry key named : +

+

+"HKEY_LOCAL_MACHINE\SOFTWARE\Apache Software Foundation\Jakarta Isapi Redirector\1.0" +

+
Key NameDescription
extension_uri

+A string value pointing to the ISAPI extension /jakarta/isapi_redirect.dll +

log_file

+A value pointing to location where log file will be created. +(for example c:\tomcat\logs\isapi.log) +
If one of the log rotation settings (log_rotationtime or log_filesize) are specified then the actual log file name is based on this setting. +If the log file name includes any '%' characters, then it is treated as a format string for strftime(3), +e.g. c:\tomcat\logs\isapi-%Y-%m-%d-%H_%M_%S.log. Otherwise, the suffix .nnnnnnnnnn is automatically added and is the time in seconds. +A full list of format string substitutions can be found in the Apache rotatelogs documentation +

log_level

+A string value for log level +(can be debug, info, warn, error or trace).

+

This directive was added in version 1.2.31

+
log_rotationtime

+The time between log file rotations in seconds. +Setting this to 0 (the default) disables log rotation based on time.

+

This directive was added in version 1.2.31

+
log_filesize

+The maximum log file size in megabytes, after which the log file will be rotated. Setting this to 0 (the default) disables log rotation based on file size. +
The value can have an optional M suffix, i.e. both 5 and 5M will rotate the log file when it grows to 5MB. +
If log_rotationtime is specified, then this setting is ignored. +

worker_file

+A string value which is the full path to workers.properties file +(for example c:\tomcat\conf\workers.properties) +

worker_mount_file

+A string value which is the full path to uriworkermap.properties file +(for example c:\tomcat\conf\uriworkermap.properties) +

rewrite_rule_file

+A string value which is the full path to rewrite.properties file +(for example c:\tomcat\conf\rewrite.properties) +

shm_size

+A DWORD value size of the shared memory. Set this value to be +the number of all defined workers * 400. +(Set this value only if you have more then 64 workers) +

+

This directive has been added in version 1.2.20

+

Starting with version 1.2.27 the size of the shared memory is determined +automatically, even for large numbers of workers. This attribute is not +needed any longer.

+
worker_mount_reload

+A DWORD value specifying the time in seconds upon which the +worker_mount_file will be reloaded. +

+

This directive has been added in version 1.2.20

+
strip_session

+A string value representing a boolean. If it is set to true, +URL session suffixes of the form ";jsessionid=..." get stripped of URLs, +even if the are served locally by the web server. +

+

+A true value can be represented by the string "1" or any string starting +with the letters "T" or "t". A false value will be assumed for "0" +or any string starting with "F" or "f". The default value is false. +

+

This directive has been added in version 1.2.21

+
auth_complete

+A DWORD value representing "0" or "1". This is needed because +of minor incompatibilities with IIS 5.1. +

+

+By default its value is 1, which means we use the SF_NOTIFY_AUTH_COMPLETE +event. If you set this to 0, then we use SF_NOTIFY_PREPROC_HEADERS. +This might be needed for IIS 5.1 when handling requests using the +PUT HTTP method. +

+

This directive has been added in version 1.2.21

+
uri_select

+A string value which influences, how URIs are decoded and re-encoded +between IIS and Tomcat. You should leave this at it's default value, +unless you have a very good reason to change it. +

+

+If the value is "parsed", the forwarded URI +will be decoded and explicit path components like ".." will already +be resolved. This is less spec compliant and is not safe +if you are using prefix forwarding rules. +

+

+If the value is "unparsed", the forwarded URI +will be the original request URI. It's spec compliant and also +the safest option. Rewriting the URI and then forwarding the rewritten +URI will not work. +

+

+If the value is "escaped", the forwarded URI +will be the re-encoded form of the URI used by "parsed". +Explicit path components like ".." will already be resolved. +This will not work in combination with URL encoded session IDs. +

+

+If the value is "proxy", the forwarded URI +will be a partially re-encoded form of the URI used by "parsed". +Explicit path components like ".." will already be resolved. +and problematic are re-encoded. +

+

The default value since version 1.2.24 is "proxy". Before it was "parsed".

+
reject_unsafe

+A string value representing a boolean. If it is set to true, +URLs containing percent signs '%' or backslashes '\' +after decoding will be rejected. +

+

+Most web apps do not use such URLs. By enabling "reject_unsafe" you +can block several well known URL encoding attacks. +

+

+A true value can be represented by the string "1" or any string starting +with the letters "T" or "t". A false value will be assumed for "0" +or any string starting with "F" or "f". The default value is false. +

+

This directive has been added in version 1.2.24

+
watchdog_interval

+A DWORD value representing the watchdog thread interval in seconds. +The workers are maintained periodically by a background thread +running periodically every watchdog_interval seconds. Worker maintenance +checks for idle connections, corrects load status and is able +to detect backend health status. +

+

+The maintenance only happens, if since the last maintenance at +least worker.maintain +seconds have passed. So setting the watchdog_interval +much smaller than worker.maintain is not useful. +

+

+The default value is 0 seconds, meaning the watchdog thread +will not be created, and the maintenance is done in combination +with normal requests instead. +

+

This directive has been added in version 1.2.27

+
error_page

+A string value representing the error page url redirection when +backend returns non-200 response. This directive can be used +to customise the error messages returned from backend server. +

+

The url must point to a valid server url and can contain +format string number (%d) that can be used to +separate the pages by error number. The redirect url in that +case is formatted by replacing %d from +error_page to returned error number. +

+

This directive has been added in version 1.2.27

+
enable_chunked_encoding

+A string value representing a boolean. If it is set to true, +chunked encoding is supported by the server. +

+

+A true value can be represented by the string "1" or any string starting +with the letters "T" or "t". A false value will be assumed for "0" +or any string starting with "F" or "f". The default value is false. +

+

This option is considered experimental and its support +must be compile time enabled. Use isapi_redirect.dll +with chunked support enabled. +

+

This directive has been added in version 1.2.27

+
+
Using a properties file for configuration
+

+The ISAPI redirector can read it's configuration from a properties file instead of the registry. +This has the advantage that you can use multiple ISAPI redirectors with independent configurations on the same server. +The redirector will check for the properties file during initialisation, and use it in preference to the registry if present. +

+

+Create a properties file in the same directory as the ISAPI redirector called isapi_redirect.properties i.e. with the same name as the ISAPI redirector DLL but with a .properties extension. A sample isapi_redirect.properties can be found under the conf directory. +

+

+The property names and values in the properties file are the same as for the registry settings described above. For example: +

+

+

+# Configuration file for the Jakarta ISAPI Redirector
+
+# The path to the ISAPI Redirector Extension, relative to the website
+# This must be in a virtual directory with execute privileges
+extension_uri=/jakarta/isapi_redirect.dll
+
+# Full path to the log file for the ISAPI Redirector
+log_file=c:\tomcat\logs\isapi_redirect.log
+
+# Log level (debug, info, warn, error or trace)
+log_level=info
+
+# Full path to the workers.properties file
+worker_file=c:\tomcat\conf\workers.properties
+
+# Full path to the uriworkermap.properties file
+worker_mount_file=c:\tomcat\conf\uriworkermap.properties
+
+

+

+ Notes: +

    +
  • + Back-slashes - '\' - are not escape characters. +
  • +
  • + Comment lines begin with '#'. +
  • +
+

+

Starting with version 1.2.27 two environment variables are +dynamically added to the environment that can be used inside +.properties files. +

    +
  • JKISAPI_PATH - Full path to the ISAPI Redirector. +
  • +
  • JKISAPI_NAME - Name of the ISAPI Redirector dll without extension +
  • +
+

+

+# Use the logs in the installation path of ISAPI Redirector
+log_file=$(ISAPI_PATH)\$(ISAPI_NAME).log
+

+
Log file rotation
+

+The ISAPI redirector with version 1.2.31 can perform log rotation, with configuration and behaviour similar to the +rotatelogs program provided with Apache HTTP Server. +

+

+To configure log rotation, configure a log_file, and one of the log_rotationtime or log_filesize options. +If both are specified, the log_rotationtime will take precedence, and log_filesize will be ignored. +
For example, to configure daily rotation of the log file: +

+
+# Configuration file for the Jakarta ISAPI Redirector
+...
+
+# Full path to the log file for the ISAPI Redirector
+log_file=c:\tomcat\logs\isapi_redirect.%Y-%m-%d.log
+
+# Log level (debug, info, warn, error or trace)
+log_level=info
+
+# Rotate the log file every day
+log_rotationtime=86400
+
+...
+
+

+Or to configure rotation of the log file when it reaches 5MB in size: +

+
+# Configuration file for the Jakarta ISAPI Redirector
+...
+
+# Full path to the log file for the ISAPI Redirector
+log_file=c:\tomcat\logs\isapi_redirect.%Y-%m-%d-%H.log
+
+# Log level (debug, info, warn, error or trace)
+log_level=info
+
+# Rotate the log file at 5 MB
+log_filesize=5M
+
+...
+
+

+The log will be rotated whenever the configured limit is reached, but only if the log file name would change. If you configure + a log file name with strftime(3) format codes in it, then ensure it specifies the same granularity + as the rotation time configured, e.g. %Y-%m-%d if rotating daily (log_rotationtime=86400). +
See the rotatelogs documentation for more examples. +

+ +
Using a simple rewrite rules
+

+The ISAPI redirector with version 1.2.16 can do a simple URL rewriting. Although not +as powerful as Apache Httpd's mod_rewrite, it allows a simple exchange of request URIs +

+

+The rule is in the form original-url-prefix=forward-url-prefix. For example: +

+
+# Simple rewrite rules, making /jsp-examples
+# and /servlets-examples available under shorter URLs
+/jsp/=/jsp-examples/
+/servlets/=/servlets-examples/
+
+

+You can also use regular expressions, if you prefix the rule with a tilde ~: +

+
+# Complex rewrite rule, adding "-examples"
+# to the first path component of all requests
+~/([^/]*)=/$1-examples
+
+

+Note that uriworkermap.properties must use the URLs before rewriting. +

+

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/printer/status.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/printer/status.html new file mode 100644 index 00000000..56412d61 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/printer/status.html @@ -0,0 +1,546 @@ +The Apache Tomcat Connector - Reference Guide - Status Worker Reference
Apache TomcatApache Logo

The Apache Tomcat Connector - Reference Guide

Status Worker Reference

Introduction
+
+

+Tomcat Connectors has a special type of worker, the so-called status worker. +The status worker does not forward requests to Tomcat instances. Instead it allows +to retrieve status and configuration information at runtime, +and furthermore to change many configuration items dynamically. This can be done +via a simple embedded web interface. +

+

+The status worker is especially powerful, when used together with load balancing workers. +

+

+This document does not explain the HTML user interface of the status worker. +Until now it is very simple, so just go ahead and use it. This doc instead +tries to explain the less obvious features of the status worker. We also will give a +complete coverage of the various request parameters and their meaning, so that you can +include the status worker in your automation scripts. +

+

+The documentation of the status worker starts with jk 1.2.20 +

+
Usage Patterns
+
+
Actions
+
+

+The status worker knows about six actions. +

    +
  • +list: lists the configurations and runtime information of all configured workers. +The output will be grouped by global information first (version data), then load balancer +information, after that AJP worker information and finally the legend. For load balancers, +there will be a summary part, and after that details for each member worker. For all workers, +we also include the URL mappings (forward definitions). +
  • +
  • +show: the same as list, but only shows data for one chosen worker +
  • +
  • +edit: produces a form to edit configuration data for a chosen worker. There is a +special subtype of "edit", that makes it easy to change one attribute for all members of +a load balancer, e.g. their activation state. +
  • +
  • +update: commit changes made in an edit form. Caution: the changes will not be +persisted to the configuration files. As soon as your restart your web server, all changes +made through the status worker will be lost! On the other hand, the changes done by the status +worker will be applied during runtime without a restart of the web server. +
  • +
  • +reset: reset all runtime statistics for a worker. +
  • +
  • +recover: Mark a member of a load balancer, that is in error state, for immediate recovery. +
  • +
  • +version: only show version information of the web server and the JK software +
  • +
  • +dump: list the original workers configuration. Caution: the dump will only contain +the configuration that was used during startup. Any changes applied later by the dynamic management +interface of the status worker itself will not be contained in this dump. +The dump action has been added in version 1.2.27. +
  • +
+

+
+ +
Output Format
+
+

+For most actions you can choose between 4 output formats. +

    +
  • +HTML: Used interactively with a browser +
  • +
  • +XML: Mostly useful for automation, when your scripting environment is XML friendly. +This format has rich structure information, but does not work line based, so you would really +like to use it together with XML tools. +
  • +
  • +Properties: This format is a line based format, that conforms to the rules of Java +property files. Most structure information is contained in the hierarchical key. For information, +that is of configuration nature, the format should produce lines very similar to the ones you can +use in workers.properties. It will not produce a complete configuration file! +
  • +
  • +Text: A simple textual output format. +
  • +
+The "edit" action does only make sense for the HTML output type. +

+
+ +
User Interface Features
+
+

+In the HTML view, there is an automatic refresh feature, implemented via the meta refresh +option of HTML. Once you start the automatic refresh, the UI will will respect it for all actions +except edit, update and maintain. Even if you navigate through one of those, the automatic refresh +will start again as soon as you come back to one of the other actions. +

+

+Many parts of the HTML page can be minimised, if they are not interesting for you. There are a couple +of "Hide" links, which will collapse parts of the information. The feature exists for the following +blocks of information: +

    +
  • +Legend: Do not show the legend for the information presented in "list" and "show" actions +
  • +
  • +URI mappings: Do not show the URI mapping for the workers +
  • +
  • +Load Balancing Workers: Do not show workers of type "lb" +
  • +
  • +AJP Workers: Do not show workers of type ajp +
  • +
  • +Balancer Members: Do not show detailed information concerning each member of load balancers +
  • +
  • +Load Balancer Configuration: Do not show configuration data for load balancers +
  • +
  • +Load Balancer Summary: Do not show status summary for load balancers +
  • +
  • +AJP Configuration: Do not show configuration data for ajp workers load balancer members +
  • +
+The last three minimisation features have been added in version 1.2.27. +

+
+ +
Special Considerations concerning URL Maps and Virtual Hosts
+
+

+Note: The following restriction has been removed starting with version 1.2.26. +

+

+The Apache module mod_jk makes use of the internal Apache httpd infrastructure concerning +virtual hosts. The downside of this is, that the status worker can only show URL maps, for +the virtual host it is defined in. It is not able to reach the configuration objects +for other virtual hosts. Of course you can define a status worker in any virtual host you +are using. All information presented apart from the URL maps will be the same, independent +of the virtual host the status worker has been called in. +

+
+ +
Logging
+
+

+The status worker will log changes made to the configuration with log level "info" to the usual +JK log file. Invalid requests will be logged with log level "warn". If you want to report some +broken behaviour, log file content of level "debug" or even "trace" will be useful. +

+
+ +
Configuration
+
+
Basic Configuration
+
+

+The basic configuration of a status worker is very similar to that of a usual ajp worker. +You need to specify a name for the worker, and the URLs you want to map to it. The first +part of the configuration happens in the workers.properties file. We define a worker named +mystatus of type status: +

+worker.list=mystatus
+worker.mystatus.type=status
+
+Then we define a URL, which should be mapped to this worker, i.e. the URL we use +to reach the functionality of the status worker. You can use any method mod_jk supports +for the web server of your choice. Possibilities are maps inside uriworkermap.properties, +an additional mount attribute in workers.properties, or in Apache JkMount. Here's an +example for a uriworkermap.properties line: +
+/private/admin/mystatus=mystatus
+
+The URI pattern is case sensitive. +

+

+As you will learn in the following sections, the status worker is very powerful. You should +use the usual authentication and authorisation methods of your web server to secure this URL. +

+

+You can also define multiple instances of the status worker, by using different names and URL mappings. +For instance you might want to configure them individually +and then allow special groups of people to use them +

+
+ +
Output Customisation
+
+

+There are a couple of attributes for the workers.properties entries, which allow to customise +various aspects of the output of the status worker. +

+

+The attribute css can be set to the URL of a stylesheet: +

+worker.mystatus.css=/private/admin/static/mystatus.css
+
+When writing HTML output, the status worker then includes the line +
+<link rel="stylesheet" type="text/css" href="/private/admin/static/mystatus.css" />
+
+There is no sample stylesheet included with the mod_jk release, and by default the attribute css +is empty, so no stylesheet reference will be included in the pages. The HTML code +of the status worker output pages does not include any class attributes. If you like to contribute a +stylesheet or improvements to the HTML layout, please contact us on the tomcat developers list. +

+

+The properties output format can be customised via the attribute prefix. The names of all +properties the status worker does output, will begin with this prefix. The default is "worker". +

+

+Several attributes influence the format when writing XML output. +The attribute ns allows to set a namespace prefix, that will be used for every status worker+element. +The default is "jk:". Setting it to "-" disables the namespace prefix. +

+

+With the attribute xmlns you can map the prefix to a namespace URL. The default value +is xmlns:jk="http://tomcat.apache.org". Setting it to "-" disables the output of the URL. +

+

+Finally you can specify an XML document type via the attribute doctype. The specified string will +be inserted at the beginning of the document, directly after the xml header. The default is empty. +

+
+ +
Securing Access
+
+

+We urge you to use the builtin access control features of your web server to control +access to the status worker URLs you have chosen. Nevertheless two configuration +attributes of status workers are helpful. The attribute "read_only" disables all features of +the status worker, that can be used to change configurations or runtime status of the other workers. +A read_only status worker will not allow access to the edit, update, reset or recover actions. +The default value is "False", ie. read/write. To enable read_only you need to set it to "True". +

+

+You could configure two status workers, one has read_only and will be made available to a larger +admin group, the other one will be used fully featured, but only by fewer people: +

+worker.list=jk-watch
+worker.jk-watch.type=status
+worker.jk-watch.read_only=True
+worker.jk-watch.mount=/user/status/jk
+worker.list=jk-manage
+worker.jk-manage.type=status
+worker.jk-manage.mount=/admin/status/jk
+
+Starting with version 1.2.21, a read/write status worker can also be switched temporarily +into read-only mode by the user via a link in the HTML GUI. The user can always switch it +back to read/write. Only a status worker configured as read-only via the "read_only" attribute +is completely safe from applying any changes. +

+

+The other attribute you can use is user. By default this list is empty, which means +no limit on the users. You can set "user" to a comma separated list of user names. If your +web server is configured such that it sends the user names with the request, the status worker +will check, if the name attached with the request is contained in it's "user" list. +

+

+The user list can be split over multiple occurrences of the "user" attribute. +

+

+By default, the user names are matched case sensitively. Starting with version 1.2.21 you can set +the attribute user_case_insensitive to "True". Then the comparison will be made case insensitive. +

+
+ +
Service Availability Rating
+
+

+For load balancing workers the status worker shows some interesting overview information. +It categorises the members of the load balancer into the classes "good", "bad" and degraded". +This feature can be combined with external escalation procedures. Depending on your global +system design and your operating practises your preferred categorisation might vary. +

+

+The categorisation is based on the activation state of the workers (active, disabled or stopped), +which is a pure configuration state, and the runtime state +(OK or ERR with possible substates idle, busy, recovering, probing, and forced recovery) +which only depends on the runtime situation. +

+

+The runtime substates have the following meaning: +

    +
  • +OK (idle): This worker didn't receive any request since the last balancer +maintenance. By default balancer maintenance runs every 60 seconds. The +worker should be OK, but since we didn't have to use it for some time, we +can't be sure. This state has been called N/A before version 1.2.24. +
  • +
  • +OK (busy): All connections for this worker are in use for requests. +
  • +
  • +ERROR (recovering): The worker was in error state for some time and is now +marked for recovery. The next request suitable for this worker will use it. +
  • +
  • +ERROR (probing): After setting the worker to recovering, we received a request +suitable for this worker. This request is now using the worker. +
  • +
  • +ERROR (forced recovery): The worker is in error, but we don't have an alternative +worker, so we keep using it. +
  • +
+

+

+By default the status worker groups into "good" all members, that have activation "active" and +runtime state not equal to "error" with empty substate. +The "bad" group consists of the members, that have either activation +"stopped", or are in runtime state "error" with empty substate. +

+

+Workers that fit neither of the two groups, are considered to be "degraded". +

+

+You can define other rules for the grouping into good, bad and degraded. +The two attributes "good" and "bad" can be populated by a comma-separated list ob single characters or +dot-separated pairs. Each character stands for the first character of one of the possible states "active", +"disabled", "stopped", "ok", "idle", "busy", "recovering" and "error". The additional states "probing" +and "forced recovery" are always rated equivalent to "recovering". +Comma-separated entries will be combined +with logical "or", if you combine a configuration and a runtime state with a dot. the are combined with logical +"and". So the default value for "good" is "a.o,a.i,a.b,a.r", for "bad" it is "e,s". +

+

+The status worker first tries to match against the "bad" definitions, if this doesn't succeed +it tries to match against "good", and finally it chooses "degraded", if no "bad" or "good" match +can be found. +

+
+
Request Parameters
+
+

+This section should help you building automation scripts based on the jk status +management interface. This interface is stable in the sense, that we only expect +to add further parameters in the future. Existing parameters from previous versions +will keep their original semantics. We also expect the output formats XML, Properties +and Text to be kept stable. So please use those, if you want to parse status worker +output in your automation scripts. +

+
Actions
+
+

+The action is determined by the parameter cmd. It can have the values "list", "show", +"edit", "update", "reset", "recover", "version" and "dump". If you omit the cmd parameter, +the default "list" will be used. +All actions except for "list", "refresh", "version" and "dump" need additional parameters. +

+

+The action "dump" has been added in version 1.2.27. +

+
+
Output Format
+
+

+The format is determined by the parameter mime. It can have the values "html", "xml", +"txt" and "prop". If you omit the mime parameter, the default "html" +will be used. The action "edit" (the edit form) does only make sense for "mime=html". +

+
+
Worker Selection
+
+

+Actions that operate on a single worker need one or two additional parameters to select +this worker. The parameter w contains the name of the worker from the worker list. +If an action operates on a member (sub worker) of a load balancer, the parameter w +contains the name of the load balancer worker, and the additional parameter sw contains the +name of the sub worker. +

+
+
Automatic Refresh
+
+

+During automatic refresh, the parameter re contain the refresh interval in seconds. +If you omit this parameter, automatic refresh will be off. +

+
+
Hide Options
+
+

+The parameter opt contains a bit mask of activated options. The default is 0, so +by default no options are activated. The following options exist: +

    +
  • +0x0001: hide members of lb workers +
  • +
  • +0x0002: hide URL maps +
  • +
  • +0x0004: hide the legend +
  • +
  • +0x0008: hide load balancer workers +
  • +
  • +0x0010: hide ajp workers +
  • +
  • +0x0020: only allow read_only actions for a read/write status worker. +
  • +
  • +0x0040: hide load balancer configuration +
  • +
  • +0x0080: hide load balancer status summary +
  • +
  • +0x0100: hide configuration for ajp and load balancer member workers +
  • +
+Values 0x0040-0x0100 have been added in version 1.2.27. +

+
+
Data Parameters for the standard Update Action
+
+

+You can use the edit action with a final click to the update button, to change settings of workers. +But you can also make direct calls to the update action. The following request parameters +contain the configuration information, you want to change. First the list for load balancer workers: +

    +
  • +vlr: retries (number) +
  • +
  • +vlt: recover_time (seconds) +
  • +
  • +vlee: error_escalation_time (seconds) +
  • +
  • +vlx: max_reply_timeouts (number) +
  • +
  • +vls: sticky_session (0/f/n/off=off, 1/t/y/on=on; case insensitive) +
  • +
  • +vlf: sticky_session_force (0/f/n/off=off, 1/t/y/on=on; case insensitive) +
  • +
  • +vlm: method (0/r="Requests", 1/t="Traffic", 2/b="Busyness", 3/s="Sessions"; case insensitive, only first character is used) +
  • +
  • +vll: lock (0/o="Optimistic", 1/p="Pessimistic"; case insensitive, only first character is used) +
  • +
+And now the list of parameters you can use to change settings for load balancer members: +
    +
  • +vwa: activation flag (0/a="active", 1/d="disabled", 2/s="stopped"; case insensitive, only first character is used) +
  • +
  • +vwf: load balancing factor (integer weight) +
  • +
  • +vwn: route for use with sticky sessions (string) +
  • +
  • +vwr: redirect to define simple failover rules (string) +
  • +
  • +vwc: domain to tell JK about your replication design (string) +
  • +
  • +vwd: distance to express preferences (integer) +
  • +
+Finally the list of parameters you can use to change settings for ajp workers and ajp load balancer members: +
    +
  • +vahst: host (string) +
  • +
  • +vaprt: port (number) +
  • +
  • +vacpt: connection_pool_timeout (number) +
  • +
  • +vact: connect_timeout (number) +
  • +
  • +vapt: prepost_timeout (number) +
  • +
  • +vart: reply_timeout (number) +
  • +
  • +var: retries (number) +
  • +
  • +varo: recovery_options (number) +
  • +
  • +vamps: max_packet_size (number) +
  • +
+Note that changing the host name or port will only take effect for new connections. +Already established connections to the old address will still be used. +Nevertheless this feature is interesting, because you can provision load balancer +members with port "0", which will automatically be stopped during startup. Later +when you know the final names and ports, you can set them and they will be +automatically activated. +

+

+The leading character "v" has been added to the parameters in version 1.2.27. +Changing settings for ajp workers has also been introduced in version 1.2.27. +

+

+For the details of all parameters, we refer to the workers.properties Reference. +

+
+
Aspect Editing for Load Balancer Members
+
+

+You can use the edit action to edit all settings for a load balancer or for a +member of a load balancer respectively on one page. If you want to edit one +configuration aspect for all members of a load balancer simultaneously, this +will be triggered by the parameter att. The value of the parameter indicates, +which aspect you want to edit. The list is the same as in the previous section, +except for "vahst" and "vaprt": +"vwa", "vwf", "vwn", "vwr", "vwc", "vwd", "vacpt", "vact", "vapt", "vart", "var", +"varo" and "vamps". But here you +need to put the name into the parameter att, instead of using it as a request +parameter name. +

+

+The values of the common aspect for all the load balancer members will be given +in parameters named "val0", "val1", .... +

+
+

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/printer/uriworkermap.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/printer/uriworkermap.html new file mode 100644 index 00000000..3bc39256 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/printer/uriworkermap.html @@ -0,0 +1,377 @@ +The Apache Tomcat Connector - Reference Guide - uriworkermap.properties configuration
Apache TomcatApache Logo

The Apache Tomcat Connector - Reference Guide

uriworkermap.properties configuration

Introduction
+
+

+The forwarding of requests from the web server to tomcat gets configured by defining mapping rules. +Such a rule maps requests to workers. The request part of the map is described by a URI pattern, +the worker by it's worker name. +

+

+The so-called uriworkermap file is a mechanism of defining rules, +which works for all web servers. There exist also other web server specific configuration +options for defining rules, which will be mostly discussed on the reference pages for +configuring tomcat connectors for the individual web servers. +

+

+The name of the file is usually uriworkermap.properties, +although this is configurable in the web server. +Please consult the web server specific documentation pages on +how to enable the uriworkermap file. +

+

+The main features supported by the uriworkermap file are +

    +
  • +Support for comments in the rule file. +
  • +
  • +Exact and wildchar matches, shortcuts to map a directory and all including content. +
  • +
  • +Exclusion rules, disabling of rules and rule priorities. +
  • +
  • +Rule extensions, modifying worker behaviour per rule. +
  • +
  • +Virtual host integration: uri mapping rules can be expressed per virtual host. +The details are web server specific though. +
  • +
  • +Dynamic reloading: The file gets checked periodically for changes. +New versions are automatically reloaded without web server restarts. +
  • +
  • +Integration with the status worker. +
  • +
+The following sections describe these aspects in more detail. +

+
Syntax
+
+
Line format
+
+

+The file has a line based format. There are no continuation characters, +so each rule needs to be defined on a single line. Each rule is a pair consisting +of a URI pattern and a worker name, combined by an equals sign '=': +

+  /myapp=myworker
+
+The URI pattern is case sensitive. +

+
+
Comments, white space
+
+

+All text after and including the character '#' gets ignored and can be used for comments. +Leading and trailing white space gets trimmed around the URI pattern and also around the worker name. +The following definitions are all equivalent: +

+  # This is a white space example
+  /myapp=myworker
+     /myapp=myworker
+  /myapp  =  myworker
+
+

+
+ +
URI patterns
+
+

+Inside the URI pattern three special characters can be used, '*', '?' and '|'. +The character '*' is a wildchar that matches any number of arbitrary characters +in the URI, '?' matches exactly one character. +Each URI pattern has to start with the character '/', or with '*' or with '?', +optionally prefixed by any combination of the modifiers '!' and '-' (see next section). +

+  # Mapping the URI /myapp1 and everything under /myapp1/:
+  /myapp1=myworker-a
+  /myapp1/*=myworker-a
+  # Mapping all URI which end with a common suffix:
+  *.jsp=myworker
+  *.do=myworker
+
+Since the first case of mapping a certain location and everything inside +it is very common, the character '|' gives a handy shortcut: +
+  # Mapping the URI /myapp1 and everything under /myapp1/:
+  /myapp1|/*=myworker-a
+
+The pattern 'X|Y' is exactly equivalent to the two maps 'X' and 'XY'. +

+
+
Exclusion, Disabling and Priorities
+
+ +
Exclusions and rule disabling
+
+

+Exclusion rules allows to define exclusions from URI rules, which would forward +requests to tomcat. If the exclusion rule matches, the request will not be forwarded. +This is usually used to serve static content by the web server. +A rule is an exclusion rule, if it is suffixed with '!': +

+  # Mapping the URI /myapp and everything under /myapp/:
+  /myapp|/*=myworker
+  # Exclude the subdirectory static:
+  !/myapp/static|/*=myworker
+  # Exclude some suffixes:
+  !*.html=myworker
+
+An exclusion rule overrides a normal mapping rule only, if the worker names in the +normal rule and in the exclusion rule are the same. Starting with version 1.2.26 of JK +you can apply an exclusion rule to any worker, by using the star character '*' as +the worker name in the exclusion rule. +More complex patterns in exclusion worker names are not allowed. +
+  # Mapping the webapps /myapp1 and /myapp2:
+  /myapp1|/*=myworker1
+  /myapp2|/*=myworker2
+  # Exclude the all subdirectories static for all workers:
+  !/*/static|/*=*
+  # Exclude some suffixes for all workers:
+  !*.html=*
+
+

+

+Rule disabling comes into play, if your web server merges rules from various sources, +and you want to disable any rule defined previously. Since the uriworkermap file gets +reloaded dynamically, you can use this to temporarily disable request forwarding: +A rule gets disabled, if it is suffixed with '-': +

+  # We are not in maintenance.
+  # The maintenance rule got defined somewhere else.
+  -/*=maintenance
+
+Exclusion rules can get disabled as well, then the rule starts with '-!'. +

+
+ +
Mapping priorities
+
+

+The most restrictive URI pattern is applied first. More precisely the URI patterns are +sorted by the number of '/' characters in the pattern (highest number first), and +rules with equal numbers are sorted by their string length (longest first). +

+

+If both distinctions still do not suffice, then the defining source of the rule is considered. +Rules defined in uriworkermap.properties come first, before rules defined by JkMount (Apache) +and inside workers.properties using the mount attribute. +

+

+All disabled rules are ignored. Exclusion rules are applied after all normal rules +have been applied. +

+

+There is no defined behaviour, for the following configuration conflict: +using literally the same URI pattern in the same defining source but with +different worker targets. +

+
+
Rule extensions
+
+

+Rule extensions were added in version 1.2.27 and are not available in earlier versions. +

+
Syntax
+
+

+Rule extensions are additional attributes, that can be attached to any rule. +They are added at the end of the rule, each extension separated by a semicolon: +

+  # This is an extension example,
+  # setting a reply_timeout of 1 minute
+  # only for this mapping.
+  /myapp=myworker;reply_timeout=60000
+  #
+  # This is an example using multiple extensions
+  /myapp=myloadbalancer;reply_timeout=60000;stopped=member1
+
+Attributes set via rule extensions always overwrite conflicting +configurations in the worker definition file. +

+
+
Extension reply_timeout
+
+

+The extension reply_timeout sets a reply timeout for a single mapping rule. +

+  # Setting a reply_timeout of 1 minute
+  # only for this mapping.
+  /myapp=myworker;reply_timeout=60000
+
+It overrides any reply_timeout defined for the worker. The extension allows +to set a reasonable default reply timeout to the worker, and a more relaxed +reply timeout to URLs, which are known to start time intensive tasks. +For a general description of reply timeouts see the +timeouts documentation. +

+
+
Extensions active/disabled/stopped
+
+

+The extensions active, disabled, and stopped +can be used in a load balancer mapping rule to set selected members +of the load balancer into a special activation state. +

+  # Stop forwarding only for member1 of loadbalancer
+  /myapp=myloadbalancer;stopped=member1
+
+Multiple members must be separated by commas or white space: +
+  # Stop forwarding for member01 and member02 of loadbalancer
+  # Disable forwarding for member21 and member22 of loadbalancer
+  /myapp=myloadbalancer;stopped=member01,member02;disabled=member21,member22
+
+For the precise meaning of the activation states see the description of +activation. +

+
+
Extension fail_on_status
+
+

+The extension fail_on_status can be used in any rule: +

+  # Send 503 instead of 404 and 500,
+  # and if we get a 503 also set the worker to error
+  /myapp=myworker;fail_on_status=-404,-500,503
+
+Multiple status codes must be separated by commas. +For the precise meaning of the attribute see the description of +fail_on_status. +

+
+
Extension use_server_errors
+
+

+The extension use_server_errors allows to let the web server +send an error page, instead of the backend (e.g. Tomcat) error page. +This is useful, if one wants to send customized error pages, but those are +not part of all web applications. They can then be put onto the web server. +

+

+The value of use_server_errors is a positive number. +Any request send to the backend, that returns with an http status +code bigger or equal to use_server_errors, will +be answered to the client with the error page of the web server +for this status code. +

+  # Use web server error page for all errors
+  /myapp=myworker;use_server_errors=400
+  # Use web server error page only for technical errors
+  /myotherapp=myworker;use_server_errors=500
+
+

+
+
Virtual host integration
+
+ +
IIS
+
+

+When using IIS you can restrict individual rules to special virtual hosts +by prefixing the URI pattern with the virtual host information. +The rules is that the url must be prefixed with the host name. +

+  # Use www.foo.org as virtual host
+  /www.foo.org/myapp/*=myworker
+  # Use www.bar.org as virtual host
+  /www.bar.org/myapp/*=myworker
+  # Normal mapping
+  /mysecondapp/*=myworker
+
+

+

+Note that /mysecondapp/* will be mapped to all virtual hosts present. +In case one needs to prevent the mappings to some particular virtual host then +the exclusion rule must be used +

+  # Make sure the myapp is accessible by all virtual hosts
+  /myapp/*=myworker
+  # Disable mapping myapp for www.foo.org virtual host
+  !/www.foo.org/myapp/*=myworker
+
+

+
+ +
Apache httpd
+
+

+For Apache you can define individual uriworkermap files per virtual host. +The directive JkMountFile can be used in the main server and in each virtual host. +If a virtual host does not use JkMountfile, but JkMountCopy is set to 'On', +then it inherits the JkMountFile from the main server. If you want all vhost to inherit +mounts from the main server, you can set JkMountCopy to 'All' in the main server. +

+
+
Dynamic reloading
+
+

+When a request is being processed, tomcat connectors check the file modification time +of the uriworkermap file. To keep the performance penalty low, this happens only, +if the last check happened at least n seconds ago. +

+

+For Apache you can configure the interval "n" using the directive JkMountFileReload, +for IIS you would use the attribute worker_mount_reload. +The default value is 60 seconds. A value of "0" turns off the reloading. +

+

+If the file changed, it gets reloaded completely. If there exist rules coming +from other sources than the uriworkermap file (e.g. the workers.properties mount +attribute or JkMount with Apache httpd), the new uriworkermap file gets dynamically +merged with these ones exactly like when you do a web server restart. +

+

+Until version 1.2.19 reloading behaved slightly differently: it continuously added +the full contents of the uriworkermap file to the rule mapping. The merging rules +were, that duplicated got eliminated and old rules could be disabled, by defining the +rule as disabled in the new file. Rules never got deleted. +

+
Status worker integration
+
+

+The configuration view of the status worker also shows the various mapping rules. +After each worker's configuration, the rules are listed, that forward to this worker. +The list contains four columns: +

    +
  • +the name of the virtual server +
  • +
  • +the URI pattern, prefixed with '-' for a disabled pattern and '!' for an exclusion pattern +
  • +
  • +the type of the rule: Exact or Wildchar +
  • +
  • +and the source of the rule definition: 'worker definition' for the workers.properties file (mount attribute), +'JkMount' for Apache httpd JkMount and it's relatives and finally 'uriworkermap' for the uriworkermap file. +
  • +
+

+

+Note: The following restriction has been removed starting with version 1.2.26. +
+For Apache httpd, there is an important subtlety: the request going to the status worker +gets executed in the context of some server (main or virtual). The status worker will only show the +mapping rules, that are defined for this server (main or virtual). +
+Until version 1.2.25 the list contained three columns: +

    +
  • +the type of the rule: Exact or Wildchar, eventually prefixed with Disabled or Unmount (for exclusion rules) +
  • +
  • +the URI pattern +
  • +
  • +and the source of the rule definition: 'worker definition' for the workers.properties file (mount attribute), +'JkMount' for Apache httpd JkMount and it's relatives and finally 'uriworkermap' for the uriworkermap file. +
  • +
+

+

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/printer/workers.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/printer/workers.html new file mode 100644 index 00000000..b2f423a9 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/printer/workers.html @@ -0,0 +1,1000 @@ +The Apache Tomcat Connector - Reference Guide - workers.properties configuration
Apache TomcatApache Logo

The Apache Tomcat Connector - Reference Guide

workers.properties configuration

Introduction
+
+

+A Tomcat worker is a Tomcat instance that is waiting to execute servlets or any other content +on behalf of some web server. For example, we can have a web server such as +Apache forwarding servlet requests to a Tomcat process (the worker) running behind it. +

+

+The scenario described above is a very simple one; +in fact one can configure multiple Tomcat workers to serve servlets on +behalf of a certain web server. +The reasons for such configuration can be: +

+
    +
  • +We want different contexts to be served by different Tomcat workers to provide a +development environment where all the developers share the same web server but +own a Tomcat worker of their own. +
  • +
  • +We want different virtual hosts served by different Tomcat processes to provide a +clear separation between sites belonging to different companies. +
  • +
  • +We want to provide load balancing, meaning run multiple Tomcat workers each on a +machine of its own and distribute the requests between them. +
  • +
+ +

+There are probably more reasons for having multiple workers but I guess that this list is enough... +

+

+Tomcat workers are defined in a properties file dubbed workers.properties and this tutorial +explains how to work with it. +

+
Configuration File Basics
+
+

Defining workers to the Tomcat web server plugin can be done using a properties file +(a sample file named workers.properties is available in the conf/ directory). +

+ +
Format, Comments, Whitespace
+
+

+The lines in the file define properties. The general format is +

+

<name>=<value>

+

+

+Dots are used as part of the name to represent a configuration hierarchy. +

+Invalid directives will be logged during web server startup and prevent the web server +from working properly. Some directives have been deprecated. Although they will +still work, you should replace them by their +successors. +

+

+Some directives are allowed multiple times. This will be explicitly +noted in the tables below. +

+

+Whitespace at the beginning and the end of a property name or value gets ignored. +Comments can be placed in any line and start with a hash sign '#'. +Any line contents behind the hash sign get ignored. +

+
+ +
Global Properties
+
+

+These directives have global scope. +

+
DirectiveDefaultDescription
worker.listajp13 +A comma separated list of workers names that the JK will use. When starting up, +the web server plugin will instantiate the workers whose name appears in the +worker.list property, these are also the workers to whom you can map requests. +

+This directive can be used multiple times. +

+
worker.maintain60 +Worker connection pool maintain interval in seconds. If set to the positive +value JK will scan all connections for all workers specified in worker.list +directive and check if connections needs to be recycled. +

+Furthermore any load balancer does a global maintenance every worker.maintain +seconds. During global maintenance load counters are decayed and workers +in error are checked for recover_time. +

+

+This feature has been added in jk 1.2.13. +

+
+
+ +
Worker Properties
+
+

+Each worker configuration directive consists of three words separated by a dot: +

+

worker.<worker name>.<directive>=<value>

+

+The first word is always worker. +The second word is the worker name you can choose. In the case of load-balancing, +the worker name has an additional meaning. Please consult the +Load Balancer HowTo. +

+

+The name of the worker can contain only the alphanumeric characters +[a-z][A-Z][0-9][_\-] and is case sensitive. +

+
+ +
Variables, Environment Variables
+
+

+You can define and use variables in the workers.properties file. +To define a variable you use the syntax: +

+

<variable_name>=<value>

+

+Dots are allowed in the variable name, but you have to be careful +not to use variable names, that clash with standard directives. +Therefore variable names should never start with "worker.". +

+

+To use a variable, you can insert "$(variable_name)" at any place +on the value side of a property line. If a variable has not been +defined before its use, we will search the process environment for +a variable with the same name and use their value. +

+
+ +
Property Inheritance
+
+

Often one wants to use the same property values for various workers. +To reduce duplication of configuration lines and to ease the maintenance of +the file, you can inherit properties from one worker to another, or even +from a template to real workers. +

+

+The directive "reference" allows to copy configurations between workers +in a hierarchical way. If worker castor sets worker.castor.reference=worker.pollux +then it inherits all properties of pollux, except for the ones that +are explicitly set for castor. +

+

+Please note, that the value of the directive is not only the name of the referred worker, +but the complete prefix including "worker.". +

+

+To use a template worker simply define it like a real worker, but do not add it +to the "worker.list" or as a member to any load balancer. Such a template worker +does not have to contain mandatory directives. This approach is especially useful, +if one has a lot of balanced workers in a load balancer +and these workers share most of their properties. You can set all of these properties +in a template worker, e.g. using the prefix "worker.template1", and then simply +reference those common properties in all balanced workers. +

+

+References can be used to inherit properties over multiple hops in a hierarchical way. +

+

+This feature has been added in jk 1.2.19. +

+
+
List of All Worker Directives
+
+
Mandatory Directives
+
+

Mandatory directives are the one that each worker must contain. Without them the worker will +be unavailable or will misbehave. Those directives will be marked with a strong font in the following tables. +

+
DirectiveDefaultDescription
typeajp13 +Type of the worker (can be one of ajp13, ajp14, jni, lb or status). The type of the worker +defines the directives that can be applied to the worker. +

AJP13 worker is the preferred worker type that JK uses for communication +between web server and Tomcat. This type of worker uses sockets as communication +channel. For detailed description of the AJP13 protocol stack browse to +AJPv13 protocol specification +

+

JNI workers have been deprecated. They will likely not work. Do not use them.

+
+
+ +
Connection Directives
+
+

Connection directives defines the parameters needed to connect and maintain +the connections pool of persistent connections between JK and remote Tomcat. +

+
DirectiveDefaultDescription
hostlocalhost +Host name or IP address of the backend Tomcat instance. The remote Tomcat must +support the ajp13 protocol stack. The host name can have a port number +embedded separated by the colon (':') character. +
port8009 +Port number of the remote Tomcat instance listening for defined protocol requests. +The default value depends on the worker type. For AJP13 workers the default port is +8009, while for AJP14 type of worker that value is 8011. +
socket_timeout0 +Socket timeout in seconds used for the communication channel between JK and remote host. +If the remote host does not respond inside the timeout specified, JK will generate an error, +and retry again. If set to zero (default) JK will wait for an infinite amount of time +on all socket operations. +
socket_connect_timeoutsocket_timeout*1000 +Socket connect timeout in milliseconds used for the communication channel between JK and remote host. +If the remote host does not respond inside the timeout specified, JK will generate an error, +and retry again. +

+Note that socket_timeout is in seconds, and +socket_connect_timeout in milliseconds, +so in absolute terms the default socket_connect_timeout is +equal to "socket_timeout. +

+

+This feature has been added in jk 1.2.27. +

+
socket_keepaliveFalse +This directive should be used when you have a firewall between your webserver +and the Tomcat engine, who tend to drop inactive connections. This flag will tell the Operating System +to send KEEP_ALIVE messages on inactive connections (interval depend on global OS settings, +generally 120 minutes), and thus prevent the firewall to cut inactive connections. +To enable keepalive set this property value to True. +

+The problem with Firewall cutting inactive connections is that sometimes, neither webserver or Tomcat +have information about the cut and couldn't handle it. +

+
ping_mode- +This flag determines, under which conditions established +connections are probed to ensure they are still working. +The probe is done with an empty AJP13 packet (CPing) and +expects to receive an appropriate answer (CPong) within +some timeout. +

+The value of the flag can be any combination of the following +flags (multiple values are combined without any separators): +

+

C (connect): If set, the connection will +be probed once after connecting to the backend. The timeout +can be set by connect_timeout. If it is not set, +the value of ping_timeout will be used instead. +

+

P (prepost): If set, the connection will +be probed before sending each request to the backend. The timeout +can be set by prepost_timeout. If it is not set, +the value of ping_timeout will be used instead. +

+

I (interval): If set, the connection will +be probed during the regular internal maintenance cycle, +but only if it is idle longer than +connection_ping_interval. The timeout +can be set by ping_timeout. +

+

A If set, all of the above probes will be used. +

+

+This feature has been added in jk 1.2.27. Connect and +prepost probing were already available via connect_timeout +and prepost_timeout since version jk 1.2.6. +

+
ping_timeout10000 +Timeout in milliseconds used when waiting for the CPong answer of a +CPing connection probe. The activation of the probes is done via +ping_mode. The timeouts for ping_mode +connect and prepost can be overwritten individually via +connect_timeout and prepost_timeout. +

+For compatibility reasons, CPing/CPong is also used, whenever +connect_timeout or prepost_timeout are set, +even if ping_mode is empty. +

+

+This feature has been added in jk 1.2.27. +

+
connection_ping_interval0 / (ping_timeout/1000)*10 +When using interval connection probing, connections idle for longer than this +interval in seconds are probed by CPing packets whether they still work. +

Interval probing can be activated either by ping_mode, +or by setting connection_ping_interval to some value bigger +than zero. If you activate interval probing via ping_mode, +then the default value of connection_ping_interval is +(ping_timeout/1000) * 10. Note that ping_timeout +is in milliseconds, and connection_ping_interval in seconds, +so in absolute terms the default connection_ping_interval is +10 times ping_timeout. +

+

+This feature has been added in jk 1.2.27. +

+
connection_pool_sizesee text +This defines the number of connections made to the AJP backend that +are maintained as a connection pool. +It will limit the number of those connection that each web server child +process can made. +

+Connection pool size property is only used for multi threaded +web servers such as Apache, IIS and Netscape/Sun. The connection_pool_size property +needs to reflect the number of requests one web server process should +be able to send to a backend in parallel. Usually this is the same as +the number of threads per web server process. JK will discover +this number for the Apache web server automatically and set the pool size to +this value. For IIS the default value is 250 (before version 1.2.20: 10), +for Netscape/Sun the default value is 1. +

+

We strongly recommend adjusting this value for IIS and the Netscape/Sun +to the number of requests one web server process should +be able to send to a backend in parallel. You should measure how many connections +you need during peak activity without performance problems, and then add some +percentage depending on your growth rate. Finally you should check, +whether your web server processes are able to use at least as many threads, +as you configured as the pool size. +

+

Do not use connection_pool_size with values higher then 1 on Apache 2.x prefork or Apache 1.3.x!

+
connection_pool_minsize(pool+1)/2 +Minimum size of the connection pool that will be maintained. +

+Its default value is (connection_pool_size+1)/2. +

+

Do not use connection_pool_size with values higher then 1 on Apache 2.x prefork or Apache 1.3.x!

+

+This feature has been added in jk 1.2.16. +

+
connection_pool_timeout0 +Cache timeout property should be used with connection_pool_minsize to specify how many seconds JK should keep +an inactive socket in cache before closing it. This property should be used to reduce the number of threads +on the Tomcat web server. The default value zero disables the closing (infinite timeout). +

+Each child could open an ajp13 connection if it has to forward a request to Tomcat, creating +a new ajp13 thread on Tomcat side. +

+

+The problem is that after an ajp13 connection is created, the child won't drop it +until killed. And since the webserver will keep its childs/threads running +to handle high-load, even it the child/thread handle only static contents, you could +finish having many unused ajp13 threads on the Tomcat side. +

+

+You should keep this time interval in sync with the connectionTimeout attribute +of your AJP connector in Tomcat's server.xml. Note however, that the value +for mod_jk is given in seconds, the one in server.xml has to use milliseconds. +

+
connection_acquire_timeoutretries*retry_interval +Timeout the worker will wait for a free socket in cache before giving up. +

+Its default value is retries * retry_interval. +

+

+This feature has been added in jk 1.2.27. +

+
lbfactor1 +Only used for a member worker of a load balancer. +

+The integer number lbfactor (load-balancing factor) is +how much we expect this worker to work, or +the worker's work quota. Load balancing factor is compared with other workers +that makes the load balancer. For example if one worker has lb_factor 5 times higher then +other worker, then it will receive five times more requests. +

+
+ +
+ +
Load Balancing Directives
+
+

Load balancer is a virtual worker that does not really communicate with Tomcat workers. +Instead it is responsible for the management of several "real" workers. +The worker is supposed to be a load balancer if it's worker type is lb. +See worker's type directive. +

+

Loadbalancer directives define the parameters needed to create the workers that are +connecting to a remote cluster of backend Tomcat servers. Each cluster node has to +have a worker defined. +

+

+Load balancer management includes: +

+ +
    +
  • +Instantiating the workers in the web server. +
  • +
  • +Using the worker's load-balancing factor, perform weighed-round-robin load balancing where +high lbfactor means stronger machine (that is going to handle more requests) +
  • +
  • +Keeping requests belonging to the same session executing on the same Tomcat worker. +
  • +
  • +Identifying failed Tomcat workers, suspending requests to them and instead fall-backing on +other workers managed by the lb worker. +
  • +
+ +

+The overall result is that workers managed by the same lb worker are load-balanced +(based on their lbfactor and current user session) and also fall-backed so a single +Tomcat process death will not "kill" the entire site. +

+

+If you want to use session stickiness, you must set different jvmRoute attributes +in the Engine element in Tomcat's server.xml. Furthermore the names of the workers +which are managed by the balancer have to be equal to the jvmRoute of the Tomcat +instance they connect with. +

+

+The restriction on the worker names can be lifted, if you use the route attribute for the workers. +

+

+The following table specifies properties that the lb worker can accept: +

+ +
DirectiveDefaultDescription
balance_workers- +A comma separated list of workers that the load balancer +need to manage. +

+This directive can be used multiple times for the same load balancer. +

+

+This directive replaces old balanced_workers directive and +can be used only with mod_jk versions 1.2.7 and up. +

+

As long as these workers should only be used via the load balancer worker, +there is no need to also put them into the worker.list property.

+
sticky_sessionTrue +Specifies whether requests with SESSION ID's should be routed back to the same +Tomcat worker. If sticky_session is set to True or 1 sessions are sticky, otherwise +sticky_session is set to False. Set sticky_session to False when Tomcat +is using a Session Manager which can persist session data across multiple +instances of Tomcat. +
sticky_session_forceFalse +Specifies whether requests with SESSION ID's for workers that are in error state +should be rejected. If sticky_session_force is set to True or 1 +and the worker that matches that SESSION ID is in error state, client will +receive 500 (Server Error). If set to False or 0 failover on +another worker will be issued with loosing client session. This directive is +used only when you set sticky_session=True. +

+This feature has been added in jk 1.2.9. +

+
methodRequest +Specifies what method load balancer is using for electing the best worker. +Please note, that session stickiness and perfect load balancing are +conflicting targets, especially when the number +of sessions is small, or the usage of sessions is extremely varying +For huge numbers of sessions this usually is not a problem. +

+Some methods note, that they aggregate in a sliding time window. They add up +accesses, and on each run of the global maintain method, the load counters +get divided by 2. Usually this happens once a minute, depending on the +setting of worker.maintain. The value of the load counters can be inspected +using the status worker. +

+

+If method is set to R[equest] the balancer will use number of requests +to find the best worker. Accesses will be distributed according to the +lbfactor in a sliding time window. This is the default value and should be +working well for most applications. +

+

+If method is set to S[ession] the balancer will use number of sessions +to find the best worker. Accesses will be distributed according to the +lbfactor in a sliding time window. Because the balancer does not keep any state, +it actually does not know the number of sessions. Instead it counts each request +without a session cookie or URL encoding as a new session. This method will neither +know, when a session is being invalidated, nor will it correct its load numbers +according to session timeouts or worker failover. This method should be used, +if sessions are your limiting resource, e.g. when you only have limited memory +and your sessions need a lot of memory. +

+

+If set to T[raffic] the balancer will use +the network traffic between JK and Tomcat to find the best worker. +Accesses will be distributed according to the lbfactor in a sliding time window. +This method should be used, if network to and from the backends is your +limiting resource. +

+

+If set to B[usyness] the balancer will +pick the worker with the lowest current load, based on how many requests the +worker is currently serving. This number is divided by the workers lbfactor, +and the lowest value (least busy) worker is picked. This method is especially +interesting, if your request take a long time to process, like for a download +application. +

+

+This feature has been added in jk 1.2.9. +The Session method has been added in jk 1.2.20. +

+
lockOptimistic +Specifies what lock method the load balancer will use for synchronising +shared memory runtime data. +If lock is set to O[ptimistic] balancer will not use shared memory lock +to find the best worker. If set to P[essimistic] balancer will use +shared memory lock. The balancer will work more accurately in case of +Pessimistic locking, but can slow down the average response time. +

+This feature has been added in jk 1.2.13. +

+
retries2 +

This directive also exists for normal workers. +For those it has a different meaning.

+If the load balancer can not get a valid member worker or in case of failover, +it will try again a number of times given by retries. +Before each retry, it will make a pause define by retry_interval directive. +

+Until version 1.2.16 the default value was 3. +

+
+ +
+ +
Status Worker Directives
+
+

+The status worker does not communicate with Tomcat. +Instead it is responsible for the load balancer management. +

+
DirectiveDefaultDescription
css- +Specifies the url for cascading stylesheet to use. +
read_onlyFalse +A status worker with read_only=True will not allow any operations, +that change the runtime state or configuration of the other workers. +These are edit/update/reset/recover. +

+This feature has been added in jk 1.2.20. +

+
user- +It is a list of users +which gets compared to the user name authenticated by the web server. +If the name is not contained in this list, access is denied. Per +default the list is empty and then access is allowed to anybody. +

+This directive can be used multiple times. +

+

+This feature has been added in jk 1.2.20. +

+
user_case_insensitiveFalse +By default, the user names are matched case sensitively. You can set +user_case_insensitive=True to make the comparison case insensitive. +This may be especially useful on the Windows platform. +

+This feature has been added in jk 1.2.21. +

+
gooda.o,a.n,a.b,a.r +For every load balancer worker, the status worker shows a summary +of the state of its members. There are three such states, +"good", "bad" and "degraded". +

+These states are determined depending on the activation of the members +(active, disabled, stopped) and their runtime state +(ok, n/a, busy, recovering, probing, forced recovery, error). +By default, members are assumed to be "good", if their activation +is "active" and their runtime state is not "error". +

+

+You can change this mapping, by assigning a list of values to the +attribute "good". Each value gives a possible match for the members, +and one match suffices. Each value is either a single character, or two +characters combined with a dot ".". The single characters are the +first characters in the words "active", "disabled", "stopped", +"ok", "na", "busy", "recovering", "error". The additional states "probing" +and "forced recovery" are always rated equivalent to "recovering". +If a value consists only +of a single character, then all members with this activation or runtime +state will be assumed good. A combination of an activation and a runtime +state concatenated with a dot "." does only apply to a member, that has +exactly this activation and state. +

+

+Members of a load balancer will first be matched against the state "bad", +if they don't match, the state "good" will be tried, and if they +still don't match, their state will be "degraded". +

+

+This directive can be used multiple times. +

+

+This feature has been added in jk 1.2.20. +

+
bads,e +See: "good". +

+By default, members are assumed to be "bad", if their activation +is "stopped" or their runtime state is "error". +

+

+This directive can be used multiple times. +

+

+This feature has been added in jk 1.2.20. +

+
prefixworker +The prefix, which will be used by the status worker +when producing properties output (mime=prop). +Each property key will be prefixed by this value. +

+This feature has been added in jk 1.2.20. +

+
nsjk: +This directive can be used to customise the XML output from the +status worker. If set to - no namespace will be used. +

+This feature has been added in jk 1.2.20. +

+
xmlns- +This directive can be used to customise the XML output from the +status worker. If set to - no xmlns will be used. +

+Default value is set to xmlns:jk="http://tomcat.apache.org" +

+

+This feature has been added in jk 1.2.20. +

+
doctype- +This directive can be used to customise the XML output from the +status worker. This value will be inserted to the output xml +after the xml header. +

+This feature has been added in jk 1.2.20. +

+
+
+ +
Advanced Worker Directives
+
+

+This table lists more advanced configuration options. Most of them only apply to +some types of workers. We use the abbreviations AJP for ajp13/ajp14 workers +used directly via the workers.list, LB for load balancer workers, +and SUB for the workers used indirectly in a load balancer worker +as a sub worker or member. +

+
DirectiveWorker TypeDefaultDescription
connect_timeoutAJP,SUB0 +Connect timeout property told webserver to send a PING request on ajp13 connection after +connection is established. The parameter is the delay in milliseconds to wait for the PONG reply. +The default value zero disables the timeout (infinite timeout). +

+This features has been added in jk 1.2.6 to avoid problem with hung Tomcat's and require ajp13 +ping/pong support which has been implemented on Tomcat 3.3.2+, 4.1.28+ and 5.0.13+. +Disabled by default. +

+
prepost_timeoutAJP,SUB0 +Prepost timeout property told webserver to send a PING request on ajp13 connection before +forwarding to it a request. The parameter is the delay in milliseconds to wait for the PONG reply. +The default value zero disables the timeout (infinite timeout). +

+This features has been added in jk 1.2.6 to avoid problem with hung Tomcat's and require ajp13 +ping/pong support which has been implemented on Tomcat 3.3.2+, 4.1.28+ and 5.0.13+. +Disabled by default. +

+
reply_timeoutAJP,SUB0 +The parameter is the number of milliseconds to wait for success during a read event. +So this is not a timeout for the complete answer time of a request, but only +for the maximum time between two packets received from Tomcat. Usually the longest +pause is between sending the request and getting the first packet of the response. +

+If the timeout passes without any data received from Tomcat, the webserver will +no longer wait for the rest of the response and send an error to the client (browser). +Usually this does not mean, that the request is also aborted on the Tomcat backend. +If the worker is a member of a load balancer, the load balancer might place the +worker into an error state and retry the request on another member. +See also max_reply_timeouts, retries and recovery_options. +

+

+By default (value zero) the webserver will wait forever which could be an issue for you. +If you set a reply_timeout, adjust it carefully if you have long running servlets. +

+

+The reply_timeout can be overwritten using the Apache httpd environment variable +JK_REPLY_TIMEOUT. +

+

+This features has been added in jk 1.2.6 to avoid problem with hung Tomcat's and works on all +servlet engines supporting ajp13. The variable JK_REPLY_TIMEOUT has been added in version 1.2.27. +

+
retriesAJP,SUB2 +

This directive also exists for load balancer workers. +For those it has a different meaning.

+The maximum number of times that the worker will send a request to Tomcat +in case of a communication error. Each retry will be done over another +connection. The first time already gets counted, so retries=2 means +one retry after error. Before a retry, the worker waits for a configurable +sleeping time. +

+See also the attribute recovery_options for a more fine-grained control +of retries and retry_interval for the sleep time configuration. +

+

+Until version 1.2.16 the default value was 3. +

+
retry_intervalAJP,SUB100 +The amount of time in milliseconds the worker sleeps before doing any retry. +

+This features has been added in jk 1.2.27. +

+
recovery_optionsAJP,SUB0 +Recovery options influence, how we should handle retries, +in case we detect a problem with Tomcat. +How often we will retry is controlled by the attribute retries. +

+This attribute is a bit mask. The following bits are allowed:
+1: don't recover if Tomcat failed after getting the request
+2: don't recover if Tomcat failed after sending the headers to client
+4: close the connection to Tomcat, if we detect an error when writing back +the answer to the client (browser)
+8: always recover requests for HTTP method HEAD (even if Bits 1 or 2 are set)
+16: always recover requests for HTTP method GET (even if Bits 1 or 2 are set)
+

+

+This features has been added in jk 1.2.6. +Option 4 has been added in version 1.2.16, +options 8 and 16 in version 1.2.24. +

+
fail_on_statusAJP,SUB0 +Set this value to the HTTP status code that will cause a worker to fail +if returned from Servlet container. Use this directive to deal with +cases when the servlet container can temporary return non-200 responses +for a short amount of time, e.g during redeployment. +

+The error page, headers and status codes of the original response will not be send back +to the client. Instead the request will result in a 503 response. +If the worker is a member of a load balancer, the member will +be put into an error state. Request failover and worker recovery will be handled +with the usual load balancer procedures. +

+

+This feature has been added in jk 1.2.20. +

+

+Starting with jk 1.2.22 it is possible to define multiple +status codes separated by space or comma characters. +For example: worker.xxx.fail_on_status=500,503 +

+

+Starting with jk 1.2.25 you can also tell the load +balancer to not put a member into an error state, if a +response returned with one of the status codes in +fail_on_status. This feature gets enabled, by putting a minus sign in +front of those status codes. +For example: worker.xxx.fail_on_status=-404,-500,503 +

+
max_packet_sizeAJP,SUB8192 +This attribute sets the maximal AJP packet size in Bytes. +The maximum value is 65536. If you change it from the default, +you must also change the packetSize attribute of your AJP +connector on the Tomcat side! The attribute packetSize is only available +in Tomcat 5.5.20+ and 6.0.2+. +

+Normally it is not necessary to change the maximum packet size. Problems +with the default value have been reported when sending certificates or +certificate chains. +

+

+This feature has been added in jk 1.2.19. +

+
mountAJP,LB- +Space delimited list of uri maps the worker should handle. It is only used, +if the worker is included in worker.list. +

+This directive can be used multiple times for the same worker. +

+
secretAJP,LB,SUB- +You can set a secret keyword on the Tomcat AJP Connector. Then only requests +from workers with the same secret keyword will be accepted. +

+Use request.secret="secret key word" in your Tomcat AJP Connector configuration. +

+

+If you set a secret on a load balancer, all its members will inherit this secret. +

+

+This feature has been added in jk 1.2.12. +

+
max_reply_timeoutsLB0 +If you use a reply_timeout for the members of a load balancer worker, +and you want to tolerate a few requests taking longer than reply_timeout, +you can set this attribute to some positive value. +

+Long running requests will still time out after reply_timeout milliseconds waiting for +data, but the corresponding member worker will only be put into an error state, +if more than max_reply_timeouts requests have timed out. +More precisely, the counter for those bad requests will be divided by two, +whenever the load balancer does its internal maintenance (by default every 60 +seconds). +

+

+This features has been added in jk 1.2.24 to make reply_timeout less +sensitive for sporadic long running requests. +

+
recover_timeLB60 +The recover time is the time in seconds the load balancer will not try +to use a worker, after it went into error state. Only after this time has passed, +a worker in error state will be marked as in recovering, so that it will be +tried for new requests. +

+This interval is not checked every time a request is being processed. +Instead it is being checked during global maintenance. The time between two +runs of global maintenance is controlled by worker.maintain. +

+

+Do not set recover_time to a very short time unless you understand the implications. +Every recovery attempt for a worker in error is done by a real request! +

+
error_escalation_timeLBrecover_time / 2 +Setting a member of a load balancer into an error state is quite serious. E.g. +it means that if you need stickyness, all access to the sessions of the +respective node is blocked. +

+Some types of error detection do not provide a precise information, whether +a node is completely broken or not. In those cases an LB will not immediately +put the node into the error state. Only when there have been no successful +responses for error_escalation_time seconds after such an error, +will the node be put into error state. +

+

+This features has been added in jk 1.2.28. +

+
activationSUBActive +Using this directive, a balanced worker of a load balancer +can be configured as disabled or stopped. A disabled worker only gets +requests, which belong to sessions for that worker. A stopped +worker does not get any requests. Users of a stopped worker will +loose their sessions, unless session replication via clustering is used. +

+Use d or D to disable and s or S to stop. +If this directive is not present the deprecated directives +"disabled" or "stopped" are used. +

+

+This flag can be changed at runtime using status worker. +

+

+This feature has been added in jk 1.2.19. +

+
routeSUBworker name +Normally the name of a balanced worker in a load balancer is equal to the jvmRoute +of the corresponding Tomcat instance. If you want to include a worker corresponding +to a Tomcat instance into several load balancers with different balancing configuration +(e.g. disabled, stopped) you can use this attribute. +

+Define a separate worker per lb and per Tomcat instance with an arbitrary worker name and +set the route attribute of the worker equal to the jvmRoute of the target Tomcat instance. +

+

+If this attribute is left empty, the name of the worker will be used. +

+

+This attribute can be changed at runtime using status worker. +

+

+If the route name contains a period, the part before the first period will be +used as domain name, unless domain is set explicitly. +

+

+This feature has been added in jk 1.2.16.
+The automatic domain rule has been added in jk 1.2.20.
+The attribute has been renamed from jvm_route to route in jk 1.2.20. +

+
distanceSUB0 +An integer number to express preferences between +the balanced workers of an lb worker. +A load balancer will never choose some balanced worker +in case there is another usable worker with lower distance. +

+Only in case all workers below a given distance are in error, disabled or stopped, +workers of a larger distance are eligible for balancing. +

+

+This feature has been added in jk 1.2.16. +

+
domainSUB- +Domain directive can be used only when the worker is a member of the load balancer. +Workers that share the same domain name are treated as single worker. If sticky_session +is used, then the domain name is used as session route. +

+This directive is used for large system with more then 6 Tomcats, to be able +to cluster the Tomcats in two groups and thus lowering the session replication +transfer between them. +

+

+This feature has been added in jk 1.2.8. +

+
redirectSUB- +Set to the name of the preferred failover worker. If worker matching +SESSION ID is in error state then the redirect worker will be used instead. +It will be used even if being disabled, thus offering hot standby. +

+If you explicitly set a route via the "route" attribute, you must set "redirect" +to this route of the preferred failover worker and not to its name. +

+

+This feature has been added in jk 1.2.9. +

+
session_cookieLBJSESSIONID +The name of the cookie that contains the routing identifier needed for session stickyness. +The routing identifier is everything after a "." character in the value of the cookie. +

+This feature has been added in jk 1.2.27. +

+
session_pathLB;jsessionid +The name of the path parameter that contains the routing identifier needed for +session stickyness. The routing identifier is everything after a "." character in the value +of the path parameter. +

+This feature has been added in jk 1.2.27. +

+
+
+ +
Deprecated Worker Directives
+
+

The following directives have been deprecated in the past. We include their documentation +in case you need to use an older version of mod_jk. We urge you to update and not use +them any more. Please migrate your existing configurations. +

+
DirectiveSuccessorDefaultDescription
cachesizeconnection_pool_sizesee text +

This directive has been deprecated since 1.2.16.

+Cachesize defines the number of connections made to the AJP backend that +are maintained as a connection pool. +It will limit the number of those connection that each web server child +process can make. +

+Cachesize property is used only for multi threaded +web servers such as Apache 2.0 (worker), IIS and Netscape. The cachesize property +should reflect the number of threads per child process. JK will discover +the number of threads per child process on Apache 2 web server with worker-mpm and set +its default value to match the ThreadsPerChild Apache directive. For IIS the default +value is 10. For other web servers than Apache or IIS this value has to be set manually. +

+

Do not use cachesize with values higher then 1 on Apache 2.x prefork or Apache 1.3.x!

+
cache_timeoutconnection_pool_timeout0 +

This directive has been deprecated since 1.2.16.

+Cache timeout property should be used with cachesize to specify how to time JK should keep +an open socket in cache before closing it. This property should be used to reduce the number of threads +on the Tomcat web server. +

+Each child could open an ajp13 connection if it have to forward a request to Tomcat, creating +a new ajp13 thread on Tomcat side. +

+

+The problem is that after an ajp13 connection is created, the child won't drop it +until killed. And since the webserver will keep its childs/threads running +to handle high-load, even it the child/thread handle only static contents, you could +finish having many unused ajp13 threads on the Tomcat side. +

+
recycle_timeoutconnection_pool_timeout0 +

This directive has been deprecated since 1.2.16.

+The number of seconds that told webserver to cut an ajp13 connection after some time of +inactivity. When choosing an endpoint for a request and the assigned socket is open, it will be +closed if it was not used for the configured time. +It's a good way to ensure that there won't too old threads living on Tomcat side, +with the extra cost you need to reopen the socket next time a request be forwarded. +This property is very similar to cache_timeout but works also in non-cache mode. +If set to value zero (default) no recycle will took place. +
balanced_workersbalance_workers- +

This directive has been deprecated since 1.2.7.

+A comma separated list of workers that the load balancer +need to manage. +
disabledactivationFalse +

This directive has been deprecated since 1.2.19.

+If set to True or 1 the worker will be disabled if member +of load balancer. This flag can be changed at runtime using status worker. +

+This feature has been added in jk 1.2.9. +

+
stoppedactivationFalse +

This directive has been deprecated since 1.2.19.

+If set to True or 1 the worker will be stopped if member +of load balancer. The flag is needed for stop complete traffic of a sticky session +worker. It is only useful, when you have a cluster that replicated the sessions. +This flag can be changed at runtime using status worker. +

+This feature has been added in jk 1.2.11. +

+
jvm_routerouteworker name +

This directive has been deprecated since 1.2.20.

+Normally the name of a balanced worker in a load balancer is equal to the jvmRoute +of the corresponding Tomcat instance. If you want to include a worker corresponding +to a Tomcat instance into several load balancers with different balancing configuration +(e.g. disabled, stopped) you can use this attribute. +

+Define a separate worker per lb and per Tomcat instance with an arbitrary worker name and +set the jvm_route attribute of the worker equal to the jvmRoute of the target Tomcat instance. +

+

+If this attribute is left empty, the name of the worker will be used. +

+

+This attribute can be changed at runtime using status worker. +

+

+This feature has been added in jk 1.2.16. +

+
+
+ +

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/status.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/status.html new file mode 100644 index 00000000..6754bc2a --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/status.html @@ -0,0 +1,547 @@ +The Apache Tomcat Connector - Reference Guide - Status Worker Reference
Apache TomcatApache Logo

Links

Reference Guide

Generic HowTo

Webserver HowTo

AJP Protocol Reference

Miscellaneous Documentation

News

The Apache Tomcat Connector - Reference Guide

Status Worker Reference

Printer Friendly Version
print-friendly
version +
Introduction
+
+

+Tomcat Connectors has a special type of worker, the so-called status worker. +The status worker does not forward requests to Tomcat instances. Instead it allows +to retrieve status and configuration information at runtime, +and furthermore to change many configuration items dynamically. This can be done +via a simple embedded web interface. +

+

+The status worker is especially powerful, when used together with load balancing workers. +

+

+This document does not explain the HTML user interface of the status worker. +Until now it is very simple, so just go ahead and use it. This doc instead +tries to explain the less obvious features of the status worker. We also will give a +complete coverage of the various request parameters and their meaning, so that you can +include the status worker in your automation scripts. +

+

+The documentation of the status worker starts with jk 1.2.20 +

+
Usage Patterns
+
+
Actions
+
+

+The status worker knows about six actions. +

    +
  • +list: lists the configurations and runtime information of all configured workers. +The output will be grouped by global information first (version data), then load balancer +information, after that AJP worker information and finally the legend. For load balancers, +there will be a summary part, and after that details for each member worker. For all workers, +we also include the URL mappings (forward definitions). +
  • +
  • +show: the same as list, but only shows data for one chosen worker +
  • +
  • +edit: produces a form to edit configuration data for a chosen worker. There is a +special subtype of "edit", that makes it easy to change one attribute for all members of +a load balancer, e.g. their activation state. +
  • +
  • +update: commit changes made in an edit form. Caution: the changes will not be +persisted to the configuration files. As soon as your restart your web server, all changes +made through the status worker will be lost! On the other hand, the changes done by the status +worker will be applied during runtime without a restart of the web server. +
  • +
  • +reset: reset all runtime statistics for a worker. +
  • +
  • +recover: Mark a member of a load balancer, that is in error state, for immediate recovery. +
  • +
  • +version: only show version information of the web server and the JK software +
  • +
  • +dump: list the original workers configuration. Caution: the dump will only contain +the configuration that was used during startup. Any changes applied later by the dynamic management +interface of the status worker itself will not be contained in this dump. +The dump action has been added in version 1.2.27. +
  • +
+

+
+ +
Output Format
+
+

+For most actions you can choose between 4 output formats. +

    +
  • +HTML: Used interactively with a browser +
  • +
  • +XML: Mostly useful for automation, when your scripting environment is XML friendly. +This format has rich structure information, but does not work line based, so you would really +like to use it together with XML tools. +
  • +
  • +Properties: This format is a line based format, that conforms to the rules of Java +property files. Most structure information is contained in the hierarchical key. For information, +that is of configuration nature, the format should produce lines very similar to the ones you can +use in workers.properties. It will not produce a complete configuration file! +
  • +
  • +Text: A simple textual output format. +
  • +
+The "edit" action does only make sense for the HTML output type. +

+
+ +
User Interface Features
+
+

+In the HTML view, there is an automatic refresh feature, implemented via the meta refresh +option of HTML. Once you start the automatic refresh, the UI will will respect it for all actions +except edit, update and maintain. Even if you navigate through one of those, the automatic refresh +will start again as soon as you come back to one of the other actions. +

+

+Many parts of the HTML page can be minimised, if they are not interesting for you. There are a couple +of "Hide" links, which will collapse parts of the information. The feature exists for the following +blocks of information: +

    +
  • +Legend: Do not show the legend for the information presented in "list" and "show" actions +
  • +
  • +URI mappings: Do not show the URI mapping for the workers +
  • +
  • +Load Balancing Workers: Do not show workers of type "lb" +
  • +
  • +AJP Workers: Do not show workers of type ajp +
  • +
  • +Balancer Members: Do not show detailed information concerning each member of load balancers +
  • +
  • +Load Balancer Configuration: Do not show configuration data for load balancers +
  • +
  • +Load Balancer Summary: Do not show status summary for load balancers +
  • +
  • +AJP Configuration: Do not show configuration data for ajp workers load balancer members +
  • +
+The last three minimisation features have been added in version 1.2.27. +

+
+ +
Special Considerations concerning URL Maps and Virtual Hosts
+
+

+Note: The following restriction has been removed starting with version 1.2.26. +

+

+The Apache module mod_jk makes use of the internal Apache httpd infrastructure concerning +virtual hosts. The downside of this is, that the status worker can only show URL maps, for +the virtual host it is defined in. It is not able to reach the configuration objects +for other virtual hosts. Of course you can define a status worker in any virtual host you +are using. All information presented apart from the URL maps will be the same, independent +of the virtual host the status worker has been called in. +

+
+ +
Logging
+
+

+The status worker will log changes made to the configuration with log level "info" to the usual +JK log file. Invalid requests will be logged with log level "warn". If you want to report some +broken behaviour, log file content of level "debug" or even "trace" will be useful. +

+
+ +
Configuration
+
+
Basic Configuration
+
+

+The basic configuration of a status worker is very similar to that of a usual ajp worker. +You need to specify a name for the worker, and the URLs you want to map to it. The first +part of the configuration happens in the workers.properties file. We define a worker named +mystatus of type status: +

+worker.list=mystatus
+worker.mystatus.type=status
+
+Then we define a URL, which should be mapped to this worker, i.e. the URL we use +to reach the functionality of the status worker. You can use any method mod_jk supports +for the web server of your choice. Possibilities are maps inside uriworkermap.properties, +an additional mount attribute in workers.properties, or in Apache JkMount. Here's an +example for a uriworkermap.properties line: +
+/private/admin/mystatus=mystatus
+
+The URI pattern is case sensitive. +

+

+As you will learn in the following sections, the status worker is very powerful. You should +use the usual authentication and authorisation methods of your web server to secure this URL. +

+

+You can also define multiple instances of the status worker, by using different names and URL mappings. +For instance you might want to configure them individually +and then allow special groups of people to use them +

+
+ +
Output Customisation
+
+

+There are a couple of attributes for the workers.properties entries, which allow to customise +various aspects of the output of the status worker. +

+

+The attribute css can be set to the URL of a stylesheet: +

+worker.mystatus.css=/private/admin/static/mystatus.css
+
+When writing HTML output, the status worker then includes the line +
+<link rel="stylesheet" type="text/css" href="/private/admin/static/mystatus.css" />
+
+There is no sample stylesheet included with the mod_jk release, and by default the attribute css +is empty, so no stylesheet reference will be included in the pages. The HTML code +of the status worker output pages does not include any class attributes. If you like to contribute a +stylesheet or improvements to the HTML layout, please contact us on the tomcat developers list. +

+

+The properties output format can be customised via the attribute prefix. The names of all +properties the status worker does output, will begin with this prefix. The default is "worker". +

+

+Several attributes influence the format when writing XML output. +The attribute ns allows to set a namespace prefix, that will be used for every status worker+element. +The default is "jk:". Setting it to "-" disables the namespace prefix. +

+

+With the attribute xmlns you can map the prefix to a namespace URL. The default value +is xmlns:jk="http://tomcat.apache.org". Setting it to "-" disables the output of the URL. +

+

+Finally you can specify an XML document type via the attribute doctype. The specified string will +be inserted at the beginning of the document, directly after the xml header. The default is empty. +

+
+ +
Securing Access
+
+

+We urge you to use the builtin access control features of your web server to control +access to the status worker URLs you have chosen. Nevertheless two configuration +attributes of status workers are helpful. The attribute "read_only" disables all features of +the status worker, that can be used to change configurations or runtime status of the other workers. +A read_only status worker will not allow access to the edit, update, reset or recover actions. +The default value is "False", ie. read/write. To enable read_only you need to set it to "True". +

+

+You could configure two status workers, one has read_only and will be made available to a larger +admin group, the other one will be used fully featured, but only by fewer people: +

+worker.list=jk-watch
+worker.jk-watch.type=status
+worker.jk-watch.read_only=True
+worker.jk-watch.mount=/user/status/jk
+worker.list=jk-manage
+worker.jk-manage.type=status
+worker.jk-manage.mount=/admin/status/jk
+
+Starting with version 1.2.21, a read/write status worker can also be switched temporarily +into read-only mode by the user via a link in the HTML GUI. The user can always switch it +back to read/write. Only a status worker configured as read-only via the "read_only" attribute +is completely safe from applying any changes. +

+

+The other attribute you can use is user. By default this list is empty, which means +no limit on the users. You can set "user" to a comma separated list of user names. If your +web server is configured such that it sends the user names with the request, the status worker +will check, if the name attached with the request is contained in it's "user" list. +

+

+The user list can be split over multiple occurrences of the "user" attribute. +

+

+By default, the user names are matched case sensitively. Starting with version 1.2.21 you can set +the attribute user_case_insensitive to "True". Then the comparison will be made case insensitive. +

+
+ +
Service Availability Rating
+
+

+For load balancing workers the status worker shows some interesting overview information. +It categorises the members of the load balancer into the classes "good", "bad" and degraded". +This feature can be combined with external escalation procedures. Depending on your global +system design and your operating practises your preferred categorisation might vary. +

+

+The categorisation is based on the activation state of the workers (active, disabled or stopped), +which is a pure configuration state, and the runtime state +(OK or ERR with possible substates idle, busy, recovering, probing, and forced recovery) +which only depends on the runtime situation. +

+

+The runtime substates have the following meaning: +

    +
  • +OK (idle): This worker didn't receive any request since the last balancer +maintenance. By default balancer maintenance runs every 60 seconds. The +worker should be OK, but since we didn't have to use it for some time, we +can't be sure. This state has been called N/A before version 1.2.24. +
  • +
  • +OK (busy): All connections for this worker are in use for requests. +
  • +
  • +ERROR (recovering): The worker was in error state for some time and is now +marked for recovery. The next request suitable for this worker will use it. +
  • +
  • +ERROR (probing): After setting the worker to recovering, we received a request +suitable for this worker. This request is now using the worker. +
  • +
  • +ERROR (forced recovery): The worker is in error, but we don't have an alternative +worker, so we keep using it. +
  • +
+

+

+By default the status worker groups into "good" all members, that have activation "active" and +runtime state not equal to "error" with empty substate. +The "bad" group consists of the members, that have either activation +"stopped", or are in runtime state "error" with empty substate. +

+

+Workers that fit neither of the two groups, are considered to be "degraded". +

+

+You can define other rules for the grouping into good, bad and degraded. +The two attributes "good" and "bad" can be populated by a comma-separated list ob single characters or +dot-separated pairs. Each character stands for the first character of one of the possible states "active", +"disabled", "stopped", "ok", "idle", "busy", "recovering" and "error". The additional states "probing" +and "forced recovery" are always rated equivalent to "recovering". +Comma-separated entries will be combined +with logical "or", if you combine a configuration and a runtime state with a dot. the are combined with logical +"and". So the default value for "good" is "a.o,a.i,a.b,a.r", for "bad" it is "e,s". +

+

+The status worker first tries to match against the "bad" definitions, if this doesn't succeed +it tries to match against "good", and finally it chooses "degraded", if no "bad" or "good" match +can be found. +

+
+
Request Parameters
+
+

+This section should help you building automation scripts based on the jk status +management interface. This interface is stable in the sense, that we only expect +to add further parameters in the future. Existing parameters from previous versions +will keep their original semantics. We also expect the output formats XML, Properties +and Text to be kept stable. So please use those, if you want to parse status worker +output in your automation scripts. +

+
Actions
+
+

+The action is determined by the parameter cmd. It can have the values "list", "show", +"edit", "update", "reset", "recover", "version" and "dump". If you omit the cmd parameter, +the default "list" will be used. +All actions except for "list", "refresh", "version" and "dump" need additional parameters. +

+

+The action "dump" has been added in version 1.2.27. +

+
+
Output Format
+
+

+The format is determined by the parameter mime. It can have the values "html", "xml", +"txt" and "prop". If you omit the mime parameter, the default "html" +will be used. The action "edit" (the edit form) does only make sense for "mime=html". +

+
+
Worker Selection
+
+

+Actions that operate on a single worker need one or two additional parameters to select +this worker. The parameter w contains the name of the worker from the worker list. +If an action operates on a member (sub worker) of a load balancer, the parameter w +contains the name of the load balancer worker, and the additional parameter sw contains the +name of the sub worker. +

+
+
Automatic Refresh
+
+

+During automatic refresh, the parameter re contain the refresh interval in seconds. +If you omit this parameter, automatic refresh will be off. +

+
+
Hide Options
+
+

+The parameter opt contains a bit mask of activated options. The default is 0, so +by default no options are activated. The following options exist: +

    +
  • +0x0001: hide members of lb workers +
  • +
  • +0x0002: hide URL maps +
  • +
  • +0x0004: hide the legend +
  • +
  • +0x0008: hide load balancer workers +
  • +
  • +0x0010: hide ajp workers +
  • +
  • +0x0020: only allow read_only actions for a read/write status worker. +
  • +
  • +0x0040: hide load balancer configuration +
  • +
  • +0x0080: hide load balancer status summary +
  • +
  • +0x0100: hide configuration for ajp and load balancer member workers +
  • +
+Values 0x0040-0x0100 have been added in version 1.2.27. +

+
+
Data Parameters for the standard Update Action
+
+

+You can use the edit action with a final click to the update button, to change settings of workers. +But you can also make direct calls to the update action. The following request parameters +contain the configuration information, you want to change. First the list for load balancer workers: +

    +
  • +vlr: retries (number) +
  • +
  • +vlt: recover_time (seconds) +
  • +
  • +vlee: error_escalation_time (seconds) +
  • +
  • +vlx: max_reply_timeouts (number) +
  • +
  • +vls: sticky_session (0/f/n/off=off, 1/t/y/on=on; case insensitive) +
  • +
  • +vlf: sticky_session_force (0/f/n/off=off, 1/t/y/on=on; case insensitive) +
  • +
  • +vlm: method (0/r="Requests", 1/t="Traffic", 2/b="Busyness", 3/s="Sessions"; case insensitive, only first character is used) +
  • +
  • +vll: lock (0/o="Optimistic", 1/p="Pessimistic"; case insensitive, only first character is used) +
  • +
+And now the list of parameters you can use to change settings for load balancer members: +
    +
  • +vwa: activation flag (0/a="active", 1/d="disabled", 2/s="stopped"; case insensitive, only first character is used) +
  • +
  • +vwf: load balancing factor (integer weight) +
  • +
  • +vwn: route for use with sticky sessions (string) +
  • +
  • +vwr: redirect to define simple failover rules (string) +
  • +
  • +vwc: domain to tell JK about your replication design (string) +
  • +
  • +vwd: distance to express preferences (integer) +
  • +
+Finally the list of parameters you can use to change settings for ajp workers and ajp load balancer members: +
    +
  • +vahst: host (string) +
  • +
  • +vaprt: port (number) +
  • +
  • +vacpt: connection_pool_timeout (number) +
  • +
  • +vact: connect_timeout (number) +
  • +
  • +vapt: prepost_timeout (number) +
  • +
  • +vart: reply_timeout (number) +
  • +
  • +var: retries (number) +
  • +
  • +varo: recovery_options (number) +
  • +
  • +vamps: max_packet_size (number) +
  • +
+Note that changing the host name or port will only take effect for new connections. +Already established connections to the old address will still be used. +Nevertheless this feature is interesting, because you can provision load balancer +members with port "0", which will automatically be stopped during startup. Later +when you know the final names and ports, you can set them and they will be +automatically activated. +

+

+The leading character "v" has been added to the parameters in version 1.2.27. +Changing settings for ajp workers has also been introduced in version 1.2.27. +

+

+For the details of all parameters, we refer to the workers.properties Reference. +

+
+
Aspect Editing for Load Balancer Members
+
+

+You can use the edit action to edit all settings for a load balancer or for a +member of a load balancer respectively on one page. If you want to edit one +configuration aspect for all members of a load balancer simultaneously, this +will be triggered by the parameter att. The value of the parameter indicates, +which aspect you want to edit. The list is the same as in the previous section, +except for "vahst" and "vaprt": +"vwa", "vwf", "vwn", "vwr", "vwc", "vwd", "vacpt", "vact", "vapt", "vart", "var", +"varo" and "vamps". But here you +need to put the name into the parameter att, instead of using it as a request +parameter name. +

+

+The values of the common aspect for all the load balancer members will be given +in parameters named "val0", "val1", .... +

+
+

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/uriworkermap.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/uriworkermap.html new file mode 100644 index 00000000..f70ee475 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/uriworkermap.html @@ -0,0 +1,378 @@ +The Apache Tomcat Connector - Reference Guide - uriworkermap.properties configuration
Apache TomcatApache Logo

Links

Reference Guide

Generic HowTo

Webserver HowTo

AJP Protocol Reference

Miscellaneous Documentation

News

The Apache Tomcat Connector - Reference Guide

uriworkermap.properties configuration

Printer Friendly Version
print-friendly
version +
Introduction
+
+

+The forwarding of requests from the web server to tomcat gets configured by defining mapping rules. +Such a rule maps requests to workers. The request part of the map is described by a URI pattern, +the worker by it's worker name. +

+

+The so-called uriworkermap file is a mechanism of defining rules, +which works for all web servers. There exist also other web server specific configuration +options for defining rules, which will be mostly discussed on the reference pages for +configuring tomcat connectors for the individual web servers. +

+

+The name of the file is usually uriworkermap.properties, +although this is configurable in the web server. +Please consult the web server specific documentation pages on +how to enable the uriworkermap file. +

+

+The main features supported by the uriworkermap file are +

    +
  • +Support for comments in the rule file. +
  • +
  • +Exact and wildchar matches, shortcuts to map a directory and all including content. +
  • +
  • +Exclusion rules, disabling of rules and rule priorities. +
  • +
  • +Rule extensions, modifying worker behaviour per rule. +
  • +
  • +Virtual host integration: uri mapping rules can be expressed per virtual host. +The details are web server specific though. +
  • +
  • +Dynamic reloading: The file gets checked periodically for changes. +New versions are automatically reloaded without web server restarts. +
  • +
  • +Integration with the status worker. +
  • +
+The following sections describe these aspects in more detail. +

+
Syntax
+
+
Line format
+
+

+The file has a line based format. There are no continuation characters, +so each rule needs to be defined on a single line. Each rule is a pair consisting +of a URI pattern and a worker name, combined by an equals sign '=': +

+  /myapp=myworker
+
+The URI pattern is case sensitive. +

+
+
Comments, white space
+
+

+All text after and including the character '#' gets ignored and can be used for comments. +Leading and trailing white space gets trimmed around the URI pattern and also around the worker name. +The following definitions are all equivalent: +

+  # This is a white space example
+  /myapp=myworker
+     /myapp=myworker
+  /myapp  =  myworker
+
+

+
+ +
URI patterns
+
+

+Inside the URI pattern three special characters can be used, '*', '?' and '|'. +The character '*' is a wildchar that matches any number of arbitrary characters +in the URI, '?' matches exactly one character. +Each URI pattern has to start with the character '/', or with '*' or with '?', +optionally prefixed by any combination of the modifiers '!' and '-' (see next section). +

+  # Mapping the URI /myapp1 and everything under /myapp1/:
+  /myapp1=myworker-a
+  /myapp1/*=myworker-a
+  # Mapping all URI which end with a common suffix:
+  *.jsp=myworker
+  *.do=myworker
+
+Since the first case of mapping a certain location and everything inside +it is very common, the character '|' gives a handy shortcut: +
+  # Mapping the URI /myapp1 and everything under /myapp1/:
+  /myapp1|/*=myworker-a
+
+The pattern 'X|Y' is exactly equivalent to the two maps 'X' and 'XY'. +

+
+
Exclusion, Disabling and Priorities
+
+ +
Exclusions and rule disabling
+
+

+Exclusion rules allows to define exclusions from URI rules, which would forward +requests to tomcat. If the exclusion rule matches, the request will not be forwarded. +This is usually used to serve static content by the web server. +A rule is an exclusion rule, if it is suffixed with '!': +

+  # Mapping the URI /myapp and everything under /myapp/:
+  /myapp|/*=myworker
+  # Exclude the subdirectory static:
+  !/myapp/static|/*=myworker
+  # Exclude some suffixes:
+  !*.html=myworker
+
+An exclusion rule overrides a normal mapping rule only, if the worker names in the +normal rule and in the exclusion rule are the same. Starting with version 1.2.26 of JK +you can apply an exclusion rule to any worker, by using the star character '*' as +the worker name in the exclusion rule. +More complex patterns in exclusion worker names are not allowed. +
+  # Mapping the webapps /myapp1 and /myapp2:
+  /myapp1|/*=myworker1
+  /myapp2|/*=myworker2
+  # Exclude the all subdirectories static for all workers:
+  !/*/static|/*=*
+  # Exclude some suffixes for all workers:
+  !*.html=*
+
+

+

+Rule disabling comes into play, if your web server merges rules from various sources, +and you want to disable any rule defined previously. Since the uriworkermap file gets +reloaded dynamically, you can use this to temporarily disable request forwarding: +A rule gets disabled, if it is suffixed with '-': +

+  # We are not in maintenance.
+  # The maintenance rule got defined somewhere else.
+  -/*=maintenance
+
+Exclusion rules can get disabled as well, then the rule starts with '-!'. +

+
+ +
Mapping priorities
+
+

+The most restrictive URI pattern is applied first. More precisely the URI patterns are +sorted by the number of '/' characters in the pattern (highest number first), and +rules with equal numbers are sorted by their string length (longest first). +

+

+If both distinctions still do not suffice, then the defining source of the rule is considered. +Rules defined in uriworkermap.properties come first, before rules defined by JkMount (Apache) +and inside workers.properties using the mount attribute. +

+

+All disabled rules are ignored. Exclusion rules are applied after all normal rules +have been applied. +

+

+There is no defined behaviour, for the following configuration conflict: +using literally the same URI pattern in the same defining source but with +different worker targets. +

+
+
Rule extensions
+
+

+Rule extensions were added in version 1.2.27 and are not available in earlier versions. +

+
Syntax
+
+

+Rule extensions are additional attributes, that can be attached to any rule. +They are added at the end of the rule, each extension separated by a semicolon: +

+  # This is an extension example,
+  # setting a reply_timeout of 1 minute
+  # only for this mapping.
+  /myapp=myworker;reply_timeout=60000
+  #
+  # This is an example using multiple extensions
+  /myapp=myloadbalancer;reply_timeout=60000;stopped=member1
+
+Attributes set via rule extensions always overwrite conflicting +configurations in the worker definition file. +

+
+
Extension reply_timeout
+
+

+The extension reply_timeout sets a reply timeout for a single mapping rule. +

+  # Setting a reply_timeout of 1 minute
+  # only for this mapping.
+  /myapp=myworker;reply_timeout=60000
+
+It overrides any reply_timeout defined for the worker. The extension allows +to set a reasonable default reply timeout to the worker, and a more relaxed +reply timeout to URLs, which are known to start time intensive tasks. +For a general description of reply timeouts see the +timeouts documentation. +

+
+
Extensions active/disabled/stopped
+
+

+The extensions active, disabled, and stopped +can be used in a load balancer mapping rule to set selected members +of the load balancer into a special activation state. +

+  # Stop forwarding only for member1 of loadbalancer
+  /myapp=myloadbalancer;stopped=member1
+
+Multiple members must be separated by commas or white space: +
+  # Stop forwarding for member01 and member02 of loadbalancer
+  # Disable forwarding for member21 and member22 of loadbalancer
+  /myapp=myloadbalancer;stopped=member01,member02;disabled=member21,member22
+
+For the precise meaning of the activation states see the description of +activation. +

+
+
Extension fail_on_status
+
+

+The extension fail_on_status can be used in any rule: +

+  # Send 503 instead of 404 and 500,
+  # and if we get a 503 also set the worker to error
+  /myapp=myworker;fail_on_status=-404,-500,503
+
+Multiple status codes must be separated by commas. +For the precise meaning of the attribute see the description of +fail_on_status. +

+
+
Extension use_server_errors
+
+

+The extension use_server_errors allows to let the web server +send an error page, instead of the backend (e.g. Tomcat) error page. +This is useful, if one wants to send customized error pages, but those are +not part of all web applications. They can then be put onto the web server. +

+

+The value of use_server_errors is a positive number. +Any request send to the backend, that returns with an http status +code bigger or equal to use_server_errors, will +be answered to the client with the error page of the web server +for this status code. +

+  # Use web server error page for all errors
+  /myapp=myworker;use_server_errors=400
+  # Use web server error page only for technical errors
+  /myotherapp=myworker;use_server_errors=500
+
+

+
+
Virtual host integration
+
+ +
IIS
+
+

+When using IIS you can restrict individual rules to special virtual hosts +by prefixing the URI pattern with the virtual host information. +The rules is that the url must be prefixed with the host name. +

+  # Use www.foo.org as virtual host
+  /www.foo.org/myapp/*=myworker
+  # Use www.bar.org as virtual host
+  /www.bar.org/myapp/*=myworker
+  # Normal mapping
+  /mysecondapp/*=myworker
+
+

+

+Note that /mysecondapp/* will be mapped to all virtual hosts present. +In case one needs to prevent the mappings to some particular virtual host then +the exclusion rule must be used +

+  # Make sure the myapp is accessible by all virtual hosts
+  /myapp/*=myworker
+  # Disable mapping myapp for www.foo.org virtual host
+  !/www.foo.org/myapp/*=myworker
+
+

+
+ +
Apache httpd
+
+

+For Apache you can define individual uriworkermap files per virtual host. +The directive JkMountFile can be used in the main server and in each virtual host. +If a virtual host does not use JkMountfile, but JkMountCopy is set to 'On', +then it inherits the JkMountFile from the main server. If you want all vhost to inherit +mounts from the main server, you can set JkMountCopy to 'All' in the main server. +

+
+
Dynamic reloading
+
+

+When a request is being processed, tomcat connectors check the file modification time +of the uriworkermap file. To keep the performance penalty low, this happens only, +if the last check happened at least n seconds ago. +

+

+For Apache you can configure the interval "n" using the directive JkMountFileReload, +for IIS you would use the attribute worker_mount_reload. +The default value is 60 seconds. A value of "0" turns off the reloading. +

+

+If the file changed, it gets reloaded completely. If there exist rules coming +from other sources than the uriworkermap file (e.g. the workers.properties mount +attribute or JkMount with Apache httpd), the new uriworkermap file gets dynamically +merged with these ones exactly like when you do a web server restart. +

+

+Until version 1.2.19 reloading behaved slightly differently: it continuously added +the full contents of the uriworkermap file to the rule mapping. The merging rules +were, that duplicated got eliminated and old rules could be disabled, by defining the +rule as disabled in the new file. Rules never got deleted. +

+
Status worker integration
+
+

+The configuration view of the status worker also shows the various mapping rules. +After each worker's configuration, the rules are listed, that forward to this worker. +The list contains four columns: +

    +
  • +the name of the virtual server +
  • +
  • +the URI pattern, prefixed with '-' for a disabled pattern and '!' for an exclusion pattern +
  • +
  • +the type of the rule: Exact or Wildchar +
  • +
  • +and the source of the rule definition: 'worker definition' for the workers.properties file (mount attribute), +'JkMount' for Apache httpd JkMount and it's relatives and finally 'uriworkermap' for the uriworkermap file. +
  • +
+

+

+Note: The following restriction has been removed starting with version 1.2.26. +
+For Apache httpd, there is an important subtlety: the request going to the status worker +gets executed in the context of some server (main or virtual). The status worker will only show the +mapping rules, that are defined for this server (main or virtual). +
+Until version 1.2.25 the list contained three columns: +

    +
  • +the type of the rule: Exact or Wildchar, eventually prefixed with Disabled or Unmount (for exclusion rules) +
  • +
  • +the URI pattern +
  • +
  • +and the source of the rule definition: 'worker definition' for the workers.properties file (mount attribute), +'JkMount' for Apache httpd JkMount and it's relatives and finally 'uriworkermap' for the uriworkermap file. +
  • +
+

+

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/workers.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/workers.html new file mode 100644 index 00000000..68b996a7 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/reference/workers.html @@ -0,0 +1,1001 @@ +The Apache Tomcat Connector - Reference Guide - workers.properties configuration
Apache TomcatApache Logo

Links

Reference Guide

Generic HowTo

Webserver HowTo

AJP Protocol Reference

Miscellaneous Documentation

News

The Apache Tomcat Connector - Reference Guide

workers.properties configuration

Printer Friendly Version
print-friendly
version +
Introduction
+
+

+A Tomcat worker is a Tomcat instance that is waiting to execute servlets or any other content +on behalf of some web server. For example, we can have a web server such as +Apache forwarding servlet requests to a Tomcat process (the worker) running behind it. +

+

+The scenario described above is a very simple one; +in fact one can configure multiple Tomcat workers to serve servlets on +behalf of a certain web server. +The reasons for such configuration can be: +

+
    +
  • +We want different contexts to be served by different Tomcat workers to provide a +development environment where all the developers share the same web server but +own a Tomcat worker of their own. +
  • +
  • +We want different virtual hosts served by different Tomcat processes to provide a +clear separation between sites belonging to different companies. +
  • +
  • +We want to provide load balancing, meaning run multiple Tomcat workers each on a +machine of its own and distribute the requests between them. +
  • +
+ +

+There are probably more reasons for having multiple workers but I guess that this list is enough... +

+

+Tomcat workers are defined in a properties file dubbed workers.properties and this tutorial +explains how to work with it. +

+
Configuration File Basics
+
+

Defining workers to the Tomcat web server plugin can be done using a properties file +(a sample file named workers.properties is available in the conf/ directory). +

+ +
Format, Comments, Whitespace
+
+

+The lines in the file define properties. The general format is +

+

<name>=<value>

+

+

+Dots are used as part of the name to represent a configuration hierarchy. +

+Invalid directives will be logged during web server startup and prevent the web server +from working properly. Some directives have been deprecated. Although they will +still work, you should replace them by their +successors. +

+

+Some directives are allowed multiple times. This will be explicitly +noted in the tables below. +

+

+Whitespace at the beginning and the end of a property name or value gets ignored. +Comments can be placed in any line and start with a hash sign '#'. +Any line contents behind the hash sign get ignored. +

+
+ +
Global Properties
+
+

+These directives have global scope. +

+
DirectiveDefaultDescription
worker.listajp13 +A comma separated list of workers names that the JK will use. When starting up, +the web server plugin will instantiate the workers whose name appears in the +worker.list property, these are also the workers to whom you can map requests. +

+This directive can be used multiple times. +

+
worker.maintain60 +Worker connection pool maintain interval in seconds. If set to the positive +value JK will scan all connections for all workers specified in worker.list +directive and check if connections needs to be recycled. +

+Furthermore any load balancer does a global maintenance every worker.maintain +seconds. During global maintenance load counters are decayed and workers +in error are checked for recover_time. +

+

+This feature has been added in jk 1.2.13. +

+
+
+ +
Worker Properties
+
+

+Each worker configuration directive consists of three words separated by a dot: +

+

worker.<worker name>.<directive>=<value>

+

+The first word is always worker. +The second word is the worker name you can choose. In the case of load-balancing, +the worker name has an additional meaning. Please consult the +Load Balancer HowTo. +

+

+The name of the worker can contain only the alphanumeric characters +[a-z][A-Z][0-9][_\-] and is case sensitive. +

+
+ +
Variables, Environment Variables
+
+

+You can define and use variables in the workers.properties file. +To define a variable you use the syntax: +

+

<variable_name>=<value>

+

+Dots are allowed in the variable name, but you have to be careful +not to use variable names, that clash with standard directives. +Therefore variable names should never start with "worker.". +

+

+To use a variable, you can insert "$(variable_name)" at any place +on the value side of a property line. If a variable has not been +defined before its use, we will search the process environment for +a variable with the same name and use their value. +

+
+ +
Property Inheritance
+
+

Often one wants to use the same property values for various workers. +To reduce duplication of configuration lines and to ease the maintenance of +the file, you can inherit properties from one worker to another, or even +from a template to real workers. +

+

+The directive "reference" allows to copy configurations between workers +in a hierarchical way. If worker castor sets worker.castor.reference=worker.pollux +then it inherits all properties of pollux, except for the ones that +are explicitly set for castor. +

+

+Please note, that the value of the directive is not only the name of the referred worker, +but the complete prefix including "worker.". +

+

+To use a template worker simply define it like a real worker, but do not add it +to the "worker.list" or as a member to any load balancer. Such a template worker +does not have to contain mandatory directives. This approach is especially useful, +if one has a lot of balanced workers in a load balancer +and these workers share most of their properties. You can set all of these properties +in a template worker, e.g. using the prefix "worker.template1", and then simply +reference those common properties in all balanced workers. +

+

+References can be used to inherit properties over multiple hops in a hierarchical way. +

+

+This feature has been added in jk 1.2.19. +

+
+
List of All Worker Directives
+
+
Mandatory Directives
+
+

Mandatory directives are the one that each worker must contain. Without them the worker will +be unavailable or will misbehave. Those directives will be marked with a strong font in the following tables. +

+
DirectiveDefaultDescription
typeajp13 +Type of the worker (can be one of ajp13, ajp14, jni, lb or status). The type of the worker +defines the directives that can be applied to the worker. +

AJP13 worker is the preferred worker type that JK uses for communication +between web server and Tomcat. This type of worker uses sockets as communication +channel. For detailed description of the AJP13 protocol stack browse to +AJPv13 protocol specification +

+

JNI workers have been deprecated. They will likely not work. Do not use them.

+
+
+ +
Connection Directives
+
+

Connection directives defines the parameters needed to connect and maintain +the connections pool of persistent connections between JK and remote Tomcat. +

+
DirectiveDefaultDescription
hostlocalhost +Host name or IP address of the backend Tomcat instance. The remote Tomcat must +support the ajp13 protocol stack. The host name can have a port number +embedded separated by the colon (':') character. +
port8009 +Port number of the remote Tomcat instance listening for defined protocol requests. +The default value depends on the worker type. For AJP13 workers the default port is +8009, while for AJP14 type of worker that value is 8011. +
socket_timeout0 +Socket timeout in seconds used for the communication channel between JK and remote host. +If the remote host does not respond inside the timeout specified, JK will generate an error, +and retry again. If set to zero (default) JK will wait for an infinite amount of time +on all socket operations. +
socket_connect_timeoutsocket_timeout*1000 +Socket connect timeout in milliseconds used for the communication channel between JK and remote host. +If the remote host does not respond inside the timeout specified, JK will generate an error, +and retry again. +

+Note that socket_timeout is in seconds, and +socket_connect_timeout in milliseconds, +so in absolute terms the default socket_connect_timeout is +equal to "socket_timeout. +

+

+This feature has been added in jk 1.2.27. +

+
socket_keepaliveFalse +This directive should be used when you have a firewall between your webserver +and the Tomcat engine, who tend to drop inactive connections. This flag will tell the Operating System +to send KEEP_ALIVE messages on inactive connections (interval depend on global OS settings, +generally 120 minutes), and thus prevent the firewall to cut inactive connections. +To enable keepalive set this property value to True. +

+The problem with Firewall cutting inactive connections is that sometimes, neither webserver or Tomcat +have information about the cut and couldn't handle it. +

+
ping_mode- +This flag determines, under which conditions established +connections are probed to ensure they are still working. +The probe is done with an empty AJP13 packet (CPing) and +expects to receive an appropriate answer (CPong) within +some timeout. +

+The value of the flag can be any combination of the following +flags (multiple values are combined without any separators): +

+

C (connect): If set, the connection will +be probed once after connecting to the backend. The timeout +can be set by connect_timeout. If it is not set, +the value of ping_timeout will be used instead. +

+

P (prepost): If set, the connection will +be probed before sending each request to the backend. The timeout +can be set by prepost_timeout. If it is not set, +the value of ping_timeout will be used instead. +

+

I (interval): If set, the connection will +be probed during the regular internal maintenance cycle, +but only if it is idle longer than +connection_ping_interval. The timeout +can be set by ping_timeout. +

+

A If set, all of the above probes will be used. +

+

+This feature has been added in jk 1.2.27. Connect and +prepost probing were already available via connect_timeout +and prepost_timeout since version jk 1.2.6. +

+
ping_timeout10000 +Timeout in milliseconds used when waiting for the CPong answer of a +CPing connection probe. The activation of the probes is done via +ping_mode. The timeouts for ping_mode +connect and prepost can be overwritten individually via +connect_timeout and prepost_timeout. +

+For compatibility reasons, CPing/CPong is also used, whenever +connect_timeout or prepost_timeout are set, +even if ping_mode is empty. +

+

+This feature has been added in jk 1.2.27. +

+
connection_ping_interval0 / (ping_timeout/1000)*10 +When using interval connection probing, connections idle for longer than this +interval in seconds are probed by CPing packets whether they still work. +

Interval probing can be activated either by ping_mode, +or by setting connection_ping_interval to some value bigger +than zero. If you activate interval probing via ping_mode, +then the default value of connection_ping_interval is +(ping_timeout/1000) * 10. Note that ping_timeout +is in milliseconds, and connection_ping_interval in seconds, +so in absolute terms the default connection_ping_interval is +10 times ping_timeout. +

+

+This feature has been added in jk 1.2.27. +

+
connection_pool_sizesee text +This defines the number of connections made to the AJP backend that +are maintained as a connection pool. +It will limit the number of those connection that each web server child +process can made. +

+Connection pool size property is only used for multi threaded +web servers such as Apache, IIS and Netscape/Sun. The connection_pool_size property +needs to reflect the number of requests one web server process should +be able to send to a backend in parallel. Usually this is the same as +the number of threads per web server process. JK will discover +this number for the Apache web server automatically and set the pool size to +this value. For IIS the default value is 250 (before version 1.2.20: 10), +for Netscape/Sun the default value is 1. +

+

We strongly recommend adjusting this value for IIS and the Netscape/Sun +to the number of requests one web server process should +be able to send to a backend in parallel. You should measure how many connections +you need during peak activity without performance problems, and then add some +percentage depending on your growth rate. Finally you should check, +whether your web server processes are able to use at least as many threads, +as you configured as the pool size. +

+

Do not use connection_pool_size with values higher then 1 on Apache 2.x prefork or Apache 1.3.x!

+
connection_pool_minsize(pool+1)/2 +Minimum size of the connection pool that will be maintained. +

+Its default value is (connection_pool_size+1)/2. +

+

Do not use connection_pool_size with values higher then 1 on Apache 2.x prefork or Apache 1.3.x!

+

+This feature has been added in jk 1.2.16. +

+
connection_pool_timeout0 +Cache timeout property should be used with connection_pool_minsize to specify how many seconds JK should keep +an inactive socket in cache before closing it. This property should be used to reduce the number of threads +on the Tomcat web server. The default value zero disables the closing (infinite timeout). +

+Each child could open an ajp13 connection if it has to forward a request to Tomcat, creating +a new ajp13 thread on Tomcat side. +

+

+The problem is that after an ajp13 connection is created, the child won't drop it +until killed. And since the webserver will keep its childs/threads running +to handle high-load, even it the child/thread handle only static contents, you could +finish having many unused ajp13 threads on the Tomcat side. +

+

+You should keep this time interval in sync with the connectionTimeout attribute +of your AJP connector in Tomcat's server.xml. Note however, that the value +for mod_jk is given in seconds, the one in server.xml has to use milliseconds. +

+
connection_acquire_timeoutretries*retry_interval +Timeout the worker will wait for a free socket in cache before giving up. +

+Its default value is retries * retry_interval. +

+

+This feature has been added in jk 1.2.27. +

+
lbfactor1 +Only used for a member worker of a load balancer. +

+The integer number lbfactor (load-balancing factor) is +how much we expect this worker to work, or +the worker's work quota. Load balancing factor is compared with other workers +that makes the load balancer. For example if one worker has lb_factor 5 times higher then +other worker, then it will receive five times more requests. +

+
+ +
+ +
Load Balancing Directives
+
+

Load balancer is a virtual worker that does not really communicate with Tomcat workers. +Instead it is responsible for the management of several "real" workers. +The worker is supposed to be a load balancer if it's worker type is lb. +See worker's type directive. +

+

Loadbalancer directives define the parameters needed to create the workers that are +connecting to a remote cluster of backend Tomcat servers. Each cluster node has to +have a worker defined. +

+

+Load balancer management includes: +

+ +
    +
  • +Instantiating the workers in the web server. +
  • +
  • +Using the worker's load-balancing factor, perform weighed-round-robin load balancing where +high lbfactor means stronger machine (that is going to handle more requests) +
  • +
  • +Keeping requests belonging to the same session executing on the same Tomcat worker. +
  • +
  • +Identifying failed Tomcat workers, suspending requests to them and instead fall-backing on +other workers managed by the lb worker. +
  • +
+ +

+The overall result is that workers managed by the same lb worker are load-balanced +(based on their lbfactor and current user session) and also fall-backed so a single +Tomcat process death will not "kill" the entire site. +

+

+If you want to use session stickiness, you must set different jvmRoute attributes +in the Engine element in Tomcat's server.xml. Furthermore the names of the workers +which are managed by the balancer have to be equal to the jvmRoute of the Tomcat +instance they connect with. +

+

+The restriction on the worker names can be lifted, if you use the route attribute for the workers. +

+

+The following table specifies properties that the lb worker can accept: +

+ +
DirectiveDefaultDescription
balance_workers- +A comma separated list of workers that the load balancer +need to manage. +

+This directive can be used multiple times for the same load balancer. +

+

+This directive replaces old balanced_workers directive and +can be used only with mod_jk versions 1.2.7 and up. +

+

As long as these workers should only be used via the load balancer worker, +there is no need to also put them into the worker.list property.

+
sticky_sessionTrue +Specifies whether requests with SESSION ID's should be routed back to the same +Tomcat worker. If sticky_session is set to True or 1 sessions are sticky, otherwise +sticky_session is set to False. Set sticky_session to False when Tomcat +is using a Session Manager which can persist session data across multiple +instances of Tomcat. +
sticky_session_forceFalse +Specifies whether requests with SESSION ID's for workers that are in error state +should be rejected. If sticky_session_force is set to True or 1 +and the worker that matches that SESSION ID is in error state, client will +receive 500 (Server Error). If set to False or 0 failover on +another worker will be issued with loosing client session. This directive is +used only when you set sticky_session=True. +

+This feature has been added in jk 1.2.9. +

+
methodRequest +Specifies what method load balancer is using for electing the best worker. +Please note, that session stickiness and perfect load balancing are +conflicting targets, especially when the number +of sessions is small, or the usage of sessions is extremely varying +For huge numbers of sessions this usually is not a problem. +

+Some methods note, that they aggregate in a sliding time window. They add up +accesses, and on each run of the global maintain method, the load counters +get divided by 2. Usually this happens once a minute, depending on the +setting of worker.maintain. The value of the load counters can be inspected +using the status worker. +

+

+If method is set to R[equest] the balancer will use number of requests +to find the best worker. Accesses will be distributed according to the +lbfactor in a sliding time window. This is the default value and should be +working well for most applications. +

+

+If method is set to S[ession] the balancer will use number of sessions +to find the best worker. Accesses will be distributed according to the +lbfactor in a sliding time window. Because the balancer does not keep any state, +it actually does not know the number of sessions. Instead it counts each request +without a session cookie or URL encoding as a new session. This method will neither +know, when a session is being invalidated, nor will it correct its load numbers +according to session timeouts or worker failover. This method should be used, +if sessions are your limiting resource, e.g. when you only have limited memory +and your sessions need a lot of memory. +

+

+If set to T[raffic] the balancer will use +the network traffic between JK and Tomcat to find the best worker. +Accesses will be distributed according to the lbfactor in a sliding time window. +This method should be used, if network to and from the backends is your +limiting resource. +

+

+If set to B[usyness] the balancer will +pick the worker with the lowest current load, based on how many requests the +worker is currently serving. This number is divided by the workers lbfactor, +and the lowest value (least busy) worker is picked. This method is especially +interesting, if your request take a long time to process, like for a download +application. +

+

+This feature has been added in jk 1.2.9. +The Session method has been added in jk 1.2.20. +

+
lockOptimistic +Specifies what lock method the load balancer will use for synchronising +shared memory runtime data. +If lock is set to O[ptimistic] balancer will not use shared memory lock +to find the best worker. If set to P[essimistic] balancer will use +shared memory lock. The balancer will work more accurately in case of +Pessimistic locking, but can slow down the average response time. +

+This feature has been added in jk 1.2.13. +

+
retries2 +

This directive also exists for normal workers. +For those it has a different meaning.

+If the load balancer can not get a valid member worker or in case of failover, +it will try again a number of times given by retries. +Before each retry, it will make a pause define by retry_interval directive. +

+Until version 1.2.16 the default value was 3. +

+
+ +
+ +
Status Worker Directives
+
+

+The status worker does not communicate with Tomcat. +Instead it is responsible for the load balancer management. +

+
DirectiveDefaultDescription
css- +Specifies the url for cascading stylesheet to use. +
read_onlyFalse +A status worker with read_only=True will not allow any operations, +that change the runtime state or configuration of the other workers. +These are edit/update/reset/recover. +

+This feature has been added in jk 1.2.20. +

+
user- +It is a list of users +which gets compared to the user name authenticated by the web server. +If the name is not contained in this list, access is denied. Per +default the list is empty and then access is allowed to anybody. +

+This directive can be used multiple times. +

+

+This feature has been added in jk 1.2.20. +

+
user_case_insensitiveFalse +By default, the user names are matched case sensitively. You can set +user_case_insensitive=True to make the comparison case insensitive. +This may be especially useful on the Windows platform. +

+This feature has been added in jk 1.2.21. +

+
gooda.o,a.n,a.b,a.r +For every load balancer worker, the status worker shows a summary +of the state of its members. There are three such states, +"good", "bad" and "degraded". +

+These states are determined depending on the activation of the members +(active, disabled, stopped) and their runtime state +(ok, n/a, busy, recovering, probing, forced recovery, error). +By default, members are assumed to be "good", if their activation +is "active" and their runtime state is not "error". +

+

+You can change this mapping, by assigning a list of values to the +attribute "good". Each value gives a possible match for the members, +and one match suffices. Each value is either a single character, or two +characters combined with a dot ".". The single characters are the +first characters in the words "active", "disabled", "stopped", +"ok", "na", "busy", "recovering", "error". The additional states "probing" +and "forced recovery" are always rated equivalent to "recovering". +If a value consists only +of a single character, then all members with this activation or runtime +state will be assumed good. A combination of an activation and a runtime +state concatenated with a dot "." does only apply to a member, that has +exactly this activation and state. +

+

+Members of a load balancer will first be matched against the state "bad", +if they don't match, the state "good" will be tried, and if they +still don't match, their state will be "degraded". +

+

+This directive can be used multiple times. +

+

+This feature has been added in jk 1.2.20. +

+
bads,e +See: "good". +

+By default, members are assumed to be "bad", if their activation +is "stopped" or their runtime state is "error". +

+

+This directive can be used multiple times. +

+

+This feature has been added in jk 1.2.20. +

+
prefixworker +The prefix, which will be used by the status worker +when producing properties output (mime=prop). +Each property key will be prefixed by this value. +

+This feature has been added in jk 1.2.20. +

+
nsjk: +This directive can be used to customise the XML output from the +status worker. If set to - no namespace will be used. +

+This feature has been added in jk 1.2.20. +

+
xmlns- +This directive can be used to customise the XML output from the +status worker. If set to - no xmlns will be used. +

+Default value is set to xmlns:jk="http://tomcat.apache.org" +

+

+This feature has been added in jk 1.2.20. +

+
doctype- +This directive can be used to customise the XML output from the +status worker. This value will be inserted to the output xml +after the xml header. +

+This feature has been added in jk 1.2.20. +

+
+
+ +
Advanced Worker Directives
+
+

+This table lists more advanced configuration options. Most of them only apply to +some types of workers. We use the abbreviations AJP for ajp13/ajp14 workers +used directly via the workers.list, LB for load balancer workers, +and SUB for the workers used indirectly in a load balancer worker +as a sub worker or member. +

+
DirectiveWorker TypeDefaultDescription
connect_timeoutAJP,SUB0 +Connect timeout property told webserver to send a PING request on ajp13 connection after +connection is established. The parameter is the delay in milliseconds to wait for the PONG reply. +The default value zero disables the timeout (infinite timeout). +

+This features has been added in jk 1.2.6 to avoid problem with hung Tomcat's and require ajp13 +ping/pong support which has been implemented on Tomcat 3.3.2+, 4.1.28+ and 5.0.13+. +Disabled by default. +

+
prepost_timeoutAJP,SUB0 +Prepost timeout property told webserver to send a PING request on ajp13 connection before +forwarding to it a request. The parameter is the delay in milliseconds to wait for the PONG reply. +The default value zero disables the timeout (infinite timeout). +

+This features has been added in jk 1.2.6 to avoid problem with hung Tomcat's and require ajp13 +ping/pong support which has been implemented on Tomcat 3.3.2+, 4.1.28+ and 5.0.13+. +Disabled by default. +

+
reply_timeoutAJP,SUB0 +The parameter is the number of milliseconds to wait for success during a read event. +So this is not a timeout for the complete answer time of a request, but only +for the maximum time between two packets received from Tomcat. Usually the longest +pause is between sending the request and getting the first packet of the response. +

+If the timeout passes without any data received from Tomcat, the webserver will +no longer wait for the rest of the response and send an error to the client (browser). +Usually this does not mean, that the request is also aborted on the Tomcat backend. +If the worker is a member of a load balancer, the load balancer might place the +worker into an error state and retry the request on another member. +See also max_reply_timeouts, retries and recovery_options. +

+

+By default (value zero) the webserver will wait forever which could be an issue for you. +If you set a reply_timeout, adjust it carefully if you have long running servlets. +

+

+The reply_timeout can be overwritten using the Apache httpd environment variable +JK_REPLY_TIMEOUT. +

+

+This features has been added in jk 1.2.6 to avoid problem with hung Tomcat's and works on all +servlet engines supporting ajp13. The variable JK_REPLY_TIMEOUT has been added in version 1.2.27. +

+
retriesAJP,SUB2 +

This directive also exists for load balancer workers. +For those it has a different meaning.

+The maximum number of times that the worker will send a request to Tomcat +in case of a communication error. Each retry will be done over another +connection. The first time already gets counted, so retries=2 means +one retry after error. Before a retry, the worker waits for a configurable +sleeping time. +

+See also the attribute recovery_options for a more fine-grained control +of retries and retry_interval for the sleep time configuration. +

+

+Until version 1.2.16 the default value was 3. +

+
retry_intervalAJP,SUB100 +The amount of time in milliseconds the worker sleeps before doing any retry. +

+This features has been added in jk 1.2.27. +

+
recovery_optionsAJP,SUB0 +Recovery options influence, how we should handle retries, +in case we detect a problem with Tomcat. +How often we will retry is controlled by the attribute retries. +

+This attribute is a bit mask. The following bits are allowed:
+1: don't recover if Tomcat failed after getting the request
+2: don't recover if Tomcat failed after sending the headers to client
+4: close the connection to Tomcat, if we detect an error when writing back +the answer to the client (browser)
+8: always recover requests for HTTP method HEAD (even if Bits 1 or 2 are set)
+16: always recover requests for HTTP method GET (even if Bits 1 or 2 are set)
+

+

+This features has been added in jk 1.2.6. +Option 4 has been added in version 1.2.16, +options 8 and 16 in version 1.2.24. +

+
fail_on_statusAJP,SUB0 +Set this value to the HTTP status code that will cause a worker to fail +if returned from Servlet container. Use this directive to deal with +cases when the servlet container can temporary return non-200 responses +for a short amount of time, e.g during redeployment. +

+The error page, headers and status codes of the original response will not be send back +to the client. Instead the request will result in a 503 response. +If the worker is a member of a load balancer, the member will +be put into an error state. Request failover and worker recovery will be handled +with the usual load balancer procedures. +

+

+This feature has been added in jk 1.2.20. +

+

+Starting with jk 1.2.22 it is possible to define multiple +status codes separated by space or comma characters. +For example: worker.xxx.fail_on_status=500,503 +

+

+Starting with jk 1.2.25 you can also tell the load +balancer to not put a member into an error state, if a +response returned with one of the status codes in +fail_on_status. This feature gets enabled, by putting a minus sign in +front of those status codes. +For example: worker.xxx.fail_on_status=-404,-500,503 +

+
max_packet_sizeAJP,SUB8192 +This attribute sets the maximal AJP packet size in Bytes. +The maximum value is 65536. If you change it from the default, +you must also change the packetSize attribute of your AJP +connector on the Tomcat side! The attribute packetSize is only available +in Tomcat 5.5.20+ and 6.0.2+. +

+Normally it is not necessary to change the maximum packet size. Problems +with the default value have been reported when sending certificates or +certificate chains. +

+

+This feature has been added in jk 1.2.19. +

+
mountAJP,LB- +Space delimited list of uri maps the worker should handle. It is only used, +if the worker is included in worker.list. +

+This directive can be used multiple times for the same worker. +

+
secretAJP,LB,SUB- +You can set a secret keyword on the Tomcat AJP Connector. Then only requests +from workers with the same secret keyword will be accepted. +

+Use request.secret="secret key word" in your Tomcat AJP Connector configuration. +

+

+If you set a secret on a load balancer, all its members will inherit this secret. +

+

+This feature has been added in jk 1.2.12. +

+
max_reply_timeoutsLB0 +If you use a reply_timeout for the members of a load balancer worker, +and you want to tolerate a few requests taking longer than reply_timeout, +you can set this attribute to some positive value. +

+Long running requests will still time out after reply_timeout milliseconds waiting for +data, but the corresponding member worker will only be put into an error state, +if more than max_reply_timeouts requests have timed out. +More precisely, the counter for those bad requests will be divided by two, +whenever the load balancer does its internal maintenance (by default every 60 +seconds). +

+

+This features has been added in jk 1.2.24 to make reply_timeout less +sensitive for sporadic long running requests. +

+
recover_timeLB60 +The recover time is the time in seconds the load balancer will not try +to use a worker, after it went into error state. Only after this time has passed, +a worker in error state will be marked as in recovering, so that it will be +tried for new requests. +

+This interval is not checked every time a request is being processed. +Instead it is being checked during global maintenance. The time between two +runs of global maintenance is controlled by worker.maintain. +

+

+Do not set recover_time to a very short time unless you understand the implications. +Every recovery attempt for a worker in error is done by a real request! +

+
error_escalation_timeLBrecover_time / 2 +Setting a member of a load balancer into an error state is quite serious. E.g. +it means that if you need stickyness, all access to the sessions of the +respective node is blocked. +

+Some types of error detection do not provide a precise information, whether +a node is completely broken or not. In those cases an LB will not immediately +put the node into the error state. Only when there have been no successful +responses for error_escalation_time seconds after such an error, +will the node be put into error state. +

+

+This features has been added in jk 1.2.28. +

+
activationSUBActive +Using this directive, a balanced worker of a load balancer +can be configured as disabled or stopped. A disabled worker only gets +requests, which belong to sessions for that worker. A stopped +worker does not get any requests. Users of a stopped worker will +loose their sessions, unless session replication via clustering is used. +

+Use d or D to disable and s or S to stop. +If this directive is not present the deprecated directives +"disabled" or "stopped" are used. +

+

+This flag can be changed at runtime using status worker. +

+

+This feature has been added in jk 1.2.19. +

+
routeSUBworker name +Normally the name of a balanced worker in a load balancer is equal to the jvmRoute +of the corresponding Tomcat instance. If you want to include a worker corresponding +to a Tomcat instance into several load balancers with different balancing configuration +(e.g. disabled, stopped) you can use this attribute. +

+Define a separate worker per lb and per Tomcat instance with an arbitrary worker name and +set the route attribute of the worker equal to the jvmRoute of the target Tomcat instance. +

+

+If this attribute is left empty, the name of the worker will be used. +

+

+This attribute can be changed at runtime using status worker. +

+

+If the route name contains a period, the part before the first period will be +used as domain name, unless domain is set explicitly. +

+

+This feature has been added in jk 1.2.16.
+The automatic domain rule has been added in jk 1.2.20.
+The attribute has been renamed from jvm_route to route in jk 1.2.20. +

+
distanceSUB0 +An integer number to express preferences between +the balanced workers of an lb worker. +A load balancer will never choose some balanced worker +in case there is another usable worker with lower distance. +

+Only in case all workers below a given distance are in error, disabled or stopped, +workers of a larger distance are eligible for balancing. +

+

+This feature has been added in jk 1.2.16. +

+
domainSUB- +Domain directive can be used only when the worker is a member of the load balancer. +Workers that share the same domain name are treated as single worker. If sticky_session +is used, then the domain name is used as session route. +

+This directive is used for large system with more then 6 Tomcats, to be able +to cluster the Tomcats in two groups and thus lowering the session replication +transfer between them. +

+

+This feature has been added in jk 1.2.8. +

+
redirectSUB- +Set to the name of the preferred failover worker. If worker matching +SESSION ID is in error state then the redirect worker will be used instead. +It will be used even if being disabled, thus offering hot standby. +

+If you explicitly set a route via the "route" attribute, you must set "redirect" +to this route of the preferred failover worker and not to its name. +

+

+This feature has been added in jk 1.2.9. +

+
session_cookieLBJSESSIONID +The name of the cookie that contains the routing identifier needed for session stickyness. +The routing identifier is everything after a "." character in the value of the cookie. +

+This feature has been added in jk 1.2.27. +

+
session_pathLB;jsessionid +The name of the path parameter that contains the routing identifier needed for +session stickyness. The routing identifier is everything after a "." character in the value +of the path parameter. +

+This feature has been added in jk 1.2.27. +

+
+
+ +
Deprecated Worker Directives
+
+

The following directives have been deprecated in the past. We include their documentation +in case you need to use an older version of mod_jk. We urge you to update and not use +them any more. Please migrate your existing configurations. +

+
DirectiveSuccessorDefaultDescription
cachesizeconnection_pool_sizesee text +

This directive has been deprecated since 1.2.16.

+Cachesize defines the number of connections made to the AJP backend that +are maintained as a connection pool. +It will limit the number of those connection that each web server child +process can make. +

+Cachesize property is used only for multi threaded +web servers such as Apache 2.0 (worker), IIS and Netscape. The cachesize property +should reflect the number of threads per child process. JK will discover +the number of threads per child process on Apache 2 web server with worker-mpm and set +its default value to match the ThreadsPerChild Apache directive. For IIS the default +value is 10. For other web servers than Apache or IIS this value has to be set manually. +

+

Do not use cachesize with values higher then 1 on Apache 2.x prefork or Apache 1.3.x!

+
cache_timeoutconnection_pool_timeout0 +

This directive has been deprecated since 1.2.16.

+Cache timeout property should be used with cachesize to specify how to time JK should keep +an open socket in cache before closing it. This property should be used to reduce the number of threads +on the Tomcat web server. +

+Each child could open an ajp13 connection if it have to forward a request to Tomcat, creating +a new ajp13 thread on Tomcat side. +

+

+The problem is that after an ajp13 connection is created, the child won't drop it +until killed. And since the webserver will keep its childs/threads running +to handle high-load, even it the child/thread handle only static contents, you could +finish having many unused ajp13 threads on the Tomcat side. +

+
recycle_timeoutconnection_pool_timeout0 +

This directive has been deprecated since 1.2.16.

+The number of seconds that told webserver to cut an ajp13 connection after some time of +inactivity. When choosing an endpoint for a request and the assigned socket is open, it will be +closed if it was not used for the configured time. +It's a good way to ensure that there won't too old threads living on Tomcat side, +with the extra cost you need to reopen the socket next time a request be forwarded. +This property is very similar to cache_timeout but works also in non-cache mode. +If set to value zero (default) no recycle will took place. +
balanced_workersbalance_workers- +

This directive has been deprecated since 1.2.7.

+A comma separated list of workers that the load balancer +need to manage. +
disabledactivationFalse +

This directive has been deprecated since 1.2.19.

+If set to True or 1 the worker will be disabled if member +of load balancer. This flag can be changed at runtime using status worker. +

+This feature has been added in jk 1.2.9. +

+
stoppedactivationFalse +

This directive has been deprecated since 1.2.19.

+If set to True or 1 the worker will be stopped if member +of load balancer. The flag is needed for stop complete traffic of a sticky session +worker. It is only useful, when you have a cluster that replicated the sessions. +This flag can be changed at runtime using status worker. +

+This feature has been added in jk 1.2.11. +

+
jvm_routerouteworker name +

This directive has been deprecated since 1.2.20.

+Normally the name of a balanced worker in a load balancer is equal to the jvmRoute +of the corresponding Tomcat instance. If you want to include a worker corresponding +to a Tomcat instance into several load balancers with different balancing configuration +(e.g. disabled, stopped) you can use this attribute. +

+Define a separate worker per lb and per Tomcat instance with an arbitrary worker name and +set the jvm_route attribute of the worker equal to the jvmRoute of the target Tomcat instance. +

+

+If this attribute is left empty, the name of the worker will be used. +

+

+This attribute can be changed at runtime using status worker. +

+

+This feature has been added in jk 1.2.16. +

+
+
+ +

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/style.css b/rubbos/app/tomcat-connectors-1.2.32-src/docs/style.css new file mode 100644 index 00000000..ecd0eb81 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/style.css @@ -0,0 +1,73 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +div.screen { + margin: 10px 0px 10px 20px; + font-size: smaller; + color: #ffffff; +} +div.example { + background-color: #e5ecf3; + color: #000; + padding: 0.5em; + margin: 1em 2em 1em 1em; +} +pre { + font-family: "Courier New", Courier, monospace; + font-weight: normal; + font-style: normal; + font-size: smaller; +} +em.screen { + font-weight: normal; + font-style: normal; + color: #c0c0c0; +} +p.screen { + background-color: #000000; + border-style: none; + color: #c0c0c0; + margin-left: 10px; + margin-right: 0px; + text-align: left; +} +b.screen { + font-weight: normal; + font-style: normal; + color: #c0c0c0; +} +code.screen { + background-color: #000000; + border-style: none; + color: #c0c0c0; + margin-left: 10px; + margin-right: 0px; + text-align: left; +} +b.code { + font-weight: normal; + font-style: normal; + color: #023264; +} +p.todo { + background-color: #ffffff; + border-style: none; + color: #000000; + margin-left: 20px; + margin-right: 10px; + text-align: justify; + font-size: smaller; +} diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/webserver_howto/apache.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/webserver_howto/apache.html new file mode 100644 index 00000000..a60cc43c --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/webserver_howto/apache.html @@ -0,0 +1,1124 @@ +The Apache Tomcat Connector - Webserver HowTo - Apache HTTP Server HowTo
Apache TomcatApache Logo

Links

Reference Guide

Generic HowTo

Webserver HowTo

AJP Protocol Reference

Miscellaneous Documentation

News

The Apache Tomcat Connector - Webserver HowTo

Apache HTTP Server HowTo

Printer Friendly Version
print-friendly
version +
Introduction
+

+This document explains how to connect Tomcat to the popular open source web server, Apache httpd. +There is actually three versions of Apache HTTP Server, 1.3, 2.0 and 2.2 and all can be used with mod_jk, +the Tomcat redirector module. +

+ +

+It is recommended that you also read the +Workers HowTo document +to learn how to setup the working entities between your web server and Tomcat Engines. +For more detailed configuration information consult the Reference Guide for +workers.properties, +uriworkermap +and Apache. +

+ +

Waring: If Apache HTTP Server and Tomcat are configured to serve content from +the same filing system location then care must be taken to ensure that httpd is +not able to serve inappropriate content such as the contents of the WEB-INF +directory or JSP source code. This could occur if the httpd DocumentRoot +overlaps with a Tomcat Host's appBase or the docBase of any Context. It could +also occur when using the httpd Alias directive with a Tomcat Host's appBase or +the docBase of any Context. +

+ +

+This document was originally part of Tomcat: A Minimalistic User's Guide written by Gal Shachor, +but has been split off for organisational reasons. +

+ +
Document Conventions and Assumptions
+

+${tomcat_home} is the root directory of tomcat. +Your Tomcat installation should have the following subdirectories: + +

    +
  • +${tomcat_home}\conf - Where you can place various configuration files +
  • +
  • +${tomcat_home}\webapps - Containing example applications +
  • +
  • +${tomcat_home}\bin - Where you place web server plugins +
  • +
+

+

+In all the examples in this document ${tomcat_home} will be /var/tomcat3. +A worker is defined to be a tomcat process that accepts work from the Apache server. +

+
+ +
Supported Configuration
+

+The mod_jk module was developed and tested on: +

    +
  • +Linux, FreeBSD, AIX, HP-UX, MacOS X, Solaris and should works on major Unixes platforms +supporting Apache 1.3 and/or 2.0/2.2 +
  • +
  • +WinNT4.0-i386 SP4/SP5/SP6a (should be able to work with other service packs), Win2K and WinXP and Win98 +
  • +
  • +Cygwin (until you have an apache server and autoconf/automake support tools) +
  • +
  • +Netware +
  • +
  • +i5/OS V5R4 (System I) with Apache HTTP Server 2.0.58. Be sure to have the latest Apache PTF installed. +
  • +
  • +Tomcat 3.2.x, Tomcat 3.3.x, Tomcat 4.0.x, Tomcat 4.1.x, Tomcat 5.0.x, Tomcat 5.5.x and Tomcat 6. +
  • +
+

+ +

+The redirector uses ajp12 and ajp13 to send requests to the Tomcat containers. There is also an option to use Tomcat in process, +more about the in-process mode can be found in the in process howto. +

+
+ +
Who support ajp protocols ?
+

+The ajp12 protocol is only available in Tomcat 3.2.x and 3.3.x. +

+ +

+The ajp12 has been deprecated with Tomcat 3.3.x and you should use instead +ajp13 which is the only ajp protocol known by Tomcat 4.x, 5 and 5.5 and Tomcat 6. +

+ +

+Of course Tomcat 3.2.x and 3.3.x also support ajp13 protocol. +

+ +

+Others servlet engines such as jetty have support for ajp13 protocol +

+ +
+ +
How does it work ?
+

+In a nutshell a web server is waiting for client HTTP requests. +When these requests arrive the server does whatever is needed to serve the +requests by providing the necessary content. +

+ +

+Adding a servlet container may somewhat change this behaviour. +Now the web server needs also to perform the following: +

+ +
    +
  • +Load the servlet container adaptor library and initialise it (prior to serving requests). +
  • +
  • +When a request arrives, it needs to check and see if a certain request belongs to a servlet, +if so it needs to let the adaptor take the request and handle it. +
  • +
+ +

+The adaptor on the other hand needs to know what requests it is going to serve, +usually based on some pattern in the request URL, and to where to direct these requests. +

+ +

+Things are even more complex when the user wants to set a configuration that uses virtual hosts, +or when they want multiple developers to work on the same web server +but on different servlet container JVMs. +We will cover these two cases in the advanced sections. +

+ +
+ +
Obtaining mod_jk
+

+mod_jk can be obtained in two formats - binary and source. +Depending on the platform you are running your web server on, a binary version of mod_jk may be available. +

+ +

+It is recommended to use the binary version if one is available. +If the binary is not available, follow the instructions for building mod_jk from source. +The mod_jk source can be downloaded from a mirror + +here +

+ +

+The binaries for mod_jk are now available for several platforms. +The binaries are located in subdirectories by platform. +

+ +

+For some platforms, such as Windows, this is the typical way of obtaining mod_jk +since most Windows systems do not have C compilers. +

+ +

+For others, the binary distribution of mod_jk offers simpler installation. +

+ +

+For example JK 1.2.x can be downloaded from a mirror + +here (look for JK 1.2 Binary Releases). The "JK 1.2 Binary Releases" link contains binary version for a variety of +operating systems for both Apache 1.3 and Apache 2. +

+ +
Installation
+

+mod_jk requires two entities: + +

    +
  • +mod_jk.xxx - The Apache HTTP Server module, depending on your operating system, it will be mod_jk.so, mod_jk.nlm or +or MOD_JK.SRVPGM (see the build section). +
  • +
  • +workers.properties - A file that describes the host(s) and port(s) used by the workers (Tomcat processes). +A sample workers.properties can be found under the conf directory in the source download. +
  • +
+

+ +

+Also as with other Apache HTTP Server modules, mod_jk should be first installed on the modules directory of your +Apache webserver, ie : /usr/lib/apache and you should update your httpd.conf file. +

+ + +
Disabling old mod_jserv
+

+If you've previously configured Apache to use mod_jserv, remove any ApJServMount directives +from your httpd.conf. +

+ +

If you're including tomcat-apache.conf or tomcat.conf, you'll want to remove them as well - +they are specific to mod_jserv. +

+ +

+The mod_jserv configuration directives are not compatible with mod_jk ! +

+
+ +
Using Tomcat auto-configure
+

+The auto-configure works only for a single Tomcat running on the same machine where Apache HTTP Server is running. +The simplest way to configure Apache HTTP Server to use mod_jk is to turn on the Apache HTTP Server auto-configure setting +in Tomcat and put the following include directive at the end of your Apache httpd.conf file +(make sure you replace $TOMCAT_HOME with the correct path for your Tomcat installation: +

+ +
+    #To be added at the end of your httpd.conf
+    Include $TOMCAT_HOME/conf/jk/mod_jk.conf-auto
+
+ +

+Note: this file may also be generated as $TOMCAT_HOME/conf/auto/mod_jk.conf +

+ +

+This will tell Apache HTTP Server to use directives in the mod_jk.conf-auto file in +the Apache configuration. This file is created by enabling the Apache +auto-configuration by creating your workers.properties file at +$TOMCAT_HOME/conf/jk/workers.properties and adding the listener to the Engine +element in the server.xml file as per the following example. +Please note that this example is specific to Tomcat 5.x, unlike other sections of this document + which also apply to previous Tomcat branches. +

+
+  ...
+  <Engine ...>
+    ...
+    <Listener className="org.apache.jk.config.ApacheConfig" modJk="/path/to/mod_jk.so" />
+    ...
+  </Engine>
+  ...
+
+ +

+Then restart Tomcat and mod_jk.conf should be generated. For more information on +this topic, please refer to the API documentation at the + +Tomcat docs website. +

+ +
+ +
Custom mod_jk configuration
+

+You should use custom configuration when : +

+
    +
  • +You couldn't use mod_jk.conf-auto since Tomcat engine isn't on the same machine that your Apache web server, +ie when you have an Apache in front of a Tomcat Farm. +
  • +
  • +Another case for custom configuration is when your Apache is in front of many different Tomcat engines, +each one having it's own configuration, a general case in ISP hosting +
  • +
  • +Also all Apache webmaster will retain custom configuration to be able to tune the settings +to their real needs. +
  • +
+ +
+ +
Simple configuration example
+

+Here is a simple configuration: +

+ +
+    # Load mod_jk module
+    LoadModule    jk_module  libexec/mod_jk.so
+    # Declare the module for <IfModule directive> (remove this line on Apache 2.0.x)
+    AddModule     mod_jk.c
+    # Where to find workers.properties
+    JkWorkersFile /etc/httpd/conf/workers.properties
+    # Where to put jk shared memory
+    JkShmFile     /var/log/httpd/mod_jk.shm
+    # Where to put jk logs
+    JkLogFile     /var/log/httpd/mod_jk.log
+    # Set the jk log level [debug/error/info]
+    JkLogLevel    info
+    # Select the timestamp log format
+    JkLogStampFormat "[%a %b %d %H:%M:%S %Y] "
+    # Send servlet for context /examples to worker named worker1
+    JkMount  /examples/servlet/* worker1
+    # Send JSPs  for context /examples to worker named worker1
+    JkMount  /examples/*.jsp worker1
+
+ +
+
mod_jk Directives
+

+We'll discuss here the mod_jk directives and details behind them +

+ +
Define workers
+

+JkWorkersFile specify the location where mod_jk will find the workers definitions. + +

+  JkWorkersFile     /etc/httpd/conf/workers.properties
+
+ +
+
+

+
+ +
Logging
+

+JkLogFile specify the location where mod_jk is going to place its log file. +

+ +
+  JkLogFile     /var/log/httpd/mod_jk.log
+
+ +

+Since JK 1.2.3 for Apache 2.0/2.2 and JK 1.2.16 for Apache 1.3 this can also +be used for piped logging: +

+ +
+  JkLogFile     "|/usr/bin/rotatelogs /var/log/httpd/mod_jk.log 86400"
+
+ +

+JkLogLevel +set the log level between : +

+ +
    +
  • +info log will contains standard mod_jk activity (default). +
  • +
  • +error log will contains also error reports. +
  • +
  • +debug log will contains all information on mod_jk activity +
  • +
+ +
+  JkLogLevel    info
+
+ +

+info should be your default selection for normal operations. +
+
+

+ +

+JkLogStampFormat will configure the date/time format found on mod_jk logfile. +Using the strftime() format string it's set by default to "[%a %b %d %H:%M:%S %Y]" +

+ +
+  JkLogStampFormat "[%a %b %d %H:%M:%S %Y] "
+
+ +

+
+
+

+ +

+JkRequestLogFormat will configure the format of mod_jk individual request logging. +Request logging is configured and enabled on a per virtual host basis. +To enable request logging for a virtual host just add a JkRequestLogFormat config. +The syntax of the format string is similar to the Apache LogFormat command, +here is a list of the available request log format options: +

+ +

+ + + + + + + + + + + + + + + + +
OptionsDescription
%bBytes sent, excluding HTTP headers (CLF format)
%BBytes sent, excluding HTTP headers
%HThe request protocol
%mThe request method
%pThe canonical Port of the server serving the request
%qThe query string (prepended with a ? if a query string exists, otherwise an empty string)
%rFirst line of request
%sRequest HTTP status code
%TRequest duration, elapsed time to handle request in seconds '.' micro seconds
%UThe URL path requested, not including any query string.
%vThe canonical ServerName of the server serving the request
%VThe server name according to the UseCanonicalName setting
%wTomcat worker name
%RSession route name (available with 1.2.19 and up)
+ +

+  JkRequestLogFormat     "%w %V %T"
+
+ +
+
+

+ +
+ +
Forwarding
+

+The directive JkOptions allow you to set many forwarding options which will enable (+) +or disable (-) following option. Without any leading signs, options will be enabled. +
+
+

+ +

+The four following options +ForwardURIxxx are mutually exclusive. +Exactly one of them is required, a negative sign prefix is not allowed with them. +The default value is "ForwardURIProxy" since version 1.2.24. +It was "ForwardURICompatUnparsed" in version 1.2.23 and +"ForwardURICompat" until version 1.2.22. +You can turn the default off by switching on one of the other two options. +You should leave this at it's default value, unless you have a very good +reason to change it. +
+
+

+ +

+All options are inherited from the global server to virtual hosts. +Options that support enabling (plus options) and disabling (minus options), +are inherited in the following way: +
+
+options(vhost) = plus_options(global) - minus_options(global) + plus_options(vhost) - minus_options(vhost) +
+
+

+ +

+Using JkOptions ForwardURIProxy, the forwarded URI +will be partially reencoded after processing inside Apache httpd and +before forwarding to Tomcat. This will be compatible with local +URL manipulation by mod_rewrite and with URL encoded session ids. + +

+  JkOptions     +ForwardURIProxy
+
+ +
+
+

+ +

+Using JkOptions ForwardURICompatUnparsed, the forwarded URI +will be unparsed. It's spec compliant and secure. +It will always forward the original request URI, so rewriting +URIs with mod_rewrite and then forwarding the rewritten URI +will not work. + +

+  JkOptions     +ForwardURICompatUnparsed
+
+ +
+
+

+

+Using JkOptions ForwardURICompat, the forwarded URI will +be decoded by Apache httpd. Encoded characters will be decoded and +explicit path components like ".." will already be resolved. +This is less spec compliant and is not safe if you are using +prefix JkMount. This option will allow to rewrite URIs with +mod_rewrite before forwarding. + +

+  JkOptions     +ForwardURICompat
+
+ +
+
+

+

+Using JkOptions ForwardURIEscaped, the forwarded URI will +be the encoded form of the URI used by ForwardURICompat. +Explicit path components like ".." will already be resolved. +This will not work in combination with URL encoded session IDs, +but it will allow to rewrite URIs with mod_rewrite before forwarding. + +

+  JkOptions     +ForwardURIEscaped
+
+ +
+
+

+ +

+JkOptions RejectUnsafeURI will block all +URLs, which contain percent signs '%' or backslashes '\' +after decoding. +
+
+

+

+Most web apps do not use such URLs. Using the option RejectUnsafeURI, you +can block several well known URL encoding attacks. By default, this option +is not set. +

+

+You can also realise such a check with mod_rewrite, which is more powerful +but also slightly more complicated. + +

+  JkOptions     +RejectUnsafeURI
+
+ +
+
+

+ +

+JkOptions ForwardDirectories is used in conjunction with DirectoryIndex +directive of Apache web server. As such mod_dir should be available to Apache, +statically or dynamically (DSO) +
+
+

+ +

+When DirectoryIndex is configured, Apache will create sub-requests for +each of the local-url's specified in the directive, to determine if there is a +local file that matches (this is done by stat-ing the file). +

+ +

+If ForwardDirectories is set to false (default) and Apache doesn't find any +files that match, Apache will serve the content of the directory (if directive +Options specifies Indexes for that directory) or a 403 Forbidden response (if +directive Options doesn't specify Indexes for that directory). +

+ +

+If ForwarDirectories is set to true and Apache doesn't find any files that +match, the request will be forwarded to Tomcat for resolution. This is used in +cases when Apache cannot see the index files on the file system for various +reasons: Tomcat is running on a different machine, the JSP file has been +precompiled etc. +

+ +

Note that locally visible files will take precedence over the +ones visible only to Tomcat (i.e. if Apache can see the file, that's the one +that's going to get served). This is important if there is more then one type of +file that Tomcat normally serves - for instance Velocity pages and JSP pages. + +

+  JkOptions     +ForwardDirectories
+
+
+
+

+ +

+JkOptions ForwardLocalAddress, you ask mod_jk to send the local address, +of the Apache web server instead remote client address. This can be used by +Tomcat remote address valve for allowing connections only from registered Apache +web servers. + +

+  JkOptions     +ForwardLocalAddress
+
+ +
+
+

+ +

+JkOptions FlushPackets, you ask mod_jk to flush Apache's connection +buffer after each AJP packet chunk received from Tomcat. This option can have +a strong performance penalty for Apache and Tomcat as writes are performed +more often than would normally be required (ie: at the end of each +response). + +

+  JkOptions     +FlushPackets
+
+ +
+
+

+ +

+JkOptions FlushHeader, you ask mod_jk to flush Apache's connection +buffer after the response headers have been received from Tomcat. + +

+  JkOptions     +FlushHeader
+
+ +
+
+

+ +

+JkOptions DisableReuse, you ask mod_jk to close connections immediately +after their use. Normally mod_jk uses persistent connections and pools idle +connections to reuse them, when new requests have to be sent to Tomcat. +

+ +

+Using this option will have a strong performance penalty for Apache and Tomcat. +Use this only as a last resort in case of unfixable network problems. +If a firewall between Apache and Tomcat silently kills idle connections, +try to use the worker attribute socket_keepalive in combination with an appropriate +TCP keepalive value in your OS. + +

+  JkOptions     +DisableReuse
+
+ +
+
+

+ +

+JkOptions ForwardKeySize, you ask mod_jk, when using ajp13, to forward also the SSL Key Size as +required by Servlet API 2.3. +This flag shouldn't be set when servlet engine is Tomcat 3.2.x (off by default). + +

+  JkOptions     +ForwardKeySize
+
+ +
+
+

+ +

+JkOptions ForwardSSLCertChain, you ask mod_jk, when using ajp13, +to forward SSL certificate chain (off by default). +Mod_jk only passes the SSL_CLIENT_CERT to the AJP connector. This is not a +problem with self-signed certificates or certificates directly signed by the +root CA certificate. However, there's a large number of certificates signed by +an intermediate CA certificate, where this is a significant problem: A servlet +will not have the possibility to validate the client certificate on its own. The +bug would be fixed by passing on the SSL_CLIENT_CERT_CHAIN to Tomcat via the AJP connector. +
+This directive exists only since version 1.2.22. +

+  JkOptions     +ForwardSSLCertChain
+
+ +
+
+

+ +

+The directive JkEnvVar allows you to forward environment variables +from Apache server to Tomcat engine. +You can add a default value as a second parameter to the directive. +If the default value is not given explicitly, the variable +will only be send, if it is set during runtime. +
+The variables can be retrieved on the Tomcat side as request attributes +via request.getAttribute(attributeName). +Note that the variables send via JkEnvVar will not be listed +in request.getAttributeNames(). +
+
+The variables are inherited from the global server to virtual hosts. + +

+  JkEnvVar     SSL_CLIENT_V_START     undefined
+
+
+
+

+ +
+ +
Assigning URLs to Tomcat
+

+If you have created a custom or local version of mod_jk.conf-local as noted above, +you can change settings such as the workers or URL prefix. +

+ +

+JkMount directive assign specific URLs to Tomcat. +In general the structure of a JkMount directive is: +

+ +
  JkMount [URL prefix] [Worker name]
+ +
+  # send all requests ending in .jsp to worker1
+  JkMount /*.jsp worker1
+  # send all requests ending /servlet to worker1
+  JkMount /*/servlet/ worker1
+  # send all requests jsp requests to files located in /otherworker will go worker2
+  JkMount /otherworker/*.jsp worker2
+
+ +

+You can use the JkMount directive at the top level or inside <VirtualHost> sections of your httpd.conf file. +

+
+ +
Configuring Apache to serve static web application files
+

+If the Tomcat Host appBase (webapps) directory is accessible by the Apache web server, +Apache can be configured to serve web application context directory static files instead +of passing the request to Tomcat. +

+ +

+Caution: For security reasons is is strongly recommended that JkMount is used to +pass all requests to Tomcat by default and JkUnMount is used to explicitly +exclude static content to be served by httpd. It should also be noted that +content served by httpd will bypass any security constraints defined in the +application's web.xml. +

+ +

Use Apache's Alias directive to map a single web application context directory into Apache's +document space for a VirtualHost: +

+ +
+  # Static files in the examples webapp are served by apache
+  Alias /examples /vat/tomcat3/webapps/examples
+  # All requests go to worker1 by default
+  JkMount /* worker1
+  # Serve html, jpg and gif using httpd
+  JkUnMount /*.html worker1
+  JkUnMount /*.jpg  worker1
+  JkUnMount /*.gif  worker1
+
+ +

+Starting with mod_jk 1.2.6 for Apache 2.0/2.2 and 1.2.19 for Apache 1.3, it's possible to exclude some URL/URI from +jk processing by setting the env var no-jk, for example with the SetEnvIf Directive. +

+ +

+You could use no-jk env var to fix problem with mod_alias or mod_userdir +directive when jk and alias/userdir URLs matches. +

+ +
+  # All URL goes to tomcat except the one containing /home
+  <VirtualHost *:80>
+      ServerName testxxx.mysys
+      DocumentRoot /www/testxxx/htdocs
+
+  # Use SetEnvIf to st no-jk when /home/ is encountered
+      SetEnvIf Request_URI "/home/*" no-jk
+
+  # Now /home will goes to /home/dataxxx/
+      Alias /home /home/dataxxx/
+
+      <Directory "/home/dataxxx">
+          Options Indexes MultiViews
+          AllowOverride None
+          Order allow,deny
+          Allow from all
+      </Directory>
+
+      JkMount /* myssys-xxx
+
+  </VirtualHost>
+
+ + +

+Use the mod_jk JkAutoAlias directive to map all web application context directories +into Apache's document space. +

+ +

+Attempts to access the WEB-INF or META-INF directories within a web application context +or a Web Archive *.war within the Tomcat Host appBase (webapps) directory will fail with an +HTTP 403, Access Forbidden +

+ +
+  # Static files in all Tomcat webapp context directories are served by apache
+  JkAutoAlias /var/tomcat3/webapps
+
+  # All requests go to worker1 by default
+  JkMount /* ajp13
+  # Serve html, jpg and gif using httpd
+  JkUnMount /*.html ajp13
+  JkUnMount /*.jpg  ajp13
+  JkUnMount /*.gif  ajp13
+
+ +

+If you encoded all your URLs to contain the session id +(;jsessionid=...), and you later decide, you want to +move part of the content to Apache httpd, you can tell +mod_jk to strip off all session ids from URLs for +those requests, that do not get forwarded via mod_jk. +

+ +

+You enable this feature by setting JkStripSession to On. +It can be enabled individually for virtual servers. The default +value is Off. +

+ +
+
Building mod_jk on Unix
+

+The mod_jk build use the widely used configure system. +

+
Prepare your mod_jk configure from subversion
+In case you get source from subversion, ie without an existing configure script, +you should have autoconf for configuration and installation. +

+To create tomcat-connectors's autoconf script, you will need libtool +1.5.2, automake 1.10 and autoconf 2.59 or newer. The use of more recent +versions is encouraged, e.g. for reliable detection of the features of +recent version of operating systems. +

+Those tools will not be required if you are just using a package downloaded from apache.org, +they are only required for developers. +

+

+To create the configure script just type : + +

[user@host] ~ $ ./buildconf.sh

+

+
+ +
Using configure to build mod_jk
+

Here's how to use configure to prepare mod_jk for building, just type: +

+./configure [autoconf arguments] [tomcat-connectors arguments]
+
+

+ +

+You could set CFLAGS and LDFLAGS to add some platform specifics: +

+ +

[user@host] ~ $ LDFLAGS=-lc ./configure -with-apxs=/home2/local/apache/bin/apxs

+ +

+If you want to build mod_jk for different version of Apache httpd, like 1.3, 2.0 and 2.2, +you need to go through the full build process for each of them. +Please note, that httpd 2.0 and 2.2 modules are not compatible. The mod_jk directory +used is "apache-2.0" in both cases, but you need to compile separately. +

    +
  • +use configure and indicate the correct Apache httpd apxs location (--with-apxs) +
  • +
  • +use make +
  • +
  • +copy the resulting mod_jk.so binary from the apache-1.3 or apache-2.0 subdirectory +to the Apache httpd modules location. +
  • +
  • +make clean (to remove all previously compiled object files) +
  • +
  • +Start over with the apxs location for your next Apache httpd version. +
  • +
+ +

+
+ +
configure arguments
+

+ + + + + + + + + + + + + + + + + + + + + + + + + +
Apache related parameters
--with-apxs[=FILE]FILE is the location of the apxs tool. Default is finding apxs in PATH. +It builds a shared Apache module. It detects automatically the Apache version. +(2.0/2.2 and 1.3)
--with-apache=DIRDIR is the path where apache sources are located. +The apache sources should have been configured before configuring mod_jk. +DIR is something like: /home/apache/apache_1.3.19 +It builds a static Apache module.
--enable-EAPIThis parameter is needed when using Apache-1.3 and mod_ssl, otherwise you will get the error message: +"this module might crash under EAPI!" when loading mod_jk.so in httpd. +Not needed when --with-apxs has been used
--enable-prefork +In case you build mod_jk for a multi-threaded Apache httpd 2.0/2.2 MPM (Multi-Processing Module), +some areas of mod_jk code need to be synchronised to make it thread-safe. +Because configure can not easily detect, whether your are using a multi-threaded MPM, +mod_jk by default is always build thread-safe for Apache httpd 2.0/2.2. +If you are sure, that your MPM is not multi-threaded, you can use "--enable-prefork" +to force the removal of the synchronisation code (thus increasing performance a bit). +For instance, the prefork MPM is not multi-threaded. For Apache httpd 1.3 +this flag will be set automatically.
--disable-trace +When using log level "trace", mod_jk traces a lot of function calls with +"enter" and "exit" log messages. Even if the log level is not "trace", +comparing the log levels to decide about logging has some performance +impact.
+If you use "--disable-trace", then the trace log code doesn't get compiled +into the module binary and you might save some cycles during execution.
+Even with "--disable-trace" logging debug messages with debug log level +will still be possible.
--enable-api-compatibility +Only use httpd API functions available in all httpd production releases +of the chosen major httpd release branch. This improves binary +compatibility of module builds with httpd releases older than the release +against mod_jk is build (only between minor httpd versions).
--enable-flock +In case the operating system supports flock system call use this flag to enable this +faster locks that are implemented as system call instead emulated by GNU C library.
+However those locks does not work on NFS mounted volumes, so you can use +"--enable-flock" during compile time to force the flocks() calls.
+
+ + + + + + + + + + + + + + +
DEPRECATED: JNI related parameters
--enable-jniBuild the JNI worker and so the build process will require +some information about your Java Environment
--with-java-home=DIRDIR is the patch to the JDK root directory. Something like: /opt/java/jdk12
--with-os-type=SUBDIRSUBDIR is the os-type subdirectory, + configure should guess it correctly.
--with-arch-type=SUBDIRSUBDIR is the arch subdirectory, + configure should guess it correctly.
--with-java-platform=VALVAL is the Java platform 1 is 1.1.x and 2 is for 1.2 and higher, + configure should guess it correctly.
+

+

The JNI option has been deprecated. It will likely not work. Do not use it.

+
+ +
Examples of configure use
+ +

Apache 1.3 and 2.0/2.2 build
[user@host] ~ $ ./configure --with-apxs=/usr/sbin/apxs
[user@host] ~ $ make
[user@host] ~ $ cp ./apache-1.3/mod_jk.so /usr/lib/apache
[user@host] ~ $ make clean
[user@host] ~ $ ./configure --with-apxs=/usr/sbin/apxs2
[user@host] ~ $ make
[user@host] ~ $ cp ./apache-2.0/mod_jk.so /usr/lib/apache2

+ +

Apache 2.0/2.2 build with JNI support
[user@host] ~ $ ./configure --with-apxs2=/opt/apache2/bin/apxs \
--with-java-home=${JAVA_HOME} --with-java-platform=2 \
--enable-jni

+

The JNI option has been deprecated. It will likely not work. Do not use it.

+
+ +
Building mod_jk for Apache on Windows NT/2K/XP
+

+The module was developed using Visual C++ version 6.0, so having this environment is a prerequisite +if you want to perform a custom build. +

+

+The steps that you need to take are: +

+
    +
  • +Change directory to the apache 1.3 or apache 2.0 source directory depending on your version of Apache. +
  • +
  • +If you want to build mod_jk for Apache 1.3, set an APACHE1_HOME environment variable which points +to where your Apache 1.3 is installed. +A mod_jk module for Apache 2.0 build will require APACHE2_HOME environment variable to be set. +
  • +
  • +Copy mod_jk.so to Apache's modules directory. +
  • +
+

+An example on how to build mod_jk for Apache 1.3: +

+

Set location for Apache 1.3 sources
c:\>set APACHE1_HOME=c:\apache13
Change directory to the mod_jk module for Apache 1.3
c:\>cd c:\home\apache\jk\native\apache-1.3
Build the sources using MSDEV
c:\>MSDEV mod_jk.dsp /MAKE ALL
Copy the dll to your apache modules directory
c:\>cp release\mod_jk.so c:\apache13\modules\

+ +

+An example on how to build mod_jk for Apache 2.0: +

+

Set location for Apache 2.0 sources
c:\>set APACHE2_HOME=c:\apache20
Change directory to the mod_jk module for Apache 2.0
c:\>cd c:\home\apache\jk\native\apache-2.0
Build the sources using MSDEV
c:\>MSDEV mod_jk.dsp /MAKE ALL
Copy the dll to your apache modules directory
c:\>cp release\mod_jk.so c:\apache20\modules\

+ +

+If msdev is not in your path, enter the full path to msdev.exe. +Also, ApacheCore.lib is expected to exist in the ${APACHEX_HOME}\src\CoreD and +${APACHEX_HOME}\src\CoreR directories before linking will succeed. +You will need to build enough of the Apache source to create these libraries. +This will build both release and debug versions of the redirector plug-in (mod_jk). +An alternative will be to open mod_jk.dsp in msdev and build it using the build menu. +

+
Building mod_jk for Apache on System I - i5/OS (OS400)
+

+Since OS400 V4R5, System I (AS/400) has used Apache 2.0 as their primary web server, +replacing the old IBM webserver. +It's now possible to build mod_jk on System I thanks to the help of the IBM +Rochester Labs which has provided information and patches to adapt mod_jk to i5/OS. +

+

+You should have at least Apache 2.0.58 (product 5722DG1), a C Compiler and IFS. +Apache 2.0.58 is provided with the most recent set of PTFs for the iSeries Apache +server, which can be found at +http://www.ibm.com/servers/eserver/iseries/software/http/ +

+

+The all latest Apache 2 for i5/OS V5R3 (or V5R4) is now 2.0.58 (as of 2007/04/17). +Be sure to have the latest PTFs loaded if you want to make use of jk 1.2.15 and higher. +NB: The latest mod_jk known to work on i5/OS V5R3 was 1.2.19. +

+

+New in i5/OS V5R4, UTF is required, also for Apache modules, as such Apache modules do not require +translations to/from EBCDIC but works should be done to port mod_jk 1.2.23 (and higher) to V5R4. + +From the V5R4 Infocenter : + +As of i5/OS(tm) V5R4, modules must be recompiled with a UTF locale. This creates an environment where locale-dependent C runtime functions assume +that string data is encoded in UTF-8. Any hardcoded constants can be encoded in UTF-8 by adding a #pragma convert(1208) statement in the module. +Additionally, input data from the client will no longer be converted to EBCDIC but will be passed as-is. +Output data sent from the module is not converted either so it must be encoded in ASCII or UTF8 as required. +APR and HTTP APIs as of V5R4, expect data in UTF-8. Note that several APIs have additional functions that allow a CCSID to be set to +indicate the encoding of the parameters being passed. Conversion functions between UTF-8 and EBCDIC have been added. +Be sure to review APIs used by your module to be aware of current changes. + +

+

+To configure mod_jk on System I use the CL source provided with the mod_jk source. +

+
    +
  • +Get the latest mod_jk source and untar it on a Windows or Unix boxes +
  • +
  • +Create a directory in IFS, ie /home/apache +
  • +
  • +Send the whole jk source directory to System I directory via FTP. +
  • +
  • +Then go to the System I command line : +
  • +
+

Create mod_jk library
===>CRTLIB MOD_JK TEXT(‘Apache mod'jk tomcat connector module')
Create service program source file
===>CRTSRCPF MOD_JK/QSRVSRC TEXT(‘Service program source file’)
Create the CL build program source file
===>CRTSRCPF FILE(MOD_JK/QCLSRC) TEXT(‘Build program source file’)
Edit the service program source file
===>STRSEU MOD_JK/QSRVSRC MOD_JK

+

+In the edited file, specify that only jk_module should be exported : +

Columns . . : 1 71 Edit MOD_JK/QSRVSRC
SEU==> MOD_JK
*************** Beginning of data *************************************
0001.00 STRPGMEXP PGMLVL(*CURRENT)
0002.00 EXPORT SYMBOL("jk_module")
0003.00 ENDPGMEXP
****************** End of data ****************************************

+

+

+You could start to build all the modules of mod_jk (cases for V5R4 or previous releases): +

+

Copy the CL build program source for i5/OS before V5R4 from IFS
===>CPYFRMSTMF FROMSTMF('/home/apache/jk/native/apache-2.0/bldjk.qclsrc') +
TOMBR('/QSYS.LIB/MOD_JK.LIB/QCLSRC.FILE/BLDJK.MBR') MBROPT(*REPLACE)
Build the CL build program
===>CRTCLPGM PGM(MOD_JK/BLDJK) SRCFILE(MOD_JK/QCLSRC) TEXT('Apache mod_jk build program')
Launch the build
===>CALL MOD_JK/BLDJK
If the build if successfull, copy the new mod_jk module
===>CRTDUPOBJ OBJ(MOD_JK) FROMLIB(MOD_JK) OBJTYPE(*SRVPGM) TOLIB(QHTTPSVR) NEWOBJ(MOD_JK)

+

Copy the CL build program source for i5/OS V5R4 from IFS
===>CPYFRMSTMF FROMSTMF('/home/apache/jk/native/apache-2.0/bldjk54.qclsrc') +
TOMBR('/QSYS.LIB/MOD_JK.LIB/QCLSRC.FILE/BLDJK54.MBR') MBROPT(*REPLACE)
Build the CL build program for i5/OS V5R4
===>CRTCLPGM PGM(MOD_JK/BLDJK54) SRCFILE(MOD_JK/QCLSRC) TEXT('Apache mod_jk build program') TGTRLS(*CURRENT)
Launch the build for i5/OS V5R4
===>CALL MOD_JK/BLDJK54
If the build if successfull, copy the new mod_jk module
===>CRTDUPOBJ OBJ(MOD_JK) FROMLIB(MOD_JK) OBJTYPE(*SRVPGM) TOLIB(QHTTPSVR) NEWOBJ(MOD_JK)

+

+Next, you should restart your Apache 2.0 instance and enjoy this piece of OpenSource on System I. +

+

ENDTCPSVR SERVER(*HTTP) HTTPSVR(MYSERVER)
STRTCPSVR SERVER(*HTTP) HTTPSVR(MYSERVER)

+
Building mod_jk for Apache on MacOS/X
+

+Mac OS X (10.2.x) build notes : +

+

+Assuming that you are root : +

+

For Apache 1.3:
[user@host] ~ $ ./configure --with-apxs=/usr/sbin/apxs
[user@host] ~ $ cd apache-1.3
[user@host] ~ $ make -f Makefile.apxs
[user@host] ~ $ cp mod_jk.so /etc/libexec/httpd
For Apache 2.0:
[user@host] ~ $ ./configure --with-apxs=/usr/local/apache2/bin/apxs
(you should point to the directory where you installed Apache 2.0)
[user@host] ~ $ cd apache-2.0
[user@host] ~ $ make -f Makefile.apxs install

+
Getting mod_jk linked statically with Apache
+

+mod_jk allows to install mod_jk in the Apache source tree to get a statically +linked mod_jk. Having mod_jk in the httpd executable brings some performance +improvements. The configure option --with-apache prepare mod_jk to install it +in the Apache source tree. +The option --with-apache works both for Apache-1.3 and Apache-2.0. +The examples below show how to get mod_jk in the httpd process. +

+ +
Installation in Apache-2.0
+

/home/apache20/httpd-2.0.43 is the directory where the httpd-2.0 sources +are located.
[user@host] ~ $ ./configure --with-apache=/home/apache20/httpd-2.0.43
[user@host] ~ $ make
Install the mod_jk library and other files in +/home/apache20/httpd-2.0.43/modules:
[user@host] ~ $ make install
It is not possible to configure Apache directly because the config.m4 of mod_jk must +be added to the configure of httpd-2.0.
[user@host] ~ $ cd /home/apache20/httpd-2.0.43
[user@host] ~ $ sh buildconf
[user@host] ~ $ configure ... --with-mod_jk
[user@host] ~ $ make
[user@host] ~ $ make install

+

+The enable-jk=share and enable-jk=static are not supported. --with-mod_jk only +allow static linking of mod_jk. +

+
+ +
Installation in Apache-1.3
+

/home/apache/apache_1.3.27 is the directory where the apache-1.3 sources +are located.
[user@host] ~ $ ./configure --with-apache=/home/apache/apache_1.3.27
[user@host] ~ $ make
Install the libjk library, mod_jk.c, includes and other files in +/home/apache/apache_1.3.27/src/modules/jk:
[user@host] ~ $ make install
Configure in the Apache sources:
[user@host] ~ $ cd /home/apache/apache_1.3.27
[user@host] ~ $ configure ... --enable-module=dir --disable-shared=dir \
--activate-module=src/modules/jk/libjk.a \
--disable-shared=jk
[user@host] ~ $ make
[user@host] ~ $ make install

+

+The --enable-shared=jk is also working and builds a dso file. +

+

Just change the configure in the Apache sources:
[user@host] ~ $ configure ... --enable-module=dir --enable-shared=dir \
--activate-module=src/modules/jk/libjk.a \
--enable-shared=jk

+
+ +

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/webserver_howto/iis.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/webserver_howto/iis.html new file mode 100644 index 00000000..5dc4ea1b --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/webserver_howto/iis.html @@ -0,0 +1,685 @@ +The Apache Tomcat Connector - Webserver HowTo - IIS HowTo
Apache TomcatApache Logo

Links

Reference Guide

Generic HowTo

Webserver HowTo

AJP Protocol Reference

Miscellaneous Documentation

News

The Apache Tomcat Connector - Webserver HowTo

IIS HowTo

Printer Friendly Version
print-friendly
version +
Introduction
+

+This document explains how to set up IIS to cooperate with Tomcat. +

+ +

+Normally IIS can not execute Servlets and Java Server Pages (JSPs), +configuring IIS to use the JK ISAPI redirector plugin will let IIS send servlet and +JSP requests to Tomcat (and this way, serve them to clients). +

+ +

+It is recommended that you also read the +Workers HowTo document +to learn how to setup the working entities between your web server and Tomcat Engines. +For more detailed configuration information consult the Reference Guide for +workers.properties, +uriworkermap +and IIS. +

+ + +
Document Conventions and Assumptions
+

+${tomcat_home} is the root directory of tomcat. +Your Tomcat installation should have the following subdirectories: + +

    +
  • +${tomcat_home}\conf - Where you can place various configuration files +
  • +
  • +${tomcat_home}\webapps - Containing example applications +
  • +
  • +${tomcat_home}\bin - Where you place web server plugins +
  • +
+

+

+In all the examples in this document ${tomcat_home} will be c:\tomcat. +A worker is defined to be a tomcat process that accepts work from the IIS server. +

+
+ + +
Supported Configuration
+

+The IIS-Tomcat redirector was developed and tested on: +

    +
  • +WinNT4.0-i386 SP4/SP5/SP6a (should be able to work with other service packs), Win2K and WinXP and Win98 +
  • +
  • +IIS4.0 and PWS4.0 (numerous people have working IIS 5 and IIS 6 configurations) +
  • +
  • +Tomcat 3.2 and later, Tomcat 4.x, Tomcat 5 and 5.5 and Tomcat 6 +
  • +
+

+ +

+The redirector uses ajp12 and ajp13 to send requests to the Tomcat containers. There is also an option to use Tomcat in process, +more about the in-process mode can be found in the in process howto. +

+
+ +
IIS 5 and 6 Notes
+

+There are extra steps you need to take for configuring Tomcat with IIS 5 and 6. Please see the appropriate links from +Tomcat Useful Links. +

+
+ +
IIS 7 notes
+

+There is a known bug in IIS that may result in incomplete log messages. See bug 45769 +for further details. +

+
+ +
Who support ajp protocols ?
+

+The ajp12 protocol is only available in Tomcat 3.2.x and 3.3.x. +

+ +

+The ajp12 has been deprecated with Tomcat 3.3.x and you should use instead +ajp13 which is the only ajp protocol known by Tomcat 4.x, 5 and 5.5 and Tomcat 6. +

+ +

+Of course Tomcat 3.2.x and 3.3.x also support ajp13 protocol. +

+ +

+Others servlet engines such as jetty have support for ajp13 protocol +

+ +
+ +
How does it work ?
+

+

    +
  1. +The IIS-Tomcat redirector is an IIS plugin (filter + extension), IIS load the redirector plugin and calls its +filter function for each in-coming request. +
  2. +
  3. +The filter then tests the request URL against a list of URI-paths held inside uriworkermap.properties, +If the current request matches one of the entries in the list of URI-paths, +the filter transfers the request to the extension. +
  4. +
  5. +The extension collects the request parameters and forwards them to the appropriate worker using the defined +protocol like ajp13. +
  6. +
  7. +The extension collects the response from the worker and returns it to the browser. +
  8. +
+

+
+ +
Installation
+

+A pre-built version of the ISAPI redirector server plugin, isapi_redirect.dll, is available under +the win32/i386 directory of tomcat-connectors distribution. +For those using Netscape as your browser, try downloading a zip version of the file, if available. +There can be problems using Netscape to download DLL files. + +You can also build a copy locally from the source present in tomcat-connectors distribution. + +The Tomcat redirector requires three entities: + +

    +
  • +isapi_redirect.dll - The IIS server plugin, either obtain a pre-built DLL or build it yourself (see the build section). +
  • +
  • +workers.properties - A file that describes the host(s) and port(s) used by the workers (Tomcat processes). +A sample workers.properties can be found under the conf directory. +
  • +
  • +uriworkermap.properties - A file that maps URL-Path patterns to workers. +A sample uriworkermap.properties can be found under the conf directory as well. +
  • +
+

+ +

+The installation includes the following parts: + +

    +
  • +Configuring the ISAPI redirector with a default /examples context and checking that you can serve servlets with IIS. +
  • +
  • +Adding more contexts to the configuration. +
  • +
+

+ +
Configuring the ISAPI Redirector
+

+In this document I will assume that isapi_redirect.dll is placed in +c:\tomcat\bin\win32\i386\isapi_redirect.dll and +that the properties files which you created are in c:\tomcat\conf. +

+

+

    +
  1. +In the registry, create a new registry key named +"HKEY_LOCAL_MACHINE\SOFTWARE\Apache Software Foundation\Jakarta Isapi Redirector\1.0" +
  2. +
  3. +Add a string value with the name extension_uri and a value of /jakarta/isapi_redirect.dll +
  4. +
  5. +Add a string value with the name log_file and a value pointing to where you want your +log file to be (for example c:\tomcat\logs\isapi.log). +
  6. +
  7. +Add a string value with the name log_level and a value for your log level +(can be debug, info, error or emerg). +
  8. +
  9. +Add a string value with the name worker_file and a value which is the full path +to your workers.properties file (for example c:\tomcat\conf\workers.properties) +
  10. +
  11. +Add a string value with the name worker_mount_file and a value which is the full path +to your uriworkermap.properties file (for example c:\tomcat\conf\uriworkermap.properties) +
  12. +
  13. +Using the IIS management console, add a new virtual directory to your IIS/PWS web site. +The name of the virtual directory must be jakarta. +Its physical path should be the directory where you placed isapi_redirect.dll +(in our example it is c:\tomcat\bin\win32\i386). +While creating this new virtual directory assign it with execute access. +
  14. +
  15. +Using the IIS management console, add isapi_redirect.dll as a filter in your IIS/PWS web site. +The name of the filter should reflect its task (I use the name tomcat), +its executable must be our c:\tomcat\bin\win32\i386\isapi_redirect.dll. +For PWS, you'll need to use regedit and add/edit the "Filter DLLs" key under +HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\W3SVC\Parameters. +This key contains a "," separated list of dlls (full paths) - +you need to insert the full path to isapi_redirect.dll. +
  16. +
  17. +If you're using IIS 6.0 you must also do the following: +
    +Using the IIS management console, add the Jakarta Isapi Redirector to the Web +Service Extensions. +
      +
    1. Right-click on Web Service Extensions and choose Add a new Web Service +Extension.
    2. +
    3. Enter tomcat for the Extension Name.
    4. +
    5. Add the isapi_redirect.dll to the required files.
    6. +
    7. Check the Set extension status to Allowed.
    8. +
    9. Click on OK.
    10. +
    +
  18. +
  19. +Restart IIS (stop + start the IIS service), make sure that the tomcat filter is marked with a green up-pointing arrow. +Under Win98 you may need to cd WINDOWS\SYSTEM\inetsrv and type PWS /stop +( the DLL and log files are locked - even if you click the stop button, +PWS will still keep the DLLs in memory. ). Type pws to start it again. +
  20. +
+

+

+That's all, you should now start Tomcat and ask IIS to serve you the /examples context. +Try http://localhost/examples/jsp/index.html for example and +execute some of the JSP examples. +

+

+If this does not work successfully, refer to the Troubleshooting section below for help on correcting the problem. +

+ +
Adding additional Contexts
+

+The examples context is useful for verifying your installation, +but you will also need to add your own contexts. Adding a new context requires two operations: +

+

+

    +
  1. +Adding the context to Tomcat (I am not going to talk about this). +
  2. +
  3. +Adding the context to the ISAPI redirector. +
  4. +
+

+

+Adding a context to the ISAPI redirector is simple, all you need to do is to edit +your uriworkermap.properties and to add a line that looks like: +

+ +
+  /context/*=worker_name
+
+ +

+Workers and their name are defined in workers.properties, by default workers.properties comes +with a single pre-configured worker named "defworker" so you can use it. +As an example, if you want to add a context named "shop", the line that you should add to +uriworkermap.properties will be: +

+ +
+  /shop/*=defworker
+
+ +After saving uriworkermap.properties restart IIS and it will serve the new context. +

+The above should be all you need for IIS to pass through to Tomcat any request for any URI which corresponds +to a Tomcat context (webapp). +

+
+ +
Advanced Context Configuration
+

+If your webiste is very busy (more than 100 requests/second, or more than 100 simultaneous client connections), +it might sometimes be desirable to have IIS serve static content (html, gif, jpeg etc.) directly, +even if these files are part of a context served by Tomcat. Allowing IIS to serve such files directly may + avoid the small overhead consisting of passing the request to Tomcat via the redirector, and may free up + Tomcat somewhat, by using it only to process requests that only Tomcat can handle (e.g. requests to JSP pages and java servlets). +

+

+For example, consider the html and gif files in the examples context : you could serve these files directly +with IIS; there is no need to serve them from the Tomcat process. +

+

However, you should be very careful when you implement the following configuration style, because by doing so you are +in fact providing a "back-door" to IIS, and allowing it to serve files out of a Tomcat context without Tomcat's knowledge, +thus bypassing any security +restrictions which Tomcat itself and the Tomcat context (webapp) may place on those files.

+

+Making IIS serve static files that are part of the Tomcat contexts requires the following: +

    +
  1. +Configuring IIS to know about the Tomcat contexts +
  2. +
  3. +Configuring the redirector to leave the static files for IIS +
  4. +
+

+ +

+Adding a Tomcat context to IIS requires the addition of a new IIS virtual directory that covers the Tomcat context. +For example adding a /example IIS virtual directory that covers the c:\tomcat\webapps\examples directory. +

+ +

+Configuring the redirector is somewhat harder, you will need to specify the exact +URL-Path pattern(s) which you want Tomcat to handle (usually only JSP files and servlets). +This requires a change to the uriworkermap.properties : + +

+  For the examples context it requires to replace the following line
+  /examples/*=defworker
+  with the following two lines
+  /examples/*.jsp=defworker
+  /examples/servlet/*=defworker
+
+

+ +

+As you can see the second configuration is more explicit, it actually instruct the redirector +to redirect only requests to resources under /examples/servlet/ and resources under /examples/ +whose name ends with .jsp. +

+ +

+You can even be more explicit and provide lines such as: + +

+  /example/servletname=defworker
+
+

+ +

+that instructs the redirector to redirect all requests whose URL-path matches the leading string "/example/servletname" +to the worker named defworker. +

+ +
+ +
Protecting the content of your Tomcat contexts
+

Once again, be aware that by allowing IIS to access the content of your Tomcat context directly, you are +potentially bypassing Tomcat's protection of that content. You should thus make sure to protect this content +at the IIS level if needed, by using the corresponding IIS management console functions. +

+

+In particular, each servlet application (context) has a special directory named WEB-INF, +which contains sensitive configuration data and Java classes, and which should always be kept hidden from web users. +Using the IIS management console it is possible to protect the WEB-INF directory from user access, but considering that +this is a general requirement, and considering that it is easy to forget to implement this protection +at the IIS level, the redirector plugin does it automatically for you, and it will reject any request +which contains WEB-INF in its URL-path. +

+
+ +
Advanced Worker Configuration
+

+Sometimes you may want to serve different contexts with different Tomcat processes +(for example to spread the load among different machines). +To achieve such a goal you will need to define several workers and assign each context to its own worker. +

+

+Defining additional workers is done in the workers.properties file. This file includes two types of entries: +

+ +

+

+  # An entry that lists all the workers defined
+  worker.list=worker1, worker2
+  # Entries that define the host and port associated with each of these workers
+  worker.worker1.host=localhost
+  worker.worker1.port=8009
+  worker.worker1.type=ajp13
+  worker.worker2.host=otherhost
+  worker.worker2.port=8009
+  worker.worker2.type=ajp13
+
+

+ +

+The above example defined two workers, now we can use these workers to serve two different contexts +each with its own worker: +

+  example uriworkermap.properties fragment
+  /examples/*=worker1
+  /webpages/*=worker2
+
+

+ +

+As you can see the examples context is served by worker1 while the +webpages context is served by worker2. +

+ +

+More information on using and configuring workers in the Workers HowTo +and in the worker.properties configuration reference. +

+ +
+ +
Building ISAPI redirector
+

+The redirector was developed using Visual C++ Ver.6.0, so having this environment is a prerequisite if you want +to perform a custom build. You should also have the IIS developer SDK. + +The steps that you need to take are: +

    +
  • +Change directory to the isapi plugins source directory. +
  • +
  • +Make the source with MSDEV +
  • +
+

Change directory to the isapi plugins source directory
c:\>cd c:\home\apache\jk\iis
Build the sources using MSDEV
c:\>MSDEV isapi.dsp /MAKE ALL

+

+

+If msdev is not in your path, enter the full path to msdev.exe. +This will build both release and debug versions of the redirector plugin. +An alternative will be to open the isapi workspace file (isapi.dsw) in msdev and +build it using the build menu. +

+
Troubleshooting
+

+It is easy to have the ISAPI redirector not work the first time you try to install it. +

+

+If this happens to you, here are some steps to follow to try to correct the problem. +

+

+These steps aren't guaranteed to cover all possible problems, +but they should help find the typical mistakes. +

+

+If you make any corrections during these steps, restart the IIS service as described above in the last step +of the installation, then retry the step. +

+ +

To enable error tracking, make sure web site activity is being logged. +For PWS 4.0 make sure "Save Web Site Activity Log" is checked in the Advanced Options of the Personal Web Manager. +

+ +

+Note: These steps assume your worker_mount_file setting points to an unmodified copy of the +uriworkermap.properties file.
+Results may be misleading if worker_mount_file points to a modified uriworkermap.properties +or the uriworkermap.properties-auto file.
+It is also assumed that the "/examples" context works correctly if you access Tomcat directly. +

+ +
Win98
+

+Start the IIS service and Tomcat. +

+

+Check for the presence of the ISAPI redirector log file you specified in the log_file setting. +If not found, verify the following: +

+
    +
  • +Check the "Filter DLLs" setting in the "HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\W3SVC\Parameters" +key and make sure the path is correct. +
  • +
  • +Check the spelling of the "HKEY_LOCAL_MACHINE\SOFTWARE\Apache Software Foundation\Jakarta Isapi Redirector\1.0" key. +Case isn't important, but an incorrect letter will prevent the isapi_redirect.dll from finding its registry settings. +
  • +
  • +Check the log_file setting for typos, name and data. Also insure the directory in which the log file will appear already exists. +
  • +If the above are set correctly, the ISAPI redirector should be able to create the log file. +
+

+Invoke the URL http://localhost/examples/jsp/index.html +in your browser. +Case is important in Tomcat. The characters following "localhost" in the URL must be lower case. +If the page fails to appear, stop the IIS service (required to view the IIS log file). +Then examine the last line in the IIS log file in found in SYSTEM/LogFiles/W3SVC1 : +

+

+If the last line contains: +

+
+  GET "/examples/jsp/index.html HTTP/1.1" 404
+
+

+then the ISAPI redirector is not recognising that it should be handling requests for the "/examples" context. +Check the following: +

+
    +
  • +Check the extension_uri name for typos. +
  • +
  • +Check the worker_file setting for typos, name and data. +
  • +
  • +Check the worker_mount_file setting typos, name and data. +
  • +If these are set correctly, the ISAPI redirector should recognise that it should handle requests for the "/examples" context. +
+ +

If the last line contains something like: +

+ +
+  GET "/jakarta/isapi_redirect.dll HTTP1.1"
+
+ +

+then the ISAPI redirector is recognising that it should handle the request, +but is not successful at getting Tomcat to service the request. +

+ +

+You should check the HTTP error code following GET "/..." : +

+ +
+  Error 404
+  GET "/..." 404
+
+ +
    +
  • +Make sure you entered the URL correctly. +
  • +
  • +Make sure the virtual directory created was called "jakarta". +It should display in Personal Web Manager as "/jakarta" (without the quotes). +
  • +
  • +Make sure the extension_uri data begins with "/jakarta/" (without the quotes). +
  • +
+ +
+  Error 500
+  GET "/..." 500
+
+ +
    +
  • +Make sure that "isapi_redirect.dll" follows "/jakarta/" in the extension_uri setting. +
  • +
  • +Check the workers.properties file and make sure the port setting for worker.ajp12.port is the same as the port specified in the server.xml for the "Apache AJP12 support". +
  • +
+ +
+  Error 200 or 403
+  GET "/..." 200
+  GET "/..." 403
+
+ +
    +
  • +Make sure you have checked Execute Access +for the jakarta virtual directory in the Advanced Options of the Personal Web Manager. +
  • +
+ +

+If the above settings are correct, the index.html page should appear in your browser. +You should also be able to click the Execute links to execute the JSP examples. +

+ +
+ +
WinNT/Win2K/WinXP
+

+Start the World Wide Web Publishing Service and Tomcat. +

+

+Check for the presence of the ISAPI redirector log file you specified in the log_file setting. +If not found, check the following: +

+
    +
  • +Check the "executable" you set for the filter in the IIS Management Console and make sure the path is correct. +
  • +
  • Check the spelling of the "HKEY_LOCAL_MACHINE\SOFTWARE\Apache Software Foundation\Jakarta Isapi Redirector\1.0" key. +Case isn't important, but an incorrect letter will prevent the isapi_redirect.dll from finding its registry settings. +
  • +
  • +Check the log_file setting for typos, name and data. Also insure the directory in which the log file will appear already exists. +
  • +If the above are set correctly, the ISAPI redirector should be able to create the log file. +
+ +

+Check the tomcat filter you added and make sure its status shows a green upward-pointing arrow. +If not, check the following: +

+
    +
  • +Check the worker_file setting for typos, name and data. +
  • +
  • +Check the worker_mount_file setting typos, name and data. +
  • +If the above are set correctly, the green upward-pointing arrow should appear, even if the other settings are wrong. +
+ +

+Invoke the URL http://localhost/examples/jsp/index.html +in your browser. Case is important in Tomcat. The characters following "localhost" in the URL must be lower case. +If the page fails to appear, examine the last line in the IIS server log file in found in SYSTEM32/LogFiles/W3SVC1. +

+ +

+The last line should contain something like: GET "/jakarta/isapi_redirect.dll HTTP1.1", +which indicates the ISAPI redirector is recognising that it should handle the request. +

+ +

+You should check the HTTP error code following GET "/..." : +

+ +
+  Error 404
+  GET "/..." 404
+
+ +
    +
  • +Make sure you entered the URL correctly. +
  • +
+ +
+  Error 500
+  GET "/..." 500
+
+ +
    +
  • +Make sure the virtual directory created was called "jakarta". +
  • +
  • +Make sure that the extension_uri setting is correct. +
  • +
  • +Check the workers.properties file and make sure the port setting for worker.ajp12.port is the same as the port specified in the server.xml for the "Apache AJP12 support". +
  • +
+ +
+  Error 200 or 403
+  GET "/..." 200
+  GET "/..." 403
+
+ +
    +
  • +Make sure you have checked Execute Access for the jakarta virtual directory in the +Advanced Options of the Personal Web Manager. +
  • +
+ +

+If the above settings are correct, the index.html page should appear in your browser. +You should also be able to click the Execute links to execute the JSP examples. +

+
+ + +

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/webserver_howto/nes.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/webserver_howto/nes.html new file mode 100644 index 00000000..e9d60a2e --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/webserver_howto/nes.html @@ -0,0 +1,483 @@ +The Apache Tomcat Connector - Webserver HowTo - SunOne -- Netscape/iPlanet HowTo
Apache TomcatApache Logo

Links

Reference Guide

Generic HowTo

Webserver HowTo

AJP Protocol Reference

Miscellaneous Documentation

News

The Apache Tomcat Connector - Webserver HowTo

SunOne -- Netscape/iPlanet HowTo

Printer Friendly Version
print-friendly
version +
Introduction
+

+This document explains how to set up Sun ONE Web Server previously known as +Netscape web servers to cooperate with Tomcat. +

+ +

+Normally the Sun ONE Web Servers come with their own Servlet engine, +but you can also configure them to send servlet and JSP requests to Tomcat +using the NSAPI redirector plugin. +

+ +

+It is recommended that you also read the Workers HowTo document +to learn how to setup the working entities between your web server and Tomcat Engines. +

+ + +
Document Conventions and Assumptions
+

+${tomcat_home} is the root directory of tomcat. +Your Tomcat installation should have the following subdirectories: + +

    +
  • +${tomcat_home}\conf - Where you can place various configuration files +
  • +
  • +${tomcat_home}\webapps - Containing example applications +
  • +
  • +${tomcat_home}\bin - Where you place web server plugins +
  • +
+

+

+In all the examples in this document ${tomcat_home} will be c:\tomcat. +A worker is defined to be a tomcat process that accepts work from the Sun ONE Web Server. +

+
+ + +
Supported Configuration
+

+The NSAPI-Tomcat redirector was developed and tested on: +

    +
  • +WINNT 2000/XP/2003 (should be able to work with other service packs) and some Unixes +
  • +
  • +Sun ONE Web Server 6.1 +
  • +
  • +Tomcat 4.1.x , Tomcat 5.0.x and Tomcat 5.5.x +
  • +
+

+ +

+The redirector uses ajp12 and ajp13 to send requests to the Tomcat containers. +There is also an option to use Tomcat in process, +more about the in-process mode can be found in the in process howto. +

+
+ +
Who support ajp protocols ?
+

+The ajp12 protocol is only available in Tomcat 3.2.x and 3.3.x. +

+ +

+The ajp12 has been deprecated with Tomcat 3.3.x and you should use instead +ajp13 which is the only ajp protocol known by Tomcat 4.0.x, 4.1.x, 5.0.x, 5.5.x and 6. +

+ +

+Of course Tomcat 3.2.x and 3.3.x also support ajp13 protocol. +

+ +

+Others servlet engines such as jetty have support for ajp13 protocol +

+ +
+ + +
How does it work ?
+

+

    +
  1. +The NSAPI-Tomcat redirector is an Netscape service step plugin, +Netscape load the redirector plugin and calls its service handler +function for request that are assigned to the "servlet" configuration object. +
  2. +
  3. +For each in-coming request Netscape will execute the set of NameTrans directives +that we added to obj.conf, the assign-name function will check if it's from +parameter matches the request URL. +
  4. +
  5. +If a match is found, assign-name will assign the servlet object name to the request. +This will cause Netscape to send the request to the servlet configuration object. +
  6. +
  7. +Netscape will execute our jk_service extension. The extension collects the +request parameters and forwards them to the appropriate worker using the ajp13 protocol +(the worker="defworker" parameter in jk_service inform it that the worker for this request is named defworker). +the workers properties files, workers.properties, will indicate that defworker use ajp13 protocol. +
  8. +
  9. +The extension collects the response from the worker and returns it to the browser. +
  10. +
+

+
+ +
Installation
+

+A pre-built version of the NSAPI redirector, nsapi_redirect.dll, may be available under +the win32/i386 directory of tomcat-connectors distribution. +For those using Netscape as your browser, try downloading a zip version of the file, if available. + +You can also build a copy locally from the source present in tomcat-connectors distribution. + + +The Tomcat redirector requires two entities: +

    +
  • +nsapi_redirect.dll (Windows) -or- nsapi_redirector.so (Unix) - The NSAPI server plugin, either obtain a pre-built DLL/so or build it yourself +(see the build section). +
  • +
  • +workers.properties - A file that describes the host(s) and port(s) used by the workers (Tomcat processes). +A sample workers.properties can be found under the conf directory. +
  • +
+ +The installation includes the following parts: + +
    +
  • +Configuring the NSAPI redirector with a default /examples context and checking that you can serve servlets +with Netscape. +
  • +
  • +Adding more contexts to the configuration. +
  • +
+ +

+
Configuring the NSAPI Redirector
+

+In this document we'll assume that nsapi_redirect.dll is placed in +c:\jk\lib\nsapi_redirect.dll, the properties file is inc:\jk\conf +and you created a log directory c:\jk\logs +

+ +
    +
  • +If the built in servlet support is working disable it. +
  • +
  • +Add the redirector plugin into the Netscape server configuration. +Edit your server magnus.conf and add the following lines: +
  • +
+ +
+  
+  Init fn="load-modules" funcs="jk_init,jk_service" shlib="c:/jk/lib/nsapi_redirect.dll" shlib_flags="(global|now)"
+  Init fn="jk_init" worker_file="c:/jk/conf/workers.properties" log_level="debug" log_file="c:/jk/logs/nsapi.log" shm_file="c:/jk/logs/jk_shm"
+
+
    +
  • +Edit your server obj.conf and add the following lines: +
  • +
+
+
+  
+  In the default object NameTrans section
+  <Object name="default">
+      
+  NameTrans fn="assign-name" from="/servlets-examples(|/*)" name="jknsapi" 
+  NameTrans fn="assign-name" from="/jsp-examples(|/*)" name="jknsapi"
+  ....
+  </Object>
+  
+  Create a new configuration object by adding the following lines to the end of the obj.conf file
+  
+  <Object name="jknsapi">
+  ObjectType fn=force-type type=text/plain
+  Service fn="jk_service" method="*" worker="worker1"
+  </Object>
+
+ +
    +
  • +Edit your worker definition file workers.properties. You should at least choose a connection pool size: +
  • +
+ +
+  #An entry that lists all the workers defined. For example:
+  worker.list=worker1
+  
+  # Entries that define the host and port associated with these workers.
+  worker.worker1.host=localhost
+  worker.worker1.port=8009
+  worker.worker1.type=ajp13
+  worker.worker1.connection_pool_size=50
+
+ +
    +
  • +Restart Web Server (stop and start the server) +
  • +
+ +

+That's all, now you should start tomcat and ask for http://server:port/servlets-examples/ +

+

+The file obj.conf seems to be sensitive to leading white space in lines, especially in +the Object element. Make sure you have no leading white space (no indentation) +on any line of this file. +

+ +
Adding additional Contexts
+

+The examples context is useful for verifying your installation, but you will also need to add your own contexts. +Adding a new context requires two operations: +

+
    +
  • +Adding the context to Tomcat (I am not going to talk about this). +
  • +
  • +Assigning the NSAPI redirector to handle this context. +
  • +
+ +

+Assigning the NSAPI redirector to handle this context is simple, +all you need to do is to edit obj.conf and add a NameTrans line that looks like: +

+ +
+  NameTrans fn="assign-name" from="/<context name>/*" name="jknsapi"
+
+ +

+After saving obj.conf restart Netscape and it will serve the new context. +

+
+ +
Advanced Context Configuration
+

+Sometimes it is better to have Netscape serve the static pages (html, gif, jpeg etc.) +even if these files are part of a context served by Tomcat. For example, consider the html and gif files in the examples context, there is no need to serve them from the Tomcat process, Netscape will suffice. +

+

+Making Netscape serve static files that are part of the Tomcat contexts requires the following: +

+
    +
  • +Configuring Netscape to know about the Tomcat contexts +
  • +
  • +Make sure that the WEB-INF directory is protected from access. +
  • +
  • +Configuring Netscape to assign the NSAPI redirector only specific requests that requires JSP/Servlet handling. +
  • +
+ +

+Adding a Tomcat context to Netscape requires the addition of a new Netscape virtual directory +that covers the Tomcat context. +

+ +

+For example, adding a /example Netscape virtual directory that +covers the c:\tomcat\webapps\examples directory. +

+ +

+To add a new virtual directory add the following line to your obj.conf: +

+ +
+  NameTrans fn=pfx2dir from=/examples dir="c:/tomcat/webapps/examples"
+
+ +

+WEB-INF protection requires some explanation; Each servlet application (context) has a special directory named WEB-INF, +this directory contains sensitive configurations data and Java classes and must be kept hidden from web users. +WEB-INF can be protected by adding the following line to the PathCheck section in the default configuration object: +

+ +
+  PathCheck fn="deny-existence" path="*/WEB-INF/*"
+  
+  This line instructs the Netscape server to reject any request with a URL that contain the path /WEB-INF/.
+
+ +

+Configuring Netscape to assign the NSAPI redirector only specific requests is somewhat harder, +you will need to specify the exact URL-Path pattern(s) that you want Tomcat to handle +(usually only JSP files and servlets). +

+ +

+This requires a change to NameTrans portion of obj.conf. +

+ +
+  For the examples context it requires to replace the following line:
+  
+  NameTrans fn="assign-name" from="/examples/*" name="jknsapi"
+  
+  with the following two lines:
+  
+  NameTrans fn="assign-name" from="/examples/jsp/*.jsp" name="jknsapi"
+  NameTrans fn="assign-name" from="/examples/servlet/*" name="jknsapi"
+
+ +

+As you can see the second configuration is more explicit, it actually instructs +Netscape to assign the redirector with only requests to resources under +/examples/servlet/ and resources under /examples/ whose name ends with .jsp. +

+ +

+You can be even more explicit and provide lines such as: +

+ +
+  NameTrans fn="assign-name" from="/examples/servletname" name="jknsapi"
+  
+  Instructs Netscape to assign the redirector request whose URL-Path equals /example/servletname
+
+ +
+ +
Advanced Worker Configuration
+

+Sometimes you want to serve different contexts with different Tomcat processes +(for example to spread the load among different machines). +To achieve such goal you will need to define several workers and assign each context with its own worker. +

+ +

+Defining workers is done in workers.properties, this file includes two types of entries: +

+ +
+  #An entry that lists all the workers defined. For example:
+  worker.list=worker1,worker2
+  
+  # Entries that define the host and port associated with these workers.
+  worker.worker1.host=localhost
+  worker.worker1.port=8009
+  worker.worker1.type=ajp13
+
+  worker.worker2.host=otherhost
+  worker.worker2.port=8009
+  worker.worker2.type=ajp13
+
+ +

+The above examples defined two workers, now we can use these workers to serve two different +contexts each with it's own worker. +Submitting requests to different workers is accomplished by using multiple Service directives +in the servlet configuration Object, each with a different path pattern parameter. +

+ +

+For example, if we want to submit the /examples context to the worker named worker1 and the +/webpages context to the worker named worker2 we should use the following configuration: +

+ +
+  <Object name="jknsapi">
+  ObjectType fn=force-type type=text/plain
+  Service fn="jk_service" worker="worker1" path="/examples/*"
+  Service fn="jk_service" worker="worker2" path="/webpages/*"
+  Service fn="jk_service" worker="worker1"
+  </Object>
+
+ +

+More informations on using and configuring workers in the Workers HowTo +and in the worker.properties configuration reference. + +

+
+ +
Building NSAPI DLL redirector for Windows
+

+The redirector was developed using Visual C++ Ver.6.0, so having this environment is a prereq if you want +to perform a custom build. You should also have NES developer SDK + +The steps that you need to take are: +

    +
  • +Change directory to the nsapi plugins source directory. +
  • +
  • +Edit nsapi.dsp and update the include and library path to reflect your own Netscape server installation +(search for a /I compiler option and /libpath linker option) +
  • +
  • +Make the source with MSDEV +
  • +
+ +Change directory to the nsapi plugins source directory +c:\>cd c:\home\apache\jk\nsapi
+Build the sources using MSDEV +c:\>MSDEV nsapi.dsp /MAKE ALL
+
+

+

+If msdev is not in your path, enter the full path to msdev.exe. +This will build both release and debug versions of the redirector plugin. +An alternative will be to open the nsapi workspace file (nsapi.dsw) in msdev and +build it using the build menu. +

+
Building NSAPI so plugin redirector for Unix
+

+The redirector requires either gcc (Linux) or gcc or the Sun cc compiler (Solaris). + +The steps that you need to take are: +

    +
  • +Change directory to the nsapi plugins source directory (src/native). +
  • +
  • +configure for Netscape/iPlanet/SunONE webserver. +
  • +
  • +Change directory to the nsapi netscape directory (./netstape). +
  • +
  • +Set environment variables JAVA_HOME resp. SUITSPOT_HOME to the location of your Java installation +resp. Netscape server installation. Depending on the web server version, you must add the subdirectory +"plugins" to SUITSPOT_HOME. +The variable is correct, if the file $SUITSPOT_HOME/include/nsapi.h exists. +
  • +
  • +Edit Makefile.solaris resp. Makefile.linux and update the variables according to your needs. +In the Solaris Makefile, you need to switch the commented lines in order to use the Sun compiler cc +instead of GNU gcc. +
  • +
  • +Make the source with gmake. +
  • +
+ +Change directory to the nsapi plugins source directory +c:\>cd /usr/local/src/tomcat-connectors-xxx-src/native
+configure for Netscape/iPlanet/SunONE webserver +c:\>./configure --enable-netscape
+Change directory to the nsapi netscape directory +c:\>cd netscape
+Set JAVA_HOME (ksh example) +c:\>export JAVA_HOME=/path/to/my/java
+Set SUITSPOT_HOME (ksh example) +c:\>export SUITSPOT_HOME=/path/to/my/netscape/server
+Edit the Makefile +c:\>vi Makefile.solaris
+Make the source with gmake +c:\>gmake -f Makefile.solaris
+
+

+

+After the build, you will have the required nsapi_redirector.so plugin. +

+

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/webserver_howto/printer/apache.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/webserver_howto/printer/apache.html new file mode 100644 index 00000000..ab972c65 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/webserver_howto/printer/apache.html @@ -0,0 +1,1123 @@ +The Apache Tomcat Connector - Webserver HowTo - Apache HTTP Server HowTo
Apache TomcatApache Logo

The Apache Tomcat Connector - Webserver HowTo

Apache HTTP Server HowTo

Introduction
+

+This document explains how to connect Tomcat to the popular open source web server, Apache httpd. +There is actually three versions of Apache HTTP Server, 1.3, 2.0 and 2.2 and all can be used with mod_jk, +the Tomcat redirector module. +

+ +

+It is recommended that you also read the +Workers HowTo document +to learn how to setup the working entities between your web server and Tomcat Engines. +For more detailed configuration information consult the Reference Guide for +workers.properties, +uriworkermap +and Apache. +

+ +

Waring: If Apache HTTP Server and Tomcat are configured to serve content from +the same filing system location then care must be taken to ensure that httpd is +not able to serve inappropriate content such as the contents of the WEB-INF +directory or JSP source code. This could occur if the httpd DocumentRoot +overlaps with a Tomcat Host's appBase or the docBase of any Context. It could +also occur when using the httpd Alias directive with a Tomcat Host's appBase or +the docBase of any Context. +

+ +

+This document was originally part of Tomcat: A Minimalistic User's Guide written by Gal Shachor, +but has been split off for organisational reasons. +

+ +
Document Conventions and Assumptions
+

+${tomcat_home} is the root directory of tomcat. +Your Tomcat installation should have the following subdirectories: + +

    +
  • +${tomcat_home}\conf - Where you can place various configuration files +
  • +
  • +${tomcat_home}\webapps - Containing example applications +
  • +
  • +${tomcat_home}\bin - Where you place web server plugins +
  • +
+

+

+In all the examples in this document ${tomcat_home} will be /var/tomcat3. +A worker is defined to be a tomcat process that accepts work from the Apache server. +

+
+ +
Supported Configuration
+

+The mod_jk module was developed and tested on: +

    +
  • +Linux, FreeBSD, AIX, HP-UX, MacOS X, Solaris and should works on major Unixes platforms +supporting Apache 1.3 and/or 2.0/2.2 +
  • +
  • +WinNT4.0-i386 SP4/SP5/SP6a (should be able to work with other service packs), Win2K and WinXP and Win98 +
  • +
  • +Cygwin (until you have an apache server and autoconf/automake support tools) +
  • +
  • +Netware +
  • +
  • +i5/OS V5R4 (System I) with Apache HTTP Server 2.0.58. Be sure to have the latest Apache PTF installed. +
  • +
  • +Tomcat 3.2.x, Tomcat 3.3.x, Tomcat 4.0.x, Tomcat 4.1.x, Tomcat 5.0.x, Tomcat 5.5.x and Tomcat 6. +
  • +
+

+ +

+The redirector uses ajp12 and ajp13 to send requests to the Tomcat containers. There is also an option to use Tomcat in process, +more about the in-process mode can be found in the in process howto. +

+
+ +
Who support ajp protocols ?
+

+The ajp12 protocol is only available in Tomcat 3.2.x and 3.3.x. +

+ +

+The ajp12 has been deprecated with Tomcat 3.3.x and you should use instead +ajp13 which is the only ajp protocol known by Tomcat 4.x, 5 and 5.5 and Tomcat 6. +

+ +

+Of course Tomcat 3.2.x and 3.3.x also support ajp13 protocol. +

+ +

+Others servlet engines such as jetty have support for ajp13 protocol +

+ +
+ +
How does it work ?
+

+In a nutshell a web server is waiting for client HTTP requests. +When these requests arrive the server does whatever is needed to serve the +requests by providing the necessary content. +

+ +

+Adding a servlet container may somewhat change this behaviour. +Now the web server needs also to perform the following: +

+ +
    +
  • +Load the servlet container adaptor library and initialise it (prior to serving requests). +
  • +
  • +When a request arrives, it needs to check and see if a certain request belongs to a servlet, +if so it needs to let the adaptor take the request and handle it. +
  • +
+ +

+The adaptor on the other hand needs to know what requests it is going to serve, +usually based on some pattern in the request URL, and to where to direct these requests. +

+ +

+Things are even more complex when the user wants to set a configuration that uses virtual hosts, +or when they want multiple developers to work on the same web server +but on different servlet container JVMs. +We will cover these two cases in the advanced sections. +

+ +
+ +
Obtaining mod_jk
+

+mod_jk can be obtained in two formats - binary and source. +Depending on the platform you are running your web server on, a binary version of mod_jk may be available. +

+ +

+It is recommended to use the binary version if one is available. +If the binary is not available, follow the instructions for building mod_jk from source. +The mod_jk source can be downloaded from a mirror + +here +

+ +

+The binaries for mod_jk are now available for several platforms. +The binaries are located in subdirectories by platform. +

+ +

+For some platforms, such as Windows, this is the typical way of obtaining mod_jk +since most Windows systems do not have C compilers. +

+ +

+For others, the binary distribution of mod_jk offers simpler installation. +

+ +

+For example JK 1.2.x can be downloaded from a mirror + +here (look for JK 1.2 Binary Releases). The "JK 1.2 Binary Releases" link contains binary version for a variety of +operating systems for both Apache 1.3 and Apache 2. +

+ +
Installation
+

+mod_jk requires two entities: + +

    +
  • +mod_jk.xxx - The Apache HTTP Server module, depending on your operating system, it will be mod_jk.so, mod_jk.nlm or +or MOD_JK.SRVPGM (see the build section). +
  • +
  • +workers.properties - A file that describes the host(s) and port(s) used by the workers (Tomcat processes). +A sample workers.properties can be found under the conf directory in the source download. +
  • +
+

+ +

+Also as with other Apache HTTP Server modules, mod_jk should be first installed on the modules directory of your +Apache webserver, ie : /usr/lib/apache and you should update your httpd.conf file. +

+ + +
Disabling old mod_jserv
+

+If you've previously configured Apache to use mod_jserv, remove any ApJServMount directives +from your httpd.conf. +

+ +

If you're including tomcat-apache.conf or tomcat.conf, you'll want to remove them as well - +they are specific to mod_jserv. +

+ +

+The mod_jserv configuration directives are not compatible with mod_jk ! +

+
+ +
Using Tomcat auto-configure
+

+The auto-configure works only for a single Tomcat running on the same machine where Apache HTTP Server is running. +The simplest way to configure Apache HTTP Server to use mod_jk is to turn on the Apache HTTP Server auto-configure setting +in Tomcat and put the following include directive at the end of your Apache httpd.conf file +(make sure you replace $TOMCAT_HOME with the correct path for your Tomcat installation: +

+ +
+    #To be added at the end of your httpd.conf
+    Include $TOMCAT_HOME/conf/jk/mod_jk.conf-auto
+
+ +

+Note: this file may also be generated as $TOMCAT_HOME/conf/auto/mod_jk.conf +

+ +

+This will tell Apache HTTP Server to use directives in the mod_jk.conf-auto file in +the Apache configuration. This file is created by enabling the Apache +auto-configuration by creating your workers.properties file at +$TOMCAT_HOME/conf/jk/workers.properties and adding the listener to the Engine +element in the server.xml file as per the following example. +Please note that this example is specific to Tomcat 5.x, unlike other sections of this document + which also apply to previous Tomcat branches. +

+
+  ...
+  <Engine ...>
+    ...
+    <Listener className="org.apache.jk.config.ApacheConfig" modJk="/path/to/mod_jk.so" />
+    ...
+  </Engine>
+  ...
+
+ +

+Then restart Tomcat and mod_jk.conf should be generated. For more information on +this topic, please refer to the API documentation at the + +Tomcat docs website. +

+ +
+ +
Custom mod_jk configuration
+

+You should use custom configuration when : +

+
    +
  • +You couldn't use mod_jk.conf-auto since Tomcat engine isn't on the same machine that your Apache web server, +ie when you have an Apache in front of a Tomcat Farm. +
  • +
  • +Another case for custom configuration is when your Apache is in front of many different Tomcat engines, +each one having it's own configuration, a general case in ISP hosting +
  • +
  • +Also all Apache webmaster will retain custom configuration to be able to tune the settings +to their real needs. +
  • +
+ +
+ +
Simple configuration example
+

+Here is a simple configuration: +

+ +
+    # Load mod_jk module
+    LoadModule    jk_module  libexec/mod_jk.so
+    # Declare the module for <IfModule directive> (remove this line on Apache 2.0.x)
+    AddModule     mod_jk.c
+    # Where to find workers.properties
+    JkWorkersFile /etc/httpd/conf/workers.properties
+    # Where to put jk shared memory
+    JkShmFile     /var/log/httpd/mod_jk.shm
+    # Where to put jk logs
+    JkLogFile     /var/log/httpd/mod_jk.log
+    # Set the jk log level [debug/error/info]
+    JkLogLevel    info
+    # Select the timestamp log format
+    JkLogStampFormat "[%a %b %d %H:%M:%S %Y] "
+    # Send servlet for context /examples to worker named worker1
+    JkMount  /examples/servlet/* worker1
+    # Send JSPs  for context /examples to worker named worker1
+    JkMount  /examples/*.jsp worker1
+
+ +
+
mod_jk Directives
+

+We'll discuss here the mod_jk directives and details behind them +

+ +
Define workers
+

+JkWorkersFile specify the location where mod_jk will find the workers definitions. + +

+  JkWorkersFile     /etc/httpd/conf/workers.properties
+
+ +
+
+

+
+ +
Logging
+

+JkLogFile specify the location where mod_jk is going to place its log file. +

+ +
+  JkLogFile     /var/log/httpd/mod_jk.log
+
+ +

+Since JK 1.2.3 for Apache 2.0/2.2 and JK 1.2.16 for Apache 1.3 this can also +be used for piped logging: +

+ +
+  JkLogFile     "|/usr/bin/rotatelogs /var/log/httpd/mod_jk.log 86400"
+
+ +

+JkLogLevel +set the log level between : +

+ +
    +
  • +info log will contains standard mod_jk activity (default). +
  • +
  • +error log will contains also error reports. +
  • +
  • +debug log will contains all information on mod_jk activity +
  • +
+ +
+  JkLogLevel    info
+
+ +

+info should be your default selection for normal operations. +
+
+

+ +

+JkLogStampFormat will configure the date/time format found on mod_jk logfile. +Using the strftime() format string it's set by default to "[%a %b %d %H:%M:%S %Y]" +

+ +
+  JkLogStampFormat "[%a %b %d %H:%M:%S %Y] "
+
+ +

+
+
+

+ +

+JkRequestLogFormat will configure the format of mod_jk individual request logging. +Request logging is configured and enabled on a per virtual host basis. +To enable request logging for a virtual host just add a JkRequestLogFormat config. +The syntax of the format string is similar to the Apache LogFormat command, +here is a list of the available request log format options: +

+ +

+ + + + + + + + + + + + + + + + +
OptionsDescription
%bBytes sent, excluding HTTP headers (CLF format)
%BBytes sent, excluding HTTP headers
%HThe request protocol
%mThe request method
%pThe canonical Port of the server serving the request
%qThe query string (prepended with a ? if a query string exists, otherwise an empty string)
%rFirst line of request
%sRequest HTTP status code
%TRequest duration, elapsed time to handle request in seconds '.' micro seconds
%UThe URL path requested, not including any query string.
%vThe canonical ServerName of the server serving the request
%VThe server name according to the UseCanonicalName setting
%wTomcat worker name
%RSession route name (available with 1.2.19 and up)
+ +

+  JkRequestLogFormat     "%w %V %T"
+
+ +
+
+

+ +
+ +
Forwarding
+

+The directive JkOptions allow you to set many forwarding options which will enable (+) +or disable (-) following option. Without any leading signs, options will be enabled. +
+
+

+ +

+The four following options +ForwardURIxxx are mutually exclusive. +Exactly one of them is required, a negative sign prefix is not allowed with them. +The default value is "ForwardURIProxy" since version 1.2.24. +It was "ForwardURICompatUnparsed" in version 1.2.23 and +"ForwardURICompat" until version 1.2.22. +You can turn the default off by switching on one of the other two options. +You should leave this at it's default value, unless you have a very good +reason to change it. +
+
+

+ +

+All options are inherited from the global server to virtual hosts. +Options that support enabling (plus options) and disabling (minus options), +are inherited in the following way: +
+
+options(vhost) = plus_options(global) - minus_options(global) + plus_options(vhost) - minus_options(vhost) +
+
+

+ +

+Using JkOptions ForwardURIProxy, the forwarded URI +will be partially reencoded after processing inside Apache httpd and +before forwarding to Tomcat. This will be compatible with local +URL manipulation by mod_rewrite and with URL encoded session ids. + +

+  JkOptions     +ForwardURIProxy
+
+ +
+
+

+ +

+Using JkOptions ForwardURICompatUnparsed, the forwarded URI +will be unparsed. It's spec compliant and secure. +It will always forward the original request URI, so rewriting +URIs with mod_rewrite and then forwarding the rewritten URI +will not work. + +

+  JkOptions     +ForwardURICompatUnparsed
+
+ +
+
+

+

+Using JkOptions ForwardURICompat, the forwarded URI will +be decoded by Apache httpd. Encoded characters will be decoded and +explicit path components like ".." will already be resolved. +This is less spec compliant and is not safe if you are using +prefix JkMount. This option will allow to rewrite URIs with +mod_rewrite before forwarding. + +

+  JkOptions     +ForwardURICompat
+
+ +
+
+

+

+Using JkOptions ForwardURIEscaped, the forwarded URI will +be the encoded form of the URI used by ForwardURICompat. +Explicit path components like ".." will already be resolved. +This will not work in combination with URL encoded session IDs, +but it will allow to rewrite URIs with mod_rewrite before forwarding. + +

+  JkOptions     +ForwardURIEscaped
+
+ +
+
+

+ +

+JkOptions RejectUnsafeURI will block all +URLs, which contain percent signs '%' or backslashes '\' +after decoding. +
+
+

+

+Most web apps do not use such URLs. Using the option RejectUnsafeURI, you +can block several well known URL encoding attacks. By default, this option +is not set. +

+

+You can also realise such a check with mod_rewrite, which is more powerful +but also slightly more complicated. + +

+  JkOptions     +RejectUnsafeURI
+
+ +
+
+

+ +

+JkOptions ForwardDirectories is used in conjunction with DirectoryIndex +directive of Apache web server. As such mod_dir should be available to Apache, +statically or dynamically (DSO) +
+
+

+ +

+When DirectoryIndex is configured, Apache will create sub-requests for +each of the local-url's specified in the directive, to determine if there is a +local file that matches (this is done by stat-ing the file). +

+ +

+If ForwardDirectories is set to false (default) and Apache doesn't find any +files that match, Apache will serve the content of the directory (if directive +Options specifies Indexes for that directory) or a 403 Forbidden response (if +directive Options doesn't specify Indexes for that directory). +

+ +

+If ForwarDirectories is set to true and Apache doesn't find any files that +match, the request will be forwarded to Tomcat for resolution. This is used in +cases when Apache cannot see the index files on the file system for various +reasons: Tomcat is running on a different machine, the JSP file has been +precompiled etc. +

+ +

Note that locally visible files will take precedence over the +ones visible only to Tomcat (i.e. if Apache can see the file, that's the one +that's going to get served). This is important if there is more then one type of +file that Tomcat normally serves - for instance Velocity pages and JSP pages. + +

+  JkOptions     +ForwardDirectories
+
+
+
+

+ +

+JkOptions ForwardLocalAddress, you ask mod_jk to send the local address, +of the Apache web server instead remote client address. This can be used by +Tomcat remote address valve for allowing connections only from registered Apache +web servers. + +

+  JkOptions     +ForwardLocalAddress
+
+ +
+
+

+ +

+JkOptions FlushPackets, you ask mod_jk to flush Apache's connection +buffer after each AJP packet chunk received from Tomcat. This option can have +a strong performance penalty for Apache and Tomcat as writes are performed +more often than would normally be required (ie: at the end of each +response). + +

+  JkOptions     +FlushPackets
+
+ +
+
+

+ +

+JkOptions FlushHeader, you ask mod_jk to flush Apache's connection +buffer after the response headers have been received from Tomcat. + +

+  JkOptions     +FlushHeader
+
+ +
+
+

+ +

+JkOptions DisableReuse, you ask mod_jk to close connections immediately +after their use. Normally mod_jk uses persistent connections and pools idle +connections to reuse them, when new requests have to be sent to Tomcat. +

+ +

+Using this option will have a strong performance penalty for Apache and Tomcat. +Use this only as a last resort in case of unfixable network problems. +If a firewall between Apache and Tomcat silently kills idle connections, +try to use the worker attribute socket_keepalive in combination with an appropriate +TCP keepalive value in your OS. + +

+  JkOptions     +DisableReuse
+
+ +
+
+

+ +

+JkOptions ForwardKeySize, you ask mod_jk, when using ajp13, to forward also the SSL Key Size as +required by Servlet API 2.3. +This flag shouldn't be set when servlet engine is Tomcat 3.2.x (off by default). + +

+  JkOptions     +ForwardKeySize
+
+ +
+
+

+ +

+JkOptions ForwardSSLCertChain, you ask mod_jk, when using ajp13, +to forward SSL certificate chain (off by default). +Mod_jk only passes the SSL_CLIENT_CERT to the AJP connector. This is not a +problem with self-signed certificates or certificates directly signed by the +root CA certificate. However, there's a large number of certificates signed by +an intermediate CA certificate, where this is a significant problem: A servlet +will not have the possibility to validate the client certificate on its own. The +bug would be fixed by passing on the SSL_CLIENT_CERT_CHAIN to Tomcat via the AJP connector. +
+This directive exists only since version 1.2.22. +

+  JkOptions     +ForwardSSLCertChain
+
+ +
+
+

+ +

+The directive JkEnvVar allows you to forward environment variables +from Apache server to Tomcat engine. +You can add a default value as a second parameter to the directive. +If the default value is not given explicitly, the variable +will only be send, if it is set during runtime. +
+The variables can be retrieved on the Tomcat side as request attributes +via request.getAttribute(attributeName). +Note that the variables send via JkEnvVar will not be listed +in request.getAttributeNames(). +
+
+The variables are inherited from the global server to virtual hosts. + +

+  JkEnvVar     SSL_CLIENT_V_START     undefined
+
+
+
+

+ +
+ +
Assigning URLs to Tomcat
+

+If you have created a custom or local version of mod_jk.conf-local as noted above, +you can change settings such as the workers or URL prefix. +

+ +

+JkMount directive assign specific URLs to Tomcat. +In general the structure of a JkMount directive is: +

+ +
  JkMount [URL prefix] [Worker name]
+ +
+  # send all requests ending in .jsp to worker1
+  JkMount /*.jsp worker1
+  # send all requests ending /servlet to worker1
+  JkMount /*/servlet/ worker1
+  # send all requests jsp requests to files located in /otherworker will go worker2
+  JkMount /otherworker/*.jsp worker2
+
+ +

+You can use the JkMount directive at the top level or inside <VirtualHost> sections of your httpd.conf file. +

+
+ +
Configuring Apache to serve static web application files
+

+If the Tomcat Host appBase (webapps) directory is accessible by the Apache web server, +Apache can be configured to serve web application context directory static files instead +of passing the request to Tomcat. +

+ +

+Caution: For security reasons is is strongly recommended that JkMount is used to +pass all requests to Tomcat by default and JkUnMount is used to explicitly +exclude static content to be served by httpd. It should also be noted that +content served by httpd will bypass any security constraints defined in the +application's web.xml. +

+ +

Use Apache's Alias directive to map a single web application context directory into Apache's +document space for a VirtualHost: +

+ +
+  # Static files in the examples webapp are served by apache
+  Alias /examples /vat/tomcat3/webapps/examples
+  # All requests go to worker1 by default
+  JkMount /* worker1
+  # Serve html, jpg and gif using httpd
+  JkUnMount /*.html worker1
+  JkUnMount /*.jpg  worker1
+  JkUnMount /*.gif  worker1
+
+ +

+Starting with mod_jk 1.2.6 for Apache 2.0/2.2 and 1.2.19 for Apache 1.3, it's possible to exclude some URL/URI from +jk processing by setting the env var no-jk, for example with the SetEnvIf Directive. +

+ +

+You could use no-jk env var to fix problem with mod_alias or mod_userdir +directive when jk and alias/userdir URLs matches. +

+ +
+  # All URL goes to tomcat except the one containing /home
+  <VirtualHost *:80>
+      ServerName testxxx.mysys
+      DocumentRoot /www/testxxx/htdocs
+
+  # Use SetEnvIf to st no-jk when /home/ is encountered
+      SetEnvIf Request_URI "/home/*" no-jk
+
+  # Now /home will goes to /home/dataxxx/
+      Alias /home /home/dataxxx/
+
+      <Directory "/home/dataxxx">
+          Options Indexes MultiViews
+          AllowOverride None
+          Order allow,deny
+          Allow from all
+      </Directory>
+
+      JkMount /* myssys-xxx
+
+  </VirtualHost>
+
+ + +

+Use the mod_jk JkAutoAlias directive to map all web application context directories +into Apache's document space. +

+ +

+Attempts to access the WEB-INF or META-INF directories within a web application context +or a Web Archive *.war within the Tomcat Host appBase (webapps) directory will fail with an +HTTP 403, Access Forbidden +

+ +
+  # Static files in all Tomcat webapp context directories are served by apache
+  JkAutoAlias /var/tomcat3/webapps
+
+  # All requests go to worker1 by default
+  JkMount /* ajp13
+  # Serve html, jpg and gif using httpd
+  JkUnMount /*.html ajp13
+  JkUnMount /*.jpg  ajp13
+  JkUnMount /*.gif  ajp13
+
+ +

+If you encoded all your URLs to contain the session id +(;jsessionid=...), and you later decide, you want to +move part of the content to Apache httpd, you can tell +mod_jk to strip off all session ids from URLs for +those requests, that do not get forwarded via mod_jk. +

+ +

+You enable this feature by setting JkStripSession to On. +It can be enabled individually for virtual servers. The default +value is Off. +

+ +
+
Building mod_jk on Unix
+

+The mod_jk build use the widely used configure system. +

+
Prepare your mod_jk configure from subversion
+In case you get source from subversion, ie without an existing configure script, +you should have autoconf for configuration and installation. +

+To create tomcat-connectors's autoconf script, you will need libtool +1.5.2, automake 1.10 and autoconf 2.59 or newer. The use of more recent +versions is encouraged, e.g. for reliable detection of the features of +recent version of operating systems. +

+Those tools will not be required if you are just using a package downloaded from apache.org, +they are only required for developers. +

+

+To create the configure script just type : + +

[user@host] ~ $ ./buildconf.sh

+

+
+ +
Using configure to build mod_jk
+

Here's how to use configure to prepare mod_jk for building, just type: +

+./configure [autoconf arguments] [tomcat-connectors arguments]
+
+

+ +

+You could set CFLAGS and LDFLAGS to add some platform specifics: +

+ +

[user@host] ~ $ LDFLAGS=-lc ./configure -with-apxs=/home2/local/apache/bin/apxs

+ +

+If you want to build mod_jk for different version of Apache httpd, like 1.3, 2.0 and 2.2, +you need to go through the full build process for each of them. +Please note, that httpd 2.0 and 2.2 modules are not compatible. The mod_jk directory +used is "apache-2.0" in both cases, but you need to compile separately. +

    +
  • +use configure and indicate the correct Apache httpd apxs location (--with-apxs) +
  • +
  • +use make +
  • +
  • +copy the resulting mod_jk.so binary from the apache-1.3 or apache-2.0 subdirectory +to the Apache httpd modules location. +
  • +
  • +make clean (to remove all previously compiled object files) +
  • +
  • +Start over with the apxs location for your next Apache httpd version. +
  • +
+ +

+
+ +
configure arguments
+

+ + + + + + + + + + + + + + + + + + + + + + + + + +
Apache related parameters
--with-apxs[=FILE]FILE is the location of the apxs tool. Default is finding apxs in PATH. +It builds a shared Apache module. It detects automatically the Apache version. +(2.0/2.2 and 1.3)
--with-apache=DIRDIR is the path where apache sources are located. +The apache sources should have been configured before configuring mod_jk. +DIR is something like: /home/apache/apache_1.3.19 +It builds a static Apache module.
--enable-EAPIThis parameter is needed when using Apache-1.3 and mod_ssl, otherwise you will get the error message: +"this module might crash under EAPI!" when loading mod_jk.so in httpd. +Not needed when --with-apxs has been used
--enable-prefork +In case you build mod_jk for a multi-threaded Apache httpd 2.0/2.2 MPM (Multi-Processing Module), +some areas of mod_jk code need to be synchronised to make it thread-safe. +Because configure can not easily detect, whether your are using a multi-threaded MPM, +mod_jk by default is always build thread-safe for Apache httpd 2.0/2.2. +If you are sure, that your MPM is not multi-threaded, you can use "--enable-prefork" +to force the removal of the synchronisation code (thus increasing performance a bit). +For instance, the prefork MPM is not multi-threaded. For Apache httpd 1.3 +this flag will be set automatically.
--disable-trace +When using log level "trace", mod_jk traces a lot of function calls with +"enter" and "exit" log messages. Even if the log level is not "trace", +comparing the log levels to decide about logging has some performance +impact.
+If you use "--disable-trace", then the trace log code doesn't get compiled +into the module binary and you might save some cycles during execution.
+Even with "--disable-trace" logging debug messages with debug log level +will still be possible.
--enable-api-compatibility +Only use httpd API functions available in all httpd production releases +of the chosen major httpd release branch. This improves binary +compatibility of module builds with httpd releases older than the release +against mod_jk is build (only between minor httpd versions).
--enable-flock +In case the operating system supports flock system call use this flag to enable this +faster locks that are implemented as system call instead emulated by GNU C library.
+However those locks does not work on NFS mounted volumes, so you can use +"--enable-flock" during compile time to force the flocks() calls.
+
+ + + + + + + + + + + + + + +
DEPRECATED: JNI related parameters
--enable-jniBuild the JNI worker and so the build process will require +some information about your Java Environment
--with-java-home=DIRDIR is the patch to the JDK root directory. Something like: /opt/java/jdk12
--with-os-type=SUBDIRSUBDIR is the os-type subdirectory, + configure should guess it correctly.
--with-arch-type=SUBDIRSUBDIR is the arch subdirectory, + configure should guess it correctly.
--with-java-platform=VALVAL is the Java platform 1 is 1.1.x and 2 is for 1.2 and higher, + configure should guess it correctly.
+

+

The JNI option has been deprecated. It will likely not work. Do not use it.

+
+ +
Examples of configure use
+ +

Apache 1.3 and 2.0/2.2 build
[user@host] ~ $ ./configure --with-apxs=/usr/sbin/apxs
[user@host] ~ $ make
[user@host] ~ $ cp ./apache-1.3/mod_jk.so /usr/lib/apache
[user@host] ~ $ make clean
[user@host] ~ $ ./configure --with-apxs=/usr/sbin/apxs2
[user@host] ~ $ make
[user@host] ~ $ cp ./apache-2.0/mod_jk.so /usr/lib/apache2

+ +

Apache 2.0/2.2 build with JNI support
[user@host] ~ $ ./configure --with-apxs2=/opt/apache2/bin/apxs \
--with-java-home=${JAVA_HOME} --with-java-platform=2 \
--enable-jni

+

The JNI option has been deprecated. It will likely not work. Do not use it.

+
+ +
Building mod_jk for Apache on Windows NT/2K/XP
+

+The module was developed using Visual C++ version 6.0, so having this environment is a prerequisite +if you want to perform a custom build. +

+

+The steps that you need to take are: +

+
    +
  • +Change directory to the apache 1.3 or apache 2.0 source directory depending on your version of Apache. +
  • +
  • +If you want to build mod_jk for Apache 1.3, set an APACHE1_HOME environment variable which points +to where your Apache 1.3 is installed. +A mod_jk module for Apache 2.0 build will require APACHE2_HOME environment variable to be set. +
  • +
  • +Copy mod_jk.so to Apache's modules directory. +
  • +
+

+An example on how to build mod_jk for Apache 1.3: +

+

Set location for Apache 1.3 sources
c:\>set APACHE1_HOME=c:\apache13
Change directory to the mod_jk module for Apache 1.3
c:\>cd c:\home\apache\jk\native\apache-1.3
Build the sources using MSDEV
c:\>MSDEV mod_jk.dsp /MAKE ALL
Copy the dll to your apache modules directory
c:\>cp release\mod_jk.so c:\apache13\modules\

+ +

+An example on how to build mod_jk for Apache 2.0: +

+

Set location for Apache 2.0 sources
c:\>set APACHE2_HOME=c:\apache20
Change directory to the mod_jk module for Apache 2.0
c:\>cd c:\home\apache\jk\native\apache-2.0
Build the sources using MSDEV
c:\>MSDEV mod_jk.dsp /MAKE ALL
Copy the dll to your apache modules directory
c:\>cp release\mod_jk.so c:\apache20\modules\

+ +

+If msdev is not in your path, enter the full path to msdev.exe. +Also, ApacheCore.lib is expected to exist in the ${APACHEX_HOME}\src\CoreD and +${APACHEX_HOME}\src\CoreR directories before linking will succeed. +You will need to build enough of the Apache source to create these libraries. +This will build both release and debug versions of the redirector plug-in (mod_jk). +An alternative will be to open mod_jk.dsp in msdev and build it using the build menu. +

+
Building mod_jk for Apache on System I - i5/OS (OS400)
+

+Since OS400 V4R5, System I (AS/400) has used Apache 2.0 as their primary web server, +replacing the old IBM webserver. +It's now possible to build mod_jk on System I thanks to the help of the IBM +Rochester Labs which has provided information and patches to adapt mod_jk to i5/OS. +

+

+You should have at least Apache 2.0.58 (product 5722DG1), a C Compiler and IFS. +Apache 2.0.58 is provided with the most recent set of PTFs for the iSeries Apache +server, which can be found at +http://www.ibm.com/servers/eserver/iseries/software/http/ +

+

+The all latest Apache 2 for i5/OS V5R3 (or V5R4) is now 2.0.58 (as of 2007/04/17). +Be sure to have the latest PTFs loaded if you want to make use of jk 1.2.15 and higher. +NB: The latest mod_jk known to work on i5/OS V5R3 was 1.2.19. +

+

+New in i5/OS V5R4, UTF is required, also for Apache modules, as such Apache modules do not require +translations to/from EBCDIC but works should be done to port mod_jk 1.2.23 (and higher) to V5R4. + +From the V5R4 Infocenter : + +As of i5/OS(tm) V5R4, modules must be recompiled with a UTF locale. This creates an environment where locale-dependent C runtime functions assume +that string data is encoded in UTF-8. Any hardcoded constants can be encoded in UTF-8 by adding a #pragma convert(1208) statement in the module. +Additionally, input data from the client will no longer be converted to EBCDIC but will be passed as-is. +Output data sent from the module is not converted either so it must be encoded in ASCII or UTF8 as required. +APR and HTTP APIs as of V5R4, expect data in UTF-8. Note that several APIs have additional functions that allow a CCSID to be set to +indicate the encoding of the parameters being passed. Conversion functions between UTF-8 and EBCDIC have been added. +Be sure to review APIs used by your module to be aware of current changes. + +

+

+To configure mod_jk on System I use the CL source provided with the mod_jk source. +

+
    +
  • +Get the latest mod_jk source and untar it on a Windows or Unix boxes +
  • +
  • +Create a directory in IFS, ie /home/apache +
  • +
  • +Send the whole jk source directory to System I directory via FTP. +
  • +
  • +Then go to the System I command line : +
  • +
+

Create mod_jk library
===>CRTLIB MOD_JK TEXT(‘Apache mod'jk tomcat connector module')
Create service program source file
===>CRTSRCPF MOD_JK/QSRVSRC TEXT(‘Service program source file’)
Create the CL build program source file
===>CRTSRCPF FILE(MOD_JK/QCLSRC) TEXT(‘Build program source file’)
Edit the service program source file
===>STRSEU MOD_JK/QSRVSRC MOD_JK

+

+In the edited file, specify that only jk_module should be exported : +

Columns . . : 1 71 Edit MOD_JK/QSRVSRC
SEU==> MOD_JK
*************** Beginning of data *************************************
0001.00 STRPGMEXP PGMLVL(*CURRENT)
0002.00 EXPORT SYMBOL("jk_module")
0003.00 ENDPGMEXP
****************** End of data ****************************************

+

+

+You could start to build all the modules of mod_jk (cases for V5R4 or previous releases): +

+

Copy the CL build program source for i5/OS before V5R4 from IFS
===>CPYFRMSTMF FROMSTMF('/home/apache/jk/native/apache-2.0/bldjk.qclsrc') +
TOMBR('/QSYS.LIB/MOD_JK.LIB/QCLSRC.FILE/BLDJK.MBR') MBROPT(*REPLACE)
Build the CL build program
===>CRTCLPGM PGM(MOD_JK/BLDJK) SRCFILE(MOD_JK/QCLSRC) TEXT('Apache mod_jk build program')
Launch the build
===>CALL MOD_JK/BLDJK
If the build if successfull, copy the new mod_jk module
===>CRTDUPOBJ OBJ(MOD_JK) FROMLIB(MOD_JK) OBJTYPE(*SRVPGM) TOLIB(QHTTPSVR) NEWOBJ(MOD_JK)

+

Copy the CL build program source for i5/OS V5R4 from IFS
===>CPYFRMSTMF FROMSTMF('/home/apache/jk/native/apache-2.0/bldjk54.qclsrc') +
TOMBR('/QSYS.LIB/MOD_JK.LIB/QCLSRC.FILE/BLDJK54.MBR') MBROPT(*REPLACE)
Build the CL build program for i5/OS V5R4
===>CRTCLPGM PGM(MOD_JK/BLDJK54) SRCFILE(MOD_JK/QCLSRC) TEXT('Apache mod_jk build program') TGTRLS(*CURRENT)
Launch the build for i5/OS V5R4
===>CALL MOD_JK/BLDJK54
If the build if successfull, copy the new mod_jk module
===>CRTDUPOBJ OBJ(MOD_JK) FROMLIB(MOD_JK) OBJTYPE(*SRVPGM) TOLIB(QHTTPSVR) NEWOBJ(MOD_JK)

+

+Next, you should restart your Apache 2.0 instance and enjoy this piece of OpenSource on System I. +

+

ENDTCPSVR SERVER(*HTTP) HTTPSVR(MYSERVER)
STRTCPSVR SERVER(*HTTP) HTTPSVR(MYSERVER)

+
Building mod_jk for Apache on MacOS/X
+

+Mac OS X (10.2.x) build notes : +

+

+Assuming that you are root : +

+

For Apache 1.3:
[user@host] ~ $ ./configure --with-apxs=/usr/sbin/apxs
[user@host] ~ $ cd apache-1.3
[user@host] ~ $ make -f Makefile.apxs
[user@host] ~ $ cp mod_jk.so /etc/libexec/httpd
For Apache 2.0:
[user@host] ~ $ ./configure --with-apxs=/usr/local/apache2/bin/apxs
(you should point to the directory where you installed Apache 2.0)
[user@host] ~ $ cd apache-2.0
[user@host] ~ $ make -f Makefile.apxs install

+
Getting mod_jk linked statically with Apache
+

+mod_jk allows to install mod_jk in the Apache source tree to get a statically +linked mod_jk. Having mod_jk in the httpd executable brings some performance +improvements. The configure option --with-apache prepare mod_jk to install it +in the Apache source tree. +The option --with-apache works both for Apache-1.3 and Apache-2.0. +The examples below show how to get mod_jk in the httpd process. +

+ +
Installation in Apache-2.0
+

/home/apache20/httpd-2.0.43 is the directory where the httpd-2.0 sources +are located.
[user@host] ~ $ ./configure --with-apache=/home/apache20/httpd-2.0.43
[user@host] ~ $ make
Install the mod_jk library and other files in +/home/apache20/httpd-2.0.43/modules:
[user@host] ~ $ make install
It is not possible to configure Apache directly because the config.m4 of mod_jk must +be added to the configure of httpd-2.0.
[user@host] ~ $ cd /home/apache20/httpd-2.0.43
[user@host] ~ $ sh buildconf
[user@host] ~ $ configure ... --with-mod_jk
[user@host] ~ $ make
[user@host] ~ $ make install

+

+The enable-jk=share and enable-jk=static are not supported. --with-mod_jk only +allow static linking of mod_jk. +

+
+ +
Installation in Apache-1.3
+

/home/apache/apache_1.3.27 is the directory where the apache-1.3 sources +are located.
[user@host] ~ $ ./configure --with-apache=/home/apache/apache_1.3.27
[user@host] ~ $ make
Install the libjk library, mod_jk.c, includes and other files in +/home/apache/apache_1.3.27/src/modules/jk:
[user@host] ~ $ make install
Configure in the Apache sources:
[user@host] ~ $ cd /home/apache/apache_1.3.27
[user@host] ~ $ configure ... --enable-module=dir --disable-shared=dir \
--activate-module=src/modules/jk/libjk.a \
--disable-shared=jk
[user@host] ~ $ make
[user@host] ~ $ make install

+

+The --enable-shared=jk is also working and builds a dso file. +

+

Just change the configure in the Apache sources:
[user@host] ~ $ configure ... --enable-module=dir --enable-shared=dir \
--activate-module=src/modules/jk/libjk.a \
--enable-shared=jk

+
+ +

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/webserver_howto/printer/iis.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/webserver_howto/printer/iis.html new file mode 100644 index 00000000..498b71f0 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/webserver_howto/printer/iis.html @@ -0,0 +1,684 @@ +The Apache Tomcat Connector - Webserver HowTo - IIS HowTo
Apache TomcatApache Logo

The Apache Tomcat Connector - Webserver HowTo

IIS HowTo

Introduction
+

+This document explains how to set up IIS to cooperate with Tomcat. +

+ +

+Normally IIS can not execute Servlets and Java Server Pages (JSPs), +configuring IIS to use the JK ISAPI redirector plugin will let IIS send servlet and +JSP requests to Tomcat (and this way, serve them to clients). +

+ +

+It is recommended that you also read the +Workers HowTo document +to learn how to setup the working entities between your web server and Tomcat Engines. +For more detailed configuration information consult the Reference Guide for +workers.properties, +uriworkermap +and IIS. +

+ + +
Document Conventions and Assumptions
+

+${tomcat_home} is the root directory of tomcat. +Your Tomcat installation should have the following subdirectories: + +

    +
  • +${tomcat_home}\conf - Where you can place various configuration files +
  • +
  • +${tomcat_home}\webapps - Containing example applications +
  • +
  • +${tomcat_home}\bin - Where you place web server plugins +
  • +
+

+

+In all the examples in this document ${tomcat_home} will be c:\tomcat. +A worker is defined to be a tomcat process that accepts work from the IIS server. +

+
+ + +
Supported Configuration
+

+The IIS-Tomcat redirector was developed and tested on: +

    +
  • +WinNT4.0-i386 SP4/SP5/SP6a (should be able to work with other service packs), Win2K and WinXP and Win98 +
  • +
  • +IIS4.0 and PWS4.0 (numerous people have working IIS 5 and IIS 6 configurations) +
  • +
  • +Tomcat 3.2 and later, Tomcat 4.x, Tomcat 5 and 5.5 and Tomcat 6 +
  • +
+

+ +

+The redirector uses ajp12 and ajp13 to send requests to the Tomcat containers. There is also an option to use Tomcat in process, +more about the in-process mode can be found in the in process howto. +

+
+ +
IIS 5 and 6 Notes
+

+There are extra steps you need to take for configuring Tomcat with IIS 5 and 6. Please see the appropriate links from +Tomcat Useful Links. +

+
+ +
IIS 7 notes
+

+There is a known bug in IIS that may result in incomplete log messages. See bug 45769 +for further details. +

+
+ +
Who support ajp protocols ?
+

+The ajp12 protocol is only available in Tomcat 3.2.x and 3.3.x. +

+ +

+The ajp12 has been deprecated with Tomcat 3.3.x and you should use instead +ajp13 which is the only ajp protocol known by Tomcat 4.x, 5 and 5.5 and Tomcat 6. +

+ +

+Of course Tomcat 3.2.x and 3.3.x also support ajp13 protocol. +

+ +

+Others servlet engines such as jetty have support for ajp13 protocol +

+ +
+ +
How does it work ?
+

+

    +
  1. +The IIS-Tomcat redirector is an IIS plugin (filter + extension), IIS load the redirector plugin and calls its +filter function for each in-coming request. +
  2. +
  3. +The filter then tests the request URL against a list of URI-paths held inside uriworkermap.properties, +If the current request matches one of the entries in the list of URI-paths, +the filter transfers the request to the extension. +
  4. +
  5. +The extension collects the request parameters and forwards them to the appropriate worker using the defined +protocol like ajp13. +
  6. +
  7. +The extension collects the response from the worker and returns it to the browser. +
  8. +
+

+
+ +
Installation
+

+A pre-built version of the ISAPI redirector server plugin, isapi_redirect.dll, is available under +the win32/i386 directory of tomcat-connectors distribution. +For those using Netscape as your browser, try downloading a zip version of the file, if available. +There can be problems using Netscape to download DLL files. + +You can also build a copy locally from the source present in tomcat-connectors distribution. + +The Tomcat redirector requires three entities: + +

    +
  • +isapi_redirect.dll - The IIS server plugin, either obtain a pre-built DLL or build it yourself (see the build section). +
  • +
  • +workers.properties - A file that describes the host(s) and port(s) used by the workers (Tomcat processes). +A sample workers.properties can be found under the conf directory. +
  • +
  • +uriworkermap.properties - A file that maps URL-Path patterns to workers. +A sample uriworkermap.properties can be found under the conf directory as well. +
  • +
+

+ +

+The installation includes the following parts: + +

    +
  • +Configuring the ISAPI redirector with a default /examples context and checking that you can serve servlets with IIS. +
  • +
  • +Adding more contexts to the configuration. +
  • +
+

+ +
Configuring the ISAPI Redirector
+

+In this document I will assume that isapi_redirect.dll is placed in +c:\tomcat\bin\win32\i386\isapi_redirect.dll and +that the properties files which you created are in c:\tomcat\conf. +

+

+

    +
  1. +In the registry, create a new registry key named +"HKEY_LOCAL_MACHINE\SOFTWARE\Apache Software Foundation\Jakarta Isapi Redirector\1.0" +
  2. +
  3. +Add a string value with the name extension_uri and a value of /jakarta/isapi_redirect.dll +
  4. +
  5. +Add a string value with the name log_file and a value pointing to where you want your +log file to be (for example c:\tomcat\logs\isapi.log). +
  6. +
  7. +Add a string value with the name log_level and a value for your log level +(can be debug, info, error or emerg). +
  8. +
  9. +Add a string value with the name worker_file and a value which is the full path +to your workers.properties file (for example c:\tomcat\conf\workers.properties) +
  10. +
  11. +Add a string value with the name worker_mount_file and a value which is the full path +to your uriworkermap.properties file (for example c:\tomcat\conf\uriworkermap.properties) +
  12. +
  13. +Using the IIS management console, add a new virtual directory to your IIS/PWS web site. +The name of the virtual directory must be jakarta. +Its physical path should be the directory where you placed isapi_redirect.dll +(in our example it is c:\tomcat\bin\win32\i386). +While creating this new virtual directory assign it with execute access. +
  14. +
  15. +Using the IIS management console, add isapi_redirect.dll as a filter in your IIS/PWS web site. +The name of the filter should reflect its task (I use the name tomcat), +its executable must be our c:\tomcat\bin\win32\i386\isapi_redirect.dll. +For PWS, you'll need to use regedit and add/edit the "Filter DLLs" key under +HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\W3SVC\Parameters. +This key contains a "," separated list of dlls (full paths) - +you need to insert the full path to isapi_redirect.dll. +
  16. +
  17. +If you're using IIS 6.0 you must also do the following: +
    +Using the IIS management console, add the Jakarta Isapi Redirector to the Web +Service Extensions. +
      +
    1. Right-click on Web Service Extensions and choose Add a new Web Service +Extension.
    2. +
    3. Enter tomcat for the Extension Name.
    4. +
    5. Add the isapi_redirect.dll to the required files.
    6. +
    7. Check the Set extension status to Allowed.
    8. +
    9. Click on OK.
    10. +
    +
  18. +
  19. +Restart IIS (stop + start the IIS service), make sure that the tomcat filter is marked with a green up-pointing arrow. +Under Win98 you may need to cd WINDOWS\SYSTEM\inetsrv and type PWS /stop +( the DLL and log files are locked - even if you click the stop button, +PWS will still keep the DLLs in memory. ). Type pws to start it again. +
  20. +
+

+

+That's all, you should now start Tomcat and ask IIS to serve you the /examples context. +Try http://localhost/examples/jsp/index.html for example and +execute some of the JSP examples. +

+

+If this does not work successfully, refer to the Troubleshooting section below for help on correcting the problem. +

+ +
Adding additional Contexts
+

+The examples context is useful for verifying your installation, +but you will also need to add your own contexts. Adding a new context requires two operations: +

+

+

    +
  1. +Adding the context to Tomcat (I am not going to talk about this). +
  2. +
  3. +Adding the context to the ISAPI redirector. +
  4. +
+

+

+Adding a context to the ISAPI redirector is simple, all you need to do is to edit +your uriworkermap.properties and to add a line that looks like: +

+ +
+  /context/*=worker_name
+
+ +

+Workers and their name are defined in workers.properties, by default workers.properties comes +with a single pre-configured worker named "defworker" so you can use it. +As an example, if you want to add a context named "shop", the line that you should add to +uriworkermap.properties will be: +

+ +
+  /shop/*=defworker
+
+ +After saving uriworkermap.properties restart IIS and it will serve the new context. +

+The above should be all you need for IIS to pass through to Tomcat any request for any URI which corresponds +to a Tomcat context (webapp). +

+
+ +
Advanced Context Configuration
+

+If your webiste is very busy (more than 100 requests/second, or more than 100 simultaneous client connections), +it might sometimes be desirable to have IIS serve static content (html, gif, jpeg etc.) directly, +even if these files are part of a context served by Tomcat. Allowing IIS to serve such files directly may + avoid the small overhead consisting of passing the request to Tomcat via the redirector, and may free up + Tomcat somewhat, by using it only to process requests that only Tomcat can handle (e.g. requests to JSP pages and java servlets). +

+

+For example, consider the html and gif files in the examples context : you could serve these files directly +with IIS; there is no need to serve them from the Tomcat process. +

+

However, you should be very careful when you implement the following configuration style, because by doing so you are +in fact providing a "back-door" to IIS, and allowing it to serve files out of a Tomcat context without Tomcat's knowledge, +thus bypassing any security +restrictions which Tomcat itself and the Tomcat context (webapp) may place on those files.

+

+Making IIS serve static files that are part of the Tomcat contexts requires the following: +

    +
  1. +Configuring IIS to know about the Tomcat contexts +
  2. +
  3. +Configuring the redirector to leave the static files for IIS +
  4. +
+

+ +

+Adding a Tomcat context to IIS requires the addition of a new IIS virtual directory that covers the Tomcat context. +For example adding a /example IIS virtual directory that covers the c:\tomcat\webapps\examples directory. +

+ +

+Configuring the redirector is somewhat harder, you will need to specify the exact +URL-Path pattern(s) which you want Tomcat to handle (usually only JSP files and servlets). +This requires a change to the uriworkermap.properties : + +

+  For the examples context it requires to replace the following line
+  /examples/*=defworker
+  with the following two lines
+  /examples/*.jsp=defworker
+  /examples/servlet/*=defworker
+
+

+ +

+As you can see the second configuration is more explicit, it actually instruct the redirector +to redirect only requests to resources under /examples/servlet/ and resources under /examples/ +whose name ends with .jsp. +

+ +

+You can even be more explicit and provide lines such as: + +

+  /example/servletname=defworker
+
+

+ +

+that instructs the redirector to redirect all requests whose URL-path matches the leading string "/example/servletname" +to the worker named defworker. +

+ +
+ +
Protecting the content of your Tomcat contexts
+

Once again, be aware that by allowing IIS to access the content of your Tomcat context directly, you are +potentially bypassing Tomcat's protection of that content. You should thus make sure to protect this content +at the IIS level if needed, by using the corresponding IIS management console functions. +

+

+In particular, each servlet application (context) has a special directory named WEB-INF, +which contains sensitive configuration data and Java classes, and which should always be kept hidden from web users. +Using the IIS management console it is possible to protect the WEB-INF directory from user access, but considering that +this is a general requirement, and considering that it is easy to forget to implement this protection +at the IIS level, the redirector plugin does it automatically for you, and it will reject any request +which contains WEB-INF in its URL-path. +

+
+ +
Advanced Worker Configuration
+

+Sometimes you may want to serve different contexts with different Tomcat processes +(for example to spread the load among different machines). +To achieve such a goal you will need to define several workers and assign each context to its own worker. +

+

+Defining additional workers is done in the workers.properties file. This file includes two types of entries: +

+ +

+

+  # An entry that lists all the workers defined
+  worker.list=worker1, worker2
+  # Entries that define the host and port associated with each of these workers
+  worker.worker1.host=localhost
+  worker.worker1.port=8009
+  worker.worker1.type=ajp13
+  worker.worker2.host=otherhost
+  worker.worker2.port=8009
+  worker.worker2.type=ajp13
+
+

+ +

+The above example defined two workers, now we can use these workers to serve two different contexts +each with its own worker: +

+  example uriworkermap.properties fragment
+  /examples/*=worker1
+  /webpages/*=worker2
+
+

+ +

+As you can see the examples context is served by worker1 while the +webpages context is served by worker2. +

+ +

+More information on using and configuring workers in the Workers HowTo +and in the worker.properties configuration reference. +

+ +
+ +
Building ISAPI redirector
+

+The redirector was developed using Visual C++ Ver.6.0, so having this environment is a prerequisite if you want +to perform a custom build. You should also have the IIS developer SDK. + +The steps that you need to take are: +

    +
  • +Change directory to the isapi plugins source directory. +
  • +
  • +Make the source with MSDEV +
  • +
+

Change directory to the isapi plugins source directory
c:\>cd c:\home\apache\jk\iis
Build the sources using MSDEV
c:\>MSDEV isapi.dsp /MAKE ALL

+

+

+If msdev is not in your path, enter the full path to msdev.exe. +This will build both release and debug versions of the redirector plugin. +An alternative will be to open the isapi workspace file (isapi.dsw) in msdev and +build it using the build menu. +

+
Troubleshooting
+

+It is easy to have the ISAPI redirector not work the first time you try to install it. +

+

+If this happens to you, here are some steps to follow to try to correct the problem. +

+

+These steps aren't guaranteed to cover all possible problems, +but they should help find the typical mistakes. +

+

+If you make any corrections during these steps, restart the IIS service as described above in the last step +of the installation, then retry the step. +

+ +

To enable error tracking, make sure web site activity is being logged. +For PWS 4.0 make sure "Save Web Site Activity Log" is checked in the Advanced Options of the Personal Web Manager. +

+ +

+Note: These steps assume your worker_mount_file setting points to an unmodified copy of the +uriworkermap.properties file.
+Results may be misleading if worker_mount_file points to a modified uriworkermap.properties +or the uriworkermap.properties-auto file.
+It is also assumed that the "/examples" context works correctly if you access Tomcat directly. +

+ +
Win98
+

+Start the IIS service and Tomcat. +

+

+Check for the presence of the ISAPI redirector log file you specified in the log_file setting. +If not found, verify the following: +

+
    +
  • +Check the "Filter DLLs" setting in the "HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\W3SVC\Parameters" +key and make sure the path is correct. +
  • +
  • +Check the spelling of the "HKEY_LOCAL_MACHINE\SOFTWARE\Apache Software Foundation\Jakarta Isapi Redirector\1.0" key. +Case isn't important, but an incorrect letter will prevent the isapi_redirect.dll from finding its registry settings. +
  • +
  • +Check the log_file setting for typos, name and data. Also insure the directory in which the log file will appear already exists. +
  • +If the above are set correctly, the ISAPI redirector should be able to create the log file. +
+

+Invoke the URL http://localhost/examples/jsp/index.html +in your browser. +Case is important in Tomcat. The characters following "localhost" in the URL must be lower case. +If the page fails to appear, stop the IIS service (required to view the IIS log file). +Then examine the last line in the IIS log file in found in SYSTEM/LogFiles/W3SVC1 : +

+

+If the last line contains: +

+
+  GET "/examples/jsp/index.html HTTP/1.1" 404
+
+

+then the ISAPI redirector is not recognising that it should be handling requests for the "/examples" context. +Check the following: +

+
    +
  • +Check the extension_uri name for typos. +
  • +
  • +Check the worker_file setting for typos, name and data. +
  • +
  • +Check the worker_mount_file setting typos, name and data. +
  • +If these are set correctly, the ISAPI redirector should recognise that it should handle requests for the "/examples" context. +
+ +

If the last line contains something like: +

+ +
+  GET "/jakarta/isapi_redirect.dll HTTP1.1"
+
+ +

+then the ISAPI redirector is recognising that it should handle the request, +but is not successful at getting Tomcat to service the request. +

+ +

+You should check the HTTP error code following GET "/..." : +

+ +
+  Error 404
+  GET "/..." 404
+
+ +
    +
  • +Make sure you entered the URL correctly. +
  • +
  • +Make sure the virtual directory created was called "jakarta". +It should display in Personal Web Manager as "/jakarta" (without the quotes). +
  • +
  • +Make sure the extension_uri data begins with "/jakarta/" (without the quotes). +
  • +
+ +
+  Error 500
+  GET "/..." 500
+
+ +
    +
  • +Make sure that "isapi_redirect.dll" follows "/jakarta/" in the extension_uri setting. +
  • +
  • +Check the workers.properties file and make sure the port setting for worker.ajp12.port is the same as the port specified in the server.xml for the "Apache AJP12 support". +
  • +
+ +
+  Error 200 or 403
+  GET "/..." 200
+  GET "/..." 403
+
+ +
    +
  • +Make sure you have checked Execute Access +for the jakarta virtual directory in the Advanced Options of the Personal Web Manager. +
  • +
+ +

+If the above settings are correct, the index.html page should appear in your browser. +You should also be able to click the Execute links to execute the JSP examples. +

+ +
+ +
WinNT/Win2K/WinXP
+

+Start the World Wide Web Publishing Service and Tomcat. +

+

+Check for the presence of the ISAPI redirector log file you specified in the log_file setting. +If not found, check the following: +

+
    +
  • +Check the "executable" you set for the filter in the IIS Management Console and make sure the path is correct. +
  • +
  • Check the spelling of the "HKEY_LOCAL_MACHINE\SOFTWARE\Apache Software Foundation\Jakarta Isapi Redirector\1.0" key. +Case isn't important, but an incorrect letter will prevent the isapi_redirect.dll from finding its registry settings. +
  • +
  • +Check the log_file setting for typos, name and data. Also insure the directory in which the log file will appear already exists. +
  • +If the above are set correctly, the ISAPI redirector should be able to create the log file. +
+ +

+Check the tomcat filter you added and make sure its status shows a green upward-pointing arrow. +If not, check the following: +

+
    +
  • +Check the worker_file setting for typos, name and data. +
  • +
  • +Check the worker_mount_file setting typos, name and data. +
  • +If the above are set correctly, the green upward-pointing arrow should appear, even if the other settings are wrong. +
+ +

+Invoke the URL http://localhost/examples/jsp/index.html +in your browser. Case is important in Tomcat. The characters following "localhost" in the URL must be lower case. +If the page fails to appear, examine the last line in the IIS server log file in found in SYSTEM32/LogFiles/W3SVC1. +

+ +

+The last line should contain something like: GET "/jakarta/isapi_redirect.dll HTTP1.1", +which indicates the ISAPI redirector is recognising that it should handle the request. +

+ +

+You should check the HTTP error code following GET "/..." : +

+ +
+  Error 404
+  GET "/..." 404
+
+ +
    +
  • +Make sure you entered the URL correctly. +
  • +
+ +
+  Error 500
+  GET "/..." 500
+
+ +
    +
  • +Make sure the virtual directory created was called "jakarta". +
  • +
  • +Make sure that the extension_uri setting is correct. +
  • +
  • +Check the workers.properties file and make sure the port setting for worker.ajp12.port is the same as the port specified in the server.xml for the "Apache AJP12 support". +
  • +
+ +
+  Error 200 or 403
+  GET "/..." 200
+  GET "/..." 403
+
+ +
    +
  • +Make sure you have checked Execute Access for the jakarta virtual directory in the +Advanced Options of the Personal Web Manager. +
  • +
+ +

+If the above settings are correct, the index.html page should appear in your browser. +You should also be able to click the Execute links to execute the JSP examples. +

+
+ + +

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/docs/webserver_howto/printer/nes.html b/rubbos/app/tomcat-connectors-1.2.32-src/docs/webserver_howto/printer/nes.html new file mode 100644 index 00000000..efb8f5a5 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/docs/webserver_howto/printer/nes.html @@ -0,0 +1,482 @@ +The Apache Tomcat Connector - Webserver HowTo - SunOne -- Netscape/iPlanet HowTo
Apache TomcatApache Logo

The Apache Tomcat Connector - Webserver HowTo

SunOne -- Netscape/iPlanet HowTo

Introduction
+

+This document explains how to set up Sun ONE Web Server previously known as +Netscape web servers to cooperate with Tomcat. +

+ +

+Normally the Sun ONE Web Servers come with their own Servlet engine, +but you can also configure them to send servlet and JSP requests to Tomcat +using the NSAPI redirector plugin. +

+ +

+It is recommended that you also read the Workers HowTo document +to learn how to setup the working entities between your web server and Tomcat Engines. +

+ + +
Document Conventions and Assumptions
+

+${tomcat_home} is the root directory of tomcat. +Your Tomcat installation should have the following subdirectories: + +

    +
  • +${tomcat_home}\conf - Where you can place various configuration files +
  • +
  • +${tomcat_home}\webapps - Containing example applications +
  • +
  • +${tomcat_home}\bin - Where you place web server plugins +
  • +
+

+

+In all the examples in this document ${tomcat_home} will be c:\tomcat. +A worker is defined to be a tomcat process that accepts work from the Sun ONE Web Server. +

+
+ + +
Supported Configuration
+

+The NSAPI-Tomcat redirector was developed and tested on: +

    +
  • +WINNT 2000/XP/2003 (should be able to work with other service packs) and some Unixes +
  • +
  • +Sun ONE Web Server 6.1 +
  • +
  • +Tomcat 4.1.x , Tomcat 5.0.x and Tomcat 5.5.x +
  • +
+

+ +

+The redirector uses ajp12 and ajp13 to send requests to the Tomcat containers. +There is also an option to use Tomcat in process, +more about the in-process mode can be found in the in process howto. +

+
+ +
Who support ajp protocols ?
+

+The ajp12 protocol is only available in Tomcat 3.2.x and 3.3.x. +

+ +

+The ajp12 has been deprecated with Tomcat 3.3.x and you should use instead +ajp13 which is the only ajp protocol known by Tomcat 4.0.x, 4.1.x, 5.0.x, 5.5.x and 6. +

+ +

+Of course Tomcat 3.2.x and 3.3.x also support ajp13 protocol. +

+ +

+Others servlet engines such as jetty have support for ajp13 protocol +

+ +
+ + +
How does it work ?
+

+

    +
  1. +The NSAPI-Tomcat redirector is an Netscape service step plugin, +Netscape load the redirector plugin and calls its service handler +function for request that are assigned to the "servlet" configuration object. +
  2. +
  3. +For each in-coming request Netscape will execute the set of NameTrans directives +that we added to obj.conf, the assign-name function will check if it's from +parameter matches the request URL. +
  4. +
  5. +If a match is found, assign-name will assign the servlet object name to the request. +This will cause Netscape to send the request to the servlet configuration object. +
  6. +
  7. +Netscape will execute our jk_service extension. The extension collects the +request parameters and forwards them to the appropriate worker using the ajp13 protocol +(the worker="defworker" parameter in jk_service inform it that the worker for this request is named defworker). +the workers properties files, workers.properties, will indicate that defworker use ajp13 protocol. +
  8. +
  9. +The extension collects the response from the worker and returns it to the browser. +
  10. +
+

+
+ +
Installation
+

+A pre-built version of the NSAPI redirector, nsapi_redirect.dll, may be available under +the win32/i386 directory of tomcat-connectors distribution. +For those using Netscape as your browser, try downloading a zip version of the file, if available. + +You can also build a copy locally from the source present in tomcat-connectors distribution. + + +The Tomcat redirector requires two entities: +

    +
  • +nsapi_redirect.dll (Windows) -or- nsapi_redirector.so (Unix) - The NSAPI server plugin, either obtain a pre-built DLL/so or build it yourself +(see the build section). +
  • +
  • +workers.properties - A file that describes the host(s) and port(s) used by the workers (Tomcat processes). +A sample workers.properties can be found under the conf directory. +
  • +
+ +The installation includes the following parts: + +
    +
  • +Configuring the NSAPI redirector with a default /examples context and checking that you can serve servlets +with Netscape. +
  • +
  • +Adding more contexts to the configuration. +
  • +
+ +

+
Configuring the NSAPI Redirector
+

+In this document we'll assume that nsapi_redirect.dll is placed in +c:\jk\lib\nsapi_redirect.dll, the properties file is inc:\jk\conf +and you created a log directory c:\jk\logs +

+ +
    +
  • +If the built in servlet support is working disable it. +
  • +
  • +Add the redirector plugin into the Netscape server configuration. +Edit your server magnus.conf and add the following lines: +
  • +
+ +
+  
+  Init fn="load-modules" funcs="jk_init,jk_service" shlib="c:/jk/lib/nsapi_redirect.dll" shlib_flags="(global|now)"
+  Init fn="jk_init" worker_file="c:/jk/conf/workers.properties" log_level="debug" log_file="c:/jk/logs/nsapi.log" shm_file="c:/jk/logs/jk_shm"
+
+
    +
  • +Edit your server obj.conf and add the following lines: +
  • +
+
+
+  
+  In the default object NameTrans section
+  <Object name="default">
+      
+  NameTrans fn="assign-name" from="/servlets-examples(|/*)" name="jknsapi" 
+  NameTrans fn="assign-name" from="/jsp-examples(|/*)" name="jknsapi"
+  ....
+  </Object>
+  
+  Create a new configuration object by adding the following lines to the end of the obj.conf file
+  
+  <Object name="jknsapi">
+  ObjectType fn=force-type type=text/plain
+  Service fn="jk_service" method="*" worker="worker1"
+  </Object>
+
+ +
    +
  • +Edit your worker definition file workers.properties. You should at least choose a connection pool size: +
  • +
+ +
+  #An entry that lists all the workers defined. For example:
+  worker.list=worker1
+  
+  # Entries that define the host and port associated with these workers.
+  worker.worker1.host=localhost
+  worker.worker1.port=8009
+  worker.worker1.type=ajp13
+  worker.worker1.connection_pool_size=50
+
+ +
    +
  • +Restart Web Server (stop and start the server) +
  • +
+ +

+That's all, now you should start tomcat and ask for http://server:port/servlets-examples/ +

+

+The file obj.conf seems to be sensitive to leading white space in lines, especially in +the Object element. Make sure you have no leading white space (no indentation) +on any line of this file. +

+ +
Adding additional Contexts
+

+The examples context is useful for verifying your installation, but you will also need to add your own contexts. +Adding a new context requires two operations: +

+
    +
  • +Adding the context to Tomcat (I am not going to talk about this). +
  • +
  • +Assigning the NSAPI redirector to handle this context. +
  • +
+ +

+Assigning the NSAPI redirector to handle this context is simple, +all you need to do is to edit obj.conf and add a NameTrans line that looks like: +

+ +
+  NameTrans fn="assign-name" from="/<context name>/*" name="jknsapi"
+
+ +

+After saving obj.conf restart Netscape and it will serve the new context. +

+
+ +
Advanced Context Configuration
+

+Sometimes it is better to have Netscape serve the static pages (html, gif, jpeg etc.) +even if these files are part of a context served by Tomcat. For example, consider the html and gif files in the examples context, there is no need to serve them from the Tomcat process, Netscape will suffice. +

+

+Making Netscape serve static files that are part of the Tomcat contexts requires the following: +

+
    +
  • +Configuring Netscape to know about the Tomcat contexts +
  • +
  • +Make sure that the WEB-INF directory is protected from access. +
  • +
  • +Configuring Netscape to assign the NSAPI redirector only specific requests that requires JSP/Servlet handling. +
  • +
+ +

+Adding a Tomcat context to Netscape requires the addition of a new Netscape virtual directory +that covers the Tomcat context. +

+ +

+For example, adding a /example Netscape virtual directory that +covers the c:\tomcat\webapps\examples directory. +

+ +

+To add a new virtual directory add the following line to your obj.conf: +

+ +
+  NameTrans fn=pfx2dir from=/examples dir="c:/tomcat/webapps/examples"
+
+ +

+WEB-INF protection requires some explanation; Each servlet application (context) has a special directory named WEB-INF, +this directory contains sensitive configurations data and Java classes and must be kept hidden from web users. +WEB-INF can be protected by adding the following line to the PathCheck section in the default configuration object: +

+ +
+  PathCheck fn="deny-existence" path="*/WEB-INF/*"
+  
+  This line instructs the Netscape server to reject any request with a URL that contain the path /WEB-INF/.
+
+ +

+Configuring Netscape to assign the NSAPI redirector only specific requests is somewhat harder, +you will need to specify the exact URL-Path pattern(s) that you want Tomcat to handle +(usually only JSP files and servlets). +

+ +

+This requires a change to NameTrans portion of obj.conf. +

+ +
+  For the examples context it requires to replace the following line:
+  
+  NameTrans fn="assign-name" from="/examples/*" name="jknsapi"
+  
+  with the following two lines:
+  
+  NameTrans fn="assign-name" from="/examples/jsp/*.jsp" name="jknsapi"
+  NameTrans fn="assign-name" from="/examples/servlet/*" name="jknsapi"
+
+ +

+As you can see the second configuration is more explicit, it actually instructs +Netscape to assign the redirector with only requests to resources under +/examples/servlet/ and resources under /examples/ whose name ends with .jsp. +

+ +

+You can be even more explicit and provide lines such as: +

+ +
+  NameTrans fn="assign-name" from="/examples/servletname" name="jknsapi"
+  
+  Instructs Netscape to assign the redirector request whose URL-Path equals /example/servletname
+
+ +
+ +
Advanced Worker Configuration
+

+Sometimes you want to serve different contexts with different Tomcat processes +(for example to spread the load among different machines). +To achieve such goal you will need to define several workers and assign each context with its own worker. +

+ +

+Defining workers is done in workers.properties, this file includes two types of entries: +

+ +
+  #An entry that lists all the workers defined. For example:
+  worker.list=worker1,worker2
+  
+  # Entries that define the host and port associated with these workers.
+  worker.worker1.host=localhost
+  worker.worker1.port=8009
+  worker.worker1.type=ajp13
+
+  worker.worker2.host=otherhost
+  worker.worker2.port=8009
+  worker.worker2.type=ajp13
+
+ +

+The above examples defined two workers, now we can use these workers to serve two different +contexts each with it's own worker. +Submitting requests to different workers is accomplished by using multiple Service directives +in the servlet configuration Object, each with a different path pattern parameter. +

+ +

+For example, if we want to submit the /examples context to the worker named worker1 and the +/webpages context to the worker named worker2 we should use the following configuration: +

+ +
+  <Object name="jknsapi">
+  ObjectType fn=force-type type=text/plain
+  Service fn="jk_service" worker="worker1" path="/examples/*"
+  Service fn="jk_service" worker="worker2" path="/webpages/*"
+  Service fn="jk_service" worker="worker1"
+  </Object>
+
+ +

+More informations on using and configuring workers in the Workers HowTo +and in the worker.properties configuration reference. + +

+
+ +
Building NSAPI DLL redirector for Windows
+

+The redirector was developed using Visual C++ Ver.6.0, so having this environment is a prereq if you want +to perform a custom build. You should also have NES developer SDK + +The steps that you need to take are: +

    +
  • +Change directory to the nsapi plugins source directory. +
  • +
  • +Edit nsapi.dsp and update the include and library path to reflect your own Netscape server installation +(search for a /I compiler option and /libpath linker option) +
  • +
  • +Make the source with MSDEV +
  • +
+ +Change directory to the nsapi plugins source directory +c:\>cd c:\home\apache\jk\nsapi
+Build the sources using MSDEV +c:\>MSDEV nsapi.dsp /MAKE ALL
+
+

+

+If msdev is not in your path, enter the full path to msdev.exe. +This will build both release and debug versions of the redirector plugin. +An alternative will be to open the nsapi workspace file (nsapi.dsw) in msdev and +build it using the build menu. +

+
Building NSAPI so plugin redirector for Unix
+

+The redirector requires either gcc (Linux) or gcc or the Sun cc compiler (Solaris). + +The steps that you need to take are: +

    +
  • +Change directory to the nsapi plugins source directory (src/native). +
  • +
  • +configure for Netscape/iPlanet/SunONE webserver. +
  • +
  • +Change directory to the nsapi netscape directory (./netstape). +
  • +
  • +Set environment variables JAVA_HOME resp. SUITSPOT_HOME to the location of your Java installation +resp. Netscape server installation. Depending on the web server version, you must add the subdirectory +"plugins" to SUITSPOT_HOME. +The variable is correct, if the file $SUITSPOT_HOME/include/nsapi.h exists. +
  • +
  • +Edit Makefile.solaris resp. Makefile.linux and update the variables according to your needs. +In the Solaris Makefile, you need to switch the commented lines in order to use the Sun compiler cc +instead of GNU gcc. +
  • +
  • +Make the source with gmake. +
  • +
+ +Change directory to the nsapi plugins source directory +c:\>cd /usr/local/src/tomcat-connectors-xxx-src/native
+configure for Netscape/iPlanet/SunONE webserver +c:\>./configure --enable-netscape
+Change directory to the nsapi netscape directory +c:\>cd netscape
+Set JAVA_HOME (ksh example) +c:\>export JAVA_HOME=/path/to/my/java
+Set SUITSPOT_HOME (ksh example) +c:\>export SUITSPOT_HOME=/path/to/my/netscape/server
+Edit the Makefile +c:\>vi Makefile.solaris
+Make the source with gmake +c:\>gmake -f Makefile.solaris
+
+

+

+After the build, you will have the required nsapi_redirector.so plugin. +

+

+ Copyright © 1999-2011, Apache Software Foundation +
\ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/build.properties.default b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/build.properties.default new file mode 100644 index 00000000..d1d0b64e --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/build.properties.default @@ -0,0 +1,22 @@ +# ----------------------------------------------------------------------------- +# build.properties.default +# +# This is an example "build.properties" file, used to customize building Tomcat +# for your local environment. It defines the location of all external +# modules that Tomcat depends on. Copy this file to "build.properties" +# in the top-level source directory, and customize it as needed. +# +# $Id: build.properties.default 892628 2009-12-20 18:01:53Z markt $ +# ----------------------------------------------------------------------------- + +# ----- Compile Control Flags ----- +compile.debug=on +compile.deprecation=off +compile.optimize=off + +# ----- Path to Tomcat installation ----- +catalina.build=/usr/local/share/tomcat-5.5 + +# ----- Some version dependent jar file names ----- +commons-modeler.jar=commons-modeler-2.0.1.jar +commons-logging.jar=commons-logging-api-1.1.1.jar diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/build.xml b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/build.xml new file mode 100644 index 00000000..33926615 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/build.xml @@ -0,0 +1,155 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/conf/jkstatus-tasks.xml b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/conf/jkstatus-tasks.xml new file mode 100644 index 00000000..36b5839a --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/conf/jkstatus-tasks.xml @@ -0,0 +1,41 @@ + + + + + + Apache mod_jk ant jkstatus Tasks + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/example/jkstatus.properties.default b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/example/jkstatus.properties.default new file mode 100644 index 00000000..4e3f0460 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/example/jkstatus.properties.default @@ -0,0 +1,23 @@ +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +jkstatus.host=localhost +jkstatus.port=2090 +jkstatus.username=manager +jkstatus.password=tomcat +jkstatus.url=http://${jkstatus.host}:${jkstatus.port}/jkstatus +jkstatus.testlb=loadbalancer +jkstatus.testworker=node01 +catalina.home=../../../../build/build \ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/example/jkstatus.xml b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/example/jkstatus.xml new file mode 100644 index 00000000..7f4c1b4d --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/example/jkstatus.xml @@ -0,0 +1,111 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/example/show.txt b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/example/show.txt new file mode 100644 index 00000000..9fffb7dd --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/example/show.txt @@ -0,0 +1,25 @@ + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + +How to use the show example: +ant -f show.xml +Configure mod_jk (httpd.conf and workers.properties): +JkMount /jkstatus jkstatus + +worker.list=jkstatus +worker.jkstatus.type=status + +Adjust jkstatus.properties.default: +jkstatus.port (for example). diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/example/show.xml b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/example/show.xml new file mode 100644 index 00000000..897745a9 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/example/show.xml @@ -0,0 +1,49 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/AbstractJkStatusTask.java b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/AbstractJkStatusTask.java new file mode 100644 index 00000000..c94258ae --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/AbstractJkStatusTask.java @@ -0,0 +1,209 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.jk.status; + +import java.io.BufferedOutputStream; +import java.io.IOException; +import java.io.InputStream; +import java.io.InputStreamReader; +import java.net.HttpURLConnection; +import java.net.MalformedURLException; +import java.net.ProtocolException; +import java.net.URL; +import java.net.URLConnection; + +import org.apache.catalina.ant.AbstractCatalinaTask; +import org.apache.catalina.util.Base64; +import org.apache.tools.ant.BuildException; +import org.apache.tools.ant.Project; + +/** + * Ant task that implements mod_jk 1.2.20 result message string + * + * @author Peter Rossbach + * @version $Revision: 802231 $ + * @since mod_jk 1.2.20 + */ +public abstract class AbstractJkStatusTask extends AbstractCatalinaTask { + + /** + * Execute the requested operation. + * + * @exception BuildException + * if an error occurs + */ + public void execute() throws BuildException { + + super.execute(); + checkParameter(); + StringBuffer sb = createLink(); + execute(sb.toString(), null, null, -1); + + } + + protected abstract void checkParameter() ; + protected abstract StringBuffer createLink() ; + + /** + * Execute the specified command, based on the configured properties. + * The input stream will be closed upon completion of this task, whether + * it was executed successfully or not. + * + * @param command Command to be executed + * @param istream InputStream to include in an HTTP PUT, if any + * @param contentType Content type to specify for the input, if any + * @param contentLength Content length to specify for the input, if any + * + * @exception BuildException if an error occurs + */ + public void execute(String command, InputStream istream, + String contentType, int contentLength) + throws BuildException { + + InputStreamReader reader = null; + try { + + HttpURLConnection hconn = send(command, istream, contentType, contentLength); + + // Process the response message + reader = new InputStreamReader(hconn.getInputStream(), "UTF-8"); + String error = null; + error = handleResult(reader, error); + if (error != null && isFailOnError()) { + // exception should be thrown only if failOnError == true + // or error line will be logged twice + throw new BuildException(error); + } + } catch (Throwable t) { + if (isFailOnError()) { + throw new BuildException(t); + } else { + handleErrorOutput(t.getMessage()); + } + } finally { + closeRedirector(); + if (reader != null) { + try { + reader.close(); + } catch (Throwable u) { + ; + } + reader = null; + } + if (istream != null) { + try { + istream.close(); + } catch (Throwable u) { + ; + } + istream = null; + } + } + + } + + private String handleResult(InputStreamReader reader, String error) throws IOException { + StringBuffer buff = new StringBuffer(); + int msgPriority = Project.MSG_INFO; + boolean first = true; + while (true) { + int ch = reader.read(); + if (ch < 0) { + break; + } else if ((ch == '\r') || (ch == '\n')) { + // in Win \r\n would cause handleOutput() to be called + // twice, the second time with an empty string, + // producing blank lines + if (buff.length() > 0) { + String line = buff.toString(); + buff.setLength(0); + if (first) { + if (!line.startsWith("Result: type=OK")) { + error = line; + msgPriority = Project.MSG_ERR; + } + first = false; + } + handleOutput(line, msgPriority); + } + } else { + buff.append((char) ch); + } + } + if (buff.length() > 0) { + handleOutput(buff.toString(), msgPriority); + } + return error; + } + + protected HttpURLConnection send(String command, InputStream istream, String contentType, int contentLength) throws IOException, MalformedURLException, ProtocolException { + URLConnection conn; + // Create a connection for this command + conn = (new URL(url + command)).openConnection(); + HttpURLConnection hconn = (HttpURLConnection) conn; + + // Set up standard connection characteristics + hconn.setAllowUserInteraction(false); + hconn.setDoInput(true); + hconn.setUseCaches(false); + if (istream != null) { + hconn.setDoOutput(true); + hconn.setRequestMethod("PUT"); + if (contentType != null) { + hconn.setRequestProperty("Content-Type", contentType); + } + if (contentLength >= 0) { + hconn.setRequestProperty("Content-Length", + "" + contentLength); + } + } else { + hconn.setDoOutput(false); + hconn.setRequestMethod("GET"); + } + hconn.setRequestProperty("User-Agent", + "JkStatus-Ant-Task/1.1"); + + // Set up an authorization header with our credentials + String input = username + ":" + password; + String output = new String(Base64.encode(input.getBytes())); + hconn.setRequestProperty("Authorization", + "Basic " + output); + + // Establish the connection with the server + hconn.connect(); + // Send the request data (if any) + if (istream != null) { + BufferedOutputStream ostream = + new BufferedOutputStream(hconn.getOutputStream(), 1024); + byte buffer[] = new byte[1024]; + while (true) { + int n = istream.read(buffer); + if (n < 0) { + break; + } + ostream.write(buffer, 0, n); + } + ostream.flush(); + ostream.close(); + istream.close(); + } + return hconn; + } + + +} diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkBalancer.java b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkBalancer.java new file mode 100644 index 00000000..f9e4f7ad --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkBalancer.java @@ -0,0 +1,335 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.jk.status; + +import java.io.Serializable; +import java.util.ArrayList; +import java.util.List; + +/** + * @author Peter Rossbach + * @version $Revision: 500555 $ $Date: 2007-01-27 16:59:41 +0100 (Sat, 27 Jan 2007) $ + * @see org.apache.jk.status.JkStatusParser + */ +public class JkBalancer implements Serializable { + + int id =-1; + String name ; + String type ; + boolean sticky ; + boolean stickyforce; + int retries ; + int recover ; + String method ; + String lock ; + int good = -1 ; + int degraded = -1; + int bad = -1 ; + int busy = -1; + int max_busy = -1 ; + int member_count = -1 ; + int map_count = -1 ; + int time_to_maintenance_min = -1 ; + int time_to_maintenance_max = -1 ; + + List members = new ArrayList() ; + List mappings = new ArrayList() ; + + /** + * @return Returns the id. + */ + public int getId() { + return id; + } + /** + * @param id The id to set. + */ + public void setId(int id) { + this.id = id; + } + /** + * @return Returns the mappings. + */ + public List getBalancerMappings() { + return mappings; + } + /** + * @param mappings The mappings to set. + */ + public void setBalancerMappings(List mappings) { + this.mappings = mappings; + } + public void addBalancerMapping(JkBalancerMapping mapping) { + mappings.add(mapping); + } + public void removeBalancerMapping(JkBalancerMapping mapping) { + mappings.remove(mapping); + } + /** + * @return Returns the members. + */ + public List getBalancerMembers() { + return members; + } + /** + * @param members The members to set. + */ + public void setBalancerMembers(List members) { + this.members = members; + } + public void addBalancerMember(JkBalancerMember member) { + members.add(member); + } + public void removeBalancerMember(JkBalancerMember member) { + members.remove(member); + } + /** + * @return Returns the name. + */ + public String getName() { + return name; + } + /** + * @param name The name to set. + */ + public void setName(String name) { + this.name = name; + } + /** + * @return Returns the recover. + */ + public int getRecover_time() { + return recover; + } + /** + * @param recover The recover to set. + */ + public void setRecover_time(int recover) { + this.recover = recover; + } + /** + * @return Returns the retries. + */ + public int getRetries() { + return retries; + } + /** + * @param retries The retries to set. + */ + public void setRetries(int retries) { + this.retries = retries; + } + /** + * @return Returns the sticky. + */ + public boolean isSticky_session() { + return sticky; + } + /** + * @param sticky The sticky to set. + */ + public void setSticky_session(boolean sticky) { + this.sticky = sticky; + } + /** + * @return Returns the stickyforce. + */ + public boolean isSticky_session_force() { + return stickyforce; + } + /** + * @param stickyforce The stickyforce to set. + */ + public void setSticky_session_force(boolean stickyforce) { + this.stickyforce = stickyforce; + } + /** + * @return Returns the type. + */ + public String getType() { + return type; + } + /** + * @param type The type to set. + */ + public void setType(String type) { + this.type = type; + } + /** + * @return the bad + * @since mod_jk 1.2.20 + */ + public int getBad() { + return bad; + } + /** + * @param bad the bad to set + * @since mod_jk 1.2.20 + */ + public void setBad(int bad) { + this.bad = bad; + } + /** + * @return the busy + * @since mod_jk 1.2.20 + */ + public int getBusy() { + return busy; + } + /** + * @param busy the busy to set + * @since mod_jk 1.2.20 + */ + public void setBusy(int busy) { + this.busy = busy; + } + /** + * @return the degraded + * @since mod_jk 1.2.20 + */ + public int getDegraded() { + return degraded; + } + /** + * @param degraded the degraded to set + * @since mod_jk 1.2.20 + */ + public void setDegraded(int degraded) { + this.degraded = degraded; + } + /** + * @return the good + * @since mod_jk 1.2.20 + */ + public int getGood() { + return good; + } + /** + * @param good the good to set + * @since mod_jk 1.2.20 + */ + public void setGood(int good) { + this.good = good; + } + /** + * @return the lock + * @since mod_jk 1.2.20 + */ + public String getLock() { + return lock; + } + /** + * @param lock the lock to set + * @since mod_jk 1.2.20 + */ + public void setLock(String lock) { + this.lock = lock; + } + /** + * @return the max_busy + * @since mod_jk 1.2.20 + */ + public int getMax_busy() { + return max_busy; + } + /** + * @param max_busy the max_busy to set + * @since mod_jk 1.2.20 + */ + public void setMax_busy(int max_busy) { + this.max_busy = max_busy; + } + /** + * @return the method + * @since mod_jk 1.2.20 + */ + public String getMethod() { + return method; + } + /** + * @param method the method to set + * @since mod_jk 1.2.20 + */ + public void setMethod(String method) { + this.method = method; + } + + /** + * @return the member_count + * @since mod_jk 1.2.20 + */ + public int getMember_count() { + return member_count; + } + + /** + * @param member_count the member_count to set + * @since mod_jk 1.2.20 + */ + public void setMember_count(int member_count) { + this.member_count = member_count; + } + + /** + * @return the map_count + * @since mod_jk 1.2.20 + */ + public int getMap_count() { + return map_count; + } + + /** + * @param map_count the map_count to set + * @since mod_jk 1.2.20 + */ + public void setMap_count(int map_count) { + this.map_count = map_count; + } + + /** + * @return the time_to_maintenance_min + * @since mod_jk 1.2.21 + */ + public int getTime_to_maintenance_min() { + return time_to_maintenance_min; + } + + /** + * @param time_to_maintenance_min the time_to_maintenance_min to set + * @since mod_jk 1.2.21 + */ + public void setTime_to_maintenance_min(int time_to_maintenance_min) { + this.time_to_maintenance_min = time_to_maintenance_min; + } + + /** + * @return the time_to_maintenance_max + * @since mod_jk 1.2.21 + */ + public int getTime_to_maintenance_max() { + return time_to_maintenance_max; + } + + /** + * @param time_to_maintenance_max the time_to_maintenance_max to set + * @since mod_jk 1.2.21 + */ + public void setTime_to_maintenance_max(int time_to_maintenance_max) { + this.time_to_maintenance_max = time_to_maintenance_max; + } + +} diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkBalancerMapping.java b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkBalancerMapping.java new file mode 100644 index 00000000..5d4ef836 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkBalancerMapping.java @@ -0,0 +1,98 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.jk.status; + +import java.io.Serializable; + +/** + * @author Peter Rossbach + * @version $Revision: 485242 $ $Date: 2006-12-10 20:45:39 +0100 (Sun, 10 Dec 2006) $ + * @see org.apache.jk.status.JkStatusParser + */ +public class JkBalancerMapping implements Serializable { + int id =-1 ; + String type ; + String uri; + String context ; + String source ; + + /** + * @return the id + */ + public int getId() { + return id; + } + /** + * @param id the id to set + */ + public void setId(int id) { + this.id = id; + } + /** + * @return Returns the context. + * @deprecated mod_jk 1.2.20 + */ + public String getContext() { + return context; + } + /** + * @param context The context to set. + * @deprecated mod_jk 1.2.20 + */ + public void setContext(String context) { + this.context = context; + } + /** + * @return Returns the type. + */ + public String getType() { + return type; + } + /** + * @param type The type to set. + */ + public void setType(String type) { + this.type = type; + } + /** + * @return Returns the uri. + */ + public String getUri() { + return uri; + } + /** + * @param uri The uri to set. + */ + public void setUri(String uri) { + this.uri = uri; + } + /** + * @return the source + * @since mod_jk 1.2.20 + */ + public String getSource() { + return source; + } + /** + * @param source the source to set + * @since mod_jk 1.2.20 + */ + public void setSource(String source) { + this.source = source; + } + + } diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkBalancerMember.java b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkBalancerMember.java new file mode 100644 index 00000000..6e884477 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkBalancerMember.java @@ -0,0 +1,516 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.jk.status; + +import java.io.Serializable; + +/** + * @author Peter Rossbach + * @version $Revision: 500550 $ $Date: 2007-01-27 16:41:36 +0100 (Sat, 27 Jan 2007) $ + * @see org.apache.jk.status.JkStatusParser + */ +/** + * @author peter + * + */ +public class JkBalancerMember implements Serializable { + + int id = -1; + + String name; + + /* possible with >= 1.2.16 */ + String jvm_route; + + /* possible with >= 1.2.20 */ + String route; + + String type; + + String host; + + int port; + + String address; + + /* deprecated with mod_jk 1.2.16*/ + String status; + + /* possible with > 1.2.16 */ + String activation; + + /* possible with > 1.2.16 */ + String state; + + int lbfactor; + + long lbvalue; + + /* possible with > 1.2.16 */ + long lbmult = -1 ; + + int elected; + + long readed; + + long transferred; + + long errors; + + long clienterrors = -1; + + int busy; + + /* possible with > 1.2.16 */ + int maxbusy = -1; + + String redirect; + + String domain; + + /* possible with > 1.2.16 */ + int distance = -1; + + /* possible with > 1.2.20 */ + int time_to_recover = -1 ; + + /* possible with > 1.2.21 */ + int time_to_recover_max = -1 ; + + /* possible with > 1.2.21 */ + int time_to_recover_min = -1 ; + + /** + * @return Returns the jvm_route. + * @since mod_jk 1.2.16 + * @deprecated + */ + public String getJvm_route() { + return jvm_route; + } + + /** + * @param jvm_route The jvm_route to set. + * @since mod_jk 1.2.16 + * @deprecated + */ + public void setJvm_route(String jvm_route) { + this.jvm_route = jvm_route; + } + + /** + * @return the route + * @since mod_jk 1.2.20 + */ + public String getRoute() { + return route; + } + + /** + * @param route the route to set + * @since mod_jk 1.2.20 + */ + public void setRoute(String route) { + this.route = route; + } + + /** + * @return Returns the address. + */ + public String getAddress() { + return address; + } + + /** + * @param address + * The address to set. + */ + public void setAddress(String address) { + this.address = address; + } + + /** + * @return Returns the busy. + */ + public int getBusy() { + return busy; + } + + /** + * @param busy + * The busy to set. + */ + public void setBusy(int busy) { + this.busy = busy; + } + + + /** + * @return Returns the maxbusy. + * @since mod_jk 1.2.18 + */ + public int getMax_busy() { + return maxbusy; + } + + /** + * @param maxbusy The maxbusy to set. + * @since mod_jk 1.2.18 + */ + public void setMax_busy(int maxbusy) { + this.maxbusy = maxbusy; + } + + /** + * @return Returns the elected. + */ + public int getElected() { + return elected; + } + + /** + * @param elected + * The elected to set. + */ + public void setElected(int elected) { + this.elected = elected; + } + + /** + * @return Returns the clienterrors. + * @since mod_jk 1.2.19 + */ + public long getClient_errors() { + return clienterrors; + } + + /** + * @param clienterrors The clienterrors to set. + * @since mod_jk 1.2.19 + */ + public void setClient_errors(long clienterrors) { + this.clienterrors = clienterrors; + } + + /** + * @return Returns the errors. + */ + public long getErrors() { + return errors; + } + + /** + * @param errors + * The errors to set. + */ + public void setErrors(long errors) { + this.errors = errors; + } + + /** + * @return Returns the host. + */ + public String getHost() { + return host; + } + + /** + * @param host + * The host to set. + */ + public void setHost(String host) { + this.host = host; + } + + /** + * @return Returns the id. + */ + public int getId() { + return id; + } + + /** + * @param id + * The id to set. + */ + public void setId(int id) { + this.id = id; + } + + /** + * @return Returns the lbfactor. + */ + public int getLbfactor() { + return lbfactor; + } + + /** + * @param lbfactor + * The lbfactor to set. + */ + public void setLbfactor(int lbfactor) { + this.lbfactor = lbfactor; + } + + /** + * @return Returns the lbvalue. + */ + public long getLbvalue() { + return lbvalue; + } + + /** + * @param lbvalue + * The lbvalue to set. + */ + public void setLbvalue(long lbvalue) { + this.lbvalue = lbvalue; + } + + /** + * @return Returns the lbmult. + * @since mod_jk 1.2.19 + */ + public long getLbmult() { + return lbmult; + } + + /** + * @param lbmult The lbmult to set. + * @since mod_jk 1.2.19 + */ + public void setLbmult(long lbmult) { + this.lbmult = lbmult; + } + + /** + * @return Returns the name. + */ + public String getName() { + return name; + } + + /** + * @param name + * The name to set. + */ + public void setName(String name) { + this.name = name; + } + + + /** + * @return Returns the port. + */ + public int getPort() { + return port; + } + + /** + * @param port + * The port to set. + */ + public void setPort(int port) { + this.port = port; + } + + /** + * @return Returns the readed. + */ + public long getReaded() { + return readed; + } + + /** + * @param readed + * The readed to set. + */ + public void setReaded(long readed) { + this.readed = readed; + } + + /** + * @return Returns the status. + * @deprecated since 1.2.16 + */ + public String getStatus() { + return status; + } + + /** + * @param status + * The status to set. + * @deprecated since 1.2.16 + */ + public void setStatus(String status) { + this.status = status; + } + + /** + * @return Returns the activation. + * @since mod_jk 1.2.19 + */ + public String getActivation() { + return activation; + } + + /** + * @param activation The activation to set. + * @since mod_jk 1.2.19 + */ + public void setActivation(String activation) { + this.activation = activation; + } + + /** + * @return Returns the state. + * @since mod_jk 1.2.19 + */ + public String getState() { + return state; + } + + /** + * @param state The state to set. + * @since mod_jk 1.2.19 + */ + public void setState(String state) { + this.state = state; + } + + /** + * @return Returns the transferred. + */ + public long getTransferred() { + return transferred; + } + + /** + * @param transferred + * The transferred to set. + */ + public void setTransferred(long transferred) { + this.transferred = transferred; + } + + /** + * @return Returns the type. + */ + public String getType() { + return type; + } + + /** + * @param type + * The type to set. + */ + public void setType(String type) { + this.type = type; + } + + + /** + * @return Returns the domain. + */ + public String getDomain() { + return domain; + } + /** + * @param domain The domain to set. + */ + public void setDomain(String domain) { + this.domain = domain; + } + + /** + * @return Returns the redirect. + */ + public String getRedirect() { + return redirect; + } + /** + * @param redirect The redirect to set. + */ + public void setRedirect(String redirect) { + this.redirect = redirect; + } + + /** + * @return Returns the distance. + * @since mod_jk 1.2.18 + */ + public int getDistance() { + return distance; + } + + /** + * @param distance The distance to set. + * @since mod_jk 1.2.18 + */ + public void setDistance(int distance) { + this.distance = distance; + } + + /** + * @return the time_to_recover + * @since mod_jk 1.2.20 + */ + public int getTime_to_recover() { + return time_to_recover; + } + + /** + * @param time_to_recover the time_to_recover to set + * @since mod_jk 1.2.20 + */ + public void setTime_to_recover(int time_to_recover) { + this.time_to_recover = time_to_recover; + } + + /** + * @return the time_to_recover_min + * @since mod_jk 1.2.21 + */ + public int getTime_to_recover_min() { + return time_to_recover_min; + } + + /** + * @param time_to_recover_min the time_to_recover_min to set + * @since mod_jk 1.2.21 + */ + public void setTime_to_recover_min(int time_to_recover_min) { + this.time_to_recover_min = time_to_recover_min; + } + + /** + * @return the time_to_recover_max + * @since mod_jk 1.2.21 + */ + public int getTime_to_recover_max() { + return time_to_recover_max; + } + + /** + * @param time_to_recover_max the time_to_recover_max to set + * @since mod_jk 1.2.21 + */ + public void setTime_to_recover_max(int time_to_recover_max) { + this.time_to_recover_max = time_to_recover_max; + } + +} diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkResult.java b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkResult.java new file mode 100644 index 00000000..63c39d7f --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkResult.java @@ -0,0 +1,54 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.jk.status; + +import java.io.Serializable; + +/** + * @author Peter Rossbach + * @version $Revision: 802231 $ $Date: 2009-08-07 23:43:52 +0200 (Fri, 07 Aug 2009) $ + * @see org.apache.jk.status.JkStatusParser + */ +public class JkResult implements Serializable { + String type ; + String message; + /** + * @return the message + */ + public String getMessage() { + return message; + } + /** + * @param message the message to set + */ + public void setMessage(String message) { + this.message = message; + } + /** + * @return the type + */ + public String getType() { + return type; + } + /** + * @param type the type to set + */ + public void setType(String type) { + this.type = type; + } + +} diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkServer.java b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkServer.java new file mode 100644 index 00000000..88bc9ce6 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkServer.java @@ -0,0 +1,56 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.jk.status; + +import java.io.Serializable; + +/** + * @author Peter Rossbach + * @version $Revision: 485242 $ $Date: 2006-12-10 20:45:39 +0100 (Sun, 10 Dec 2006) $ + * @see org.apache.jk.status.JkStatusParser + */ +public class JkServer implements Serializable { + String name ; + String port; + + /** + * @return Returns the name. + */ + public String getName() { + return name; + } + /** + * @param name The name to set. + */ + public void setName(String name) { + this.name = name; + } + /** + * @return Returns the port. + */ + public String getPort() { + return port; + } + /** + * @param port The port to set. + */ + public void setPort(String port) { + this.port = port; + } + + +} diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkSoftware.java b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkSoftware.java new file mode 100644 index 00000000..da220b06 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkSoftware.java @@ -0,0 +1,54 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.jk.status; + +import java.io.Serializable; + +/** + * @author Peter Rossbach + * @version $Revision: 802231 $ $Date: 2009-08-07 23:43:52 +0200 (Fri, 07 Aug 2009) $ + * @see org.apache.jk.status.JkStatusParser + */ +public class JkSoftware implements Serializable { + String web_server; + String jk_version ; + + /** + * @return Returns the software. + */ + public String getWeb_server() { + return web_server; + } + /** + * @param software The software to set. + */ + public void setWeb_server(String software) { + this.web_server = software; + } + /** + * @return Returns the version. + */ + public String getJk_version() { + return jk_version; + } + /** + * @param version The version to set. + */ + public void setJk_version(String version) { + this.jk_version = version; + } +} diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkStatus.java b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkStatus.java new file mode 100644 index 00000000..df51ed1a --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkStatus.java @@ -0,0 +1,90 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.jk.status; + +import java.io.Serializable; +import java.util.ArrayList; +import java.util.List; + +/** + * @author Peter Rossbach + * @version $Revision: 485242 $ $Date: 2006-12-10 20:45:39 +0100 (Sun, 10 Dec 2006) $ + * @see org.apache.jk.status.JkStatusParser + */ +public class JkStatus implements Serializable { + + JkServer server ; + JkSoftware software ; + JkResult result ; + List balancers = new ArrayList() ; + + /** + * @return Returns the balancers. + */ + public List getBalancers() { + return balancers; + } + /** + * @param balancers The balancers to set. + */ + public void setBalancers(List balancers) { + this.balancers = balancers; + } + + public void addBalancer(JkBalancer balancer) { + balancers.add(balancer); + } + + public void removeBalancer(JkBalancer balancer) { + balancers.remove(balancer); + } + + /** + * @return Returns the server. + */ + public JkServer getServer() { + return server; + } + public void setServer(JkServer server) { + this.server = server ; + } + /** + * @return the result + */ + public JkResult getResult() { + return result; + } + /** + * @param result the result to set + */ + public void setResult(JkResult result) { + this.result = result; + } + + /** + * @return Returns the software. + */ + public JkSoftware getSoftware() { + return software; + } + /** + * @param software The software to set. + */ + public void setSoftware(JkSoftware software) { + this.software = software; + } +} diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkStatusAccessor.java b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkStatusAccessor.java new file mode 100644 index 00000000..e884f542 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkStatusAccessor.java @@ -0,0 +1,133 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.jk.status; + +import java.io.IOException; +import java.net.HttpURLConnection; +import java.net.MalformedURLException; +import java.net.ProtocolException; +import java.net.URL; +import java.net.URLConnection; + +import org.apache.catalina.util.Base64; +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; +import org.apache.tomcat.util.digester.Digester; + +/** + * Create connection to mod_jk jkstatus page. + * Optional you can use Http basic auth user and password. + * @author Peter Rossbach + * @version $Revision: 485242 $ $Date: 2006-12-10 20:45:39 +0100 (Sun, 10 Dec 2006) $ + * @see org.apache.jk.status.JkStatusParser + * @since 5.5.10 + */ +public class JkStatusAccessor { + + private static Log log = LogFactory.getLog(JkStatusAccessor.class); + /** + * The descriptive information about this implementation. + */ + protected static final String info = "org.apache.jk.status.JkStatusAccessor/1.0"; + + /** + * Parse Apache mod_jk Status from base url http://host:port/jkstatus) + * @param url + * @param username + * @param password + * + */ + public JkStatus status(String url, String username, String password) + throws Exception { + + if(url == null || "".equals(url)) + return null ; + HttpURLConnection hconn = null; + JkStatus status = null; + + try { + // FIXME: use cmd show for older mod_jk versions + hconn = openConnection(url + "?cmd=list&mime=xml", username, password); + Digester digester = JkStatusParser.getDigester(); + synchronized (digester) { + status = (JkStatus) digester.parse(hconn.getInputStream()); + } + } catch (Throwable t) { + throw new Exception(t); + } finally { + if (hconn != null) { + try { + hconn.disconnect(); + } catch (Throwable u) { + ; + } + hconn = null; + } + } + return status; + } + + /** + * Create a auth http connection for this url + * + * @param url + * @param username + * @param password + * @return HttpConnection + * @throws IOException + * @throws MalformedURLException + * @throws ProtocolException + */ + protected HttpURLConnection openConnection(String url, String username, + String password) throws IOException, MalformedURLException, + ProtocolException { + URLConnection conn; + conn = (new URL(url)).openConnection(); + HttpURLConnection hconn = (HttpURLConnection) conn; + + // Set up standard connection characteristics + hconn.setAllowUserInteraction(false); + hconn.setDoInput(true); + hconn.setUseCaches(false); + hconn.setDoOutput(false); + hconn.setRequestMethod("GET"); + hconn.setRequestProperty("User-Agent", "JkStatus-Client/1.0"); + + if(username != null && password != null ) { + setAuthHeader(hconn, username, password); + } + // Establish the connection with the server + hconn.connect(); + return hconn; + } + + /** + * Set Basic Auth Header + * + * @param hconn + * @param username + * @param password + */ + protected void setAuthHeader(HttpURLConnection hconn, String username, + String password) { + // Set up an authorization header with our credentials + String input = username + ":" + password; + String output = new String(Base64.encode(input.getBytes())); + hconn.setRequestProperty("Authorization", "Basic " + output); + } + +} \ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkStatusParser.java b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkStatusParser.java new file mode 100644 index 00000000..87595d99 --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkStatusParser.java @@ -0,0 +1,228 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.jk.status; + +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; +import org.apache.tomcat.util.digester.Digester; + +/** + * mod_jk 1.2.19 document:
+ * + * + * <?xml version="1.0" encoding="UTF-8" ?> + * <jk:status xmlns:jk="http://tomcat.apache.org"> + * <jk:server name="localhost" port="2010" software="Apache/2.0.58 (Unix) mod_jk/1.2.19-dev" version="1.2.19" /> + * <jk:balancers> + * <jk:balancer id="0" name="loadbalancer" type="lb" sticky="True" stickyforce="False" retries="2" recover="60" > + * <jk:member id="0" name="node01" type="ajp13" host="localhost" port="20012" address="127.0.0.1:20012" activation="ACT" state="N/A" distance="0" lbfactor="1" lbmult="1" lbvalue="0" elected="0" errors="0" transferred="0" readed="0" busy="0" maxbusy="0" jvm_route="node01" /> + * <jk:member id="1" name="node02" type="ajp13" host="localhost" port="20022" address="127.0.0.1:20022" activation="ACT" state="N/A" distance="0" lbfactor="1" lbmult="1" lbvalue="0" elected="0" errors="0" transferred="0" readed="0" busy="0" maxbusy="0" jvm_route="node02" /> + * <jk:map type="Wildchar" uri="/ClusterSession*" context="/ClusterSession*" /> + * <jk:map type="Wildchar" uri="/ClusterTest*" context="/ClusterTest*" /> + * <jk:map type="Wildchar" uri="/test*" context="/test*" /> + * </jk:balancer> + * </jk:balancers> + * </jk:status> + * + *
+ * mod_jk 1.2.20 document:
+ * + * <?xml version="1.0" encoding="UTF-8" ?> + * <jk:status xmlns:jk="http://tomcat.apache.org"> + * <jk:server + * name="127.0.0.1" + * port="2080" + * software="Apache/2.0.59 (Unix) mod_jk/1.2.20-dev" + * version="1.2.20"/> + * <jk:balancers> + * <jk:balancer + * name="loadbalancer" + * type="lb" + * sticky="True" + * stickyforce="False" + * retries="2" + * recover="60" + * method="Request" + * lock="Optimistic" + * good="2" + * degraded="0" + * bad="0" + * busy="0" + * max_busy="0"> + * <jk:member + * name="node01" + * type="ajp13" + * host="localhost" + * port="7309" + * address="127.0.0.1:7309" + * activation="ACT" + * lbfactor="1" + * jvm_route="node01" + * redirect="" + * domain="" + * distance="0" + * state="N/A" + * lbmult="1" + * lbvalue="0" + * elected="0" + * errors="0" + * clienterrors="0" + * transferred="0" + * readed="0" + * busy="0" + * maxbusy="0" + * time-to-recover="0"/> + * <jk:member + * name="node02" + * type="ajp13" + * host="localhost" + * port="7409" + * address="127.0.0.1:7409" + * activation="ACT" + * lbfactor="1" + * jvm_route="node02" + * redirect="" + * domain="" + * distance="0" + * state="N/A" + * lbmult="1" + * lbvalue="0" + * elected="0" + * errors="0" + * clienterrors="0" + * transferred="0" + * readed="0" + * busy="0" + * maxbusy="0" + * time-to-recover="0"/> + * <jk:map + * type="Wildchar" + * uri="/ClusterTest*" + * source="JkMount"/> + * <jk:map + * type="Wildchar" + * uri="/myapps*" + * source="JkMount"/> + * <jk:map + * type="Wildchar" + * uri="/last*" + * source="JkMount"/> + * </jk:balancer> + * </jk:balancers> + * </jk:status> + * + * + * + *
+ * mod_jk 1.2.24 runtime state N/A changed to OK/IDLE:
+ * + * state="OK/IDLE" + * + * @author Peter Rossbach + * @version $Revision: 753168 $ $Date: 2009-03-13 09:46:29 +0100 (Fri, 13 Mar 2009) $ + * @since 5.5.10 + */ +public class JkStatusParser { + private static Log log = LogFactory.getLog(JkStatusParser.class); + + /** + * The descriptive information about this implementation. + */ + private static final String info = "org.apache.jk.status.JkStatusParser/1.1"; + + /** + * Return descriptive information about this implementation and the + * corresponding version number, in the format + * <description>/<version>. + */ + public String getInfo() { + + return (info); + + } + + /** + * The Digester instance used to parse registry descriptors. + */ + public static final Digester digester = createDigester(); + + public static Digester getDigester() { + return digester; + } + + /** + * Create and configure the Digester we will be using for setup mod_jk jk status page. + */ + public static Digester createDigester() { + long t1 = System.currentTimeMillis(); + // Initialize the digester + Digester digester = new Digester(); + digester.setValidating(false); + digester.setClassLoader(JkStatus.class.getClassLoader()); + + // parse status + digester.addObjectCreate("jk:status", "org.apache.jk.status.JkStatus", + "className"); + digester.addSetProperties("jk:status"); + + digester.addObjectCreate("jk:status/jk:server", + "org.apache.jk.status.JkServer", "className"); + digester.addSetProperties("jk:status/jk:server"); + digester.addSetNext("jk:status/jk:server", "setServer", + "org.apache.jk.status.JkServer"); + + digester.addObjectCreate("jk:status/jk:software", + "org.apache.jk.status.JkSoftware", "className"); + digester.addSetProperties("jk:status/jk:software"); + digester.addSetNext("jk:status/jk:software", "setSoftware", + "org.apache.jk.status.JkSoftware"); + + digester.addObjectCreate("jk:status/jk:result", + "org.apache.jk.status.JkResult", "className"); + digester.addSetProperties("jk:status/jk:result"); + digester.addSetNext("jk:status/jk:result", "setResult", + "org.apache.jk.status.JkResult"); + + digester.addObjectCreate("jk:status/jk:balancers/jk:balancer", + "org.apache.jk.status.JkBalancer", "className"); + digester.addSetProperties("jk:status/jk:balancers/jk:balancer"); + digester.addSetNext("jk:status/jk:balancers/jk:balancer", + "addBalancer", "org.apache.jk.status.JkBalancer"); + + digester.addObjectCreate( + "jk:status/jk:balancers/jk:balancer/jk:member", + "org.apache.jk.status.JkBalancerMember", "className"); + digester + .addSetProperties("jk:status/jk:balancers/jk:balancer/jk:member"); + digester.addSetNext("jk:status/jk:balancers/jk:balancer/jk:member", + "addBalancerMember", "org.apache.jk.status.JkBalancerMember"); + + digester.addObjectCreate("jk:status/jk:balancers/jk:balancer/jk:map", + "org.apache.jk.status.JkBalancerMapping", "className"); + digester.addSetProperties("jk:status/jk:balancers/jk:balancer/jk:map"); + digester.addSetNext("jk:status/jk:balancers/jk:balancer/jk:map", + "addBalancerMapping", "org.apache.jk.status.JkBalancerMapping"); + + long t2 = System.currentTimeMillis(); + if (log.isDebugEnabled()) + log.debug("Digester for apache mod_jk jkstatus page is created " + + (t2 - t1)); + return (digester); + + } + +} diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkStatusResetTask.java b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkStatusResetTask.java new file mode 100644 index 00000000..703f04bf --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkStatusResetTask.java @@ -0,0 +1,133 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.jk.status; + +import java.io.UnsupportedEncodingException; +import java.net.URLEncoder; + +import org.apache.tools.ant.BuildException; + +/** + * Ant task that implements the /jkstatus?cmd=reset&w=loadbalancer command, supported by the + * mod_jk status (1.2.20) application. + * + * @author Peter Rossbach + * @version $Revision: 485242 $ + * @since mod_jk 1.2.20 + */ +public class JkStatusResetTask extends AbstractJkStatusTask { + + /** + * The descriptive information about this implementation. + */ + private static final String info = "org.apache.jk.status.JkStatusResetTask/1.1"; + + private String worker; + private String loadbalancer; + + /** + * + */ + public JkStatusResetTask() { + super(); + setUrl("http://localhost/jkstatus"); + } + + /** + * Return descriptive information about this implementation and the + * corresponding version number, in the format + * <description>/<version>. + */ + public String getInfo() { + + return (info); + + } + + /** + * @return the loadbalancer + */ + public String getLoadbalancer() { + return loadbalancer; + } + + + /** + * @param loadbalancer the loadbalancer to set + */ + public void setLoadbalancer(String loadbalancer) { + this.loadbalancer = loadbalancer; + } + + + /** + * @return the worker + */ + public String getWorker() { + return worker; + } + + + /** + * @param worker the worker to set + */ + public void setWorker(String worker) { + this.worker = worker; + } + + + /** + * Create jkstatus reset link + *
    + *
  • loadbalancer example: + * http://localhost/jkstatus?cmd=reset&mime=txt&w=loadbalancer
  • + *
  • loadbalancer + sub worker example: + * http://localhost/jkstatus?cmd=reset&mime=txt&w=loadbalancer&sw=node01
  • + *
+ * + * @return create jkstatus reset link + */ + protected StringBuffer createLink() { + // Building URL + StringBuffer sb = new StringBuffer(); + try { + sb.append("?cmd=reset"); + sb.append("&mime=txt"); + sb.append("&w="); + sb.append(URLEncoder.encode(loadbalancer, getCharset())); + if(worker != null) { + sb.append("&sw="); + sb.append(URLEncoder.encode(worker, getCharset())); + } + + } catch (UnsupportedEncodingException e) { + throw new BuildException("Invalid 'charset' attribute: " + + getCharset()); + } + return sb; + } + + /** + * check correct pararmeter + */ + protected void checkParameter() { + if (loadbalancer == null) { + throw new BuildException("Must specify 'loadbalanacer' attribute"); + } + } +} \ No newline at end of file diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkStatusTask.java b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkStatusTask.java new file mode 100644 index 00000000..73d11eab --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkStatusTask.java @@ -0,0 +1,735 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.jk.status; + +import java.util.Iterator; +import java.util.List; + +import org.apache.catalina.ant.BaseRedirectorHelperTask; +import org.apache.tomcat.util.IntrospectionUtils; +import org.apache.tools.ant.BuildException; +import org.apache.tools.ant.Project; + +/** + * Ant task that implements the show /jkstatus command, supported + * by the mod_jk status (1.2.13) application. + * + * @author Peter Rossbach + * @version $Revision: 752644 $ + * @since 5.5.10 + */ +public class JkStatusTask extends BaseRedirectorHelperTask { + + /** + * The descriptive information about this implementation. + */ + private static final String info = "org.apache.jk.status.JkStatusTask/1.2"; + + /** + * Store status as resultProperty prefix. + */ + protected String resultproperty; + + /** + * Echo status at ant console + */ + protected boolean echo = false; + + /** + * The login password for the mod_jk status page. + */ + protected String password = null; + + /** + * The URL of the mod_jk status page to be used. + */ + protected String url = "http://localhost:80/jkstatus"; + + /** + * The login username for the mod_jk status page. + */ + protected String username = null; + + private String errorProperty; + + private String worker; + + private String loadbalancer; + + /** + * Return descriptive information about this implementation and the + * corresponding version number, in the format + * <description>/<version>. + */ + public String getInfo() { + + return (info); + + } + + public String getPassword() { + return (this.password); + } + + public void setPassword(String password) { + this.password = password; + } + + public String getUrl() { + return (this.url); + } + + public void setUrl(String url) { + this.url = url; + } + + public String getUsername() { + return (this.username); + } + + public void setUsername(String username) { + this.username = username; + } + + /** + * @return Returns the echo. + */ + public boolean isEcho() { + return echo; + } + + /** + * @param echo + * The echo to set. + */ + public void setEcho(boolean echo) { + this.echo = echo; + } + + /** + * @return Returns the resultproperty. + */ + public String getResultproperty() { + return resultproperty; + } + + /** + * @param resultproperty + * The resultproperty to set. + */ + public void setResultproperty(String resultproperty) { + this.resultproperty = resultproperty; + } + + /** + * @return Returns the loadbalancer. + */ + public String getLoadbalancer() { + return loadbalancer; + } + /** + * @param loadbalancer The loadbalancer to set. + */ + public void setLoadbalancer(String loadbalancer) { + this.loadbalancer = loadbalancer; + } + /** + * @return Returns the worker. + */ + public String getWorker() { + return worker; + } + /** + * @param worker The worker to set. + */ + public void setWorker(String worker) { + this.worker = worker; + } + // --------------------------------------------------------- Public Methods + + /** + * Get jkstatus from server. + * + * @exception BuildException + * if a validation error occurs + */ + public void execute() throws BuildException { + + if (url == null) { + throw new BuildException("Must specify an 'url'"); + } + boolean isWorkerOnly = worker != null && !"".equals(worker); + boolean isLoadbalancerOnly = loadbalancer != null + && !"".equals(loadbalancer); + + StringBuffer error = new StringBuffer(); + try { + JkStatusAccessor accessor = new JkStatusAccessor(); + JkStatus status = accessor.status(url, username, password); + if (status.result != null && !"OK".equals(status.result.type) ) { + if (getErrorProperty() != null) { + getProject().setNewProperty(errorProperty, status.result.message); + } + if (isFailOnError()) { + throw new BuildException(status.result.message); + } else { + handleErrorOutput(status.result.message); + return; + } + + } + + if (!isWorkerOnly && !isLoadbalancerOnly) { + JkServer server = status.getServer(); + JkSoftware software = status.getSoftware(); + JkResult result = status.getResult(); + if (resultproperty != null) { + createProperty(server, "server", "name"); + createProperty(server, "server", "port"); + createProperty(software, "web_server"); + createProperty(software, "jk_version"); + createProperty(result, "result", "type"); + createProperty(result, "result", "message"); + } + if (isEcho()) { + handleOutput("server name=" + server.getName() + ":" + + server.getPort() + " - " + software.getWeb_server() + " - " + software.getJk_version()); + } + } + List balancers = status.getBalancers(); + for (Iterator iter = balancers.iterator(); iter.hasNext();) { + JkBalancer balancer = (JkBalancer) iter.next(); + String balancerIndex = null; + if (isLoadbalancerOnly) { + if (loadbalancer.equals(balancer.getName())) { + if (resultproperty != null) { + setPropertyBalancerOnly(balancer); + } + echoBalancer(balancer); + return; + } + } else { + if (!isWorkerOnly) { + if (resultproperty != null) { + if ( balancer.getId() >= 0) + balancerIndex = Integer.toString(balancer.getId()); + else + balancerIndex = balancer.getName() ; + + setPropertyBalancer(balancer,balancerIndex); + } + echoBalancer(balancer); + } + List members = balancer.getBalancerMembers(); + for (Iterator iterator = members.iterator(); iterator + .hasNext();) { + JkBalancerMember member = (JkBalancerMember) iterator + .next(); + if (isWorkerOnly) { + if (worker.equals(member.getName())) { + if (resultproperty != null) { + setPropertyWorkerOnly(balancer, member); + } + echoWorker(member); + return; + } + } else { + if (resultproperty != null) { + setPropertyWorker(null, member); + } + echoWorker(member); + if (member.getStatus() != null && !"OK".equals(member.getStatus())) { + error.append(" worker name=" + member.getName() + + " status=" + member.getStatus() + + " host=" + member.getAddress()); + } + if (member.getState() != null && + !("OK".equals(member.getState()) || + "N/A".equals(member.getState()) || + "OK/IDLE".equals(member.getState())) ){ + error.append(" worker name=" + member.getName() + + " state=" + member.getState() + + " host=" + member.getAddress()); + } + } + } + if (!isWorkerOnly) { + if (resultproperty != null && members.size() > 0) { + getProject().setNewProperty( + resultproperty + "." + + balancer.getName() + ".length", + Integer.toString(members.size())); + } + List mappings = balancer.getBalancerMappings(); + int j = 0; + String mapIndex ; + if( balancerIndex != null ) + mapIndex = balancerIndex + ".map" ; + else + mapIndex = "map" ; + for (Iterator iterator = mappings.iterator(); iterator + .hasNext(); j++) { + JkBalancerMapping mapping = (JkBalancerMapping) iterator + .next(); + if (resultproperty != null) { + String stringIndex2 ; + if( mapping.getId() >= 0) { + stringIndex2 = Integer.toString(mapping.getId()) ; + } else { + stringIndex2 = Integer.toString(j); + } + createProperty(mapping, mapIndex, + stringIndex2, "type"); + createProperty(mapping, mapIndex, + stringIndex2, "uri"); + createProperty(mapping, mapIndex, + stringIndex2, "context"); + createProperty(mapping, mapIndex, + stringIndex2, "source"); + } + if (isEcho()) { + String mappingOut ; + + if(mapping.source != null) { + mappingOut = + "balancer name=" + + balancer.getName() + " mappingtype=" + + mapping.getType() + " uri=" + + mapping.getUri() + " source=" + + mapping.getSource() ; + } else { + mappingOut = "balancer name=" + + balancer.getName() + " mappingtype=" + + mapping.getType() + " uri=" + + mapping.getUri() + " context=" + + mapping.getContext() ; + } + handleOutput(mappingOut); + } + } + if (resultproperty != null && mappings.size() > 0) { + getProject().setNewProperty( + resultproperty + "." + + mapIndex + ".length", + Integer.toString(mappings.size())); + } + } + } + } + if (!isWorkerOnly && !isLoadbalancerOnly) { + if (resultproperty != null && balancers.size() > 0) { + getProject().setNewProperty( + resultproperty + ".length", + Integer.toString(balancers.size())); + } + } + } catch (Throwable t) { + error.append(t.getMessage()); + if (getErrorProperty() != null) { + getProject().setNewProperty(errorProperty, error.toString()); + } + if (isFailOnError()) { + throw new BuildException(t); + } else { + handleErrorOutput(t.getMessage()); + return; + } + } + if (error.length() != 0) { + if (getErrorProperty() != null) { + getProject().setNewProperty(errorProperty, error.toString()); + } + if (isFailOnError()) { + // exception should be thrown only if failOnError == true + // or error line will be logged twice + throw new BuildException(error.toString()); + } + } + + } + + /** + * @param member + */ + private void echoWorker(JkBalancerMember member) { + if (isEcho()) { + StringBuffer state = new StringBuffer("worker name=") ; + state.append( member.getName()) ; + if(member.getStatus() != null) { + state.append(" status="); + state.append(member.getStatus()); + } + if(member.getState() != null) { + state.append(" state="); + state.append(member.getState()) ; + } + state.append(" host="); + state.append(member.getAddress()); + handleOutput(state.toString()); + } + } + + /** + * @param balancer + */ + private void echoBalancer(JkBalancer balancer) { + if (isEcho()) { + handleOutput("balancer name=" + balancer.getName() + " type=" + + balancer.getType()); + } + } + + /** + * @param balancer + */ + private void setPropertyBalancerOnly(JkBalancer balancer) { + String prefix = resultproperty + "." + balancer.getName(); + if(balancer.getId() >= 0 ) { + getProject().setNewProperty(prefix + ".id", + Integer.toString(balancer.getId())); + } + getProject().setNewProperty(prefix + ".type", balancer.getType()); + getProject().setNewProperty(prefix + ".stick_session", + Boolean.toString(balancer.isSticky_session())); + getProject().setNewProperty(prefix + ".sticky_session_force", + Boolean.toString(balancer.isSticky_session_force())); + getProject().setNewProperty(prefix + ".retries", + Integer.toString(balancer.getRetries())); + getProject().setNewProperty(prefix + ".recover_time", + Integer.toString(balancer.getRecover_time())); + getProject().setNewProperty(prefix + ".method", + balancer.getMethod()); + getProject().setNewProperty(prefix + ".good", + Integer.toString(balancer.getGood())); + getProject().setNewProperty(prefix + ".degraded", + Integer.toString(balancer.getDegraded())); + getProject().setNewProperty(prefix + ".bad", + Integer.toString(balancer.getBad())); + getProject().setNewProperty(prefix + ".busy", + Integer.toString(balancer.getBusy())); + getProject().setNewProperty(prefix + ".map_count", + Integer.toString(balancer.getMap_count())); + getProject().setNewProperty(prefix + ".member_count", + Integer.toString(balancer.getMember_count())); + getProject().setNewProperty(prefix + ".max_busy", + Integer.toString(balancer.getMax_busy())); + getProject().setNewProperty(prefix + ".time_to_maintenance_min", + Integer.toString(balancer.getTime_to_maintenance_min())); + getProject().setNewProperty(prefix + ".time_to_maintenance_max", + Integer.toString(balancer.getTime_to_maintenance_max())); + getProject().setNewProperty(prefix + ".lock", + balancer.getLock()); + + } + + /** + * @param balancer + * @param balancerIndex + */ + private void setPropertyBalancer(JkBalancer balancer,String balancerIndex) { + if(balancer.id >= 0) { + createProperty(balancer, balancerIndex, "id"); + } + + createProperty(balancer, balancerIndex, "name"); + createProperty(balancer, balancerIndex, "type"); + createProperty(balancer, balancerIndex, "sticky_session"); + createProperty(balancer, balancerIndex, "sticky_session_force"); + createProperty(balancer, balancerIndex, "retries"); + createProperty(balancer, balancerIndex, "recover_time"); + if(balancer.getMethod() != null) { + createProperty(balancer, balancerIndex, "method"); + } + if(balancer.getLock() != null) { + createProperty(balancer, balancerIndex, "lock"); + } + if(balancer.getGood() >= 0) { + createProperty(balancer, balancerIndex, "good"); + } + if(balancer.getDegraded() >= 0) { + createProperty(balancer, balancerIndex, "degraded"); + } + if(balancer.getBad() >= 0) { + createProperty(balancer, balancerIndex, "bad"); + } + if(balancer.getBusy() >= 0) { + createProperty(balancer, balancerIndex, "busy"); + } + if(balancer.getMax_busy() >= 0) { + createProperty(balancer, balancerIndex, "max_busy"); + } + if(balancer.getMember_count() >=0) { + createProperty(balancer, balancerIndex, "member_count"); + } + if(balancer.getMap_count() >=0) { + createProperty(balancer, balancerIndex, "map_count"); + } + if(balancer.getTime_to_maintenance_min() >=0) { + createProperty(balancer, balancerIndex, "time_to_maintenance_min"); + } + if(balancer.getTime_to_maintenance_max() >=0) { + createProperty(balancer, balancerIndex, "time_to_maintenance_max"); + } + } + + /** + * @param balancerIndex + * @param member + */ + private void setPropertyWorker(String balancerIndex, JkBalancerMember member) { + String workerIndex ; + if(member.getId() >= 0) { + workerIndex = Integer.toString(member.getId()); + createProperty(member, balancerIndex, workerIndex, "id"); + createProperty(member, balancerIndex, workerIndex, "name"); + } else { + workerIndex = member.getName(); + } + createProperty(member, balancerIndex, workerIndex, "type"); + createProperty(member, balancerIndex, workerIndex, "host"); + createProperty(member, balancerIndex, workerIndex, "port"); + createProperty(member, balancerIndex, workerIndex, "address"); + if(member.getJvm_route() != null) { + createProperty(member, balancerIndex, workerIndex, "jvm_route"); + } + if(member.getRoute() != null) { + createProperty(member, balancerIndex, workerIndex, "route"); + } + if(member.getStatus() != null) { + createProperty(member, balancerIndex, workerIndex, "status"); + } + if(member.getActivation() != null) { + createProperty(member, balancerIndex, workerIndex, "activation"); + } + if(member.getState() != null) { + createProperty(member, balancerIndex, workerIndex, "state"); + } + createProperty(member, balancerIndex, workerIndex, "lbfactor"); + createProperty(member, balancerIndex, workerIndex, "lbvalue"); + if(member.getLbmult() >= 0) { + createProperty(member, balancerIndex, workerIndex, "lbmult"); + } + createProperty(member, balancerIndex, workerIndex, "elected"); + createProperty(member, balancerIndex, workerIndex, "readed"); + createProperty(member, balancerIndex, workerIndex, "busy"); + if(member.getMax_busy() >= 0) { + createProperty(member, balancerIndex, workerIndex, "max_busy"); + } + createProperty(member, balancerIndex, workerIndex, "transferred"); + createProperty(member, balancerIndex, workerIndex, "errors"); + if(member.getClient_errors() >= 0) { + createProperty(member, balancerIndex, workerIndex, "client_errors"); + } + if(member.getDistance() >= 0) { + createProperty(member, balancerIndex, workerIndex, "distance"); + } + if (member.getDomain() != null) { + createProperty(member, balancerIndex, workerIndex, "domain"); + } else { + getProject().setNewProperty(resultproperty + "." + balancerIndex + "." + workerIndex + + ".domain", ""); + } + if (member.getRedirect() != null) { + createProperty(member, balancerIndex, workerIndex, "redirect"); + } else { + getProject().setNewProperty(resultproperty + "." + balancerIndex + "." + workerIndex + + ".redirect", ""); + } + } + + /** + * @param balancer + * @param member + */ + private void setPropertyWorkerOnly(JkBalancer balancer, + JkBalancerMember member) { + //String prefix = resultproperty + "." + balancer.getName() + "." + member.getName(); + String prefix = resultproperty + "." + member.getName(); + Project currentProject = getProject(); + if ( balancer.getId() >= 0) { + currentProject.setNewProperty(prefix + ".lb.id", + Integer.toString(balancer.getId())); + } + //currentProject.setNewProperty(prefix + ".lb.name", balancer.getName()); + if( member.getId() >= 0) { + currentProject.setNewProperty(prefix + ".id", + Integer.toString(member.getId())); + } + currentProject.setNewProperty(prefix + ".type", member.getType()); + if (member.getJvm_route() != null) { + currentProject.setNewProperty(prefix + ".jvm_route", member.getJvm_route()); + } + if (member.getRoute() != null) { + currentProject.setNewProperty(prefix + ".route", member.getRoute()); + } + if (member.getStatus() != null) { + currentProject.setNewProperty(prefix + ".status", member.getStatus()); + } + if (member.getActivation() != null) { + currentProject.setNewProperty(prefix + ".activation", member.getActivation()); + } + if (member.getState() != null) { + currentProject.setNewProperty(prefix + ".state", member.getState()); + } + currentProject.setNewProperty(prefix + ".host", member.getHost()); + currentProject.setNewProperty(prefix + ".address", member.getAddress()); + currentProject.setNewProperty(prefix + ".port", + Integer.toString(member.getPort())); + currentProject.setNewProperty(prefix + ".lbfactor", + Integer.toString(member.getLbfactor())); + currentProject.setNewProperty(prefix + ".lbvalue", + Long.toString(member.getLbvalue())); + if(member.getLbmult() >= 0) { + currentProject.setNewProperty(prefix + ".lbmult", + Long.toString(member.getLbmult())); + } + currentProject.setNewProperty(prefix + ".elected", + Long.toString(member.getElected())); + currentProject.setNewProperty(prefix + ".readed", + Long.toString(member.getReaded())); + currentProject.setNewProperty(prefix + ".transferred", + Long.toString(member.getTransferred())); + currentProject.setNewProperty(prefix + ".busy", + Integer.toString(member.getBusy())); + if(member.getMax_busy() >= 0) { + currentProject.setNewProperty(prefix + ".max_busy", + Long.toString(member.getMax_busy())); + } + currentProject.setNewProperty(prefix + ".errors", + Long.toString(member.getErrors())); + if(member.getClient_errors() >= 0) { + currentProject.setNewProperty(prefix + ".client_errors", + Long.toString(member.getClient_errors())); + } + if(member.getDistance() >= 0) { + currentProject.setNewProperty(prefix + ".distance", + Integer.toString(member.getDistance())); + } + if (member.getDomain() != null) { + currentProject.setNewProperty(prefix + ".domain", member.getDomain()); + } else { + currentProject.setNewProperty(prefix + ".domain", ""); + } + if (member.getRedirect() != null) { + currentProject.setNewProperty(prefix + ".redirect", + member.getRedirect()); + } else { + currentProject.setNewProperty(prefix + ".redirect", ""); + } + if(member.getTime_to_recover() >= 0) { + currentProject.setNewProperty(prefix + ".time_to_recover", + Integer.toString(member.getTime_to_recover())); + } + if(member.getTime_to_recover_min() >= 0) { + currentProject.setNewProperty(prefix + ".time_to_recover_min", + Integer.toString(member.getTime_to_recover_min())); + } + if(member.getTime_to_recover_max() >= 0) { + currentProject.setNewProperty(prefix + ".time_to_recover_max", + Integer.toString(member.getTime_to_recover_max())); + currentProject.setNewProperty(prefix + ".time_to_recover", + (Integer.toString((member.getTime_to_recover_min() + + member.getTime_to_recover_max()) / 2))); + } + + } + + /* + * Set ant property for save error state + * + * @see org.apache.catalina.ant.BaseRedirectorHelperTask#setErrorProperty(java.lang.String) + */ + public void setErrorProperty(String arg0) { + errorProperty = arg0; + super.setErrorProperty(arg0); + } + + /** + * @return Returns the errorProperty. + */ + public String getErrorProperty() { + return errorProperty; + } + + protected void createProperty(Object result, String attribute) { + createProperty(result, null, null, attribute); + } + + protected void createProperty(Object result, String arraymark, + String attribute) { + createProperty(result, arraymark, null, attribute); + } + + /** + * create result as property with name from attribute resultproperty + */ + protected void createProperty(Object result, String arraymark, + String arraymark2, String attribute) { + if (resultproperty != null) { + Object value = IntrospectionUtils.getProperty(result, attribute); + if (value != null ) { + StringBuffer propertyname = new StringBuffer(resultproperty); + + if (result instanceof JkBalancer) { + if (arraymark != null) { + propertyname.append("."); + propertyname.append(arraymark); + } + } else if (result instanceof JkServer) { + if (arraymark != null) { + propertyname.append("."); + propertyname.append(arraymark); + } + } else if (result instanceof JkSoftware) { + if (arraymark != null) { + propertyname.append("."); + propertyname.append(arraymark); + } + } else if (result instanceof JkResult) { + if (arraymark != null) { + propertyname.append("."); + propertyname.append(arraymark); + } + } else if (result instanceof JkBalancerMember) { + if (arraymark != null) { + propertyname.append("."); + propertyname.append(arraymark); + } + if (arraymark2 != null) { + propertyname.append("."); + propertyname.append(arraymark2); + } + } else if (result instanceof JkBalancerMapping) { + if (arraymark != null) { + propertyname.append("."); + propertyname.append(arraymark); + } + if (arraymark2 != null) { + propertyname.append("."); + propertyname.append(arraymark2); + } + } + propertyname.append("."); + propertyname.append(attribute); + getProject().setNewProperty(propertyname.toString(), + value.toString()); + } + } + } + +} diff --git a/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkStatusUpdateLoadbalancerTask.java b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkStatusUpdateLoadbalancerTask.java new file mode 100644 index 00000000..99e4c24d --- /dev/null +++ b/rubbos/app/tomcat-connectors-1.2.32-src/jkstatus/src/share/org/apache/jk/status/JkStatusUpdateLoadbalancerTask.java @@ -0,0 +1,307 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.jk.status; + +import java.io.UnsupportedEncodingException; +import java.net.URLEncoder; + +import org.apache.tools.ant.BuildException; + +/** + * Ant task that implements the /status update loadbalancer command, supported by the + * mod_jk status (1.2.20) application. + * + * + * @author Peter Rossbach + * @version $Revision: 611693 $ + * @since mod_jk 1.2.20 + */ +public class JkStatusUpdateLoadbalancerTask extends AbstractJkStatusTask { + + /** + * The descriptive information about this implementation. + */ + private static final String info = "org.apache.jk.status.JkStatusUpdateLoadbalancerTask/1.0"; + + protected String loadbalancer ; + + protected int retries = -1; + protected int recoverWaitTime = -1; + protected int methodCode = -1; + protected String method; + + protected Boolean stickySession ; + + protected Boolean forceStickySession ; + + protected int lockCode = -1; + protected String lock; + protected int maxReplyTimeouts = -1; + + /** + * Return descriptive information about this implementation and the + * corresponding version number, in the format + * <description>/<version>. + */ + public String getInfo() { + + return (info); + + } + + /** + * + */ + public JkStatusUpdateLoadbalancerTask() { + super(); + setUrl("http://localhost/jkstatus"); + } + + /** + * @return the forceStickySession + */ + public Boolean getForceStickySession() { + return forceStickySession; + } + + /** + * @param forceStickySession the forceStickySession to set + */ + public void setForceStickySession(Boolean forceStickySession) { + this.forceStickySession = forceStickySession; + } + + /** + * @return the loadbalancer + */ + public String getLoadbalancer() { + return loadbalancer; + } + + /** + * @param loadbalancer the loadbalancer to set + */ + public void setLoadbalancer(String loadbalancer) { + this.loadbalancer = loadbalancer; + } + + + /** + * @return the locking + */ + public String getLock() { + return lock; + } + + /** + * @param locking the locking to set + */ + public void setLock(String locking) { + this.lock = locking; + } + + /** + * @return the lockingCode + */ + public int getLockCode() { + return lockCode; + } + + /** + * @param lockingCode the lockingCode to set + */ + public void setLockCode(int lockingCode) { + this.lockCode = lockingCode; + } + + /** + * @return the method + */ + public String getMethod() { + return method; + } + + /** + * @param method the method to set + */ + public void setMethod(String method) { + this.method = method; + } + + /** + * @return the methodCode + */ + public int getMethodCode() { + return methodCode; + } + + /** + * @param methodCode the methodCode to set + */ + public void setMethodCode(int methodCode) { + this.methodCode = methodCode; + } + + /** + * @return the recoverWaitTime + */ + public int getRecoverWaitTime() { + return recoverWaitTime; + } + + /** + * @param recoverWaitTime the recoverWaitTime to set + */ + public void setRecoverWaitTime(int recoverWaitTime) { + this.recoverWaitTime = recoverWaitTime; + } + + /** + * @return the retries + */ + public int getRetries() { + return retries; + } + + /** + * @param retries the retries to set + */ + public void setRetries(int retries) { + this.retries = retries; + } + + /** + * @return the stickySession + */ + public Boolean getStickySession() { + return stickySession; + } + + /** + * @param stickySession the stickySession to set + */ + public void setStickySession(Boolean stickySession) { + this.stickySession = stickySession; + } + + /** + * @return the maxReplyTimeouts + */ + public int getMaxReplyTimeouts() { + return maxReplyTimeouts; + } + + /** + * @param maxReplyTimeouts the maxReplyTimeouts to set + */ + public void setMaxReplyTimeouts(int maxReplyTimeouts) { + this.maxReplyTimeouts = maxReplyTimeouts; + } + + /** + * Create JkStatus worker update link + *