public class GovernorSchedUtil extends Governor
Modifier and Type | Field | Description |
---|---|---|
static long |
MAX_RATE_LIMIT |
Maximum value of timer rate: microseconds.
|
static long |
MIN_RATE_LIMIT |
Minimum value of timer rate: microseconds.
|
governorType, manager, PATH_GOVERNOR_SETTINGS
Modifier and Type | Method | Description |
---|---|---|
long |
getDownRateLimit() |
Gets the amount of microseconds Schedutil must wait before decreasing
the frequency.
|
protected java.lang.String |
getTag() |
Returns the class tag used for logging purposes.
|
long |
getUpRateLimit() |
Gets the amount of microseconds Schedutil must wait before increasing
the frequency.
|
void |
setDownRateLimit(long limit) |
Sets the amount of microseconds Schedutil must wait before decreasing
the frequency.
|
void |
setUpRateLimit(long limit) |
Sets the amount of microseconds Schedutil must wait before increasing
the frequency.
|
getGovernorType, getSettingPath, readFile, writeFile
public static final long MAX_RATE_LIMIT
public static final long MIN_RATE_LIMIT
protected java.lang.String getTag()
Governor
public long getDownRateLimit() throws CPUException
CPUException
- If there is an error during the configuration
process.MAX_RATE_LIMIT
,
MIN_RATE_LIMIT
,
getUpRateLimit()
,
setDownRateLimit(long)
,
setUpRateLimit(long)
public void setDownRateLimit(long limit) throws CPUException
limit
- Time in microseconds.CPUException
- If there is an error during the configuration
process.java.lang.IllegalArgumentException
- If limit < MIN_RATE_LIMIT
or
if limit > MAX_RATE_LIMIT
.MAX_RATE_LIMIT
,
MIN_RATE_LIMIT
,
getDownRateLimit()
,
getUpRateLimit()
,
setUpRateLimit(long)
public long getUpRateLimit() throws CPUException
CPUException
- If there is an error during the configuration
process.MAX_RATE_LIMIT
,
MIN_RATE_LIMIT
,
getDownRateLimit()
,
setDownRateLimit(long)
,
setUpRateLimit(long)
public void setUpRateLimit(long limit) throws CPUException
limit
- Time in microseconds.CPUException
- If there is an error during the configuration
process.java.lang.IllegalArgumentException
- If limit < MIN_RATE_LIMIT
or
if limit > MAX_RATE_LIMIT
.MAX_RATE_LIMIT
,
MIN_RATE_LIMIT
,
getDownRateLimit()
,
getUpRateLimit()
,
setDownRateLimit(long)