public class GridLogThrottle extends Object
Errors are logged only if they were not logged for the last
throttleTimeout number of minutes.
Note that not only error messages are checked for duplicates, but also exception
classes.
| Modifier and Type | Field and Description |
|---|---|
static int |
DFLT_THROTTLE_TIMEOUT
Default throttle timeout in milliseconds (value is 5 * 60 * 1000).
|
| Modifier | Constructor and Description |
|---|---|
protected |
GridLogThrottle()
Ensure singleton.
|
| Modifier and Type | Method and Description |
|---|---|
static void |
clear()
Clears all stored data.
|
static void |
error(IgniteLogger log,
Throwable e,
String msg)
Logs error if needed.
|
static void |
info(IgniteLogger log,
String msg)
Logs info if needed.
|
static void |
info(IgniteLogger log,
String msg,
boolean quite)
Logs info if needed.
|
static long |
throttleTimeout()
Gets system-wide log throttle timeout.
|
static void |
throttleTimeout(int timeout)
Sets system-wide log throttle timeout.
|
static void |
warn(IgniteLogger log,
Throwable e,
String msg)
Logs warning if needed.
|
static void |
warn(IgniteLogger log,
Throwable e,
String msg,
boolean quite)
Logs warning if needed.
|
static void |
warn(IgniteLogger log,
Throwable e,
String longMsg,
String shortMsg)
Logs warning if needed.
|
public static final int DFLT_THROTTLE_TIMEOUT
public static void throttleTimeout(int timeout)
timeout - System-wide log throttle timeout.public static long throttleTimeout()
public static void error(@Nullable
IgniteLogger log,
@Nullable
Throwable e,
String msg)
log - Logger.e - Error (optional).msg - Message.public static void warn(@Nullable
IgniteLogger log,
@Nullable
Throwable e,
String msg)
log - Logger.e - Error (optional).msg - Message.public static void warn(@Nullable
IgniteLogger log,
@Nullable
Throwable e,
String msg,
boolean quite)
log - Logger.e - Error (optional).msg - Message.quite - Print warning anyway.public static void warn(@Nullable
IgniteLogger log,
@Nullable
Throwable e,
String longMsg,
@Nullable
String shortMsg)
log - Logger.e - Error (optional).longMsg - Long message (or just message).shortMsg - Short message for quite logging.public static void info(@Nullable
IgniteLogger log,
String msg,
boolean quite)
log - Logger.msg - Message.quite - Print info anyway.public static void info(@Nullable
IgniteLogger log,
String msg)
log - Logger.msg - Message.public static void clear()
Follow @ApacheIgnite
Ignite Fabric : ver. 1.7.0 Release Date : August 1 2016