If a Stream is inactive, pretend to have no packets.
This commit is contained in:
parent
76824b9789
commit
2d2b9ff70f
@ -122,6 +122,11 @@ public class Main {
|
||||
{
|
||||
if (inputNames.add(Integer.toString(streamStatus.input)))
|
||||
{
|
||||
if (streamStatus.status.equalsIgnoreCase("Inactive"))
|
||||
{
|
||||
streamStatus.packets = 0;
|
||||
streamStatus.bytes = 0;
|
||||
}
|
||||
packets.labelValues(Integer.toString(streamStatus.input)).set(streamStatus.packets);
|
||||
bytes.labelValues(Integer.toString(streamStatus.input)).set(streamStatus.bytes);
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user