Two school districts share one SaaS-style deployment of a student services app. Queries must never return another tenant's student rows even if object IDs are similar. What multi-tenant data pattern should the code enforce?
Select an answer to reveal the explanation.
Short Explanation
Shared SaaS is a duplex apartment: each district gets its own locks, not a hallway dump of every student's file. Put tenantId in the key or filter and check it on every read — UUIDs alone are not walls.
Full Explanation
Multi-tenant applications must enforce isolation with tenant identifiers in partition keys, query conditions, or equivalent row filters on every access path. Client-side filtering after a full scan, key obscurity without server checks, and unrestricted Scan for all roles allow cross-tenant leakage.