You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[job][logs] FTR Configs #19 / Endpoint plugin @ess @serverless @skipInServerlessMKI Endpoint policy response api GET /api/endpoint/policy_response "before all" hook for "should return one policy response for an id"
[job][logs] Jest Integration Tests #9 / workflow with wait step when duration is short should have correct workflow duration
Total count of every any typed public API. Target amount is 0. Run node scripts/build_api_docs --plugin [yourplugin] --stats any for more detailed information.
Patch made by @gsoldevila included in this PR seems to have a marked improvement in memory consumption while profiling prebuilt rule installation using kibana-puppetter-scripts in my local machine.
Note that peak usage drops by around 41MB and average almost by 100MB. Since this is running locally in --dev mode the figures are different than in prod but at least its a clear indication there has been a big improvement. Note that on the second (right) data set GC also appears less aggressive since more memory is available to the process (due to lower overall baseline) and there is a higher memory budget to play with. This could mean that mean peak memory is even lower (as in greater difference than 41MB) if we reduced the max_old_space_size even further.
Local Kibana was started in --dev mode with memory profiling enabled (KBN_MEM_PROFILE / --mem-profile), producing kibana-memory-profile-*.csv and kibana.output.*.txt per run.
1400 in the folder names refers to NODE_OPTIONS="--max_old_space_size=1400" (1400 MiB V8 old-space limit).
First 30 seconds excluded relative to the first row’s timestamp_ms (startup/warmup omitted); all remaining samples in the ~5 minute profile window are included.
Peak = maximum heap_used after the cutoff; average = arithmetic mean of heap_used after the cutoff.
Results (after 30 s cutoff)
main (main-1400-round*)
Run
Peak heap_used
Avg heap_used
round1
1235.66 MiB
1121.35 MiB
round2
1257.13 MiB
1100.33 MiB
round3
1242.56 MiB
1120.50 MiB
Mean of 3 runs
1245.12 MiB
1114.06 MiB
zod-patch (zod-patch-1400-round*)
Run
Peak heap_used
Avg heap_used
round1
1205.73 MiB
1019.57 MiB
round2
1216.71 MiB
1022.62 MiB
round3
1188.32 MiB
1022.64 MiB
Mean of 3 runs
1203.59 MiB
1021.61 MiB
Which set is more memory efficient?
zod-patch is more memory efficient on this data: lower peak and lower average heap_used in every run versus main, and lower means across the three runs (~41 MiB lower mean peak, ~92 MiB lower mean average heap after the 30 s cutoff).
Logs
Console captures (kibana.output.*.txt alongside each CSV) were spot-checked for heap OOM / allocation failed style messages; none were found in these runs. For deeper log comparison (errors, warnings counts), diff the kibana.output files per folder.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR contains Zod v4 patched in gsoldevila/zod#1.