cloudstack-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From karuturi <...@git.apache.org>
Subject [GitHub] cloudstack pull request: CLOUDSTACK-7930, CLOUDSTACK-7931: Do not ...
Date Tue, 18 Nov 2014 09:02:08 GMT
Github user karuturi commented on a diff in the pull request:

    https://github.com/apache/cloudstack/pull/41#discussion_r20492616
  
    --- Diff: server/src/com/cloud/configuration/ConfigurationManagerImpl.java ---
    @@ -725,6 +725,21 @@ private String validateConfigurationValue(String name, String value,
String scop
                 type = c.getType();
             }
     
    +        String errMsg = null;
    +        try {
    +            if (type.equals(Integer.class)) {
    +                errMsg = "There was error in trying to parse value: " + value + ". Please
enter a valid integer value for parameter " + name;
    +                Integer.parseInt(value);
    +            } else if (type.equals(Float.class)) {
    +                errMsg = "There was error in trying to parse value: " + value + ". Please
enter a valid float value for parameter " + name;
    +                Float.parseFloat(value);
    --- End diff --
    
    I understand that it will fail during parsing. But, we can string replace "," with ""


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

Mime
View raw message