[C API] Versioned, documented compatibility for the save/load stream format

Abierto
#426 0 comentarios 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 5 días

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
5/5
Tiempo estimado
Más de una semana
Aptitud para principiantes
18/100
Tipo de issue
Nueva funcionalidad
Claridad
Bastante claro
Estado de actividad
Activo
Stack tecnológico
c, cpp
Área
api, backend

Línea de trabajo

Start with svs_get_version() in bindings/c/src/svs_c.cpp (line 69) and the save_version field in dynamic_index.h, which is currently 0.0.0. Trace svs_index_save_stream and svs_index_load_stream_dynamic to see where a format version would go in the stream header. Done means a format version is written and readable without loading the index, and a mismatched stream returns an error rather than crashing. The compatibility contract also needs a decision from maintainers before code work starts.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

Summary

Please version the byte stream produced by svs_index_save_stream and consumed by svs_index_load_stream_dynamic, independently of the C API version, and document which versions a given release can load.

Why

valkey-search embeds the SVS stream in its RDB files. Users upgrade the module (and so SVS) in place, and replicas can briefly run a different build from the primary. Today the only version available to us is svs_get_version(), the C API version (bindings/c/src/svs_c.cpp:69); the serialized save_version in dynamic_index.h is 0.0.0. So we can't tell "same format, newer library" from "incompatible format", and have to either reject every RDB after any SVS bump or risk loading an incompatible stream.

Ask

  1. A format version in the stream header, and a C API call to read it from a stream without loading the index, or to report it from a handle.
  2. A compatibility contract: a release can load streams written by earlier releases within the same major format version, and fails cleanly (an error, not a crash) on a stream it can't load.
  3. Release notes that call out format version changes.

Consumer context

valkey-search (ALGORITHM SVS_VAMANA), C API submodule pinned at 8285340. Today vector_svs.cc rejects any svs_get_version() mismatch on load. With a format version we can accept compatible streams and rebuild from the keyspace otherwise.

Lenguaje dominante
C++
Estrellas
241
Forks
48
Merge medio
4 d 21 h
PR fusionados (30 d)
11

Preparar el entorno

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de intel/ScalableVectorSearch

Todos los issues de intel/ScalableVectorSearch

Issues similares

Más issues de C++

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.