Skip to content

Latest commit

 

History

History
76 lines (55 loc) · 2.48 KB

File metadata and controls

76 lines (55 loc) · 2.48 KB

CloudSim Scheduling Algorithms

Java CloudSim Algorithms

This project simulates scheduling in a cloud computing environment using CloudSim. Multiple scheduling algorithms are implemented, allowing for flexibility in assigning tasks (cloudlets) to virtual machines (VMs).

Features

  • Implemented scheduling algorithms:
    • Round Robin
    • First-Come-First-Serve (FCFS)
    • Shortest Job First (SJF)
    • Genetic Algorithm
    • Ant Colony Optimization (ACO)

How It Works

  1. Create Datacenter and VMs: A datacenter with a pool of VMs is initialized.
  2. Cloudlets: Multiple cloudlets (tasks) are created, each representing a unit of workload.
  3. Scheduling: The user can select an algorithm to schedule cloudlets to VMs.
  4. Algorithms: Based on the selected algorithm, the cloudlets are assigned to VMs in an optimized manner.
  5. Simulation: The CloudSim engine runs the simulation and outputs the scheduling results.

Algorithms Usage

Enter the algorithm to be used: (roundrobin, fcfs, ant, genetic, sjf): genetic

Choose any of the following algorithms:

  • roundrobin: Round-robin scheduling.
  • fcfs: First-Come-First-Serve scheduling.
  • ant: Ant Colony Optimization scheduling.
  • genetic: Genetic Algorithm-based scheduling.
  • sjf: Shortest Job First scheduling.

Requirements

  • Java 8 or higher
  • CloudSim library

Setup

  1. Clone the repository:
    git clone https://github.com/Ravikisha/CloudSim-Examples.git
  2. Add the CloudSim library to your project.
  3. Compile and run the project:
    javac CloudSimDemo.java
    java CloudSimDemo

Example Output

========== OUTPUT ==========
CloudletID     STATUS    DataCenterID   VM ID    Time      StartTime       FinishTime
0              SUCCESS   0              1        10.0      0.5            10.5
1              SUCCESS   0              0        8.5       1.0            9.5

License

This project is licensed under the MIT License. See the LICENSE file for details.

Contributing

Feel free to fork this project, create issues, and make pull requests to contribute!


Happy Scheduling with CloudSim! 🚀