Umbraco 15 - how to reduce memory usage?

Im trying to reduce memory footprint of an Umbraco 15 installation. Umbraco uses 230mb when we spin up a docker container.

After accessing Umbraco backend and logging ind, Umbraco container uses 470 mb (we only logged in)

Memory usage seems to be minimum at 470mb.

The Umbraco installation is used for

  • deliverying content using content delivery api
  • delivering images uploaded to media section

There is not much content (10 pages) but there is a lot of doctypes etc.

For frontends

  • Content is fetched and cached elsewhere.
  • Images are not fetched from disk not using /media.

Umbraco backend is still accessing images direct.

What ive done:

Questions:

  • Is that expected mem usage or what can i do?
  • how does Umbraco react on memory restrictions?

Any pointers would be fantastic. I cant imagine that Umbraco really needs 0.5 GB ram

To be honest, I personally don’t find it weird that is needs 500MB of RAM or more. It’s a content management system with a lot of background tasks, services etc.

HI luuk,

Well I get that but still … Umbraco can be used in so many ways. I would think that a specific Umbraco solution have very different needs from another. The need for caching media, content internal / external, content delivery api must vary by a lot. And while some solutions might benefit from caching all on startup and keeping it in mem, others might not (specially if the caching is done elsewhere - in frontend for instance.

Since we use Umbraco Headless and with media served via external services - its pointless for us to have Umbraco wired up to serve from cache.

Umbraco introduces HybridCache which has some options I need to learn. But it would be amazing to know if there are any knowledge in this area hidden in docs or brains :slight_smile:

HybridCache library in ASP.NET Core | Microsoft Learn)

I was really annoyed how sluggish local builds were with 15 but I updated my current project to 16 and it is a lot better.

Hi Liam,

What do you mean by sluggish?

Are you aware of the new caching settings with hybridcache? You can change the duration / max size of the cache and can also change which things are seeded in the cache on startup:
Cache Settings | Umbraco CMS

Hi Jesper,

Thanks for joining :slight_smile:

:white_check_mark: Hybrid cache settings - yep, im aware.

Ive experimented a bit and I’m not concluding anything yet but it doesnt seem to affect the initial mem use. I’ll post my findings soon.

I think you can attribute most of this to the architecture and framework it’s built on. I don’t know of many .NET applications that don’t immediately balloon up to large memory footprints like this.

I’ll be watching this topic closely–I’d love to hear more and possibly follow along to get our applications memory footprint down too.

Good topic Jesper!