Skip to content

Add Prune API skeleton#376

Open
zipdoki wants to merge 2 commits into
feat/prune-metadatafrom
feat/prune-api
Open

Add Prune API skeleton#376
zipdoki wants to merge 2 commits into
feat/prune-metadatafrom
feat/prune-api

Conversation

@zipdoki

@zipdoki zipdoki commented Jun 7, 2026

Copy link
Copy Markdown
Contributor

Summary

This implements API skeleton for pruning the edges.

One endpoint covers every prunable structure (CACHE now, GROUP later):
POST /graph/v3/databases/{database}/tables/{table}/edges/prune

$ curl -X POST "https://.../graph/v3/databases/mydb/tables/mytable/edges/prune" \
  -H "Content-Type: application/json" \
  -d '{
    "type": "cache",
    "targets": [
      { "start": "user:1001", "direction": "OUT" }
    ]
  }'

{
  "results": [
    {
      "start": "user:1001",
      "direction": "OUT",
      "cache": "permission_created_at_desc",
      "status": "PRUNED"
    }
  ]
}

Part of #322.

Changes

  • Add prune payloads to core.edge.payload
  • Add POST .../edges/prune to EdgeMutationController
  • Add EdgeCachePruneSpec (engine) and EdgeCachePruneE2ETest (server); behavior cases disabled until the data plane lands

How to Test

./gradlew :engine:test --tests "*.EdgeCachePruneSpec" :server:test --tests "*.EdgeCachePruneE2ETest"

AI Assistance

  • This PR was written largely with AI assistance.
    • Tool / model: Claude Code (Opus 4.8)

@zipdoki zipdoki self-assigned this Jun 7, 2026
@zipdoki zipdoki requested a review from em3s as a code owner June 7, 2026 14:02
@dosubot dosubot Bot added the size:M This PR changes 30-99 lines, ignoring generated files. label Jun 7, 2026
@zipdoki zipdoki removed the request for review from em3s June 7, 2026 14:02
@dosubot dosubot Bot added the enhancement New feature or request label Jun 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request size:M This PR changes 30-99 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant