Re: [phpgrabcomics-announce] PostgreSQL backend support
Brought to you by:
baravalle
From: Jim W. <jw...@ma...> - 2006-09-21 03:25:06
|
> I have not done any tests recently, but I remember an awful performance= > decrease with the PEAR database abstraction layer. I'm not too sure about PEAR; I've used database abstractions in every PHP system I ever built. I've never seen too much of a problem. I have heard various reviews about PEAR, most of them bad. > I have used the phplib abstraction layer for a long, long time, but I > have needed it only once since 2000, to reuse some code that was used > for an oracle db in mysql... The problem with phplib is that is > unmantained and unsopported. Well, if we're looking to put in new things, probably doesn't make much sense to stick unmaintained code in there. > A rapid googling gave me this page on abstraction layers for databases:= > http://phplens.com/lens/adodb/ > > I haven't checked the code of the testing, but the web page reports a > 40% overhead with phplib and 154% using PEAR... Looking at their test, it's important to look at those results and how they apply to phpGrabComics. They show a decent slowdown in pages / second. Do those statistics meaningfully apply to this project? I don't know how most people use it, but I doubt there's that much load. I also don't know much about these abstraction layers... I wouldn't be too surprised if they were garbage. PHP is a dumpy little language: great for small scripting jobs, bad for large projects. It encorages some pretty bad code. >> I know *of* PEAR, though I haven't ever used it. I'll grab the code a= nd >> take a look. I do respect your wish to use PEAR for parts of the >> project; I'll see what I can do. >=20 > I do not like PEAR too much. It's quite slow. On the other hand, > phpGrabComics is already using PEAR, and is using caching techniques > (jpcache). >=20 > Have you got any alternatives in mind? The main requirement is not to > have to use any "exotic" module (e.g. dbx), because users can't often > have them in shared hostings I was just going to roll my own (easy to get that on shared hosting:). I've written these things a few times before; hating MySQL and liking PostgreSQL has sure gotten me my share of "well if you want it, do it yourself." It won't take long, as I already have much of this code lying around. If it's slow, I'll look into something else. I don't think we'll find that that's the case, however. Hey: can't hurt to try, right? --=20 Jim Wyllie Master's Student IRG Lab, Dept. of EE and CS Ohio University |