cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From prachida...@apache.org
Subject [34/50] [abbrv] Removing ^M's from code.
Date Fri, 05 Apr 2013 21:03:29 GMT
http://git-wip-us.apache.org/repos/asf/cloudstack/blob/469c4dd1/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMComputeTagDaoImpl.java
----------------------------------------------------------------------
diff --git a/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMComputeTagDaoImpl.java b/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMComputeTagDaoImpl.java
index 6037ad4..6f70b35 100644
--- a/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMComputeTagDaoImpl.java
+++ b/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMComputeTagDaoImpl.java
@@ -14,76 +14,76 @@
 // KIND, either express or implied.  See the License for the
 // specific language governing permissions and limitations
 // under the License.
-package org.apache.cloudstack.engine.cloud.entity.api.db.dao;
-
-
-import java.util.ArrayList;
-import java.util.List;
-
-import javax.annotation.PostConstruct;
-import javax.ejb.Local;
-
-
-import org.apache.cloudstack.engine.cloud.entity.api.db.VMComputeTagVO;
-
-import org.springframework.stereotype.Component;
-
-import com.cloud.utils.db.GenericDaoBase;
-import com.cloud.utils.db.SearchBuilder;
-import com.cloud.utils.db.SearchCriteria;
-import com.cloud.utils.db.Transaction;
-
-@Component
-@Local(value = { VMComputeTagDao.class })
-public class VMComputeTagDaoImpl extends GenericDaoBase<VMComputeTagVO, Long> implements VMComputeTagDao {
-
-    protected SearchBuilder<VMComputeTagVO> VmIdSearch;
-    
-    public VMComputeTagDaoImpl() {
-    }
-    
-    @PostConstruct
-    public void init() {
-        VmIdSearch = createSearchBuilder();
-        VmIdSearch.and("vmId", VmIdSearch.entity().getVmId(), SearchCriteria.Op.EQ);
-        VmIdSearch.done();
-        
-    }
-    
-    @Override
-    public void persist(long vmId, List<String> computeTags) {
-        Transaction txn = Transaction.currentTxn();
-
-        txn.start();
-        SearchCriteria<VMComputeTagVO> sc = VmIdSearch.create();
-        sc.setParameters("vmId", vmId);
-        expunge(sc);
-        
-        for (String tag : computeTags) {
-            if(tag != null){
-                tag = tag.trim();
-                if(tag.length() > 0) {
-                    VMComputeTagVO vo = new VMComputeTagVO(vmId, tag);
-                    persist(vo);
-                }
-            }
-        }
-        txn.commit();
-    }
-
-    @Override
-    public List<String> getComputeTags(long vmId) {
-        
-        SearchCriteria<VMComputeTagVO> sc = VmIdSearch.create();
-        sc.setParameters("vmId", vmId);
-        
-        List<VMComputeTagVO> results = search(sc, null);
-        List<String> computeTags = new ArrayList<String>(results.size());
-        for (VMComputeTagVO result : results) {
-            computeTags.add(result.getComputeTag());
-        }
-
-        return computeTags;
-    }
-    
-}
+package org.apache.cloudstack.engine.cloud.entity.api.db.dao;
+
+
+import java.util.ArrayList;
+import java.util.List;
+
+import javax.annotation.PostConstruct;
+import javax.ejb.Local;
+
+
+import org.apache.cloudstack.engine.cloud.entity.api.db.VMComputeTagVO;
+
+import org.springframework.stereotype.Component;
+
+import com.cloud.utils.db.GenericDaoBase;
+import com.cloud.utils.db.SearchBuilder;
+import com.cloud.utils.db.SearchCriteria;
+import com.cloud.utils.db.Transaction;
+
+@Component
+@Local(value = { VMComputeTagDao.class })
+public class VMComputeTagDaoImpl extends GenericDaoBase<VMComputeTagVO, Long> implements VMComputeTagDao {
+
+    protected SearchBuilder<VMComputeTagVO> VmIdSearch;
+
+    public VMComputeTagDaoImpl() {
+    }
+
+    @PostConstruct
+    public void init() {
+        VmIdSearch = createSearchBuilder();
+        VmIdSearch.and("vmId", VmIdSearch.entity().getVmId(), SearchCriteria.Op.EQ);
+        VmIdSearch.done();
+
+    }
+
+    @Override
+    public void persist(long vmId, List<String> computeTags) {
+        Transaction txn = Transaction.currentTxn();
+
+        txn.start();
+        SearchCriteria<VMComputeTagVO> sc = VmIdSearch.create();
+        sc.setParameters("vmId", vmId);
+        expunge(sc);
+
+        for (String tag : computeTags) {
+            if(tag != null){
+                tag = tag.trim();
+                if(tag.length() > 0) {
+                    VMComputeTagVO vo = new VMComputeTagVO(vmId, tag);
+                    persist(vo);
+                }
+            }
+        }
+        txn.commit();
+    }
+
+    @Override
+    public List<String> getComputeTags(long vmId) {
+
+        SearchCriteria<VMComputeTagVO> sc = VmIdSearch.create();
+        sc.setParameters("vmId", vmId);
+
+        List<VMComputeTagVO> results = search(sc, null);
+        List<String> computeTags = new ArrayList<String>(results.size());
+        for (VMComputeTagVO result : results) {
+            computeTags.add(result.getComputeTag());
+        }
+
+        return computeTags;
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/469c4dd1/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMNetworkMapDao.java
----------------------------------------------------------------------
diff --git a/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMNetworkMapDao.java b/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMNetworkMapDao.java
index baa0920..59c41c2 100644
--- a/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMNetworkMapDao.java
+++ b/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMNetworkMapDao.java
@@ -14,18 +14,18 @@
 // KIND, either express or implied.  See the License for the
 // specific language governing permissions and limitations
 // under the License.
-package org.apache.cloudstack.engine.cloud.entity.api.db.dao;
-
-import java.util.List;
-
-import org.apache.cloudstack.engine.cloud.entity.api.db.VMNetworkMapVO;
-
-import com.cloud.utils.db.GenericDao;
-
-public interface VMNetworkMapDao extends GenericDao<VMNetworkMapVO, Long>{
-
-    void persist(long vmId, List<Long> networks);
-    
-    List<Long> getNetworks(long vmId);
-
-}
+package org.apache.cloudstack.engine.cloud.entity.api.db.dao;
+
+import java.util.List;
+
+import org.apache.cloudstack.engine.cloud.entity.api.db.VMNetworkMapVO;
+
+import com.cloud.utils.db.GenericDao;
+
+public interface VMNetworkMapDao extends GenericDao<VMNetworkMapVO, Long>{
+
+    void persist(long vmId, List<Long> networks);
+
+    List<Long> getNetworks(long vmId);
+
+}

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/469c4dd1/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMNetworkMapDaoImpl.java
----------------------------------------------------------------------
diff --git a/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMNetworkMapDaoImpl.java b/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMNetworkMapDaoImpl.java
index 378f16d..0f2c4cc 100644
--- a/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMNetworkMapDaoImpl.java
+++ b/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMNetworkMapDaoImpl.java
@@ -14,72 +14,72 @@
 // KIND, either express or implied.  See the License for the
 // specific language governing permissions and limitations
 // under the License.
-package org.apache.cloudstack.engine.cloud.entity.api.db.dao;
-
-
-import java.util.ArrayList;
-import java.util.List;
-import javax.annotation.PostConstruct;
-import javax.ejb.Local;
-import javax.inject.Inject;
-import org.apache.cloudstack.engine.cloud.entity.api.db.VMNetworkMapVO;
-import org.springframework.stereotype.Component;
-import com.cloud.network.dao.NetworkDao;
-import com.cloud.utils.db.GenericDaoBase;
-import com.cloud.utils.db.SearchBuilder;
-import com.cloud.utils.db.SearchCriteria;
-import com.cloud.utils.db.Transaction;
-
-@Component
-@Local(value = { VMNetworkMapDao.class })
-public class VMNetworkMapDaoImpl extends GenericDaoBase<VMNetworkMapVO, Long> implements VMNetworkMapDao {
-
-    protected SearchBuilder<VMNetworkMapVO> VmIdSearch;
-    
-    @Inject
-    protected NetworkDao _networkDao;
-    
-    public VMNetworkMapDaoImpl() {
-    }
-    
-    @PostConstruct
-    public void init() {
-        VmIdSearch = createSearchBuilder();
-        VmIdSearch.and("vmId", VmIdSearch.entity().getVmId(), SearchCriteria.Op.EQ);
-        VmIdSearch.done();
-        
-    }
-    
-    @Override
-    public void persist(long vmId, List<Long> networks) {
-        Transaction txn = Transaction.currentTxn();
-
-        txn.start();
-        SearchCriteria<VMNetworkMapVO> sc = VmIdSearch.create();
-        sc.setParameters("vmId", vmId);
-        expunge(sc);
-        
-        for (Long networkId : networks) {
-            VMNetworkMapVO vo = new VMNetworkMapVO(vmId, networkId);
-            persist(vo);
-        }
-
-        txn.commit();
-    }
-
-    @Override
-    public List<Long> getNetworks(long vmId) {
-        
-        SearchCriteria<VMNetworkMapVO> sc = VmIdSearch.create();
-        sc.setParameters("vmId", vmId);
-        
-        List<VMNetworkMapVO> results = search(sc, null);
-        List<Long> networks = new ArrayList<Long>(results.size());
-        for (VMNetworkMapVO result : results) {
-            networks.add(result.getNetworkId());
-        }
-
-        return networks;
-    }
-    
-}
+package org.apache.cloudstack.engine.cloud.entity.api.db.dao;
+
+
+import java.util.ArrayList;
+import java.util.List;
+import javax.annotation.PostConstruct;
+import javax.ejb.Local;
+import javax.inject.Inject;
+import org.apache.cloudstack.engine.cloud.entity.api.db.VMNetworkMapVO;
+import org.springframework.stereotype.Component;
+import com.cloud.network.dao.NetworkDao;
+import com.cloud.utils.db.GenericDaoBase;
+import com.cloud.utils.db.SearchBuilder;
+import com.cloud.utils.db.SearchCriteria;
+import com.cloud.utils.db.Transaction;
+
+@Component
+@Local(value = { VMNetworkMapDao.class })
+public class VMNetworkMapDaoImpl extends GenericDaoBase<VMNetworkMapVO, Long> implements VMNetworkMapDao {
+
+    protected SearchBuilder<VMNetworkMapVO> VmIdSearch;
+
+    @Inject
+    protected NetworkDao _networkDao;
+
+    public VMNetworkMapDaoImpl() {
+    }
+
+    @PostConstruct
+    public void init() {
+        VmIdSearch = createSearchBuilder();
+        VmIdSearch.and("vmId", VmIdSearch.entity().getVmId(), SearchCriteria.Op.EQ);
+        VmIdSearch.done();
+
+    }
+
+    @Override
+    public void persist(long vmId, List<Long> networks) {
+        Transaction txn = Transaction.currentTxn();
+
+        txn.start();
+        SearchCriteria<VMNetworkMapVO> sc = VmIdSearch.create();
+        sc.setParameters("vmId", vmId);
+        expunge(sc);
+
+        for (Long networkId : networks) {
+            VMNetworkMapVO vo = new VMNetworkMapVO(vmId, networkId);
+            persist(vo);
+        }
+
+        txn.commit();
+    }
+
+    @Override
+    public List<Long> getNetworks(long vmId) {
+
+        SearchCriteria<VMNetworkMapVO> sc = VmIdSearch.create();
+        sc.setParameters("vmId", vmId);
+
+        List<VMNetworkMapVO> results = search(sc, null);
+        List<Long> networks = new ArrayList<Long>(results.size());
+        for (VMNetworkMapVO result : results) {
+            networks.add(result.getNetworkId());
+        }
+
+        return networks;
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/469c4dd1/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMReservationDao.java
----------------------------------------------------------------------
diff --git a/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMReservationDao.java b/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMReservationDao.java
index a312578..721a8c4 100644
--- a/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMReservationDao.java
+++ b/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMReservationDao.java
@@ -14,21 +14,21 @@
 // KIND, either express or implied.  See the License for the
 // specific language governing permissions and limitations
 // under the License.
-package org.apache.cloudstack.engine.cloud.entity.api.db.dao;
-
-
-import java.util.Map;
-
-import org.apache.cloudstack.engine.cloud.entity.api.db.VMReservationVO;
-
-import com.cloud.utils.db.GenericDao;
-
-public interface VMReservationDao extends GenericDao<VMReservationVO, Long>{
-    
-    VMReservationVO findByVmId(long vmId);
-
-    void loadVolumeReservation(VMReservationVO reservation);
-    
-    VMReservationVO findByReservationId(String reservationId);
-
-}
+package org.apache.cloudstack.engine.cloud.entity.api.db.dao;
+
+
+import java.util.Map;
+
+import org.apache.cloudstack.engine.cloud.entity.api.db.VMReservationVO;
+
+import com.cloud.utils.db.GenericDao;
+
+public interface VMReservationDao extends GenericDao<VMReservationVO, Long>{
+
+    VMReservationVO findByVmId(long vmId);
+
+    void loadVolumeReservation(VMReservationVO reservation);
+
+    VMReservationVO findByReservationId(String reservationId);
+
+}

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/469c4dd1/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMReservationDaoImpl.java
----------------------------------------------------------------------
diff --git a/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMReservationDaoImpl.java b/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMReservationDaoImpl.java
index dc346cc..73b4dd2 100644
--- a/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMReservationDaoImpl.java
+++ b/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMReservationDaoImpl.java
@@ -14,98 +14,98 @@
 // KIND, either express or implied.  See the License for the
 // specific language governing permissions and limitations
 // under the License.
-package org.apache.cloudstack.engine.cloud.entity.api.db.dao;
-
-
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
-import javax.annotation.PostConstruct;
-import javax.ejb.Local;
-import javax.inject.Inject;
-
-import org.apache.cloudstack.engine.cloud.entity.api.db.VMEntityVO;
-import org.apache.cloudstack.engine.cloud.entity.api.db.VMReservationVO;
-import org.apache.cloudstack.engine.cloud.entity.api.db.VolumeReservationVO;
-import org.springframework.stereotype.Component;
-
-import com.cloud.host.dao.HostTagsDaoImpl;
-import com.cloud.utils.db.DB;
-import com.cloud.utils.db.GenericDaoBase;
-import com.cloud.utils.db.SearchBuilder;
-import com.cloud.utils.db.SearchCriteria;
-import com.cloud.utils.db.Transaction;
-
-@Component
-@Local(value = { VMReservationDao.class })
-public class VMReservationDaoImpl extends GenericDaoBase<VMReservationVO, Long> implements VMReservationDao {
-
-    protected SearchBuilder<VMReservationVO> VmIdSearch;
-    
-    @Inject protected VolumeReservationDao _volumeReservationDao;
-    
-    public VMReservationDaoImpl() {
-    }
-    
-    @PostConstruct
-    public void init() {
-        VmIdSearch = createSearchBuilder();
-        VmIdSearch.and("vmId", VmIdSearch.entity().getVmId(), SearchCriteria.Op.EQ);
-        VmIdSearch.done();
-    }
-    
-    @Override
-    public VMReservationVO findByVmId(long vmId) {
-        SearchCriteria<VMReservationVO> sc = VmIdSearch.create("vmId", vmId);
-        VMReservationVO vmRes = findOneBy(sc);
-        loadVolumeReservation(vmRes);
-        return vmRes;
-    }
-    
-    
-    @Override
-    public void loadVolumeReservation(VMReservationVO reservation){
-        if(reservation != null){
-            List<VolumeReservationVO> volumeResList = _volumeReservationDao.listVolumeReservation(reservation.getId());
-            Map<Long, Long> volumeReservationMap = new HashMap<Long,Long>();
-            
-            for(VolumeReservationVO res : volumeResList){
-                volumeReservationMap.put(res.getVolumeId(), res.getPoolId());
-            }
-            reservation.setVolumeReservation(volumeReservationMap);
-        }
-    }
-    
-    @Override
-    @DB
-    public VMReservationVO persist(VMReservationVO reservation) {
-        Transaction txn = Transaction.currentTxn();
-        txn.start();
-
-        VMReservationVO dbVO = super.persist(reservation);
-
-        saveVolumeReservation(reservation);
-        loadVolumeReservation(dbVO);
-
-        txn.commit();
-
-        return dbVO;
-    }
-
-    private void saveVolumeReservation(VMReservationVO reservation) {
-        if(reservation.getVolumeReservation() != null){
-            for(Long volumeId : reservation.getVolumeReservation().keySet()){
-                VolumeReservationVO volumeReservation = new VolumeReservationVO(reservation.getVmId(), volumeId, reservation.getVolumeReservation().get(volumeId), reservation.getId());
-                _volumeReservationDao.persist(volumeReservation);
-            }
-        }        
-    }
-
-    @Override
-    public VMReservationVO findByReservationId(String reservationId) {
-        VMReservationVO vmRes = super.findByUuid(reservationId);
-        loadVolumeReservation(vmRes);
-        return vmRes;
-    }
-}
+package org.apache.cloudstack.engine.cloud.entity.api.db.dao;
+
+
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
+import javax.annotation.PostConstruct;
+import javax.ejb.Local;
+import javax.inject.Inject;
+
+import org.apache.cloudstack.engine.cloud.entity.api.db.VMEntityVO;
+import org.apache.cloudstack.engine.cloud.entity.api.db.VMReservationVO;
+import org.apache.cloudstack.engine.cloud.entity.api.db.VolumeReservationVO;
+import org.springframework.stereotype.Component;
+
+import com.cloud.host.dao.HostTagsDaoImpl;
+import com.cloud.utils.db.DB;
+import com.cloud.utils.db.GenericDaoBase;
+import com.cloud.utils.db.SearchBuilder;
+import com.cloud.utils.db.SearchCriteria;
+import com.cloud.utils.db.Transaction;
+
+@Component
+@Local(value = { VMReservationDao.class })
+public class VMReservationDaoImpl extends GenericDaoBase<VMReservationVO, Long> implements VMReservationDao {
+
+    protected SearchBuilder<VMReservationVO> VmIdSearch;
+
+    @Inject protected VolumeReservationDao _volumeReservationDao;
+
+    public VMReservationDaoImpl() {
+    }
+
+    @PostConstruct
+    public void init() {
+        VmIdSearch = createSearchBuilder();
+        VmIdSearch.and("vmId", VmIdSearch.entity().getVmId(), SearchCriteria.Op.EQ);
+        VmIdSearch.done();
+    }
+
+    @Override
+    public VMReservationVO findByVmId(long vmId) {
+        SearchCriteria<VMReservationVO> sc = VmIdSearch.create("vmId", vmId);
+        VMReservationVO vmRes = findOneBy(sc);
+        loadVolumeReservation(vmRes);
+        return vmRes;
+    }
+
+
+    @Override
+    public void loadVolumeReservation(VMReservationVO reservation){
+        if(reservation != null){
+            List<VolumeReservationVO> volumeResList = _volumeReservationDao.listVolumeReservation(reservation.getId());
+            Map<Long, Long> volumeReservationMap = new HashMap<Long,Long>();
+
+            for(VolumeReservationVO res : volumeResList){
+                volumeReservationMap.put(res.getVolumeId(), res.getPoolId());
+            }
+            reservation.setVolumeReservation(volumeReservationMap);
+        }
+    }
+
+    @Override
+    @DB
+    public VMReservationVO persist(VMReservationVO reservation) {
+        Transaction txn = Transaction.currentTxn();
+        txn.start();
+
+        VMReservationVO dbVO = super.persist(reservation);
+
+        saveVolumeReservation(reservation);
+        loadVolumeReservation(dbVO);
+
+        txn.commit();
+
+        return dbVO;
+    }
+
+    private void saveVolumeReservation(VMReservationVO reservation) {
+        if(reservation.getVolumeReservation() != null){
+            for(Long volumeId : reservation.getVolumeReservation().keySet()){
+                VolumeReservationVO volumeReservation = new VolumeReservationVO(reservation.getVmId(), volumeId, reservation.getVolumeReservation().get(volumeId), reservation.getId());
+                _volumeReservationDao.persist(volumeReservation);
+            }
+        }
+    }
+
+    @Override
+    public VMReservationVO findByReservationId(String reservationId) {
+        VMReservationVO vmRes = super.findByUuid(reservationId);
+        loadVolumeReservation(vmRes);
+        return vmRes;
+    }
+}

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/469c4dd1/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMRootDiskTagDao.java
----------------------------------------------------------------------
diff --git a/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMRootDiskTagDao.java b/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMRootDiskTagDao.java
index 5a4c2be..dc00880 100644
--- a/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMRootDiskTagDao.java
+++ b/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMRootDiskTagDao.java
@@ -14,18 +14,18 @@
 // KIND, either express or implied.  See the License for the
 // specific language governing permissions and limitations
 // under the License.
-package org.apache.cloudstack.engine.cloud.entity.api.db.dao;
-
-import java.util.List;
-
-import org.apache.cloudstack.engine.cloud.entity.api.db.VMRootDiskTagVO;
-
-import com.cloud.utils.db.GenericDao;
-
-public interface VMRootDiskTagDao extends GenericDao<VMRootDiskTagVO, Long>{
-
-    void persist(long vmId, List<String> diskTags);
-    
-    List<String> getRootDiskTags(long vmId);
-
-}
+package org.apache.cloudstack.engine.cloud.entity.api.db.dao;
+
+import java.util.List;
+
+import org.apache.cloudstack.engine.cloud.entity.api.db.VMRootDiskTagVO;
+
+import com.cloud.utils.db.GenericDao;
+
+public interface VMRootDiskTagDao extends GenericDao<VMRootDiskTagVO, Long>{
+
+    void persist(long vmId, List<String> diskTags);
+
+    List<String> getRootDiskTags(long vmId);
+
+}

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/469c4dd1/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMRootDiskTagDaoImpl.java
----------------------------------------------------------------------
diff --git a/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMRootDiskTagDaoImpl.java b/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMRootDiskTagDaoImpl.java
index 60ea547..be194bb 100644
--- a/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMRootDiskTagDaoImpl.java
+++ b/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VMRootDiskTagDaoImpl.java
@@ -14,75 +14,75 @@
 // KIND, either express or implied.  See the License for the
 // specific language governing permissions and limitations
 // under the License.
-package org.apache.cloudstack.engine.cloud.entity.api.db.dao;
-
-
-import java.util.ArrayList;
-import java.util.List;
-
-import javax.annotation.PostConstruct;
-import javax.ejb.Local;
-
-
-import org.apache.cloudstack.engine.cloud.entity.api.db.VMRootDiskTagVO;
-
-import org.springframework.stereotype.Component;
-
-import com.cloud.utils.db.GenericDaoBase;
-import com.cloud.utils.db.SearchBuilder;
-import com.cloud.utils.db.SearchCriteria;
-import com.cloud.utils.db.Transaction;
-
-@Component
-@Local(value = { VMRootDiskTagDao.class })
-public class VMRootDiskTagDaoImpl extends GenericDaoBase<VMRootDiskTagVO, Long> implements VMRootDiskTagDao {
-
-    protected SearchBuilder<VMRootDiskTagVO> VmIdSearch;
-    
-    public VMRootDiskTagDaoImpl() {
-    }
-    
-    @PostConstruct
-    public void init() {
-        VmIdSearch = createSearchBuilder();
-        VmIdSearch.and("vmId", VmIdSearch.entity().getVmId(), SearchCriteria.Op.EQ);
-        VmIdSearch.done();
-        
-    }
-    
-    @Override
-    public void persist(long vmId, List<String> rootDiskTags) {
-        Transaction txn = Transaction.currentTxn();
-
-        txn.start();
-        SearchCriteria<VMRootDiskTagVO> sc = VmIdSearch.create();
-        sc.setParameters("vmId", vmId);
-        expunge(sc);
-        
-        for (String tag : rootDiskTags) {
-            if(tag != null){
-                tag = tag.trim();
-                if(tag.length() > 0) {
-                    VMRootDiskTagVO vo = new VMRootDiskTagVO(vmId, tag);
-                    persist(vo);
-                }
-            }
-        }
-        txn.commit();
-    }
-
-
-    @Override
-    public List<String> getRootDiskTags(long vmId) {
-        SearchCriteria<VMRootDiskTagVO> sc = VmIdSearch.create();
-        sc.setParameters("vmId", vmId);
-        
-        List<VMRootDiskTagVO> results = search(sc, null);
-        List<String> computeTags = new ArrayList<String>(results.size());
-        for (VMRootDiskTagVO result : results) {
-            computeTags.add(result.getRootDiskTag());
-        }
-        return computeTags;
-    }
-    
-}
+package org.apache.cloudstack.engine.cloud.entity.api.db.dao;
+
+
+import java.util.ArrayList;
+import java.util.List;
+
+import javax.annotation.PostConstruct;
+import javax.ejb.Local;
+
+
+import org.apache.cloudstack.engine.cloud.entity.api.db.VMRootDiskTagVO;
+
+import org.springframework.stereotype.Component;
+
+import com.cloud.utils.db.GenericDaoBase;
+import com.cloud.utils.db.SearchBuilder;
+import com.cloud.utils.db.SearchCriteria;
+import com.cloud.utils.db.Transaction;
+
+@Component
+@Local(value = { VMRootDiskTagDao.class })
+public class VMRootDiskTagDaoImpl extends GenericDaoBase<VMRootDiskTagVO, Long> implements VMRootDiskTagDao {
+
+    protected SearchBuilder<VMRootDiskTagVO> VmIdSearch;
+
+    public VMRootDiskTagDaoImpl() {
+    }
+
+    @PostConstruct
+    public void init() {
+        VmIdSearch = createSearchBuilder();
+        VmIdSearch.and("vmId", VmIdSearch.entity().getVmId(), SearchCriteria.Op.EQ);
+        VmIdSearch.done();
+
+    }
+
+    @Override
+    public void persist(long vmId, List<String> rootDiskTags) {
+        Transaction txn = Transaction.currentTxn();
+
+        txn.start();
+        SearchCriteria<VMRootDiskTagVO> sc = VmIdSearch.create();
+        sc.setParameters("vmId", vmId);
+        expunge(sc);
+
+        for (String tag : rootDiskTags) {
+            if(tag != null){
+                tag = tag.trim();
+                if(tag.length() > 0) {
+                    VMRootDiskTagVO vo = new VMRootDiskTagVO(vmId, tag);
+                    persist(vo);
+                }
+            }
+        }
+        txn.commit();
+    }
+
+
+    @Override
+    public List<String> getRootDiskTags(long vmId) {
+        SearchCriteria<VMRootDiskTagVO> sc = VmIdSearch.create();
+        sc.setParameters("vmId", vmId);
+
+        List<VMRootDiskTagVO> results = search(sc, null);
+        List<String> computeTags = new ArrayList<String>(results.size());
+        for (VMRootDiskTagVO result : results) {
+            computeTags.add(result.getRootDiskTag());
+        }
+        return computeTags;
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/469c4dd1/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VolumeReservationDao.java
----------------------------------------------------------------------
diff --git a/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VolumeReservationDao.java b/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VolumeReservationDao.java
index d6a9fe2..fd709b0 100644
--- a/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VolumeReservationDao.java
+++ b/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VolumeReservationDao.java
@@ -14,18 +14,18 @@
 // KIND, either express or implied.  See the License for the
 // specific language governing permissions and limitations
 // under the License.
-package org.apache.cloudstack.engine.cloud.entity.api.db.dao;
-
-import java.util.List;
-
-import org.apache.cloudstack.engine.cloud.entity.api.db.VolumeReservationVO;
-
-import com.cloud.utils.db.GenericDao;
-
-public interface VolumeReservationDao extends GenericDao<VolumeReservationVO, Long>{
-
-   VolumeReservationVO findByVmId(long vmId);
-   
-   List<VolumeReservationVO> listVolumeReservation(long vmReservationId);
-
-}
+package org.apache.cloudstack.engine.cloud.entity.api.db.dao;
+
+import java.util.List;
+
+import org.apache.cloudstack.engine.cloud.entity.api.db.VolumeReservationVO;
+
+import com.cloud.utils.db.GenericDao;
+
+public interface VolumeReservationDao extends GenericDao<VolumeReservationVO, Long>{
+
+   VolumeReservationVO findByVmId(long vmId);
+
+   List<VolumeReservationVO> listVolumeReservation(long vmReservationId);
+
+}

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/469c4dd1/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VolumeReservationDaoImpl.java
----------------------------------------------------------------------
diff --git a/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VolumeReservationDaoImpl.java b/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VolumeReservationDaoImpl.java
index 4b1b1e6..26bc65f 100644
--- a/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VolumeReservationDaoImpl.java
+++ b/engine/orchestration/src/org/apache/cloudstack/engine/cloud/entity/api/db/dao/VolumeReservationDaoImpl.java
@@ -14,55 +14,55 @@
 // KIND, either express or implied.  See the License for the
 // specific language governing permissions and limitations
 // under the License.
-package org.apache.cloudstack.engine.cloud.entity.api.db.dao;
-
-
-import java.util.List;
-
-import javax.annotation.PostConstruct;
-import javax.ejb.Local;
-import javax.inject.Inject;
-
-import org.apache.cloudstack.engine.cloud.entity.api.db.VMReservationVO;
-import org.apache.cloudstack.engine.cloud.entity.api.db.VolumeReservationVO;
-import org.springframework.stereotype.Component;
-
-import com.cloud.host.dao.HostTagsDaoImpl;
-import com.cloud.utils.db.GenericDaoBase;
-import com.cloud.utils.db.SearchBuilder;
-import com.cloud.utils.db.SearchCriteria;
-
-@Component
-@Local(value = { VolumeReservationDao.class })
-public class VolumeReservationDaoImpl extends GenericDaoBase<VolumeReservationVO, Long> implements VolumeReservationDao {
-
-    protected SearchBuilder<VolumeReservationVO> VmIdSearch;
-    protected SearchBuilder<VolumeReservationVO> VmReservationIdSearch;
-    
-    public VolumeReservationDaoImpl() {
-    }
-    
-    @PostConstruct
-    public void init() {
-        VmIdSearch = createSearchBuilder();
-        VmIdSearch.and("vmId", VmIdSearch.entity().getVmId(), SearchCriteria.Op.EQ);
-        VmIdSearch.done();
-        
-        VmReservationIdSearch = createSearchBuilder();
-        VmReservationIdSearch.and("vmReservationId", VmReservationIdSearch.entity().geVmReservationId(), SearchCriteria.Op.EQ);
-        VmReservationIdSearch.done();
-    }
-    
-    @Override
-    public VolumeReservationVO findByVmId(long vmId) {
-        SearchCriteria<VolumeReservationVO> sc = VmIdSearch.create("vmId", vmId);
-        return findOneBy(sc);
-    }
-
-    @Override
-    public List<VolumeReservationVO> listVolumeReservation(long vmReservationId) {
-        SearchCriteria<VolumeReservationVO> sc = VmReservationIdSearch.create("vmReservationId", vmReservationId);
-        return listBy(sc);
-    }
-    
-}
+package org.apache.cloudstack.engine.cloud.entity.api.db.dao;
+
+
+import java.util.List;
+
+import javax.annotation.PostConstruct;
+import javax.ejb.Local;
+import javax.inject.Inject;
+
+import org.apache.cloudstack.engine.cloud.entity.api.db.VMReservationVO;
+import org.apache.cloudstack.engine.cloud.entity.api.db.VolumeReservationVO;
+import org.springframework.stereotype.Component;
+
+import com.cloud.host.dao.HostTagsDaoImpl;
+import com.cloud.utils.db.GenericDaoBase;
+import com.cloud.utils.db.SearchBuilder;
+import com.cloud.utils.db.SearchCriteria;
+
+@Component
+@Local(value = { VolumeReservationDao.class })
+public class VolumeReservationDaoImpl extends GenericDaoBase<VolumeReservationVO, Long> implements VolumeReservationDao {
+
+    protected SearchBuilder<VolumeReservationVO> VmIdSearch;
+    protected SearchBuilder<VolumeReservationVO> VmReservationIdSearch;
+
+    public VolumeReservationDaoImpl() {
+    }
+
+    @PostConstruct
+    public void init() {
+        VmIdSearch = createSearchBuilder();
+        VmIdSearch.and("vmId", VmIdSearch.entity().getVmId(), SearchCriteria.Op.EQ);
+        VmIdSearch.done();
+
+        VmReservationIdSearch = createSearchBuilder();
+        VmReservationIdSearch.and("vmReservationId", VmReservationIdSearch.entity().geVmReservationId(), SearchCriteria.Op.EQ);
+        VmReservationIdSearch.done();
+    }
+
+    @Override
+    public VolumeReservationVO findByVmId(long vmId) {
+        SearchCriteria<VolumeReservationVO> sc = VmIdSearch.create("vmId", vmId);
+        return findOneBy(sc);
+    }
+
+    @Override
+    public List<VolumeReservationVO> listVolumeReservation(long vmReservationId) {
+        SearchCriteria<VolumeReservationVO> sc = VmReservationIdSearch.create("vmReservationId", vmReservationId);
+        return listBy(sc);
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/469c4dd1/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/ClusterEntityImpl.java
----------------------------------------------------------------------
diff --git a/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/ClusterEntityImpl.java b/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/ClusterEntityImpl.java
index 3471b7a..46dd21d 100644
--- a/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/ClusterEntityImpl.java
+++ b/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/ClusterEntityImpl.java
@@ -14,196 +14,196 @@
 // KIND, either express or implied.  See the License for the
 // specific language governing permissions and limitations
 // under the License.
-
-package org.apache.cloudstack.engine.datacenter.entity.api;
-
-import java.lang.reflect.Method;
-import java.util.Date;
-import java.util.List;
-import java.util.Map;
-
-import org.apache.cloudstack.engine.datacenter.entity.api.DataCenterResourceEntity.State.Event;
-import org.apache.cloudstack.engine.datacenter.entity.api.db.EngineClusterVO;
-import com.cloud.hypervisor.Hypervisor.HypervisorType;
-import com.cloud.org.Cluster.ClusterType;
-import com.cloud.org.Grouping.AllocationState;
-import com.cloud.org.Managed.ManagedState;
-import com.cloud.utils.fsm.NoTransitionException;
-
-
-public class ClusterEntityImpl implements ClusterEntity {
-	
-	
-	private DataCenterResourceManager manager;
-
-	private EngineClusterVO clusterVO;
-	
-	
-	public ClusterEntityImpl(String clusterId, DataCenterResourceManager manager) {
-		this.manager = manager;
-    	this.clusterVO = this.manager.loadCluster(clusterId);
-    }	
-
-	@Override
-	public boolean enable() {
-		try {
-			manager.changeState(this, Event.EnableRequest);
-		} catch (NoTransitionException e) {
-			return false;
-		}
-    	return true;
-	}
-
-	@Override
-	public boolean disable() {
-		try {
-			manager.changeState(this, Event.DisableRequest);
-		} catch (NoTransitionException e) {
-			return false;
-		}
-    	return true;
-	}
-
-	@Override
-	public boolean deactivate() {
-		try {
-			manager.changeState(this, Event.DeactivateRequest);
-		} catch (NoTransitionException e) {
-			return false;
-		}
-    	return true;
-	}
-
-
-	@Override
-	public boolean reactivate() {
-		try {
-			manager.changeState(this, Event.ActivatedRequest);
-		} catch (NoTransitionException e) {
-			return false;
-		}
-    	return true;
-	}
-
-
-	@Override
-	public State getState() {
-		return clusterVO.getState();
-	}
-
-	@Override
-	public void persist() {
-		manager.saveCluster(clusterVO);
-	}
-
-	@Override
-	public String getUuid() {
-		return clusterVO.getUuid();
-	}
-
-	@Override
-	public long getId() {
-		return clusterVO.getId();
-	}
-
-	@Override
-	public String getCurrentState() {
-		// TODO Auto-generated method stub
-		return null;
-	}
-
-	@Override
-	public String getDesiredState() {
-		// TODO Auto-generated method stub
-		return null;
-	}
-
-	@Override
-	public Date getCreatedTime() {
-		return clusterVO.getCreated();
-	}
-
-	@Override
-	public Date getLastUpdatedTime() {
-		return clusterVO.getLastUpdated();
-	}
-
-	@Override
-	public String getOwner() {
-		return clusterVO.getOwner();
-	}
-
-	@Override
-	public Map<String, String> getDetails() {
-		// TODO Auto-generated method stub
-		return null;
-	}
-
-	@Override
-	public void addDetail(String name, String value) {
-		// TODO Auto-generated method stub
-
-	}
-
-	@Override
-	public void delDetail(String name, String value) {
-		// TODO Auto-generated method stub
-
-	}
-
-	@Override
-	public void updateDetail(String name, String value) {
-		// TODO Auto-generated method stub
-
-	}
-
-	@Override
-	public List<Method> getApplicableActions() {
-		// TODO Auto-generated method stub
-		return null;
-	}
-
-	@Override
-	public String getName() {
-		return clusterVO.getName();
-	}
-
-	@Override
-	public long getDataCenterId() {
-		return clusterVO.getDataCenterId();
-	}
-
-	@Override
-	public long getPodId() {
-		return clusterVO.getPodId();
-	}
-
-	@Override
-	public HypervisorType getHypervisorType() {
-		return clusterVO.getHypervisorType();
-	}
-
-	@Override
-	public ClusterType getClusterType() {
-		return clusterVO.getClusterType();
-	}
-
-	@Override
-	public AllocationState getAllocationState() {
-		return clusterVO.getAllocationState();
-	}
-
-	@Override
-	public ManagedState getManagedState() {
-		return clusterVO.getManagedState();
-	}
-
-	public void setOwner(String owner) {
-		clusterVO.setOwner(owner);
-	}
-
-	public void setName(String name) {
-		clusterVO.setName(name);
-	}
-
-}
+
+package org.apache.cloudstack.engine.datacenter.entity.api;
+
+import java.lang.reflect.Method;
+import java.util.Date;
+import java.util.List;
+import java.util.Map;
+
+import org.apache.cloudstack.engine.datacenter.entity.api.DataCenterResourceEntity.State.Event;
+import org.apache.cloudstack.engine.datacenter.entity.api.db.EngineClusterVO;
+import com.cloud.hypervisor.Hypervisor.HypervisorType;
+import com.cloud.org.Cluster.ClusterType;
+import com.cloud.org.Grouping.AllocationState;
+import com.cloud.org.Managed.ManagedState;
+import com.cloud.utils.fsm.NoTransitionException;
+
+
+public class ClusterEntityImpl implements ClusterEntity {
+
+
+	private DataCenterResourceManager manager;
+
+	private EngineClusterVO clusterVO;
+
+
+	public ClusterEntityImpl(String clusterId, DataCenterResourceManager manager) {
+		this.manager = manager;
+	this.clusterVO = this.manager.loadCluster(clusterId);
+    }
+
+	@Override
+	public boolean enable() {
+		try {
+			manager.changeState(this, Event.EnableRequest);
+		} catch (NoTransitionException e) {
+			return false;
+		}
+	return true;
+	}
+
+	@Override
+	public boolean disable() {
+		try {
+			manager.changeState(this, Event.DisableRequest);
+		} catch (NoTransitionException e) {
+			return false;
+		}
+	return true;
+	}
+
+	@Override
+	public boolean deactivate() {
+		try {
+			manager.changeState(this, Event.DeactivateRequest);
+		} catch (NoTransitionException e) {
+			return false;
+		}
+	return true;
+	}
+
+
+	@Override
+	public boolean reactivate() {
+		try {
+			manager.changeState(this, Event.ActivatedRequest);
+		} catch (NoTransitionException e) {
+			return false;
+		}
+	return true;
+	}
+
+
+	@Override
+	public State getState() {
+		return clusterVO.getState();
+	}
+
+	@Override
+	public void persist() {
+		manager.saveCluster(clusterVO);
+	}
+
+	@Override
+	public String getUuid() {
+		return clusterVO.getUuid();
+	}
+
+	@Override
+	public long getId() {
+		return clusterVO.getId();
+	}
+
+	@Override
+	public String getCurrentState() {
+		// TODO Auto-generated method stub
+		return null;
+	}
+
+	@Override
+	public String getDesiredState() {
+		// TODO Auto-generated method stub
+		return null;
+	}
+
+	@Override
+	public Date getCreatedTime() {
+		return clusterVO.getCreated();
+	}
+
+	@Override
+	public Date getLastUpdatedTime() {
+		return clusterVO.getLastUpdated();
+	}
+
+	@Override
+	public String getOwner() {
+		return clusterVO.getOwner();
+	}
+
+	@Override
+	public Map<String, String> getDetails() {
+		// TODO Auto-generated method stub
+		return null;
+	}
+
+	@Override
+	public void addDetail(String name, String value) {
+		// TODO Auto-generated method stub
+
+	}
+
+	@Override
+	public void delDetail(String name, String value) {
+		// TODO Auto-generated method stub
+
+	}
+
+	@Override
+	public void updateDetail(String name, String value) {
+		// TODO Auto-generated method stub
+
+	}
+
+	@Override
+	public List<Method> getApplicableActions() {
+		// TODO Auto-generated method stub
+		return null;
+	}
+
+	@Override
+	public String getName() {
+		return clusterVO.getName();
+	}
+
+	@Override
+	public long getDataCenterId() {
+		return clusterVO.getDataCenterId();
+	}
+
+	@Override
+	public long getPodId() {
+		return clusterVO.getPodId();
+	}
+
+	@Override
+	public HypervisorType getHypervisorType() {
+		return clusterVO.getHypervisorType();
+	}
+
+	@Override
+	public ClusterType getClusterType() {
+		return clusterVO.getClusterType();
+	}
+
+	@Override
+	public AllocationState getAllocationState() {
+		return clusterVO.getAllocationState();
+	}
+
+	@Override
+	public ManagedState getManagedState() {
+		return clusterVO.getManagedState();
+	}
+
+	public void setOwner(String owner) {
+		clusterVO.setOwner(owner);
+	}
+
+	public void setName(String name) {
+		clusterVO.setName(name);
+	}
+
+}

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/469c4dd1/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/DataCenterResourceManager.java
----------------------------------------------------------------------
diff --git a/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/DataCenterResourceManager.java b/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/DataCenterResourceManager.java
index ab1cbe6..a5f6d5e 100644
--- a/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/DataCenterResourceManager.java
+++ b/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/DataCenterResourceManager.java
@@ -14,37 +14,37 @@
 // KIND, either express or implied.  See the License for the
 // specific language governing permissions and limitations
 // under the License.
-package org.apache.cloudstack.engine.datacenter.entity.api;
-
-
-import org.apache.cloudstack.engine.datacenter.entity.api.DataCenterResourceEntity.State.Event;
-import org.apache.cloudstack.engine.datacenter.entity.api.db.EngineClusterVO;
-import org.apache.cloudstack.engine.datacenter.entity.api.db.EngineDataCenterVO;
-import org.apache.cloudstack.engine.datacenter.entity.api.db.EngineHostPodVO;
-import org.apache.cloudstack.engine.datacenter.entity.api.db.EngineHostVO;
-
-import com.cloud.utils.fsm.NoTransitionException;
-
-
-
-public interface DataCenterResourceManager {
-	
-	EngineDataCenterVO loadDataCenter(String dataCenterId);
-	
-	void saveDataCenter(EngineDataCenterVO dc);
-	
-	void savePod(EngineHostPodVO dc);
-	
-	void saveCluster(EngineClusterVO cluster);
-	
-	boolean changeState(DataCenterResourceEntity entity, Event event) throws NoTransitionException;
-	
-	EngineHostPodVO loadPod(String uuid);
-	
-	EngineClusterVO loadCluster(String uuid);
-
-	EngineHostVO loadHost(String uuid);
-
-	void saveHost(EngineHostVO hostVO);
-
-}
+package org.apache.cloudstack.engine.datacenter.entity.api;
+
+
+import org.apache.cloudstack.engine.datacenter.entity.api.DataCenterResourceEntity.State.Event;
+import org.apache.cloudstack.engine.datacenter.entity.api.db.EngineClusterVO;
+import org.apache.cloudstack.engine.datacenter.entity.api.db.EngineDataCenterVO;
+import org.apache.cloudstack.engine.datacenter.entity.api.db.EngineHostPodVO;
+import org.apache.cloudstack.engine.datacenter.entity.api.db.EngineHostVO;
+
+import com.cloud.utils.fsm.NoTransitionException;
+
+
+
+public interface DataCenterResourceManager {
+
+	EngineDataCenterVO loadDataCenter(String dataCenterId);
+
+	void saveDataCenter(EngineDataCenterVO dc);
+
+	void savePod(EngineHostPodVO dc);
+
+	void saveCluster(EngineClusterVO cluster);
+
+	boolean changeState(DataCenterResourceEntity entity, Event event) throws NoTransitionException;
+
+	EngineHostPodVO loadPod(String uuid);
+
+	EngineClusterVO loadCluster(String uuid);
+
+	EngineHostVO loadHost(String uuid);
+
+	void saveHost(EngineHostVO hostVO);
+
+}

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/469c4dd1/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/DataCenterResourceManagerImpl.java
----------------------------------------------------------------------
diff --git a/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/DataCenterResourceManagerImpl.java b/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/DataCenterResourceManagerImpl.java
index 3cfca3b..c267e55 100644
--- a/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/DataCenterResourceManagerImpl.java
+++ b/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/DataCenterResourceManagerImpl.java
@@ -14,116 +14,116 @@
 // KIND, either express or implied.  See the License for the
 // specific language governing permissions and limitations
 // under the License.
-package org.apache.cloudstack.engine.datacenter.entity.api;
-
-import javax.inject.Inject;
-
-import org.apache.cloudstack.engine.datacenter.entity.api.DataCenterResourceEntity.State;
-import org.apache.cloudstack.engine.datacenter.entity.api.DataCenterResourceEntity.State.Event;
-import org.apache.cloudstack.engine.datacenter.entity.api.db.EngineClusterVO;
-import org.apache.cloudstack.engine.datacenter.entity.api.db.EngineDataCenterVO;
-import org.apache.cloudstack.engine.datacenter.entity.api.db.EngineHostPodVO;
-import org.apache.cloudstack.engine.datacenter.entity.api.db.EngineHostVO;
-import org.apache.cloudstack.engine.datacenter.entity.api.db.dao.EngineClusterDao;
-import org.apache.cloudstack.engine.datacenter.entity.api.db.dao.EngineDataCenterDao;
-import org.apache.cloudstack.engine.datacenter.entity.api.db.dao.EngineHostDao;
-import org.apache.cloudstack.engine.datacenter.entity.api.db.dao.EngineHostPodDao;
-import org.springframework.stereotype.Component;
-
-
-import com.cloud.exception.InvalidParameterValueException;
-import com.cloud.utils.fsm.NoTransitionException;
-import com.cloud.utils.fsm.StateMachine2;
-
-@Component
-public class DataCenterResourceManagerImpl implements DataCenterResourceManager {
-
-	@Inject
-    EngineDataCenterDao _dataCenterDao;
-
-	@Inject
-	EngineHostPodDao _podDao;
-
-	@Inject
-	EngineClusterDao _clusterDao;
-	
-	@Inject
-	EngineHostDao _hostDao;
-	
-	
-    protected StateMachine2<State, Event, DataCenterResourceEntity> _stateMachine = DataCenterResourceEntity.State.s_fsm;
-
-	@Override
-	public EngineDataCenterVO loadDataCenter(String dataCenterId) {
-    	EngineDataCenterVO dataCenterVO = _dataCenterDao.findByUuid(dataCenterId);
-    	if(dataCenterVO == null){
-    		throw new InvalidParameterValueException("Zone does not exist");
-    	}
-    	return dataCenterVO;
-	}
-
-	@Override
-	public void saveDataCenter(EngineDataCenterVO dc) {
-		_dataCenterDao.persist(dc);
-
-	}
-
-	@Override
-	public boolean changeState(DataCenterResourceEntity entity, Event event) throws NoTransitionException {
-		
-		if(entity instanceof ZoneEntity){
-			return _stateMachine.transitTo(entity, event, null, _dataCenterDao);
-		}else if(entity instanceof PodEntity){
-			return _stateMachine.transitTo(entity, event, null, _podDao);
-		}else if(entity instanceof ClusterEntity){
-			return _stateMachine.transitTo(entity, event, null, _clusterDao);
-		}else if(entity instanceof HostEntity){
-			return _stateMachine.transitTo(entity, event, null, _hostDao);
-		}
-
-		return false;
-	}
-
-	@Override
-	public EngineHostPodVO loadPod(String uuid) {
-		EngineHostPodVO pod = _podDao.findByUuid(uuid);
-    	if(pod == null){
-    		throw new InvalidParameterValueException("Pod does not exist");
-    	}
-		return pod;
-	}
-
-	@Override
-	public EngineClusterVO loadCluster(String uuid) {
-		EngineClusterVO cluster = _clusterDao.findByUuid(uuid);
-    	if(cluster == null){
-    		throw new InvalidParameterValueException("Pod does not exist");
-    	}
-		return cluster;
-	}
-
-	@Override
-	public void savePod(EngineHostPodVO pod) {
-		_podDao.persist(pod);
-	}
-
-	@Override
-	public void saveCluster(EngineClusterVO cluster) {
-		_clusterDao.persist(cluster);		
-	}
-
-	@Override
-	public EngineHostVO loadHost(String uuid) {
-		EngineHostVO host = _hostDao.findByUuid(uuid);
-    	if(host == null){
-    		throw new InvalidParameterValueException("Host does not exist");
-    	}
-		return host;
-	}
-
-	@Override
-	public void saveHost(EngineHostVO hostVO) {
-		_hostDao.persist(hostVO);		
-	}
-
-}
+package org.apache.cloudstack.engine.datacenter.entity.api;
+
+import javax.inject.Inject;
+
+import org.apache.cloudstack.engine.datacenter.entity.api.DataCenterResourceEntity.State;
+import org.apache.cloudstack.engine.datacenter.entity.api.DataCenterResourceEntity.State.Event;
+import org.apache.cloudstack.engine.datacenter.entity.api.db.EngineClusterVO;
+import org.apache.cloudstack.engine.datacenter.entity.api.db.EngineDataCenterVO;
+import org.apache.cloudstack.engine.datacenter.entity.api.db.EngineHostPodVO;
+import org.apache.cloudstack.engine.datacenter.entity.api.db.EngineHostVO;
+import org.apache.cloudstack.engine.datacenter.entity.api.db.dao.EngineClusterDao;
+import org.apache.cloudstack.engine.datacenter.entity.api.db.dao.EngineDataCenterDao;
+import org.apache.cloudstack.engine.datacenter.entity.api.db.dao.EngineHostDao;
+import org.apache.cloudstack.engine.datacenter.entity.api.db.dao.EngineHostPodDao;
+import org.springframework.stereotype.Component;
+
+
+import com.cloud.exception.InvalidParameterValueException;
+import com.cloud.utils.fsm.NoTransitionException;
+import com.cloud.utils.fsm.StateMachine2;
+
+@Component
+public class DataCenterResourceManagerImpl implements DataCenterResourceManager {
+
+	@Inject
+    EngineDataCenterDao _dataCenterDao;
+
+	@Inject
+	EngineHostPodDao _podDao;
+
+	@Inject
+	EngineClusterDao _clusterDao;
+
+	@Inject
+	EngineHostDao _hostDao;
+
+
+    protected StateMachine2<State, Event, DataCenterResourceEntity> _stateMachine = DataCenterResourceEntity.State.s_fsm;
+
+	@Override
+	public EngineDataCenterVO loadDataCenter(String dataCenterId) {
+	EngineDataCenterVO dataCenterVO = _dataCenterDao.findByUuid(dataCenterId);
+	if(dataCenterVO == null){
+		throw new InvalidParameterValueException("Zone does not exist");
+	}
+	return dataCenterVO;
+	}
+
+	@Override
+	public void saveDataCenter(EngineDataCenterVO dc) {
+		_dataCenterDao.persist(dc);
+
+	}
+
+	@Override
+	public boolean changeState(DataCenterResourceEntity entity, Event event) throws NoTransitionException {
+
+		if(entity instanceof ZoneEntity){
+			return _stateMachine.transitTo(entity, event, null, _dataCenterDao);
+		}else if(entity instanceof PodEntity){
+			return _stateMachine.transitTo(entity, event, null, _podDao);
+		}else if(entity instanceof ClusterEntity){
+			return _stateMachine.transitTo(entity, event, null, _clusterDao);
+		}else if(entity instanceof HostEntity){
+			return _stateMachine.transitTo(entity, event, null, _hostDao);
+		}
+
+		return false;
+	}
+
+	@Override
+	public EngineHostPodVO loadPod(String uuid) {
+		EngineHostPodVO pod = _podDao.findByUuid(uuid);
+	if(pod == null){
+		throw new InvalidParameterValueException("Pod does not exist");
+	}
+		return pod;
+	}
+
+	@Override
+	public EngineClusterVO loadCluster(String uuid) {
+		EngineClusterVO cluster = _clusterDao.findByUuid(uuid);
+	if(cluster == null){
+		throw new InvalidParameterValueException("Pod does not exist");
+	}
+		return cluster;
+	}
+
+	@Override
+	public void savePod(EngineHostPodVO pod) {
+		_podDao.persist(pod);
+	}
+
+	@Override
+	public void saveCluster(EngineClusterVO cluster) {
+		_clusterDao.persist(cluster);
+	}
+
+	@Override
+	public EngineHostVO loadHost(String uuid) {
+		EngineHostVO host = _hostDao.findByUuid(uuid);
+	if(host == null){
+		throw new InvalidParameterValueException("Host does not exist");
+	}
+		return host;
+	}
+
+	@Override
+	public void saveHost(EngineHostVO hostVO) {
+		_hostDao.persist(hostVO);
+	}
+
+}

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/469c4dd1/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/HostEntityImpl.java
----------------------------------------------------------------------
diff --git a/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/HostEntityImpl.java b/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/HostEntityImpl.java
index b4a2080..17114e7 100644
--- a/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/HostEntityImpl.java
+++ b/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/HostEntityImpl.java
@@ -14,202 +14,202 @@
 // KIND, either express or implied.  See the License for the
 // specific language governing permissions and limitations
 // under the License.
-package org.apache.cloudstack.engine.datacenter.entity.api;
-
-import java.lang.reflect.Method;
-import java.util.Date;
-import java.util.List;
-import java.util.Map;
-
-import org.apache.cloudstack.engine.datacenter.entity.api.DataCenterResourceEntity.State.Event;
-import org.apache.cloudstack.engine.datacenter.entity.api.db.EngineHostVO;
-
-import com.cloud.hypervisor.Hypervisor.HypervisorType;
-import com.cloud.utils.fsm.NoTransitionException;
-
-public class HostEntityImpl implements HostEntity {
-	
-	private DataCenterResourceManager manager;
-    
-    private EngineHostVO hostVO;
-
-    public HostEntityImpl(String uuid, DataCenterResourceManager manager) {
-    	this.manager = manager;
-    	hostVO = manager.loadHost(uuid);
-    }
-
-	@Override
-	public boolean enable() {
-    	try {
-			manager.changeState(this, Event.EnableRequest);
-		} catch (NoTransitionException e) {
-			return false;
-		}
-    	return true;
-	}
-
-	@Override
-	public boolean disable() {
-    	try {
-			manager.changeState(this, Event.DisableRequest);
-		} catch (NoTransitionException e) {
-			return false;
-		}
-    	return true;
-	}
-
-	@Override
-	public boolean deactivate() {
-    	try {
-			manager.changeState(this, Event.DeactivateRequest);
-		} catch (NoTransitionException e) {
-			return false;
-		}
-    	return true;
-	}
-
-	@Override
-	public boolean reactivate() {
-    	try {
-			manager.changeState(this, Event.ActivatedRequest);
-		} catch (NoTransitionException e) {
-			return false;
-		}
-    	return true;
-	}
-
-	@Override
-	public State getState() {
-		return hostVO.getOrchestrationState();
-	}
-
-	@Override
-	public void persist() {
-		manager.saveHost(hostVO);
-	}
-
-	@Override
-	public String getName() {
-		return hostVO.getName();
-	}
-
-	@Override
-	public String getUuid() {
-		return hostVO.getUuid();
-	}
-
-	@Override
-	public long getId() {
-		return hostVO.getId();
-	}
-
-	@Override
-	public String getCurrentState() {
-		// TODO Auto-generated method stub
-		return null;
-	}
-
-	@Override
-	public String getDesiredState() {
-		// TODO Auto-generated method stub
-		return null;
-	}
-
-	@Override
-	public Date getCreatedTime() {
-		return hostVO.getCreated();
-	}
-
-	@Override
-	public Date getLastUpdatedTime() {
-		return hostVO.getLastUpdated();
-	}
-
-	@Override
-	public String getOwner() {
-		// TODO Auto-generated method stub
-		return hostVO.getOwner();
-	}
-
-	
-    public void setDetails(Map<String,String> details) {
-    	hostVO.setDetails(details);
-    }
-    
-	@Override
-	public Map<String, String> getDetails() {
-		return hostVO.getDetails();
-	}
-
-	@Override
-	public void addDetail(String name, String value) {
-		hostVO.setDetail(name, value);
-	}
-
-	@Override
-	public void delDetail(String name, String value) {
-		// TODO Auto-generated method stub
-	}
-
-	@Override
-	public void updateDetail(String name, String value) {
-		// TODO Auto-generated method stub
-
-	}
-
-	@Override
-	public List<Method> getApplicableActions() {
-		// TODO Auto-generated method stub
-		return null;
-	}
-
-	@Override
-	public Long getTotalMemory() {
-		return hostVO.getTotalMemory();
-	}
-
-	@Override
-	public Integer getCpus() {
-		return hostVO.getCpus();
-	}
-
-	@Override
-	public Long getSpeed() {
-		return hostVO.getSpeed();
-	}
-
-	@Override
-	public Long getPodId() {
-		return hostVO.getPodId();
-	}
-
-	@Override
-	public long getDataCenterId() {
-		return hostVO.getDataCenterId();
-	}
-
-	@Override
-	public HypervisorType getHypervisorType() {
-		return hostVO.getHypervisorType();
-	}
-
-	@Override
-	public String getGuid() {
-		return hostVO.getGuid();
-	}
-
-	@Override
-	public Long getClusterId() {
-		return hostVO.getClusterId();
-	}
-
-	public void setOwner(String owner) {
-		hostVO.setOwner(owner);
-	}
-	
-	public void setName(String name) {
-		hostVO.setName(name);
-	}
-	
-
-}
+package org.apache.cloudstack.engine.datacenter.entity.api;
+
+import java.lang.reflect.Method;
+import java.util.Date;
+import java.util.List;
+import java.util.Map;
+
+import org.apache.cloudstack.engine.datacenter.entity.api.DataCenterResourceEntity.State.Event;
+import org.apache.cloudstack.engine.datacenter.entity.api.db.EngineHostVO;
+
+import com.cloud.hypervisor.Hypervisor.HypervisorType;
+import com.cloud.utils.fsm.NoTransitionException;
+
+public class HostEntityImpl implements HostEntity {
+
+	private DataCenterResourceManager manager;
+
+    private EngineHostVO hostVO;
+
+    public HostEntityImpl(String uuid, DataCenterResourceManager manager) {
+	this.manager = manager;
+	hostVO = manager.loadHost(uuid);
+    }
+
+	@Override
+	public boolean enable() {
+	try {
+			manager.changeState(this, Event.EnableRequest);
+		} catch (NoTransitionException e) {
+			return false;
+		}
+	return true;
+	}
+
+	@Override
+	public boolean disable() {
+	try {
+			manager.changeState(this, Event.DisableRequest);
+		} catch (NoTransitionException e) {
+			return false;
+		}
+	return true;
+	}
+
+	@Override
+	public boolean deactivate() {
+	try {
+			manager.changeState(this, Event.DeactivateRequest);
+		} catch (NoTransitionException e) {
+			return false;
+		}
+	return true;
+	}
+
+	@Override
+	public boolean reactivate() {
+	try {
+			manager.changeState(this, Event.ActivatedRequest);
+		} catch (NoTransitionException e) {
+			return false;
+		}
+	return true;
+	}
+
+	@Override
+	public State getState() {
+		return hostVO.getOrchestrationState();
+	}
+
+	@Override
+	public void persist() {
+		manager.saveHost(hostVO);
+	}
+
+	@Override
+	public String getName() {
+		return hostVO.getName();
+	}
+
+	@Override
+	public String getUuid() {
+		return hostVO.getUuid();
+	}
+
+	@Override
+	public long getId() {
+		return hostVO.getId();
+	}
+
+	@Override
+	public String getCurrentState() {
+		// TODO Auto-generated method stub
+		return null;
+	}
+
+	@Override
+	public String getDesiredState() {
+		// TODO Auto-generated method stub
+		return null;
+	}
+
+	@Override
+	public Date getCreatedTime() {
+		return hostVO.getCreated();
+	}
+
+	@Override
+	public Date getLastUpdatedTime() {
+		return hostVO.getLastUpdated();
+	}
+
+	@Override
+	public String getOwner() {
+		// TODO Auto-generated method stub
+		return hostVO.getOwner();
+	}
+
+
+    public void setDetails(Map<String,String> details) {
+	hostVO.setDetails(details);
+    }
+
+	@Override
+	public Map<String, String> getDetails() {
+		return hostVO.getDetails();
+	}
+
+	@Override
+	public void addDetail(String name, String value) {
+		hostVO.setDetail(name, value);
+	}
+
+	@Override
+	public void delDetail(String name, String value) {
+		// TODO Auto-generated method stub
+	}
+
+	@Override
+	public void updateDetail(String name, String value) {
+		// TODO Auto-generated method stub
+
+	}
+
+	@Override
+	public List<Method> getApplicableActions() {
+		// TODO Auto-generated method stub
+		return null;
+	}
+
+	@Override
+	public Long getTotalMemory() {
+		return hostVO.getTotalMemory();
+	}
+
+	@Override
+	public Integer getCpus() {
+		return hostVO.getCpus();
+	}
+
+	@Override
+	public Long getSpeed() {
+		return hostVO.getSpeed();
+	}
+
+	@Override
+	public Long getPodId() {
+		return hostVO.getPodId();
+	}
+
+	@Override
+	public long getDataCenterId() {
+		return hostVO.getDataCenterId();
+	}
+
+	@Override
+	public HypervisorType getHypervisorType() {
+		return hostVO.getHypervisorType();
+	}
+
+	@Override
+	public String getGuid() {
+		return hostVO.getGuid();
+	}
+
+	@Override
+	public Long getClusterId() {
+		return hostVO.getClusterId();
+	}
+
+	public void setOwner(String owner) {
+		hostVO.setOwner(owner);
+	}
+
+	public void setName(String name) {
+		hostVO.setName(name);
+	}
+
+
+}

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/469c4dd1/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/PodEntityImpl.java
----------------------------------------------------------------------
diff --git a/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/PodEntityImpl.java b/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/PodEntityImpl.java
index 5c66a21..758a997 100755
--- a/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/PodEntityImpl.java
+++ b/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/PodEntityImpl.java
@@ -1,211 +1,211 @@
-/*
- * 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.engine.datacenter.entity.api;
-
-import java.lang.reflect.Method;
-import java.util.Date;
-import java.util.List;
-import java.util.Map;
-
-import org.apache.cloudstack.engine.datacenter.entity.api.DataCenterResourceEntity.State.Event;
-import org.apache.cloudstack.engine.datacenter.entity.api.db.EngineHostPodVO;
-
-import com.cloud.org.Cluster;
-import com.cloud.org.Grouping.AllocationState;
-import com.cloud.utils.fsm.NoTransitionException;
-
-public class PodEntityImpl implements PodEntity {
-
-	
-	private DataCenterResourceManager manager;
-    
-    private EngineHostPodVO podVO;
-
-    public PodEntityImpl(String uuid, DataCenterResourceManager manager) {
-    	this.manager = manager;
-    	podVO = manager.loadPod(uuid);
-    }
-
-    @Override
-    public boolean enable() {
-    	try {
-			manager.changeState(this, Event.EnableRequest);
-		} catch (NoTransitionException e) {
-			return false;
-		}
-    	return true;
-    }
-
-    @Override
-    public boolean disable() {
-    	try {
-			manager.changeState(this, Event.DisableRequest);
-		} catch (NoTransitionException e) {
-			return false;
-		}
-    	return true;
-    }
-
-    @Override
-    public boolean deactivate() {
-    	try {
-			manager.changeState(this, Event.DeactivateRequest);
-		} catch (NoTransitionException e) {
-			return false;
-		}
-    	return true;
-    }
-
-    @Override
-    public boolean reactivate() {
-    	try {
-			manager.changeState(this, Event.ActivatedRequest);
-		} catch (NoTransitionException e) {
-			return false;
-		}
-    	return true;
-    }
-
-    @Override
-    public State getState() {
-        return podVO.getState();
-    }
-
-    @Override
-    public String getUuid() {
-        return podVO.getUuid();
-    }
-
-    @Override
-    public long getId() {
-        return podVO.getId();
-    }
-
-    @Override
-    public String getCurrentState() {
-        // TODO Auto-generated method stub
-    	return null;
-    }
-
-    @Override
-    public String getDesiredState() {
-        // TODO Auto-generated method stub
-        return null;
-    }
-
-    @Override
-    public Date getCreatedTime() {
-        return podVO.getCreated();
-    }
-
-    @Override
-    public Date getLastUpdatedTime() {
-        return podVO.getLastUpdated();
-    }
-
-    @Override
-    public String getOwner() {
-        return podVO.getOwner();
-    }
-
-
-    @Override
-    public List<Method> getApplicableActions() {
-        // TODO Auto-generated method stub
-        return null;
-    }
-
-    @Override
-    public String getCidrAddress() {
-        return podVO.getCidrAddress();
-    }
-
-    @Override
-    public int getCidrSize() {
-        return podVO.getCidrSize();
-    }
-
-    @Override
-    public String getGateway() {
-        return podVO.getGateway();
-    }
-
-    @Override
-    public long getDataCenterId() {
-        return podVO.getDataCenterId();
-    }
-
-    @Override
-    public String getName() {
-        return podVO.getName();
-    }
-
-    @Override
-    public AllocationState getAllocationState() {
-        return podVO.getAllocationState();
-    }
-
-    @Override
-    public boolean getExternalDhcp() {
-        return podVO.getExternalDhcp();
-    }
-
-    @Override
-    public List<Cluster> listClusters() {
-        // TODO Auto-generated method stub
-        return null;
-    }
-
-	@Override
-	public void persist() {
-		manager.savePod(podVO);
-		
-	}
-
-	@Override
-	public Map<String, String> getDetails() {
-		return null;
-	}
-
-	@Override
-	public void addDetail(String name, String value) {
-		// TODO Auto-generated method stub
-		
-	}
-
-	@Override
-	public void delDetail(String name, String value) {
-		// TODO Auto-generated method stub
-		
-	}
-
-	@Override
-	public void updateDetail(String name, String value) {
-
-	}
-
-	public void setOwner(String owner) {
-		podVO.setOwner(owner);		
-	}
-
-	public void setName(String name) {
-		podVO.setName(name);
-	}
-	
-}
+/*
+ * 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.engine.datacenter.entity.api;
+
+import java.lang.reflect.Method;
+import java.util.Date;
+import java.util.List;
+import java.util.Map;
+
+import org.apache.cloudstack.engine.datacenter.entity.api.DataCenterResourceEntity.State.Event;
+import org.apache.cloudstack.engine.datacenter.entity.api.db.EngineHostPodVO;
+
+import com.cloud.org.Cluster;
+import com.cloud.org.Grouping.AllocationState;
+import com.cloud.utils.fsm.NoTransitionException;
+
+public class PodEntityImpl implements PodEntity {
+
+
+	private DataCenterResourceManager manager;
+
+    private EngineHostPodVO podVO;
+
+    public PodEntityImpl(String uuid, DataCenterResourceManager manager) {
+	this.manager = manager;
+	podVO = manager.loadPod(uuid);
+    }
+
+    @Override
+    public boolean enable() {
+	try {
+			manager.changeState(this, Event.EnableRequest);
+		} catch (NoTransitionException e) {
+			return false;
+		}
+	return true;
+    }
+
+    @Override
+    public boolean disable() {
+	try {
+			manager.changeState(this, Event.DisableRequest);
+		} catch (NoTransitionException e) {
+			return false;
+		}
+	return true;
+    }
+
+    @Override
+    public boolean deactivate() {
+	try {
+			manager.changeState(this, Event.DeactivateRequest);
+		} catch (NoTransitionException e) {
+			return false;
+		}
+	return true;
+    }
+
+    @Override
+    public boolean reactivate() {
+	try {
+			manager.changeState(this, Event.ActivatedRequest);
+		} catch (NoTransitionException e) {
+			return false;
+		}
+	return true;
+    }
+
+    @Override
+    public State getState() {
+        return podVO.getState();
+    }
+
+    @Override
+    public String getUuid() {
+        return podVO.getUuid();
+    }
+
+    @Override
+    public long getId() {
+        return podVO.getId();
+    }
+
+    @Override
+    public String getCurrentState() {
+        // TODO Auto-generated method stub
+	return null;
+    }
+
+    @Override
+    public String getDesiredState() {
+        // TODO Auto-generated method stub
+        return null;
+    }
+
+    @Override
+    public Date getCreatedTime() {
+        return podVO.getCreated();
+    }
+
+    @Override
+    public Date getLastUpdatedTime() {
+        return podVO.getLastUpdated();
+    }
+
+    @Override
+    public String getOwner() {
+        return podVO.getOwner();
+    }
+
+
+    @Override
+    public List<Method> getApplicableActions() {
+        // TODO Auto-generated method stub
+        return null;
+    }
+
+    @Override
+    public String getCidrAddress() {
+        return podVO.getCidrAddress();
+    }
+
+    @Override
+    public int getCidrSize() {
+        return podVO.getCidrSize();
+    }
+
+    @Override
+    public String getGateway() {
+        return podVO.getGateway();
+    }
+
+    @Override
+    public long getDataCenterId() {
+        return podVO.getDataCenterId();
+    }
+
+    @Override
+    public String getName() {
+        return podVO.getName();
+    }
+
+    @Override
+    public AllocationState getAllocationState() {
+        return podVO.getAllocationState();
+    }
+
+    @Override
+    public boolean getExternalDhcp() {
+        return podVO.getExternalDhcp();
+    }
+
+    @Override
+    public List<Cluster> listClusters() {
+        // TODO Auto-generated method stub
+        return null;
+    }
+
+	@Override
+	public void persist() {
+		manager.savePod(podVO);
+
+	}
+
+	@Override
+	public Map<String, String> getDetails() {
+		return null;
+	}
+
+	@Override
+	public void addDetail(String name, String value) {
+		// TODO Auto-generated method stub
+
+	}
+
+	@Override
+	public void delDetail(String name, String value) {
+		// TODO Auto-generated method stub
+
+	}
+
+	@Override
+	public void updateDetail(String name, String value) {
+
+	}
+
+	public void setOwner(String owner) {
+		podVO.setOwner(owner);
+	}
+
+	public void setName(String name) {
+		podVO.setName(name);
+	}
+
+}

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/469c4dd1/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/ZoneEntityImpl.java
----------------------------------------------------------------------
diff --git a/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/ZoneEntityImpl.java b/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/ZoneEntityImpl.java
index 333a220..e254880 100644
--- a/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/ZoneEntityImpl.java
+++ b/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/ZoneEntityImpl.java
@@ -1,201 +1,201 @@
-/*
- * 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.engine.datacenter.entity.api;
-
-import java.lang.reflect.Method;
-import java.util.ArrayList;
-import java.util.Date;
-import java.util.List;
-import java.util.Map;
-import javax.ws.rs.GET;
-import javax.ws.rs.Path;
-import org.apache.cloudstack.engine.datacenter.entity.api.DataCenterResourceEntity.State.Event;
-import org.apache.cloudstack.engine.datacenter.entity.api.db.EngineDataCenterVO;
-import com.cloud.utils.fsm.FiniteStateObject;
-import com.cloud.utils.fsm.NoTransitionException;
-
-
-@Path("/zone/{id}")
-public class ZoneEntityImpl implements ZoneEntity, FiniteStateObject<DataCenterResourceEntity.State, DataCenterResourceEntity.State.Event> {
-	
-	
-	private DataCenterResourceManager manager;
-
-	private EngineDataCenterVO dataCenterVO;
-	
-	
-	public ZoneEntityImpl(String dataCenterId, DataCenterResourceManager manager) {
-		this.manager = manager;
-    	this.dataCenterVO = this.manager.loadDataCenter(dataCenterId);
-    }
-
-	@Override
-    @GET
-    public String getUuid() {
-        return dataCenterVO.getUuid();
-    }
-
-    @Override
-    public long getId() {
-    	return dataCenterVO.getId();
-    }
-
-    @Override
-    public boolean enable() {
-    	try {
-			manager.changeState(this, Event.EnableRequest);
-		} catch (NoTransitionException e) {
-			return false;
-		}
-    	return true;
-    }
-
-    @Override
-    public boolean disable() {
-    	try {
-			manager.changeState(this, Event.DisableRequest);
-		} catch (NoTransitionException e) {
-			return false;
-		}
-    	return true;
-    }
-
-    @Override
-    public boolean deactivate() {
-    	try {
-			manager.changeState(this, Event.DeactivateRequest);
-		} catch (NoTransitionException e) {
-			return false;
-		}
-    	return true;
-    }
-
-    @Override
-    public boolean reactivate() {
-    	try {
-			manager.changeState(this, Event.ActivatedRequest);
-		} catch (NoTransitionException e) {
-			return false;
-		}
-    	return true;
-    }
-
-    @Override
-    public String getCurrentState() {
-        // TODO Auto-generated method stub
-        return "state";
-    }
-
-    @Override
-    public String getDesiredState() {
-        // TODO Auto-generated method stub
-        return "desired_state";
-    }
-
-    @Override
-    public Date getCreatedTime() {
-        return dataCenterVO.getCreated();
-    }
-
-    @Override
-    public Date getLastUpdatedTime() {
-        return  dataCenterVO.getLastUpdated();
-    }
-
-    @Override
-    public String getOwner() {
-        return dataCenterVO.getOwner();
-    }
-
-    
-    public void setOwner(String owner) {
-    	dataCenterVO.setOwner(owner);
-    }
-    
-    @Override
-    public Map<String, String> getDetails() {
-    	return dataCenterVO.getDetails();
-	}
-
-    public void setDetails(Map<String,String> details) {
-    	dataCenterVO.setDetails(details);
-    }
-
-    
-    @Override
-    public void addDetail(String name, String value) {
-    	dataCenterVO.setDetail(name, value);
-    }
-
-    @Override
-    public void delDetail(String name, String value) {
-        // TODO Auto-generated method stub
-    }
-
-    @Override
-    public void updateDetail(String name, String value) {
-        // TODO Auto-generated method stub
-
-    }
-
-    @Override
-    public List<Method> getApplicableActions() {
-        // TODO Auto-generated method stub
-        return null;
-    }
-
-    @Override
-    public State getState() {
-        return dataCenterVO.getState();
-    }
-
-
-    @Override
-    public List<PodEntity> listPods() {
-        // TODO Auto-generated method stub
-        return null;
-    }
-
-	@Override
-	public void setState(State state) {
-		//use FSM to set state.
-	}
-
-	@Override
-	public void persist() {
-		manager.saveDataCenter(dataCenterVO);
-	}
-
-    @Override
-    public String getName() {
-        return dataCenterVO.getName();
-    }
-
-    @Override
-    public List<String> listPodIds() {
-        List<String> podIds = new ArrayList<String>();
-        podIds.add("pod-uuid-1");
-        podIds.add("pod-uuid-2");
-        return podIds;
-    }
-
-	public void setName(String name) {
-		dataCenterVO.setName(name);
-	}
-}
+/*
+ * 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.engine.datacenter.entity.api;
+
+import java.lang.reflect.Method;
+import java.util.ArrayList;
+import java.util.Date;
+import java.util.List;
+import java.util.Map;
+import javax.ws.rs.GET;
+import javax.ws.rs.Path;
+import org.apache.cloudstack.engine.datacenter.entity.api.DataCenterResourceEntity.State.Event;
+import org.apache.cloudstack.engine.datacenter.entity.api.db.EngineDataCenterVO;
+import com.cloud.utils.fsm.FiniteStateObject;
+import com.cloud.utils.fsm.NoTransitionException;
+
+
+@Path("/zone/{id}")
+public class ZoneEntityImpl implements ZoneEntity, FiniteStateObject<DataCenterResourceEntity.State, DataCenterResourceEntity.State.Event> {
+
+
+	private DataCenterResourceManager manager;
+
+	private EngineDataCenterVO dataCenterVO;
+
+
+	public ZoneEntityImpl(String dataCenterId, DataCenterResourceManager manager) {
+		this.manager = manager;
+	this.dataCenterVO = this.manager.loadDataCenter(dataCenterId);
+    }
+
+	@Override
+    @GET
+    public String getUuid() {
+        return dataCenterVO.getUuid();
+    }
+
+    @Override
+    public long getId() {
+	return dataCenterVO.getId();
+    }
+
+    @Override
+    public boolean enable() {
+	try {
+			manager.changeState(this, Event.EnableRequest);
+		} catch (NoTransitionException e) {
+			return false;
+		}
+	return true;
+    }
+
+    @Override
+    public boolean disable() {
+	try {
+			manager.changeState(this, Event.DisableRequest);
+		} catch (NoTransitionException e) {
+			return false;
+		}
+	return true;
+    }
+
+    @Override
+    public boolean deactivate() {
+	try {
+			manager.changeState(this, Event.DeactivateRequest);
+		} catch (NoTransitionException e) {
+			return false;
+		}
+	return true;
+    }
+
+    @Override
+    public boolean reactivate() {
+	try {
+			manager.changeState(this, Event.ActivatedRequest);
+		} catch (NoTransitionException e) {
+			return false;
+		}
+	return true;
+    }
+
+    @Override
+    public String getCurrentState() {
+        // TODO Auto-generated method stub
+        return "state";
+    }
+
+    @Override
+    public String getDesiredState() {
+        // TODO Auto-generated method stub
+        return "desired_state";
+    }
+
+    @Override
+    public Date getCreatedTime() {
+        return dataCenterVO.getCreated();
+    }
+
+    @Override
+    public Date getLastUpdatedTime() {
+        return  dataCenterVO.getLastUpdated();
+    }
+
+    @Override
+    public String getOwner() {
+        return dataCenterVO.getOwner();
+    }
+
+
+    public void setOwner(String owner) {
+	dataCenterVO.setOwner(owner);
+    }
+
+    @Override
+    public Map<String, String> getDetails() {
+	return dataCenterVO.getDetails();
+	}
+
+    public void setDetails(Map<String,String> details) {
+	dataCenterVO.setDetails(details);
+    }
+
+
+    @Override
+    public void addDetail(String name, String value) {
+	dataCenterVO.setDetail(name, value);
+    }
+
+    @Override
+    public void delDetail(String name, String value) {
+        // TODO Auto-generated method stub
+    }
+
+    @Override
+    public void updateDetail(String name, String value) {
+        // TODO Auto-generated method stub
+
+    }
+
+    @Override
+    public List<Method> getApplicableActions() {
+        // TODO Auto-generated method stub
+        return null;
+    }
+
+    @Override
+    public State getState() {
+        return dataCenterVO.getState();
+    }
+
+
+    @Override
+    public List<PodEntity> listPods() {
+        // TODO Auto-generated method stub
+        return null;
+    }
+
+	@Override
+	public void setState(State state) {
+		//use FSM to set state.
+	}
+
+	@Override
+	public void persist() {
+		manager.saveDataCenter(dataCenterVO);
+	}
+
+    @Override
+    public String getName() {
+        return dataCenterVO.getName();
+    }
+
+    @Override
+    public List<String> listPodIds() {
+        List<String> podIds = new ArrayList<String>();
+        podIds.add("pod-uuid-1");
+        podIds.add("pod-uuid-2");
+        return podIds;
+    }
+
+	public void setName(String name) {
+		dataCenterVO.setName(name);
+	}
+}

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/469c4dd1/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/db/EngineCluster.java
----------------------------------------------------------------------
diff --git a/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/db/EngineCluster.java b/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/db/EngineCluster.java
index c4f1940..98b7a99 100644
--- a/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/db/EngineCluster.java
+++ b/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/db/EngineCluster.java
@@ -1,23 +1,23 @@
-// 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.engine.datacenter.entity.api.db;
-
-import com.cloud.org.Cluster;
-
-public interface EngineCluster extends Cluster {
-
-}
+// 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.engine.datacenter.entity.api.db;
+
+import com.cloud.org.Cluster;
+
+public interface EngineCluster extends Cluster {
+
+}

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/469c4dd1/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/db/EngineDataCenter.java
----------------------------------------------------------------------
diff --git a/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/db/EngineDataCenter.java b/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/db/EngineDataCenter.java
index 24e01a0..240dddf 100644
--- a/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/db/EngineDataCenter.java
+++ b/engine/orchestration/src/org/apache/cloudstack/engine/datacenter/entity/api/db/EngineDataCenter.java
@@ -1,23 +1,23 @@
-// 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.engine.datacenter.entity.api.db;
-
-import com.cloud.dc.DataCenter;
-
-public interface EngineDataCenter extends DataCenter {
-
-}
+// 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.engine.datacenter.entity.api.db;
+
+import com.cloud.dc.DataCenter;
+
+public interface EngineDataCenter extends DataCenter {
+
+}


Mime
View raw message