---
title: "Discussion on \"19× throughput on one public Django-Bolt route with Rust on master\" | Hashnode"
description: "Discussion on \"19× throughput on one public Django-Bolt route with Rust on master\". On Django-Bolt’s master branch, one public 10-row PostgreSQL route went from 2,915 requests/sec on stock Bolt to 55,601 with Quickset’s Rust executor. The responses matched byte for byte. This path by"
url: "https://hashnode.com/posts/i-moved-one-django-bolt-read-route-to-rust-and-got-19-the-throughput-on-master/6b1180eb01c5604b30915f33"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [19× throughput on one public Django-Bolt route with Rust on master](https://yassershkeir.hashnode.dev/i-moved-one-django-bolt-read-route-to-rust-and-got-19-the-throughput-on-master?utm_source=hashnode&utm_medium=feed)

On Django-Bolt’s master branch, one public 10-row PostgreSQL route went from 2,915 requests/sec on stock Bolt to 55,601 with Quickset’s Rust executor. The responses matched byte for byte. This path by

1d ago · 2 min read · yassershkeir.hashnode.dev  
Read the article

-   [#django](https://hashnode.com/tag/django)
-   [#python](https://hashnode.com/tag/python)
-   [#rust](https://hashnode.com/tag/rust)
-   [#postgres](https://hashnode.com/tag/postgres)
-   [#opensource](https://hashnode.com/tag/opensource)

## Written by

[Yasser Shkeir](https://hashnode.com/@yassershkeir)

@yassershkeir

  
[View profile](https://hashnode.com/@yassershkeir)

## Responses 5

Markdown supported · ⌘↵ to post

[AI Developer](https://hashnode.com/@lycore)

[1d ago](https://hashnode.com/posts/i-moved-one-django-bolt-read-route-to-rust-and-got-19-the-throughput-on-master/6b1180eb01c5604b30915f33/comment/6b118482a94a97915c845c5d)

The 'refuse unless provably identical' design is the part I find most interesting. Recording the compiled SQL at startup assumes the QuerySet's shape is fixed, but things like database routers, per-request tenant schemas, or a changed search\_path could alter the SQL or the target connection without the route code changing. Does quickset key the recording on the connection alias and any router decision, or are routers one of the refusal cases? Also curious how it handles parameter-dependent query shapes, such as a filter that is skipped when min\_score is 0, since that changes the SQL text rather than just the bound values.

[Yasser Shkeir](https://hashnode.com/@yassershkeir)

[1d ago](https://hashnode.com/posts/i-moved-one-django-bolt-read-route-to-rust-and-got-19-the-throughput-on-master/6b1180eb01c5604b30915f33/comment/6b118482a94a97915c845c5d#reply-6b1191cb0f9bd2018eb3bb13)

A nonempty `DATABASE_ROUTERS` setting keeps the route on Django’s ORM. Otherwise Quickset records one connection alias and checks it across samples. Rust uses its own pool and doesn’t track `search_path` per request. I’d leave a tenant-dependent route on the ORM.

Your `if min_score:` example also stays on the ORM. A straight `.filter(score__gte=min_score)` is supported, including when Django drops the predicate or skips the query.

[Eagle](https://hashnode.com/@eagle2000)

[1d ago](https://hashnode.com/posts/i-moved-one-django-bolt-read-route-to-rust-and-got-19-the-throughput-on-master/6b1180eb01c5604b30915f33/comment/6b1181fa5da8e8dcc1530b95)

That's a wild jump from one route. Does Django still handle auth and middleware before handing off to Rust?

[Yasser Shkeir](https://hashnode.com/@yassershkeir)

[1d ago](https://hashnode.com/posts/i-moved-one-django-bolt-read-route-to-rust-and-got-19-the-throughput-on-master/6b1180eb01c5604b30915f33/comment/6b1181fa5da8e8dcc1530b95#reply-6b118a6e37159dedcbc42967)

No. On the Rust route, the request goes straight to Rust and PostgreSQL. Python middleware and Bolt’s auth checks never run. The 19× result was one public route on Bolt master. Routes with auth or guards stay in Python. I haven’t benchmarked an authenticated route.

[Eagle](https://hashnode.com/@eagle2000)

[1d ago](https://hashnode.com/posts/i-moved-one-django-bolt-read-route-to-rust-and-got-19-the-throughput-on-master/6b1180eb01c5604b30915f33/comment/6b1181fa5da8e8dcc1530b95#reply-6b11a69add83204e92ed4614)

Makes sense for public reads, and 2x on auth routes is a nice bonus. Still makes me wonder how maintainable that split becomes once the codebase grows.
