It's totally cool -- I enjoy the debate.  I was trying to imply that the 
previous discussion was in the list archives, not that my suggestion was 
the One True Way(tm).

The 10% performance hit isn't that huge, but I've got a gut feeling that 
that cost will increase as the size of the database gets really large.  
I could totally be wrong, but it would be an interesting thing to test.  
Grab the Flickr Auto-Downloader and let it run all weekend -- then see 
how MySQL likes seeking out records from 60GB of images.

The thing that bothers me isn't necessarily having the database store 
the images, but how you handle the number of connections to the database 
under load.  Apache is very good at handling a ton of connections, and 
serving even large data streams to a large group of connected users.  
MySQL has performed well for me under a resonable load (2-2.5M 
pageviews/day) with no external caching when selecting small sets of 
data (1-2k) from small, well-indexed tables.

I'm really curious to know whether or not you'll start running out of 
thread or connections when the datasets returned are much larger, and 
last for longer periods of time.  A 750k - 1.5MB JPEG would be a good 
baseline, if you want to store something of sufficient quality to 
print.  That's a pretty big undertaking, especially generating a 
significant amount of load (unless it crashes and burns easily).

-Jeromie

>Personally, I also think the code is cleaner and more easily  
>understood -- it sure is easier to encapsulate if you don't have  
>implementation details "leaking" into the file system! From a  
>cohesion and coupling point of view, images in the actual record are  
>closer to "normal form" than having references to files, which  
>essentially represents a de-normalization of the design. Certainly,  
>if you ever have to move the entire thing, having one database is a  
>joy, compared to hunting down various bits and pieces. (And for any  
>largish file-based design, there will be many directories and  
>complicated hashing to keep track of them -- keeping gazillions of  
>images in one directory is CERTAINLY a performance disaster!)
>
>Images in files make sense for a lot of people -- perhaps most of  
>them! I only objected to the "it's been discussed many times" with  
>the implied consensus that images in files are universally "better"  
>in all possible situations.
>
>:::: We need an energy policy that encourages consumption. -- George  
>W. Bush
>:::: Jan Steinman <http://www.Bytesmiths.com/Item/99BD07>
>
>
>
>
>The php_mysql group is dedicated to learn more about the PHP/MySQL web 
>database possibilities through group learning.  
>Yahoo! Groups Links
>
>
>
> 
>
>
>  
>



The php_mysql group is dedicated to learn more about the PHP/MySQL web database 
possibilities through group learning.  
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/php_mysql/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 


Reply via email to