Serverless Stream Processing: Architecture and Trade-offs
Multi-tenant streaming architectures serve multiple customers or business units from shared streaming infrastructure while maintaining isolation, fair resource allocation, and data separation.
Isolation Patterns
| Pattern | Isolation | Cost | Complexity |
| Separate clusters | Full | High | Low |
| Namespace separation | Logical | Medium | Medium |
| Row-level filtering | Minimal | Low | High |
| Schema-per-tenant | Moderate | Medium | Medium |
Row-Level Multi-Tenancy with SQL
-- Shared source with tenant_id
CREATE SOURCE events (tenant_id VARCHAR, event_type VARCHAR, data JSONB, ts TIMESTAMP)
WITH (connector='kafka', topic='multi-tenant-events', ...);
-- Per-tenant views (row-level filtering)
CREATE MATERIALIZED VIEW tenant_metrics AS
SELECT tenant_id, event_type, COUNT(*) as cnt, SUM((data->>'amount')::DECIMAL) as total
FROM events WHERE ts > NOW()-INTERVAL '1 hour'
GROUP BY tenant_id, event_type;
-- Query with tenant filter: SELECT * FROM tenant_metrics WHERE tenant_id = 'acme-corp';
Frequently Asked Questions
How do I prevent noisy neighbors in shared streaming?
Use resource quotas per tenant (CPU, memory limits), separate processing pipelines for high-volume tenants, and monitoring with per-tenant metrics. RisingWave's disaggregated architecture helps — S3 storage scales per-tenant without affecting compute.

