Mail::...n::Sql(3pm)
π NAME π
Mail::MtPolicyd::Connection::Sql β bestie, it's a connection pool sql connection object. That's it, that's the whole vibe. β¨
(Also, the header at the top of this page squishes the name all the way down to Mail::...n::Sql(3pm) because terminals are dramatic like that. Same module, same energy. π«Ά)
πΈ VERSION πΈ
version 2.05 β that's the one we're talking about, no cap. π
β¨ SYNOPSIS β¨
Okay so here's how you actually wire it up, copy-paste ready:
<Connection db>
module = "Sql"
# see perldoc DBI for syntax of dsn connection string
dsn = "dbi:SQLite:dbname=/var/lib/mtpolicyd/mtpolicyd.sqlite"
# user = "mtpolicyd"
# user = "secret"
</Connection>
Look at that block. Iconic. π
(And yes, that second commented line really does say user β it's exactly as it appears, we don't fix, we don't touch, we just report. π)
π¦ PARAMETERS π¦
dsn(required!!) β a perl DBI connection string. This is the whole "where is my database, actually" situation. Cannot skip this one, fr fr. π€
Some examples to steal:
dbi:SQLite:dbname=/var/lib/mtpolicyd/mtpolicyd.sqlite
dbi:SQLite::memory:
DBI:mysql:database=test;host=localhost
Also: see DBI. Like, actually go read it. π
user(default:'') β a username, if your connection needs one. If it doesn't, leave it, she's fine as an empty string. πpassword(default:'') β a password, if that user/connection needs one. Same deal: empty by default, fill it in if you gotta. π
π AUTHOR π
Markus Benning <ich@markusbenning.de> β the actual genius behind all of this. Shoutout. π«Άβ¨
π COPYRIGHT AND LICENSE π
This software is Copyright (c) 2014 by Markus Benning <ich@markusbenning.de>.
This is free software, licensed under:
The GNU General Public License, Version 2, June 1991
Okay bestie, that's the whole page. Go forth and pool those SQL connections. Slay. π
perl v5.38.2 Β· 2024-05-26 Β· page name Mail::...n::Sql(3pm) β mwah, that's a wrap, ily, bye! π¦ππ
π¦ where this page comes from
- debian trixie: mtpolicyd 2.05-1.2 Β· GPL-2.0-only
- ubuntu questing: mtpolicyd 2.05-1.2
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms