Remove temporary actor key version prefix

Railway has no persistent volumes so stale actors are wiped on
each deploy. The v2 key rotation is no longer needed.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Nathan Flurry 2026-03-12 22:07:51 -07:00
parent 58c695e8b4
commit 1ac2dec220

View file

@ -1,36 +1,34 @@
export type ActorKey = string[];
const ACTOR_KEY_SCHEMA_VERSION = "v2";
export function workspaceKey(workspaceId: string): ActorKey {
return ["ws", ACTOR_KEY_SCHEMA_VERSION, workspaceId];
return ["ws", workspaceId];
}
export function projectKey(workspaceId: string, repoId: string): ActorKey {
return ["ws", ACTOR_KEY_SCHEMA_VERSION, workspaceId, "project", repoId];
return ["ws", workspaceId, "project", repoId];
}
export function taskKey(workspaceId: string, repoId: string, taskId: string): ActorKey {
return ["ws", ACTOR_KEY_SCHEMA_VERSION, workspaceId, "project", repoId, "task", taskId];
return ["ws", workspaceId, "project", repoId, "task", taskId];
}
export function sandboxInstanceKey(workspaceId: string, providerId: string, sandboxId: string): ActorKey {
return ["ws", ACTOR_KEY_SCHEMA_VERSION, workspaceId, "provider", providerId, "sandbox", sandboxId];
return ["ws", workspaceId, "provider", providerId, "sandbox", sandboxId];
}
export function historyKey(workspaceId: string, repoId: string): ActorKey {
return ["ws", ACTOR_KEY_SCHEMA_VERSION, workspaceId, "project", repoId, "history"];
return ["ws", workspaceId, "project", repoId, "history"];
}
export function projectPrSyncKey(workspaceId: string, repoId: string): ActorKey {
return ["ws", ACTOR_KEY_SCHEMA_VERSION, workspaceId, "project", repoId, "pr-sync"];
return ["ws", workspaceId, "project", repoId, "pr-sync"];
}
export function projectBranchSyncKey(workspaceId: string, repoId: string): ActorKey {
return ["ws", ACTOR_KEY_SCHEMA_VERSION, workspaceId, "project", repoId, "branch-sync"];
return ["ws", workspaceId, "project", repoId, "branch-sync"];
}
export function taskStatusSyncKey(workspaceId: string, repoId: string, taskId: string, sandboxId: string, sessionId: string): ActorKey {
// Include sandbox + session so multiple sandboxes/sessions can be tracked per task.
return ["ws", ACTOR_KEY_SCHEMA_VERSION, workspaceId, "project", repoId, "task", taskId, "status-sync", sandboxId, sessionId];
return ["ws", workspaceId, "project", repoId, "task", taskId, "status-sync", sandboxId, sessionId];
}