Comments (4)
The default allocator does not return unused memory to avoid the performance loss and memory fragmentation that additional system calls would cause. Reddit
Additionally, there is a PR in rust-analyzer
repository suggesting a revisit to the use of jemalloc
in release build. issue
Despite the advantages, introducing jemalloc into Loco
might lead to observation issue resulting in misleading or out of sync memory usage reports in htop.
In my opinion, adding a bref guide in the documentation about switching to different allocator could benefit users seeking max performance. We should also include warning for the observation issue mentioned above.
from loco.
This is a great suggestion. I think it calls for some kind of "running in production" section in the docs π
from loco.
This is very interesting! thanks!
I'm wondering what is the reason for the difference? probably that the default allocator prefers keeping things in memory until memory has pressure and then it will release?
from loco.
Just to add to this, as mentioned above, Rust used to ship with the jemalloc allocator by default but it got removed (possibly due to binary size bloat and not supporting as many platforms).
The foundations crate from cloudflare, which has some tools for building networked services, uses jemalloc (https://docs.rs/foundations/latest/foundations/static.JEMALLOC_MEMORY_ALLOCATOR.html).
I point this out just to say that it's not uncommon for rust projects to use an allocator different from the system allocator, and for networked or long running services to use the jemalloc allocator more specifically (where it excels).
(No affiliation with Cloudflare, just an example I found)
from loco.
Related Issues (20)
- Cron/Scheduler support? HOT 6
- Adding `ilike` to model query dsl HOT 4
- docs: build a "rosetta stone" for frameworks vs "how its done in Loco"
- loco-cli doesn't have the subcommand "generate" HOT 2
- Plural naming system doesn't work for atypical plurals HOT 2
- "ActiveCache" subsystem for streamlined cache service in Loco
- "ActiveData" subsystem: enable seamless and strongly typed loading of static data for an app
- Add Error processing hook HOT 3
- Getting Started section of guide has commands that do not work as expected HOT 5
- When I use loco, the following error is too common. what reason? HOT 9
- βοΈ π Guest blog posts HOT 4
- Add RequestContext, and support request-scoped sessions HOT 3
- add `production.yml` to `.gitignore` by default
- Add information section to documentation about order of extractors mattering HOT 3
- _ping and api/_pingοΌ HOT 3
- Configurable Auth Token Location.
- Make it easier to change JWT algorithm HOT 2
- Use git tags for released versions of loco HOT 1
- Improve docs with snipdoc
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. πππ
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google β€οΈ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from loco.