database - Store multimedia fileuploads through a webapp -
i'm developing webapp based on spring hibernate , want utilize mysql database store multimedia files through fileupload mechanism. don't know best way it, mean, can store files database directly? or have maintain reference in database , store files in filesystem?
i'm thinking in sec approach don't know how desing model database. have user profile, , ever user can store differents files photos, music or videos. i'm thinking in entity user related entity multimediaalbum n n relationship. mean have 3 tables (user, multimediaalbum, , relationship table).
futhermore, want create accesible these multimedia files through web services, need link these files. , finally, don't know store these files in filesystem.
thank much responses.
check out post storing files blobs in mysql: how store .pdf files mysql blob php?
personally prefer store files uploaded in database. i've done few times, quick reasons why:
easier avoid orphaned files. if deletes file, delete database. don't have search file scheme , delete there well.
if don't security right , people upload scripts/programs, should safer have them in database instead of on file scheme of server. (although i'm sure creative people can still harm file in database.)
database web-applications file-upload filesystems store
No comments:
Post a Comment