Description
Hello team,
I am using serverless instance from weaviate cloud and using the API endpoint to make the connection. Tried the gRPC endpoint but getting a 503 error and I believe gRPC is not supported at the moment for weaviate cloud serverless.
What am I trying to achieve?
Created a multi-tenant collection and object with properties videoID, sourceType and sourceId. Before creating a new object I want check if there are already objects for specific videoID, sourceType and sourceId, if yes then I want to delete them and then insert new ones
what is going wrong?
To achieve above when I use Filter by Property from V4 client library, I am getting gRPC SSL handshake error. If get pass the SSL handshake error then I am getting 503 error.
Please could you confirm if Filter by Property is supported for Weaviate cloud serverless? If yes, then please could you point me to right way of doing it?
Server Setup Information
- Weaviate Server Version: Serverless
- Deployment Method: Weaviate Cloud
- Multi Node? Number of Running Nodes: N/A
- Client Language and Version: Python weaviate_client V4 4.14.4
- Multitenancy?: Yes
Any additional Information
My implementation:
Weviate client
self.client = weaviate.connect_to_weaviate_cloud(
cluster_url = os.getenv(“WEAVIATE_CLUSTER_URL”),
auth_credentials = Auth.api_key(os.getenv(“WEAVIATE_API_KEY”)),
skip_init_checks = True,
headers = {“X-OpenAI-Api-Key”: config.chatgptkey}
)
Query by property type
coll = self.client.collections.get(cname)
if coll.tenants.get_by_name(company_id) is None:
logging.warning("Tenant '%s' does not exist in '%s'.", company_id, cname)
return 0
# Build the filter
where = (
Filter.by_property("videoID").equal(video_id)
& Filter.by_property("sourceType").equal(source_type)
& Filter.by_property("sourceId").equal(source_id)
)
# Query for UUIDs
results = (
coll.query
.with_where(where)
.with_additional(["uuid"])
.with_limit(100) # paginate if needed
.do(tenant=company_id)
)