408 private links
The project: https://github.com/kustomzone/sierra-db
You benchmark your node/ruby/python software on a fancy Macbook M4 and celebrate 500ms response time.
I benchmark my rust software on a $30 potato computer that may as well have 256MB of RAM and celebrate 800ms response time.
Documentation: https://pingoo.io/
Developed by Silvain Kerkour: https://kerkour.com/
The heap is a performance killer in Rust. One woraround is to swap to a more efficient memory allocator such as jemalloc.
In Cargo.toml:
[dependencies]
mimalloc = "0.1"
In main.rs:
#[global_allocator]
static GLOBAL: mimalloc::MiMalloc = mimalloc::MiMalloc;
The best performance optimisation is to avoid the heap. There is the heapless create for that. "The only thing to know is that the size of heapless types and collections needs to be known at compile-time."
Lifetime annotations are needed to tell the compiler that we are manipulating some kind of long-lived reference and let it assert that we are not going to screw ourselves
The only downside is that smart pointers, in Rust, are a little bit verbose (but still way less ugly than lifetime annotations). [They add some runtime overhead.]
When to use lifetimes annotations?
When performance really matters or when your code will be used in no_std environments.
I don't know. It seems to be overkill for the use. Instead of words, some functions get a capital letter.
A work to use rust build as PHP extension
It marks the function as never returning.
In comparison, the unit type () returns at least a value.
Everything in one place: Organizations, contacts, projects, and how they relate.
Own your data: Plain text files and tooling that runs on your machine.
Open data model: Tailor to your business with custom schemas.
Automate anything: Search, report, integrate, whatever. It's just code.
AI-ready: LLMs can read, write, and query your business structure.
The author creates an extension for 3 uuid functions in Rust.
Tradeoffs: big extension size (330KB for simple uuids)
About using SQLite:
As mentioned in an earlier post the two biggest pain points are the "slow" schema changes on 10M+ rows tables locking the entire database for 10+ seconds, and the difficulty to implement automated failover. But it rocks for services that don't need 99.999 % of availability.
assert!() use in const expression are a great way to ensure safe type casting
Rust code is shared between IOS and Android.
How to store the traits related to an object? Typetag use a type property in JSON format and integrates with serde.