cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From edi...@apache.org
Subject [15/17] clean up storage related coded
Date Thu, 30 May 2013 01:06:35 GMT
http://git-wip-us.apache.org/repos/asf/cloudstack/blob/0a522892/engine/api/src/org/apache/cloudstack/storage/datastore/db/TemplateDataStoreDao.java
----------------------------------------------------------------------
diff --git a/engine/api/src/org/apache/cloudstack/storage/datastore/db/TemplateDataStoreDao.java b/engine/api/src/org/apache/cloudstack/storage/datastore/db/TemplateDataStoreDao.java
index b83c590..79acd31 100644
--- a/engine/api/src/org/apache/cloudstack/storage/datastore/db/TemplateDataStoreDao.java
+++ b/engine/api/src/org/apache/cloudstack/storage/datastore/db/TemplateDataStoreDao.java
@@ -22,14 +22,13 @@ import org.apache.cloudstack.engine.subsystem.api.storage.ObjectInDataStoreState
 import org.apache.cloudstack.engine.subsystem.api.storage.DataObjectInStore;
 import org.apache.cloudstack.engine.subsystem.api.storage.ObjectInDataStoreStateMachine;
 
-
 import com.cloud.storage.DataStoreRole;
 import com.cloud.storage.VMTemplateStorageResourceAssoc;
 import com.cloud.utils.db.GenericDao;
 import com.cloud.utils.fsm.StateDao;
 
-public interface TemplateDataStoreDao extends GenericDao<TemplateDataStoreVO, Long>, StateDao<ObjectInDataStoreStateMachine.State, ObjectInDataStoreStateMachine.Event, DataObjectInStore>  {
-
+public interface TemplateDataStoreDao extends GenericDao<TemplateDataStoreVO, Long>,
+        StateDao<ObjectInDataStoreStateMachine.State, ObjectInDataStoreStateMachine.Event, DataObjectInStore> {
 
     public List<TemplateDataStoreVO> listByStoreId(long id);
 
@@ -43,11 +42,14 @@ public interface TemplateDataStoreDao extends GenericDao<TemplateDataStoreVO, Lo
 
     List<TemplateDataStoreVO> listByTemplateStoreStatus(long templateId, long storeId, State... states);
 
-    List<TemplateDataStoreVO> listByTemplateStoreDownloadStatus(long templateId, long storeId, VMTemplateStorageResourceAssoc.Status... status);
+    List<TemplateDataStoreVO> listByTemplateStoreDownloadStatus(long templateId, long storeId,
+            VMTemplateStorageResourceAssoc.Status... status);
 
-    List<TemplateDataStoreVO> listByTemplateZoneDownloadStatus(long templateId, Long zoneId, VMTemplateStorageResourceAssoc.Status... status);
+    List<TemplateDataStoreVO> listByTemplateZoneDownloadStatus(long templateId, Long zoneId,
+            VMTemplateStorageResourceAssoc.Status... status);
 
-    TemplateDataStoreVO findByTemplateZoneDownloadStatus(long templateId, Long zoneId, VMTemplateStorageResourceAssoc.Status... status);
+    TemplateDataStoreVO findByTemplateZoneDownloadStatus(long templateId, Long zoneId,
+            VMTemplateStorageResourceAssoc.Status... status);
 
     TemplateDataStoreVO findByStoreTemplate(long storeId, long templateId);
 

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/0a522892/engine/api/src/org/apache/cloudstack/storage/datastore/db/TemplateDataStoreVO.java
----------------------------------------------------------------------
diff --git a/engine/api/src/org/apache/cloudstack/storage/datastore/db/TemplateDataStoreVO.java b/engine/api/src/org/apache/cloudstack/storage/datastore/db/TemplateDataStoreVO.java
index 44bda70..2cee4d1 100755
--- a/engine/api/src/org/apache/cloudstack/storage/datastore/db/TemplateDataStoreVO.java
+++ b/engine/api/src/org/apache/cloudstack/storage/datastore/db/TemplateDataStoreVO.java
@@ -41,67 +41,67 @@ import com.cloud.utils.fsm.StateObject;
 
 /**
  * Join table for image_data_store and templates
- *
+ * 
  */
 @Entity
-@Table(name="template_store_ref")
+@Table(name = "template_store_ref")
 public class TemplateDataStoreVO implements StateObject<ObjectInDataStoreStateMachine.State>, DataObjectInStore {
-	@Id
-	@GeneratedValue(strategy=GenerationType.IDENTITY)
-	Long id;
+    @Id
+    @GeneratedValue(strategy = GenerationType.IDENTITY)
+    Long id;
 
-	@Column(name="store_id")
-	private Long dataStoreId; // this can be null for baremetal templates
+    @Column(name = "store_id")
+    private Long dataStoreId; // this can be null for baremetal templates
 
-	@Column(name="template_id")
-	private long templateId;
+    @Column(name = "template_id")
+    private long templateId;
 
-    @Column(name="store_role")
+    @Column(name = "store_role")
     @Enumerated(EnumType.STRING)
     private DataStoreRole dataStoreRole;
 
-	@Column(name=GenericDaoBase.CREATED_COLUMN)
-	private Date created = null;
+    @Column(name = GenericDaoBase.CREATED_COLUMN)
+    private Date created = null;
 
-	@Column(name="last_updated")
-	@Temporal(value=TemporalType.TIMESTAMP)
-	private Date lastUpdated = null;
+    @Column(name = "last_updated")
+    @Temporal(value = TemporalType.TIMESTAMP)
+    private Date lastUpdated = null;
 
-	@Column (name="download_pct")
-	private int downloadPercent;
+    @Column(name = "download_pct")
+    private int downloadPercent;
 
-	@Column (name="size")
-	private long size;
+    @Column(name = "size")
+    private long size;
 
-	@Column (name="physical_size")
-	private long physicalSize;
+    @Column(name = "physical_size")
+    private long physicalSize;
 
-	@Column (name="download_state")
-	@Enumerated(EnumType.STRING)
-	private Status downloadState;
+    @Column(name = "download_state")
+    @Enumerated(EnumType.STRING)
+    private Status downloadState;
 
-	@Column (name="local_path")
-	private String localDownloadPath;
+    @Column(name = "local_path")
+    private String localDownloadPath;
 
-	@Column (name="error_str")
-	private String errorString;
+    @Column(name = "error_str")
+    private String errorString;
 
-	@Column (name="job_id")
-	private String jobId;
+    @Column(name = "job_id")
+    private String jobId;
 
-	@Column (name="install_path")
+    @Column(name = "install_path")
     private String installPath;
 
-	@Column (name="url")
-	private String downloadUrl;
+    @Column(name = "url")
+    private String downloadUrl;
 
-	@Column(name="is_copy")
-	private boolean isCopy = false;
+    @Column(name = "is_copy")
+    private boolean isCopy = false;
 
-    @Column(name="destroyed")
+    @Column(name = "destroyed")
     boolean destroyed = false;
 
-    @Column(name="update_count", updatable = true, nullable=false)
+    @Column(name = "update_count", updatable = true, nullable = false)
     protected long updatedCount;
 
     @Column(name = "updated")
@@ -112,31 +112,27 @@ public class TemplateDataStoreVO implements StateObject<ObjectInDataStoreStateMa
     @Enumerated(EnumType.STRING)
     ObjectInDataStoreStateMachine.State state;
 
+    public TemplateDataStoreVO(Long hostId, long templateId) {
+        super();
+        this.dataStoreId = hostId;
+        this.templateId = templateId;
+        this.state = ObjectInDataStoreStateMachine.State.Allocated;
+    }
 
-
-
-	public TemplateDataStoreVO(Long hostId, long templateId) {
-		super();
-		this.dataStoreId = hostId;
-		this.templateId = templateId;
-		this.state = ObjectInDataStoreStateMachine.State.Allocated;
-	}
-
-	public TemplateDataStoreVO(Long hostId, long templateId, Date lastUpdated,
-			int downloadPercent, Status downloadState,
-			String localDownloadPath, String errorString, String jobId,
-			String installPath, String downloadUrl) {
-		super();
-		this.dataStoreId = hostId;
-		this.templateId = templateId;
-		this.lastUpdated = lastUpdated;
-		this.downloadPercent = downloadPercent;
-		this.downloadState = downloadState;
-		this.localDownloadPath = localDownloadPath;
-		this.errorString = errorString;
-		this.jobId = jobId;
-		this.installPath = installPath;
-		this.setDownloadUrl(downloadUrl);
+    public TemplateDataStoreVO(Long hostId, long templateId, Date lastUpdated, int downloadPercent,
+            Status downloadState, String localDownloadPath, String errorString, String jobId, String installPath,
+            String downloadUrl) {
+        super();
+        this.dataStoreId = hostId;
+        this.templateId = templateId;
+        this.lastUpdated = lastUpdated;
+        this.downloadPercent = downloadPercent;
+        this.downloadState = downloadState;
+        this.localDownloadPath = localDownloadPath;
+        this.errorString = errorString;
+        this.jobId = jobId;
+        this.installPath = installPath;
+        this.setDownloadUrl(downloadUrl);
         switch (downloadState) {
         case DOWNLOADED:
             this.state = ObjectInDataStoreStateMachine.State.Ready;
@@ -157,18 +153,17 @@ public class TemplateDataStoreVO implements StateObject<ObjectInDataStoreStateMa
             this.state = ObjectInDataStoreStateMachine.State.Allocated;
             break;
         }
-	}
+    }
 
-	public TemplateDataStoreVO() {
+    public TemplateDataStoreVO() {
 
-	}
+    }
 
     @Override
     public String getInstallPath() {
         return installPath;
     }
 
-
     @Override
     public long getDataStoreId() {
         return dataStoreId;
@@ -224,44 +219,44 @@ public class TemplateDataStoreVO implements StateObject<ObjectInDataStoreStateMa
     }
 
     public void setLocalDownloadPath(String localPath) {
-		this.localDownloadPath = localPath;
-	}
+        this.localDownloadPath = localPath;
+    }
 
     public String getLocalDownloadPath() {
-		return localDownloadPath;
-	}
+        return localDownloadPath;
+    }
 
     public void setErrorString(String errorString) {
-		this.errorString = errorString;
-	}
+        this.errorString = errorString;
+    }
 
     public String getErrorString() {
-		return errorString;
-	}
+        return errorString;
+    }
 
     public void setJobId(String jobId) {
-		this.jobId = jobId;
-	}
+        this.jobId = jobId;
+    }
 
     public String getJobId() {
-		return jobId;
-	}
-
-	@Override
-	public boolean equals(Object obj) {
-		if (obj instanceof TemplateDataStoreVO) {
-			TemplateDataStoreVO other = (TemplateDataStoreVO)obj;
-			return (this.templateId==other.getTemplateId() && this.dataStoreId==other.getDataStoreId());
-		}
-		return false;
-	}
-
-	@Override
-	public int hashCode() {
-		Long tid = new Long(templateId);
-		Long hid = new Long(dataStoreId);
-		return tid.hashCode()+hid.hashCode();
-	}
+        return jobId;
+    }
+
+    @Override
+    public boolean equals(Object obj) {
+        if (obj instanceof TemplateDataStoreVO) {
+            TemplateDataStoreVO other = (TemplateDataStoreVO) obj;
+            return (this.templateId == other.getTemplateId() && this.dataStoreId == other.getDataStoreId());
+        }
+        return false;
+    }
+
+    @Override
+    public int hashCode() {
+        Long tid = new Long(templateId);
+        Long hid = new Long(dataStoreId);
+        return tid.hashCode() + hid.hashCode();
+    }
 
     public void setSize(Long size) {
         this.size = size;
@@ -271,7 +266,6 @@ public class TemplateDataStoreVO implements StateObject<ObjectInDataStoreStateMa
         return size;
     }
 
-
     public void setPhysicalSize(long physicalSize) {
         this.physicalSize = physicalSize;
     }
@@ -281,37 +275,38 @@ public class TemplateDataStoreVO implements StateObject<ObjectInDataStoreStateMa
     }
 
     public void setDestroyed(boolean destroyed) {
-    	this.destroyed = destroyed;
+        this.destroyed = destroyed;
     }
 
     public boolean getDestroyed() {
-    	return destroyed;
+        return destroyed;
     }
 
-	public void setDownloadUrl(String downloadUrl) {
-		this.downloadUrl = downloadUrl;
-	}
+    public void setDownloadUrl(String downloadUrl) {
+        this.downloadUrl = downloadUrl;
+    }
 
-	public String getDownloadUrl() {
-		return downloadUrl;
-	}
+    public String getDownloadUrl() {
+        return downloadUrl;
+    }
 
-	public void setCopy(boolean isCopy) {
-		this.isCopy = isCopy;
-	}
+    public void setCopy(boolean isCopy) {
+        this.isCopy = isCopy;
+    }
 
-	public boolean isCopy() {
-		return isCopy;
-	}
+    public boolean isCopy() {
+        return isCopy;
+    }
 
     public long getTemplateSize() {
-	    return -1;
-	}
+        return -1;
+    }
 
-	@Override
+    @Override
     public String toString() {
-	    return new StringBuilder("TmplHost[").append(id).append("-").append(templateId).append("-").append(dataStoreId).append(installPath).append("]").toString();
-	}
+        return new StringBuilder("TmplHost[").append(id).append("-").append(templateId).append("-").append(dataStoreId)
+                .append(installPath).append("]").toString();
+    }
 
     @Override
     public ObjectInDataStoreStateMachine.State getState() {
@@ -319,12 +314,10 @@ public class TemplateDataStoreVO implements StateObject<ObjectInDataStoreStateMa
         return this.state;
     }
 
-
     public void setState(ObjectInDataStoreStateMachine.State state) {
         this.state = state;
     }
 
-
     public long getUpdatedCount() {
         return this.updatedCount;
     }
@@ -341,7 +334,6 @@ public class TemplateDataStoreVO implements StateObject<ObjectInDataStoreStateMa
         return updated;
     }
 
-
     @Override
     public long getObjectId() {
         return this.getTemplateId();
@@ -349,7 +341,7 @@ public class TemplateDataStoreVO implements StateObject<ObjectInDataStoreStateMa
 
     @Override
     public State getObjectInStoreState() {
-       return this.state;
+        return this.state;
     }
 
     public DataStoreRole getDataStoreRole() {
@@ -360,6 +352,4 @@ public class TemplateDataStoreVO implements StateObject<ObjectInDataStoreStateMa
         this.dataStoreRole = dataStoreRole;
     }
 
-
-
 }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/0a522892/engine/api/src/org/apache/cloudstack/storage/datastore/db/VolumeDataStoreDao.java
----------------------------------------------------------------------
diff --git a/engine/api/src/org/apache/cloudstack/storage/datastore/db/VolumeDataStoreDao.java b/engine/api/src/org/apache/cloudstack/storage/datastore/db/VolumeDataStoreDao.java
index 16877b8..7c89bbf 100644
--- a/engine/api/src/org/apache/cloudstack/storage/datastore/db/VolumeDataStoreDao.java
+++ b/engine/api/src/org/apache/cloudstack/storage/datastore/db/VolumeDataStoreDao.java
@@ -16,17 +16,16 @@
 // under the License.
 package org.apache.cloudstack.storage.datastore.db;
 
-
 import java.util.List;
 
 import org.apache.cloudstack.engine.subsystem.api.storage.DataObjectInStore;
 import org.apache.cloudstack.engine.subsystem.api.storage.ObjectInDataStoreStateMachine;
 
-
 import com.cloud.utils.db.GenericDao;
 import com.cloud.utils.fsm.StateDao;
 
-public interface VolumeDataStoreDao extends GenericDao<VolumeDataStoreVO, Long>, StateDao<ObjectInDataStoreStateMachine.State, ObjectInDataStoreStateMachine.Event, DataObjectInStore>  {
+public interface VolumeDataStoreDao extends GenericDao<VolumeDataStoreVO, Long>,
+        StateDao<ObjectInDataStoreStateMachine.State, ObjectInDataStoreStateMachine.Event, DataObjectInStore> {
 
     public List<VolumeDataStoreVO> listByStoreId(long id);
 

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/0a522892/engine/api/src/org/apache/cloudstack/storage/datastore/db/VolumeDataStoreVO.java
----------------------------------------------------------------------
diff --git a/engine/api/src/org/apache/cloudstack/storage/datastore/db/VolumeDataStoreVO.java b/engine/api/src/org/apache/cloudstack/storage/datastore/db/VolumeDataStoreVO.java
index 7e89de4..d2e5c25 100755
--- a/engine/api/src/org/apache/cloudstack/storage/datastore/db/VolumeDataStoreVO.java
+++ b/engine/api/src/org/apache/cloudstack/storage/datastore/db/VolumeDataStoreVO.java
@@ -41,66 +41,66 @@ import com.cloud.utils.fsm.StateObject;
 
 /**
  * Join table for image_data_store and volumes
- *
+ * 
  */
 @Entity
-@Table(name="volume_store_ref")
+@Table(name = "volume_store_ref")
 public class VolumeDataStoreVO implements StateObject<ObjectInDataStoreStateMachine.State>, DataObjectInStore {
-	@Id
-	@GeneratedValue(strategy=GenerationType.IDENTITY)
-	Long id;
+    @Id
+    @GeneratedValue(strategy = GenerationType.IDENTITY)
+    Long id;
 
-	@Column(name="store_id")
-	private long dataStoreId;
+    @Column(name = "store_id")
+    private long dataStoreId;
 
-	@Column(name="volume_id")
-	private long volumeId;
+    @Column(name = "volume_id")
+    private long volumeId;
 
-	@Column(name="zone_id")
-	private long zoneId;
+    @Column(name = "zone_id")
+    private long zoneId;
 
-	@Column(name=GenericDaoBase.CREATED_COLUMN)
-	private Date created = null;
+    @Column(name = GenericDaoBase.CREATED_COLUMN)
+    private Date created = null;
 
-	@Column(name="last_updated")
-	@Temporal(value=TemporalType.TIMESTAMP)
-	private Date lastUpdated = null;
+    @Column(name = "last_updated")
+    @Temporal(value = TemporalType.TIMESTAMP)
+    private Date lastUpdated = null;
 
-	@Column (name="download_pct")
-	private int downloadPercent;
+    @Column(name = "download_pct")
+    private int downloadPercent;
 
-	@Column (name="size")
-	private long size;
+    @Column(name = "size")
+    private long size;
 
-	@Column (name="physical_size")
-	private long physicalSize;
+    @Column(name = "physical_size")
+    private long physicalSize;
 
-	@Column (name="download_state")
-	@Enumerated(EnumType.STRING)
-	private Status downloadState;
+    @Column(name = "download_state")
+    @Enumerated(EnumType.STRING)
+    private Status downloadState;
 
-    @Column(name="checksum")
+    @Column(name = "checksum")
     private String checksum;
 
-	@Column (name="local_path")
-	private String localDownloadPath;
+    @Column(name = "local_path")
+    private String localDownloadPath;
 
-	@Column (name="error_str")
-	private String errorString;
+    @Column(name = "error_str")
+    private String errorString;
 
-	@Column (name="job_id")
-	private String jobId;
+    @Column(name = "job_id")
+    private String jobId;
 
-	@Column (name="install_path")
+    @Column(name = "install_path")
     private String installPath;
 
-	@Column (name="url")
-	private String downloadUrl;
+    @Column(name = "url")
+    private String downloadUrl;
 
-    @Column(name="destroyed")
+    @Column(name = "destroyed")
     boolean destroyed = false;
 
-    @Column(name="update_count", updatable = true, nullable=false)
+    @Column(name = "update_count", updatable = true, nullable = false)
     protected long updatedCount;
 
     @Column(name = "updated")
@@ -112,164 +112,144 @@ public class VolumeDataStoreVO implements StateObject<ObjectInDataStoreStateMach
     ObjectInDataStoreStateMachine.State state;
 
     public String getInstallPath() {
-		return installPath;
-	}
+        return installPath;
+    }
 
     @Override
-	public long getDataStoreId() {
-		return dataStoreId;
-	}
-
-	public void setDataStoreId(long storeId) {
-		this.dataStoreId = storeId;
-	}
+    public long getDataStoreId() {
+        return dataStoreId;
+    }
 
+    public void setDataStoreId(long storeId) {
+        this.dataStoreId = storeId;
+    }
 
     public long getVolumeId() {
-		return volumeId;
-	}
-
+        return volumeId;
+    }
 
     public void setVolumeId(long volumeId) {
-		this.volumeId = volumeId;
-	}
-
+        this.volumeId = volumeId;
+    }
 
     public long getZoneId() {
-		return zoneId;
-	}
-
-	public void setZoneId(long zoneId) {
-		this.zoneId = zoneId;
-	}
+        return zoneId;
+    }
 
-	public int getDownloadPercent() {
-		return downloadPercent;
-	}
+    public void setZoneId(long zoneId) {
+        this.zoneId = zoneId;
+    }
 
+    public int getDownloadPercent() {
+        return downloadPercent;
+    }
 
     public void setDownloadPercent(int downloadPercent) {
-		this.downloadPercent = downloadPercent;
-	}
-
+        this.downloadPercent = downloadPercent;
+    }
 
     public void setDownloadState(Status downloadState) {
-		this.downloadState = downloadState;
-	}
-
+        this.downloadState = downloadState;
+    }
 
     public long getId() {
-		return id;
-	}
-
+        return id;
+    }
 
     public Date getCreated() {
-		return created;
-	}
-
+        return created;
+    }
 
     public Date getLastUpdated() {
-		return lastUpdated;
-	}
-
+        return lastUpdated;
+    }
 
     public void setLastUpdated(Date date) {
-	    lastUpdated = date;
-	}
-
+        lastUpdated = date;
+    }
 
     public void setInstallPath(String installPath) {
-	    this.installPath = installPath;
-	}
-
+        this.installPath = installPath;
+    }
 
     public Status getDownloadState() {
-		return downloadState;
-	}
-
-	public String getChecksum() {
-		return checksum;
-	}
-
-	public void setChecksum(String checksum) {
-		this.checksum = checksum;
-	}
-
-	public VolumeDataStoreVO(long hostId, long volumeId) {
-		super();
-		this.dataStoreId = hostId;
-		this.volumeId = volumeId;
-		this.state = ObjectInDataStoreStateMachine.State.Allocated;
-	}
-
-	public VolumeDataStoreVO(long hostId, long volumeId, Date lastUpdated,
-			int downloadPercent, Status downloadState,
-			String localDownloadPath, String errorString, String jobId,
-			String installPath, String downloadUrl, String checksum) {
-		//super();
-		this.dataStoreId = hostId;
-		this.volumeId = volumeId;
-		//this.zoneId = zoneId;
-		this.lastUpdated = lastUpdated;
-		this.downloadPercent = downloadPercent;
-		this.downloadState = downloadState;
-		this.localDownloadPath = localDownloadPath;
-		this.errorString = errorString;
-		this.jobId = jobId;
-		this.installPath = installPath;
-		this.setDownloadUrl(downloadUrl);
-		this.checksum = checksum;
-	}
-
-	public VolumeDataStoreVO() {
-
-	}
+        return downloadState;
+    }
 
+    public String getChecksum() {
+        return checksum;
+    }
 
-    public void setLocalDownloadPath(String localPath) {
-		this.localDownloadPath = localPath;
-	}
+    public void setChecksum(String checksum) {
+        this.checksum = checksum;
+    }
 
+    public VolumeDataStoreVO(long hostId, long volumeId) {
+        super();
+        this.dataStoreId = hostId;
+        this.volumeId = volumeId;
+        this.state = ObjectInDataStoreStateMachine.State.Allocated;
+    }
 
-    public String getLocalDownloadPath() {
-		return localDownloadPath;
-	}
+    public VolumeDataStoreVO(long hostId, long volumeId, Date lastUpdated, int downloadPercent, Status downloadState,
+            String localDownloadPath, String errorString, String jobId, String installPath, String downloadUrl,
+            String checksum) {
+        // super();
+        this.dataStoreId = hostId;
+        this.volumeId = volumeId;
+        // this.zoneId = zoneId;
+        this.lastUpdated = lastUpdated;
+        this.downloadPercent = downloadPercent;
+        this.downloadState = downloadState;
+        this.localDownloadPath = localDownloadPath;
+        this.errorString = errorString;
+        this.jobId = jobId;
+        this.installPath = installPath;
+        this.setDownloadUrl(downloadUrl);
+        this.checksum = checksum;
+    }
 
+    public VolumeDataStoreVO() {
 
-    public void setErrorString(String errorString) {
-		this.errorString = errorString;
-	}
+    }
 
+    public void setLocalDownloadPath(String localPath) {
+        this.localDownloadPath = localPath;
+    }
 
-    public String getErrorString() {
-		return errorString;
-	}
+    public String getLocalDownloadPath() {
+        return localDownloadPath;
+    }
 
+    public void setErrorString(String errorString) {
+        this.errorString = errorString;
+    }
 
-    public void setJobId(String jobId) {
-		this.jobId = jobId;
-	}
+    public String getErrorString() {
+        return errorString;
+    }
 
+    public void setJobId(String jobId) {
+        this.jobId = jobId;
+    }
 
     public String getJobId() {
-		return jobId;
-	}
-
-
-	public boolean equals(Object obj) {
-		if (obj instanceof VolumeDataStoreVO) {
-			VolumeDataStoreVO other = (VolumeDataStoreVO)obj;
-			return (this.volumeId==other.getVolumeId() && this.dataStoreId==other.getDataStoreId());
-		}
-		return false;
-	}
+        return jobId;
+    }
 
+    public boolean equals(Object obj) {
+        if (obj instanceof VolumeDataStoreVO) {
+            VolumeDataStoreVO other = (VolumeDataStoreVO) obj;
+            return (this.volumeId == other.getVolumeId() && this.dataStoreId == other.getDataStoreId());
+        }
+        return false;
+    }
 
-	public int hashCode() {
-		Long tid = new Long(volumeId);
-		Long hid = new Long(dataStoreId);
-		return tid.hashCode()+hid.hashCode();
-	}
+    public int hashCode() {
+        Long tid = new Long(volumeId);
+        Long hid = new Long(dataStoreId);
+        return tid.hashCode() + hid.hashCode();
+    }
 
     public void setSize(long size) {
         this.size = size;
@@ -279,7 +259,6 @@ public class VolumeDataStoreVO implements StateObject<ObjectInDataStoreStateMach
         return size;
     }
 
-
     public void setPhysicalSize(long physicalSize) {
         this.physicalSize = physicalSize;
     }
@@ -289,29 +268,29 @@ public class VolumeDataStoreVO implements StateObject<ObjectInDataStoreStateMach
     }
 
     public void setDestroyed(boolean destroyed) {
-    	this.destroyed = destroyed;
+        this.destroyed = destroyed;
     }
 
     public boolean getDestroyed() {
-    	return destroyed;
+        return destroyed;
     }
 
-	public void setDownloadUrl(String downloadUrl) {
-		this.downloadUrl = downloadUrl;
-	}
-
-	public String getDownloadUrl() {
-		return downloadUrl;
-	}
+    public void setDownloadUrl(String downloadUrl) {
+        this.downloadUrl = downloadUrl;
+    }
 
-	public long getVolumeSize() {
-	    return -1;
-	}
+    public String getDownloadUrl() {
+        return downloadUrl;
+    }
 
+    public long getVolumeSize() {
+        return -1;
+    }
 
     public String toString() {
-	    return new StringBuilder("VolumeHost[").append(id).append("-").append(volumeId).append("-").append(dataStoreId).append(installPath).append("]").toString();
-	}
+        return new StringBuilder("VolumeHost[").append(id).append("-").append(volumeId).append("-").append(dataStoreId)
+                .append(installPath).append("]").toString();
+    }
 
     public long getUpdatedCount() {
         return this.updatedCount;
@@ -335,7 +314,6 @@ public class VolumeDataStoreVO implements StateObject<ObjectInDataStoreStateMach
         return this.state;
     }
 
-
     public void setState(ObjectInDataStoreStateMachine.State state) {
         this.state = state;
     }
@@ -350,5 +328,4 @@ public class VolumeDataStoreVO implements StateObject<ObjectInDataStoreStateMach
         return this.state;
     }
 
-
 }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/0a522892/engine/api/src/org/apache/cloudstack/storage/image/datastore/ImageStoreEntity.java
----------------------------------------------------------------------
diff --git a/engine/api/src/org/apache/cloudstack/storage/image/datastore/ImageStoreEntity.java b/engine/api/src/org/apache/cloudstack/storage/image/datastore/ImageStoreEntity.java
index 9adcfb1..636941c 100644
--- a/engine/api/src/org/apache/cloudstack/storage/image/datastore/ImageStoreEntity.java
+++ b/engine/api/src/org/apache/cloudstack/storage/image/datastore/ImageStoreEntity.java
@@ -30,9 +30,14 @@ import com.cloud.storage.ImageStore;
 
 public interface ImageStoreEntity extends DataStore, ImageStore {
     TemplateInfo getTemplate(long templateId);
+
     VolumeInfo getVolume(long volumeId);
+
     SnapshotInfo getSnapshot(long snapshotId);
+
     boolean exists(DataObject object);
+
     Set<TemplateInfo> listTemplates();
+
     String getMountPoint(); // get the mount point on ssvm.
 }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/0a522892/engine/api/src/org/apache/cloudstack/storage/image/datastore/ImageStoreInfo.java
----------------------------------------------------------------------
diff --git a/engine/api/src/org/apache/cloudstack/storage/image/datastore/ImageStoreInfo.java b/engine/api/src/org/apache/cloudstack/storage/image/datastore/ImageStoreInfo.java
index c5f7ca9..d51780d 100644
--- a/engine/api/src/org/apache/cloudstack/storage/image/datastore/ImageStoreInfo.java
+++ b/engine/api/src/org/apache/cloudstack/storage/image/datastore/ImageStoreInfo.java
@@ -22,5 +22,6 @@ import org.apache.cloudstack.engine.subsystem.api.storage.DataStore;
 
 public interface ImageStoreInfo extends DataStore {
     public long getImageStoreId();
+
     public String getType();
 }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/0a522892/engine/api/src/org/apache/cloudstack/storage/to/ImageStoreTO.java
----------------------------------------------------------------------
diff --git a/engine/api/src/org/apache/cloudstack/storage/to/ImageStoreTO.java b/engine/api/src/org/apache/cloudstack/storage/to/ImageStoreTO.java
index 96e9479..45d0e98 100644
--- a/engine/api/src/org/apache/cloudstack/storage/to/ImageStoreTO.java
+++ b/engine/api/src/org/apache/cloudstack/storage/to/ImageStoreTO.java
@@ -27,7 +27,7 @@ public class ImageStoreTO implements DataStoreTO {
     private String providerName;
     private DataStoreRole role;
 
-    public ImageStoreTO(){
+    public ImageStoreTO() {
 
     }
 
@@ -53,7 +53,6 @@ public class ImageStoreTO implements DataStoreTO {
         return providerName;
     }
 
-
     public void setType(String type) {
         this.type = type;
     }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/0a522892/engine/api/src/org/apache/cloudstack/storage/to/NfsPrimaryDataStoreTO.java
----------------------------------------------------------------------
diff --git a/engine/api/src/org/apache/cloudstack/storage/to/NfsPrimaryDataStoreTO.java b/engine/api/src/org/apache/cloudstack/storage/to/NfsPrimaryDataStoreTO.java
deleted file mode 100644
index 96fb6bb..0000000
--- a/engine/api/src/org/apache/cloudstack/storage/to/NfsPrimaryDataStoreTO.java
+++ /dev/null
@@ -1,44 +0,0 @@
-// 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.storage.to;
-
-import org.apache.cloudstack.engine.subsystem.api.storage.PrimaryDataStoreInfo;
-
-public class NfsPrimaryDataStoreTO extends PrimaryDataStoreTO {
-    private String server;
-    private String path;
-    
-    public NfsPrimaryDataStoreTO(PrimaryDataStoreInfo dataStore) {
-        super(dataStore);
-    }
-    
-    public void setServer(String server) {
-        this.server = server;
-    }
-    
-    public String getServer() {
-        return this.server;
-    }
-    
-    public void setPath(String path) {
-        this.path = path;
-    }
-    
-    public String getPath() {
-        return this.path;
-    }
-}

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/0a522892/engine/api/src/org/apache/cloudstack/storage/to/PrimaryDataStoreTO.java
----------------------------------------------------------------------
diff --git a/engine/api/src/org/apache/cloudstack/storage/to/PrimaryDataStoreTO.java b/engine/api/src/org/apache/cloudstack/storage/to/PrimaryDataStoreTO.java
index c3ce0e0..1b4c08f 100644
--- a/engine/api/src/org/apache/cloudstack/storage/to/PrimaryDataStoreTO.java
+++ b/engine/api/src/org/apache/cloudstack/storage/to/PrimaryDataStoreTO.java
@@ -25,35 +25,35 @@ import com.cloud.storage.Storage.StoragePoolType;
 public class PrimaryDataStoreTO implements DataStoreTO {
     private final String uuid;
     private final String name;
-    private  String type;
+    private String type;
     private final long id;
     private StoragePoolType poolType;
     private String host;
     private String path;
     private int port;
+
     public PrimaryDataStoreTO(PrimaryDataStoreInfo dataStore) {
         this.uuid = dataStore.getUuid();
         this.name = dataStore.getName();
-      //  this.type = dataStore.getType();
         this.id = dataStore.getId();
         this.setPoolType(dataStore.getPoolType());
         this.setHost(dataStore.getHostAddress());
         this.setPath(dataStore.getPath());
         this.setPort(dataStore.getPort());
     }
-    
+
     public long getId() {
         return this.id;
     }
-    
+
     public String getUuid() {
         return this.uuid;
     }
-    
+
     public String getName() {
         return this.name;
     }
-    
+
     public String getType() {
         return this.type;
     }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/0a522892/engine/api/src/org/apache/cloudstack/storage/to/SnapshotObjectTO.java
----------------------------------------------------------------------
diff --git a/engine/api/src/org/apache/cloudstack/storage/to/SnapshotObjectTO.java b/engine/api/src/org/apache/cloudstack/storage/to/SnapshotObjectTO.java
index 492bd06..f8f622c 100644
--- a/engine/api/src/org/apache/cloudstack/storage/to/SnapshotObjectTO.java
+++ b/engine/api/src/org/apache/cloudstack/storage/to/SnapshotObjectTO.java
@@ -24,50 +24,50 @@ import com.cloud.agent.api.to.DataTO;
 import com.cloud.hypervisor.Hypervisor.HypervisorType;
 
 public class SnapshotObjectTO implements DataTO {
-	private String path;
-	private VolumeObjectTO volume;
-	private String parentSnapshotPath;
-	private DataStoreTO dataStore;
-	private String vmName;
-	private String name;
-	private HypervisorType hypervisorType;
-	private long id;
-	
-	public SnapshotObjectTO() {
-	    
-	}
-	
-	public SnapshotObjectTO(SnapshotInfo snapshot) {
-	    this.path = snapshot.getPath();
-	    this.setId(snapshot.getId());
-	    this.volume = (VolumeObjectTO)snapshot.getBaseVolume().getTO();
-	    this.setVmName(snapshot.getBaseVolume().getAttachedVmName());
-	    if (snapshot.getParent() != null) {
-	        this.parentSnapshotPath = snapshot.getParent().getPath();
-	    }
-	    this.dataStore = snapshot.getDataStore().getTO();
-	    this.setName(snapshot.getName());
-	    this.hypervisorType = snapshot.getHypervisorType();
-	}
-	
-	@Override
-	public DataObjectType getObjectType() {
-		return DataObjectType.SNAPSHOT;
-	}
-
-	@Override
-	public DataStoreTO getDataStore() {
-		return this.dataStore;
-	}
-
-	@Override
-	public String getPath() {
-		return this.path;
-	}
-	
-	public void setPath(String path) {
-		this.path = path;
-	}
+    private String path;
+    private VolumeObjectTO volume;
+    private String parentSnapshotPath;
+    private DataStoreTO dataStore;
+    private String vmName;
+    private String name;
+    private HypervisorType hypervisorType;
+    private long id;
+
+    public SnapshotObjectTO() {
+
+    }
+
+    public SnapshotObjectTO(SnapshotInfo snapshot) {
+        this.path = snapshot.getPath();
+        this.setId(snapshot.getId());
+        this.volume = (VolumeObjectTO) snapshot.getBaseVolume().getTO();
+        this.setVmName(snapshot.getBaseVolume().getAttachedVmName());
+        if (snapshot.getParent() != null) {
+            this.parentSnapshotPath = snapshot.getParent().getPath();
+        }
+        this.dataStore = snapshot.getDataStore().getTO();
+        this.setName(snapshot.getName());
+        this.hypervisorType = snapshot.getHypervisorType();
+    }
+
+    @Override
+    public DataObjectType getObjectType() {
+        return DataObjectType.SNAPSHOT;
+    }
+
+    @Override
+    public DataStoreTO getDataStore() {
+        return this.dataStore;
+    }
+
+    @Override
+    public String getPath() {
+        return this.path;
+    }
+
+    public void setPath(String path) {
+        this.path = path;
+    }
 
     public VolumeObjectTO getVolume() {
         return volume;

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/0a522892/engine/api/src/org/apache/cloudstack/storage/to/TemplateObjectTO.java
----------------------------------------------------------------------
diff --git a/engine/api/src/org/apache/cloudstack/storage/to/TemplateObjectTO.java b/engine/api/src/org/apache/cloudstack/storage/to/TemplateObjectTO.java
index 3d7a901..fefb0ad 100644
--- a/engine/api/src/org/apache/cloudstack/storage/to/TemplateObjectTO.java
+++ b/engine/api/src/org/apache/cloudstack/storage/to/TemplateObjectTO.java
@@ -17,8 +17,6 @@
 package org.apache.cloudstack.storage.to;
 
 import org.apache.cloudstack.engine.subsystem.api.storage.TemplateInfo;
-import org.apache.cloudstack.engine.subsystem.api.storage.disktype.DiskFormat;
-import org.apache.cloudstack.storage.image.datastore.ImageStoreInfo;
 
 import com.cloud.agent.api.to.DataObjectType;
 import com.cloud.agent.api.to.DataStoreTO;
@@ -27,17 +25,17 @@ import com.cloud.storage.Storage.ImageFormat;
 import com.cloud.template.VirtualMachineTemplate;
 
 public class TemplateObjectTO implements DataTO {
-    private  String path;
+    private String path;
     private String origUrl;
-    private  String uuid;
+    private String uuid;
     private long id;
     private ImageFormat format;
     private long accountId;
     private String checksum;
     private boolean hvm;
     private String displayText;
-    private  DataStoreTO imageDataStore;
-    private  String name;
+    private DataStoreTO imageDataStore;
+    private String name;
     private String guestOsType;
     private Long size;
 
@@ -45,7 +43,7 @@ public class TemplateObjectTO implements DataTO {
 
     }
 
-    public TemplateObjectTO(VirtualMachineTemplate template){
+    public TemplateObjectTO(VirtualMachineTemplate template) {
         this.uuid = template.getUuid();
         this.id = template.getId();
         this.origUrl = template.getUrl();
@@ -69,7 +67,7 @@ public class TemplateObjectTO implements DataTO {
         this.name = template.getUniqueName();
         this.format = template.getFormat();
         if (template.getDataStore() != null) {
-        	this.imageDataStore = template.getDataStore().getTO();
+            this.imageDataStore = template.getDataStore().getTO();
         }
     }
 
@@ -85,28 +83,35 @@ public class TemplateObjectTO implements DataTO {
     public long getId() {
         return id;
     }
+
     public ImageFormat getFormat() {
         return format;
     }
+
     public long getAccountId() {
         return accountId;
     }
+
     public String getChecksum() {
         return checksum;
     }
+
     public boolean isRequiresHvm() {
         return hvm;
     }
-    public void setRequiresHvm(boolean hvm){
+
+    public void setRequiresHvm(boolean hvm) {
         this.hvm = hvm;
     }
+
     public String getDescription() {
         return displayText;
     }
 
-    public void setDescription(String desc){
+    public void setDescription(String desc) {
         this.displayText = desc;
     }
+
     public DataStoreTO getImageDataStore() {
         return this.imageDataStore;
     }
@@ -118,7 +123,7 @@ public class TemplateObjectTO implements DataTO {
 
     @Override
     public DataStoreTO getDataStore() {
-        return (DataStoreTO)this.imageDataStore;
+        return (DataStoreTO) this.imageDataStore;
     }
 
     /**
@@ -127,30 +132,39 @@ public class TemplateObjectTO implements DataTO {
     public String getName() {
         return name;
     }
+
     public void setPath(String path) {
         this.path = path;
     }
+
     public void setUuid(String uuid) {
         this.uuid = uuid;
     }
+
     public void setName(String name) {
         this.name = name;
     }
-	public String getOrigUrl() {
-		return origUrl;
-	}
-	public void setOrigUrl(String origUrl) {
-		this.origUrl = origUrl;
-	}
+
+    public String getOrigUrl() {
+        return origUrl;
+    }
+
+    public void setOrigUrl(String origUrl) {
+        this.origUrl = origUrl;
+    }
+
     public void setFormat(ImageFormat format) {
         this.format = format;
     }
+
     public void setAccountId(long accountId) {
         this.accountId = accountId;
     }
+
     public void setChecksum(String checksum) {
         this.checksum = checksum;
     }
+
     public void setImageDataStore(DataStoreTO imageDataStore) {
         this.imageDataStore = imageDataStore;
     }
@@ -163,11 +177,11 @@ public class TemplateObjectTO implements DataTO {
         this.guestOsType = guestOsType;
     }
 
-	public Long getSize() {
-		return size;
-	}
+    public Long getSize() {
+        return size;
+    }
 
-	public void setSize(Long size) {
-		this.size = size;
-	}
+    public void setSize(Long size) {
+        this.size = size;
+    }
 }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/0a522892/engine/api/src/org/apache/cloudstack/storage/to/VolumeObjectTO.java
----------------------------------------------------------------------
diff --git a/engine/api/src/org/apache/cloudstack/storage/to/VolumeObjectTO.java b/engine/api/src/org/apache/cloudstack/storage/to/VolumeObjectTO.java
index 96cfbc7..be268ff 100644
--- a/engine/api/src/org/apache/cloudstack/storage/to/VolumeObjectTO.java
+++ b/engine/api/src/org/apache/cloudstack/storage/to/VolumeObjectTO.java
@@ -72,7 +72,7 @@ public class VolumeObjectTO implements DataTO {
     public Volume.Type getVolumeType() {
         return this.volumeType;
     }
-   
+
     public DataStoreTO getDataStore() {
         return this.dataStore;
     }
@@ -133,29 +133,28 @@ public class VolumeObjectTO implements DataTO {
         this.vmName = vmName;
     }
 
-	public String getChainInfo() {
-		return chainInfo;
-	}
-
-	public void setChainInfo(String chainInfo) {
-		this.chainInfo = chainInfo;
-	}
+    public String getChainInfo() {
+        return chainInfo;
+    }
 
-	public long getId() {
-		return id;
-	}
+    public void setChainInfo(String chainInfo) {
+        this.chainInfo = chainInfo;
+    }
 
-	public void setId(long id) {
-		this.id = id;
-	}
+    public long getId() {
+        return id;
+    }
 
-	public Storage.ImageFormat getFormat() {
-		return format;
-	}
+    public void setId(long id) {
+        this.id = id;
+    }
 
-	public void setFormat(Storage.ImageFormat format) {
-		this.format = format;
-	}
+    public Storage.ImageFormat getFormat() {
+        return format;
+    }
 
+    public void setFormat(Storage.ImageFormat format) {
+        this.format = format;
+    }
 
 }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/0a522892/engine/schema/src/com/cloud/storage/DiskOfferingVO.java
----------------------------------------------------------------------
diff --git a/engine/schema/src/com/cloud/storage/DiskOfferingVO.java b/engine/schema/src/com/cloud/storage/DiskOfferingVO.java
index 909d7fe..23b8d60 100755
--- a/engine/schema/src/com/cloud/storage/DiskOfferingVO.java
+++ b/engine/schema/src/com/cloud/storage/DiskOfferingVO.java
@@ -34,80 +34,78 @@ import javax.persistence.Temporal;
 import javax.persistence.TemporalType;
 import javax.persistence.Transient;
 
-import org.apache.cloudstack.api.Identity;
 import com.cloud.offering.DiskOffering;
 import com.cloud.utils.db.GenericDao;
-import org.apache.cloudstack.api.InternalIdentity;
 
 @Entity
-@Table(name="disk_offering")
-@Inheritance(strategy=InheritanceType.JOINED)
-@DiscriminatorColumn(name="type", discriminatorType=DiscriminatorType.STRING, length=32)
+@Table(name = "disk_offering")
+@Inheritance(strategy = InheritanceType.JOINED)
+@DiscriminatorColumn(name = "type", discriminatorType = DiscriminatorType.STRING, length = 32)
 public class DiskOfferingVO implements DiskOffering {
     public enum Type {
-        Disk,
-        Service
+        Disk, Service
     };
 
     @Id
-    @GeneratedValue(strategy=GenerationType.IDENTITY)
-    @Column(name="id")
+    @GeneratedValue(strategy = GenerationType.IDENTITY)
+    @Column(name = "id")
     long id;
 
-    @Column(name="domain_id")
+    @Column(name = "domain_id")
     Long domainId;
 
-    @Column(name="unique_name")
+    @Column(name = "unique_name")
     private String uniqueName;
 
-    @Column(name="name")
+    @Column(name = "name")
     private String name = null;
 
-    @Column(name="display_text", length=4096)
+    @Column(name = "display_text", length = 4096)
     private String displayText = null;
 
-    @Column(name="disk_size")
+    @Column(name = "disk_size")
     long diskSize;
 
-    @Column(name="tags", length=4096)
+    @Column(name = "tags", length = 4096)
     String tags;
 
-    @Column(name="type")
+    @Column(name = "type")
     Type type;
 
-    @Column(name=GenericDao.REMOVED)
+    @Column(name = GenericDao.REMOVED)
     @Temporal(TemporalType.TIMESTAMP)
     private Date removed;
 
-    @Column(name=GenericDao.CREATED_COLUMN)
+    @Column(name = GenericDao.CREATED_COLUMN)
     private Date created;
 
-    @Column(name="recreatable")
+    @Column(name = "recreatable")
     private boolean recreatable;
 
-    @Column(name="use_local_storage")
+    @Column(name = "use_local_storage")
     private boolean useLocalStorage;
 
-    @Column(name="system_use")
+    @Column(name = "system_use")
     private boolean systemUse;
 
-    @Column(name="customized")
+    @Column(name = "customized")
     private boolean customized;
 
-    @Column(name="uuid")
+    @Column(name = "uuid")
     private String uuid;
 
-    @Column(name="sort_key")
+    @Column(name = "sort_key")
     int sortKey;
 
-    @Column(name="display_offering")
+    @Column(name = "display_offering")
     boolean displayOffering;
 
     public DiskOfferingVO() {
-    	this.uuid = UUID.randomUUID().toString();
+        this.uuid = UUID.randomUUID().toString();
     }
 
-    public DiskOfferingVO(Long domainId, String name, String displayText, long diskSize, String tags, boolean isCustomized) {
+    public DiskOfferingVO(Long domainId, String name, String displayText, long diskSize, String tags,
+            boolean isCustomized) {
         this.domainId = domainId;
         this.name = name;
         this.displayText = displayText;
@@ -117,10 +115,11 @@ public class DiskOfferingVO implements DiskOffering {
         this.type = Type.Disk;
         this.useLocalStorage = false;
         this.customized = isCustomized;
-    	this.uuid = UUID.randomUUID().toString();
+        this.uuid = UUID.randomUUID().toString();
     }
 
-    public DiskOfferingVO(String name, String displayText, boolean mirrored, String tags, boolean recreatable, boolean useLocalStorage, boolean systemUse, boolean customized) {
+    public DiskOfferingVO(String name, String displayText, boolean mirrored, String tags, boolean recreatable,
+            boolean useLocalStorage, boolean systemUse, boolean customized) {
         this.domainId = null;
         this.type = Type.Service;
         this.name = name;
@@ -130,11 +129,13 @@ public class DiskOfferingVO implements DiskOffering {
         this.useLocalStorage = useLocalStorage;
         this.systemUse = systemUse;
         this.customized = customized;
-    	this.uuid = UUID.randomUUID().toString();
+        this.uuid = UUID.randomUUID().toString();
     }
 
-    //domain specific offerings constructor (null domainId implies public offering)
-    public DiskOfferingVO(String name, String displayText, boolean mirrored, String tags, boolean recreatable, boolean useLocalStorage, boolean systemUse, boolean customized, Long domainId) {
+    // domain specific offerings constructor (null domainId implies public
+    // offering)
+    public DiskOfferingVO(String name, String displayText, boolean mirrored, String tags, boolean recreatable,
+            boolean useLocalStorage, boolean systemUse, boolean customized, Long domainId) {
         this.type = Type.Service;
         this.name = name;
         this.displayText = displayText;
@@ -144,7 +145,7 @@ public class DiskOfferingVO implements DiskOffering {
         this.systemUse = systemUse;
         this.customized = customized;
         this.domainId = domainId;
-    	this.uuid = UUID.randomUUID().toString();
+        this.uuid = UUID.randomUUID().toString();
     }
 
     @Override
@@ -154,14 +155,14 @@ public class DiskOfferingVO implements DiskOffering {
 
     @Override
     public boolean isCustomized() {
-		return customized;
-	}
+        return customized;
+    }
 
-	public void setCustomized(boolean customized) {
-		this.customized = customized;
-	}
+    public void setCustomized(boolean customized) {
+        this.customized = customized;
+    }
 
-	@Override
+    @Override
     public String getUniqueName() {
         return uniqueName;
     }
@@ -197,7 +198,6 @@ public class DiskOfferingVO implements DiskOffering {
         this.name = name;
     }
 
-
     @Override
     public boolean getSystemUse() {
         return systemUse;
@@ -211,13 +211,14 @@ public class DiskOfferingVO implements DiskOffering {
     public String getDisplayText() {
         return displayText;
     }
+
     public void setDisplayText(String displayText) {
         this.displayText = displayText;
     }
 
     @Override
-    public long getDiskSize(){
-    	return diskSize;
+    public long getDiskSize() {
+        return diskSize;
     }
 
     @Override
@@ -229,10 +230,10 @@ public class DiskOfferingVO implements DiskOffering {
         return removed;
     }
 
-	@Override
+    @Override
     public Date getCreated() {
-		return created;
-	}
+        return created;
+    }
 
     protected void setTags(String tags) {
         this.tags = tags;
@@ -290,9 +291,9 @@ public class DiskOfferingVO implements DiskOffering {
         setTags(buf.toString());
     }
 
-	public void setUseLocalStorage(boolean useLocalStorage) {
-		this.useLocalStorage = useLocalStorage;
-	}
+    public void setUseLocalStorage(boolean useLocalStorage) {
+        this.useLocalStorage = useLocalStorage;
+    }
 
     public void setRemoved(Date removed) {
         this.removed = removed;
@@ -300,26 +301,25 @@ public class DiskOfferingVO implements DiskOffering {
 
     @Override
     public String getUuid() {
-    	return this.uuid;
+        return this.uuid;
     }
 
     public void setUuid(String uuid) {
-    	this.uuid = uuid;
+        this.uuid = uuid;
     }
 
     public void setSortKey(int key) {
-    	sortKey = key;
+        sortKey = key;
     }
 
     public int getSortKey() {
-    	return sortKey;
+        return sortKey;
     }
-    
+
     public void setRecreatable(boolean recreatable) {
-    	this.recreatable = recreatable;
+        this.recreatable = recreatable;
     }
 
-
     public boolean getDisplayOffering() {
         return displayOffering;
     }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/0a522892/engine/schema/src/com/cloud/storage/GuestOSCategoryVO.java
----------------------------------------------------------------------
diff --git a/engine/schema/src/com/cloud/storage/GuestOSCategoryVO.java b/engine/schema/src/com/cloud/storage/GuestOSCategoryVO.java
index 03a7479..36773e3 100644
--- a/engine/schema/src/com/cloud/storage/GuestOSCategoryVO.java
+++ b/engine/schema/src/com/cloud/storage/GuestOSCategoryVO.java
@@ -25,44 +25,41 @@ import javax.persistence.GenerationType;
 import javax.persistence.Id;
 import javax.persistence.Table;
 
-import org.apache.cloudstack.api.Identity;
-import org.apache.cloudstack.api.InternalIdentity;
-
 @Entity
-@Table(name="guest_os_category")
+@Table(name = "guest_os_category")
 public class GuestOSCategoryVO implements GuestOsCategory {
     @Id
-    @GeneratedValue(strategy=GenerationType.IDENTITY)
-    @Column(name="id")
+    @GeneratedValue(strategy = GenerationType.IDENTITY)
+    @Column(name = "id")
     long id;
 
-    @Column(name="name")
+    @Column(name = "name")
     String name;
 
-    @Column(name="uuid")
+    @Column(name = "uuid")
     String uuid = UUID.randomUUID().toString();
 
     @Override
     public long getId() {
-    	return id;
+        return id;
     }
 
     @Override
     public String getName() {
-    	return name;
+        return name;
     }
 
     @Override
     public void setName(String name) {
-    	this.name = name;
+        this.name = name;
     }
 
     @Override
     public String getUuid() {
-    	return this.uuid;
+        return this.uuid;
     }
 
     public void setUuid(String uuid) {
-    	this.uuid = uuid;
+        this.uuid = uuid;
     }
 }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/0a522892/engine/schema/src/com/cloud/storage/GuestOSVO.java
----------------------------------------------------------------------
diff --git a/engine/schema/src/com/cloud/storage/GuestOSVO.java b/engine/schema/src/com/cloud/storage/GuestOSVO.java
index 49e136d..f34d831 100644
--- a/engine/schema/src/com/cloud/storage/GuestOSVO.java
+++ b/engine/schema/src/com/cloud/storage/GuestOSVO.java
@@ -25,66 +25,63 @@ import javax.persistence.GenerationType;
 import javax.persistence.Id;
 import javax.persistence.Table;
 
-import org.apache.cloudstack.api.Identity;
-import org.apache.cloudstack.api.InternalIdentity;
-
 @Entity
-@Table(name="guest_os")
+@Table(name = "guest_os")
 public class GuestOSVO implements GuestOS {
     @Id
-    @GeneratedValue(strategy=GenerationType.IDENTITY)
-    @Column(name="id")
+    @GeneratedValue(strategy = GenerationType.IDENTITY)
+    @Column(name = "id")
     long id;
 
-    @Column(name="category_id")
+    @Column(name = "category_id")
     private long categoryId;
 
-    @Column(name="name")
+    @Column(name = "name")
     String name;
 
-    @Column(name="display_name")
+    @Column(name = "display_name")
     String displayName;
 
-    @Column(name="uuid")
+    @Column(name = "uuid")
     String uuid = UUID.randomUUID().toString();
 
     @Override
     public long getId() {
-    	return id;
+        return id;
     }
 
     public long getCategoryId() {
-    	return categoryId;
+        return categoryId;
     }
 
     public void setCategoryId(long categoryId) {
-    	this.categoryId = categoryId;
+        this.categoryId = categoryId;
     }
 
     @Override
     public String getName() {
-    	return name;
+        return name;
     }
 
     public void setName(String name) {
-    	this.name = name;
+        this.name = name;
     }
 
     @Override
     public String getDisplayName() {
-    	return displayName;
+        return displayName;
     }
 
     public void setDisplayName(String displayName) {
-    	this.displayName = displayName;
+        this.displayName = displayName;
     }
 
     @Override
     public String getUuid() {
-    	return this.uuid;
+        return this.uuid;
     }
 
     public void setUuid(String uuid) {
-    	this.uuid = uuid;
+        this.uuid = uuid;
     }
 }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/0a522892/engine/schema/src/com/cloud/storage/LaunchPermissionVO.java
----------------------------------------------------------------------
diff --git a/engine/schema/src/com/cloud/storage/LaunchPermissionVO.java b/engine/schema/src/com/cloud/storage/LaunchPermissionVO.java
index 992bac2..9082deb 100644
--- a/engine/schema/src/com/cloud/storage/LaunchPermissionVO.java
+++ b/engine/schema/src/com/cloud/storage/LaunchPermissionVO.java
@@ -24,19 +24,20 @@ import javax.persistence.Id;
 import javax.persistence.Table;
 
 @Entity
-@Table(name="launch_permission")
+@Table(name = "launch_permission")
 public class LaunchPermissionVO implements InternalIdentity {
     @Id
-    @Column(name="id")
+    @Column(name = "id")
     private Long id;
 
-    @Column(name="template_id")
+    @Column(name = "template_id")
     private long templateId;
 
-    @Column(name="account_id")
+    @Column(name = "account_id")
     private long accountId;
 
-    public LaunchPermissionVO() { }
+    public LaunchPermissionVO() {
+    }
 
     public LaunchPermissionVO(long templateId, long accountId) {
         this.templateId = templateId;

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/0a522892/engine/schema/src/com/cloud/storage/S3VO.java
----------------------------------------------------------------------
diff --git a/engine/schema/src/com/cloud/storage/S3VO.java b/engine/schema/src/com/cloud/storage/S3VO.java
index ec49bc9..6b2c23f 100644
--- a/engine/schema/src/com/cloud/storage/S3VO.java
+++ b/engine/schema/src/com/cloud/storage/S3VO.java
@@ -18,10 +18,7 @@
  */
 package com.cloud.storage;
 
-import com.cloud.agent.api.to.S3TO;
-import com.cloud.utils.db.GenericDao;
-import org.apache.cloudstack.api.Identity;
-import org.apache.cloudstack.api.InternalIdentity;
+import java.util.Date;
 
 import javax.persistence.Column;
 import javax.persistence.Entity;
@@ -29,7 +26,9 @@ import javax.persistence.GeneratedValue;
 import javax.persistence.GenerationType;
 import javax.persistence.Id;
 import javax.persistence.Table;
-import java.util.Date;
+
+import com.cloud.agent.api.to.S3TO;
+import com.cloud.utils.db.GenericDao;
 
 @Entity
 @Table(name = "s3")
@@ -76,11 +75,9 @@ public class S3VO implements S3 {
         super();
     }
 
-    public S3VO(final String uuid, final String accessKey,
-            final String secretKey, final String endPoint,
-            final String bucketName, final Boolean httpsFlag,
-            final Integer connectionTimeout, final Integer maxErrorRetry,
-            final Integer socketTimeout, final Date created) {
+    public S3VO(final String uuid, final String accessKey, final String secretKey, final String endPoint,
+            final String bucketName, final Boolean httpsFlag, final Integer connectionTimeout,
+            final Integer maxErrorRetry, final Integer socketTimeout, final Date created) {
 
         super();
 
@@ -111,10 +108,8 @@ public class S3VO implements S3 {
             httpsFlag = this.httpsFlag == 0 ? false : true;
         }
 
-        return new S3TO(this.id, this.uuid, this.accessKey, this.secretKey,
-                this.endPoint, this.bucketName, httpsFlag,
-                this.connectionTimeout, this.maxErrorRetry, this.socketTimeout,
-                this.created);
+        return new S3TO(this.id, this.uuid, this.accessKey, this.secretKey, this.endPoint, this.bucketName, httpsFlag,
+                this.connectionTimeout, this.maxErrorRetry, this.socketTimeout, this.created);
 
     }
 

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/0a522892/engine/schema/src/com/cloud/storage/SnapshotPolicyVO.java
----------------------------------------------------------------------
diff --git a/engine/schema/src/com/cloud/storage/SnapshotPolicyVO.java b/engine/schema/src/com/cloud/storage/SnapshotPolicyVO.java
index 4eb4916..fc6283d 100644
--- a/engine/schema/src/com/cloud/storage/SnapshotPolicyVO.java
+++ b/engine/schema/src/com/cloud/storage/SnapshotPolicyVO.java
@@ -25,53 +25,51 @@ import javax.persistence.GenerationType;
 import javax.persistence.Id;
 import javax.persistence.Table;
 
-import org.apache.cloudstack.api.Identity;
 import com.cloud.storage.snapshot.SnapshotPolicy;
 import com.cloud.utils.DateUtil.IntervalType;
-import org.apache.cloudstack.api.InternalIdentity;
 
 @Entity
-@Table(name="snapshot_policy")
+@Table(name = "snapshot_policy")
 public class SnapshotPolicyVO implements SnapshotPolicy {
 
     @Id
-    @GeneratedValue(strategy=GenerationType.IDENTITY)
-    @Column(name="id")
+    @GeneratedValue(strategy = GenerationType.IDENTITY)
+    @Column(name = "id")
     long id;
 
-    @Column(name="volume_id")
+    @Column(name = "volume_id")
     long volumeId;
 
-    @Column(name="schedule")
+    @Column(name = "schedule")
     String schedule;
 
-    @Column(name="timezone")
+    @Column(name = "timezone")
     String timezone;
 
-    @Column(name="interval")
+    @Column(name = "interval")
     private short interval;
 
-    @Column(name="max_snaps")
+    @Column(name = "max_snaps")
     private int maxSnaps;
 
-    @Column(name="active")
+    @Column(name = "active")
     boolean active = false;
 
-    @Column(name="uuid")
+    @Column(name = "uuid")
     String uuid;
 
     public SnapshotPolicyVO() {
-    	this.uuid = UUID.randomUUID().toString();
+        this.uuid = UUID.randomUUID().toString();
     }
 
     public SnapshotPolicyVO(long volumeId, String schedule, String timezone, IntervalType intvType, int maxSnaps) {
-    	this.volumeId = volumeId;
+        this.volumeId = volumeId;
         this.schedule = schedule;
         this.timezone = timezone;
-        this.interval = (short)intvType.ordinal();
+        this.interval = (short) intvType.ordinal();
         this.maxSnaps = maxSnaps;
         this.active = true;
-    	this.uuid = UUID.randomUUID().toString();
+        this.uuid = UUID.randomUUID().toString();
     }
 
     public long getId() {
@@ -79,10 +77,10 @@ public class SnapshotPolicyVO implements SnapshotPolicy {
     }
 
     public long getVolumeId() {
-		return volumeId;
-	}
+        return volumeId;
+    }
 
-	public void setSchedule(String schedule) {
+    public void setSchedule(String schedule) {
         this.schedule = schedule;
     }
 
@@ -124,10 +122,10 @@ public class SnapshotPolicyVO implements SnapshotPolicy {
 
     @Override
     public String getUuid() {
-    	return this.uuid;
+        return this.uuid;
     }
 
     public void setUuid(String uuid) {
-    	this.uuid = uuid;
+        this.uuid = uuid;
     }
 }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/0a522892/engine/schema/src/com/cloud/storage/SnapshotScheduleVO.java
----------------------------------------------------------------------
diff --git a/engine/schema/src/com/cloud/storage/SnapshotScheduleVO.java b/engine/schema/src/com/cloud/storage/SnapshotScheduleVO.java
index 75757c6..7adc136 100644
--- a/engine/schema/src/com/cloud/storage/SnapshotScheduleVO.java
+++ b/engine/schema/src/com/cloud/storage/SnapshotScheduleVO.java
@@ -28,40 +28,40 @@ import javax.persistence.Table;
 import javax.persistence.Temporal;
 import javax.persistence.TemporalType;
 
-import org.apache.cloudstack.api.Identity;
 import com.cloud.storage.snapshot.SnapshotSchedule;
-import org.apache.cloudstack.api.InternalIdentity;
 
 @Entity
-@Table(name="snapshot_schedule")
+@Table(name = "snapshot_schedule")
 public class SnapshotScheduleVO implements SnapshotSchedule {
 
     @Id
-    @GeneratedValue(strategy=GenerationType.IDENTITY)
-	@Column(name="id")
-	long id;
+    @GeneratedValue(strategy = GenerationType.IDENTITY)
+    @Column(name = "id")
+    long id;
 
-    // DB constraint: For a given volume and policyId, there will only be one entry in this table.
-    @Column(name="volume_id")
+    // DB constraint: For a given volume and policyId, there will only be one
+    // entry in this table.
+    @Column(name = "volume_id")
     long volumeId;
 
-    @Column(name="policy_id")
+    @Column(name = "policy_id")
     long policyId;
 
-    @Column(name="scheduled_timestamp")
-    @Temporal(value=TemporalType.TIMESTAMP)
+    @Column(name = "scheduled_timestamp")
+    @Temporal(value = TemporalType.TIMESTAMP)
     Date scheduledTimestamp;
 
-    @Column(name="async_job_id")
+    @Column(name = "async_job_id")
     Long asyncJobId;
 
-    @Column(name="snapshot_id")
+    @Column(name = "snapshot_id")
     Long snapshotId;
 
-    @Column(name="uuid")
+    @Column(name = "uuid")
     String uuid = UUID.randomUUID().toString();
 
-    public SnapshotScheduleVO() { }
+    public SnapshotScheduleVO() {
+    }
 
     public SnapshotScheduleVO(long volumeId, long policyId, Date scheduledTimestamp) {
         this.volumeId = volumeId;
@@ -83,43 +83,43 @@ public class SnapshotScheduleVO implements SnapshotSchedule {
         return policyId;
     }
 
-	public void setPolicyId(long policyId) {
+    public void setPolicyId(long policyId) {
         this.policyId = policyId;
     }
 
     /**
-	 * @return the scheduledTimestamp
-	 */
-	public Date getScheduledTimestamp() {
-		return scheduledTimestamp;
-	}
+     * @return the scheduledTimestamp
+     */
+    public Date getScheduledTimestamp() {
+        return scheduledTimestamp;
+    }
 
-	public void setScheduledTimestamp(Date scheduledTimestamp) {
+    public void setScheduledTimestamp(Date scheduledTimestamp) {
         this.scheduledTimestamp = scheduledTimestamp;
     }
 
     public Long getAsyncJobId() {
-	    return asyncJobId;
-	}
+        return asyncJobId;
+    }
 
-	public void setAsyncJobId(Long asyncJobId) {
-	    this.asyncJobId = asyncJobId;
-	}
+    public void setAsyncJobId(Long asyncJobId) {
+        this.asyncJobId = asyncJobId;
+    }
 
-	public Long getSnapshotId() {
-	    return snapshotId;
-	}
+    public Long getSnapshotId() {
+        return snapshotId;
+    }
 
-	public void setSnapshotId(Long snapshotId) {
-	    this.snapshotId = snapshotId;
-	}
+    public void setSnapshotId(Long snapshotId) {
+        this.snapshotId = snapshotId;
+    }
 
-	@Override
-	public String getUuid() {
-		return this.uuid;
-	}
+    @Override
+    public String getUuid() {
+        return this.uuid;
+    }
 
-	public void setUuid(String uuid) {
-		this.uuid = uuid;
-	}
+    public void setUuid(String uuid) {
+        this.uuid = uuid;
+    }
 }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/0a522892/engine/schema/src/com/cloud/storage/SnapshotVO.java
----------------------------------------------------------------------
diff --git a/engine/schema/src/com/cloud/storage/SnapshotVO.java b/engine/schema/src/com/cloud/storage/SnapshotVO.java
index 4fc195c..e391274 100644
--- a/engine/schema/src/com/cloud/storage/SnapshotVO.java
+++ b/engine/schema/src/com/cloud/storage/SnapshotVO.java
@@ -25,69 +25,70 @@ import java.util.Date;
 import java.util.UUID;
 
 @Entity
-@Table(name="snapshots")
+@Table(name = "snapshots")
 public class SnapshotVO implements Snapshot {
 
     @Id
-    @GeneratedValue(strategy=GenerationType.IDENTITY)
-    @Column(name="id")
+    @GeneratedValue(strategy = GenerationType.IDENTITY)
+    @Column(name = "id")
     private long id;
 
-    @Column(name="data_center_id")
+    @Column(name = "data_center_id")
     long dataCenterId;
 
-    @Column(name="account_id")
+    @Column(name = "account_id")
     long accountId;
 
-    @Column(name="domain_id")
+    @Column(name = "domain_id")
     long domainId;
 
-    @Column(name="volume_id")
+    @Column(name = "volume_id")
     Long volumeId;
 
-    @Column(name="disk_offering_id")
+    @Column(name = "disk_offering_id")
     Long diskOfferingId;
 
     @Expose
-    @Column(name="name")
+    @Column(name = "name")
     String name;
 
     @Expose
-    @Column(name="status", updatable = true, nullable=false)
-    @Enumerated(value=EnumType.STRING)
+    @Column(name = "status", updatable = true, nullable = false)
+    @Enumerated(value = EnumType.STRING)
     private State state;
 
-    @Column(name="snapshot_type")
+    @Column(name = "snapshot_type")
     short snapshotType;
 
-    @Column(name="type_description")
+    @Column(name = "type_description")
     String typeDescription;
 
-    @Column(name="size")
+    @Column(name = "size")
     long size;
 
-    @Column(name=GenericDao.CREATED_COLUMN)
+    @Column(name = GenericDao.CREATED_COLUMN)
     Date created;
 
-    @Column(name=GenericDao.REMOVED_COLUMN)
+    @Column(name = GenericDao.REMOVED_COLUMN)
     Date removed;
 
-    @Column(name="hypervisor_type")
-    @Enumerated(value=EnumType.STRING)
-    HypervisorType  hypervisorType;
+    @Column(name = "hypervisor_type")
+    @Enumerated(value = EnumType.STRING)
+    HypervisorType hypervisorType;
 
     @Expose
-    @Column(name="version")
+    @Column(name = "version")
     String version;
 
-    @Column(name="uuid")
+    @Column(name = "uuid")
     String uuid;
 
     public SnapshotVO() {
         this.uuid = UUID.randomUUID().toString();
     }
 
-    public SnapshotVO(long dcId, long accountId, long domainId, Long volumeId, Long diskOfferingId, String name, short snapshotType, String typeDescription, long size, HypervisorType hypervisorType ) {
+    public SnapshotVO(long dcId, long accountId, long domainId, Long volumeId, Long diskOfferingId, String name,
+            short snapshotType, String typeDescription, long size, HypervisorType hypervisorType) {
         this.dataCenterId = dcId;
         this.accountId = accountId;
         this.domainId = domainId;
@@ -135,11 +136,11 @@ public class SnapshotVO implements Snapshot {
         this.volumeId = volumeId;
     }
 
-
     @Override
     public String getName() {
         return name;
     }
+
     @Override
     public short getsnapshotType() {
         return snapshotType;
@@ -163,8 +164,8 @@ public class SnapshotVO implements Snapshot {
     }
 
     @Override
-    public boolean isRecursive(){
-        if ( snapshotType >= Type.HOURLY.ordinal() && snapshotType <= Type.MONTHLY.ordinal() ) {
+    public boolean isRecursive() {
+        if (snapshotType >= Type.HOURLY.ordinal() && snapshotType <= Type.MONTHLY.ordinal()) {
             return true;
         }
         return false;
@@ -177,6 +178,7 @@ public class SnapshotVO implements Snapshot {
     public String getTypeDescription() {
         return typeDescription;
     }
+
     public void setTypeDescription(String typeDescription) {
         this.typeDescription = typeDescription;
     }
@@ -203,14 +205,13 @@ public class SnapshotVO implements Snapshot {
         return state;
     }
 
-
-	public void setState(State state) {
+    public void setState(State state) {
         this.state = state;
     }
 
     public static Type getSnapshotType(String snapshotType) {
-        for ( Type type : Type.values()) {
-            if ( type.equals(snapshotType)) {
+        for (Type type : Type.values()) {
+            if (type.equals(snapshotType)) {
                 return type;
             }
         }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/0a522892/engine/schema/src/com/cloud/storage/StoragePoolHostAssoc.java
----------------------------------------------------------------------
diff --git a/engine/schema/src/com/cloud/storage/StoragePoolHostAssoc.java b/engine/schema/src/com/cloud/storage/StoragePoolHostAssoc.java
index 34326d9..1b20bf6 100644
--- a/engine/schema/src/com/cloud/storage/StoragePoolHostAssoc.java
+++ b/engine/schema/src/com/cloud/storage/StoragePoolHostAssoc.java
@@ -21,15 +21,15 @@ import org.apache.cloudstack.api.InternalIdentity;
 import java.util.Date;
 
 public interface StoragePoolHostAssoc extends InternalIdentity {
-	
-	long getHostId();
-	
-	long getPoolId();
-	
-	String getLocalPath();
 
-	Date getCreated();
+    long getHostId();
 
-	Date getLastUpdated();
+    long getPoolId();
+
+    String getLocalPath();
+
+    Date getCreated();
+
+    Date getLastUpdated();
 
 }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/0a522892/engine/schema/src/com/cloud/storage/StoragePoolHostVO.java
----------------------------------------------------------------------
diff --git a/engine/schema/src/com/cloud/storage/StoragePoolHostVO.java b/engine/schema/src/com/cloud/storage/StoragePoolHostVO.java
index 1b02f6d..3b70984 100644
--- a/engine/schema/src/com/cloud/storage/StoragePoolHostVO.java
+++ b/engine/schema/src/com/cloud/storage/StoragePoolHostVO.java
@@ -31,79 +31,73 @@ import com.cloud.utils.db.GenericDaoBase;
 
 /**
  * Join table for storage pools and hosts
- *
+ * 
  */
 @Entity
-@Table(name="storage_pool_host_ref")
+@Table(name = "storage_pool_host_ref")
 public class StoragePoolHostVO implements StoragePoolHostAssoc {
-	@Id
-	@GeneratedValue(strategy=GenerationType.IDENTITY)
-	private Long id;
+    @Id
+    @GeneratedValue(strategy = GenerationType.IDENTITY)
+    private Long id;
 
-	@Column(name="pool_id")
-	private long poolId;
+    @Column(name = "pool_id")
+    private long poolId;
 
-	@Column(name="host_id")
-	private long hostId;
+    @Column(name = "host_id")
+    private long hostId;
 
-	@Column(name="local_path")
-	private String localPath;
+    @Column(name = "local_path")
+    private String localPath;
 
-	@Column(name=GenericDaoBase.CREATED_COLUMN)
+    @Column(name = GenericDaoBase.CREATED_COLUMN)
     private Date created = null;
 
-	@Column(name="last_updated")
-	@Temporal(value=TemporalType.TIMESTAMP)
+    @Column(name = "last_updated")
+    @Temporal(value = TemporalType.TIMESTAMP)
     private Date lastUpdated = null;
 
+    public StoragePoolHostVO() {
+        super();
+    }
 
-	public StoragePoolHostVO() {
-		super();
-	}
-
-
-	public StoragePoolHostVO(long poolId, long hostId, String localPath) {
-		this.poolId = poolId;
-		this.hostId = hostId;
-		this.localPath = localPath;
-	}
-
-
-	@Override
-	public long getHostId() {
-		return hostId;
-	}
+    public StoragePoolHostVO(long poolId, long hostId, String localPath) {
+        this.poolId = poolId;
+        this.hostId = hostId;
+        this.localPath = localPath;
+    }
 
+    @Override
+    public long getHostId() {
+        return hostId;
+    }
 
     @Override
     public long getId() {
         return id;
     }
 
-
     @Override
-	public String getLocalPath() {
-		return localPath;
-	}
-
-	@Override
-	public long getPoolId() {
-		return poolId;
-	}
+    public String getLocalPath() {
+        return localPath;
+    }
 
-	@Override
-	public Date getCreated() {
-		return created;
-	}
+    @Override
+    public long getPoolId() {
+        return poolId;
+    }
 
-	@Override
-	public Date getLastUpdated() {
-		return lastUpdated;
-	}
+    @Override
+    public Date getCreated() {
+        return created;
+    }
 
+    @Override
+    public Date getLastUpdated() {
+        return lastUpdated;
+    }
 
-	public void setLocalPath(String localPath) {
-		this.localPath = localPath;
-	}
+    public void setLocalPath(String localPath) {
+        this.localPath = localPath;
+    }
 
 }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/0a522892/engine/schema/src/com/cloud/storage/StoragePoolWorkVO.java
----------------------------------------------------------------------
diff --git a/engine/schema/src/com/cloud/storage/StoragePoolWorkVO.java b/engine/schema/src/com/cloud/storage/StoragePoolWorkVO.java
index 440065d..56d57ec 100644
--- a/engine/schema/src/com/cloud/storage/StoragePoolWorkVO.java
+++ b/engine/schema/src/com/cloud/storage/StoragePoolWorkVO.java
@@ -27,9 +27,9 @@ import javax.persistence.Id;
 import javax.persistence.Table;
 
 @Entity
-@Table(name="storage_pool_work")
+@Table(name = "storage_pool_work")
 public class StoragePoolWorkVO implements InternalIdentity {
-    
+
     public long getId() {
         return id;
     }
@@ -42,22 +42,18 @@ public class StoragePoolWorkVO implements InternalIdentity {
         return poolId;
     }
 
-
     public void setPoolId(Long poolId) {
         this.poolId = poolId;
     }
 
-
     public boolean isStoppedForMaintenance() {
         return stoppedForMaintenance;
     }
 
-
     public void setStoppedForMaintenance(boolean stoppedForMaintenance) {
         this.stoppedForMaintenance = stoppedForMaintenance;
     }
 
-
     public boolean isStartedAfterMaintenance() {
         return startedAfterMaintenance;
     }
@@ -73,7 +69,7 @@ public class StoragePoolWorkVO implements InternalIdentity {
     public void setVmId(Long vmId) {
         this.vmId = vmId;
     }
-    
+
     public Long getManagementServerId() {
         return managementServerId;
     }
@@ -83,27 +79,27 @@ public class StoragePoolWorkVO implements InternalIdentity {
     }
 
     @Id
-    @GeneratedValue(strategy=GenerationType.IDENTITY)
-    @Column(name="id")
+    @GeneratedValue(strategy = GenerationType.IDENTITY)
+    @Column(name = "id")
     private Long id;
-    
-    @Column(name="pool_id")
+
+    @Column(name = "pool_id")
     private Long poolId;
 
-    @Column(name="vm_id")
+    @Column(name = "vm_id")
     private Long vmId;
-    
-    @Column(name="stopped_for_maintenance")
+
+    @Column(name = "stopped_for_maintenance")
     private boolean stoppedForMaintenance;
-    
-    @Column(name="started_after_maintenance")
+
+    @Column(name = "started_after_maintenance")
     private boolean startedAfterMaintenance;
 
-    @Column(name="mgmt_server_id")
+    @Column(name = "mgmt_server_id")
     private Long managementServerId;
-    
 
-    public StoragePoolWorkVO(long vmId, long poolId, boolean stoppedForMaintenance, boolean startedAfterMaintenance, long mgmtServerId) {
+    public StoragePoolWorkVO(long vmId, long poolId, boolean stoppedForMaintenance, boolean startedAfterMaintenance,
+            long mgmtServerId) {
         super();
         this.vmId = vmId;
         this.poolId = poolId;
@@ -111,8 +107,8 @@ public class StoragePoolWorkVO implements InternalIdentity {
         this.startedAfterMaintenance = startedAfterMaintenance;
         this.managementServerId = mgmtServerId;
     }
-    
+
     public StoragePoolWorkVO() {
-        
+
     }
 }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/0a522892/engine/schema/src/com/cloud/storage/SwiftVO.java
----------------------------------------------------------------------
diff --git a/engine/schema/src/com/cloud/storage/SwiftVO.java b/engine/schema/src/com/cloud/storage/SwiftVO.java
index c99f0ef..4136a22 100644
--- a/engine/schema/src/com/cloud/storage/SwiftVO.java
+++ b/engine/schema/src/com/cloud/storage/SwiftVO.java
@@ -26,39 +26,40 @@ import javax.persistence.GenerationType;
 import javax.persistence.Id;
 import javax.persistence.Table;
 
+import org.apache.cloudstack.api.InternalIdentity;
+
 import com.cloud.agent.api.to.SwiftTO;
-import org.apache.cloudstack.api.Identity;
 import com.cloud.utils.db.GenericDao;
-import org.apache.cloudstack.api.InternalIdentity;
 
 @Entity
-@Table(name="swift")
+@Table(name = "swift")
 public class SwiftVO implements Swift, InternalIdentity {
 
     @Id
-    @GeneratedValue(strategy=GenerationType.IDENTITY)
-    @Column(name="id")
+    @GeneratedValue(strategy = GenerationType.IDENTITY)
+    @Column(name = "id")
     private long id;
 
-    @Column(name="url")
+    @Column(name = "url")
     String url;
 
-    @Column(name="account")
+    @Column(name = "account")
     String account;
 
-    @Column(name="username")
+    @Column(name = "username")
     String userName;
 
-    @Column(name="key")
+    @Column(name = "key")
     String key;
 
-    @Column(name="uuid")
+    @Column(name = "uuid")
     String uuid = UUID.randomUUID().toString();
 
     @Column(name = GenericDao.CREATED_COLUMN)
     private Date created;
 
-    public SwiftVO() { }
+    public SwiftVO() {
+    }
 
     public SwiftVO(String url, String account, String userName, String key) {
         this.url = url;
@@ -71,18 +72,22 @@ public class SwiftVO implements Swift, InternalIdentity {
     public long getId() {
         return id;
     }
+
     @Override
     public String getUrl() {
         return url;
     }
+
     @Override
     public String getAccount() {
         return account;
     }
+
     @Override
     public String getUserName() {
         return userName;
     }
+
     @Override
     public String getKey() {
         return key;
@@ -99,10 +104,10 @@ public class SwiftVO implements Swift, InternalIdentity {
 
     @Override
     public String getUuid() {
-    	return this.uuid;
+        return this.uuid;
     }
 
     public void setUuid(String uuid) {
-    	this.uuid = uuid;
+        this.uuid = uuid;
     }
 }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/0a522892/engine/schema/src/com/cloud/storage/UploadVO.java
----------------------------------------------------------------------
diff --git a/engine/schema/src/com/cloud/storage/UploadVO.java b/engine/schema/src/com/cloud/storage/UploadVO.java
index fe8b812..63fadfa 100755
--- a/engine/schema/src/com/cloud/storage/UploadVO.java
+++ b/engine/schema/src/com/cloud/storage/UploadVO.java
@@ -34,112 +34,109 @@ import com.cloud.utils.NumbersUtil;
 import com.cloud.utils.db.GenericDaoBase;
 
 @Entity
-@Table(name="upload")
+@Table(name = "upload")
 public class UploadVO implements Upload {
-	@Id
-	@GeneratedValue(strategy=GenerationType.IDENTITY)
-	long id;
+    @Id
+    @GeneratedValue(strategy = GenerationType.IDENTITY)
+    long id;
 
-    @Column(name="uuid")
-	private String uuid;
+    @Column(name = "uuid")
+    private String uuid;
 
-	@Column(name="host_id")
-	private long storeId;
+    @Column(name = "host_id")
+    private long storeId;
 
-	@Column(name="type_id")
-	private long typeId;
+    @Column(name = "type_id")
+    private long typeId;
 
-	@Column(name=GenericDaoBase.CREATED_COLUMN)
-	private Date created = null;
+    @Column(name = GenericDaoBase.CREATED_COLUMN)
+    private Date created = null;
 
-	@Column(name="last_updated")
-	@Temporal(value=TemporalType.TIMESTAMP)
-	private Date lastUpdated = null;
+    @Column(name = "last_updated")
+    @Temporal(value = TemporalType.TIMESTAMP)
+    private Date lastUpdated = null;
 
-	@Column (name="upload_pct")
-	private int uploadPercent;
+    @Column(name = "upload_pct")
+    private int uploadPercent;
 
-	@Column (name="type")
-	@Enumerated(EnumType.STRING)
-	private Type type;
+    @Column(name = "type")
+    @Enumerated(EnumType.STRING)
+    private Type type;
 
-	@Column (name="mode")
+    @Column(name = "mode")
     @Enumerated(EnumType.STRING)
     private Mode mode = Mode.FTP_UPLOAD;
 
-	@Column (name="upload_state")
-	@Enumerated(EnumType.STRING)
-	private Status uploadState;
+    @Column(name = "upload_state")
+    @Enumerated(EnumType.STRING)
+    private Status uploadState;
 
-	@Column (name="error_str")
-	private String errorString;
+    @Column(name = "error_str")
+    private String errorString;
 
-	@Column (name="job_id")
-	private String jobId;
+    @Column(name = "job_id")
+    private String jobId;
 
-	@Column (name="url")
-	private String uploadUrl;
+    @Column(name = "url")
+    private String uploadUrl;
 
-	@Column (name="install_path")
-	private String installPath;
+    @Column(name = "install_path")
+    private String installPath;
 
-	@Override
+    @Override
     public long getDataStoreId() {
-		return storeId;
-	}
+        return storeId;
+    }
 
-	public void setDataStoreId(long hostId) {
-		this.storeId = hostId;
-	}
+    public void setDataStoreId(long hostId) {
+        this.storeId = hostId;
+    }
 
-	@Override
+    @Override
     public long getId() {
-		return id;
-	}
-
+        return id;
+    }
 
-	@Override
+    @Override
     public String getUuid() {
         return uuid;
     }
 
     @Override
     public Date getCreated() {
-		return created;
-	}
+        return created;
+    }
 
-	@Override
+    @Override
     public Date getLastUpdated() {
-		return lastUpdated;
-	}
-
-	public void setLastUpdated(Date date) {
-	    lastUpdated = date;
-	}
-
-	public UploadVO(long hostId, long templateId) {
-		super();
-		this.storeId = hostId;
-		this.typeId = templateId;
-		this.uuid = UUID.randomUUID().toString();
-	}
-
-	public UploadVO(long hostId, long typeId, Date lastUpdated,
-			Status uploadState, Type type,
-			String uploadUrl, Mode mode) {
-		super();
-		this.storeId = hostId;
-		this.typeId = typeId;
-		this.lastUpdated = lastUpdated;
-		this.uploadState = uploadState;
-		this.mode = mode;
-		this.type = type;
-		this.uploadUrl = uploadUrl;
+        return lastUpdated;
+    }
+
+    public void setLastUpdated(Date date) {
+        lastUpdated = date;
+    }
+
+    public UploadVO(long hostId, long templateId) {
+        super();
+        this.storeId = hostId;
+        this.typeId = templateId;
         this.uuid = UUID.randomUUID().toString();
-	}
+    }
 
-	public UploadVO(long hostId, long typeId, Date lastUpdated,
-            Status uploadState, int uploadPercent, Type type,
+    public UploadVO(long hostId, long typeId, Date lastUpdated, Status uploadState, Type type, String uploadUrl,
+            Mode mode) {
+        super();
+        this.storeId = hostId;
+        this.typeId = typeId;
+        this.lastUpdated = lastUpdated;
+        this.uploadState = uploadState;
+        this.mode = mode;
+        this.type = type;
+        this.uploadUrl = uploadUrl;
+        this.uuid = UUID.randomUUID().toString();
+    }
+
+    public UploadVO(long hostId, long typeId, Date lastUpdated, Status uploadState, int uploadPercent, Type type,
             Mode mode) {
         super();
         this.storeId = hostId;
@@ -153,82 +150,83 @@ public class UploadVO implements Upload {
 
     }
 
-	protected UploadVO() {
-	}
+    protected UploadVO() {
+    }
 
-	public UploadVO(Long uploadId) {
-		this.id = uploadId;
-	}
+    public UploadVO(Long uploadId) {
+        this.id = uploadId;
+    }
 
-	public void setErrorString(String errorString) {
-		this.errorString = errorString;
-	}
+    public void setErrorString(String errorString) {
+        this.errorString = errorString;
+    }
 
-	@Override
+    @Override
     public String getErrorString() {
-		return errorString;
-	}
+        return errorString;
+    }
 
-	public void setJobId(String jobId) {
-		this.jobId = jobId;
-	}
+    public void setJobId(String jobId) {
+        this.jobId = jobId;
+    }
 
-	@Override
+    @Override
     public String getJobId() {
-		return jobId;
-	}
-
-	@Override
-	public boolean equals(Object obj) {
-		if (obj instanceof UploadVO) {
-			UploadVO other = (UploadVO)obj;
-		   return (this.typeId==other.getTypeId() && this.storeId==other.getDataStoreId() && this.type == other.getType());
-		}
-		return false;
-	}
-
-	@Override
-	public int hashCode() {
-		return NumbersUtil.hash(id);
-	}
-
-	@Override
+        return jobId;
+    }
+
+    @Override
+    public boolean equals(Object obj) {
+        if (obj instanceof UploadVO) {
+            UploadVO other = (UploadVO) obj;
+            return (this.typeId == other.getTypeId() && this.storeId == other.getDataStoreId() && this.type == other
+                    .getType());
+        }
+        return false;
+    }
+
+    @Override
+    public int hashCode() {
+        return NumbersUtil.hash(id);
+    }
+
+    @Override
     public int getUploadPercent() {
-		return uploadPercent;
-	}
+        return uploadPercent;
+    }
 
-	public void setUploadPercent(int uploadPercent) {
-		this.uploadPercent = uploadPercent;
-	}
+    public void setUploadPercent(int uploadPercent) {
+        this.uploadPercent = uploadPercent;
+    }
 
-	@Override
+    @Override
     public Status getUploadState() {
-		return uploadState;
-	}
+        return uploadState;
+    }
 
-	public void setUploadState(Status uploadState) {
-		this.uploadState = uploadState;
-	}
+    public void setUploadState(Status uploadState) {
+        this.uploadState = uploadState;
+    }
 
-	@Override
+    @Override
     public long getTypeId() {
-		return typeId;
-	}
+        return typeId;
+    }
 
-	public void setTypeId(long typeId) {
-		this.typeId = typeId;
-	}
+    public void setTypeId(long typeId) {
+        this.typeId = typeId;
+    }
 
-	@Override
+    @Override
     public Type getType() {
-		return type;
-	}
+        return type;
+    }
 
-	public void setType(Type type) {
-		this.type = type;
-	}
+    public void setType(Type type) {
+        this.type = type;
+    }
 
-	@Override
+    @Override
     public Mode getMode() {
         return mode;
     }
@@ -239,22 +237,22 @@ public class UploadVO implements Upload {
 
     @Override
     public String getUploadUrl() {
-		return uploadUrl;
-	}
+        return uploadUrl;
+    }
 
-	public void setUploadUrl(String uploadUrl) {
-		this.uploadUrl = uploadUrl;
-	}
+    public void setUploadUrl(String uploadUrl) {
+        this.uploadUrl = uploadUrl;
+    }
 
-	@Override
+    @Override
     public void setId(Long id) {
-		this.id = id;
-	}
+        this.id = id;
+    }
 
-	@Override
+    @Override
     public void setCreated(Date created) {
-		this.created = created;
-	}
+        this.created = created;
+    }
 
     @Override
     public String getInstallPath() {


Mime
View raw message