Jump to content

Store Attachments in Database in Chunks


KT Walrus

Recommended Posts

When attachments are stored in the database, the whole file is inserted in one row. This row could be very large and really mess up replication, especially if using synchronous replication using the Galera replication library. Also, storing large BLOBs in MySQL requires my.cnf configuration so it would be much better for many users if IPS4 could run with MySQL defaults (and still allow storing attachments in the database).

Could you please consider "chunking" attachments into multiple rows where the default chunk size is 255KB with an admin setting to change the chunk size?

See how MongoDB's GridFS stores files in two tables: https://docs.mongodb.org/v3.0/reference/gridfs/#gridfs-chunks-collection

Also, I would like to see MongoDB as a supported storage method for files in some future version of IPS4. MongoDB is probably a better option than using most of the other supported storage methods (especially the File System or the Local Database) as MongoDB is really built to scale infinitely using multiple servers with large Block Storage available.

Finally, the list of Storage Methods should probably also include Remote MySQL Database (just like the Forums app supports Archiving to a Remote Database).

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...