KamoCRM

File a message's search-index row and lead link under its thread id, not the conversation row's surrogate

FixEmailService
Shipped
October 12, 2026 at 3:46 AM UTC
Author
Kamo
Commit
b8a8c93

conversations.thread_id is generated (@GeneratedValue on ConversationEntity, primary key the thread id alone), so the row **************** returns carries a random id while thread_messages holds the thread's UUIDv5 of its root Message-ID. The push indexer and the bulk sync passed that surrogate to search_index and the lead link, so the EMAIL_THREAD disclosure label (KamoCollab CP05 spec §5.3), which reads a thread's From/To/Cc from search_index by the thread_messages id, found no rows: the sender and every addressee fell out of its participants and external parties. Found live by CP05 Task 40 in sp00verify. ConversationService.threadIdOf names the one thread id; MessageIndexer and SyncController use it for the search index and the lead link. MessageIndexerThreadIdTest pins it (red before: search_index got the surrogate).

All changes

Like what you see shipping?

All of it arrives in your workspace on its own. Start on the free plan and read this page again in a month.

Start Free ForeverView Pricing