Provide a way to check the resourceVersion of a specific informer in multiNamespaceInformer

Abierto
#3,607 2 comentarios 1 reacción 1 asignado Ver en GitHub

Los mantenedores suelen responder en 1 día

@sbueringer ya está trabajando en esto.

Desde el 12/10/2026.

Evaluación

Dificultad
4/5
Tiempo estimado
3-5 días
Aptitud para principiantes
48/100
Tipo de issue
Nueva funcionalidad
Claridad
Bastante claro
Estado de actividad
Activo
Stack tecnológico
go

Línea de trabajo

Start by tracing GetInformerForKind and GetInformer through multiNamespaceInformer, then compare its behavior with SharedIndexInformer and getStore().LastStoreSyncResourceVersion(). Define a public way to retrieve the resourceVersion for the relevant underlying namespace store, and verify it against the Cluster API use case without relying on reflection.

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

Descripción

For a regular informer it's possible to check the RV in the following way:

  • GetInformerForKind / GetInformer returns an Informer
  • type cast the informer to SharedIndexInformer
  • call getStore().LastStoreSyncResourceVersion())

With a multiNamespaceCache it's not possible

  • GetInformerForKind / GetInformer returns an Informer (implemented by multiNamespaceInformer)
  • multiNamespaceInformer is neither a SharedIndexInformer nor has it any other way to retrieve the last resourceVersion from the right underlying store

I've hit this issue in Cluster API and for now the only possible workaround that I've found was to use reflection. xref: https://github.com/kubernetes-sigs/cluster-api/pull/14283

We'll probably look into this when we make the ReadYourWritesConsistency (https://github.com/kubernetes-sigs/controller-runtime/issues/3320) feature work with multiNamespaceCache/multiNamespaceInformer

Lenguaje dominante
Go
Estrellas
3k
Forks
1.3k
Merge medio
1 d 7 h
PR fusionados (30 d)
48

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 kubernetes-sigs/controller-runtime

Todos los issues de kubernetes-sigs/controller-runtime

Issues similares

Más issues de Go

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.