Replace file-based route metadata with a Revision informer

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

Los mantenedores suelen responder en 4 días

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
5/5
Tiempo estimado
Más de una semana
Aptitud para principiantes
25/100
Tipo de issue
Refactorización
Claridad
Bastante claro
Estado de actividad
Activo
Stack tecnológico
kubernetes, rust

Línea de trabajo

Start by tracing how fiber-router currently reads the lampyr-routes ConfigMap and polls its directory, then inspect the related work in #21, #22, and #61. The issue does not name source files or tests, so first locate the router's route source, Revision conversion, readiness acknowledgement, and Fiber pool handling. Done means replacing file polling with an informer-backed cache, preserving local development, readiness, and pool behavior, and covering the listed informer and identity cases.

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

Descripción

Problem

fiber-router currently reads one JSON file per Revision from the lampyr-routes ConfigMap volume and reloads the directory every 500 ms. This keeps the router away from the Kubernetes API, but it introduces polling, duplicate file identities, stale files, and failure handling for projected filesystem state.

#21 and #61 harden this path so one invalid file does not block unrelated routes. That is useful during the transition, but it does not remove the underlying synchronization layer. #22 also identifies collisions in the file and pool keys.

Proposed direction

Replace the projected route files with an informer-backed cache of Knative Revisions:

  • watch only the Revision data needed by fiber-router;
  • derive execution mode, timeout, routing state, and identity through shared conversion and validation logic;
  • update or remove one cached Revision without blocking unrelated Revisions;
  • use structured, collision-free namespace and Revision identities;
  • release affected Fiber pools when a Revision is removed or no longer routed; and
  • keep local development behind the same route-source interface without requiring Kubernetes.

The router will need narrowly scoped RBAC to list and watch Revisions. The design must document that security trade-off before implementation.

Readiness

Replace the current ConfigMap version acknowledgement. The Revision reconciler must be able to confirm that the router observed the required state without waiting for Revision Ready and creating a readiness cycle.

Completion criteria

  • The lampyr-routes ConfigMap, volume, and polling loop are removed.
  • Add, update, delete, and routing-state changes update the router cache and Fiber pools correctly.
  • One invalid Revision does not block unrelated Revisions.
  • Readiness confirms the router observed the expected Revision version without a cycle.
  • Local development uses the same route-source abstraction.
  • Tests cover informer restart, relist, deletion, invalid objects, and collision-free identities.

Follow-up to #21, #22, and #61.

Lenguaje dominante
Rust
Estrellas
3
Forks
2
Merge medio
3 d 57 min
PR fusionados (30 d)
17

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 hyperlight-dev/lampyr

Todos los issues de hyperlight-dev/lampyr

Issues similares

Más issues de Rust

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.