spiffe / spire-controller-manager

Kubernetes controller manager that reconciles workload registration and federation relationships.
Apache License 2.0
47 stars 36 forks source link

Do we have plans to add caching to the `listEntries` function? #301

Closed kongweiguo closed 5 months ago

kongweiguo commented 5 months ago

Currently, any change to a pod or ClusterSPIFFIEID triggers a full-scale query from spire server. I think this will cause significant pressure on the spire Server.

func (r *entryReconciler) listEntries(ctx context.Context) ([]spireapi.Entry, error) {
    // TODO: cache?
    return r.config.EntryClient.ListEntries(ctx)
}