This is an automated email from the ASF dual-hosted git repository.
bhaisaab pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/cloudstack.git
The following commit(s) were added to refs/heads/master by this push:
new 4dd8b5d CLOUDSTACK-9563: ExtractTemplate returns malformed URL after
migrating NFS to s3 (#1733)
4dd8b5d is described below
commit 4dd8b5d0615ceeeedf698c8bc23fc031ad841ab3
Author: SudharmaJain <[email protected]>
AuthorDate: Fri Sep 1 14:53:41 2017 +0530
CLOUDSTACK-9563: ExtractTemplate returns malformed URL after migrating NFS
to s3 (#1733)
While downloading the template for the first time install path was not
available. During first download after migration template is synced to s3
storage and template install path is updated to DB. But while generating the
extract URL we are still taking install path from TemplateDataStoreVO object
cached in the process.
---
server/src/com/cloud/template/TemplateManagerImpl.java | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/server/src/com/cloud/template/TemplateManagerImpl.java
b/server/src/com/cloud/template/TemplateManagerImpl.java
index 1b7eb53..86f687c 100644
--- a/server/src/com/cloud/template/TemplateManagerImpl.java
+++ b/server/src/com/cloud/template/TemplateManagerImpl.java
@@ -542,7 +542,7 @@ public class TemplateManagerImpl extends ManagerBase
implements TemplateManager,
_tmpltSvr.syncTemplateToRegionStore(templateId, tmpltStore);
TemplateInfo templateObject = _tmplFactory.getTemplate(templateId,
tmpltStore);
- String extractUrl =
tmpltStore.createEntityExtractUrl(tmpltStoreRef.getInstallPath(),
template.getFormat(), templateObject);
+ String extractUrl =
tmpltStore.createEntityExtractUrl(templateObject.getInstallPath(),
template.getFormat(), templateObject);
tmpltStoreRef.setExtractUrl(extractUrl);
tmpltStoreRef.setExtractUrlCreated(DateUtil.now());
_tmplStoreDao.update(tmpltStoreRef.getId(), tmpltStoreRef);
--
To stop receiving notification emails like this one, please contact
['"[email protected]" <[email protected]>'].