Merge: nixos/matrix-synapse: configure PYTHONMALLOC when using jemalloc (#369444)

authored by Maximilian Bosch and committed by GitHub 1fdc9d0e c6be0af7

+4 -1
+2
nixos/doc/manual/release-notes/rl-2505.section.md
··· 304 304 305 305 - `services.avahi.ipv6` now defaults to true. 306 306 307 + - For matrix homeserver Synapse we are now following the upstream recommendation to enable jemalloc as the memory allocator by default. 308 + 307 309 - `bind.cacheNetworks` now only controls access for recursive queries, where it previously controlled access for all queries. 308 310 309 311 - Caddy can now be built with plugins by using `caddy.withPlugins`, a `passthru` function that accepts an attribute set as a parameter. The `plugins` argument represents a list of Caddy plugins, with each Caddy plugin being a versioned module. The `hash` argument represents the `vendorHash` of the resulting Caddy source code with the plugins added.
+2 -1
nixos/modules/services/matrix/synapse.nix
··· 705 705 706 706 withJemalloc = mkOption { 707 707 type = types.bool; 708 - default = false; 708 + default = true; 709 709 description = '' 710 710 Whether to preload jemalloc to reduce memory fragmentation and overall usage. 711 711 ''; ··· 1462 1462 baseServiceConfig = { 1463 1463 environment = optionalAttrs (cfg.withJemalloc) { 1464 1464 LD_PRELOAD = "${pkgs.jemalloc}/lib/libjemalloc.so"; 1465 + PYTHONMALLOC = "malloc"; 1465 1466 }; 1466 1467 serviceConfig = { 1467 1468 Type = "notify";