Skip to content

perf: support fastpath in dbauthz GetLatestWorkspaceBuildByWorkspaceID - #21047

Merged
cstyan merged 5 commits into
mainfrom
callum/workspace-build-fastpath
Dec 9, 2025
Merged

cstyan merged 5 commits into
mainfrom
callum/workspace-build-fastpath

Conversation

@cstyan

@cstyan cstyan commented Dec 1, 2025

Copy link
Copy Markdown
Collaborator

This PR piggy backs on the agent API cached workspace added in #20662 to provide a fast path for avoiding GetWorkspaceByID calls in GetLatestWorkspaceBuildByWorkspaceID via injection of the workspaces RBAC object into the context. We can do this from the agentConnectionMonitor easily since we already cache the workspace.

rbac object in context

Signed-off-by: Callum Styan <callumstyan@gmail.com>
Signed-off-by: Callum Styan <callumstyan@gmail.com>
Signed-off-by: Callum Styan <callumstyan@gmail.com>
Signed-off-by: Callum Styan <callumstyan@gmail.com>
@cstyan cstyan mentioned this pull request Dec 4, 2025
16 tasks done
Comment thread coderd/agentapi/cached_workspace.go Resolved
Signed-off-by: Callum Styan <callumstyan@gmail.com>
@cstyan
cstyan merged commit 27c3ec0 into main Dec 9, 2025
25 checks passed
@cstyan
cstyan deleted the callum/workspace-build-fastpath branch December 9, 2025 23:53
@github-actions github-actions Bot locked and limited conversation to collaborators Dec 9, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants