sveltekit-adapter-aws
sveltekit-adapter-aws copied to clipboard
Out of memory when used in conjunction with vite-plugin-pwa
I'm using vite-plug-pwa to setup service workers.
When I try to combine this plugin with sveltekit-adapter-aws ('edge-bundled'), I get a v8 JavasScript heap out of memory error. I can remove either plugin, and the project will build ok.
<--- Last few GCs --->
[204930:0x61551c0] 141045 ms: Mark-Compact 1995.0 (2084.7) -> 1978.3 (2085.2) MB, 1673.13 / 0.01 ms (average mu = 0.235, current mu = 0.167) allocation failure; scavenge might not succeed
[204930:0x61551c0] 144935 ms: Mark-Compact 1996.1 (2085.4) -> 1980.5 (2086.2) MB, 3728.52 / 0.01 ms (average mu = 0.113, current mu = 0.041) allocation failure; scavenge might not succeed
<--- JS stacktrace --->
FATAL ERROR: Ineffective mark-compacts near heap limit Allocation failed - JavaScript heap out of memory
----- Native stack trace -----
1: 0xca5430 node::Abort() [node]
2: 0xb7807d [node]
3: 0xeca0b0 v8::Utils::ReportOOMFailure(v8::internal::Isolate*, char const*, v8::OOMDetails const&) [node]
4: 0xeca397 v8::internal::V8::FatalProcessOutOfMemory(v8::internal::Isolate*, char const*, v8::OOMDetails const&) [node]
5: 0x10dc0e5 [node]
6: 0x10dc674 v8::internal::Heap::RecomputeLimits(v8::internal::GarbageCollector) [node]
7: 0x10f3564 v8::internal::Heap::PerformGarbageCollection(v8::internal::GarbageCollector, v8::internal::GarbageCollectionReason, char const*) [node]
8: 0x10f3d7c v8::internal::Heap::CollectGarbage(v8::internal::AllocationSpace, v8::internal::GarbageCollectionReason, v8::GCCallbackFlags) [node]
9: 0x10ca081 v8::internal::HeapAllocator::AllocateRawWithLightRetrySlowPath(int, v8::internal::AllocationType, v8::internal::AllocationOrigin, v8::internal::AllocationAlignment) [node]
10: 0x10cb215 v8::internal::HeapAllocator::AllocateRawWithRetryOrFailSlowPath(int, v8::internal::AllocationType, v8::internal::AllocationOrigin, v8::internal::AllocationAlignment) [node]
11: 0x10a8866 v8::internal::Factory::NewFillerObject(int, v8::internal::AllocationAlignment, v8::internal::AllocationType, v8::internal::AllocationOrigin) [node]
12: 0x15035f6 v8::internal::Runtime_AllocateInYoungGeneration(int, unsigned long*, v8::internal::Isolate*) [node]
13: 0x193cef6 [node]
System:
System:
OS: Linux 6.1 Amazon Linux 2023
CPU: (4) x64 AMD EPYC 7571
Memory: 8.28 GB / 15.45 GB
Container: Yes
Shell: 5.2.15 - /bin/bash