mongrel 0.3.11 → 0.3.12
Sign up to get free protection for your applications and to get access to all the features.
- data/Rakefile +4 -2
- data/bin/mongrel_rails +65 -101
- data/bin/mongrel_rails_service +1 -1
- data/bin/mongrel_rails_svc +131 -115
- data/doc/rdoc/classes/Class.html +197 -0
- data/doc/rdoc/classes/Class.src/M000001.html +24 -0
- data/doc/rdoc/classes/Class.src/M000002.html +62 -0
- data/doc/rdoc/classes/Class.src/M000003.html +21 -0
- data/doc/rdoc/classes/Class.src/M000004.html +20 -0
- data/doc/rdoc/classes/IO.html +170 -0
- data/doc/rdoc/classes/IO.src/M000005.html +19 -0
- data/doc/rdoc/classes/IO.src/M000006.html +19 -0
- data/doc/rdoc/classes/Kernel.html +159 -0
- data/doc/rdoc/classes/Kernel.src/M000025.html +19 -0
- data/doc/rdoc/classes/Kernel.src/M000026.html +25 -0
- data/doc/rdoc/classes/Mongrel.html +181 -0
- data/doc/rdoc/classes/Mongrel/CGIWrapper.html +383 -0
- data/doc/rdoc/classes/Mongrel/CGIWrapper.src/M000090.html +24 -0
- data/doc/rdoc/classes/Mongrel/CGIWrapper.src/M000091.html +47 -0
- data/doc/rdoc/classes/Mongrel/CGIWrapper.src/M000092.html +34 -0
- data/doc/rdoc/classes/Mongrel/CGIWrapper.src/M000093.html +27 -0
- data/doc/rdoc/classes/Mongrel/CGIWrapper.src/M000094.html +25 -0
- data/doc/rdoc/classes/Mongrel/CGIWrapper.src/M000095.html +18 -0
- data/doc/rdoc/classes/Mongrel/CGIWrapper.src/M000096.html +18 -0
- data/doc/rdoc/classes/Mongrel/CGIWrapper.src/M000097.html +18 -0
- data/doc/rdoc/classes/Mongrel/CGIWrapper.src/M000098.html +19 -0
- data/doc/rdoc/classes/Mongrel/Camping.html +177 -0
- data/doc/rdoc/classes/Mongrel/Camping.src/M000048.html +22 -0
- data/doc/rdoc/classes/Mongrel/Camping/CampingHandler.html +165 -0
- data/doc/rdoc/classes/Mongrel/Camping/CampingHandler.src/M000049.html +18 -0
- data/doc/rdoc/classes/Mongrel/Camping/CampingHandler.src/M000050.html +27 -0
- data/doc/rdoc/classes/Mongrel/Command.html +119 -0
- data/doc/rdoc/classes/Mongrel/Command/Base.html +337 -0
- data/doc/rdoc/classes/Mongrel/Command/Base.src/M000029.html +24 -0
- data/doc/rdoc/classes/Mongrel/Command/Base.src/M000030.html +41 -0
- data/doc/rdoc/classes/Mongrel/Command/Base.src/M000031.html +18 -0
- data/doc/rdoc/classes/Mongrel/Command/Base.src/M000032.html +18 -0
- data/doc/rdoc/classes/Mongrel/Command/Base.src/M000033.html +18 -0
- data/doc/rdoc/classes/Mongrel/Command/Base.src/M000034.html +22 -0
- data/doc/rdoc/classes/Mongrel/Command/Base.src/M000035.html +18 -0
- data/doc/rdoc/classes/Mongrel/Command/Base.src/M000036.html +18 -0
- data/doc/rdoc/classes/Mongrel/Command/Base.src/M000037.html +18 -0
- data/doc/rdoc/classes/Mongrel/Command/Base.src/M000038.html +18 -0
- data/doc/rdoc/classes/Mongrel/Command/Registry.html +192 -0
- data/doc/rdoc/classes/Mongrel/Command/Registry.src/M000039.html +20 -0
- data/doc/rdoc/classes/Mongrel/Command/Registry.src/M000040.html +25 -0
- data/doc/rdoc/classes/Mongrel/Command/Registry.src/M000041.html +46 -0
- data/doc/rdoc/classes/Mongrel/Configurator.html +563 -0
- data/doc/rdoc/classes/Mongrel/Configurator.src/M000099.html +24 -0
- data/doc/rdoc/classes/Mongrel/Configurator.src/M000100.html +23 -0
- data/doc/rdoc/classes/Mongrel/Configurator.src/M000101.html +18 -0
- data/doc/rdoc/classes/Mongrel/Configurator.src/M000102.html +32 -0
- data/doc/rdoc/classes/Mongrel/Configurator.src/M000103.html +19 -0
- data/doc/rdoc/classes/Mongrel/Configurator.src/M000104.html +31 -0
- data/doc/rdoc/classes/Mongrel/Configurator.src/M000105.html +33 -0
- data/doc/rdoc/classes/Mongrel/Configurator.src/M000106.html +18 -0
- data/doc/rdoc/classes/Mongrel/Configurator.src/M000107.html +25 -0
- data/doc/rdoc/classes/Mongrel/Configurator.src/M000108.html +19 -0
- data/doc/rdoc/classes/Mongrel/Configurator.src/M000109.html +22 -0
- data/doc/rdoc/classes/Mongrel/Configurator.src/M000110.html +21 -0
- data/doc/rdoc/classes/Mongrel/Configurator.src/M000111.html +18 -0
- data/doc/rdoc/classes/Mongrel/Configurator.src/M000112.html +27 -0
- data/doc/rdoc/classes/Mongrel/Configurator.src/M000113.html +46 -0
- data/doc/rdoc/classes/Mongrel/Configurator.src/M000114.html +18 -0
- data/doc/rdoc/classes/Mongrel/Const.html +286 -0
- data/doc/rdoc/classes/Mongrel/DirHandler.html +288 -0
- data/doc/rdoc/classes/Mongrel/DirHandler.src/M000058.html +20 -0
- data/doc/rdoc/classes/Mongrel/DirHandler.src/M000059.html +42 -0
- data/doc/rdoc/classes/Mongrel/DirHandler.src/M000060.html +40 -0
- data/doc/rdoc/classes/Mongrel/DirHandler.src/M000061.html +51 -0
- data/doc/rdoc/classes/Mongrel/DirHandler.src/M000062.html +40 -0
- data/doc/rdoc/classes/Mongrel/DirHandler.src/M000063.html +18 -0
- data/doc/rdoc/classes/Mongrel/Error404Handler.html +171 -0
- data/doc/rdoc/classes/Mongrel/Error404Handler.src/M000115.html +18 -0
- data/doc/rdoc/classes/Mongrel/Error404Handler.src/M000116.html +18 -0
- data/doc/rdoc/classes/Mongrel/HeaderOut.html +185 -0
- data/doc/rdoc/classes/Mongrel/HeaderOut.src/M000072.html +18 -0
- data/doc/rdoc/classes/Mongrel/HeaderOut.src/M000073.html +18 -0
- data/doc/rdoc/classes/Mongrel/HttpHandler.html +152 -0
- data/doc/rdoc/classes/Mongrel/HttpHandler.src/M000074.html +17 -0
- data/doc/rdoc/classes/Mongrel/HttpHandlerPlugin.html +169 -0
- data/doc/rdoc/classes/Mongrel/HttpHandlerPlugin.src/M000027.html +18 -0
- data/doc/rdoc/classes/Mongrel/HttpHandlerPlugin.src/M000028.html +17 -0
- data/doc/rdoc/classes/Mongrel/HttpParser.html +271 -0
- data/doc/rdoc/classes/Mongrel/HttpParser.src/M000051.html +28 -0
- data/doc/rdoc/classes/Mongrel/HttpParser.src/M000052.html +29 -0
- data/doc/rdoc/classes/Mongrel/HttpParser.src/M000053.html +29 -0
- data/doc/rdoc/classes/Mongrel/HttpParser.src/M000054.html +41 -0
- data/doc/rdoc/classes/Mongrel/HttpParser.src/M000055.html +27 -0
- data/doc/rdoc/classes/Mongrel/HttpParser.src/M000056.html +27 -0
- data/doc/rdoc/classes/Mongrel/HttpParser.src/M000057.html +28 -0
- data/doc/rdoc/classes/Mongrel/HttpRequest.html +222 -0
- data/doc/rdoc/classes/Mongrel/HttpRequest.src/M000117.html +28 -0
- data/doc/rdoc/classes/Mongrel/HttpRequest.src/M000118.html +20 -0
- data/doc/rdoc/classes/Mongrel/HttpRequest.src/M000119.html +20 -0
- data/doc/rdoc/classes/Mongrel/HttpRequest.src/M000120.html +32 -0
- data/doc/rdoc/classes/Mongrel/HttpResponse.html +371 -0
- data/doc/rdoc/classes/Mongrel/HttpResponse.src/M000075.html +26 -0
- data/doc/rdoc/classes/Mongrel/HttpResponse.src/M000076.html +20 -0
- data/doc/rdoc/classes/Mongrel/HttpResponse.src/M000077.html +25 -0
- data/doc/rdoc/classes/Mongrel/HttpResponse.src/M000078.html +22 -0
- data/doc/rdoc/classes/Mongrel/HttpResponse.src/M000079.html +22 -0
- data/doc/rdoc/classes/Mongrel/HttpResponse.src/M000080.html +23 -0
- data/doc/rdoc/classes/Mongrel/HttpResponse.src/M000081.html +18 -0
- data/doc/rdoc/classes/Mongrel/HttpResponse.src/M000082.html +20 -0
- data/doc/rdoc/classes/Mongrel/HttpResponse.src/M000083.html +18 -0
- data/doc/rdoc/classes/Mongrel/HttpServer.html +360 -0
- data/doc/rdoc/classes/Mongrel/HttpServer.src/M000064.html +24 -0
- data/doc/rdoc/classes/Mongrel/HttpServer.src/M000065.html +65 -0
- data/doc/rdoc/classes/Mongrel/HttpServer.src/M000066.html +24 -0
- data/doc/rdoc/classes/Mongrel/HttpServer.src/M000067.html +60 -0
- data/doc/rdoc/classes/Mongrel/HttpServer.src/M000068.html +28 -0
- data/doc/rdoc/classes/Mongrel/HttpServer.src/M000069.html +18 -0
- data/doc/rdoc/classes/Mongrel/HttpServer.src/M000070.html +22 -0
- data/doc/rdoc/classes/Mongrel/HttpServer.src/M000071.html +18 -0
- data/doc/rdoc/classes/Mongrel/Rails.html +112 -0
- data/doc/rdoc/classes/Mongrel/Rails/RailsConfigurator.html +223 -0
- data/doc/rdoc/classes/Mongrel/Rails/RailsConfigurator.src/M000042.html +35 -0
- data/doc/rdoc/classes/Mongrel/Rails/RailsConfigurator.src/M000043.html +25 -0
- data/doc/rdoc/classes/Mongrel/Rails/RailsConfigurator.src/M000044.html +32 -0
- data/doc/rdoc/classes/Mongrel/Rails/RailsHandler.html +250 -0
- data/doc/rdoc/classes/Mongrel/Rails/RailsHandler.src/M000045.html +22 -0
- data/doc/rdoc/classes/Mongrel/Rails/RailsHandler.src/M000046.html +48 -0
- data/doc/rdoc/classes/Mongrel/Rails/RailsHandler.src/M000047.html +23 -0
- data/doc/rdoc/classes/Mongrel/StopServer.html +117 -0
- data/doc/rdoc/classes/Mongrel/URIClassifier.html +301 -0
- data/doc/rdoc/classes/Mongrel/URIClassifier.src/M000084.html +18 -0
- data/doc/rdoc/classes/Mongrel/URIClassifier.src/M000085.html +18 -0
- data/doc/rdoc/classes/Mongrel/URIClassifier.src/M000086.html +39 -0
- data/doc/rdoc/classes/Mongrel/URIClassifier.src/M000087.html +51 -0
- data/doc/rdoc/classes/Mongrel/URIClassifier.src/M000088.html +36 -0
- data/doc/rdoc/classes/Mongrel/URIClassifier.src/M000089.html +83 -0
- data/doc/rdoc/classes/MongrelDbg.html +209 -0
- data/doc/rdoc/classes/MongrelDbg.src/M000020.html +19 -0
- data/doc/rdoc/classes/MongrelDbg.src/M000021.html +20 -0
- data/doc/rdoc/classes/MongrelDbg.src/M000022.html +22 -0
- data/doc/rdoc/classes/MongrelDbg.src/M000023.html +21 -0
- data/doc/rdoc/classes/MongrelDbg.src/M000024.html +18 -0
- data/doc/rdoc/classes/ObjectTracker.html +176 -0
- data/doc/rdoc/classes/ObjectTracker.src/M000016.html +22 -0
- data/doc/rdoc/classes/ObjectTracker.src/M000017.html +18 -0
- data/doc/rdoc/classes/ObjectTracker.src/M000018.html +18 -0
- data/doc/rdoc/classes/ObjectTracker.src/M000019.html +46 -0
- data/doc/rdoc/classes/RequestLog.html +113 -0
- data/doc/rdoc/classes/RequestLog/Files.html +144 -0
- data/doc/rdoc/classes/RequestLog/Files.src/M000121.html +19 -0
- data/doc/rdoc/classes/RequestLog/Objects.html +144 -0
- data/doc/rdoc/classes/RequestLog/Objects.src/M000122.html +19 -0
- data/doc/rdoc/classes/RequestLog/Params.html +144 -0
- data/doc/rdoc/classes/RequestLog/Params.src/M000123.html +19 -0
- data/doc/rdoc/classes/Stats.html +306 -0
- data/doc/rdoc/classes/Stats.src/M000009.html +19 -0
- data/doc/rdoc/classes/Stats.src/M000010.html +23 -0
- data/doc/rdoc/classes/Stats.src/M000011.html +26 -0
- data/doc/rdoc/classes/Stats.src/M000012.html +18 -0
- data/doc/rdoc/classes/Stats.src/M000013.html +18 -0
- data/doc/rdoc/classes/Stats.src/M000014.html +19 -0
- data/doc/rdoc/classes/Stats.src/M000015.html +20 -0
- data/doc/rdoc/classes/TCPServer.html +173 -0
- data/doc/rdoc/classes/TCPServer.src/M000007.html +19 -0
- data/doc/rdoc/created.rid +1 -0
- data/doc/rdoc/files/COPYING.html +756 -0
- data/doc/rdoc/files/LICENSE.html +756 -0
- data/doc/rdoc/files/README.html +302 -0
- data/doc/rdoc/files/ext/http11/http11_c.html +101 -0
- data/doc/rdoc/files/lib/mongrel/camping_rb.html +108 -0
- data/doc/rdoc/files/lib/mongrel/cgi_rb.html +108 -0
- data/doc/rdoc/files/lib/mongrel/command_rb.html +111 -0
- data/doc/rdoc/files/lib/mongrel/debug_rb.html +110 -0
- data/doc/rdoc/files/lib/mongrel/handlers_rb.html +109 -0
- data/doc/rdoc/files/lib/mongrel/init_rb.html +109 -0
- data/doc/rdoc/files/lib/mongrel/rails_rb.html +111 -0
- data/doc/rdoc/files/lib/mongrel/stats_rb.html +117 -0
- data/doc/rdoc/files/lib/mongrel/tcphack_rb.html +109 -0
- data/doc/rdoc/files/lib/mongrel_rb.html +118 -0
- data/doc/rdoc/fr_class_index.html +60 -0
- data/doc/rdoc/fr_file_index.html +40 -0
- data/doc/rdoc/fr_method_index.html +149 -0
- data/doc/rdoc/index.html +24 -0
- data/doc/rdoc/rdoc-style.css +208 -0
- data/examples/builder.rb +29 -0
- data/examples/camping/blog.rb +11 -2
- data/examples/simpletest.rb +20 -7
- data/ext/http11/http11.c +71 -14
- data/ext/http11/http11_parser.c +27 -24
- data/ext/http11/http11_parser.h +2 -1
- data/lib/http11.bundle +0 -0
- data/lib/mongrel.rb +498 -135
- data/lib/mongrel/command.rb +1 -1
- data/lib/mongrel/debug.rb +259 -0
- data/lib/mongrel/handlers.rb +76 -22
- data/lib/mongrel/rails.rb +165 -72
- data/lib/mongrel/stats.rb +71 -0
- data/test/test_configurator.rb +67 -0
- data/test/test_debug.rb +31 -0
- data/test/test_http11.rb +16 -0
- data/test/test_response.rb +5 -0
- data/test/test_stats.rb +28 -0
- metadata +224 -2
@@ -0,0 +1,83 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html>
|
7
|
+
<head>
|
8
|
+
<title>resolve (Mongrel::URIClassifier)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre>/**
|
14
|
+
* call-seq:
|
15
|
+
* uc.resolve("/someuri") -> "/someuri", "", handler
|
16
|
+
* uc.resolve("/someuri/pathinfo") -> "/someuri", "/pathinfo", handler
|
17
|
+
* uc.resolve("/notfound/orhere") -> nil, nil, nil
|
18
|
+
* uc.resolve("/") -> "/", "/", handler # if uc.register("/", handler)
|
19
|
+
* uc.resolve("/path/from/root") -> "/", "/path/from/root", handler # if uc.register("/", handler)
|
20
|
+
*
|
21
|
+
* Attempts to resolve either the whole URI or at the longest prefix, returning
|
22
|
+
* the prefix (as script_info), path (as path_info), and registered handler
|
23
|
+
* (usually an HttpHandler). If it doesn't find a handler registered at the longest
|
24
|
+
* match then it returns nil,nil,nil.
|
25
|
+
*
|
26
|
+
* Because the resolver uses a trie you are able to register a handler at *any* character
|
27
|
+
* in the URI and it will be handled as long as it's the longest prefix. So, if you
|
28
|
+
* registered handler #1 at "/something/lik", and #2 at "/something/like/that", then a
|
29
|
+
* a search for "/something/like" would give you #1. A search for "/something/like/that/too"
|
30
|
+
* would give you #2.
|
31
|
+
*
|
32
|
+
* This is very powerful since it means you can also attach handlers to parts of the ;
|
33
|
+
* (semi-colon) separated path params, any part of the path, use off chars, anything really.
|
34
|
+
* It also means that it's very efficient to do this only taking as long as the URI has
|
35
|
+
* characters.
|
36
|
+
*
|
37
|
+
* A slight modification to the CGI 1.2 standard is given for handlers registered to "/".
|
38
|
+
* CGI expects all CGI scripts to be at some script path, so it doesn't really say anything
|
39
|
+
* about a script that handles the root. To make this work, the resolver will detect that
|
40
|
+
* the requested handler is at "/", and return that for script_name, and then simply return
|
41
|
+
* the full URI back as path_info.
|
42
|
+
*
|
43
|
+
* It expects strings with no embedded '\0' characters. Don't try other string-like stuff yet.
|
44
|
+
*/
|
45
|
+
VALUE URIClassifier_resolve(VALUE self, VALUE uri)
|
46
|
+
{
|
47
|
+
void *handler = NULL;
|
48
|
+
int pref_len = 0;
|
49
|
+
struct tst *tst = NULL;
|
50
|
+
VALUE result;
|
51
|
+
unsigned char *uri_str = NULL;
|
52
|
+
|
53
|
+
DATA_GET(self, struct tst, tst);
|
54
|
+
uri_str = (unsigned char *)StringValueCStr(uri);
|
55
|
+
|
56
|
+
handler = tst_search(uri_str, tst, &pref_len);
|
57
|
+
|
58
|
+
// setup for multiple return values
|
59
|
+
result = rb_ary_new();
|
60
|
+
|
61
|
+
if(handler) {
|
62
|
+
rb_ary_push(result, rb_str_substr (uri, 0, pref_len));
|
63
|
+
// compensate for a script_name="/" where we need to add the "/" to path_info to keep it consistent
|
64
|
+
if(pref_len == 1 && uri_str[0] == '/') {
|
65
|
+
// matches the root URI so we have to use the whole URI as the path_info
|
66
|
+
rb_ary_push(result, uri);
|
67
|
+
} else {
|
68
|
+
// matches a script so process like normal
|
69
|
+
rb_ary_push(result, rb_str_substr(uri, pref_len, RSTRING(uri)->len));
|
70
|
+
}
|
71
|
+
|
72
|
+
rb_ary_push(result, (VALUE)handler);
|
73
|
+
} else {
|
74
|
+
// not found so push back nothing
|
75
|
+
rb_ary_push(result, Qnil);
|
76
|
+
rb_ary_push(result, Qnil);
|
77
|
+
rb_ary_push(result, Qnil);
|
78
|
+
}
|
79
|
+
|
80
|
+
return result;
|
81
|
+
}</pre>
|
82
|
+
</body>
|
83
|
+
</html>
|
@@ -0,0 +1,209 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
7
|
+
<head>
|
8
|
+
<title>Module: MongrelDbg</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<meta http-equiv="Content-Script-Type" content="text/javascript" />
|
11
|
+
<link rel="stylesheet" href=".././rdoc-style.css" type="text/css" media="screen" />
|
12
|
+
<script type="text/javascript">
|
13
|
+
// <![CDATA[
|
14
|
+
|
15
|
+
function popupCode( url ) {
|
16
|
+
window.open(url, "Code", "resizable=yes,scrollbars=yes,toolbar=no,status=no,height=150,width=400")
|
17
|
+
}
|
18
|
+
|
19
|
+
function toggleCode( id ) {
|
20
|
+
if ( document.getElementById )
|
21
|
+
elem = document.getElementById( id );
|
22
|
+
else if ( document.all )
|
23
|
+
elem = eval( "document.all." + id );
|
24
|
+
else
|
25
|
+
return false;
|
26
|
+
|
27
|
+
elemStyle = elem.style;
|
28
|
+
|
29
|
+
if ( elemStyle.display != "block" ) {
|
30
|
+
elemStyle.display = "block"
|
31
|
+
} else {
|
32
|
+
elemStyle.display = "none"
|
33
|
+
}
|
34
|
+
|
35
|
+
return true;
|
36
|
+
}
|
37
|
+
|
38
|
+
// Make codeblocks hidden by default
|
39
|
+
document.writeln( "<style type=\"text/css\">div.method-source-code { display: none }</style>" )
|
40
|
+
|
41
|
+
// ]]>
|
42
|
+
</script>
|
43
|
+
|
44
|
+
</head>
|
45
|
+
<body>
|
46
|
+
|
47
|
+
|
48
|
+
|
49
|
+
<div id="classHeader">
|
50
|
+
<table class="header-table">
|
51
|
+
<tr class="top-aligned-row">
|
52
|
+
<td><strong>Module</strong></td>
|
53
|
+
<td class="class-name-in-header">MongrelDbg</td>
|
54
|
+
</tr>
|
55
|
+
<tr class="top-aligned-row">
|
56
|
+
<td><strong>In:</strong></td>
|
57
|
+
<td>
|
58
|
+
<a href="../files/lib/mongrel/debug_rb.html">
|
59
|
+
lib/mongrel/debug.rb
|
60
|
+
</a>
|
61
|
+
<br />
|
62
|
+
</td>
|
63
|
+
</tr>
|
64
|
+
|
65
|
+
</table>
|
66
|
+
</div>
|
67
|
+
<!-- banner header -->
|
68
|
+
|
69
|
+
<div id="bodyContent">
|
70
|
+
|
71
|
+
|
72
|
+
|
73
|
+
<div id="contextContent">
|
74
|
+
|
75
|
+
|
76
|
+
|
77
|
+
</div>
|
78
|
+
|
79
|
+
<div id="method-list">
|
80
|
+
<h3 class="section-bar">Methods</h3>
|
81
|
+
|
82
|
+
<div class="name-list">
|
83
|
+
<a href="#M000022">begin_trace</a>
|
84
|
+
<a href="#M000020">configure</a>
|
85
|
+
<a href="#M000023">end_trace</a>
|
86
|
+
<a href="#M000021">trace</a>
|
87
|
+
<a href="#M000024">tracing?</a>
|
88
|
+
</div>
|
89
|
+
</div>
|
90
|
+
|
91
|
+
</div>
|
92
|
+
|
93
|
+
|
94
|
+
<!-- if includes -->
|
95
|
+
|
96
|
+
<div id="section">
|
97
|
+
|
98
|
+
|
99
|
+
<div id="constants-list">
|
100
|
+
<h3 class="section-bar">Constants</h3>
|
101
|
+
|
102
|
+
<div class="name-list">
|
103
|
+
<table summary="Constants">
|
104
|
+
<tr class="top-aligned-row context-row">
|
105
|
+
<td class="context-item-name">SETTINGS</td>
|
106
|
+
<td>=</td>
|
107
|
+
<td class="context-item-value">{ :tracing => {}}</td>
|
108
|
+
</tr>
|
109
|
+
<tr class="top-aligned-row context-row">
|
110
|
+
<td class="context-item-name">LOGGING</td>
|
111
|
+
<td>=</td>
|
112
|
+
<td class="context-item-value">{ }</td>
|
113
|
+
</tr>
|
114
|
+
</table>
|
115
|
+
</div>
|
116
|
+
</div>
|
117
|
+
|
118
|
+
|
119
|
+
|
120
|
+
|
121
|
+
|
122
|
+
|
123
|
+
<!-- if method_list -->
|
124
|
+
<div id="methods">
|
125
|
+
<h3 class="section-bar">Public Class methods</h3>
|
126
|
+
|
127
|
+
<div id="method-M000022" class="method-detail">
|
128
|
+
<a name="M000022"></a>
|
129
|
+
|
130
|
+
<div class="method-heading">
|
131
|
+
<a href="MongrelDbg.src/M000022.html" target="Code" class="method-signature"
|
132
|
+
onclick="popupCode('MongrelDbg.src/M000022.html');return false;">
|
133
|
+
<span class="method-name">begin_trace</span><span class="method-args">(target)</span>
|
134
|
+
</a>
|
135
|
+
</div>
|
136
|
+
|
137
|
+
<div class="method-description">
|
138
|
+
</div>
|
139
|
+
</div>
|
140
|
+
|
141
|
+
<div id="method-M000020" class="method-detail">
|
142
|
+
<a name="M000020"></a>
|
143
|
+
|
144
|
+
<div class="method-heading">
|
145
|
+
<a href="MongrelDbg.src/M000020.html" target="Code" class="method-signature"
|
146
|
+
onclick="popupCode('MongrelDbg.src/M000020.html');return false;">
|
147
|
+
<span class="method-name">configure</span><span class="method-args">(log_dir = "log/mongrel_debug")</span>
|
148
|
+
</a>
|
149
|
+
</div>
|
150
|
+
|
151
|
+
<div class="method-description">
|
152
|
+
</div>
|
153
|
+
</div>
|
154
|
+
|
155
|
+
<div id="method-M000023" class="method-detail">
|
156
|
+
<a name="M000023"></a>
|
157
|
+
|
158
|
+
<div class="method-heading">
|
159
|
+
<a href="MongrelDbg.src/M000023.html" target="Code" class="method-signature"
|
160
|
+
onclick="popupCode('MongrelDbg.src/M000023.html');return false;">
|
161
|
+
<span class="method-name">end_trace</span><span class="method-args">(target)</span>
|
162
|
+
</a>
|
163
|
+
</div>
|
164
|
+
|
165
|
+
<div class="method-description">
|
166
|
+
</div>
|
167
|
+
</div>
|
168
|
+
|
169
|
+
<div id="method-M000021" class="method-detail">
|
170
|
+
<a name="M000021"></a>
|
171
|
+
|
172
|
+
<div class="method-heading">
|
173
|
+
<a href="MongrelDbg.src/M000021.html" target="Code" class="method-signature"
|
174
|
+
onclick="popupCode('MongrelDbg.src/M000021.html');return false;">
|
175
|
+
<span class="method-name">trace</span><span class="method-args">(target, message)</span>
|
176
|
+
</a>
|
177
|
+
</div>
|
178
|
+
|
179
|
+
<div class="method-description">
|
180
|
+
</div>
|
181
|
+
</div>
|
182
|
+
|
183
|
+
<div id="method-M000024" class="method-detail">
|
184
|
+
<a name="M000024"></a>
|
185
|
+
|
186
|
+
<div class="method-heading">
|
187
|
+
<a href="MongrelDbg.src/M000024.html" target="Code" class="method-signature"
|
188
|
+
onclick="popupCode('MongrelDbg.src/M000024.html');return false;">
|
189
|
+
<span class="method-name">tracing?</span><span class="method-args">(target)</span>
|
190
|
+
</a>
|
191
|
+
</div>
|
192
|
+
|
193
|
+
<div class="method-description">
|
194
|
+
</div>
|
195
|
+
</div>
|
196
|
+
|
197
|
+
|
198
|
+
</div>
|
199
|
+
|
200
|
+
|
201
|
+
</div>
|
202
|
+
|
203
|
+
|
204
|
+
<div id="validator-badges">
|
205
|
+
<p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
|
206
|
+
</div>
|
207
|
+
|
208
|
+
</body>
|
209
|
+
</html>
|
@@ -0,0 +1,19 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html>
|
7
|
+
<head>
|
8
|
+
<title>configure (MongrelDbg)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre> <span class="ruby-comment cmt"># File lib/mongrel/debug.rb, line 11</span>
|
14
|
+
11: <span class="ruby-keyword kw">def</span> <span class="ruby-constant">MongrelDbg</span><span class="ruby-operator">::</span><span class="ruby-identifier">configure</span>(<span class="ruby-identifier">log_dir</span> = <span class="ruby-value str">"log/mongrel_debug"</span>)
|
15
|
+
12: <span class="ruby-constant">Dir</span>.<span class="ruby-identifier">mkdir</span>(<span class="ruby-identifier">log_dir</span>) <span class="ruby-keyword kw">if</span> <span class="ruby-keyword kw">not</span> <span class="ruby-constant">File</span>.<span class="ruby-identifier">exist?</span>(<span class="ruby-identifier">log_dir</span>)
|
16
|
+
13: <span class="ruby-ivar">@log_dir</span> = <span class="ruby-identifier">log_dir</span>
|
17
|
+
14: <span class="ruby-keyword kw">end</span></pre>
|
18
|
+
</body>
|
19
|
+
</html>
|
@@ -0,0 +1,20 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html>
|
7
|
+
<head>
|
8
|
+
<title>trace (MongrelDbg)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre> <span class="ruby-comment cmt"># File lib/mongrel/debug.rb, line 17</span>
|
14
|
+
17: <span class="ruby-keyword kw">def</span> <span class="ruby-constant">MongrelDbg</span><span class="ruby-operator">::</span><span class="ruby-identifier">trace</span>(<span class="ruby-identifier">target</span>, <span class="ruby-identifier">message</span>)
|
15
|
+
18: <span class="ruby-keyword kw">if</span> <span class="ruby-constant">SETTINGS</span>[<span class="ruby-identifier">:tracing</span>][<span class="ruby-identifier">target</span>] <span class="ruby-keyword kw">and</span> <span class="ruby-constant">LOGGING</span>[<span class="ruby-identifier">target</span>]
|
16
|
+
19: <span class="ruby-constant">LOGGING</span>[<span class="ruby-identifier">target</span>].<span class="ruby-identifier">log</span>(<span class="ruby-constant">Logger</span><span class="ruby-operator">::</span><span class="ruby-constant">DEBUG</span>, <span class="ruby-identifier">message</span>)
|
17
|
+
20: <span class="ruby-keyword kw">end</span>
|
18
|
+
21: <span class="ruby-keyword kw">end</span></pre>
|
19
|
+
</body>
|
20
|
+
</html>
|
@@ -0,0 +1,22 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html>
|
7
|
+
<head>
|
8
|
+
<title>begin_trace (MongrelDbg)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre> <span class="ruby-comment cmt"># File lib/mongrel/debug.rb, line 23</span>
|
14
|
+
23: <span class="ruby-keyword kw">def</span> <span class="ruby-constant">MongrelDbg</span><span class="ruby-operator">::</span><span class="ruby-identifier">begin_trace</span>(<span class="ruby-identifier">target</span>)
|
15
|
+
24: <span class="ruby-constant">SETTINGS</span>[<span class="ruby-identifier">:tracing</span>][<span class="ruby-identifier">target</span>] = <span class="ruby-keyword kw">true</span>
|
16
|
+
25: <span class="ruby-keyword kw">if</span> <span class="ruby-keyword kw">not</span> <span class="ruby-constant">LOGGING</span>[<span class="ruby-identifier">target</span>]
|
17
|
+
26: <span class="ruby-constant">LOGGING</span>[<span class="ruby-identifier">target</span>] = <span class="ruby-constant">Logger</span>.<span class="ruby-identifier">new</span>(<span class="ruby-constant">File</span>.<span class="ruby-identifier">join</span>(<span class="ruby-ivar">@log_dir</span>, <span class="ruby-node">"#{target.to_s}.log"</span>))
|
18
|
+
27: <span class="ruby-keyword kw">end</span>
|
19
|
+
28: <span class="ruby-constant">MongrelDbg</span><span class="ruby-operator">::</span><span class="ruby-identifier">trace</span>(<span class="ruby-identifier">target</span>, <span class="ruby-node">"TRACING ON #{Time.now}"</span>)
|
20
|
+
29: <span class="ruby-keyword kw">end</span></pre>
|
21
|
+
</body>
|
22
|
+
</html>
|
@@ -0,0 +1,21 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html>
|
7
|
+
<head>
|
8
|
+
<title>end_trace (MongrelDbg)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre> <span class="ruby-comment cmt"># File lib/mongrel/debug.rb, line 31</span>
|
14
|
+
31: <span class="ruby-keyword kw">def</span> <span class="ruby-constant">MongrelDbg</span><span class="ruby-operator">::</span><span class="ruby-identifier">end_trace</span>(<span class="ruby-identifier">target</span>)
|
15
|
+
32: <span class="ruby-constant">SETTINGS</span>[<span class="ruby-identifier">:tracing</span>][<span class="ruby-identifier">target</span>] = <span class="ruby-keyword kw">false</span>
|
16
|
+
33: <span class="ruby-constant">MongrelDbg</span><span class="ruby-operator">::</span><span class="ruby-identifier">trace</span>(<span class="ruby-identifier">target</span>, <span class="ruby-node">"TRACING OFF #{Time.now}"</span>)
|
17
|
+
34: <span class="ruby-constant">LOGGING</span>[<span class="ruby-identifier">target</span>].<span class="ruby-identifier">close</span>
|
18
|
+
35: <span class="ruby-constant">LOGGING</span>[<span class="ruby-identifier">target</span>] = <span class="ruby-keyword kw">nil</span>
|
19
|
+
36: <span class="ruby-keyword kw">end</span></pre>
|
20
|
+
</body>
|
21
|
+
</html>
|
@@ -0,0 +1,18 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html>
|
7
|
+
<head>
|
8
|
+
<title>tracing? (MongrelDbg)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre> <span class="ruby-comment cmt"># File lib/mongrel/debug.rb, line 38</span>
|
14
|
+
38: <span class="ruby-keyword kw">def</span> <span class="ruby-constant">MongrelDbg</span><span class="ruby-operator">::</span><span class="ruby-identifier">tracing?</span>(<span class="ruby-identifier">target</span>)
|
15
|
+
39: <span class="ruby-constant">SETTINGS</span>[<span class="ruby-identifier">:tracing</span>][<span class="ruby-identifier">target</span>]
|
16
|
+
40: <span class="ruby-keyword kw">end</span></pre>
|
17
|
+
</body>
|
18
|
+
</html>
|
@@ -0,0 +1,176 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
7
|
+
<head>
|
8
|
+
<title>Module: ObjectTracker</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<meta http-equiv="Content-Script-Type" content="text/javascript" />
|
11
|
+
<link rel="stylesheet" href=".././rdoc-style.css" type="text/css" media="screen" />
|
12
|
+
<script type="text/javascript">
|
13
|
+
// <![CDATA[
|
14
|
+
|
15
|
+
function popupCode( url ) {
|
16
|
+
window.open(url, "Code", "resizable=yes,scrollbars=yes,toolbar=no,status=no,height=150,width=400")
|
17
|
+
}
|
18
|
+
|
19
|
+
function toggleCode( id ) {
|
20
|
+
if ( document.getElementById )
|
21
|
+
elem = document.getElementById( id );
|
22
|
+
else if ( document.all )
|
23
|
+
elem = eval( "document.all." + id );
|
24
|
+
else
|
25
|
+
return false;
|
26
|
+
|
27
|
+
elemStyle = elem.style;
|
28
|
+
|
29
|
+
if ( elemStyle.display != "block" ) {
|
30
|
+
elemStyle.display = "block"
|
31
|
+
} else {
|
32
|
+
elemStyle.display = "none"
|
33
|
+
}
|
34
|
+
|
35
|
+
return true;
|
36
|
+
}
|
37
|
+
|
38
|
+
// Make codeblocks hidden by default
|
39
|
+
document.writeln( "<style type=\"text/css\">div.method-source-code { display: none }</style>" )
|
40
|
+
|
41
|
+
// ]]>
|
42
|
+
</script>
|
43
|
+
|
44
|
+
</head>
|
45
|
+
<body>
|
46
|
+
|
47
|
+
|
48
|
+
|
49
|
+
<div id="classHeader">
|
50
|
+
<table class="header-table">
|
51
|
+
<tr class="top-aligned-row">
|
52
|
+
<td><strong>Module</strong></td>
|
53
|
+
<td class="class-name-in-header">ObjectTracker</td>
|
54
|
+
</tr>
|
55
|
+
<tr class="top-aligned-row">
|
56
|
+
<td><strong>In:</strong></td>
|
57
|
+
<td>
|
58
|
+
<a href="../files/lib/mongrel/debug_rb.html">
|
59
|
+
lib/mongrel/debug.rb
|
60
|
+
</a>
|
61
|
+
<br />
|
62
|
+
</td>
|
63
|
+
</tr>
|
64
|
+
|
65
|
+
</table>
|
66
|
+
</div>
|
67
|
+
<!-- banner header -->
|
68
|
+
|
69
|
+
<div id="bodyContent">
|
70
|
+
|
71
|
+
|
72
|
+
|
73
|
+
<div id="contextContent">
|
74
|
+
|
75
|
+
|
76
|
+
|
77
|
+
</div>
|
78
|
+
|
79
|
+
<div id="method-list">
|
80
|
+
<h3 class="section-bar">Methods</h3>
|
81
|
+
|
82
|
+
<div class="name-list">
|
83
|
+
<a href="#M000016">configure</a>
|
84
|
+
<a href="#M000019">sample</a>
|
85
|
+
<a href="#M000017">start</a>
|
86
|
+
<a href="#M000018">stop</a>
|
87
|
+
</div>
|
88
|
+
</div>
|
89
|
+
|
90
|
+
</div>
|
91
|
+
|
92
|
+
|
93
|
+
<!-- if includes -->
|
94
|
+
|
95
|
+
<div id="section">
|
96
|
+
|
97
|
+
|
98
|
+
|
99
|
+
|
100
|
+
|
101
|
+
|
102
|
+
|
103
|
+
|
104
|
+
<!-- if method_list -->
|
105
|
+
<div id="methods">
|
106
|
+
<h3 class="section-bar">Public Class methods</h3>
|
107
|
+
|
108
|
+
<div id="method-M000016" class="method-detail">
|
109
|
+
<a name="M000016"></a>
|
110
|
+
|
111
|
+
<div class="method-heading">
|
112
|
+
<a href="ObjectTracker.src/M000016.html" target="Code" class="method-signature"
|
113
|
+
onclick="popupCode('ObjectTracker.src/M000016.html');return false;">
|
114
|
+
<span class="method-name">configure</span><span class="method-args">()</span>
|
115
|
+
</a>
|
116
|
+
</div>
|
117
|
+
|
118
|
+
<div class="method-description">
|
119
|
+
</div>
|
120
|
+
</div>
|
121
|
+
|
122
|
+
<div id="method-M000019" class="method-detail">
|
123
|
+
<a name="M000019"></a>
|
124
|
+
|
125
|
+
<div class="method-heading">
|
126
|
+
<a href="ObjectTracker.src/M000019.html" target="Code" class="method-signature"
|
127
|
+
onclick="popupCode('ObjectTracker.src/M000019.html');return false;">
|
128
|
+
<span class="method-name">sample</span><span class="method-args">()</span>
|
129
|
+
</a>
|
130
|
+
</div>
|
131
|
+
|
132
|
+
<div class="method-description">
|
133
|
+
</div>
|
134
|
+
</div>
|
135
|
+
|
136
|
+
<div id="method-M000017" class="method-detail">
|
137
|
+
<a name="M000017"></a>
|
138
|
+
|
139
|
+
<div class="method-heading">
|
140
|
+
<a href="ObjectTracker.src/M000017.html" target="Code" class="method-signature"
|
141
|
+
onclick="popupCode('ObjectTracker.src/M000017.html');return false;">
|
142
|
+
<span class="method-name">start</span><span class="method-args">()</span>
|
143
|
+
</a>
|
144
|
+
</div>
|
145
|
+
|
146
|
+
<div class="method-description">
|
147
|
+
</div>
|
148
|
+
</div>
|
149
|
+
|
150
|
+
<div id="method-M000018" class="method-detail">
|
151
|
+
<a name="M000018"></a>
|
152
|
+
|
153
|
+
<div class="method-heading">
|
154
|
+
<a href="ObjectTracker.src/M000018.html" target="Code" class="method-signature"
|
155
|
+
onclick="popupCode('ObjectTracker.src/M000018.html');return false;">
|
156
|
+
<span class="method-name">stop</span><span class="method-args">()</span>
|
157
|
+
</a>
|
158
|
+
</div>
|
159
|
+
|
160
|
+
<div class="method-description">
|
161
|
+
</div>
|
162
|
+
</div>
|
163
|
+
|
164
|
+
|
165
|
+
</div>
|
166
|
+
|
167
|
+
|
168
|
+
</div>
|
169
|
+
|
170
|
+
|
171
|
+
<div id="validator-badges">
|
172
|
+
<p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
|
173
|
+
</div>
|
174
|
+
|
175
|
+
</body>
|
176
|
+
</html>
|