RustTokioBenchmark
SpacetimeDB
RustTokioBenchmark | SpacetimeDB | |
---|---|---|
1 | 14 | |
0 | 4,172 | |
- | 3.4% | |
2.7 | 9.8 | |
about 2 months ago | 3 days ago | |
Rust | Rust | |
MIT License | GNU General Public License v3.0 or later |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
RustTokioBenchmark
-
3 years of fulltime Rust game development, and why we're leaving Rust behind
> If you ever pull up a debugger and step through an async Rust/tokio codebase, you'll get a good sense for what the overhead here we're talking about is.
So I didn't quite do that, but the overhead was interesting to me anyway, and as I was unable to find existing benchmarks (surely they exist?), I instructed computer to create one for me: https://github.com/eras/RustTokioBenchmark
On this wee laptop the numbers are 532 vs 6381 cpu cycles when sending a message (one way) from one async thread to another (tokio) or one kernel thread to another (std::mpsc), when limited to one CPU. (It's limited to one CPU as rdtscp numbers are not comparable between different CPUs; I suppose pinning both threads to their own CPUs and actually measuring end-to-end delay would solve that, but this is what I have now.)
So this was eye-opening to me, as I expected tokio to be even faster! But still, it's 10x as fast as the thread-based method.. Straight up callback would still be a lot faster, of course, but it will affect the way you structure your code.
Improvements to methodology accepted via pull requests :).
SpacetimeDB
- Why SQLite Uses Bytecode
-
3 years of fulltime Rust game development, and why we're leaving Rust behind
I don't use Rust for game dev but I do for low level libraries and find it easier than C++ to get started. I have enjoyed it more than Java and like it for different reasons than Go, but it feels good to program in.
As for the design patterns that a complex game requires, if you are considering Rust for game dev and ecs design patterns it might be useful to check out projects that are Rust centric like https://spacetimedb.com/.
-
What if an SQL Statement Returned a Database?
Yeah, I worked on https://tablam.org and https://spacetimedb.com.
It becomes pretty clear that `order` is a significant property to make useful (and performant!) programs. "Duplicates" is also required to make usefull programs.
One nonobvious reason for this: You wanna report that a `customer` has a duplicated key `1`. If you CAN'T model `[(customer.id = 1), (customer.id = 1)]` then you can't report errors! And `erroneous` data is VITAL to make useful programs because then the only possibility is "perfect" data, and that is not possible!
Another reason is that we want to `count` duplicates, to see `duplicates`, and other NON-obvious at first: "What is a duplicate?". Get fun with floats, Unicode, combining case and non-case sensitive input... and is obvious that for useful programs IS REQUIRED to support bags in an extended version of the relational model.
And yet...
IS very important to remember about `set semantics` and try to adhere to it when makes sense. Your query planner will like it. You "valid" constraints like it. And `unique index` like it. And so on...
- SpacetimeDB v0.7 Released: WebAssembly stored procedure database
- SpacetimeDB v0.7 Released: WebAssembly stored procedure database written in Rust
-
SQLite 3.43.0 Released
> I asked was about querying data without ever using a SQL language, like tapping directly into the data.
I agree (making https://tablam.org to try a fix & working on https://github.com/clockworklabs/SpacetimeDB in the SQL conformance).
Before I think SQL was bad. *Now I'm certain*. SQL is absurdly massive for things that could have collapse all the features 10x or more.
However, working in an RDBM now I also understand why is not desirable to make "raw" calls to the DB: The engine MUST mediate all the calls to make things works (from query optimization, execution, iteration, lock management, transaction management, etc).
Is incredible how much sophistication is in a simple `SELECT * FROM table`.
What I wish is to build a `Wasm-like` IR so that is what anybody target, and `SQL` is not the mediator.
- A new database written in Rust that replaces your server entirely
-
Show HN: SpacetimeDB – The database that replaces your server
I wouldn't ordinarily chirp about this because it seems to be such a common typo/mistake but the fact you have a badge for it <https://github.com/clockworklabs/SpacetimeDB/blob/0f1fdf62d0...> as well as typoing it down in the license section <https://github.com/clockworklabs/SpacetimeDB/blob/0f1fdf62d0...> makes it worth pointing out in hopes of correction
The SPDX for BUsiness Source License is BUSL https://spdx.org/licenses/BUSL-1.1.html but the SPDX for Boost Source License is BSL https://spdx.org/licenses/BSL-1.0.html
Based on a search <https://shields.io/search?q=license> it seems you're using the custom badge syntax <https://shields.io/badges/static-badge> so you have influence over the correction
- SpacetimeDB: A new database written in Rust that replaces your server entirely
What are some alternatives?
pocketbase - Open Source realtime backend in 1 file
ink - Polkadot's ink! to write smart contracts.
aptos-core - Aptos is a layer 1 blockchain built to support the widespread use of blockchain through better technology and user experience.
anchor - ⚓ Solana Sealevel Framework
sui - Sui, a next-generation smart contract platform with high throughput, low latency, and an asset-oriented programming model powered by the Move programming language
surrealdb - A scalable, distributed, collaborative, document-graph database, for the realtime web
amber - All things AMBER
TablaM - The practical relational programing language for data-oriented applications
prql - PRQL is a modern language for transforming data — a simple, powerful, pipelined SQL replacement
cozo - A transactional, relational-graph-vector database that uses Datalog for query. The hippocampus for AI!
laravel - JSON:API for Laravel applications
json-api - A specification for building JSON APIs