campus.auth: introspection (~150-240ms POST /auth/v1/root/) on every campus.api call — cache to cut submit-path latency
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 22/100
- Issue type
- Feature
- Clarity
- Mostly clear
- Activity status
- Active
- Tech stack
- python
- Domain
- authentication, performance
Research direction
The issue concerns token introspection via POST /auth/v1/root/, called from campus.auth on every campus.api child span. Start by finding where campus.auth performs that introspection and how campus.api invokes it, then measure per-request call counts on the submit path. The issue offers two options, a short-TTL cache keyed by token hash or local verification of self-issued tokens, so the work needs a design decision first. Done means a chosen approach with a measured drop in introspection calls per journey.
Written by the indexing model from the issue text.
Description
Found by the 2026-11-24 prod classroom journey investigation.
Every campus.api child span pays a POST /auth/v1/root/ token-introspection round trip (~140–240 ms each, nested inside assignment/submission reads). Systematic product impact observed on prod:
POST /api/v1/submissions/{id}/submit: 1.8–4.4 s across 9 students (8–11 spans, each introspecting)- Assignment views with two broker calls: 2.5–3.6 s (max observed 25.8 s)
Proposal: short-TTL cache of introspection results (token-hash keyed) in campus.auth, or local verification of self-issued tokens, so a multi-span journey introspects once per token per N seconds rather than per call. Pairs with the classroom-side fix (single broker call per assignment view, filed on campus-classroom).
- Dominant language
- Python
- Stars
- 0
- Forks
- 2
- Avg merge
- 39m
- Merged PRs (30d)
- 235
Getting set up
- No Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from nyjc-computing/campus
-
enhancement for-collaborators for-contributors
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
nyjc-computing/campus#451 · 1 comment ·
Maintainers usually reply within 1 day
-
Difficulty 4/5 3-5 days Newbie friendliness 42/100
nyjc-computing/campus#1320 ·
Maintainers usually reply within 1 day
-
Difficulty 1/5 Under an hour Newbie friendliness 25/100
nyjc-computing/campus#1309 ·
Maintainers usually reply within 1 day
-
Difficulty 4/5 3-5 days Newbie friendliness 18/100
nyjc-computing/campus#1300 · 1 comment ·
Maintainers usually reply within 1 day
-
Difficulty 5/5 Over a week Newbie friendliness 5/100
nyjc-computing/campus#1295 · 4 comments ·
Maintainers usually reply within 1 day
All issues in nyjc-computing/campus
Similar issues
-
triage
Difficulty 1/5 1-3 hours Newbie friendliness 88/100
kornia/kornia-rs#1416 · 1 comment ·
Maintainers usually reply within 2 days
-
ui
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
PolicyEngine/ai-inequality#64 ·
Maintainers usually reply within 1 day
-
LinearGaussianStateSpace.dist splits states and observations wrongly when the transition varies over timePossibly taken @PabloRoque claimed this today. Open
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
pymc-devs/pymc-extras#839 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
Maintainers usually reply within 1 day