Zanzana: Optimize batch check (#96669)

* Restructure check code so we only check namespace access once for each GroupResource during for batch
This commit is contained in:
Karl Persson
2024-11-19 14:39:46 +01:00
committed by GitHub
parent e270412dbf
commit 11a4a366c6
9 changed files with 131 additions and 160 deletions
@@ -29,8 +29,8 @@ func (s *Server) Write(ctx context.Context, req *authzextv1.WriteRequest) (*auth
}
writeReq := &openfgav1.WriteRequest{
StoreId: storeInf.Id,
AuthorizationModelId: storeInf.AuthorizationModelId,
StoreId: storeInf.ID,
AuthorizationModelId: storeInf.ModelID,
}
if len(writeTuples) > 0 {
writeReq.Writes = &openfgav1.WriteRequestWrites{