8000 perf: skip page cache allocation for in-memory databases · Issue #274 · project-minigraf/minigraf · GitHub
[go: up one dir, main page]

Skip to content

perf: skip page cache allocation for in-memory databases #274

Closed

Description

@adityamukho

Problem

OpenOptions::page_cache_size is respected even when opening an in-memory database via open_memory(). The PageCache struct is allocated at full capacity (default 256 pages = 1MB), but all reads hit RAM directly — the cache is never useful and wastes heap.

Proposed fix

In Minigraf::in_memory_with_options, ignore page_cache_size and allocate a zero-capacity 9B8E PageCache (or skip allocation entirely). The MemoryBackend does not go through the page cache path, so this is a safe no-op change with no semantic impact.

Acceptance criteria

  • In-memory databases do not allocate the page cache regardless of page_cache_size.
  • OpenOptions::page_cache_size is documented as file-backed only.
  • Existing in-memory tests pass unchanged.

Activity

  1. added this to the 2.0 milestone on May 19, 2026
  2. modified the milestones: 2.0, v1.3.0 on Jun 28, 2026
  3. added a commit that references this issue on Aug 23, 2026
    33423fa
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    performanceBenchmark performance regressions

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      0