Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Multi-tenancy #752

Open
bladehliu opened this issue Feb 6, 2024 · 3 comments
Open

Multi-tenancy #752

bladehliu opened this issue Feb 6, 2024 · 3 comments
Assignees

Comments

@bladehliu
Copy link
Member

bladehliu commented Feb 6, 2024

When building an LLM-based AI application, we need the right way to store user/tenant-specific vector data. And it is the common case that there are millions or billions of users while each user's data is not too much - say several document files, i.e., there are lots of spaces and most of them is small-sized.

Vearch needs a more efficient way to support millions of small spaces in one cluster.

@bladehliu bladehliu assigned bladehliu and guichuanghua and unassigned bladehliu Feb 10, 2024
@bladehliu
Copy link
Member Author

bladehliu commented Feb 11, 2024

design consideration

we can divide spaces by two kinds: public vs private. Public spaces are accessed by lots of users and usually partitioned for performance or capacity. A private space is owned and accessed exclusively by a single user so does not needed to be partitioned.

Note it is a bad idea that a private space corresponds to one raft replication state machine - too much overhead (heartbeats, goroutines, et al). And there are two solution candidates:

1, multiple private spaces are assigned to one replication group in the current shared-nothing architecture
2, separation of storage/compute, no replication at the compute layer, multiple spaces hosted by a server, #749

@bladehliu
Copy link
Member Author

Goal:

  1. separated data space per tenant
  2. scale to millions of tenants in a cluster of hundreds of servers, with tens of thousands of active tenants per server
  3. inactive tenants should be offloaded to release the RAM resource and will be loaded on demand

@CharlesJQuarra
Copy link

Goal:

1. separated data space per tenant

This is a common use case for RocksDB column families. They can be created and removed on demand and they avoid adding global indexing overheads to separate column families.

2. scale to millions of tenants in a cluster of hundreds of servers, with tens of thousands of active tenants per server

3. inactive tenants should be offloaded to release the RAM resource and will be loaded on demand

RocksDB should be able to manage this transparently during regular compaction

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants