DaanHoogland commented on code in PR #8230:
URL: https://github.com/apache/cloudstack/pull/8230#discussion_r1474335435
##########
usage/src/main/java/com/cloud/usage/parser/VMInstanceUsageParser.java:
##########
@@ -172,10 +174,9 @@ private static void createUsageRecord(int type, long
runningTime, Date startDate
DecimalFormat dFormat = new DecimalFormat("#.######");
String usageDisplay = dFormat.format(usage);
- if (s_logger.isDebugEnabled()) {
- s_logger.debug("Creating VM usage record for vm: " + vmName + ",
type: " + type + ", usage: " + usageDisplay + ", startDate: " + startDate + ",
endDate: " +
- endDate + ", for account: " + account.getId());
- }
+ s_logger.debug(String.format("Creating VM usage record for vm [%s],
type [%s], usage [%s], startDate [%s], and endDate [%s], for account [%s].",
Review Comment:
guard
##########
usage/src/main/java/com/cloud/usage/parser/VMSnapshotOnPrimaryParser.java:
##########
@@ -114,10 +116,9 @@ private static void createUsageRecord(int usageType, long
runningTime, Date star
DecimalFormat dFormat = new DecimalFormat("#.######");
String usageDisplay = dFormat.format(usage);
- if (s_logger.isDebugEnabled()) {
- s_logger.debug("Creating VMSnapshot Id: " + vmSnapshotId + " On
Primary usage record for vm: " + vmId + ", usage: " + usageDisplay + ",
startDate: " + startDate + ", endDate: " + endDate
- + ", for account: " + account.getId());
- }
+ s_logger.debug(String.format("Creating usage record for VMSnapshot
with id [%s] in primary, vm [%s], usage [%s], startDate [%s], and endDate [%s],
for account [%s].",
Review Comment:
guard
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]