amikos-tech / chroma-cookbook

Learn how to use ChromaDB
https://cookbook.chromadb.dev
MIT License
35 stars 4 forks source link

Add example on how to delete tenants and databases #14

Open terilias opened 6 months ago

terilias commented 6 months ago

Hello, Thank you so much for publishing the ChromaDB Cookbook! It is very helpful! Especially I find very useful the multitenancy guide. I was wondering if there is a way to delete a specific tenant and a database from a chroma server. Also, I want to be able to manage the tenants that I have created to the server but I can't find a way to list all tenants and remove some of thems.

tazarov commented 2 months ago

@terilias, sorry for late response. This functionality technically allows the hosted/distributed Chroma via a management plane. However adding delete/list/update operations in the core OSS API is not something the team wants to do as the ops will not be supported in the distributed version of Chroma (via the core API).

That said I can relate to your problem, and I'll think of ways how to manage tenants and DBs.

terilias commented 2 months ago

Hi @tazarov , thank you for your reply! Ok, I understand that this operation is out of the team's development plans. Personally, as a workaround, I ended up using the delete/list/update only for collections inside the tenants and databases. If I wanted to perform a deletion, I was able to remove the collection and leave the database of a tenant empty. Thanks!

tazarov commented 2 months ago

@terilias, that is probably the simplest approach as both tenant and database are just virtual concept that are backed only by a single row for each in the sqlite3 db.

terilias commented 2 months ago

@tazarov Ok, I understand, so, it is no problem or overhead to leave them empty. Ok, then if you want you can close this issue as there is no planning for the tenants management implementation in the chromadb as you said. Thank you for your time!