docs::a...he2::MPM(3)
πΈ NAME πΈ
okay so bestie, this page is docs::a...he2::MPM(3), and it comes from the User Contributed Perl Documentation β¨. The main character here is Apache2::MPM β the Perl API for accessing Apache MPM information π
.
π Synopsis π
use Apache2::MPM ();
# check whether Apache MPM is threaded
if (Apache2::MPM->is_threaded) { do_something() }
# which mpm is used
my $mpm = lc Apache2::MPM->show;
# query mpm properties
use Apache2::Const -compile => qw(:mpmq);
if (Apache2::MPM->query(Apache2::Const::MPMQ_STATIC)) { ... }
π¦ Description π¦
so like, Apache2::MPM provides the Perl API for accessing Apache MPM information. That's the whole vibe β MPM info, but make it Perl π«Ά.
π API π
Apache2::MPM provides the following functions and/or methods, bestie:
π "query" π
Query various attributes of the MPM β¨
my $query = Apache2::MPM->query($const);
- obj:
$class("Apache2::MPM class") β the class name. - arg1:
$const("Apache2::Const :mpmq group constant") β The MPM attribute to query. - ret:
$query(boolean) β the result of the query. - since:
2.0.00
For example to test whether the mpm is static:
use Apache2::Const -compile => qw(MPMQ_STATIC);
if (Apache2::MPM->query(Apache2::Const::MPMQ_STATIC)) { ... }
π¦ "is_threaded" π¦
Check whether the running Apache MPM is threaded π
my $is_threaded = Apache2::MPM->is_threaded;
- obj:
$class("Apache2::MPM class") β the class name. - ret:
$is_threaded(boolean) β threaded or not. - since:
2.0.00
Note that this functionality is just a shortcut for:
use Apache2::Const -compile => qw(MPMQ_IS_THREADED);
my $is_threaded = Apache2::MPM->query(Apache2::Const::MPMQ_IS_THREADED);
π "show" π
What mpm is used π₯
my $mpm = Apache2::MPM->show();
- obj:
$class("Apache2::MPM class") β the class name. - ret:
$mpm(string) β the name of the MPM. e.g.,"Prefork". - since:
2.0.00
π See Also π
mod_perl 2.0 documentation. β go peek at that, bestie π
π Copyright π
mod_perl 2.0 and its core modules are copyrighted under The Apache Software License, Version 2.0.
π Authors π
The mod_perl development team and numerous contributors.
mwah π this cutie is from perl v5.42.3, dated 2023-10-21, and the page is docs::a...he2::MPM(3) β¨π«Ά
π¦ where this page comes from
- nixos 26.05: mod_perl 2.0.13
- nixpkgs unstable: mod_perl 2.0.13
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms