How to setup RLS based on namespace in multi tenancy environment

-On a multi-tenancy scenario (shared database) the datasets should be ‘dynamically’ and ‘automatically’ filtered based on the namespace. What is the best practice in order to do setup not for 2 customers as in the example, but for >100 customers (tenants, each customer with 2-5 users

-How many namespaces can we have in one account? more than 100?

  1. How are you currently managing users for RLS? Is it in a database that can be updated? We use Cognito and have trigger events that update lambdas. You could also use Cognito directly and their groups, and make a dataset from that. Here’s an example with Athena.
  1. I don’t know if there is a limit. I’m sure more than 100 would work.