GaOrtiga commented on code in PR #13939:
URL: https://github.com/apache/cloudstack/pull/13939#discussion_r3844021502


##########
engine/schema/src/main/java/com/cloud/upgrade/dao/Upgrade42020to42030.java:
##########
@@ -18,11 +18,102 @@
 
 import java.io.InputStream;
 import java.sql.Connection;
+import java.sql.PreparedStatement;
+import java.sql.ResultSet;
+import java.sql.SQLException;
 
 import com.cloud.utils.exception.CloudRuntimeException;
 
 public class Upgrade42020to42030 extends DbUpgradeAbstractImpl implements 
DbUpgrade, DbUpgradeSystemVmTemplate {
 
+    private static String SELECT_TEMPLATE = "SELECT `name` FROM 
`cloud`.`email_template` WHERE `name`=\"backup_report_template\";";

Review Comment:
   @JoaoJandre Why are these changes necessary? Adding them to the 4.23 (or 24) 
shouldn't be enough?



##########
api/src/main/java/org/apache/cloudstack/api/command/user/backup/GetBackupReportCmd.java:
##########
@@ -0,0 +1,133 @@
+// Licensed to the Apache Software Foundation (ASF) under one
+// or more contributor license agreements.  See the NOTICE file
+// distributed with this work for additional information
+// regarding copyright ownership.  The ASF licenses this file
+// to you under the Apache License, Version 2.0 (the
+// "License"); you may not use this file except in compliance
+// with the License.  You may obtain a copy of the License at
+//
+//   http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied.  See the License for the
+// specific language governing permissions and limitations
+// under the License.
+
+package org.apache.cloudstack.api.command.user.backup;
+
+import com.cloud.exception.ConcurrentOperationException;
+import com.cloud.exception.InsufficientCapacityException;
+import com.cloud.exception.InvalidParameterValueException;
+import com.cloud.exception.NetworkRuleConflictException;
+import com.cloud.exception.ResourceAllocationException;
+import com.cloud.exception.ResourceUnavailableException;
+import org.apache.cloudstack.acl.RoleType;
+import org.apache.cloudstack.api.APICommand;
+import org.apache.cloudstack.api.ApiConstants;
+import org.apache.cloudstack.api.BaseCmd;
+import org.apache.cloudstack.api.Parameter;
+import org.apache.cloudstack.api.ServerApiException;
+import org.apache.cloudstack.api.response.AccountResponse;
+import org.apache.cloudstack.api.response.BackupReportResponse;
+import org.apache.cloudstack.api.response.DomainResponse;
+import org.apache.cloudstack.api.response.ProjectResponse;
+import org.apache.cloudstack.api.response.ZoneResponse;
+import org.apache.cloudstack.backup.BackupReportService;
+
+import javax.inject.Inject;
+import java.util.Date;
+
+@APICommand(name = "getBackupReport",
+        description = "Get the backup report for the given period",
+        responseObject = BackupReportResponse.class, since = "4.24.0.0", 
authorized = {RoleType.Admin})

Review Comment:
   ```suggestion
           responseObject = BackupReportResponse.class, since = "24.0.0", 
authorized = {RoleType.Admin})
   ```



-- 
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]

Reply via email to