fix: address message audit review findings
This commit is contained in:
@@ -17,9 +17,6 @@ CREATE TABLE IF NOT EXISTS channel_actors (
|
||||
UNIQUE (tenant_key, channel, external_actor_id)
|
||||
);
|
||||
|
||||
CREATE INDEX IF NOT EXISTS idx_channel_actors_lookup
|
||||
ON channel_actors (tenant_key, channel, external_actor_id);
|
||||
|
||||
-- ============================================================
|
||||
-- 2. Channel Conversations
|
||||
-- ============================================================
|
||||
@@ -36,9 +33,6 @@ CREATE TABLE IF NOT EXISTS channel_conversations (
|
||||
UNIQUE (tenant_key, channel, external_conversation_id)
|
||||
);
|
||||
|
||||
CREATE INDEX IF NOT EXISTS idx_channel_conversations_lookup
|
||||
ON channel_conversations (tenant_key, channel, external_conversation_id);
|
||||
|
||||
-- ============================================================
|
||||
-- 3. Messages
|
||||
-- ============================================================
|
||||
@@ -75,7 +69,7 @@ CREATE INDEX IF NOT EXISTS idx_messages_tenant_conv_created
|
||||
|
||||
-- Index for correlation lookups
|
||||
CREATE INDEX IF NOT EXISTS idx_messages_correlation
|
||||
ON messages (correlation_id);
|
||||
ON messages (tenant_key, correlation_id);
|
||||
|
||||
-- ============================================================
|
||||
-- 4. Extend turns table
|
||||
|
||||
Reference in New Issue
Block a user