Changeset 408 for gssim_ui/branches


Ignore:
Timestamp:
08/18/12 00:20:34 (13 years ago)
Author:
mcichenski
Message:
 
Location:
gssim_ui/branches/vine/gssimstudio/src/web/ui/flex
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • gssim_ui/branches/vine/gssimstudio/src/web/ui/flex/app/gssim/gssimstudio/editor/gssim/experiment/ExperimentProperties.as

    r238 r408  
    5252                         
    5353                         //set default output folder: 
    54                         properties[statsOutputFolder] = "../../output/experiment_result"; 
     54                        properties[statsOutputFolder] = "../output/experiment_result"; 
    5555                        //set default values for plugins 
    5656                        properties[gridSchedulingPlugin] = null; 
     
    120120                public function setWorkloadFile(file : String) : void 
    121121                { 
    122                         properties[workloadFile] = "input/workloads/" + file; 
     122                        properties[workloadFile] = "$INPUT/" + file; 
    123123                        workload = file; 
    124124                } 
     
    126126                public function setTopologyFile(file : String) : void 
    127127                { 
    128                         properties[networkTopologyFile] = "input/topologies/" + file; 
     128                        properties[networkTopologyFile] = "$INPUT/" + file; 
    129129                        topology = file; 
    130130                } 
     
    132132                public function setResourceFile(file : String) : void 
    133133                { 
    134                         properties[resourceDescriptionFile] = "input/resources/" + file; 
     134                        properties[resourceDescriptionFile] = "$INPUT/" + file; 
    135135                        resources = file; 
    136136                } 
  • gssim_ui/branches/vine/gssimstudio/src/web/ui/flex/app/gssim/gssimstudio/editor/views/ExperimentEditor.mxml

    r391 r408  
    9898                                 
    9999                                parentApplication.service.uploadAndSubmitExperiment 
    100                                         (propertyFileName, experiment.toString()); 
     100                                        (propertyFileName, experiment.toString(), experiment.workload, experiment.resources, experiment.topology); 
    101101                        } 
    102102                         
  • gssim_ui/branches/vine/gssimstudio/src/web/ui/flex/java/gssim/gssimstudio/flex/app/editor/DatabaseHelper.java

    r370 r408  
    5656         */ 
    5757        protected String jdOutputLocation = "$OUTPUT_LOCATION"; 
     58         
     59        /** 
     60         * Properties input data location 
     61         */ 
     62        protected String pInputLocation = "$INPUT"; 
    5863} 
  • gssim_ui/branches/vine/gssimstudio/src/web/ui/flex/java/gssim/gssimstudio/flex/app/editor/GSSimStudio.java

    r407 r408  
    161161     
    162162    @BlazeDsMethod() 
    163         public GSSimStudioModel uploadAndSubmitExperiment(String destFileName, String fileContent) throws IOException { 
     163        public GSSimStudioModel uploadAndSubmitExperiment(String destFileName, String fileContent, String workload, String resources, String topology) throws IOException { 
    164164        GSSimStudioModel model = getModel(); 
    165165         
     
    168168                Integer expId = addExperimentToDb(expName, metaexpName); 
    169169                fileContent += "experiment.id="+expId.toString(); 
     170                String uniqueFolderName = "tmp" + String.valueOf(new Date().getTime()); 
     171                fileContent = fileContent.replace(pInputLocation, uniqueFolderName) 
    170172                uploadPropertyFile(destFileName, fileContent); 
    171173                 
     
    250252            String destination = gssimInput + "/" + uniqueFolderName + "/"; 
    251253            copyFile(gssimInput + "/" + destFileName, destination); 
     254            if (workload != null && !workload.isEmpty()) { 
     255                copyFile(gssimInput + "/workloads/" + workload, destination); 
     256            } 
     257            if (resources != null && !resources.isEmpty()) { 
     258                copyFile(gssimInput + "/resources/" + resources, destination); 
     259            } 
     260            if (topology != null && !topology.isEmpty()) { 
     261                copyFile(gssimInput + "/topologies/" + topology, destination); 
     262            } 
    252263                         
    253264                } catch (SQLException e) { 
Note: See TracChangeset for help on using the changeset viewer.