Scale up as you grow — whether you're running one virtual machine or ten thousand.

From GPU-powered inference and Kubernetes to managed databases and storage, get everything you need to build, scale, and deploy intelligent applications.

Hello Everyone,
I am trying to deploy app build with NestJs for the Backend and ReactJs & ViteJs for the FrontEnd.
The app is on Github and i am using the repository directly in the app project.
During Build and Deploy, build complete, but while starting the server app it was giving me the following error.
FATAL ERROR: Ineffective mark-compacts near heap limit Allocation failed - JavaScript heap out of memory
Here is the full logs after build completed
[2024-09-06 12:52:50] ✔ build complete
[2024-09-06 12:53:40] > omni-crm-server@1.0.0 start
[2024-09-06 12:53:40] > nest start
[2024-09-06 12:53:40]
[2024-09-06 12:54:01]
[2024-09-06 12:54:01] <--- Last few GCs --->
[2024-09-06 12:54:01]
[2024-09-06 12:54:01] [17:0x56bae10] 20102 ms: Mark-Compact (reduce) 509.2 (521.4) -> 508.7 (519.2) MB, 601.25 / 0.00 ms (+ 7.0 ms in 10 steps since start of marking, biggest step 1.5 ms, walltime since start of marking 612 ms) (average mu = 0.256, current mu = 0.238) fina[17:0x56bae10] 20106 ms: Scavenge 509.9 (519.2) -> 509.2 (522.2) MB, 1.16 / 0.00 ms (average mu = 0.256, current mu = 0.238) allocation failure;
[2024-09-06 12:54:01]
[2024-09-06 12:54:01]
[2024-09-06 12:54:01] <--- JS stacktrace --->
[2024-09-06 12:54:01]
[2024-09-06 12:54:01] FATAL ERROR: Ineffective mark-compacts near heap limit Allocation failed - JavaScript heap out of memory
[2024-09-06 12:54:01] ----- Native stack trace -----
[2024-09-06 12:54:01]
[2024-09-06 12:54:01] 1: 0xb86ecf node::OOMErrorHandler(char const*, v8::OOMDetails const&) [node]
[2024-09-06 12:54:01] 2: 0xef74d0 v8::Utils::ReportOOMFailure(v8::internal::Isolate*, char const*, v8::OOMDetails const&) [node]
[2024-09-06 12:54:01] 3: 0xef77b7 v8::internal::V8::FatalProcessOutOfMemory(v8::internal::Isolate*, char const*, v8::OOMDetails const&) [node]
[2024-09-06 12:54:01] 4: 0x1109355 [node]
[2024-09-06 12:54:01] 5: 0x11098e4 v8::internal::Heap::RecomputeLimits(v8::internal::GarbageCollector) [node]
[2024-09-06 12:54:01] 6: 0x11207d4 v8::internal::Heap::PerformGarbageCollection(v8::internal::GarbageCollector, v8::internal::GarbageCollectionReason, char const*) [node]
[2024-09-06 12:54:01] 7: 0x1120fec v8::internal::Heap::CollectGarbage(v8::internal::AllocationSpace, v8::internal::GarbageCollectionReason, v8::GCCallbackFlags) [node]
[2024-09-06 12:54:01] 8: 0x112314a v8::internal::Heap::HandleGCRequest() [node]
[2024-09-06 12:54:01] 9: 0x108e7b7 v8::internal::StackGuard::HandleInterrupts() [node]
[2024-09-06 12:54:01] 10: 0x15310b2 v8::internal::Runtime_StackGuardWithGap(int, unsigned long*, v8::internal::Isolate*) [node]
[2024-09-06 12:54:01] 11: 0x196aef6 [node]
[2024-09-06 12:54:01] Aborted
[2024-09-06 12:54:01] npm notice
[2024-09-06 12:54:01] npm notice New patch version of npm available! 10.8.2 -> 10.8.3
[2024-09-06 12:54:01] npm notice Changelog: https://github.com/npm/cli/releases/tag/v10.8.3
[2024-09-06 12:54:01] npm notice To update run: npm install -g npm@10.8.3
[2024-09-06 12:54:01] npm notice
[] was terminated
[2024-09-06 12:54:18]
[2024-09-06 12:54:18] > omni-crm-server@1.0.0 start
[2024-09-06 12:54:18] > nest start
[2024-09-06 12:54:18]
I have added the following App-Level Environment Variable
Key: NODE_OPTIONS Value: --max-old-space-size=4096
Starting the server still failing and here are the full logs
[2024-09-06 13:34:12] ✔ build complete
[2024-09-06 13:34:24] > omni-crm-server@1.0.0 start
[2024-09-06 13:34:24] > nest start
[2024-09-06 13:34:24]
[] was terminated
[2024-09-06 13:35:06]
[2024-09-06 13:35:06] > omni-crm-server@1.0.0 start
[2024-09-06 13:35:06] > nest start
[2024-09-06 13:35:06]
How can i fix that?
dolphinnn
Vaishnavi Vundyala
016512ea60864da0867e5280f293de
Peter Monadjemi
Prince7hakur
devjk1
fc9acbfbc3124cbf8df28a1c5c5cdb
ab871885551143798f41908c709271
gouskova
Saivion Services
Marin
182d09356ab94d3893ddfaca4f0270