LevelDB, RocksDB and BoltDB support

Aberta
#2,515 0 comentários 0 reações 0 responsáveis Ver no GitHub

Mantenedores costumam responder em até 1 dia

Ninguém assumiu esta issue ainda.

Avaliação

Dificuldade
5/5
Tempo estimado
Mais de uma semana
Facilidade para iniciantes
35/100
Tipo de issue
Funcionalidade
Clareza
Razoavelmente clara
Status de atividade
Pouca atividade
Stack de tecnologia
swift
Domínio
databases

Direção de pesquisa

Start by locating the registry plugin architecture and reading how existing database integrations are organized. Then assess support for reading LevelDB and RocksDB directories, read-only access by default, byte-oriented key/value views, prefix filtering and range scans, and RocksDB column families. Done means these requirements are covered; the issue names no files or tests, so identify the relevant entry points and validation approach in the project first.

Escrita pelo modelo de indexação a partir do texto da issue.

Descrição

enhancement platform-macos
Problem

None of the embedded key-value stores LevelDB, RocksDB and BoltDB is supported, so inspecting an application's local data means writing a throwaway program. They run in-process with no server, so the only way in is to open the files, the way TablePro opens a SQLite file today. Folds in #524.

Proposed solution

A registry plugin that opens a local store:

  • Point at a LevelDB or RocksDB directory, or a BoltDB file. Read-only by default, since these formats hold a single-process lock and opening one under a running app is unsafe. When another process holds the lock, say so plainly instead of waiting on it.
  • Keys and values in the grid, with a hex and a text view, since all three stores are byte-oriented.
  • Prefix filtering and range scans, since there is no query language to fall back on.
  • The sidebar shows column families for RocksDB and buckets, nested ones included, for BoltDB. LevelDB has one flat keyspace.

Reading the files

  • LevelDB and RocksDB: link their C APIs as static libraries published through apple/Libs/, or read the on-disk format (sorted table files, the manifest and the write-ahead log, with their compression) in Swift. The C APIs are the smaller risk.
  • BoltDB (bbolt, which etcd uses) is Go only, with no C library, but its file is one B+tree of fixed-size pages, small enough to read in Swift.

Open question

Whether writes ever come after the read-only version, and for which store first.

Alternatives considered

A throwaway script per inspection.

Platform

macOS

Related database type

N/A / General

Linguagem predominante
Swift
Estrelas
6.2k
Forks
412
Merge médio
3h 56min
PRs com merge (30d)
669

Preparar o ambiente

Este projeto não oferece contêiner de desenvolvimento, Dockerfile nem guia de contribuição, então a configuração fica por sua conta: comece pelo README e veja nosso guia da primeira contribuição para os passos gerais.

Primeiros passos

  1. Leia a issue inteira e depois o guia de contribuição do projeto.
  2. Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
  3. Faça um fork do repositório e trabalhe em uma branch.
  4. Abra um pull request que referencie o número da issue.

Mais de TableProApp/TablePro

Todas as issues de TableProApp/TablePro

Issues semelhantes

Mais issues de Swift

Receba novas issues na sua caixa de entrada

Um resumo curto de issues do GitHub para quem está começando.