cd /news/ai-infrastructure/my-ann-search-queries-are-absolutely… · home topics ai-infrastructure article
[ARTICLE · art-107373] src=promptcube3.com ↗ pub= topic=ai-infrastructure verified=true sentiment=↓ negative

My ANN_SEARCH queries are absolutely nuking my OLTP performance

A developer reports that running ANN_SEARCH vector similarity queries for a RAG pipeline in OceanBase is causing severe CPU thread starvation, with OLTP point queries that normally complete in under 1ms experiencing queueing times exceeding 400ms at around 800 concurrent vector search requests. The developer has tried adjusting tenant_max_cpu but seeks a more granular solution to cap parallel threads for ANN_SEARCH traversals, hoping to avoid moving vector workloads to a separate tenant due to cross-tenant latency and data synchronization overhead.

read2 min views1 publishedAug 22, 2026
My ANN_SEARCH queries are absolutely nuking my OLTP performance
Image: Promptcube3 (auto-discovered)

The setup is pretty straightforward: we use the same tenant for our standard real-time OLTP point-queries (basic primary key lookups) and our dense vector similarity searches for our RAG pipeline using the ANN_SEARCH

command with a VSAG index. On paper, this should work fine. In reality, as soon as we hit a concurrency spike—around 800 simultaneous vector search requests—the entire tenant falls apart.

The symptoms are brutal. Our simple SELECT ... WHERE id = ?

queries, which usually fly through in under 1ms, suddenly start lagging with queueing times exceeding 400ms. It’s not even a latency issue with the data itself; it’s a pure starvation issue.

I did a deep dive into the monitoring using GV$OB_PROCESSLIST

to figure out what was actually happening under the hood. It looks like the parallel execution threads being spawned for the graph-based VSAG index traversals are aggressively saturating the entire CPU worker thread pool for that tenant. Basically, the heavy vector math is grabbing every available thread, leaving absolutely nothing for the lightweight transactional queries to breathe.

I tried a few things to fix this, but nothing has stuck:

Resource Isolation attempt: I tried adjusting thetenant_max_cpu

boundaries, but since both the OLTP and the vector workloads are living inside the same tenant, the isolation isn't helping. The CPU is capped at the tenant level, but the "bad actor" (the vector search) is just eating everything within that cap.

What I'm looking for is a way to perform a more granular deployment of resources. Does anyone know if there is a tenant-level session variable or a specific system configuration in OceanBase that can explicitly cap the maximum number of parallel threads allocated specifically for

ANN_SEARCH

vector graph traversals? I really need to prevent the vector execution from starving the standard OLTP queries of CPU resources.

I’m trying to avoid the "obvious" solution of spinning up a dedicated second tenant for the vector searches. If I move the vector work to a different tenant, I'll run into cross-tenant network latency and massive data synchronization overhead, especially since we need to perform joined queries across both datasets. We need this to work in a single tenant for the sake of our AI workflow performance.

Has anyone dealt with this kind of thread starvation when running heavy LLM-related vector workloads alongside standard SQL? Any advice on tuning the parallel execution limits would be a lifesaver.

Next I tried to write my own textbooks and almost lost my mind →

── more in #ai-infrastructure 4 stories · sorted by recency
── more on @oceanbase 3 stories trending now
sponsored brought to you by zahid.host 4,200+ EU-deployed projects
reading about agents? ship yours in a single git push.

Run your AI side-project on zahid.host

EU-based hosting, git-push deploys, automatic HTTPS, no cold starts. Free tier with a custom domain — perfect for shipping the agent you just read about.

$git push zahid main
Live at https://your-agent.zahid.host
Get free account → Pricing
from €0/mo · no card required
LIVE [news/my-ann-search-querie…] indexed:0 read:2min 2026-08-22 ·