cloudstack
cloudstack copied to clipboard
generateUsageRecords does not work
According to CloudStack API description:
https://cloudstack.apache.org/api/apidocs-4.17/apis/generateUsageRecords.html
Generates usage records. This will generate records only if there any records to be generated, i.e if the scheduled usage job was not run or failed
startdate and enddate are required parameters of the API. However, both seem not used (and domainid as well).
https://github.com/apache/cloudstack/blob/d288bb0c78e0f3964982926070bd14785c88a441/server/src/main/java/com/cloud/usage/UsageServiceImpl.java#L140-L164
ISSUE TYPE
- Bug Report
COMPONENT NAME
Usage
CLOUDSTACK VERSION
4.18
CONFIGURATION
OS / ENVIRONMENT
SUMMARY
STEPS TO REPRODUCE
EXPECTED RESULTS
ACTUAL RESULTS
I checked the code and noticed that we don't use the startDate and endDate anywhere in the job. start_date and end_date columns in usage_job table are used only for logging purposes as of now.