You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by GitBox <gi...@apache.org> on 2020/12/08 14:51:27 UTC
[GitHub] [cloudstack] ravening commented on a change in pull request #4522: template: Copying templates to all zones if type changed to system
ravening commented on a change in pull request #4522:
URL: https://github.com/apache/cloudstack/pull/4522#discussion_r538457598
##########
File path: server/src/main/java/com/cloud/template/TemplateManagerImpl.java
##########
@@ -2224,6 +2232,21 @@ else if (details != null && !details.isEmpty()) {
return _tmpltDao.findById(id);
}
+ private void copyTemplateToAllZones(Long id) {
+ s_logger.info("Copying template to all zones since it will be a system template");
+ List<DataCenterVO> zones = _dcDao.listEnabledZones();
+ if (zones != null) {
+ List<Long> zoneIds = zones.stream().map(zone -> zone.getId()).collect(Collectors.toList());
Review comment:
Should we skip the zone on which the template is already in?
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org