Skip to content

Tag profile cache expires after 60s with no stale serving #185

Closed

Description

@harlan-github-agent

The tag profile handler caches for 60 seconds with swr disabled on a heavy FTS query plus per-row subqueries, so crawler sweeps recompute it continuously (SKILLD-19, SKILLD-1C, SKILLD-1H).

Target: layers/registry/server/api/tags/[slug].get.ts

Verify with: pnpm vitest run test/unit/tag-profile-cache.test.ts

Estimated to change 2 files.

The sentry-checkin routine opened this issue automatically on its 2026-09-08T20:20:00.000Z run. It is not Harlan's own report. Close it to reject the proposal, and the reason you give stops it being offered again.

Activity

  1. harlan-github-agent commented on Sep 8, 2026

    @harlan-github-agent
    ContributorAuthor

    🤖 ISSUE TRIAGE

    Harlan Agent Kit posted this automated triage. It is not Harlan's personal assessment or commitment. AI open source policy.

    • Route: Ready to implement
    • Difficulty: 2/5
    • Impact: 3/5
    • Reproduction: Yes
    • Codebase review: Not needed
    • Summary: Confirmed in layers/registry/server/api/tags/[slug].get.ts:209-216: defineCachedEventHandler uses maxAge: 60 with swr: false while the handler runs a heavy FTS query plus per-row subqueries (derivedTagCount, tagDecisionKeep, getGeneratedBat
    • Next action: In layers/registry/server/api/tags/[slug].get.ts change the cache options to swr: true with a longer maxAge, add test/unit/tag-profile-cache.test.ts asserting stale-while-revalidate serving, and run pnpm vitest run test/unit/tag-profile-cache.test.ts.
    • Fix with: Cluster endpoints recompute on 60s expiry with no stale window #182
  2. added
    harlan-agent-ready-to-implementIssue triage found bounded work ready for an implementation Agent.
    harlan-agent-runningAn Agent holds a Task on this issue or pull request right now.
    and removed
    harlan-agent-runningAn Agent holds a Task on this issue or pull request right now.
    on Sep 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions