All Projects → KuiBaDB → kbio

KuiBaDB / kbio

Licence: MIT License
Another Async IO Framework based on io_uring

Programming Languages

rust
11053 projects
shell
77523 projects

Projects that are alternatives of or similar to kbio

Aiomisc
aiomisc - miscellaneous utils for asyncio
Stars: ✭ 200 (+270.37%)
Mutual labels:  asyncio, async-await
tomodachi
💻 Microservice library / framework using Python's asyncio event loop with full support for HTTP + WebSockets, AWS SNS+SQS, RabbitMQ / AMQP, middleware, etc. Extendable for GraphQL, protobuf, gRPC, among other technologies.
Stars: ✭ 170 (+214.81%)
Mutual labels:  asyncio, async-await
Aioodbc
aioodbc - is a library for accessing a ODBC databases from the asyncio
Stars: ✭ 206 (+281.48%)
Mutual labels:  asyncio, async-await
Aiormq
Pure python AMQP 0.9.1 asynchronous client library
Stars: ✭ 112 (+107.41%)
Mutual labels:  asyncio, async-await
is-async-function
Is this a native `async function`?
Stars: ✭ 17 (-68.52%)
Mutual labels:  await, async-await
Cppcoro
A library of C++ coroutine abstractions for the coroutines TS
Stars: ✭ 2,118 (+3822.22%)
Mutual labels:  asyncio, async-await
await-generator
A library to use async/await in PHP using generators.
Stars: ✭ 80 (+48.15%)
Mutual labels:  await, async-await
Uvloop
Ultra fast asyncio event loop.
Stars: ✭ 8,246 (+15170.37%)
Mutual labels:  asyncio, async-await
synchronicity
Synchronicity lets you interoperate with asynchronous Python APIs.
Stars: ✭ 41 (-24.07%)
Mutual labels:  asyncio, await
helo
A simple and small low-level asynchronous ORM using Python asyncio.
Stars: ✭ 18 (-66.67%)
Mutual labels:  asyncio, await
Riprova
Versatile async-friendly library to retry failed operations with configurable backoff strategies
Stars: ✭ 106 (+96.3%)
Mutual labels:  asyncio, async-await
nardis
A small web framework based on ASGI
Stars: ✭ 14 (-74.07%)
Mutual labels:  asyncio, async-await
Greenletio
Asyncio integration with sync code using greenlets.
Stars: ✭ 102 (+88.89%)
Mutual labels:  asyncio, async-await
Aiozipkin
Distributed tracing instrumentation for asyncio with zipkin
Stars: ✭ 161 (+198.15%)
Mutual labels:  asyncio, async-await
Web Applications With Fastapi Course
Demo code and other handouts for students of our FastAPI Web Apps course.
Stars: ✭ 56 (+3.7%)
Mutual labels:  asyncio, async-await
Aiohttp admin
admin interface for aiohttp application http://aiohttp-admin.readthedocs.io
Stars: ✭ 207 (+283.33%)
Mutual labels:  asyncio, async-await
Async Reduce
Reducer for similar simultaneously coroutines
Stars: ✭ 17 (-68.52%)
Mutual labels:  asyncio, async-await
Asyncio
asyncio historical repository
Stars: ✭ 952 (+1662.96%)
Mutual labels:  asyncio, async-await
of
🍬 Promise wrapper with sugar 🍬
Stars: ✭ 13 (-75.93%)
Mutual labels:  await, async-await
aioflask
Flask running on asyncio!
Stars: ✭ 192 (+255.56%)
Mutual labels:  asyncio, async-await

KBIO, added IO-Uring in tokio. Currently, kbio is just used in KuiBaDB, it is only a prototype and has not been tested fully.

  • Our experience using C++20 coroutines in Hologres tells us that Worker Steal is very necessary. So we build kbio based on tokio.

  • We run one IO-Uring instance per Worker. Before that, all Workers in Tokio used an Epoll instance, mainly because once a file descriptor is bound to an Epoll instance in Tokio, then the file descriptor will never switch to other Epoll instances, which will affect the effect of Worker Steal.

  • When a Worker needs to submit SQE, it will give priority to the Uring instance corresponding to the current Worker, and will also switch to other Uring instances when there is no free space in the current Uring instance.

  • KBIO is only a transitional project. We expect Tokio to support iouring in the end.

Usage

Most of them are fully compatible with tokio. See integrate kbio into memc for another example.

Benchmark

We use monoio-benchmark to do the benchmark, and use the example above to replace tokio-server/src/main.rs..

See integrate kbio into memc for another example.

[[email protected]]$ taskset -c 6-7 ./tokio-server --cores 6 7
[[email protected] 1k]$ ./client -c 0 1 2 3 -n 150
Running ping pong client.
Packet size: 1024
Connection count per core: 150; Global connection count: 600
QPS limit per core: 0; Global QPS limit: 0
Target: 127.0.0.1:40000
CPU slot: 0,1,2,3
1.000: NAdd: 138103; NSum: 138103; NAverage: 138093.969, LatencyAverage: 1831.181 us
2.000: NAdd: 179485; NSum: 317588; NAverage: 158781.531, LatencyAverage: 2535.254 us
3.000: NAdd: 187939; NSum: 505527; NAverage: 168495.281, LatencyAverage: 2779.394 us
4.000: NAdd: 187813; NSum: 693340; NAverage: 173320.438, LatencyAverage: 2891.172 us
5.000: NAdd: 187757; NSum: 881097; NAverage: 176204.344, LatencyAverage: 2959.997 us
6.001: NAdd: 186244; NSum: 1067341; NAverage: 177874.719, LatencyAverage: 3002.718 us
7.001: NAdd: 190705; NSum: 1258046; NAverage: 179705.047, LatencyAverage: 3023.978 us
8.001: NAdd: 192710; NSum: 1450756; NAverage: 181329.328, LatencyAverage: 3036.164 us
^C

[[email protected] 1k]$ ./monoio-server --cores 6 7
[[email protected] 1k]$ ./client -c 0 1 2 3 -n 150
Running ping pong client.
Packet size: 1024
Connection count per core: 150; Global connection count: 600
QPS limit per core: 0; Global QPS limit: 0
Target: 127.0.0.1:40000
CPU slot: 0,1,2,3
1.000: NAdd: 199135; NSum: 199135; NAverage: 199119.969, LatencyAverage: 2629.738 us
2.000: NAdd: 231118; NSum: 430253; NAverage: 215108.594, LatencyAverage: 2612.171 us
3.000: NAdd: 242953; NSum: 673206; NAverage: 224382.906, LatencyAverage: 2560.102 us
4.000: NAdd: 244618; NSum: 917824; NAverage: 229436.391, LatencyAverage: 2531.557 us
5.000: NAdd: 242257; NSum: 1160081; NAverage: 231997.594, LatencyAverage: 2519.936 us
6.000: NAdd: 247475; NSum: 1407556; NAverage: 234573.359, LatencyAverage: 2502.973 us
7.001: NAdd: 250774; NSum: 1658330; NAverage: 236884.219, LatencyAverage: 2486.379 us
8.001: NAdd: 240513; NSum: 1898843; NAverage: 237327.906, LatencyAverage: 2487.242 us
^C

[[email protected] 1k]$ ./glommio-server --cores 6 7
[[email protected] 1k]$ ./client -c 0 1 2 3 -n 150
Running ping pong client.
Packet size: 1024
Connection count per core: 150; Global connection count: 600
QPS limit per core: 0; Global QPS limit: 0
Target: 127.0.0.1:40000
CPU slot: 0,1,2,3
1.000: NAdd: 108135; NSum: 108135; NAverage: 108127.938, LatencyAverage: 4766.189 us
2.000: NAdd: 127786; NSum: 235921; NAverage: 117951.289, LatencyAverage: 4727.146 us
3.000: NAdd: 127098; NSum: 363019; NAverage: 120996.281, LatencyAverage: 4725.291 us
4.000: NAdd: 127328; NSum: 490347; NAverage: 122576.320, LatencyAverage: 4721.638 us
5.000: NAdd: 127299; NSum: 617646; NAverage: 123518.625, LatencyAverage: 4719.515 us
^C
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].