This project implements a Kubernetes-managed, Django-based architecture designed for task offloading and scheduling across Cloud, Edge, Fog, and IoT clusters. The system is structured to manage IoT devices (acting as pods) and process the tasks they generate, whether they are periodic or dependent (in Directed Acyclic Graphs, DAGs).
-
IoT Cluster:
- Contains multiple pods representing IoT devices such as sensors.
- Each device generates various tasks, which may be periodic or have dependencies (DAG-based).
- A controller unit on each device selects the appropriate node (Edge, Fog, or Cloud) to perform the tasks.
-
Edge Cluster:
- Comprises several edge devices, each containing:
- Task Handler: Handles task input/output and execution.
- Scheduler: Manages task scheduling.
- Offload Control Unit: Manages the offloading of tasks to other nodes.
- Mobility Control Unit: Handles the mobility of devices, managing changes in their location.
- Comprises several edge devices, each containing:
-
Fog Cluster:
- Contains fog devices equipped with:
- Task Handler: Responsible for task execution.
- Offload Control Unit: Manages task offloading.
- Reinforcement Learning (RL) Scheduler: Optimizes task execution and management based on historical performance.
- Contains fog devices equipped with:
-
Cloud Cluster:
- Includes a pod with:
- Task Handler: Executes and manages tasks.
- RL Scheduler: Coordinates resource management and task scheduling.
- Device Registry Unit: Registers and manages both edge and fog devices.
- Includes a pod with:
-
Monitoring Unit:
- The system is equipped with a monitoring unit that tracks key metrics such as:
- Latency
- Energy consumption
- Resource utilization
- All data and task metadata are stored in a central database.
- The system is equipped with a monitoring unit that tracks key metrics such as:
This architecture allows dynamic task allocation, mobility handling, and efficient resource usage across a heterogeneous distributed network of IoT, Edge, Fog, and Cloud layers.
This guide will help you quickly set up and run the project using Python 3.12 in a Linux environment.
- Python 3.12 or higher
- Bash shell
- Kubernetes environment with appropriate clusters (IoT, Edge, Fog, Cloud)
- Docker (for containerized deployments)
- Kubernetes command-line tool (
kubectl
)
-
Clone the repository:
git clone https://github.com/Anonymous0-0paper/MEES.git cd MEES
-
Install dependencies:
Make sure you have Python 3.12 installed. Then, install the required Python packages using:
pip install -r requirements.txt
-
Run setup script:
The provided
bash.sh
script will help set up the environment and deploy the required services../bash.sh
To deploy the architecture on Kubernetes, you need to deploy each cluster (IoT, Edge, Fog, Cloud) with its specific deployment and service configurations. The deployment and service YAML files are located within the respective directories of the clusters (IoT, Edge, Fog, and Cloud).
-
Deployment: Modify and apply the provided
iot-deployment.yaml
file in theIoT
directory.kubectl apply -f IoT/iot-deployment.yaml
-
Service: Deploy the service configuration for IoT devices:
kubectl apply -f IoT/iot-service.yaml
For the Edge
Cluster, navigate to the Edge directory and deploy the relevant files:
-
Deployment:
kubectl apply -f Edge/edge-deployment.yaml
-
Service:
kubectl apply -f Edge/edge-service.yaml
Navigate to the Fog
directory and apply the respective files for the Fog Cluster:
-
Deployment:
kubectl apply -f Fog/fog-deployment.yaml
-
Service:
kubectl apply -f Fog/fog-service.yaml
Finally, navigate to the Cloud
directory and deploy the Cloud Cluster using the following commands:
-
Deployment:
kubectl apply -f Cloud/cloud-deployment.yaml
-
Service:
kubectl apply -f Cloud/cloud-service.yaml
The results of our experiments are available in the Results
directory. Each experiment was conducted with different configurations, showcasing the performance under various setups.
- Experiment Configurations: Configurations are found under:
Results/config-1/
Results/config-2/
Results/config-3/
Results/config-4/
Results/config-5/
To see detailed results, refer to the corresponding PDFs in each folder.
This project is licensed under the MIT License. See the LICENSE file for details.