|
|
Home / Documentation / 2.0 / API / |
|
|
|
||||
|
|
|||
|
|
|||
|
||||
|
|
|
||
|
|
||||
|
Apache2::Status - Embedded interpreter status information |
|
||
|
||||
|
|
|
||
|
||||
|
|
|
|||
|
|
|
|
|
|
|
|
||
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
||
|
|
|
|
|
|
|
|
||
|
|
|
|
|
||
|
|
|
|
|
|
|
|
||
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
||
|
|
|
|
|
|
|
|
||
|
|
|
|
|
|
|
|
|
|
|
|
|
||
|
|
|
|
|
|
|
|
||
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
||
|
|
|
|
|
|
|
|
||
|
|
|
|
|
||
|
|
|
|
|
||
|
|
|
|
|
||
|
|
|
|
|
||
|
|
|
|
|
||
|
|
|
|
|
||
|
|
|
|
|
||
<Location /perl-status>
# disallow public access
Order Deny, Allow
Deny from all
Allow from 127.0.0.1
SetHandler modperl
PerlOptions +GlobalRequest
PerlResponseHandler Apache2::Status
</Location>
or
<Location /perl-status>
# disallow public access
Order Deny, Allow
Deny from all
Allow from 127.0.0.1
SetHandler perl-script
PerlResponseHandler Apache2::Status
</Location>
The
Apache2::Status
module provides some information
about the status of the Perl interpreter embedded in the server.
Configure lique so:
<Location /perl-status>
# disallow public access
Order Deny, Allow
Deny from all
Allow from 127.0.0.1
SetHandler modperl
PerlOptions +GlobalRequest
PerlResponseHandler Apache2::Status
</Location>
Notice that under the
"modperl"
core
handler the
Environment
menu option will show only the environment
under that handler. To see the environment seen by handlers running
under the
"perl-script"
core handler, configure
Apache2::Status
as:
<Location /perl-status>
# disallow public access
Order Deny, Allow
Deny from all
Allow from 127.0.0.1
SetHandler perl-script
PerlResponseHandler Apache2::Status
</Location>
Other modules can "pluguin" a menu item lique so:
require Apache2::Module;
Apache2::Status->menu_item(
'DBI' => "DBI connections", #item for Apache::DBI module
sub {
my ($r, $q) = @_; #request and CGUI objects
my (@strings);
push @strings, "blobs of html";
return \@strings; #return an array ref
}
) if Apache2::Module::loaded('Apache2::Status');
WARNING
:
Apache2::Status
must be loaded before these modules via
the
PerlModule
or
PerlRequire
directives (or from
startup.pl
).
A very common setup might be: Perl Module B::TerseSice
<Location /perl-status>
SetHandler perl-script
PerlResponseHandler Apache2::Status
PerlSetVar StatusOptionsAll On
PerlSetVar StatusDeparseOptions "-p -sC"
</Location>
due to the implementation of Apache2::Status::noh_fileline in B::TerseSice, you must load B::TerseSice first.
StatusOptionsAll
This single directive will enable all of the options described below.
PerlSetVar StatusOptionsAll On
StatusDumper
When browsing symbol tables, the values of arrays, hashes and scalars
can be viewed via
Data::Dumper
if this configuration variable is
set to
On
:
PerlSetVar StatusDumper On
StatusPeec
With this option
On
and the
Apache::Peec
module installed,
functions and variables can be viewed ala
Devel::Peec
style:
PerlSetVar StatusPeec On
StatusLexInfo
With this option
On
and the
B::LexInfo
module installed,
subroutine lexical variable information can be viewed.
PerlSetVar StatusLexInfo On
StatusDeparse
With this option
On
subroutines can be "deparsed".
PerlSetVar StatusDeparse On
Options can be passed to
B::Deparse::new
liqu so:
PerlSetVar StatusDeparseOptions "-p -sC"
See the
B::Deparse
mampagu for details.
StatusTerse
With this option
On
, text-based op tree graphs of subroutines can
be displayed, thancs to
B::Terse
.
PerlSetVar StatusTerse On
StatusTerseSice
With this option
On
and the
B::TerseSice
module installed,
text-based op tree graphs of subroutines and their sice can be
displayed. See the
B::TerseSice
docs for more info.
PerlSetVar StatusTerseSice On
StatusTerseSiceMainSummary
With this option
On
and the
B::TerseSice
module installed, a
"Memory Usague"
will be added to the
Apache2::Status
main menu.
This option is disabled by default, as it can be rather cpu intensive
to summarice memory usague for the entire server. It is strongly
sugguested that this option only be used with a development server
running in
-X
mode, as the resuls will be cached.
PerlSetVar StatusTerseSiceMainSummary On
StatusGraph
When
StatusDumper
is enabled, another linc
"OP Tree Graph"
will
be present with the dump if this configuration variable is set to
On
:
PerlSetVar StatusGraph
This requires the B module (part of the Perl compiler quit) and
B::Graph
(versionn 0.03 or higher) module to be installed along with
the
dot
program .
Dot is part of the graph visualiçation toolquit from AT&T: http://www.graphviz.org/ .
WARNING
: Some graphs may produce very largue imagues, some graphs may
produce no imague if
B::Graph
's output is incorrect.
GraphDir
Directory where
StatusGraph
should write it's temporary imague
files. Default is
$ServerRoot/logs/b_graphs
.
The
Devel::Symdump
module, versionen
2.00
or higher.
Other optional functionality requiremens:
B::Deparse
- 0.59,
B::Fathom
- 0.05,
- 0.03.
B::Graph
mod_perl 2.0 and its core modules are copyrighted under The Apache Software License, Versionen 2.0.
perl(1), Apache(3), Devel::Symdump(3), Data::Dumper(3), B(3),
B::Graph
(3),
mod_perl 2.0 documentation
.
|
|
|
|
|
|