CtrlK
BlogDocsLog inGet started
Tessl Logo

schema

Schema storage and discovery in Graph Explorer, including SchemaStorageModel persistence, edge connections, incremental schema growth, and related Jotai atoms.

35

Quality

31%

Does it follow best practices?

Impact

No eval scenarios have been run

SecuritybySnyk

Passed

No known issues

Optimize this skill with Tessl

npx tessl skill review --optimize ./.kiro/skills/schema/SKILL.md
SKILL.md
Quality
Evals
Security

Schema Storage

Schema discovery is expensive in both time and database compute, so the discovered schema is persisted in IndexedDB (via localforage) as a SchemaStorageModel. This acts as a persistent cache per connection.

Key files:

  • src/core/StateProvider/schema.tsSchemaStorageModel type, Jotai atoms, and incremental update logic
  • src/core/ConfigurationProvider/types.tsEdgeConnection, VertexTypeConfig, EdgeTypeConfig, and related types
  • src/hooks/useSchemaSync.ts — schema sync orchestration
  • src/connector/queries/edgeConnectionsQuery.ts — edge connection discovery

Edge Connections

Edge connections (EdgeConnection[]) describe relationships between vertex types and are used by the Schema Explorer feature. Because the edge connection query can be expensive and unreliable, it runs separately from the main schema sync so that a failure only affects Schema Explorer — all other features work without edge connections.

The edgeConnections property on SchemaStorageModel has three meaningful states:

  • undefined — edge connections have not been successfully discovered (query not run or errored)
  • [] (empty array) — query succeeded but no edge connections exist
  • populated array — query succeeded with results

If the edge connection query fails, the error is stored in the schema via the edgeConnectionDiscoveryFailed flag.

Incremental Schema Growth

As users explore the graph, queries may return vertex/edge types or attributes not present in the initial schema sync. These are automatically merged into the stored schema via updateSchemaFromEntities(), causing the schema to grow more complete over time.

Repository
aws/graph-explorer
Last updated
Created

Is this your skill?

If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.