Package com.cloud.storage.Upload

Examples of com.cloud.storage.Upload.Type


  @Override
  public Long extractTemplate( VMTemplateVO template, String url,
      TemplateDataStoreVO vmTemplateHost,Long dataCenterId, long eventId, long asyncJobId, AsyncJobManager asyncMgr){

    Type type = (template.getFormat() == ImageFormat.ISO) ? Type.ISO : Type.TEMPLATE ;

    DataStore secStore = storeMgr.getImageStore(dataCenterId);

    UploadVO uploadTemplateObj = new UploadVO(secStore.getId(), template.getId(), new Date(),
                          Upload.Status.NOT_UPLOADED, type, url, Mode.FTP_UPLOAD);
View Full Code Here


    @Override
    public UploadVO createEntityDownloadURL(VMTemplateVO template, TemplateDataStoreVO vmTemplateHost, Long dataCenterId, long eventId) {

        String errorString = "";
        boolean success = false;
        Type type = (template.getFormat() == ImageFormat.ISO) ? Type.ISO : Type.TEMPLATE;

        // find an endpoint to send command
        DataStore store = storeMgr.getDataStore(vmTemplateHost.getDataStoreId(), DataStoreRole.Image);
        EndPoint ep = _epSelector.select(store);
        if (ep == null) {
View Full Code Here

  @Override
  public Long extractTemplate( VMTemplateVO template, String url,
      VMTemplateHostVO vmTemplateHost,Long dataCenterId, long eventId, long asyncJobId, AsyncJobManager asyncMgr){

    Type type = (template.getFormat() == ImageFormat.ISO) ? Type.ISO : Type.TEMPLATE ;
       
    List<HostVO> storageServers = _resourceMgr.listAllHostsInOneZoneByType(Host.Type.SecondaryStorage, dataCenterId);
    HostVO sserver = storageServers.get(0);     
   
    UploadVO uploadTemplateObj = new UploadVO(sserver.getId(), template.getId(), new Date(),
View Full Code Here

  public UploadVO createEntityDownloadURL(VMTemplateVO template, VMTemplateHostVO vmTemplateHost, Long dataCenterId, long eventId) {
     
      String errorString = "";
      boolean success = false;
      Host secStorage = ApiDBUtils.findHostById(vmTemplateHost.getHostId());     
      Type type = (template.getFormat() == ImageFormat.ISO) ? Type.ISO : Type.TEMPLATE ;
     
        //Check if ssvm is up
        HostVO ssvm = _ssvmMgr.pickSsvmHost(ApiDBUtils.findHostById(vmTemplateHost.getHostId()));
        if( ssvm == null ) {
            throw new CloudRuntimeException("There is no secondary storage VM for secondary storage host " + secStorage.getId());
View Full Code Here

TOP

Related Classes of com.cloud.storage.Upload.Type

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.