cloudstack-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF GitHub Bot (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CLOUDSTACK-9417) Usage module refactoring
Date Tue, 16 Aug 2016 15:23:20 GMT

    [ https://issues.apache.org/jira/browse/CLOUDSTACK-9417?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15422882#comment-15422882
] 

ASF GitHub Bot commented on CLOUDSTACK-9417:
--------------------------------------------

Github user rafaelweingartner commented on a diff in the pull request:

    https://github.com/apache/cloudstack/pull/1593#discussion_r74957023
  
    --- Diff: usage/src/com/cloud/usage/UsageSanityChecker.java ---
    @@ -72,7 +72,9 @@ protected boolean checkItemCountByPstmt(CheckCase checkCase) throws
SQLException
             try (PreparedStatement pstmt = conn.prepareStatement(checkCase.sqlTemplate))
{
                 if(checkCase.checkId) {
                     pstmt.setInt(1, lastId);
    -                pstmt.setInt(2, maxId);
    +                if (maxId > 0) {
    +                    pstmt.setInt(2, maxId);
    --- End diff --
    
    @nvazquez thanks for the explanation. Now I understood it a little bit more. These SLQs
that are built using if(s)/else(s) and use few methods are a bit hard to follow sometimes
without debugging it in runtime.
    
    This was my only doubt. So, LGTM here.



> Usage module refactoring
> ------------------------
>
>                 Key: CLOUDSTACK-9417
>                 URL: https://issues.apache.org/jira/browse/CLOUDSTACK-9417
>             Project: CloudStack
>          Issue Type: Bug
>      Security Level: Public(Anyone can view this level - this is the default.) 
>          Components: Usage
>    Affects Versions: 4.9.0
>            Reporter: Nicolas Vazquez
>            Assignee: Nicolas Vazquez
>             Fix For: 4.9.1
>
>
> h3. Introduction
> Usage sanity check file was not been updated on sanity check.
> It is proposed:
> * New usage folder {{/var/cache/cloudstack/usage}}, creation on cloudstack-usage package
built.
> * New sanity check file location in new folder {{/var/cache/cloudstack/usage}}
> * Timestamp included in {{usage.log}} file
> * Include {{updateMaxId()}} on sanity check as it wasn't being updated



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message