Clone Tools
  • last updated a few seconds ago
Constraints
Constraints: committers
 
Constraints: files
Constraints: dates
Relax what we check for in the daemon health stats unit test

Make test Locale independent

Introduce test that simulates GC activity

    • -3
    • +3
    ./gc/GarbageCollectionMonitorTest.groovy
  1. … 5 more files in changeset.
Rework daemon GC/memory expiration checks

- Do not sniff for VM vendor to figure out which GC strategies may be used

- Rename permgen -> non-heap in most places, Java 8+ uses metaspace for this memory pool

- Rename tenured -> heap

- Only add GarbageCollectionEvents to the observation window when there's been a GC collection

- This simplifies the calculation of GC rate

- Non-heap memory pools are not GC'd

- Re-enable daemon performance soak test

    • -100
    • +55
    ./DaemonMemoryStatusTest.groovy
    • -0
    • +53
    ./LowHeapSpaceDaemonExpirationStrategyTest.groovy
    • -0
    • +53
    ./LowNonHeapDaemonExpirationStrategyTest.groovy
    • -53
    • +0
    ./LowPermGenDaemonExpirationStrategyTest.groovy
    • -53
    • +0
    ./LowTenuredSpaceDaemonExpirationStrategyTest.groovy
    • -23
    • +4
    ./gc/GarbageCollectionMonitorTest.groovy
    • -13
    • +54
    ./gc/GarbageCollectionStatsTest.groovy
  1. … 18 more files in changeset.
Do not wait on memory status event on daemon startup

We only need Runtime.getRuntime().maxMemory() in DaemonHealthStats

  1. … 2 more files in changeset.
Refine memory sampling event publishing

Merge MemoryStatusBroadcaster into MemoryManager

Broadcast start/stop is now isolated in MemoryManager

DaemonHealthStats wait for one JVM memory event

Strengthen tests around health logging

Services depend on ExecutorFactory to use ScheduledExecutorServices

And stop them properly

  1. … 14 more files in changeset.
Refine memory sampling event publishing

Move MemoryStatusBroadcaster startup to DefaultGradleLauncherFactory

Add support for ScheduledExecutors to ExecutorFactory

& Stoppable & honoring ExecutorPolicy

Move global scheduled executor creation to GlobalScopeServices

Don’t use anonymous broadcasters

DaemonHealthStats now consume memory sampling events

  1. … 20 more files in changeset.
Split JVM/OS memory events and add coverage

    • -6
    • +6
    ./LowMemoryDaemonExpirationStrategyTest.groovy
  1. … 16 more files in changeset.
Move process memory related code into :core

    • -1
    • +1
    ./LowMemoryDaemonExpirationStrategyTest.groovy
    • -132
    • +0
    ./memory/MeminfoAvailableMemoryTest.groovy
    • -53
    • +0
    ./memory/VmstatAvailableMemoryTest.groovy
  1. … 35 more files in changeset.
Initial implementation of an event-based memory broadcaster

    • -14
    • +33
    ./LowMemoryDaemonExpirationStrategyTest.groovy
  1. … 12 more files in changeset.
Fix meminfo reading on Linux systems.

- Improve calculation of free memory on Linux 3.x where MemAvailable

is not available. Add Linux 3.x tests

- Break MemoryInfo apart into classes using Strategy pattern for

getting available memory depending on OS

- Eliminate unnecessary logic in LowMemoryDaemonExpirationStrategy

+review REVIEW-6218

    • -45
    • +14
    ./LowMemoryDaemonExpirationStrategyTest.groovy
    • -0
    • +132
    ./memory/MeminfoAvailableMemoryTest.groovy
    • -0
    • +57
    ./memory/MemoryInfoTest.groovy
    • -0
    • +53
    ./memory/VmstatAvailableMemoryTest.groovy
  1. … 12 more files in changeset.
Aggressively terminate duplicate idle Daemons under low memory.

- Set reasonable threshold bounds of 384Mb to 1Gb for low memory

detection.

- Reduce idle timeout to 10 seconds for Daemons that are not

most recently used when available system memory is < 5% of total.

+review REVIEW-6215

    • -11
    • +27
    ./LowMemoryDaemonExpirationStrategyTest.groovy
  1. … 2 more files in changeset.
Fix free memory calculation on Linux and MacOS.

The OperatingSystem MBean does not consider memory used for the

disk cache when calculating free memory. This causes measured

available memory to be low on *nix systems, resulting in Daemons

expiring prematurely due to our low memory conditions.

This commit changes MemoryInfo to parse vm_stat output on MacOS

and pars /proc/meminfo output on Linux. This includes memory

that can be reclaimed for applications at no cost, so we factor

that into available memory.

+review REVIEW-6218

  1. … 2 more files in changeset.
Improve Daemon start message. +review REVIEW-5986

    • -1
    • +1
    ./GcThrashingDaemonExpirationStrategyTest.groovy
    • -3
    • +3
    ./LowMemoryDaemonExpirationStrategyTest.groovy
    • -1
    • +1
    ./LowPermGenDaemonExpirationStrategyTest.groovy
    • -1
    • +1
    ./LowTenuredSpaceDaemonExpirationStrategyTest.groovy
  1. … 15 more files in changeset.
More improvements to daemon expiration messages

+review REVIEW-5986

    • -1
    • +1
    ./LowMemoryDaemonExpirationStrategyTest.groovy
  1. … 5 more files in changeset.
Improving daemon expiration messages

+review REVIEW-5986

    • -1
    • +1
    ./GcThrashingDaemonExpirationStrategyTest.groovy
    • -1
    • +1
    ./LowMemoryDaemonExpirationStrategyTest.groovy
    • -1
    • +1
    ./LowPermGenDaemonExpirationStrategyTest.groovy
    • -1
    • +1
    ./LowTenuredSpaceDaemonExpirationStrategyTest.groovy
  1. … 5 more files in changeset.
Introduce DaemonRunningStats and detangle daemon classes.

Introducing this exposed incestuous relationships between packages that triggered the restructure.

+review

    • -0
    • +78
    ./DaemonHealthStatsTest.groovy
    • -0
    • +170
    ./DaemonMemoryStatusTest.groovy
    • -0
    • +53
    ./GcThrashingDaemonExpirationStrategyTest.groovy
    • -0
    • +116
    ./LowMemoryDaemonExpirationStrategyTest.groovy
    • -0
    • +53
    ./LowPermGenDaemonExpirationStrategyTest.groovy
    • -0
    • +53
    ./LowTenuredSpaceDaemonExpirationStrategyTest.groovy
  1. … 67 more files in changeset.
Added tests to guard against future NPEs caused by trying to collect stats from unsupported GCs

    • -0
    • +22
    ./gc/GarbageCollectionMonitorTest.groovy
Internally expose basic daemon information (cherry picked from commit 2a9b6b5)

  1. … 12 more files in changeset.
Refactoring DaemonStatus to eliminate duplicate logic

+review REVIEW-5981

  1. … 1 more file in changeset.
Changing daemon health check to use expiration strategy

+review REVIEW-5981

  1. … 16 more files in changeset.
Merged 2.14-rc-1 into master

  1. … 10 more files in changeset.
Cleaning up log messages when no GC has happened

+review REVIEW-5946

  1. … 3 more files in changeset.
Detect when daemon is thrashing

+review REVIEW-5981

  1. … 17 more files in changeset.
Tightening up unit test for perm gen monitoring

+review REVIEW-5973

  1. … 2 more files in changeset.
Adding support for monitoring perm gen usage

+review REVIEW-5973

    • -1
    • +2
    ./gc/GarbageCollectionMonitorTest.groovy
  1. … 7 more files in changeset.
Cleanup of daemon low heap detection classes

+review REVIEW-5946

  1. … 6 more files in changeset.
Improving test coverage for low heap detection

+review REVIEW-5946

    • -0
    • +45
    ./gc/DefaultSlidingWindowTest.groovy
    • -0
    • +51
    ./gc/GarbageCollectionMonitorTest.groovy
  1. … 5 more files in changeset.
DaemonStatsTest assertions are now Locale aware

Fixing broken unit test

+review REVIEW-5946