File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes JDBC and the fly likes image repository in DB Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


JavaRanch » Java Forums » Databases » JDBC
Bookmark "image repository in DB" Watch "image repository in DB" New topic
Author

image repository in DB

Nitin Raodeo
Greenhorn

Joined: Jul 27, 2002
Posts: 21
What are the pro and cons of storing the images in DB as compared to storing on File system of the server?
Consider a medium size internet application , with 500 concurrent users requesting for products with images.

Image sizes could vary from 10 KB to 200 KB.


1) SCJP 1.4<br />2) SCBCD (EJB 2.0)<br />3) IBM WebSphere Portal<br />4) WSAD (exam 287)
Jeanne Boyarsky
author & internet detective
Marshal

Joined: May 26, 2003
Posts: 30586
    
154

Nitin,
I would store those in the file system. If you have a web server, store them there. If not, store them on the application server.

If the users are reasonably likely to be accessing the images, you want them to link to the images. If the users could somehow search by image (by bytes or something), there would be an advantage to keeping them in the database. Another reason to keep images in a database is if they change often.


[Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Blogging on Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, OCAJP, OCPJP beta, TOGAF part 1 and part 2
 
GeeCON Prague 2014
 
subject: image repository in DB