rust-client icon indicating copy to clipboard operation
rust-client copied to clipboard

[bug] upsert_points_blocking() api blocks indefinitely without any clear debug message

Open hackintoshrao opened this issue 2 years ago • 3 comments

Hey folks,

I'm creating a custom payload and committing data to Qdrant. The upsert operation works perfectly for about a thousand points, then gets blocked indefinitely. There was no debug information available to identify what could have gone wrong.

  client
             .upsert_points_blocking(COLLECTION_NAME, new, None)
             .await
             .map_err(|_| Box::new(CommitError::QdrantError))?;

hackintoshrao avatar Aug 16 '23 15:08 hackintoshrao

Hey folks, I'm observing something weird. I'm writing data to Qdrant in a loop. The database writes get blocked precisely at the 70th upsert operation!

Initially, I assumed the issue could be with a particular payload. Still, it turns out that irrespective of the point payload, the writes get blocked at a predictable iteration of the write!

hackintoshrao avatar Aug 22 '23 08:08 hackintoshrao

Hi @hackintoshrao, could you please provide a full function code, so we could try to reproduce? So far we didn't observe any hanging problems with rust client, even though it is heavily used in our benchmark tool: https://github.com/qdrant/bfb

generall avatar Aug 22 '23 08:08 generall

@generall : The issue happens only when I block the async upsert operation function using use futures::executor::block_on. This is leading to a deadlock down the line while upserting data.

I was blocking on the upserts since I was upserting inside a closure, moved the upsert out of the closure and removed the block_on. Works perfectly now.

If you think it would still be interesting to see the issue first hand, ill keep the issue open and create a stripped-out version of the code to reproduce this over the weekend.

hackintoshrao avatar Aug 22 '23 11:08 hackintoshrao