[ 
https://issues.apache.org/jira/browse/ARTEMIS-3993?focusedWorklogId=833334&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-833334
 ]

ASF GitHub Bot logged work on ARTEMIS-3993:
-------------------------------------------

                Author: ASF GitHub Bot
            Created on: 14/Dec/22 08:55
            Start Date: 14/Dec/22 08:55
    Worklog Time Spent: 10m 
      Work Description: michaelandrepearce commented on code in PR #4312:
URL: https://github.com/apache/activemq-artemis/pull/4312#discussion_r1048176649


##########
artemis-commons/src/main/java/org/apache/activemq/artemis/utils/ByteUtil.java:
##########
@@ -39,9 +39,9 @@ public class ByteUtil {
    private static final String prefix = "^\\s*(\\d+)\\s*";
    private static final String suffix = "(b)?\\s*$";
    private static final Pattern ONE = Pattern.compile(prefix + suffix, 
Pattern.CASE_INSENSITIVE);
-   private static final Pattern KILO = Pattern.compile(prefix + "k" + suffix, 
Pattern.CASE_INSENSITIVE);
-   private static final Pattern MEGA = Pattern.compile(prefix + "m" + suffix, 
Pattern.CASE_INSENSITIVE);
-   private static final Pattern GIGA = Pattern.compile(prefix + "g" + suffix, 
Pattern.CASE_INSENSITIVE);
+   private static final Pattern KILO = Pattern.compile(prefix + "ki?" + 
suffix, Pattern.CASE_INSENSITIVE);

Review Comment:
   This will break anyone using existing styles. Add new style support but 
don't break existing





Issue Time Tracking
-------------------

    Worklog Id:     (was: 833334)
    Time Spent: 40m  (was: 0.5h)

> WebConsole shows sizes in KB but actually uses 1024 multipliers
> ---------------------------------------------------------------
>
>                 Key: ARTEMIS-3993
>                 URL: https://issues.apache.org/jira/browse/ARTEMIS-3993
>             Project: ActiveMQ Artemis
>          Issue Type: Bug
>          Components: Web Console
>    Affects Versions: 2.25.0
>            Reporter: Erwin Dondorp
>            Priority: Minor
>         Attachments: screenshot-1.png, screenshot-2.png, screenshot-3.png
>
>          Time Spent: 40m
>  Remaining Estimate: 0h
>
> To make the actual size clear, the binary version of the prefix should be 
> used.
> See https://en.wikipedia.org/wiki/Binary_prefix
> changes:
> * apply binary prefixes on output, e.g. Ki/Mi/Gi
> * recognize binary prefixes on input, continue recognizing previous style 
> which uses the "K/M/G" prefixes but was already 1024 based.
> * make units consistent: always present with uppercase first character 
> Ki/Mi/Gi (not k/m/g)
> * updated documentation to match
> Status screen:
> !screenshot-1.png! 
> Browse queue (queue):
> !screenshot-2.png! 
> Browse queue (message):
> !screenshot-3.png!



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to