[geaflow/ai-memory] Define `GraphBackend` SPI
- Dominant language
- Java
- Stars
- 808
- Forks
- 188
- Avg merge
- 3d 22h
- Merged PRs (30d)
- 2
Description
Priority: P0
Difficulty: Advanced
Context: Current main path uses in-process `MemoryGraph`; `GraphComputeEngine` is an empty interface. Phase 1 needs a backend boundary so local persistence and a GeaFlow vertical slice can share contracts.
Scope:
- Define `GraphBackend` interface for upsert vertex, upsert edge, delete, scan, get schema, and transaction boundary.
- Define capability flags: local, persistent, distributed, supports checkpoint, supports tenant scope.
- Add contract tests using an in-memory fake backend.
Constraints:
- Do not replace `MemoryGraph` everywhere in this issue.
- Do not claim distributed production capability.
- Public SPI needs maintainer review.
Acceptance Criteria:
- A fake backend passes contract tests.
- Existing `GraphAccessor` integration path can be adapted later without breaking tests.
Suggested paths:
- `geaflow-ai/src/main/java/org/apache/geaflow/ai/backend`
Contributor guide
Research direction
Start in geaflow-ai/src/main/java/org/apache/geaflow/ai/backend and read the empty GraphComputeEngine interface alongside the current in-process MemoryGraph path. Define the GraphBackend contract and capability flags, then add contract tests with an in-memory fake backend. Done means the fake passes the contracts while existing GraphAccessor integration remains unchanged.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- backend-api-design, distributed-systems
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100