Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask
 
PerlMonks  

PostgreSQL for stored Perl procedures

by Aighearach (Initiate)
on Mar 29, 2002 at 01:01 UTC ( [id://155167]=note: print w/replies, xml ) Need Help??


in reply to Perl and Databases

I use PostgreSQL, for a few reasons: Excellent performance and scalability, good transactions, and easy to extend. My favorite thing is the Perl integration.

PostgreSQL supports an interpretted language called PL/Perl for writing stored procedures. What this is, is a perl interpretter running inside the plperl module, running the stored Perl inside a Safe.pm sandbox. The nice thing is, it's all open source, so you just edit the PL/Perl source to add functions to what can be used in the sandbox. Then, you can let the database itself dispatch your code for you. This is nice for a few reasons:

  • It moves database related processes off of your web/other servers, and places them on your database server. There is no good reason for large database accesses to slow down a website if you have seperate servers for them, but this is often the case.
  • It allows you to change your Perl database code without touching the clients. So if you have 34 servers accessing your database server, you only change the code in 1 place. (unless you're changing the agreed schema)
  • It allows for a higher level of specialization for each piece of code, encouraging the practice of building a system out of small bricks with well defined tasks.

--
Snazzy tagline here ### Changlog ### # 1061536574: fix mispelling of "Perl" (was "perl")

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://155167]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others perusing the Monastery: (5)
As of 2024-03-29 08:49 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found