I have never used uploading feature in JSF, but now I have to. I have couple of questions and they are like "for dummies" series questions. So:
1) Logged in users' pictures to DB or to filesystem of server?
2) If to server relative or fixed path or root url to db/properties and relative part to db too?
3) If to DB, how is the performance when using JPA2 + Mysql? Any cons otherwise?
4) If using server, is it secure to add new context for images to server.xml and use images from the address www.examble.com/imagesfolder/images.jpg? How to avoid the situation that everyone can see the pictures?
5) What is the best way to handle uploading? I am using Primefaces, is it good for that purpose or something else?
6) Any good tutorial or examples how to do this like a pro :)?
7) How to avoid situation that there might be files with a same name? Hashing the names or?
8) What if (really big if) I decide to share my application to two physical servers, problems with paths to pictures?
9) In my case, I have pictures, which are common to everyone and pictures "owned by logged in users. How would you implement this and why if you know that I am using Primefaces, JPA2 and Mysql and I have unlimited space in the server?
10) Very nice and hot summer to everyone!!
Sami