You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cloudstack.apache.org by "Ilia Shakitko (JIRA)" <ji...@apache.org> on 2014/11/03 15:23:34 UTC

[jira] [Commented] (CLOUDSTACK-6850) Cpu cores, cpu speed and memory are not returned by listUsageRecords

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

Ilia Shakitko commented on CLOUDSTACK-6850:
-------------------------------------------

I am not able to see those records in 4.4.2: command=listUsageRecords&response=json&startdate=2014-11-03&enddate=2014-11-03&type=2

class stdClass#1 (1) {
  public $listusagerecordsresponse =>
  class stdClass#2 (2) {
    public $count =>
    int(6)
    public $usagerecord =>
    array(6) {
      [0] =>
      class stdClass#3 (16) {
        public $account =>
        string(6) "ISH001"
        public $accountid =>
        string(36) "e2104bd7-dc87-4528-9d69-7141c79d7879"
        public $domainid =>
        string(36) "8255b58c-39d1-4221-837f-3a6a8ed84a3f"
        public $zoneid =>
        string(36) "75cb86ef-d0e0-4459-b781-0a31002f2786"
        public $description =>
        string(55) "wolkvm01 allocated (ServiceOffering: 1) (Template: 201)"
        public $usage =>
        string(12) "0.166666 Hrs"
        public $usagetype =>
        int(2)
        public $rawusage =>
        string(8) "0.166666"
        public $virtualmachineid =>
        string(36) "5a2c057a-6aff-44ae-8b65-ff524c8c2007"
        public $name =>
        string(8) "wolkvm01"
        public $offeringid =>
        string(36) "39f423ca-9c83-4061-9ad6-4f5b48fa312c"
        public $templateid =>
        string(36) "92b60dfd-11a3-4b47-8a93-1a65cef9619f"
        public $usageid =>
        string(36) "5a2c057a-6aff-44ae-8b65-ff524c8c2007"
        public $type =>
        string(3) "KVM"
        public $startdate =>
        string(27) "2014-11-03'T'15:05:00+01:00"
        public $enddate =>
        string(27) "2014-11-03'T'15:15:00+01:00"
      }
      [1] =>
      class stdClass#4 (16) {
        public $account =>
        string(6) "ISH001"
        public $accountid =>
        string(36) "e2104bd7-dc87-4528-9d69-7141c79d7879"
        public $domainid =>
        string(36) "8255b58c-39d1-4221-837f-3a6a8ed84a3f"
        public $zoneid =>
        string(36) "75cb86ef-d0e0-4459-b781-0a31002f2786"
        public $description =>
        string(55) "wolkvm01 allocated (ServiceOffering: 1) (Template: 201)"
        public $usage =>
        string(12) "0.166667 Hrs"
        public $usagetype =>
        int(2)
        public $rawusage =>
        string(8) "0.166667"
        public $virtualmachineid =>
        string(36) "5a2c057a-6aff-44ae-8b65-ff524c8c2007"
        public $name =>
        string(8) "wolkvm01"
        public $offeringid =>
        string(36) "39f423ca-9c83-4061-9ad6-4f5b48fa312c"
        public $templateid =>
        string(36) "92b60dfd-11a3-4b47-8a93-1a65cef9619f"
        public $usageid =>
        string(36) "5a2c057a-6aff-44ae-8b65-ff524c8c2007"
        public $type =>
        string(3) "KVM"
        public $startdate =>
        string(27) "2014-11-03'T'14:55:00+01:00"
        public $enddate =>
        string(27) "2014-11-03'T'15:05:00+01:00"
      }
}}}

> Cpu cores, cpu speed and memory are not returned by listUsageRecords
> --------------------------------------------------------------------
>
>                 Key: CLOUDSTACK-6850
>                 URL: https://issues.apache.org/jira/browse/CLOUDSTACK-6850
>             Project: CloudStack
>          Issue Type: Bug
>      Security Level: Public(Anyone can view this level - this is the default.) 
>          Components: Usage
>    Affects Versions: 4.3.0, 4.4.0
>            Reporter: Olivier Lemasle
>            Assignee: Olivier Lemasle
>            Priority: Critical
>             Fix For: 4.4.0
>
>
> When using dynamic custom offerings, cpu cores, cpu speed and ram values are recorded in usage_vm_instance table while parsing the usage events.
> But these details are not populated in cloud_usage table, and are not returned by the listUsageRecords command. Therefore, there is no way to know the historical values for cpu and memory using API.
> We should add cpu_cores, cpu_speed and memory in cloud_usage.cloud_usage and return them in listUsageRecords response.



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