On query #5 : there is a section called "Working With Usage" in the Developer's Guide and another similarly named section in the Administrator's Guide. These contain details relevant for the audience of each guide. Why not see whether this contains the information you need. If not, it's always possible to file a Doc enhancement bug!
http://cloudstack.apache.org/docs/en-US/Apache_CloudStack/4.1.0/html-single/Developers_Guide/index.html#working-with-usage-data http://cloudstack.apache.org/docs/en-US/Apache_CloudStack/4.1.0/html-single/Admin_Guide/index.html#work-with-usage Jessica T. On Mon, Jun 17, 2013 at 1:06 AM, Wei ZHOU <ustcweiz...@gmail.com> wrote: > 1. No. APIs are for users, not for cloudstack. There is a thread running at > the scheduled time. > 2. No, generateUsageRecords API adds an usage job in database > cloud_usage.usage_job. > 3. There is a thread named Heartbeat in usage server which running every > minute. It checks the database and generates the usage records from last > usage job. > 4. see 3. > 5. I do not know. > > -Wei > > > 2013/6/16 CK <cloudw...@gmail.com> > > > Can anyone help with my queries...? > > > > > > On 10 June 2013 09:21, CK <cloudw...@gmail.com> wrote: > > > > > Can someone please provide further information on what the API call: > > > generateUsageRecords actually does? > > > > > > I know it generates usage records, but: > > > > > > 1. Does the Usage Server service call the generateUsageRecords API when > > > it runs at the scheduled time(=usage.stats.job.exec.time) or does the > > > service do more than that? > > > > > > 2. Does the generateUsageRecords API execute the Usage Server service > on > > > demand to generate the usage records? > > > > > > 3. For what period does it generate the usage records eg. > > > i. from the last time this API function was called > > > ii. from the last time the usage server ran > > > > > > 4. If I create a VM and the corresponding ACS events are created in the > > > Cloud DB, if I then run generateUsageRecords soon after will the usage > > > records be generated for up to that point? > > > > > > 5. Are there any other documented details available on this API command > > > other than the API document? > > > > > >