You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by ra...@apache.org on 2017/02/08 08:14:44 UTC
[1/3] git commit: updated refs/heads/master to 25f1552
Repository: cloudstack
Updated Branches:
refs/heads/master e303baa1b -> 25f1552e3
CLOUDSTACK-4858 Honors the snapshot.backup.rightafter configuration variable
Unhides snapshot.backup.rightafter from global configuration
If snapshot.backup.rightafter is set to false (defaults to true), snapshots are
not backed up to secondary storage
Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/1a55a93f
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/1a55a93f
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/1a55a93f
Branch: refs/heads/master
Commit: 1a55a93f04a0ab5b14c090d4b80f36150e6157ad
Parents: cc043e9
Author: Nathan Johnson <nj...@ena.com>
Authored: Fri Sep 30 09:39:27 2016 -0500
Committer: Nathan Johnson <nj...@ena.com>
Committed: Fri Sep 30 09:39:27 2016 -0500
----------------------------------------------------------------------
.../orchestration/VolumeOrchestrator.java | 23 ++++++++++++++++++++
.../SnapshotStateMachineManagerImpl.java | 1 +
.../snapshot/XenserverSnapshotStrategy.java | 19 +++++++++++++++-
server/src/com/cloud/configuration/Config.java | 2 +-
.../storage/snapshot/SnapshotManagerImpl.java | 8 ++++++-
.../com/cloud/template/TemplateManagerImpl.java | 20 +++++++++++++++++
.../cloud/template/TemplateManagerImplTest.java | 9 ++++++++
7 files changed, 79 insertions(+), 3 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cloudstack/blob/1a55a93f/engine/orchestration/src/org/apache/cloudstack/engine/orchestration/VolumeOrchestrator.java
----------------------------------------------------------------------
diff --git a/engine/orchestration/src/org/apache/cloudstack/engine/orchestration/VolumeOrchestrator.java b/engine/orchestration/src/org/apache/cloudstack/engine/orchestration/VolumeOrchestrator.java
index ca4ef4f..ea6a66d 100644
--- a/engine/orchestration/src/org/apache/cloudstack/engine/orchestration/VolumeOrchestrator.java
+++ b/engine/orchestration/src/org/apache/cloudstack/engine/orchestration/VolumeOrchestrator.java
@@ -44,7 +44,10 @@ import org.apache.cloudstack.engine.subsystem.api.storage.PrimaryDataStoreDriver
import org.apache.cloudstack.engine.subsystem.api.storage.SnapshotDataFactory;
import org.apache.cloudstack.engine.subsystem.api.storage.SnapshotInfo;
import org.apache.cloudstack.engine.subsystem.api.storage.SnapshotService;
+import org.apache.cloudstack.engine.subsystem.api.storage.SnapshotStrategy;
+import org.apache.cloudstack.engine.subsystem.api.storage.SnapshotStrategy.SnapshotOperation;
import org.apache.cloudstack.engine.subsystem.api.storage.StoragePoolAllocator;
+import org.apache.cloudstack.engine.subsystem.api.storage.StorageStrategyFactory;
import org.apache.cloudstack.engine.subsystem.api.storage.TemplateDataFactory;
import org.apache.cloudstack.engine.subsystem.api.storage.TemplateInfo;
import org.apache.cloudstack.engine.subsystem.api.storage.VolumeDataFactory;
@@ -178,6 +181,8 @@ public class VolumeOrchestrator extends ManagerBase implements VolumeOrchestrati
ClusterManager clusterManager;
@Inject
StorageManager storageMgr;
+ @Inject
+ StorageStrategyFactory _storageStrategyFactory;
private final StateMachine2<Volume.State, Volume.Event, Volume> _volStateMachine;
protected List<StoragePoolAllocator> _storagePoolAllocators;
@@ -383,6 +388,24 @@ public class VolumeOrchestrator extends ManagerBase implements VolumeOrchestrati
DataStoreRole dataStoreRole = getDataStoreRole(snapshot);
SnapshotInfo snapInfo = snapshotFactory.getSnapshot(snapshot.getId(), dataStoreRole);
+
+ if(snapInfo == null && dataStoreRole == DataStoreRole.Image) {
+ // snapshot is not backed up to secondary, let's do that now.
+ snapInfo = snapshotFactory.getSnapshot(snapshot.getId(), DataStoreRole.Primary);
+
+ if (snapInfo == null) {
+ throw new CloudRuntimeException("Cannot find snapshot " + snapshot.getId());
+ }
+ // We need to copy the snapshot onto secondary.
+ SnapshotStrategy snapshotStrategy = _storageStrategyFactory.getSnapshotStrategy(snapshot, SnapshotOperation.BACKUP);
+ snapshotStrategy.backupSnapshot(snapInfo);
+
+ // Attempt to grab it again.
+ snapInfo = snapshotFactory.getSnapshot(snapshot.getId(), dataStoreRole);
+ if (snapInfo == null) {
+ throw new CloudRuntimeException("Cannot find snapshot " + snapshot.getId() + " on secondary and could not create backup");
+ }
+ }
// don't try to perform a sync if the DataStoreRole of the snapshot is equal to DataStoreRole.Primary
if (!DataStoreRole.Primary.equals(dataStoreRole)) {
try {
http://git-wip-us.apache.org/repos/asf/cloudstack/blob/1a55a93f/engine/storage/snapshot/src/org/apache/cloudstack/storage/snapshot/SnapshotStateMachineManagerImpl.java
----------------------------------------------------------------------
diff --git a/engine/storage/snapshot/src/org/apache/cloudstack/storage/snapshot/SnapshotStateMachineManagerImpl.java b/engine/storage/snapshot/src/org/apache/cloudstack/storage/snapshot/SnapshotStateMachineManagerImpl.java
index cf5944b..1cec2dc 100644
--- a/engine/storage/snapshot/src/org/apache/cloudstack/storage/snapshot/SnapshotStateMachineManagerImpl.java
+++ b/engine/storage/snapshot/src/org/apache/cloudstack/storage/snapshot/SnapshotStateMachineManagerImpl.java
@@ -47,6 +47,7 @@ public class SnapshotStateMachineManagerImpl implements SnapshotStateMachineMana
stateMachine.addTransition(Snapshot.State.BackingUp, Event.OperationFailed, Snapshot.State.Error);
stateMachine.addTransition(Snapshot.State.BackedUp, Event.DestroyRequested, Snapshot.State.Destroying);
stateMachine.addTransition(Snapshot.State.BackedUp, Event.CopyingRequested, Snapshot.State.Copying);
+ stateMachine.addTransition(Snapshot.State.BackedUp, Event.BackupToSecondary, Snapshot.State.BackingUp);
stateMachine.addTransition(Snapshot.State.Copying, Event.OperationSucceeded, Snapshot.State.BackedUp);
stateMachine.addTransition(Snapshot.State.Copying, Event.OperationFailed, Snapshot.State.BackedUp);
stateMachine.addTransition(Snapshot.State.Destroying, Event.OperationSucceeded, Snapshot.State.Destroyed);
http://git-wip-us.apache.org/repos/asf/cloudstack/blob/1a55a93f/engine/storage/snapshot/src/org/apache/cloudstack/storage/snapshot/XenserverSnapshotStrategy.java
----------------------------------------------------------------------
diff --git a/engine/storage/snapshot/src/org/apache/cloudstack/storage/snapshot/XenserverSnapshotStrategy.java b/engine/storage/snapshot/src/org/apache/cloudstack/storage/snapshot/XenserverSnapshotStrategy.java
index 2544484..d984fc4 100644
--- a/engine/storage/snapshot/src/org/apache/cloudstack/storage/snapshot/XenserverSnapshotStrategy.java
+++ b/engine/storage/snapshot/src/org/apache/cloudstack/storage/snapshot/XenserverSnapshotStrategy.java
@@ -39,6 +39,7 @@ import org.apache.cloudstack.storage.datastore.db.SnapshotDataStoreVO;
import org.apache.cloudstack.storage.datastore.PrimaryDataStoreImpl;
import org.apache.cloudstack.storage.to.SnapshotObjectTO;
+import com.cloud.configuration.Config;
import com.cloud.exception.InvalidParameterValueException;
import com.cloud.hypervisor.Hypervisor;
import com.cloud.hypervisor.Hypervisor.HypervisorType;
@@ -374,8 +375,24 @@ public class XenserverSnapshotStrategy extends SnapshotStrategyBase {
snapshot = result.getSnashot();
DataStore primaryStore = snapshot.getDataStore();
+ boolean backupFlag = Boolean.parseBoolean(configDao.getValue(Config.BackupSnapshotAfterTakingSnapshot.toString()));
- SnapshotInfo backupedSnapshot = backupSnapshot(snapshot);
+ SnapshotInfo backupedSnapshot;
+ if(backupFlag) {
+ backupedSnapshot = backupSnapshot(snapshot);
+ } else {
+ // Fake it to get the transitions to fire in the proper order
+ s_logger.debug("skipping backup of snapshot due to configuration "+Config.BackupSnapshotAfterTakingSnapshot.toString());
+
+ SnapshotObject snapObj = (SnapshotObject)snapshot;
+ try {
+ snapObj.processEvent(Snapshot.Event.OperationNotPerformed);
+ } catch (NoTransitionException e) {
+ s_logger.debug("Failed to change state: " + snapshot.getId() + ": " + e.toString());
+ throw new CloudRuntimeException(e.toString());
+ }
+ backupedSnapshot = snapshot;
+ }
try {
SnapshotInfo parent = snapshot.getParent();
http://git-wip-us.apache.org/repos/asf/cloudstack/blob/1a55a93f/server/src/com/cloud/configuration/Config.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/configuration/Config.java b/server/src/com/cloud/configuration/Config.java
index 600ecc4..d502536 100644
--- a/server/src/com/cloud/configuration/Config.java
+++ b/server/src/com/cloud/configuration/Config.java
@@ -512,7 +512,7 @@ public enum Config {
null),
SnapshotDeltaMax("Snapshots", SnapshotManager.class, Integer.class, "snapshot.delta.max", "16", "max delta snapshots between two full snapshots.", null),
BackupSnapshotAfterTakingSnapshot(
- "Hidden",
+ "Snapshots",
SnapshotManager.class,
Boolean.class,
"snapshot.backup.rightafter",
http://git-wip-us.apache.org/repos/asf/cloudstack/blob/1a55a93f/server/src/com/cloud/storage/snapshot/SnapshotManagerImpl.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/storage/snapshot/SnapshotManagerImpl.java b/server/src/com/cloud/storage/snapshot/SnapshotManagerImpl.java
index 16762c5..7c02de2 100644
--- a/server/src/com/cloud/storage/snapshot/SnapshotManagerImpl.java
+++ b/server/src/com/cloud/storage/snapshot/SnapshotManagerImpl.java
@@ -1018,7 +1018,13 @@ public class SnapshotManagerImpl extends MutualExclusiveIdsManagerBase implement
DataStoreRole dataStoreRole = getDataStoreRole(snapshot, _snapshotStoreDao, dataStoreMgr);
SnapshotDataStoreVO snapshotStoreRef = _snapshotStoreDao.findBySnapshot(snapshotId, dataStoreRole);
-
+ if(snapshotStoreRef == null) {
+ // The snapshot was not backed up to secondary. Find the snap on primary
+ snapshotStoreRef = _snapshotStoreDao.findBySnapshot(snapshotId, DataStoreRole.Primary);
+ if(snapshotStoreRef == null) {
+ throw new CloudRuntimeException("Could not find snapshot");
+ }
+ }
UsageEventUtils.publishUsageEvent(EventTypes.EVENT_SNAPSHOT_CREATE, snapshot.getAccountId(), snapshot.getDataCenterId(), snapshotId, snapshot.getName(),
null, null, snapshotStoreRef.getPhysicalSize(), volume.getSize(), snapshot.getClass().getName(), snapshot.getUuid());
http://git-wip-us.apache.org/repos/asf/cloudstack/blob/1a55a93f/server/src/com/cloud/template/TemplateManagerImpl.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/template/TemplateManagerImpl.java b/server/src/com/cloud/template/TemplateManagerImpl.java
index c03db35..6520270 100644
--- a/server/src/com/cloud/template/TemplateManagerImpl.java
+++ b/server/src/com/cloud/template/TemplateManagerImpl.java
@@ -75,7 +75,10 @@ import org.apache.cloudstack.engine.subsystem.api.storage.PrimaryDataStore;
import org.apache.cloudstack.engine.subsystem.api.storage.Scope;
import org.apache.cloudstack.engine.subsystem.api.storage.SnapshotDataFactory;
import org.apache.cloudstack.engine.subsystem.api.storage.SnapshotInfo;
+import org.apache.cloudstack.engine.subsystem.api.storage.SnapshotStrategy;
+import org.apache.cloudstack.engine.subsystem.api.storage.SnapshotStrategy.SnapshotOperation;
import org.apache.cloudstack.engine.subsystem.api.storage.StorageCacheManager;
+import org.apache.cloudstack.engine.subsystem.api.storage.StorageStrategyFactory;
import org.apache.cloudstack.engine.subsystem.api.storage.TemplateDataFactory;
import org.apache.cloudstack.engine.subsystem.api.storage.TemplateInfo;
import org.apache.cloudstack.engine.subsystem.api.storage.TemplateService;
@@ -254,6 +257,8 @@ public class TemplateManagerImpl extends ManagerBase implements TemplateManager,
@Inject
private SnapshotDataFactory _snapshotFactory;
@Inject
+ StorageStrategyFactory _storageStrategyFactory;
+ @Inject
private TemplateService _tmpltSvr;
@Inject
private DataStoreManager _dataStoreMgr;
@@ -1493,6 +1498,21 @@ public class TemplateManagerImpl extends ManagerBase implements TemplateManager,
SnapshotInfo snapInfo = _snapshotFactory.getSnapshot(snapshotId, dataStoreRole);
if (dataStoreRole == DataStoreRole.Image) {
+ if (snapInfo == null) {
+ snapInfo = _snapshotFactory.getSnapshot(snapshotId, DataStoreRole.Primary);
+ if(snapInfo == null) {
+ throw new CloudRuntimeException("Cannot find snapshot "+snapshotId);
+ }
+ // We need to copy the snapshot onto secondary.
+ SnapshotStrategy snapshotStrategy = _storageStrategyFactory.getSnapshotStrategy(snapshot, SnapshotOperation.BACKUP);
+ snapshotStrategy.backupSnapshot(snapInfo);
+
+ // Attempt to grab it again.
+ snapInfo = _snapshotFactory.getSnapshot(snapshotId, dataStoreRole);
+ if(snapInfo == null) {
+ throw new CloudRuntimeException("Cannot find snapshot " + snapshotId + " on secondary and could not create backup");
+ }
+ }
DataStore snapStore = snapInfo.getDataStore();
if (snapStore != null) {
http://git-wip-us.apache.org/repos/asf/cloudstack/blob/1a55a93f/server/test/com/cloud/template/TemplateManagerImplTest.java
----------------------------------------------------------------------
diff --git a/server/test/com/cloud/template/TemplateManagerImplTest.java b/server/test/com/cloud/template/TemplateManagerImplTest.java
index 6e16938..e6e9edd 100644
--- a/server/test/com/cloud/template/TemplateManagerImplTest.java
+++ b/server/test/com/cloud/template/TemplateManagerImplTest.java
@@ -68,6 +68,7 @@ import org.apache.cloudstack.engine.subsystem.api.storage.EndPointSelector;
import org.apache.cloudstack.engine.subsystem.api.storage.PrimaryDataStore;
import org.apache.cloudstack.engine.subsystem.api.storage.SnapshotDataFactory;
import org.apache.cloudstack.engine.subsystem.api.storage.StorageCacheManager;
+import org.apache.cloudstack.engine.subsystem.api.storage.StorageStrategyFactory;
import org.apache.cloudstack.engine.subsystem.api.storage.TemplateDataFactory;
import org.apache.cloudstack.engine.subsystem.api.storage.TemplateService;
import org.apache.cloudstack.engine.subsystem.api.storage.VolumeDataFactory;
@@ -161,6 +162,9 @@ public class TemplateManagerImplTest {
@Inject
SnapshotDao snapshotDao;
+ @Inject
+ StorageStrategyFactory storageStrategyFactory;
+
public class CustomThreadPoolExecutor extends ThreadPoolExecutor {
AtomicInteger ai = new AtomicInteger(0);
public CustomThreadPoolExecutor(int corePoolSize, int maximumPoolSize, long keepAliveTime, TimeUnit unit,
@@ -454,6 +458,11 @@ public class TemplateManagerImplTest {
}
@Bean
+ public StorageStrategyFactory storageStrategyFactory() {
+ return Mockito.mock(StorageStrategyFactory.class);
+ }
+
+ @Bean
public VMTemplatePoolDao vmTemplatePoolDao() {
return Mockito.mock(VMTemplatePoolDao.class);
}
[2/3] git commit: updated refs/heads/master to 25f1552
Posted by ra...@apache.org.
Merge pull request #1697 from myENA/feature/49_observe_snapshot_backup_rightafter
CLOUDSTACK-4858 Honors the snapshot.backup.rightafter configuration variable
Unhides snapshot.backup.rightafter from global configuration
If snapshot.backup.rightafter is set to false (defaults to true), snapshots are
not backed up to secondary storage.
This is the same as PR #1644 applied to 4.9, as per @jburwell
* pr/1697:
CLOUDSTACK-4858 Honors the snapshot.backup.rightafter configuration variable Unhides snapshot.backup.rightafter from global configuration
Signed-off-by: Rajani Karuturi <ra...@accelerite.com>
Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/c101817d
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/c101817d
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/c101817d
Branch: refs/heads/master
Commit: c101817d45dc7203881dc98aafa9fe95331a2eb7
Parents: c3aff8e 1a55a93
Author: Rajani Karuturi <ra...@accelerite.com>
Authored: Wed Feb 8 12:34:17 2017 +0530
Committer: Rajani Karuturi <ra...@accelerite.com>
Committed: Wed Feb 8 12:34:17 2017 +0530
----------------------------------------------------------------------
.../orchestration/VolumeOrchestrator.java | 23 ++++++++++++++++++++
.../SnapshotStateMachineManagerImpl.java | 1 +
.../snapshot/XenserverSnapshotStrategy.java | 19 +++++++++++++++-
server/src/com/cloud/configuration/Config.java | 2 +-
.../storage/snapshot/SnapshotManagerImpl.java | 8 ++++++-
.../com/cloud/template/TemplateManagerImpl.java | 20 +++++++++++++++++
.../cloud/template/TemplateManagerImplTest.java | 9 ++++++++
7 files changed, 79 insertions(+), 3 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cloudstack/blob/c101817d/engine/storage/snapshot/src/org/apache/cloudstack/storage/snapshot/XenserverSnapshotStrategy.java
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cloudstack/blob/c101817d/server/src/com/cloud/storage/snapshot/SnapshotManagerImpl.java
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cloudstack/blob/c101817d/server/src/com/cloud/template/TemplateManagerImpl.java
----------------------------------------------------------------------
[3/3] git commit: updated refs/heads/master to 25f1552
Posted by ra...@apache.org.
Merge release branch 4.9 to master
This closes #1644
* 4.9:
CLOUDSTACK-4858 Honors the snapshot.backup.rightafter configuration variable Unhides snapshot.backup.rightafter from global configuration
Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/25f1552e
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/25f1552e
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/25f1552e
Branch: refs/heads/master
Commit: 25f1552e371543512d58becdf5e44aab4478e45f
Parents: e303baa c101817
Author: Rajani Karuturi <ra...@accelerite.com>
Authored: Wed Feb 8 12:37:21 2017 +0530
Committer: Rajani Karuturi <ra...@accelerite.com>
Committed: Wed Feb 8 13:43:02 2017 +0530
----------------------------------------------------------------------
.../orchestration/VolumeOrchestrator.java | 23 ++++++++++++++++++++
.../SnapshotStateMachineManagerImpl.java | 1 +
.../snapshot/XenserverSnapshotStrategy.java | 19 +++++++++++++++-
server/src/com/cloud/configuration/Config.java | 2 +-
.../storage/snapshot/SnapshotManagerImpl.java | 8 ++++++-
.../com/cloud/template/TemplateManagerImpl.java | 20 +++++++++++++++++
.../cloud/template/TemplateManagerImplTest.java | 9 ++++++++
7 files changed, 79 insertions(+), 3 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cloudstack/blob/25f1552e/engine/orchestration/src/org/apache/cloudstack/engine/orchestration/VolumeOrchestrator.java
----------------------------------------------------------------------
diff --cc engine/orchestration/src/org/apache/cloudstack/engine/orchestration/VolumeOrchestrator.java
index 32cb19b,ea6a66d..4405d98
--- a/engine/orchestration/src/org/apache/cloudstack/engine/orchestration/VolumeOrchestrator.java
+++ b/engine/orchestration/src/org/apache/cloudstack/engine/orchestration/VolumeOrchestrator.java
@@@ -187,7 -182,7 +190,9 @@@ public class VolumeOrchestrator extend
@Inject
StorageManager storageMgr;
@Inject
+ protected UserVmCloneSettingDao _vmCloneSettingDao;
++ @Inject
+ StorageStrategyFactory _storageStrategyFactory;
private final StateMachine2<Volume.State, Volume.Event, Volume> _volStateMachine;
protected List<StoragePoolAllocator> _storagePoolAllocators;
http://git-wip-us.apache.org/repos/asf/cloudstack/blob/25f1552e/engine/storage/snapshot/src/org/apache/cloudstack/storage/snapshot/XenserverSnapshotStrategy.java
----------------------------------------------------------------------
diff --cc engine/storage/snapshot/src/org/apache/cloudstack/storage/snapshot/XenserverSnapshotStrategy.java
index 16a47c6,2686e40..94e9f43
--- a/engine/storage/snapshot/src/org/apache/cloudstack/storage/snapshot/XenserverSnapshotStrategy.java
+++ b/engine/storage/snapshot/src/org/apache/cloudstack/storage/snapshot/XenserverSnapshotStrategy.java
@@@ -380,10 -375,26 +381,26 @@@ public class XenserverSnapshotStrategy
}
}
- snapshot = result.getSnashot();
+ snapshot = result.getSnapshot();
DataStore primaryStore = snapshot.getDataStore();
+ boolean backupFlag = Boolean.parseBoolean(configDao.getValue(Config.BackupSnapshotAfterTakingSnapshot.toString()));
- SnapshotInfo backupedSnapshot = backupSnapshot(snapshot);
+ SnapshotInfo backupedSnapshot;
+ if(backupFlag) {
+ backupedSnapshot = backupSnapshot(snapshot);
+ } else {
+ // Fake it to get the transitions to fire in the proper order
+ s_logger.debug("skipping backup of snapshot due to configuration "+Config.BackupSnapshotAfterTakingSnapshot.toString());
+
+ SnapshotObject snapObj = (SnapshotObject)snapshot;
+ try {
+ snapObj.processEvent(Snapshot.Event.OperationNotPerformed);
+ } catch (NoTransitionException e) {
+ s_logger.debug("Failed to change state: " + snapshot.getId() + ": " + e.toString());
+ throw new CloudRuntimeException(e.toString());
+ }
+ backupedSnapshot = snapshot;
+ }
try {
SnapshotInfo parent = snapshot.getParent();
http://git-wip-us.apache.org/repos/asf/cloudstack/blob/25f1552e/server/src/com/cloud/configuration/Config.java
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cloudstack/blob/25f1552e/server/src/com/cloud/storage/snapshot/SnapshotManagerImpl.java
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cloudstack/blob/25f1552e/server/src/com/cloud/template/TemplateManagerImpl.java
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cloudstack/blob/25f1552e/server/test/com/cloud/template/TemplateManagerImplTest.java
----------------------------------------------------------------------
diff --cc server/test/com/cloud/template/TemplateManagerImplTest.java
index 61a8a4a,e6e9edd..3039b8b
--- a/server/test/com/cloud/template/TemplateManagerImplTest.java
+++ b/server/test/com/cloud/template/TemplateManagerImplTest.java
@@@ -163,8 -163,8 +164,11 @@@ public class TemplateManagerImplTest
SnapshotDao snapshotDao;
@Inject
+ VMTemplateDetailsDao tmpltDetailsDao;
+
++ @Inject
+ StorageStrategyFactory storageStrategyFactory;
+
public class CustomThreadPoolExecutor extends ThreadPoolExecutor {
AtomicInteger ai = new AtomicInteger(0);
public CustomThreadPoolExecutor(int corePoolSize, int maximumPoolSize, long keepAliveTime, TimeUnit unit,