Skip to content

Commit

Permalink
优化告警规则
Browse files Browse the repository at this point in the history
  • Loading branch information
calvin1978 committed Nov 12, 2018
1 parent b6ee63b commit 8d58371
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions vjtop/src/main/java/com/vip/vjtools/vjtop/WarningRule.java
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,14 @@
import com.vip.vjtools.vjtop.util.Formats;

public class WarningRule {

public DoubleWarning cpu = new DoubleWarning(50d, 70d);

public LongWarning swap = new LongWarning(1, 1);
public LongWarning thread = new LongWarning();
public LongWarning newThread = new LongWarning();
public LongWarning newThread = new LongWarning(1, Long.MAX_VALUE);
public LongWarning io = new LongWarning(100 * Formats.MB_SIZE, Long.MAX_VALUE);

public LongWarning loadClass = new LongWarning(80000, 150000);
public LongWarning loadClass = new LongWarning(80000, Long.MAX_VALUE);
public LongWarning newClass = new LongWarning(1, Long.MAX_VALUE);

public LongWarning old = new LongWarning();
Expand All @@ -31,8 +30,6 @@ public void updateProcessor(int processors) {
}

public void updateInterval(long intervalSeconds) {
newThread.yellow = 1;
newThread.red = intervalSeconds * 2;

ygcTime.yellow = intervalSeconds * 1000 * 5 / 100; // 5% interval
ygcTime.red = intervalSeconds * 1000 * 10 / 100; // 10% interval
Expand Down

0 comments on commit 8d58371

Please sign in to comment.