2

I have a local instance of weaviate running on my machine. I am trying to enable multi-tenancy by following this guidance and by utilizing this code:

client.schema.create_class({
    'class': 'MultiTenancyClass',
    'multiTenancyConfig': {'enabled': True}
})

client.schema.add_class_tenants(
  class_name='MultiTenancyClass',  # The class to which the tenants will be added
  tenants=[Tenant(name='tenantA'), Tenant(name='tenantB')]
)

However, I keep getting this error:

weaviate.exceptions.UnexpectedStatusCodeException: Add classes tenants! Unexpected status code: 404, with response body: {'code': 404, 'message': 'path /v1/schema/MultiTenancyClass/tenants was not found'}.

Is it not possible to add multi-tenancy to a local instance of weaviate?

Lizzard28
  • 53
  • 4
  • when I try to update my class to use mutli-tenancy via ```response = client.schema.update_config(CLASS_NAME, {"multiTenancyConfig": {"enabled": True}})``` I get a warning message ```compaction halted due to shard READONLY status``` However, when I check the status of my shard via ```shards_response = client.schema.get_class_shards(CLASS_NAME)``` it shows that my shard is ready ```[{'name': 'TmSEG9ZtZpl8', 'status': 'READY'}]``` – Lizzard28 Aug 07 '23 at 19:03

0 Answers0