Implement per-user message cache for SED

Fixes #23
Fixes #24
Merge branch 'master' into feature/23
Replace most recent message

Replace FIFO with LIFO to apply SED to most recent message