If I wrote something in plperlu, when would that module be reloaded? Every time the function ran? The first time it ran? Does the Perl DLL get unloaded if it hasn't been used in a while, and then after that it'd be another module reload?
Asked
Active
Viewed 299 times
1 Answers
4
I think the module will be loaded once for each server process (i.e. new session / connection) on the first use of that language within that session.
You can preload them to avoid any delay on first use, per
the manual for shared_preload_libraries
and local_preload_libraries
.
Old PostgreSQL versions just had a single preload_libraries
setting; see the manual for your version if you're on something very old.

Craig Ringer
- 307,061
- 76
- 688
- 778
-
Oh...this is handy knowledge, but I think I wasn't clear, I mean *a* Perl module, i.e., one actually written in Perl, like Net::SMTP, not *the* Perl module, plperlu.dll or whatever the Perl interpreter module itself is called. – Kev Feb 18 '09 at 20:31
-
I realize I asked about the DLL too, only because I wondered if the pure-perl modules get precompiled and kept around, thus making module reloading dependent on DLL reloading. – Kev Feb 18 '09 at 20:34
-
Actually, I guess you answered the title of the question dead on. I should open a second question. Thanks! – Kev Feb 18 '09 at 20:43