Are custom post types suitable for storing high numbers of data elements, in this case chat messages?

As far as I can see, the main problem you might have to deal with is having to store a fairly large amount of chat messages.

So to avoid making WP core functionalities querying post and postmeta from large amount of rows generated by your single functionality, it seems obvious to me you’d better create a custom table.

I believe this would also offer to you the possibility to optimize your table’s structure for your specific usage which would result in faster queries.

At this time, WP postmeta queries get very slow generally speaking, when they have to deal with a large amount of rows.
Look at the problem WooCommerce actually has when dealing with over 100k products which they store as post and postmeta. They’re on the way of fixing this by migrating all the products inside custom tables…

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)