Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
G
gpucloudsim
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
LPDS
gpucloudsim
Commits
262b52ea
Commit
262b52ea
authored
Jan 05, 2012
by
Anton Beloglazov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Started fixing the PlanetLab examples
parent
bc1fa0a6
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
133 additions
and
22 deletions
+133
-22
PlanetLabConstants.java
...cloudsim/examples/power/planetlab/PlanetLabConstants.java
+9
-2
PlanetLabHelper.java
...us/cloudsim/examples/power/planetlab/PlanetLabHelper.java
+11
-2
PlanetLabRunner.java
...us/cloudsim/examples/power/planetlab/PlanetLabRunner.java
+23
-13
PlanetLabRunnerConsole.java
...dsim/examples/power/planetlab/PlanetLabRunnerConsole.java
+58
-0
RandomConstants.java
...udbus/cloudsim/examples/power/random/RandomConstants.java
+9
-2
RandomHelper.java
...cloudbus/cloudsim/examples/power/random/RandomHelper.java
+12
-1
RandomRunner.java
...cloudbus/cloudsim/examples/power/random/RandomRunner.java
+11
-2
No files found.
modules/cloudsim-examples/src/main/java/org/cloudbus/cloudsim/examples/power/planetlab/PlanetLabConstants.java
View file @
262b52ea
package
org
.
cloudbus
.
cloudsim
.
examples
.
power
.
planetlab
;
package
org
.
cloudbus
.
cloudsim
.
examples
.
power
.
planetlab
;
/**
/**
* @author Anton Beloglazov
* If you are using any algorithms, policies or workload included in the power package please cite
* @since Dec 17, 2011
* the following paper:
*
* Anton Beloglazov, and Rajkumar Buyya, "Optimal Online Deterministic Algorithms and Adaptive
* Heuristics for Energy and Performance Efficient Dynamic Consolidation of Virtual Machines in
* Cloud Data Centers", Concurrency and Computation: Practice and Experience, ISSN: 1532-0626, Wiley
* Press, New York, USA, 2011, DOI: 10.1002/cpe.1867
*
*
* @author Anton Beloglazov
* @since Jan 5, 2012
*/
*/
public
class
PlanetLabConstants
{
public
class
PlanetLabConstants
{
...
...
modules/cloudsim-examples/src/main/java/org/cloudbus/cloudsim/examples/power/planetlab/PlanetLabHelper.java
View file @
262b52ea
...
@@ -12,9 +12,18 @@ import org.cloudbus.cloudsim.UtilizationModelPlanetLabInMemory;
...
@@ -12,9 +12,18 @@ import org.cloudbus.cloudsim.UtilizationModelPlanetLabInMemory;
import
org.cloudbus.cloudsim.examples.power.Constants
;
import
org.cloudbus.cloudsim.examples.power.Constants
;
/**
/**
* @author Anton Beloglazov
* A helper class for the running examples for the PlanetLab workload.
* @since Dec 17, 2011
*
* If you are using any algorithms, policies or workload included in the power package please cite
* the following paper:
*
*
* Anton Beloglazov, and Rajkumar Buyya, "Optimal Online Deterministic Algorithms and Adaptive
* Heuristics for Energy and Performance Efficient Dynamic Consolidation of Virtual Machines in
* Cloud Data Centers", Concurrency and Computation: Practice and Experience, ISSN: 1532-0626, Wiley
* Press, New York, USA, 2011, DOI: 10.1002/cpe.1867
*
* @author Anton Beloglazov
* @since Jan 5, 2012
*/
*/
public
class
PlanetLabHelper
{
public
class
PlanetLabHelper
{
...
...
modules/cloudsim-examples/src/main/java/org/cloudbus/cloudsim/examples/power/planetlab/PlanetLabRunner
Abstract
.java
→
modules/cloudsim-examples/src/main/java/org/cloudbus/cloudsim/examples/power/planetlab/PlanetLabRunner.java
View file @
262b52ea
...
@@ -8,24 +8,34 @@ import org.cloudbus.cloudsim.examples.power.Helper;
...
@@ -8,24 +8,34 @@ import org.cloudbus.cloudsim.examples.power.Helper;
import
org.cloudbus.cloudsim.examples.power.RunnerAbstract
;
import
org.cloudbus.cloudsim.examples.power.RunnerAbstract
;
/**
/**
* The Class PlanetLabRunnerAbstract.
* The example runner for the PlanetLab workload.
*
* If you are using any algorithms, policies or workload included in the power package please cite
* the following paper:
*
* Anton Beloglazov, and Rajkumar Buyya, "Optimal Online Deterministic Algorithms and Adaptive
* Heuristics for Energy and Performance Efficient Dynamic Consolidation of Virtual Machines in
* Cloud Data Centers", Concurrency and Computation: Practice and Experience, ISSN: 1532-0626, Wiley
* Press, New York, USA, 2011, DOI: 10.1002/cpe.1867
*
*
* @author Anton Beloglazov
* @author Anton Beloglazov
* @since
Dec 17, 2011
* @since
Jan 5, 2012
*/
*/
public
class
PlanetLabRunner
Abstract
extends
RunnerAbstract
{
public
class
PlanetLabRunner
extends
RunnerAbstract
{
/**
/**
* @param enableOutput
* Instantiates a new planet lab runner.
* @param outputToFile
*
* @param inputFolder
* @param enableOutput the enable output
* @param outputFolder
* @param outputToFile the output to file
* @param workload
* @param inputFolder the input folder
* @param vmAllocationPolicy
* @param outputFolder the output folder
* @param vmSelectionPolicy
* @param workload the workload
* @param parameter
* @param vmAllocationPolicy the vm allocation policy
* @param vmSelectionPolicy the vm selection policy
* @param parameter the parameter
*/
*/
public
PlanetLabRunner
Abstract
(
public
PlanetLabRunner
(
boolean
enableOutput
,
boolean
enableOutput
,
boolean
outputToFile
,
boolean
outputToFile
,
String
inputFolder
,
String
inputFolder
,
...
@@ -63,7 +73,7 @@ public class PlanetLabRunnerAbstract extends RunnerAbstract {
...
@@ -63,7 +73,7 @@ public class PlanetLabRunnerAbstract extends RunnerAbstract {
hostList
=
Helper
.
createHostList
(
PlanetLabConstants
.
NUMBER_OF_HOSTS
);
hostList
=
Helper
.
createHostList
(
PlanetLabConstants
.
NUMBER_OF_HOSTS
);
}
catch
(
Exception
e
)
{
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
e
.
printStackTrace
();
Log
.
printLine
(
"
Unwanted errors happen
"
);
Log
.
printLine
(
"
The simulation has been terminated due to an unexpected error
"
);
}
}
}
}
...
...
modules/cloudsim-examples/src/main/java/org/cloudbus/cloudsim/examples/power/planetlab/
Runner
.java
→
modules/cloudsim-examples/src/main/java/org/cloudbus/cloudsim/examples/power/planetlab/
PlanetLabRunnerConsole
.java
View file @
262b52ea
...
@@ -2,16 +2,35 @@ package org.cloudbus.cloudsim.examples.power.planetlab;
...
@@ -2,16 +2,35 @@ package org.cloudbus.cloudsim.examples.power.planetlab;
import
java.io.IOException
;
import
java.io.IOException
;
import
org.cloudbus.cloudsim.examples.power.RunnerAbstract
;
/**
* This is a universal example runner that can be used for running examples from console. All the
public
class
Runner
extends
RunnerAbstract
{
* parameters are specified as command line parameters.
*
* If you are using any algorithms, policies or workload included in the power package please cite
* the following paper:
*
* Anton Beloglazov, and Rajkumar Buyya, "Optimal Online Deterministic Algorithms and Adaptive
* Heuristics for Energy and Performance Efficient Dynamic Consolidation of Virtual Machines in
* Cloud Data Centers", Concurrency and Computation: Practice and Experience, ISSN: 1532-0626, Wiley
* Press, New York, USA, 2011, DOI: 10.1002/cpe.1867
*
* @author Anton Beloglazov
* @since Jan 5, 2012
*/
public
class
PlanetLabRunnerConsole
{
/**
* The main method.
*
* @param args the arguments
* @throws IOException Signals that an I/O exception has occurred.
*/
public
static
void
main
(
String
[]
args
)
throws
IOException
{
public
static
void
main
(
String
[]
args
)
throws
IOException
{
boolean
enableOutput
=
false
;
boolean
enableOutput
=
false
;
boolean
outputToFile
=
true
;
if
(
args
[
0
].
equals
(
"1"
))
{
if
(
args
[
0
].
equals
(
"1"
))
{
enableOutput
=
true
;
enableOutput
=
true
;
}
}
System
.
out
.
println
(
"enable output: "
+
enableOutput
);
String
inputFolder
=
args
[
1
];
String
inputFolder
=
args
[
1
];
String
outputFolder
=
args
[
2
];
String
outputFolder
=
args
[
2
];
String
workload
=
args
[
3
];
String
workload
=
args
[
3
];
...
@@ -25,7 +44,14 @@ public class Runner extends RunnerAbstract {
...
@@ -25,7 +44,14 @@ public class Runner extends RunnerAbstract {
parameter
=
args
[
6
];
parameter
=
args
[
6
];
}
}
run
(
enableOutput
,
true
,
inputFolder
,
outputFolder
,
workload
,
vmAllocationPolicy
,
vmSelectionPolicy
,
new
PlanetLabRunner
(
enableOutput
,
outputToFile
,
inputFolder
,
outputFolder
,
workload
,
vmAllocationPolicy
,
vmSelectionPolicy
,
parameter
);
parameter
);
}
}
...
...
modules/cloudsim-examples/src/main/java/org/cloudbus/cloudsim/examples/power/random/RandomConstants.java
View file @
262b52ea
package
org
.
cloudbus
.
cloudsim
.
examples
.
power
.
random
;
package
org
.
cloudbus
.
cloudsim
.
examples
.
power
.
random
;
/**
/**
* @author Anton Beloglazov
* If you are using any algorithms, policies or workload included in the power package please cite
* @since Dec 17, 2011
* the following paper:
*
* Anton Beloglazov, and Rajkumar Buyya, "Optimal Online Deterministic Algorithms and Adaptive
* Heuristics for Energy and Performance Efficient Dynamic Consolidation of Virtual Machines in
* Cloud Data Centers", Concurrency and Computation: Practice and Experience, ISSN: 1532-0626, Wiley
* Press, New York, USA, 2011, DOI: 10.1002/cpe.1867
*
*
* @author Anton Beloglazov
* @since Jan 5, 2012
*/
*/
public
class
RandomConstants
{
public
class
RandomConstants
{
...
...
modules/cloudsim-examples/src/main/java/org/cloudbus/cloudsim/examples/power/random/RandomHelper.java
View file @
262b52ea
...
@@ -13,7 +13,18 @@ import org.cloudbus.cloudsim.UtilizationModelStochastic;
...
@@ -13,7 +13,18 @@ import org.cloudbus.cloudsim.UtilizationModelStochastic;
import
org.cloudbus.cloudsim.examples.power.Constants
;
import
org.cloudbus.cloudsim.examples.power.Constants
;
/**
/**
* The Class Helper.
* The Helper class for the random workload.
*
* If you are using any algorithms, policies or workload included in the power package please cite
* the following paper:
*
* Anton Beloglazov, and Rajkumar Buyya, "Optimal Online Deterministic Algorithms and Adaptive
* Heuristics for Energy and Performance Efficient Dynamic Consolidation of Virtual Machines in
* Cloud Data Centers", Concurrency and Computation: Practice and Experience, ISSN: 1532-0626, Wiley
* Press, New York, USA, 2011, DOI: 10.1002/cpe.1867
*
* @author Anton Beloglazov
* @since Jan 5, 2012
*/
*/
public
class
RandomHelper
{
public
class
RandomHelper
{
...
...
modules/cloudsim-examples/src/main/java/org/cloudbus/cloudsim/examples/power/random/RandomRunner.java
View file @
262b52ea
...
@@ -8,9 +8,18 @@ import org.cloudbus.cloudsim.examples.power.Helper;
...
@@ -8,9 +8,18 @@ import org.cloudbus.cloudsim.examples.power.Helper;
import
org.cloudbus.cloudsim.examples.power.RunnerAbstract
;
import
org.cloudbus.cloudsim.examples.power.RunnerAbstract
;
/**
/**
* @author Anton Beloglazov
* The example runner for the random workload.
* @since Dec 17, 2011
*
* If you are using any algorithms, policies or workload included in the power package please cite
* the following paper:
*
*
* Anton Beloglazov, and Rajkumar Buyya, "Optimal Online Deterministic Algorithms and Adaptive
* Heuristics for Energy and Performance Efficient Dynamic Consolidation of Virtual Machines in
* Cloud Data Centers", Concurrency and Computation: Practice and Experience, ISSN: 1532-0626, Wiley
* Press, New York, USA, 2011, DOI: 10.1002/cpe.1867
*
* @author Anton Beloglazov
* @since Jan 5, 2012
*/
*/
public
class
RandomRunner
extends
RunnerAbstract
{
public
class
RandomRunner
extends
RunnerAbstract
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment