public class Load extends Object
Represents the load that a Bolt is currently under to help in deciding where to route a tuple, to help balance the load.
Constructor and Description |
---|
Load(boolean hasMetrics,
double boltLoad,
double connectionLoad)
Create a new load.
|
Modifier and Type | Method and Description |
---|---|
double |
getBoltLoad()
Get bolt load.
|
double |
getConnectionLoad()
Get connection load.
|
double |
getLoad()
Get load.
|
boolean |
hasMetrics()
Check whether has metrics.
|
String |
toString() |
public Load(boolean hasMetrics, double boltLoad, double connectionLoad)
Create a new load.
hasMetrics
- have metrics been reported yet?boltLoad
- the load as reported by the bolt 0.0 no load 1.0 fully loadedconnectionLoad
- the load as reported by the connection to the bolt 0.0 no load 1.0 fully loaded.public boolean hasMetrics()
Check whether has metrics.
public double getBoltLoad()
Get bolt load.
public double getConnectionLoad()
Get connection load.
public double getLoad()
Get load.
Copyright © 2020 The Apache Software Foundation. All rights reserved.