Improved Jellyfish Algorithm-based multi-aspect task scheduling model for IoT tasks over fog integrated cloud environment

Corporations and enterprises creating IoT-based systems frequently use fog computing integrated with cloud computing to harness the benefits offered by both. These computing paradigms use virtualization and a pay-as-you-go strategy to provide IT resources, including CPU, memory, network and storage. Resource management in such a hybrid environment becomes a challenging task. This problem is exacerbated in the IoT environment, as it generates deadline-driven and heterogeneous data demanding real-time processing. This work proposes an efficient two-step scheduling algorithm comprising a Bi-factor classification task phase based on deadline and priority and a scheduling phase using an enhanced artificial Jellyfish Search Optimizer (JS) proposed as an Improved Jellyfish Algorithm (IJFA). The model considers a variety of cloud and fog resource parameters, including speed, capacity, task size, number of tasks, and number of virtual machines for resource provisioning in a fog integrated cloud environment. The model has been tested for the real-time task scenario with the number of tasks considering both the smaller workload and the relatively higher workload scenario matching the real-time situation. The model addresses the Quality of Service (QoS) parameters of minimizing the batch’s make-span time, lowering the batch execution costs, and increasing the resource utilization. Simulation results prove the effectiveness of the proposed model.


Introduction
In recent decades, the scientific community has embraced meta-heuristic optimization approaches to solve complicated optimization problems. Neural networks, data mining, industrial, mechanical, electrical, software engineering, and specific issues in location theory are some of the application domains of meta-heuristic algorithms [1][2][3][4][5]. Hussain's analysis of 1,222 papers on metaheuristics from 1983 to 2016 (33 years) suggests that the behaviour of birds, humans, plants, water, the ecosystem, electromagnetic forces, and gravitation have been employed as metaphors in metaheuristic techniques [6]. Figure 1 presents a division of these techniques into two groups. The first group includes approaches that imitate biological or physical events and can be divided into four sub-categories: Nature-based, Physics-based, Humanbased and Swarm-based methods. The third group consists of those that have been motivated by human events. The most exciting and widely used metaheuristic algorithms are swarm-intelligence algorithms based on the collective intelligence of colonies of ants, termites, bees, flocks of birds, and so on [7]. Their success can be attributed to the fact that they leverage shared knowledge among several agents, allowing self-organization, co-evolution and learning to aid in creating high-quality products during cycles. Although not all swarm-intelligence algorithms succeed, a handful has been quite effective Page 2 of 21 Jangu and Raza Journal of Cloud Computing (2022) 11:98 and have thus become popular tools for tackling realworld problems [8]. Working in the same trend, cloud computing research has also leveraged the benefits of many meta-heuristics to target its' complex problems, e.g., virtual machine allocation [9][10][11], virtual machine placement [12,13], load balancing [14], task scheduling [15][16][17][18][19][20][21][22][23][24][25][26][27], workload prediction [28], resource allocation [29,30], workflow scheduling [31,32], virtual machine migration [33] and many more.
Computing paradigms like cloud and related technologies, fog and edge computing are built on the payas-you-go model. Resources are provided based on the service-level agreements (SLA) between the service providers and the consumers. Resources are of utmost importance for these technologies. Accordingly, resource provisioning for task scheduling becomes one of the significant concerns for these paradigms alongwith other challenges like security, performance, resource management, reliability etc. Therefore, to achieve an efficient performance and to make the best use of the scarce fog or cloud resources, the users' tasks must be scheduled intelligently on the available resources while meeting the desired QoS. There are numerous factors to be considered for designing any task-scheduling algorithm. Some of critical factors are task completion time, makespan, security, and response time from a user's standpoint. From the service provider's Provider's standpoint, the crucial parameters considered are resource utilization, fault tolerance, and power consumption to name a few.
Owing to the large solution space and time required to obtain an optimal solution, job scheduling, also known as  11:98 resource provisioning for the cloud and peers, has been classed as NP-hard [34]. Optimization methodologies using meta-heuristic methods based on performance factors, e.g., completion time, cost, resource utilization offer a solution to address the resource provisioning problem. Although cloud computing meets the criteria of executing IoT operations locally, it impacts task performance and requires a platform to handle these tasks. Furthermore, IoT applications conduct various tasks with varying priorities and deadlines that must be performed without delay. Still, remote execution of these tasks in the cloud server creates multiple issues, including higher latency and limited bandwidth availability. These challenges can be overcome by processing IoT tasks at the network's edge, called fog computing [35]. The goal of fog computing is to complete work before the deadline with local workload execution. The hybrid fog-cloud architecture offers a promising arrangement to improve the QoS with a broaded horizon. The fog layer assists the cloud layer in the task execution. Some appropriate tasks are executed at the fog level, with the remainder of the workload offloading to the cloud. Scheduling tasks in the fogcloud layers promise to achieve reduced make-span time in executing these tasks with a better resource utilization. Looking at the immense benefits of using meta-heuristics in computing literature, this study proposes an Improved Jellyfish algorithm (IJFA) model for scheduling classified tasks over the Fog integrated cloud environment. The work considers the tasks originating from the Internet of Things (IoT) devices, resulting in a heterogeneous task generation. The model uses a bi-factor classification method based on task category considering the priority and deadline, and the resource requirements aiming to minimize the make-span time of the batch of jobs. This, in turn, will lower the execution cost of tasks submitted for execution while improving the overall resource efficiency and utilization.
The proposed algorithm IJFA is based on a recently developed population-based nature-inspired meta-heuristic algorithm, an artificial Jellyfish Search Optimizer (JS), inspired by the behaviour of Jellyfish in the ocean. The simulation of jellyfish search behaviour includes their following of the ocean current, their motion within a jellyfish swarm as active and passive motions, a temporal control system for switching between these movements, and their convergence into a jellyfish bloom. On benchmark functions and optimization problems, the new approach performes admirably. The population size and the number of iterations are the only two control parameters in JS. As a result, it requires minimum effors in deployment and could be an excellent meta-heuristic algorithm for addressing optimization problems. This work modifies the the JS algorithm in order to to achieve faster convergence by improving its exploration phase resulting in a wider exploration of the solution space to attain efficient scheduling decisions [36].
The remaining section of this research is systematized as follows. Literature survey section provides the literature survey of the various works reported in the literature in the domain. The proposed multi-aspect task scheduling approach section details the proposed model including Improved Jellyfish algorithm (IJFA) based on task scheduling principles. Experimental results section discusses the simulation setup, simulation results and a performance evaluation of the proposed model. Conclusion and future works section 5 presents the conclusion drawn from the work and possible future directions.

Literature survey
Cloud computing is the most popular distributed computing paradigm that provides self-service, dynamically scaled and metered access to a shared pool of resources with guaranteed Quality of Service (QoS) to the users. The jobs must be efficiently mapped to the offered resources to achieve QoS. Otherwise, it may violate Service Level Agreements (SLA). As a result, users will be hesitant to pay if the desired performance is not realized. Therefore, cloud computing systems consider scheduling a significant theme, where obtaining a subpar solution in a short period is desirable. No algorithms can solve the scheduling issue in polynomial time and provide optimal results owing to the vast search space in the actual implementation of the computing world. Therefore, combining meta-heuristic algorithms with the optimization of essential parameters reduces search space complexity and execution time. Also, the goal of task scheduling changes from one application to the next according to the QoS standard requirements. As a result, numerous studies in cloud and fog computing focus on metaheuristics-based job scheduling. This section provides a comprehensive review of several scheduling techniques using various metaheuristics in the realm of cloud and fog computing.

Meta-heuristics in cloud computing
When implementing a task scheduling approach, at least one objective function ensures high performance. The most prevalent objectives are make-span, monetary cost, computational cost (i.e., CPU, memory, storage, GPU, bandwidth, etc.), reliability and availability, elasticity or scalability, energy consumption, security, resource usage, and throughput [37]. Researchers have explored these single-objective and multiobjective areas interestingly using various metaheuristics.
In [38], the authors introduced a new single objective strategy based on the Firefly algorithm for scheduling  [39], the authors proposed a hybrid method that combines the benefits of Ant Colony Optimization (ACO) and Cuckoo search that tries to lower the makespan or completion time. The work achieved this objective using the hybrid algorithm because the jobs were completed by allocating sufficient resources inside the set time interval. The findings suggest that the Hybrid algorithm outperforms the ACO method in terms of algorithm performance and time to completion. An improved ant colony algorithm for multiobjective optimization scheduling based on a resource cost model (relationship between the user's resource costs and the budget costs) was reported in [40]. The model achieved multiobjective performance and price optimization by including the make-span and the user's budget costs as optimization constraints. Their multiobjective optimization method performed better than similar methods based on the make-span, cost, deadline violation rate and resource utilization. Using the benefits like the speed and accuracy of the PSO algorithm, the authors in [41] proposed a comprehensive multiobjective model to give better QoS to Cloud customers by reducing the task execution/transferring time and cost. The authors tried to achieve it by moving extra tasks from an overloaded VM rather than migrating the complete overload and eliminating the use of the VM pre-copy process. The simulation results reveal that the suggested method dramatically decreases the load balancing time compared to standard load balancing methodologies.
Similarly, research in [42] proposes a PSO-based Adaptive Multiobjective Task Scheduling (AMTS) strategy that considers both processing and transmission time and produces a better quasi-optimal solution in terms of average cost, job completion time and energy consumption, according to experimental results. The work reported using an adaptive acceleration coefficient to preserve particle diversity. Following the same trend, [43] also sed a load-balanced scheduling strategy based on the New Particle Swarm Optimization (NPSO) method. A new cost assessment function was employed to reduce the monetary cost of processing tasks on VMs. The suggested method improves efficiency through cost optimization (minimized cost) based on a statistical analysis of the total cost (execution and transfer) on a data set with many iterations and particles.
To build a complete multiobjective optimization model for task scheduling, the authors in [44] included four conflicting objectives: task transfer time, task execution cost, power consumption, and task queue length to lower expenses for customers and providers. Using the Multiobjective Particle Swarm Optimization (MOPSO) and Multiobjective Genetic Algorithm (MOGA), their proposed multiobjective model achieves optimal trade-off solutions among the four conflicting objectives, reducing job response time and make-span significantly. Findings say that the proposed model is faster and more accurate, improving QoS and lowering provider costs. Authors in [45] introduced a novel Multi-objective Cuckoo Search Optimization (MOCSO) technique for dealing with the resource scheduling problem in cloud computing to lower cloud user costs and improve performance by reducing make-span time. This helps cloud providers earn revenue or profit by maximizing utilization. The investigations and evaluation of the proposed method show that it outperforms MOACO, MOGA, MOMM, and MOPSO in balancing numerous objectives such as projected time to completion and cost. [46] proposed an ACO, PSO, and GA-based task-level and service-level dynamic resource scheduling technique, in which a task is assigned to a VM and a task is assigned to a service, respectively. This solution optimizes the make-span and CPU time while also lowering the overall operational cost of data centres. Still, the model does not perform well when allocating resources to global tasks. Table 1 summarises some of the recent single objective and multiobjective meta-heuristic algorithms employed in the cloud to address various QoS parameters.

Meta-heuristics in fog integrated cloud computing
Taking inspiration from the usage of metaheuristics in fellow cloud computing, researchers have explored the aspect of task scheduling using the same in fog computing and fog integrated cloud environments. In the work [47], the authors offered an energy-saving method based on a meta-heuristic known as the Harris Hawks optimization technique to increase QoS while main- taining SLA. The proposed algorithm is based on the fact that task scheduling is essential and adds to fog servers' energy usage when managing Industrial IoT (IIOT) applications. It reportedly beats other known algorithms such as Particle Swarm Optimization (PSO) and Teaching Learning Based Optimization (TLBO) while considering the performance in terms of energy consumption and other QoS factors. In [48], the authors introduced an Adaptive Double fitness Genetic Task Scheduling (ADGTS) algorithm to maximize task make-span and communication cost at the same time using collaborative task and fog resource scheduling. Simulation results suggest that the ADGTS algorithm can simultaneously balance communication cost and task make-span performance. It performs better considering task make-span than the Min-Min method. Authors in [49] proposed a task scheduling algorithm based on a Moth-Flame Optimization (TS-MFO) algorithm. The proposed technique assigns an appropriate set of tasks to fog nodes to meet the quality-of-service criteria of Cyber-Physical Systems (CPS) applications while minimizing task execution time. The simulation study suggests the outperformance of the model over the PSO, NSGA-II, and (Bees Life Algorithm) BLA techniques in terms of total task execution time. The authors in [50], provides an optimization technique for IoT based applications using modified version of genetic algorithms with a focus on reducing latencies. On the other hand, few works tried to explore multiobjective scenarios. In one such work [51], the authors tried to improve the QoS supplied to users in (Industrial IoT) IIoT applications to propose an energy-aware meta-heuristic based on a Harris Hawks Optimisation algorithm based on a Local search Strategy (HHOLS) for Task Scheduling in Fog Computing (TSFC) aided by the normalizing and scaling phase in solving the discrete TSFC. The quality of the solution was improved even more by balancing workloads across all virtual machines due to the swap mutation. The work compared their HHOLS method with other meta-heuristics based on various performance indicators, such as energy consumption, make-span, cost, flow time, and emission rate of CO 2. Using the same meta-heuristic, the authors in [52] proposed an enhanced elitism genetic algorithm (IEGA) to solve the work scheduling problem for FC and increase the quality of services provided to IoT device consumers. The proposed method demonstrates superior performance in make-span, flow time, fitness function, carbon dioxide emission rate, and energy consumption compared to other peers. The benefits of IEGA come from two main phases: first, the mutation rate and the crossover rate being manipulated to aid the algorithms in exploring the majority of the possible combinations that could form the near-optimal permutation; and second, several solutions being mutated based on a certain probability to avoid becoming trapped in local minima and to find a better solution.
Another work reported in [53] demonstrates a novel scheduling method based on the ant colony algorithm allowing for more accurate job scheduling and execution. It is a three-step method in which tasks are separated into two groups based on their completion time and cost, followed by prioritization based on completion time and cost. Then, the ant colony method is utilized to choose the best virtual computer to run the jobs. Simulation results suggest that the proposed method provides acceptable performance in make-span, response time, and energy usage compared to others. The work in [54] presents a Novel Bio-Inspired Hybrid Algorithm (NBIHA), a mix of Modified Particle Swarm  [55], the authors proposed a Priority-aware Genetic Algorithm (PGA) which is a hybrid technique combining task prioritization with a genetic algorithm implementation. The objective is to determine the best compute node for each task by considering various job requirements while considering the diverse nature of fog and cloud nodes. It is a novel fog-cloud scheduling algorithm that optimizes a multiobjective function, a weighted sum of overall computation time, energy consumption, and Percentage of Deadline Satisfied Tasks (PDST). The work [56] introduced a Discrete Non-Dominated Sorting Genetic Algorithm II (DNSGA-II) based optimization model to schedule tasks dynamically aiming to reduce the makespan and costs in a fog-cloud environment. The model deals with the discrete multiobjective scheduling problem, allocates computing resources either on cloud or fog nodes and organizes the distribution of workloads. Another work in [57] attempts to reduce the makespan and energy consumption in the fog-cloud environment by using an integration of the Cultural Evolution Algorithm (CEA) and the Invasive Weed Optimization (IWO) named as hybrid (IWO-CA). The Dynamic Voltage and Frequency Scaling (DVFS) technique is presented to minimize the consumption of energy. Whale Optimization algorithm in smart healthcare application has been explored in [58] to address the massive data generated in the process aiming to minimize the average energy consumption and cost. Table 2 summarises some of the recent single objective and multiobjective meta-heuristic algorithms used in fog environment for addressing various QoS parameters.

Motivation and objective
Literature survey reveals that owing to the NP class nature of the scheduling problem, the work done considering both single-objective and multiobjective problems addressed the scheduling problem in different ways while proposing or utilizing a variety of well-known metaheuristics. However, many of them ignored the need of classifying heterogeneous end-user requests. The present study takes into account the importance of task categorization and is based on the novel approach JS (Jel-lyFish Search Optimiser) [36]. JS has proven to be better than peers e.g.   11:98 decisions for the heterogeneous IoT tasks. Further, the classification of jobs in the batch before making scheduling decisions results in a model suitable for real time and deadline aware tasks.
The proposed multi-aspect task scheduling approach The system's design, problem statement, suggested model and algorithm, simulation setup, and evaluation procedures are all presented in this section. To ensure the effective success of the objectives and aims, the research methodology is built over similar works in the domain of classification of tasks of IoT and its' scheduling employing metaheuristics.

Methodology design
The work aims to schedule the jobs in the fog integrated cloud environment to minimize the make-span time for the jobs. The main research challenge identified is scheduling the requests from various IoT devices with heterogeneous demands in large volumes seeking different QoS needs. The ample search space makes scheduling these requests an even more complicated task. Several previous works and studies have been examined to discover competent qualities that may be utilized to classify and schedule requests. Classification is essential before scheduling for two main reasons: first, the requests are heterogeneous and second, to make use of the integrated environment of cloud and fog layers working with different capabilities and purposes. Fog layer aids real-time processing, necessitating ultra-low latency, location awareness, edge resource pooling, mobility, and most importantly preventing cloud server overloading. It's also helpful in places where connectivity is inconsistent. On the other hand, cloud is more centralized and powerful than fog exhibiting features like availability, computing capabilities and storage capacity. It also aids in the longterm storage of data used for analysis and decision-making. Figure 2 presents the fog integrated cloud system architecture.
All user demands are first submitted to a broker or a gateway with respective parameter values. The centralized broker, which is also a centralized decision-maker, is an intermediate party between the users and the providers and draws its inspiration from the broker used in [59]. The role of the broker is to manage the fog-cloud resource provisioning upon the user requests. It has the same role as a cloud broker, described as "an entity that manages the use, performance and delivery of cloud services, and negotiates relationships between cloud providers and consumers" [60]. The centralized broker records dynamically changing and uncertain resources from multiple fog and cloud providers along with the various IoT devices generating heterogeneous requests. Therefore, it minimizes the complexity arising out of many request handlers by providing a single point solution in the fog integrated Cloud environment. Once the broker recevices the requests, first, the bi-factor classification algorithm categorizes it based on the deadline and the priority. Next, these tasks are scheduled using the Improved Jellyfish algorithm (IJFA) based on the task category of the requests and their resource requirement to fog nodes or cloud nodes accordingly.
The most important properties of the requests coming from IoT devices are their deadline and priority, which can be used to classify them and then schedule them accordingly. For this purpose, this work proposes a bifactor classification algorithm to ascertain the task category. The work proposes an Improved Jellyfish Algorithm (IJFA) strengthening the exploration properties of JS algorithm. JS is chosen for improvement as it is a promising meta-heuristic because of its simplicity and the use of only two control parameters, i.e., population size and the number of iterations. Figure 3 presents the workflow of the proposed model.

Problem statement
The IoT devices in the given environment produce data required to be processed for various applications for which it has been deployed. The computationally constrained nature of IoT devices makes it necessary for the devices to offload the data to other computing nodes for processing. In the proposed fog integrated cloud environment, the node assigned with a task and performing computation might be the fog node controlling the network of that geographical location or the cloud node present in a remote location. These nodes consider the processing of data as a task. Each task will be assigned either to a fog node or a cloud node executed as a virtual machine. The VM configuration can be the same if the tasks are of the same type or different depending on the task types. The tasks to for which computation is required can be denoted as, where T k is the number of tasks submitted by the IoT devices. T i represents the i th task in the task sequence. These tasks are later clubbed together to form a batch of tasks to be executed as per the QoS requirements. For every task a suitable fog or cloud node is decided for allocation. As with many scheduling approaches, the proposed also aims to minimize the makespan of the tasks submitted by the IoT devices. Each task T i possesses some features which can be formulated as, Here,T ID i is the task identifier, T TL i the job length (unit: million instructions), T p i the priority level, and T dl i deadline of execution of any given task T i . The nodes which process the tasks can be a fog node ND f , represented as or a node ND c in the cloud data center denoted as, Each node N j and N r possesses certain features as defined in Eqs. 5

and 6 as
Here, N id j and N id r denote the identification or the serial number of a node at the fog layer or the cloud layer, N MIPS j and N MIPS r the information processing speed of nodes (unit: millions-of-instructions-per-second, MIPS), N m j and N m r the memory availability and N ds j and N ds r the disk space availability corresponding to nodes N j and N r respectively. The allocation of a task T i to node N j or N r obeys certain conditions which are expressed as follows, Here, A ij is the allocation vector representing the placement of task T i on node N j . The above equations describe that the allocation of tasks will be carried out only if the resource availability of the node is greater than the resource requirements of the task. The Expect Complete Time (ECT) matrix of size [ N k * N n ] represents the expected execution time to run the task individually on each computing resource of the fog layer resources as, Similarly, the matrix of size [ N k * N m ] represents the expected execution time to run the tasks on each computing resource (VM) of cloud resources individually as, One of the aims of the proposed model while making a scheduling decision is to minimize the make-span by locating the most efficient group of tasks on virtual machines. ECT ij for the same can be computed as, where ECT ij refers to the required execution time of i th task on j th virtual machine of fog layer, TL(T i ) is the task-length of the i th task. Similarly, ECT ir refers to the expected execution time of i th task on r th VM in the cloud layer represented as Eq. 13.
The fitness value indicating the suitability of a node for a task can be defined as: The proposed model aims to optimize the task's execution time and improve the utilization of resources, thereby achieving the required QoS in terms of completion time. The primary objectives for the same can be summarised as, where, Ru is the resource utilization, QoS the Quality Of Service to be met and E T the execution time of the tasks/ batch of tasks scheduled in the considered computing environment.

Bi-factor task classification
The tasks originating from the IoT devices are aggregated by the Broker/Gateway which classifies tasks and performs scheduling. The incoming tasks possess various priorities and deadlines that should be considered to effectively categorize the tasks. The classification of tasks is performed to analyze the tasks in order to achieve an increased completion rate. The threshold values for priority and deadline of a task can be computed as, Here, H T p i and H T dl i are the thresholds corresponding to priority and task execution deadline respectively. Further, T p i is the priority value and T dl i is the deadline requirement of the task T i with the threshold value ranging from 0 to 1. The priority and deadline are classified into two classes, namely low and high, and can be formulated as, fit = max ECT ij ∀i ∈ 1, k mapped to jth VM, j = 1,2, … n  Table 3 presents the task classification based on task priority and the deadline. The classification of tasks is carried out into four major classes: highly intense, intense, moderate, and low, based on the priority and deadline of the tasks. These categorized tasks are then scheduled using the proposed model to meet the desired QoS.

Multi-aspect task scheduling
The scheduling of categorized tasks is performed by the Broker to achieve robust computation of tasks. The factors considered for effective scheduling of tasks are task category T C i , and resource requirement . This work proposes Improved Jellyfish Algorithm (IJFA) to explore the search space for aa better solution for scheduling of tasks with an increased convergence rate. As mentioned earlier, IJFA aims to improve the search space exploration as compared to JS while reducing the convergence time. To computationally realize the same, initially, the Jellyfish vectors are initialized as, where, − → K 0 denotes the initial vector of the Jellyfish, and − → K J is the vector that holds the chaotic values of J th Jellyfish. η is aconstant which is taken as four in the proposed approach. Once the initialization is over, the selection of solution based on Ft is performed to select the location with maximum food − → K * . Following it, the time control mechanism is utilized to switch between the motions of Jellyfish either towards ocean current or inside the swarms. The motion towards the ocean current can be formulated as, Here, ��� ⃗ rn, rn 1 represents a random number in the range of 0 to 1, β the distribution coefficient and µ is the population mean. The motion of Jellyfish inside the swarm is emulated in two ways using action motion and passive motion. The determination of a new location using passive motion can be computed as, Here, γ is a constant representing the motion length, rn 3 a random number in the range of 0 to 1, up b the upper bound of search space and lw b the lower bound of the search space. The determination of a new location using active motion can be computed as,

Here,
− → Dr denotes the motion direction of the Jellyfish to locate the best food and can be expressed as, In the above equation, l represents the jellyfish index that is selected randomly. The control function ϑ(t) for switching of motion of Jellyfish can be written as, If the value of ϑ(t) is greater than or equal to the constant ϑ 0, the Jellyfish follows the ocean current. Otherwise, the Jellyfish tends to move inside the swarm. If the randomly generated number rn 4 is greater than 1 − ϑ(t) then the Jellyfish moves in a passive motion else it moves in an active motion. Improving JS, the enhancement is in the exploration capabilities of IJFA which prevents premature convergence. IJFA aims to achieving faster convergence while reducing the search time. This can be accomplished by using the randomization concept in investigating the swarm's locations. Initially, the population, as usual is random to have diversity. Later on, it exploits some local optimum, but the introduced randomness also avoids premature convergence. The new formulation can be written as, The improved algorithm selects three random solutions from the population and updates each population accordingly to ensure a fast convergence rate. Further, it has a higher chance of moving towards global optimum. (26) Figure 4 presents the proposed multi-aspect task scheduling using IJFA, which runs at the broker site. The user requests from various IoT devices are submitted and categorized using the bi-classification algorithm and then forwarded to the scheduler. Based on task requirement and category, the scheduler then schedules a task on the fog or cloud layer after initializing the algorithm's parameters and computing and evaluating the fitness of the tasks. The time control mechanism governs the switching between the two types of movement of Jellyfish moving in the ocean in search of food. They are more attracted to locations where the available quantity of food is more significant. The location and corresponding objective function determine the amount of food found.
The pseudocode of the IJFA based task scheduling process is presented in the box below, scheduling of tasks based on task category and resource requirements.

Experimental results
This section presents the simulation framework and the experimental result analysis of the proposed model featuring a multi-aspect task scheduler using the Improved Jelly Fish Algorithm (IJFA) for the fog integrated cloud environment. The scheduler uses IJFA to optimize the scheduling of IoT tasks based on the task's priority, deadline and resource requirements. The requests are classified based on deadline and priority and then accordingly scheduled on either the fog or the cloud layer.

Simulation environment
Experimenting on real-world data in a real-world cloud environment is costly and complicated. Furthermore, if the experiment does not go as intended, crucial data may be lost. As a result, a simulator that can simulate the realworld cloud environment is necessary to test and validate various strategies and procedures presented for the benefit of the stakeholders. Once approved, these strategies and mechanisms can be used in a real-world context without the risk of data loss.
The classification before scheduling across the data center is essential in IoT tasks due to its effectiveness in managing the execution by executing real-time requests with high priority within their deadline. This work uses a Bi-factor classification algorithm to classify requests before scheduling them to address the concern. The experimental parameters are based on previous literature work reported in the literature for cloud and fog based resource provisioning.
The experiments were conducted by simulating a hybrid fog-cloud environment and heterogeneous task transfer. Table 4 summarises the simulation attributes used in the work. For effective simulation, MATLAB toolbox named Distributed System is utilized. This toolbox can be used to emulate any distributed network including fog integrated cloud environment. All experiments were executed for twenty different runs, including 3000 iterations for optimization.
The different batch sizes of Real-Time (RT) and Non-Real Time (NRT) requests were randomly generated and submitted. The distribution of VMs for fog and cloud nodes was kept at 30% and 70%, respectively. In each simulation, VMs, cloud and fog nodes were randomly generated with different processing capacities and configurations within the range in accordance with Table 5 as presented in the coming section.

Experimental setting
The proposed work used MATLAB to realize the fog integrated cloud environment. The experiments were designed to use five batches comprising of 600, 1200,1800, 2400 and 3000 tasks respectively. The different dataset sizes allow for more complicated task transfer scheduling testing. As the dataset size grows larger, the scheduling difficulty becomes more difficult, thus ensuring rigorous testing of the model under a real fog-cloud like workload. Each task is represented by four parameters: task ID, task size, task deadline, and the task's priority. Task ID is a unique transfer identifier while job size provides an estimate of the computational execution time. Expected Completion Time (ECT) is used as the parameter to compare the performance of both JS and IJFA. In the computing environment, the dataset placement has been evaluated for three different scenarios: (1) allocating the dataset for execution directly on the cloud, (2) allocating the dataset for execution directly on the fog, (3) allocating the dataset for execution across fog  integrated cloud architecture using classification being the main focus of this work.

Experimental results and analysis
Experiments using meta-heuristic scheduling algorithms, JS and the proposed IJFA were conducted in the fog-cloud environment. The findings of the experimentation are presented in this section. The simulation's goal is to calculate the make-span of these two metaheuristic scheduling methods being tested. The ideal meta-heuristic scheduling method is believed to be the one with the shortest make-span. Different test scenarios are used to calculate the performance of these two based on the ECT matrix to ensure the VMs' balanced workload. In the proposed model, the task scheduling phase is proceeded by the bi-factor classification phase, which improves the overall performance by characterizing user tasks based on the priority and the deadline. Accordingly, the incoming tasks in the batch of jobs are classified into highly intensive, intensive, moderately intensive, and less intensive based on the priority and deadline. These two parameters enable the deadline sensitive and essential tasks to be scheduled at the fog layer, decreasing latency and time delay. These categorized tasks are then considered for scheduling, aiming to achieve better makespan.

Scenario 1: batch size variation from 600 to 3000 tasks with a fixed number of iterations as 3000
In this case, five different batches of tasks comprising tasks varying in the range 600-3000 were scheduled using JS and IJFA executed over 100 VMs run over 3000 iterations. Figure 5a-e presents the Expected Completion Time (ECT) of an optimized schedule for all the five batches of tasks having 600, 1200, 1800, 2400 and 3000 tasks, respectively based on JS and IJFA algorithms through the convergence curves. As discussed in The proposed multi-aspect task scheduling approach section, the tasks are classified into four categories, i.e., highly intensive, intensive, moderately intensive and low intensive, based on deadline and priority using a biclassification algorithm. These are then offloaded to the cloud and fog layer of the hybrid architecture based on their category. In the proposed model, on average, almost half of the requests generated in different trials are getting served by the fog, which directly improves the system's total performance. The scheduler then, using JS and IJFA, allocates requests on available fog nodes by calculating the expected time of completion of each request of the batch and selects the one with minimum time among the available nodes at the respective layer where they have been offloaded to ensure a balanced workload for VMs. An average ECT scorewas computed for virtual machines at cloud and fog layers using the JS algorithm. From Fig. 5a-e, it is observed that The IJFA can converge to a better solution with a better convergence rate in all the cases, from smaller batches of tasks to bigger ones. The better convergence of IJFA can be attributed to its better exploration capability to achieve faster convergence by reducing the search time than the traditional JS. This was made possible in IJFA by exploring search locations or solutions which other members could not have previously explored by randomly picking any three solutions from the population and updating the population accordingly. Table 5 summarises the optimized ECT based on the various experiment scenarios. The results were obtained for every set of tasks for three different runs. The average best and average worst performance in ECT reported by JS and IJFA were observed. The results based on these three random trials over different task sets indicate that the optimized ECT observed in the model using the proposed IJFA is way lesser than the one obtained with JS as a trend due to efficient task scheduling based on multiple aspects by IJFA including bi-classification. The IJFA has faster convergence due to the improvement in the exploration phase and achieves the trade-off between exploration and exploitation with less time consumption due to implementing a two-directional search strategy resulting in better solutions. For instance, in the experiment with 600 batches of tasks, the optimized ECT for IJFA is about 13 s in the average best scenario, which is better than the average best of 17 s reported by JS. As far as the average worst scenario is concerned for both JS and IJFA, it is observed that IJFA is performing at par with JS. The same trend can be seen in all the different batches of jobs. It can be concluded that IJFA outperforms JS easily when used in the fog integrated cloud environment with randomly generated and scheduled heterogeneous tasks.
The ECT of JS and IJFA implementations for various task sets spread over 20 iterations is presented in Fig. 6ae. A boxplot performance for all five batches of jobs has been given. It is observed that the median of IJFA is less than JS in all the cases. For instance, the median for batch I (600 tasks 100 VMs) is 75 s for IJFA and 95 s for traditional JS. Also, the ECT for IJFA and JS has been dispersed over 167 s to 13 s and 186 s to 17 s, respectively. The same trend has been observed in all the other four batches of jobs, too, where range dispersion and median of IJFA are less than JS. The box plots reflects that IJFA performs an efficient task scheduling compared to JS, irrespective of the task set sizes. The result remains the same even with the change in the number of VMs. The same has not been reproduced here to avoid redundancy.
The performance of the proposed IJFA algorithm and traditional JS has also been evaluated by feeding a different number of tasks ranging from 600 to 4800to observe a general trend of the performance of the two algorithms. The same has been presented in Fig. 7. This is significant because a wide range of data sizes could be used to support the task transfer scheduling's sophisticated testing. As the data size grows larger, the scheduling becomes more difficult but still IJFA performes very well as compared to traditional JS. It is worth mentioning that the performance of IJFA becomes even superior with the increasing task set size which corresponding with the fog integrated cloud environment. As the size of the batch increases, the difference in ECT reported by both  the algorithms also increases. The increased difference between the two concluded that IJFA is more suitable in the situation with large size datasets, which is very appropriate in the real-world scenarios especially considering IoT devices as the task generators.

Scenario 2: performance evaluation of IJFA using Fog Integrated Cloud, Cloud-Only and Fog-Only Scheduling architectures
To understand the usefulness of fog-integrated cloud architecture over cloud-only and fog-only architectures, JS and the proposed algorithm IJFA was applied to work in three scenarios for the above mentioned three architectures. To realize the same, five batches of tasks with batch sizes ranging from 600 to 3000 were made, which were later scheduled on the above three architectures separately. Accordingly, batches were made with batch I comprising 600 tasks, batch II comprising 1200 tasks till batch V comprising 3000 tasks. A comparative analysis of the minimized makes-span trend for this study has been presented in Table 6 and a bar chart representation is depicted in Fig. 8a-c. The ECT observed in both the cases of using JS and IJFA clearly outlines the outperformance of IJFA over JS for all the batch sizes over randomly generated datasets. Table 7 summarises the results obtained using IJFA as the scheduling strategy with the results in terms of ECT for varying batch sizes for the fog-only, cloud-only and the fog integrated cloud architectures. These results have been presented pictorially in Fig. 9. It is observed that the low-capacity nodes at the fog layer led to maximum ECT in all the used five batches of jobs followed by cloud-only architecture. For instance, ECT for the batch I dataset came out to be approximately 13 s, 31 s and 321 s for fog integrated cloud, cloud-only and fog-only architectures The same trend can be seen for the remaining batches too. Therefore, it is established that the proposed IJFA algorithm performs very well in the hybrid fog-cloud environment owing to the classification of jobs prior to actual scheduling, which led to offloading of high priority and time-sensitive requests to the fog nodes and rest to the cloud nodes. As per the analysis of the random generation of requests in different trials, almost 50% of jobs were executed at the fog layer, resulting in a low ECT in the hybrid environment. In all the cases, if all the tasks were offloaded to the fog layer, it resulted in the maximum ECT as the number of fog devices is limited and computationally constrained as compared to cloud-only and fog integrated cloud architecture. The study infers that it is best to have an integration of fog nodes and cloud nodes contributing to schedule based on the task preferences to achieve better performance.
This section studies the experimental results of the proposed model to optimize the execution of IoT tasks in the fog integrated cloud architecture. The effect of the batches of data on the performance was analyzed to study the results under various scenarios. It is gathered from the experimental results that the optimization of tasks in fog-only and cloud-only architecture faced challenges in scheduling as they did not classify and categorized the tasks based on their requirements and nature. This led to an increased ECT in both the scenarios. Also, with an increased number of tasks, the complexity of job scheduling increases, leading to delays in response and in the worst case request failures. The integration of classification of jobs with IJFA results in an efficient ECT reduction of the batch of jobs under numerous testing cases. Compared to using solely standard JS algorithm, the proposed model comprising of two-phase scheduling algorithm allows for adequate optimization time. The bi-classification phase helps in characterizing the IoT requests based on the deadline and the priority to schedule the tasks using IJFA on the available computing resources. These available resources can be either at the cloud layer or fog layer with their selection ensuring an optimal use of both for an efficient job execution. Therefore, this work gains significance as it addresses the efficient resource provisioning in the fog-ingrated cloud environment for the heterogeneous and delay sensitive IoT tasks to reduce the execution time leading to a decreased cost of execution for the batch of jobs.

Conclusion and future works
The Internet of Things (IoT) has emerged as a prominent technology in automation by performing real-time tasks for various applications with different priorities and deadlines. An integrated fog-cloud architecture offers the remote execution of these tasks with an improved latency and better availability of bandwidth. However, it is important to have a suitable resource provisioning scheme for task offloading to fog and cloud resources while meeting the task and resource requirements. This work proposes a multi-aspect task scheduling algorithm based on Improved Jellyfish Algorithm (IJFA) by leveraging the benefits of the integrated environment of fogcloud. The proposed bi-factor classification phase helps the tasks to be scheduled to the right place based on their deadline and priority. The scheduler ensures minimizing the task completion time while maximizing resource utilization thus improving the overall QoS. The simulation results reveal that combining the classification phase with the IJFA speed up the completion of tasks based on their relevance. The advantage of using fog resources integrated with cloud resources offering superior task completion time has been presented. The model was rigorously tested to successfully evaluate its performance from low load to the real-world scenario of large volume and heterogeneous IoT task requests. The proposed IJFA based scheduler outperforms the traditional Jellyfish search optimizer (JS) under various test conditions to prove its effectiveness. The authors have already started to take this work further to propose a multiobjective model minimizing the response time and energy for the integrated fog-cloud architecture aiming an improved QoS to the users while decreasing the cost for the providers.