Skip to content

Fix PebbleDB v1.1.5 upgrade compatibility#400

Open
jeremyhahn wants to merge 1 commit into
lni:masterfrom
jeremyhahn:fix/pebble-upgrade
Open

Fix PebbleDB v1.1.5 upgrade compatibility#400
jeremyhahn wants to merge 1 commit into
lni:masterfrom
jeremyhahn:fix/pebble-upgrade

Conversation

@jeremyhahn

Copy link
Copy Markdown

Upgrades PebbleDB from v1.0.0 to v1.1.5 to fix critical crash bug in table cache cleanup that causes nil pointer dereference.

Changes:

  • Update go.mod dependencies for PebbleDB v1.1.5
  • Implement missing VFS methods required by new PebbleDB version:
    • Fd() returns invalid fd (-1) as lni/vfs doesn't expose descriptors
    • OpenReadWrite() for read/write file access
    • Preallocate() no-op (optimization hint not supported by lni/vfs)
    • Prefetch() no-op (optimization hint not supported by lni/vfs)
    • SyncData() delegates to Sync()
    • SyncTo() delegates to Sync() for full file sync
  • Add proper error handling and code formatting
  • All methods maintain compatibility with lni/vfs interface

I believe this addresses the following related items:
#343
#337
#341

Upgrades PebbleDB from v1.0.0 to v1.1.5 to fix critical crash bug in
table cache cleanup that causes nil pointer dereference.

Changes:
- Update go.mod dependencies for PebbleDB v1.1.5
- Implement missing VFS methods required by new PebbleDB version:
  - Fd() returns invalid fd (-1) as lni/vfs doesn't expose descriptors
  - OpenReadWrite() for read/write file access
  - Preallocate() no-op (optimization hint not supported by lni/vfs)
  - Prefetch() no-op (optimization hint not supported by lni/vfs)
  - SyncData() delegates to Sync()
  - SyncTo() delegates to Sync() for full file sync
- Add proper error handling and code formatting
- All methods maintain compatibility with lni/vfs interface

The upgrade resolves the production crash while maintaining full
compatibility with dragonboat's existing VFS abstraction.
@jeremyhahn

Copy link
Copy Markdown
Author

What do we need to do to get this merged in? The pebble version used by dragonboat is extremely outdated and causing build problems for projects also using Pebble.

@gladkikhartem

Copy link
Copy Markdown
  • Right now on-disk example is not usable because of this issue

@biskit

biskit commented Feb 18, 2026

Copy link
Copy Markdown

it will be nice to have this officially merged into v4 branch along with #398

not sure what the hold up is, unless @lni or @kevburnsjr wants to make an official v4 release soon...

i'm running my own set of local patches, not as clean as this one so prefer something right from the repo

@gladkikhartem

Copy link
Copy Markdown

Can we merge this?

@kevburnsjr

Copy link
Copy Markdown
Contributor

@biskit I can't make releases. I'm not a maintainer. Just a user.

@hertzcodes

Copy link
Copy Markdown

@lni it would be nice if you merged this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants