Singlestore CIAB error - Leaf not keeps disconnecting from cluster Error: 2004-HY000

I have a memsql ciab cluster I use for local development.
I’ve used the latest instructions to spin up this cluster from github page

docker run -i --init \
    --name memsql-ciab \
    -e SINGLESTORE_LICENSE=$MEMSQL_LICENSE_KEY \
    -e ROOT_PASSWORD=singlestore_doesnt_work \
    -p 3306:3306 -p 8080:8080 \
    --platform linux/amd64 \
    ghcr.io/singlestore-labs/singlestoredb-dev:latest

The cluster is healthy when there are no queries running.

The moment I run a query, I start getting these errors.


uncategorized SQLException for SQL [SELECT col1, col2, col3, DOT_PRODUCT(vector, JSON_ARRAY_PACK(?)) AS score from table where vector IS NOT NULL and vector !='' order by score desc limit ?]; SQL state [HY000]; error code [1777]; (conn=659) Partition local_db:0 has no master instance. This is likely because the node or nodes that hold a copy of the partition are down. Check for offline leaf nodes by running SHOW LEAVES and bring them back online to restore access to the partition; nested exception is java.sql.SQLException: (conn=659) Partition local_db:0 has no master instance. This is likely because the node or nodes that hold a copy of the partition are down. Check for offline leaf nodes by running SHOW LEAVES and bring them back online to restore access to the partition

The query fails with an error, the node suddenly disconnects.
However within seconds of running that query, the node is able to re-attach and the cluster becomes healthy again.

Happens every time I try to run this query

Not sure why this doesn’t work and how to debug this.

Details of my setup
M1 Mac
jdk 11
singlestore-jdbc-client v1.2.2

Can you give a full repro, including

Full details of how you are running on M1 including the instructions on our web site that you followed to set it up, if any.

CREATE TABLE
INSERT a little data (if needed)
the SELECT query that causes the crash

It might be a bug related to the M1 Intel emulation environment (I’m just speculating). So as a workaround, consider using a free instance on our cloud.

I shared all the setup steps in the previous post, As I mentioned earlier, I’ve followed all the steps on your github page for singlestore-ciab docker image setup on m1 mac

Basic select and insert commands seem to be working fine.
it feels like the problem is limited to vector search queries (semantic search). You can try to repro using the singlestore blogpost about this topic. I can’t share the data i’ve used and neither can I run this test on the cloud due to infosec policies and data privacy concerns.

Unfortunately redis does much better for vector search, and the decision to use singlestore for this use case was made above my pay grade :confused:

Great news! SingleStore 8.5.17, which just came out, fixes the known issues with vector search and dot_product for M1/M2/M3 Macs.