Package io.webfolder.cdp.command
Interface MemoryAsync
public interface MemoryAsync
-
Method Summary
Modifier and TypeMethodDescriptionSimulate OomIntervention by purging V8 memory.Retrieve native memory allocations profile collected since renderer process startup.Retrieve native memory allocations profile collected since browser process startup.Retrieve native memory allocations profile collected since last startSampling call.setPressureNotificationsSuppressed
(Boolean suppressed) Enable/disable suppressing memory pressure notifications in all processes.Simulate a memory pressure notification in all processes.Start collecting native memory profile.startSampling
(Integer samplingInterval, Boolean suppressRandomness) Start collecting native memory profile.Stop collecting native memory profile.
-
Method Details
-
forciblyPurgeJavaScriptMemory
CompletableFuture<Void> forciblyPurgeJavaScriptMemory()Simulate OomIntervention by purging V8 memory. -
getAllTimeSamplingProfile
CompletableFuture<SamplingProfile> getAllTimeSamplingProfile()Retrieve native memory allocations profile collected since renderer process startup. -
getBrowserSamplingProfile
CompletableFuture<SamplingProfile> getBrowserSamplingProfile()Retrieve native memory allocations profile collected since browser process startup. -
getDOMCounters
CompletableFuture<GetDOMCountersResult> getDOMCounters()- Returns:
- GetDOMCountersResult
-
getSamplingProfile
CompletableFuture<SamplingProfile> getSamplingProfile()Retrieve native memory allocations profile collected since last startSampling call. -
prepareForLeakDetection
CompletableFuture<Void> prepareForLeakDetection() -
setPressureNotificationsSuppressed
Enable/disable suppressing memory pressure notifications in all processes.- Parameters:
suppressed
- If true, memory pressure notifications will be suppressed.
-
simulatePressureNotification
Simulate a memory pressure notification in all processes.- Parameters:
level
- Memory pressure level of the notification.
-
startSampling
CompletableFuture<Void> startSampling()Start collecting native memory profile. -
startSampling
Start collecting native memory profile.- Parameters:
samplingInterval
- Average number of bytes between samples.suppressRandomness
- Do not randomize intervals between samples.
-
stopSampling
CompletableFuture<Void> stopSampling()Stop collecting native memory profile.
-