We have a chat feature in our rails app where users can talk to each other.
This is done using Actioncable, and a basic messages
and inboxes
schema structure, where:
- Each unique conversation between 2 participants has its own
inbox_id
, and all messages sent by users to another user reside in thatinbox_id
. - In the
messages
table, which holds the records of every message, we have aread
column (which is currently unused).
We want to implement a way for our system to know if messages have been read by a specific user, but we're not entirely sure what the best method to facilitate this might be. We're unsure on how we should go about designing this exactly.