跳到正文
Skillpedia
数据库40k · #7370

qdrant-scaling-qps

它能做什么

这份指南可以帮你提高 Qdrant 每秒能处理的搜索次数。重点在于优化系统,让它同时处理更多请求,这与让单次搜索变得更快不太一样。

适用场景

  • ✓当你需要系统能同时响应更多搜索时。
  • ✓如果因为很多人同时使用系统而导致搜索变慢。
  • ✓当你要配置 Qdrant 来处理大量请求时。

技能链接

https://github.com/github/awesome-copilot/blob/main/skills/qdrant-scaling/scaling-qps/SKILL.md

复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。

使用方法

最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。

可直接粘贴的消息

请用这个技能帮我:https://github.com/github/awesome-copilot/blob/main/skills/qdrant-scaling/scaling-qps/SKILL.md 阅读该链接中的 SKILL.md 文件,并在我的任务中按照它的说明来做。
想让你的 AI 自己找到这样的技能吗?安装免费的 Skillpedia MCP:只需一行,每次任务前它都会在 15,000+ 个技能中搜索。1 分钟完成安装 →

可以这样问 AI

“我该如何让 Qdrant 每秒处理更多查询?”

每周 5 个新技能,1 分钟读完。

工作原理

要提高每秒查询数,你可以调整设置,让 Qdrant 在每次搜索时占用更少的资源,比如合并批量搜索,或者同一时间查询更少的数据分片。如果这些还不够,你可以增加机器,让它们共同分担工作量。

技术内容(原始 SKILL.md)

作者在 GitHub 上的英文原文。

Scaling for Query Throughput (QPS)

Throughput scaling means handling more parallel queries per second. This is different from latency - throughput and latency are opposite tuning directions and cannot be optimized simultaneously on the same node.

High throughput favors fewer, larger segments so each query touches less overhead.

Performance Tuning for Higher RPS

Minimize impact of Update Workloads

  • Configure update throughput control (v1.17+) to prevent unoptimized searches degrading reads Low latency search
  • Set optimizer_cpu_budget to limit indexing CPUs (e.g. 2 on an 8-CPU node reserves 6 for queries)
  • Configure delayed read fan-out (v1.17+) for tail latency Delayed fan-outs

Horizontal Scaling for Throughput

If a single node is saturated on CPU after applying the tuning above, scale horizontally with read replicas.

  • Shard replicas serve queries from replicated shards, distributing read load across nodes
  • Each replica adds independent query capacity without re-sharding
  • Use replication_factor: 2+ and route reads to replicas Distributed deployment

See also Horizontal Scaling for general horizontal scaling guidance.

Disk I/O Bottlenecks

If it is not possible to keep all vectors in RAM, disk I/O can become the bottleneck for throughput. In this case:

  • Upgrade to provisioned IOPS or local NVMe first. See impact of disk performance to vector search in Disk performance article
  • Use io_uring on Linux (kernel 5.11+) io_uring article
  • In case of quantized vectors, prefer global rescoring over per-segment rescoring to reduce disk reads. Example in the tutorial
  • Configure higher number of search threads to parallelize disk reads. Default is cpu_count - 1, which is optimal for RAM-based search but may be too low for disk-based search. See configuration reference
  • If still saturated, scale out horizontally (each node adds independent IOPS)

What NOT to Do

  • Do not expect to optimize throughput and latency simultaneously on the same node
  • Do not use many small segments for throughput workloads (increases per-query overhead)
  • Do not scale horizontally when IOPS-bound without also upgrading disk tier
  • Do not run at >90% RAM (OS cache eviction = severe performance degradation)
常见问题

搜索速度(延迟)和每秒查询数(吞吐量)有什么区别?

延迟是单次搜索得到响应所需的时间,吞吐量是系统每秒能响应多少次搜索。优化其中一个,有时会让另一个变差。

什么是“segment”?为什么 segment 越少,每秒查询数越高?

segment 就像存放数据的文件。segment 越少、体积越大,Qdrant 每次搜索需要访问的文件就越少。当目标是快速响应大量搜索时,这样效率更高。

什么是“横向扩展”?

横向扩展指增加机器(或 Qdrant 实例)来分担工作。当即使经过优化,单台机器也无法承受所有请求时,这种方式就很有用。

详情

作者的原始描述

Guides Qdrant query throughput (QPS) scaling. Use when someone asks 'how to increase QPS', 'need more throughput', 'queries per second too low', 'batch search', 'read replicas', or 'how to handle more concurrent queries'.

repo: github/awesome-copilot

热度

GitHub 星标
40k
排名
#7370
许可证
MIT
更新时间
2026/10/15

这个技能有用吗?

0

登录 后即可投票。

评论

  • …

同一仓库的更多技能

相似技能