>Thanks, Rich, I''m happy to help.
> If I use BLOB, I have to make a lot of change to my code. Therefore, I have > to persist it as String. I used base64 to encode and decode the byte[] into > String. Because I resize the images to small ones. I use a VARCHAR length > about 10k~20k to persist the String. Thats fine, if you don't want to do a hugh code change then keep it the same > "How often do you need to load all 300 images? If it is forum style I > would imangine a limited number of posting per page say max 20. So > the would be a maximum of 20 images per page load." > If this is true, which method is the best among the above three? Which method is 'best' depends on what you want. For fast access and low memory - persist to hard drive > "If you must use the least amount of memory as possible, persist the > images to the hard drive and store the file reference to the url in > the database. " > If I want to persist images to the hard drive of server. Shall I persist the > data inside WAR or outside? Because user can change their portrait, does it > mean it must be persisted outside WAR? No just make a base dir in your app called 'userAvatar' or something similar. Then persist the image as user_xxxx.gif (xxxx = the user id). When they chage their image override the file. Also as stated by Pawel, make sure you have a performance problem before you try to solve a performance problem. > -- > View this message in context: > http://www.nabble.com/Performance-issue-with-large-data%28such-as-images%29-tp23945029p23948048.html > Sent from the Struts - User mailing list archive at Nabble.com. > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: user-unsubscr...@struts.apache.org > For additional commands, e-mail: user-h...@struts.apache.org > > --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscr...@struts.apache.org For additional commands, e-mail: user-h...@struts.apache.org