Committed by
Brian O'Connor
GUI -- Topo View - Clip bit rate to 10.0 Gbps - temporary measure for CORD Fabric demo at ONS 2015.
Change-Id: I840cbd6ff45fe502221d176b5a4d7cfa8d18237f
Showing
1 changed file
with
8 additions
and
1 deletions
... | @@ -796,7 +796,7 @@ public abstract class TopologyViewMessageHandlerBase extends UiMessageHandler { | ... | @@ -796,7 +796,7 @@ public abstract class TopologyViewMessageHandlerBase extends UiMessageHandler { |
796 | return format.format(value) + " " + unit; | 796 | return format.format(value) + " " + unit; |
797 | } | 797 | } |
798 | 798 | ||
799 | - // Poor-mans formatting to get the labels with byte counts looking nice. | 799 | + // Poor-mans formatting to get the labels with bit rate looking nice. |
800 | private String formatBitRate(long bytes) { | 800 | private String formatBitRate(long bytes) { |
801 | String unit; | 801 | String unit; |
802 | double value; | 802 | double value; |
... | @@ -805,6 +805,13 @@ public abstract class TopologyViewMessageHandlerBase extends UiMessageHandler { | ... | @@ -805,6 +805,13 @@ public abstract class TopologyViewMessageHandlerBase extends UiMessageHandler { |
805 | if (bits > GIGA) { | 805 | if (bits > GIGA) { |
806 | value = bits / GIGA; | 806 | value = bits / GIGA; |
807 | unit = GBITS_UNIT; | 807 | unit = GBITS_UNIT; |
808 | + | ||
809 | + // NOTE: temporary hack to clip rate at 10.0 Gbps | ||
810 | + // Added for the CORD Fabric demo at ONS 2015 | ||
811 | + if (value > 10.0) { | ||
812 | + value = 10.0; | ||
813 | + } | ||
814 | + | ||
808 | } else if (bits > MEGA) { | 815 | } else if (bits > MEGA) { |
809 | value = bits / MEGA; | 816 | value = bits / MEGA; |
810 | unit = MBITS_UNIT; | 817 | unit = MBITS_UNIT; | ... | ... |
-
Please register or login to post a comment