I would love to agree that it is me who is the problem with the memory requirement. Attempting to run with 8GB (binary) gives me the following error:
PS C:\Users\csworen\Downloads\8272.DynamicStackedChart\DynamicStackedChart> npm start
> dynamic-stacked-chart@0.0.0 start
> node --max_old_space_size=8192 node_modules/@angular/cli/bin/ng serve -o --optimization false
<--- Last few GCs --->
<--- JS stacktrace --->
#
# Fatal javascript OOM in GC during deserialization
#
PS C:\Users\csworen\Downloads\8272.DynamicStackedChart\DynamicStackedChart>
As I increase the memory in max_old_space_size, I it alternates between that (and similar) and random allocation issues with the JavaScript heap. Here's an example at 12GB (decimal):
PS C:\Users\csworen\Downloads\8272.DynamicStackedChart\DynamicStackedChart> npm start
> dynamic-stacked-chart@0.0.0 start
> node --max_old_space_size=12000 node_modules/@angular/cli/bin/ng serve -o --optimization false
Option "optimization" is deprecated: Use the "optimization" option in the browser builder instead.
⠼ Generating browser application bundles (phase: emitting)...node:internal/buffer:959
super(bufferOrLength, byteOffset, length);
^
RangeError: Array buffer allocation failed
at new ArrayBuffer ()
at new Uint8Array ()
at new FastBuffer (node:internal/buffer:959:5)
at createUnsafeBuffer (node:internal/buffer:1062:12)
at allocate (node:buffer:409:10)
at Function.allocUnsafe (node:buffer:374:10)
at Function.concat (node:buffer:552:25)
at ConcatSource.buffer (C:\Users\csworen\Downloads\8272.DynamicStackedChart\DynamicStackedChart\node_modules\webpack\node_modules\webpack-sources\lib\ConcatSource.js:69:17)
at getContent (C:\Users\csworen\Downloads\8272.DynamicStackedChart\DynamicStackedChart\node_modules\webpack\lib\Compiler.js:665:23)
at processMissingFile (C:\Users\csworen\Downloads\8272.DynamicStackedChart\DynamicStackedChart\node_modules\webpack\lib\Compiler.js:783:24)
PS C:\Users\csworen\Downloads\8272.DynamicStackedChart\DynamicStackedChart>
And another at 13GB (decimal):
PS C:\Users\csworen\Downloads\8272.DynamicStackedChart\DynamicStackedChart> npm start
> dynamic-stacked-chart@0.0.0 start
> node --max_old_space_size=13000 node_modules/@angular/cli/bin/ng serve -o --optimization false
Option "optimization" is deprecated: Use the "optimization" option in the browser builder instead.
⠙ Generating browser application bundles (phase: sealing)...
<--- Last few GCs --->
[15476:04508F88] 34235 ms: Scavenge 703.3 (730.7) -> 701.0 (731.0) MB, 2.4 / 0.0 ms (average mu = 0.202, current mu = 0.103) allocation failure
[15476:04508F88] 34242 ms: Scavenge 703.7 (731.0) -> 701.8 (732.0) MB, 4.1 / 0.0 ms (average mu = 0.202, current mu = 0.103) allocation failure
[15476:04508F88] 34249 ms: Scavenge 704.8 (732.0) -> 702.7 (741.0) MB, 4.2 / 0.0 ms (average mu = 0.202, current mu = 0.103) allocation failure
<--- JS stacktrace --->
FATAL ERROR: Reached heap limit Allocation failed - JavaScript heap out of memory
1: 00FB5D3F v8::internal::Heap::AllocateExternalBackingStore+1551
PS C:\Users\csworen\Downloads\8272.DynamicStackedChart\DynamicStackedChart>
It finally ran again at 14GB (decimal).
From when it actually runs, I generally math the binary GB requirement and update to make sure it still runs. A couple times, I have had to do the next +.5GB.
I made some modifications to keep this process moving forward. I added single scenario tabs and I sorted data so the color coding between Design and Process is working as expected.
I figured out both, actually (single scenario not populating and reload of all tabs when another tab is selected). I also cleaned up the code/structure a bit.
I think I have resolved every issue I needed fixed. I will let you know if something else comes up. Attaching the final results (for now) for reference.
3252.DynamicStackedChart.zip