The Messaging table index is presently set in an inflexible and fragile manner, and users paginate through messages with limit/offset. It is preferable to use a more robust auto-increment index for the table, and store a cursor in the Session struct such that pagination is deterministic (and simpler).