extfieldsofstudy:
Medicine
Computer Science

text:
A static VM placement and hybrid job scheduling model for green data centers

Reducing energy consumption has become a critical issue in today data centers. Reducing the number of required physical and Virtual Machines results in energy-efficiency. In this paper, to avoid the disadvantages of VM migration, a static VM placement algorithm is proposed which places VMs on hosts in a Worst-Fit-Decreasing (WFD) fashion. To reduce energy consumption further, the effect of job scheduling policy on the number of VMs needed for maintaining QoS requirements is studied. Each VM is modeled by an M/M/* queue in space-shared, time-shared, and hybrid job scheduling policies, and energy consumption of real-time as well as non-real-time applications is analyzed. Numerical results show that the hybrid policy outperforms space-shared and time-shared policies, in terms of energy consumption as well as Service Level Agreement (SLA) violations. Moreover, our non-migration method outperforms three different algorithms which use VM migration, in terms of reducing both energy consumption and SLA Violations.

Introduction
Ever-increasingly, companies move to the cloud to lower their budgets and reduce costs by benefiting from pooled hardware and software resources, delivered as IT services. These shared, on demand services are mainly offered in three forms: Infrastructure as a Service (IaaS), Platform as a Service (PaaS), and Software as a Service (SaaS). In the scope of IaaS clouds (e.g., Amazon EC2, Microsoft Azure, and Google Compute Engine (GCE)), server virtualization is a key factor for elasticizing the data center by sharing computing resources between several users and simultaneously, isolating them from each other. Elasticity, the ability to expand and contract resources as workloads change, is an important aspect of IaaS clouds, which profits both cloud providers and users by removing the extra resources. Elasticity not only decreases green-house gasses and global warming by reducing the energy consumption of data centers, but also cuts the costs for cloud users, while providing sufficient resources to maintain QoS requirements. Server virtualization benefits IaaS datacenters, in fundamental different ways [1]: • Physical servers are usually too big for a single user. Virtual machines can divide them into smaller virtual servers, and assign each one to a different user.
• Virtual servers are easier to manage because they are software-based and expose a uniform interface through standard abstractions.
QoS requirements and obligations such as response time, reliability, availability, and security are summarized in Service Level Agreement (SLA), and a penalty is charged for any violation [2]. In this paper, we focus on response time and avoid SLA violations by verifying that the time it takes for a request to complete does not surpass its deadline. It is justified in [3] that focusing on CPU usage is sufficient in managing the resource allocations to CPU-intensive applications. So, we concentrate on CPU usage, and propose a method to reduce the amount of resources allocated to services while maintaining their SLA requirements. Basically, servers consume about 45% of the whole energy of a data center while their energy consumption is not proportional to their load [4]. As a server turns on, it consumes 69-97% of its total energy, therefore, when the server is idle or under-loaded, much of its energy is literally wasted [5]. Thus, one way to reduce the energy consumed in a data center is to turn off as many servers as possible. But as it takes a considerable amount of time to turn on a switched off host, so, it is wise to switch an idle host into a sleeping mode instead of turning it off.
Some papers consider using VM migration to dynamically place as many VMs as possible on a server and reduce the number of active servers [6,7]. VM migration could be very time consuming and detrimental to real-time applications, therefore, live migration is used to reduce the downtime. Live VM migration is the practice of moving a running VM from one physical machine to another, without disconnecting the applications. Although, live migration can decrease energy consumption, it introduces some additional energy usage to the data center. It has been shown in [8] that static resource allocation is more energy-efficient than dynamic allocation. VM migration (even in its live form) brings many disadvantages. First of all, it hurts real-time applications, as it increases latency. It also causes difficulty for the addressing and routing system, e.g., when the VM migrates to a new subnet, its IP address has to be changed, and subsequently, all the forwarding tables in the switches and routers need to be modified. Moreover, it unexpectedly intensifies the traffic and might cause congestion. As such, some of the previously proposed methods completely avoid VM migration, but usually require the workload to be predictable [9][10][11].
In this paper, we propose a method to place VMs on less number of servers statically in a Worst-Fit-Decreasing (WFD) fashion. WFD is a bin packing algorithm that according to our results performs better than other bin packing algorithms, namely, First-Fit-Decreasing (FFD) and Best-Fit-Decreasing (BFD) when placing VMs on servers. To further make our method more energy-efficient, we purpose a hybrid job scheduling algorithm using queuing theory that reduces the number of VMs by placing as many jobs as possible on a VM. By using less VMs, we utilize less servers and eventually reduce energy consumption.
Generally, Virtual Machines (VM) use two main scheduling policies, namely, space-and time-shared to assign resources to the jobs appointed to them. Additionally, hybrid algorithms, combine the two aforementioned policies. While in space-shared, which is non-preemptive, the processing space is shared among different jobs, in time-shared, which is preemptive, time is divided between them [12,13]. In hybrid mode, both time and processing space are divided between jobs. A good comparison between different algorithms of each class of policies is given in [13]. Basically, First-Come-First-Serve (FCFS) and Shortest-Job-First (SJF) are the two main algorithms used for space-shared policy. Another approach to space-sharing is randomization which unfavorably, eliminates predictability. Priority scheduling, another space-shared method, processes jobs according to certain predefined priority levels. Moreover, backfilling, in which shorter jobs can be processed in the unused spaces left between longer ones, is another technique used in space-shared policy [14]. In a time-shared policy, the scheduler shifts between jobs in different time slices. One of the simplest algorithms for this discipline is Round Robin (RR), which treats all jobs equally. In contrast, Shortest Remaining Time (SRT) and Highest Response Ratio Next (HRRN), always choose the job that has the shortest processing time left and the job with highest response ratio ((W + T s )/T s , where W is the job's waiting time and T s is the expected service time), for the next slice, respectively. Feedback scheduling is another pre-emptive scheduling algorithm which concentrates on the time spent in execution so far, rather than the remaining time to execute. The hybrid mode includes algorithms such as co-operative scheduling and scheduling with Message Passing Interface (MPI). Detailed discussion of job scheduling disciplines is beyond the scope of this paper.
Inspired with static VM allocation superiority, in this paper, we propose a non-migration method which does not necessarily need to predict the workload, when placing VMs on hosts in a WFD fashion. As an extension to our research and to reduce the energy consumption further, a novel queue-based algorithm is proposed to schedule jobs on fewer number of VMs by finding the right number of VMs required for each cloud user to maintain SLA conditions. By removing the extra VMs, we aim to utilize fewer number of servers and reduce energy consumption. Since a VM with space-share policy shares the processor space between jobs nonpreemptively, it executes the jobs on different cores of the processor. Therefore, it is modeled by an M/M/m queue. Normally, all the cores of a processor are the same and have equal capacity. Furthermore, we make sure jobs are assigned to the VMs which have enough capacity for executing them. In such a situation, FCFS with backfilling, which performs very well [15] and even near-optima [16], converges to FCFS, as there is no wholes left between longer jobs [15]. In addition, FCFS is the fairest space-shared policy [17,18]. Other disciplines such as SJF, randomization, and priority scheduling are prone to starvation. To this end, a VM with spaceshared policy is modeled by an M/M/m/FCFS queue.
In time-shared policy, since Processor Sharing (PS) discipline is a good approximation for RR algorithm, a VM is modeled by an M/M/1/PS queue. In hybrid mode, each core devotes a time slot to a different job in an RR manner. Therefore, it is modeled by an M/M/m/PS queue. In each scenario, the maximum request arrival rate λ max of each VM is derived. By modeling SLA in terms of response times or latencies, both real-time and non-real-time applications are taken into consideration. Our findings show that there is a trade-off between server utilization and SLA violation: The busier a server gets, the more time is required for each job to be completed. Analyzing VM request queues, we balance those two metrics to design an energy-aware non-migration algorithm for placing VMs on servers in a WFD bin-packing fashion, as WFD is found in our work to have better performance in placing VMs on physical hosts compared with the other two algorithms, namely BFD and FFD bin-packing.
To simulate our algorithm CloudSim [12] is interfaced with Matlab. We found that the hybrid mode, remarkably, outperforms space-shared and time-shared policies and assembles their advantages. We conclude that by applying hybrid policies in conjunction with nonmigration VM management, SLA conditions are better maintained, and less energy is consumed. The simulation results show that our non-migration method outperforms three different algorithms which use VM migration in terms of reducing both energy consumption and SLA violation.
The remainder of the paper is organized as follows. Related work is reviewed in Section 2. Section 3 and 4 describe our proposed model. Section 5 presents the experimental results. A conclusion is made in section 6.

Related work
To reduce the power consumption, the proposed methods in [6] and [7] decrease the number of active servers. The authors of [19] propose a method called PRESS in which an elastic resource allocation scheme is developed by predicting tenants' behavior. The prediction is done using Fast Fourier Transform (FFT) for workloads which do have a repeating pattern and discrete time Markov chain for workloads that do not. In [20], a cloud server farm is modeled by an M/M/R queue. Then, a cost function consisting of system operating cost, working mode cost, and system congestion cost is minimized using two heuristic algorithms called OCP, and OCPF. Although [19] and [20] present a model to reduce energy consumption, they do not propose any method for finding the optimal number of VMs or placing them on servers. In [21], the M/M/1 Queuing Theory Predicting Method (MMQMPM) is improved for predicting the workload. It argues that the delay of MMQMPM, during the rapidly increasing period is unacceptable. To overcome this problem, it uses the Linear Trend Predicting Method (LTPM), which responds quickly to continuously increasing sequences. In [22] and [23] resources are modeled by an M/M/c and M/M/1 queues. They both formulate an optimization problem for resource provisioning and reducing power consumption. Authors in [24] model an incoming data stream by a queue with arrival rate λ. In order to satisfy QoS requirements, they define a limit on maximum waiting times, corresponding to deadlines. By Little's law, they transfer this limit to an upper bound on the queue's length. Using this upper bound, they adjust the number of VMs to reduce energy consumption.
The reported works in [25][26][27] try to reduce the number of migrations, but they didn't completely avoid VM migration, as it requires the workload to be predictable. However, our proposed algorithm does not necessarily need to foresee the workload. The authors of [9] bring two scenarios under consideration: SSAP which represents a constant workload over time, and SSAPv which provides cyclic workloads over time. For each of these scenarios an optimization problem is formulated and then solved by Branch & Bound and heuristic algorithms, and then compared with each other. Similarly, in [10] SSAP and SSAPv have been formulated as an optimization problem and solved by heuristic algorithms. In [11], considering most workloads are seasonally cyclic, the constraint matrix of each VM is derived by analyzing resource demands over time, and then reduced using Singular Value Decomposition (SVD). Using the information gained, an integer programming problem is formulated to optimally place VMs on servers. In this paper we build a paradigm to implement energy-aware nonmigration VM placement, which do not necessarily need the workload to be predictable.
The authors of [9] and [28] use FFD algorithms to find the minimum number of servers required for placing a certain amount of VMs on them. Whereas [29] uses BFD to minimize the number of required servers for VM accommodation. However, [30] and [31] found that WFD has performance in placing VMs on physical hosts. In [30], the placement of jobs on VMs, and VMs on hosts has been organized, using bin packing algorithms. Accordingly, four different strategies have been examined: best fit-best fit, worst fit-worst fit, worst fit-best fit, best fit-worst fit. It is concluded that placing the jobs on VMs by best fit, and VMs on hosts by worst fit algorithms (best fit-worst fit), present the best results for reducing energy consumption. In [31], simulated annealing has been combined with worst-fit decreasing algorithm to solve the bin-packing problem. We use WFD to implement our energy-aware non-migration algorithm and compare it with WFD, BFD, and FFD which use VM migration for optimizing VM placement.
None of the works explained above consider the VM's job scheduling policy, when rightsizing the allocated resources. Moreover, they do not bring real-time applications under consideration. EARH [32] proposes a scheduling paradigm to manage energy consumption for real-time applications. It utilizes a rolling horizon architecture to schedule jobs with respect to their deadlines. SEATS [33] provides equations to obtain the CPU utilization point of a host where energy consumption is minimum. According to that it places the VMs on the hosts in a way that real-time tasks are executed before their deadlines. In [34] Markov queuing theory is used to schedule tasks on VMs according to their SLA conditions. Then, an optimization problem is formulated to reduce energy consumption while placing VMs on hosts. Four different heuristic algorithms are used to solve the optimization problem. Although papers [32][33][34] use VM migration to decrease energy consumption, their focus aims at avoiding the side effects, especially on real-time applications. In two rather similar but separate works, ant colony optimization is used for virtual machine placement in data centers. Both works have reported that their method has outperformed FFD in terms of power consumption [35,36]. To optimize energy consumption in dynamic VM placement, a partitioned optimization method is proposed in [37] by combining the partheno-genetic algorithm with a multiplayer random evolutionary game theory to find the best migration possibility. As most works propose a method for nonreal-time applications, real-time applications are considered rarely.
In this paper, we propose an energy-aware non-migration VM placement algorithm which benefits real-time applications the most. We show that taking the job scheduling policy into consideration and adopting hybrid policy instead of space-shared or time-shared can remarkably reduce the energy consumption while maintaining SLA conditions. For this purpose, a resource-rightsizing algorithm for a space-shared policy with FCFS and a time-shared policy with RR discipline, and hybrid policy: the combination of space-shared and time-shared policies, are tested. We take both real-time and non-real-time applications into consideration. The results show that the hybrid policy excels space-shared and time-shared policies lower energy consumption and fewer SLA violations. In addition, the hybrid policy outperforms WFD, BFD, and FFD with VM migration, in terms of reducing both energy consumption and SLA violation. The next two sections explain our proposed model. The terminology used is summarized in Table 1.

The proposed model
According to what has been stated in the SLA, some minimum number of VMs are initially assigned to each cloud user. It has been shown in [30] and [31] that among BFD, FFD, and WFD, WFD performs better. Thus, we use WFD in our non-migration VM management strategy to place these VMs on data center servers. In WFD, first, the hosts and the VMs are sorted according to the amount of processor capacity they respectively have and require in decreasing order. Then the largest VM is placed on the largest host. The next VMs are in turn placed on the largest available space on the utilized hosts. If a VM could not fit on the largest available space, a new server is utilized. We aim to execute the jobs on minimum number of VMs possible, and therefore, reduce the number of active hosts. Since it takes considerable amount of time to turn on a server, a host whose all its VMs are idle will not be switched off, instead, it will be asleep. This is extremely useful for real-time applications. As depicted in Fig 1, when a new job arrives, the job scheduler faces two different scenarios: (1) there is an active VM with enough capacity to execute it, (2) all of the active VMs are fully occupied and cannot undertake the job, and therefore, a new VM should be activated or created.
In our method, when a job is executed and completed, the VM updates the maximum request arrival rate, λ max (We will see in section 4 that to calculate λ max , the mean execution time, T s , is required. Thus, when a job is completed, λ max needs to be updated.).
The job scheduler unit keeps a record for each VM, stating whether the VM can or cannot accept more jobs. The job scheduler uses this record to decide whether or not it should give a newly arrived job to a VM. Each time a new job is assigned to a VM, or completed and removed, the VM sends a report to the job scheduler unit and updates its record. Algorithm 1 shows a VM sending a report to the job scheduler unit upon a new job arriving, or a job departing. In this algorithm, the VM uses Little's law to convert the maximum request arrival rate λ max to the maximum number of jobs in the VM, N max (N max = 1 + λ max .waiting_time where λ max .waiting_time number of jobs are waiting for service and 1 job is being served). If the number of jobs that the VM is serving is smaller than N max , the VM reports to the job scheduler that it "can accept more jobs" otherwise, it reports that it "cannot accept more jobs".

Algorithm 1. VM Report Upon a New Job Arriving or a Job Departing
Input: λ max , the maximum request arrival rate the VM is allowed to have; W, maximum waiting time. job_number: the number of jobs being served by this VM. Output: Report stating whether it can accept more jobs or not. 1: N max = λ max .W + 1 2: if job number < N max then 3: report = can_accept_more_jobs 4: else 5: report = cannot_accept_more_jobs 6: send (report) When the service is entering busy hours, or the job request rate is increasing, the job scheduler unit might find that none of the active VMs are able to undertake the new job, therefore, a new VM should be activated or created. We designed the job scheduler unit to make a fair decision in the four following steps: 1. If there are idle sleeping VMs on active hosts, activate the largest one and assign the new job to it. The host is already active and much of its energy is being consumed. By activating the largest VM, we make better use of the host and provide more processing capacity to the increasing number of arriving jobs.

2.
If there isn't any idle VM on the active hosts, but there is enough empty space on them, select the largest space and create the largest VM which fits in that space. Aside from making better use of active hosts and presenting biggest processing capacity possible to the increasing number of arriving jobs, this decision is the closest to WFD policy.
3. If no VM can be activated or created on the active hosts, but there are idle VMs on sleeping hosts, select the smallest sleeping host and activate the largest VM on it. Since we are activating only one VM of a host, a great portion of the hosts' CPU capacity will be unused. With a larger host, which consumes more energy, more CPU capacity is unused

PLOS ONE
and wasted. Additionally, the largest VM consumes a greater portion of hosts' processing capacity and provides greater processing capacity to the increasing number of arriving jobs.

If no VM can be activated or created on the active hosts, and there is no idle VM on the sleeping ones, select the smallest host and create the largest VM on it.
Other than the reason explained in the previous part, this decision is the closest to WFD policy.
The job scheduler unit checks the VM reports in the order of VM creation. In other words, the VMs which were created earlier are checked sooner. This way, when the busy hours are over, or the job request rate is decreasing, new jobs are assigned to older VMs and the younger ones would gradually become idle and asleep in turn. A host can go to sleep as soon as all of its VMs are idle. Once a VM is created, we do not delete it anymore, because it is very likely that it would be needed again soon when the job request rate increases. With this paradigm, we place the VMs on servers in a WFD fashion, and reduce the number of servers used and the amount of energy consumed without migrating any VM. We elasticize the data center by adding and removing VMs from the service. In other words, we divided the VMs into two parts: (1) the minimum number of VMs which are almost always running, because the load seldom gets lower than the sum of their capacities, and (2) additional VMs, which are added to the service as the load increases, and removed again when the load decreases. The minimum number of VMs are created initially and located on the servers according to WFD algorithm. The additional VMs are located on the hosts later on in our aforementioned four steps with a policy very close to WFD. Algorithm 2 provides the code of the job scheduler unit. In the next section, we explain how VMs calculate their maximum request arrival rate λ max .

The maximum request arrival rate, λ max
We define a start time, an execution time, and a deadline for each job. Therefore, the waiting time is calculated by: In real-time applications, W is as small as 100 (ms), but in non-real-time procedures, it can be greater [38]. Since requests are submitted stochastically, we can assume that arrival times have an exponential distribution with mean arrival rate λ. In fact, it is very common to assume the arrival time and service time of the jobs have an exponential distribution [20][21][22][23][24]. As the mean request arrival rate, λ, increases, the VM gets busier and it takes more time for each job to complete. Our goal is to discover the maximum value of λ, which keeps the time jobs spend in the VM lower than W and no SLA violation occurs. Taking t as a random variable denoting the time a job spends in the VM (sojourn time), we can find a lower bound on the probability Prðt �TÞ using Cantelli's inequality which is a generalization of Chebyshev's inequality [39] Where μ t and s 2 t are the mean and variance of t, respectively, h can be any real number, and T is the maximum sojourn time possiblê AssumingT ¼ h þ m t ) h ¼T À m t , and since h ¼T À m t > 0, we can have

PLOS ONE
Thus, In the following sections, our models for space-shared, time-shared, and hybrid policies are described.

Space-shared policy
In space-shared policy the VM shares the CPU cores between jobs, non-preemptively [12]. A VM with space-share policy is modeled by an M/M/m/FCFS queue. We denote the arrival rate by λ and the mean service time by T s = 1/(mμ). Thus, the utilization factor is ρ = λ/(mμ) = λT s . According to Eq (5), in order to find a lower limit on Prðt �TÞ, we need the mean and variance of t, which can be obtained for FCFS discipline by Eqs (6) and (7) [40].
Where π w is the probability of the number of requests waiting in the queue (n), being greater or equal to m. In other words, the probability that a request must wait for service, when it arrives.
And π 0 is the probability of no requests waiting in the queue. Hence, π w is Erlang's C formula. We want Prðt �TÞ to be higher than a certain bound b, therefore by substituting Eqs (6) and (7) into Eq (5) we obtainT Eq (10) leads to a polynomial in ρ with maximum order 2m + 2. For m = 2, we find T 2 ð1 À bÞr 4 À 4T 2 s br 3 À ð2T ðT À 2T s Þð1 À bÞ À 4T 2 s bÞr 2 þ ðT À 2T s Þ 2 ð1 À bÞ À 4T 2 s b ¼ 0ð11Þ We solve this equation with Newton-Raphson's method [41]. The closer b is to 1, the higher is the possibility of roots being lower than 1. Once the roots of ρ are found, the largest positive answer is chosen, and the maximum arrival rate λ max is obtained by That implies that in our algorithm, this VM is allowed to accept the coming jobs, as long as its arrival rate is not greater than λ max . We calculated the mean execution time (T s = 1/(mμ)) using the moving average method [23].
T s ðiÞ ¼ aðexecution timeðiÞÞ þ ð1 À aÞ:T s ði À 1Þ ð13Þ Where α�(0, 1) is the smoothing factor, and i is the index of the job submitted to the VM. By experiment we found that the best results are obtained when α = 0.2.

Time-shared policy
In time-shared policy, in each time slot, the VM devotes all of its processing space to the selected job. Thus, it is modeled by an M/M/1/PS queue with arrival rate λ and mean service time T s = 1/μ. Therefore, the utilization factor is ρ = λ/μ = λT s . In order to find λ max , we find a lower limit on Prðt �TÞ as we did in space-shared policy. Hence, we use the mean and variance of the sojourn time in M/M/1/PS queue [42,43]: Again we consider a fixed lower limit b for Prðt �TÞ and by substituting Eqs (14) and (15) into Eq (6), we obtain Eq (17) is a third degree polynomial in ρ, which can be solved by Newton-Raphson's method [41], and through its maximum positive root, we find λ max by Eq (12). Moreover, T s is acquired by Eq (13).

Hybrid mode
In the hybrid mode, in each time slot, the VM assigns each one of its cores to a different job and therefore serves more than one job in a time slot. This scenario, which is a combination of space-shared and time-shared policies, is modeled using an M/M/m/PS queue with arrival rate λ and mean service time T s = 1/(mμ), and thus, the utilization factor is ρ = λ/(mμ) = λT s . Again we need the mean and variance of the sojourn time to acquire a lower limit for Prðt �TÞ. Since the mean sojourn time is independent from the dispatching discipline (the queue policy for serving the customers), it is obtained by Eq (6). Braband has found a state dependent formula for waiting time of M/M/m/PS queue and derived an exact formulation for its first two moments, M (1) and M (2) [43]. Accordingly, for m = 2 the variance of the sojourn time is Where M ð1Þ 0 and M ð2Þ 0 are the first and the second moments when n, the number of requests in the queue is zero. It has thoroughly been explained in [43] how M ð1Þ 0 and M ð2Þ 0 are acquired. For more information on this matter refer to [43,44].
We consider a fixed lower bound b for Prðt �TÞ and substitute Eqs (17) and (6) into Eq (5) and findT Eq (18) does not lead to a polynomial in ρ, but a root for it can still be found by the Newton-Raphson's method. The integrals of the M ð1Þ 0 and M ð2Þ 0 (see [43]) is solved by the Monte-Carlo method [45] in our program. Then λ max is obtained from Eq (12). T s is also calculated using Eq (13). Algorithm 3 describes our proposed model for finding λ max in space-shared, time-shared, and hybrid policies. Based on experimental analysis, we found that our proposed queuing theory methods for finding the right number of jobs in a VM with space-shared, time-shared, and hybrid job scheduling policies have a small transition time and converge to steady state fast enough, so that sufficient number of VMs are activated on time.

Experimental results
To simulate and evaluate our proposed model, we interfaced CloudSim with Matlab. We used Google cluster data [46] that was collected in twenty-nine days. We created 500 hosts in CloudSim and inserted 2000 jobs into our simulation. Half of the hosts were HP ProLiant ML110 G4 (Intel Xeon 3040, 2cores×1860MHz, 4GB), and the other half were HP ProLiant ML110 G5 (Intel Xeon 3075, 2 cores×2660MHz, 4GB), as in [47]. We chose two different sizes, 500 and 800 MIPS, for the VMs. We explored the three job scheduling policies for different acceptable waiting times W. Usually, cloud users do not tolerate SLA violation, therefore we only chose higher probability bounds (Prðt �T Þ � b), b = 0.99, 0.9, and 0.8 for our simulation. It t can be seen from the diagrams that as maximum waiting time increases, energy consumption and SLA violations are both reduced. This indicates that managing real-time jobs is much harder and more complicated than non-real-time jobs. Moreover, the diagrams indicate that the hybrid policy outperforms both space-shared and time-shared policies and has lower

PLOS ONE
energy consumption and fewer SLA violations compared to space-shared and time-shared policies.
Next, our algorithm is compared with three different energy-aware VM placement algorithms which use VM migration. Initially, VMs are randomly placed on hosts. Every five seconds, VM placement is checked and optimized using WFD, BFD, and FFD algorithms. The diagrams show that our algorithm outperforms WFD, BFD, and FFD algorithms with VM migration. The reason is that our algorithm places VMs on physical machines in a WFD fashion without migration. VM migration prolongs the execution process and raises the probability of SLA violation. Even in live migration the jobs have to stop and wait until their essential codes and data stacks are moved, and then continue their execution. Moreover, VM migration introduces a burst to the network and causes even more latency. Thus, especially for

PLOS ONE
real-time applications, VM migration brings about SLA violation. In addition, some additional amount of energy is consumed by the network to migrate the VMs. Therefore, the energy consumption and SLA violation of the three algorithms with VM migration degrades and our energy-aware non-migration VM placement excels them. Corresponding to any SLA violation level, the energy consumption of our method is better than that of dynamic FFD, BFD, and WFD methods. So, our hybrid algorithm presents lower energy consumptions and fewer SLA violations and outperforms the three dynamic algorithms. We also found that the energy consumption of the three dynamic algorithms is highly affected by the number of migrations. Therefore, since the number of migrations of the three dynamic algorithms does not noticeably change as the waiting time rises, in Fig 5, the energy consumption of them does not decrease; however, as waiting time rises less jobs elapse their deadlines and fewer SLA violations occur, according to Fig 6.

Conclusion
In this paper, an energy-aware non-migration VM placement and hybrid job scheduling policy was proposed to make the cloud elastic. Generally, job scheduling policies can be classified into two main groups, namely, space-shared and time-shared. Moreover, some algorithms, which we call hybrid, combine the two aforementioned algorithms. Proposed methods which completely avoid VM migration, usually require the workload to be predictable. However, in our approach, the workload do not necessarily need to be predictable. In addition, our method is applicable for both real-time and non-real-time applications. We showed in our paper that hybrid policy excels space-shared and time-shared policies in terms of reducing both energy consumption and SLA violation. We adjusted the resources allocated to each cloud user according to their QoS by modeling the VMs of a data center with a queuing theory technic. We applied our idea to space-shared, time-shared, and hybrid policies, developed different equations for each one, and obtained the maximum acceptable arrival rates λ max by studying the sojourn time of the jobs. λ max was used to determine whether a VM can accept more jobs or not. An energy-aware non-migration algorithm was designed to place the VMs on servers in a WFD fashion.
We interfaced CloudSim with Matlab to simulate and evaluated our algorithm. The results show that as waiting time increases, both energy consumption and SLA violation decrease. This clearly shows that although real-time jobs are not minded in previous research deservedly, managing real-time jobs are much more complicated than non-real-time jobs. The experimental results indicate that the hybrid policy is superior to space-shared and timeshared policies in reducing both energy consumption and SLA violation. Moreover, we compared hybrid algorithm with three different algorithms, WFD, BFD, FFD with migration. The results show that our energy-aware non-migration VM placement algorithm with hybrid job scheduling policy outperforms all three in terms of reducing both energy consumption and SLA violation.


Online Social Space Identiﬁcation. A Computational Tool for Optimizing Social Recommendations

: Conscious and functional use of online social spaces can support the elderly with mind cognitive impairment (MCI) in their daily routine, not only for systematic monitoring, but to achieve effective targeted engagement. In this sense, although social involvement can be obtained when elder’s experiences, interests, and goals are shared and accepted by the community, an important subsistence for aging depends on the compelling information, users’ co-operation, and resource reliability. Unfortunately, applications aimed at optimizing the information content and the reliability of online users are still missing. Within the SystEm of Nudge theory-based ICT applications for OldeR citizens (SENIOR) project, an advanced social platform will be created in which the elderly with MCI will be involved in “optimized” social communities, where suggestions for general well-being will be recognized as useful by users and shared by care providers. We report the results of our study addressing this issue from a theoretical perspective: we propose a computational problem and a heuristic solution where “expert users” can engage and support the elderly by suggesting available services and facilities for their conditions. The numerical experiments on synthetic data are of interest when considering large communities, which is the most natural situation for online social spaces.

Introduction
Mind cognitive impairment (MCI) is rapidly becoming one of the most common clinical manifestations affecting the elderly. It is characterized by deterioration of memory and cognitive function that is beyond what is expected based on age and educational level. MCI does not interfere significantly with individuals' daily activities. It can act as a transitional level of evolving dementia with a range of conversion of 10%-15% per year [1]. Therefore, it is crucial to protect older people against MCI.
The SystEm of Nudge theory-based ICT applications for OldeR citizens (SENIOR) project (a project supported by the Cariplo Foundation according to well-being and social cohesion planned intervention strategies) will create an advanced nudge-based [2,3] social platform, collecting and integrating significant physiological and behavioral data to interact with elderly people and to

Related Work
Online education plays a fundamental role in the prevention and conscious participation of patients in the care process. In particular, some online social networks have been emphasized as a useful tool that acts as social support for the elderly, capable of shielding, in some circumstances, from psychological stress and encouraging participation and engagement [4][5][6][7][8][9].
Some of these platforms, such as PatientsLikeMe (http://www.patientslikeme.com), CureTogether (http://www.curetogether.com), or MedHelp (http://www.medhelp.org), have provided users self-management of personal activities for their own diseases. For example, in [10], an auto-tracking system called "Empower"was designed to allow the self-management of patients and their treating physicians. In this case, specialists can provide recommendations and monitor patient's daily progress. Similarly, HealthNet (HN) [11] allows users to access suggestions on both doctors and health facilities that best fit the patient's clinical profile. The main component of HN is a recommender system that is able to suggest similar profiled patients and indicate health services for a specific condition. Moreover, understanding (or even inducing) the formation of social ties within online health networks, their structure, and functions, as well as the associated mechanisms linking these to health services, can be extremely relevant for several reasons. For example, • To reduce information overload [12][13][14]; • To provide trust-based communications [15][16][17]; • To handle complex relationships among the networks' elements [18]; • To allocate limited resources properly [19,20].
In this regard, one of the most convincing ideas for promoting the creation of suitable health social spaces has been the application of recommender systems (RS). Unfortunately, these mechanisms have not yet been widely used in the medical context (and in health informatics). Above all, in these fields, they still lack the fulfillment of the above issues simultaneously. To some extent, current solutions are limited to conferring direct benefits either to health professionals or patients, rather than inducing both optimized and reliable information content spaces for targeted allocation of health services. Wiesner and Pfeifer [21] distinguished two different scenarios. On the one hand, healthcare professionals are the beneficiaries of the recommendations to find, for example, additional information for specific case studies, guidelines, or research articles. On the other hand, the beneficiaries are the patients. In the latter case, RS focuses on delivering high quality, evidence-based, health-related content to end-user patients, for example suggesting clinical examinations [22], lifestyle changes [23,24] , or improving patient safety [25]. Similarly, they are also used to indicate to the patient a better understanding of his/her personal health status, to retrieve semantically-related content, or to suggest web sites concerning specific diseases [26,27].
To the best of our knowledge, no framework exists that specifies how health-related recommender systems can guide the network creation process and, in particular, can generate networks that comply with the requirements argued previously. It is our opinion that promising new research in this direction can be conducted by applying computational methods to the study of heterogeneous information networks more widely [18,[28][29][30][31][32]. In this context, graph theory and optimization techniques could provide future recommendation systems with the ability to influence and effectively support user communication in online health spaces. For example, in the literature, some algorithms designed for this purpose, i.e., to identify specific subgraph communities such as cliques or k-clubs, can be found in [33][34][35][36]. It is worth noting that the optimization of targeting social spaces for potential recommender systems, and therefore the theoretical identification of these communities, may lead to combinatorial optimization issues, which, in turn, bring the identification of intrinsically complex (intractable) problems [37]. Anyway, even in these circumstances, common approaches exist for applying specific heuristics or designing particular (machine) learning techniques that offer approximate, but efficient solutions [38][39][40][41][42].

The "Social Space Identification" Problem
In some circumstances, friendship is not the only factor that allows us to build reliable suggestions for a recommendation system. Instead, for users, sharing information about available facilities and services, being involved in common goals, or even sharing their own history and experience with other users should be the key issues to consider when providing adequate recommendations. With this perspective, SENIOR's social engine will be formulated as a computational problem aimed at optimizing heterogeneous groups of people and resources by exploiting the involvement and the skills of "expert users", i.e., care providers, specialized personal, acquaintances, patients with similar experiences.
Without loss of generality, we can consider the case of a "clinic oriented engagement". Suppose users are recently diagnosed (RD) patients who want to be involved in managing their diseases through the experience of other users (e.g., being followed up for similar diseases), say "expert patients" (EX). In this situation, new users may be interested in acquiring information about, e.g., follow-up treatments, specialized hospitals, and doctors; in general terms, they should be interested in knowing as much as possible about the caregivers (here, we will also use the term health service provider or its acronym HSP) and the services they offer. In this case, the platform should motivate new patients to socialize with experts who have already been followed up, for example, in the same health centers or by other specific caregivers. It is more likely that, under these circumstances, EX patients can share reliable and convincing suggestions.
Importantly, the identification of potential users and resources would, therefore, allow properly providing the recommendation system with effective information, which, in turn, would allow inducing the targeted communication within the chosen group.

Problem Formulation
Modeling the situation described in the previous section naturally leads to the problem of identifying (large and dense) communities of users and items. In our case, the role of expert users is fundamental to apply the method properly. We could represent EX patients through "entities", which act as "bridges" between new patients and HSPs: their role is to connect RD patients and HSPs, indirectly. In such a situation, the interest becomes that of identifying a large (and dense) community in which RD users can be at most at a distance of two from HSPs, being connected through the "experts" who can offer their support.
The problem can, therefore, be formulated as follows. Within a given network, identify the largest community in which users are connected (through paths of length two) to items through available specific users. This model leads to the theoretical concept of two-clubs (i.e., graphs with particular properties). For the sake of clarity, before defining the problem computationally, we recall some important definitions in the context of graph theory.

Main Notation and Definitions
Graphs are abstract models of complex relationships commonly established in current networks. Formally, a graph G = (V, E) is a collection of the network's entities (i.e., vertices, V) and interactions among them (edges, E). Given a graph G, we use the corresponding adjacency matrix A, which indicates whether two vertices v i , v j of G are connected by an edge, i.e., (A) We also use the notation A[i, k : j, m] to denote the sub-matrix of A indexed by the rows i...k and columns j...m. Moreover, we denote by G[V ] the subgraph of G induced by the subset of vertices V ∈ V.
A path in G is a finite (or infinite) sequence of edges that joins a sequence of distinct vertices. The distance, d G (u, v), between two distinct vertices u and v is the number of edges in the shortest path connecting them. The diameter of G = (V, E) is defined as max u,v∈V d G (u, v), i.e., the maximum distance between any two vertices in V. Finally, we denote by N(v) = {u : {v, u} ∈ E} the neighborhood of a vertex v. The following definitions are fundamental for our objectives: Definition 1. Two-clubs are subgraphs where all the vertices are at a distance at most two. Importantly, given a graph G = (V, E), a two-club in G is a subgraph G[W], with W ⊆ V, whose diameter is at most equal to two.
Let G be a graph, V = T ∪ X ∪ R its set of vertices, and T, X, and R the set of RD patients, EX patients, and HSP centers, respectively. Consider a labeling function h : V → S that assigns to each vertex in V a (type of) service in S. Notice that a service h(v) ∈ S can be required by new users v ∈ T (e.g., v requires information about h(v)), already prescribed for some expert v ∈ X (e.g., v was followed up with h(v)) or available in some center v ∈ R (i.e., health service h(v) is available in v).

Definition 2.
A vertex x ∈ X, for which there exists, in N(x), at least one pair (t, r) ∈ T × R, where h(t) = h(x) = h(r), will be named a "feasible vertex". Moreover, we call the set of "feasible vertices", C, a "feasible set" and the pair, (t, r), a feasible pair.
In our example, feasible vertices are experts "equipped" with pairs (t, r) consisting of a new patient t with the available caregiver r. In other terms, when a new (target) patientt requires information, our interest will be to supplyt with his/her "own" heterogeneous community of users/items G[T ∪ X ∪ R ], with T ⊆ T, X ⊆ X, R ⊆ R, consisting of the largest number of feasible pairs. More formally, we seek a maximum size two-club fort (i.e.,t included), which has the further property of providing, the largest number of (feasible) pairs (t, r) whose vertices t and r are connected with at least one simple path passing through some x ∈ X , such that h(t) = h(x) = h(r), i.e., the information about service h(t), requested byt, is available with (the caregiver) r. This information can be obtained consulting x.
For any "target", the identification of the largest size two-club (with the largest number of feasible pairs) offers multiple sources of alternative information (each node of a two-club community being reachable through paths of size two). In other words, "targets" can acquire greater awareness in reaching available resources by exploiting different paths and through different "experts". For example, in our case, recent patients (i.e., target users) can collect information on alternative providers (HSP) from the same expert, as well as information on the same center from different available experts. With the above concepts, we can formulate the optimization problem in the following general terms.
where T is the set of RD patients, X is the set of EX patients, and R is the set of HSP centers. (2) A set of service S and a labeling h, such that h : T ∪ X ∪ R → S , i.e., h labels expert patients, recent patients, and services. (3) The target patientt ∈ T. Output: A set V ⊆ V, such thatt ⊆ V and G[V ] is a two-club having both maximum size and the largest number of feasible pairs.

Approximate Solutions
Problem 1 is a computational variant of the max s-club problem, whose complexity is NP-hard for s ≥ 1 [39]. Similarly, this result also applies to Problem 1.
In order to find approximate solutions at a reasonable cost (time), in this paper, we designed a genetic-based heuristic by defining specific operators that allow obtaining fast solutions.

Chromosome Representation
In this way, we assume that c is used to represent a (chromosome) solution obtained through the evolution of randomly initialized binary vectors (starting population) of dimension |V|. In other terms, we represent with binary vectors a population of chromosomes that state the vertices to be included within the corresponding identified community (two-club). With a slight abuse of notation, we indicate with G

Fitness Function
Genetic algorithms (GAs) promote system adaptation in such a way that candidate chromosomes (in our case, being able to represent graphs with a diameter value no larger than two) "evolve" through standard elitism. The evaluation of a chromosome is then obtained by applying a fitness function [43]. Here, we give a general formulation for the fitness we apply in the following paragraphs.
where the value of α will be functionally related either to (1)  Notice that the above objectives are reflected, in turn, by the entropy of the corresponding distributions, i.e., a "distribution of entities", say f Y , obtained by counting the different types of entities in N(v) for each v ∈ V[c], and a "distribution of services" (supplied or demanded by entities), say f S , obtained by counting the different types of services in N(v), for each v ∈ V[c] (These estimations are clearly biased due to the "relationships" between neighborhoods. In fact, here, we are assuming the independence between the distributions of vertices in different neighborhoods.).
As the entropy H( f S ) (respectively, H( f Y )) reaches the maximum if all the outcomes are equally likely, in this case fitness (1), it should promote those chromosomes that represent uniform service-/entity-type distributions around EX patients. Hence, following the above arguments, we set

Mutation
The objective of mutation is to encourage system adaptation. The following three genetic operators are applied (with equal probability). In this case, a standard mutation procedure was applied: bits were randomly switched either "on" or "off".

Cross-Over
The following cross-over operators were designed.
• Logical AND/OR cross-over: New offspring was generated by applying AND/OR logic operations on parent chromosomes.
• Standard cross-over: This operation is typical and is often used in standard applications of genetic algorithms. Parent chromosomes are reported and mixed in new descendants.

Distributed Learning
The large number of data observed in online social interactions and the intrinsic complexity of the proposed problem make it difficult to solve the optimization target computationally. The effective distribution of the learning task is therefore desirable.
The idea of "distributed learning" in GAs has been explored with many motivations [44]. Most of these approaches share the concept of evolving independent (genetic) populations in parallel. Similarly, our goal in this paper is task-motivated: we framed the optimization Problem 1 into independent, local smaller optimization tasks, while returning (local) solutions that could be associated with specific subgraphs.

A Genetic Cascade Model
Distributed learning was conceived following the process in Figure 1. Large scale optimization was divided into smaller problems, where different populations evolved over different (computational) "sites" independently. Each "site" was locally "trained" with the GA described in Section 4, using only a part of the input instances. Figure 1. Distributed process. Different populations evolve over different (computational) "sites" independently. Each "site" is locally trained with the GA, and the best chromosomes from the pair of "ascendents" initialize the lower level site population.
Without loss of generality, we can assume that the sets of expert patients, X, recent patients T, and health providers R form an indexed collection of elements (B i ) i∈[n] , B = {T ∪ X ∪ R}, whose values [n] (to simplify the notation, here we use [n] as a shortcut for {1, 2, .., n}) also index the rows and columns of the graph adjacency matrix A[1, n : 1, n] of G[B]. Moreover, let us assume that the computational load is distributed on a first sequence of different units (say, sites of Level 1) in such a way that each unit of this sequence (say, site i of Level 1, s 1,i ) executes the GA, only on a part of the available users and items data in B. In particular, we distribute to s 1,i only a sub-sequence of k input elements {b 1 , b 2 , . . . , b k }, where b i is either a user or an item in B. For example, site A1 = s 1,1 in Figure 2 works on the sequence consisting of the first five elements {b 1 , b 2 , . . . , b 5 }. Similarly, the second site A2 = s 1,2 employs the successive elements {b 6 , b 7 , . . . , b 10 }.
Using this load distribution, each (first level) site processes its own solution for the graph adjacency (sub)matrix A [i, i + k; i, i + k] whose rows and columns are associated, respectively, with the corresponding sequence of k(input data) elements (B i ) i∈{i,...,i+k} .
Given two (subsequent) first-level sites s 1,i and s 1,i+1 , their input workload {b 1 , b 2 , . . . , b k } and {b k+1 , b k+1 , . . . , b 2k }, and the respective GAs solutions obtained in s 1,i and s 1,i+1 , we can insert the best chromosomes (from s 1,i and s 1,i+1 , respectively) within the population of a new processing unit (say, site s 2,k , of Level 2). In this way, the new chromosome population in s 2,k is properly initialized to return the local solution for the corresponding input subgraph. Indeed, by extending the chromosome representation reported in Section 4.1, we can train the GA employed in s 2,k on the set of elements {b 1 , b 2 , . . . , b 2k }, thus providing feasible solutions for the extended set of input instances, which, in turn, represent a larger local solution whose graph adjacency matrix is: Finally, by extending the process to the lower level site, we complete the evolution of all input data. The best solution provided by the last site identifies, in this way, the community (i.e., the two-club) on the whole input network.

Numerical Experiments
The numerical experiments mainly aimed at evaluating the ability of the GA-based approach to obtain correct solutions in a reasonable time. In order to promote large sized sub-networks, we applied the two cases of fitness introduced in Section 4.2. In particular, we applied Case 1 (distribution-based) for a standard GA evolution (reported as "centralized" in the following discussion) and Case 2 (feasible pairs estimation) for the distributed learning.

Centralized Learning
As we could not compare the solution of the GAs with the problem's optimal solution (NP-hardness), we evaluated the possibility of identifying communities where the services operated by health centers and the services required by users were best distributed around feasible vertices. As discussed in Section 4.2, we encouraged, on the one hand, the offer of a large number of services versus a differentiated request for services and, on the other, the participation of different types of entities around feasible users (uniform distributions).

Models
AvInD We considered the average value of the entropy for the health service and vertex-type distributions around expert patients. It is worth emphasizing that the system returned solutions whose entropy could not be associated with distributions having the whole probability mass centered on any specific value. Notice that, since only RD patients and HSP could be found around EX users, then we had 0 ≤ H( f Y ) ≤ 1. Similarly, as we had S ∈ {1 . . . 5}, i.e., five types of services were considered in our experiments, then H( f S ) was such that 0 ≤ H( f S ) ≤ log 2 (5). • Moreover, notice that, at least 12% of the output nodes were identified as feasible. Larger values are reported for large input networks, e.g., ER(300, 0.15) or ER(150, 0.3). This was a compelling property, for example, in the case of large communities.

•
System time seemed reasonable (T2 ≤ 7.2 s) for the applied instances.

Distributed Learning
In this case, fitness promoted the identification of large networks by weighting the chromosomes with the estimation of the number of feasible pairs (Case 2 fitness) observed in the corresponding chromosome representation. We coded the procedures with the "Multiprocessing" Python package, working on local concurrency with four cores (i.e., the cascade model used four starting sites). The R and Python interfaces were managed by the rpy2 (https://rpy2.readthedocs.io/en/version_2.8.x) utility. Experiments were executed on Apple OSX 10.12.6, system type MacBook Pro Retina, processor Intel(R), Core(TM) i5-6360U 2.00 GHz, 3.100 GHz, 2 core(s), 4 logical processors; installed physical memory (RAM) 8.00 GB. Results are given in Tables 2 and 3. In particular, we compared the results with "centralized" (not distributed) executions. The following attributes were used. • Input/Output diameters: the input graph diameter and output graph diameter proposed by the best chromosome solutions. The following observations can be given.
• All models, except ER(500, 0.1), returned correct two-clubs. This was an interesting result when large input graphs (e.g., more than 1000 vertices in our table) were considered.
• Similarly to previous experiments, as we could not confront the problem's optimal solution, to evaluate the solution proposed by the genetic algorithm qualitatively, we report the ratio between the number of vertices of the input and the output graphs. Notice that the approximability of the problem was very hard to obtain (not approximable within a factor |V| 1/2−ε , for each ε > 0 [47]). Considering our results, in particular the ratio in Table 3, we concluded that the most interesting solutions were those for which the larger the input graph (number of vertices), the lower the difference between the ratio and the unit.

•
Although the size of the identified communities did not seem to differ, the (average) number of iterations of the last level site (distributed execution) was much lower than the iterations reported by the standard, centralized evolution. This was also evident from the decrease in the average execution time per level, reported by the distributed process. Since GAs use the same parameters for the standard and the distributed evolution, this behavior could be traced back to the initialization that each lower level site received from the higher levels.

•
The computational cost seemed to depend on both the edge numbers (i.e., high expected connectivity of random models E(n, p)) and the number of input vertices. As the fitness computational complexity was related to the diameter computation, this assertion could be justified considering the diameter computational cost, which is known to be bounded by O(|V| 3 ).

Conclusions
The challenge set by the SENIOR project is to involve the elderly, with mind cognitive impairment, in target communities where the shared information and the available resources can be exploited as best as possible by users and caregivers. The SENIOR social engine will be designed as a specific recommender system able to leverage on-line information to influence elderly participation and to promote resources for their well-being. As recognized above, to the best of our knowledge, no framework exists that specifies how health-related recommender systems can promote this "network creation process". In this regard, the expected value of the proposed ideas is to promote the creation of online "health spaces" by enhancing trust-based communication between patients and "experts" for suitable resource allocation. In this model, the "experts" not only play an essential role for patients in the real world, but represent mediation nodes for suggesting "items" (i.e., resources) accurately. The recommender system should, therefore, influence the development of the social network with appropriate suggestions.
In conclusion, we can characterize the contributions of this article as follows.
• We formulated a computational optimization problem for the future suggestions of the SENIOR recommender system. • Algorithmic solutions were proposed as well, based on evolutionary heuristics, both for centralized and parallel processing environments.
Further extension of our research will be addressed as follows.
• As reported in recent studies, using additional user and item relationships could improve the recommendation quality [48,49] . In this perspective, the optimization objective formulated in Equation (1) will be further constrained by taking into account relationships between target users. These relationships could be interpretable as either "friendships between target users" or "targets sharing similar experiences". The feasible solutions (i.e., two-clubs) optimized with such a type of connection would allow the future recommendation system to induce even more compelling communication among users, perhaps looking for similar reliable resources. Furthermore, edges among "experts " (within the identified two-clubs) could be used as an endorsement, thus allowing target users to evaluate new different experiences or the consistency of the information of other expert users. Such links could also induce more effective communication between experts to facilitate final patient support. Similarly, a constrained optimization accounting for "resource to resource" relationships, within the identified community, could offer the user equivalent available resources. • In Section 4.2, we presented a general fitness formulation for two different evaluations of a free parameter (α). A more context-based formulation able to manage real needs will certainly provide more effective results in this sense. As an example, we can consider the first reported case (Number 1), where α is related to the health service and vertex-type distributions. In this situation, a linear combination of entropies is used to optimize (and balance) an induced two-club community. Direct comparisons (e.g., using cross-entropy evaluations) of user requirement distribution vs. service distribution could be similarly evaluated for future numerical experiments. • Finally, we assumed so far that each provider could supply one service only. In fact, this was "coded" by the labeling function h discussed in Section 3.2. It is straightforward to extend this labeling to multiple services for a more realistic implementation. Funding: This research received no external funding.


Design an Adaptive Mechanism Model for Supporting the Prevention of SLAs Violation in a Context of COPD Patient Monitoring

During recent decades, contextual computing applications have emerged in the field of healthcare and particularly in the field of telemonitoring of patients suffering from chronic obstructive pulmonary disease (COPD). According to WHO rankings, chronic obstructive pulmonary disease (COPD) is the third leading cause of death worldwide. Various research works are therefore carried out to improve the health of patients and the monitoring of patients in the comfort of their home environment. To this end, several telemonitoring systems are designed to COPD patients. These systems are connected to health center. Emergency physicians follow the patients subscribed to these systems remotely. These systems focus mainly on prediction, decision-making and the requirements of the healthcare profession, and do not address the quality control aspects of services or QoS based on service level agreements (SLAs). This situation can be dangerous for patients in case of extreme exacerbation of COPD patients. For example, the unavailability of the monitoring system can lead to the death of the patient because the emergency physician could not have access to the patient's data in real time in the context of COPD Patient Monitoring. In addition, Remote medical monitoring platforms are manipulating large volumes of data and the risks of data lost or data quality are real. It is therefore important to have the mechanisms to continuously improve the quality of service of these monitoring platforms in general and COPD patients particularly. In this article, we propose an ontology that uses SLA information from COPD monitoring platforms with dynamic data from the patient context. The purpose of this article is to propose a dynamic mechanism model for evaluating SLA violations. This solution allows retrieving knowledge from the main items of the SLA document based on XML and the COPD patient context data dynamically from a COPD SLA ontology. These data retrieved in real time allow the calculation of SLO-based metrics and display a SLA template available on the supplier and consumer interfaces. The information of the SLA violation control Interface changes dynamically depending the context-aware system and SLA document data. The SLA parties can dynamically control their Key Performance Indicators (KPI) Target.

I. Introduction
During the last few decades, ubiquitous computing, commonly referred to as pervasive/ubiquitous systems, has impacted the world of research. This revolution is materialized by many context-aware applications that have become important in different fields of research in general and particularly in the medical field. SLA was introduced in the 1980s. SLA today is considered a standard service agreement between the various parties. The SLA has been used in various fields such as telecommunications, call centers, security, cloud, health systems . One of the main features of the ubiquitous systems used in medical research is the coupling of context and software. This coupling of patient context and software offers the possibility in the medical field to carry out prediction, and the monitoring of patients, despite of many challenges. These healthcare systems focus mainly on prediction, decision-making and the requirements of the health care profession. However, they do not address well the quality control of services (QoS) based on service level agreements (SLAs) in the context of COPD diseases. This situation can be dangerous for patients in case of extreme exacerbation of patient COPD. Indeed, the lack of monitoring dynamic QoS [4] in COPD patients' systems can have dramatic consequences for the patient and affect their quality of life. For example, the delayed and unavailability of the monitoring system can cause the death of the patient because the emergency physician would not be able to have real-time data on the patient. In addition, Remote medical monitoring platforms are manipulating large volumes [4] of data and the risks of data lost or data quality are real. It is therefore important to have the mechanisms to continuously improve the quality of service of these platforms in general and COPD patients particularly. In this article, we propose an ontology that uses SLA information from COPD monitoring platforms with dynamic data from the patient context. The purpose of this article is to propose a dynamic mechanism for evaluating SLA violations. The solution allows to retrieve the main items from SLA XML documents based on WSA and then retrieve the COPD patient context data dynamically from a COPD SLA ontology. These data retrieved in real time allow the calculation of Key Performance Indicators (KPI) Targets based on Service Level Objective (SLO). The adaptive SLA model displays the result of SLA control. This model is available on the supplier and consumer interfaces in real-time. The information of the interface SLA control changes dynamically depending the context-aware system data and SLA document data. The SLA parties can dynamically control their Key Performance Indicators (KPI) Target. Our solution can be also deployed on different COPD patient monitoring systems, in the application layer to integrate quality control mechanisms. This paper presents our adaptive mechanism model of control SLA violations, in the context of monitoring COPD patients. The structure of the article is organized as follows: Section 2 describes the problem. Section 3 presents an overview of the related works. Section 4 describes the details of our proposal model. Section 5 presents Interface for supporting the prevention of SLAs violation. Section 6 gives conclusion and future works.

II. Problems Description
Quality of service (QoS) is important in the field of monitoring systems because context-aware applications must constantly adapt their services to the context [11]. This context changes dynamically and meeting QoS requirements becomes a challenge. Tamura explained [11]: '. These new requirements, such as having to fulfill changing QoS levels under different context situations, further exacerbate the problem of guaranteeing the expected quality of these services, especially under varying conditions of system execution.'. Context-aware applications must constantly adapt their services to the changing context. The question is how to dynamically monitor the service level agreement (SLA) during the adaptation activity in which context can be changed. Abawajy et al. [2] state: "An SLA model is a partially completed SLA document and defines the initial negotiable SLAs and the constraints (placed on the negotiable SLAs, such as lower limits of acceptable values)". In SLA models, we can identify the standard types of metric groupings, such as platform performance metrics, hardware performance metrics and software performance metrics. Khattak argues that Context Quality of Service (CQoS) errors [1], which can occur at any stage of the adaptation process, can have an impact on the quality of service provided by contextual applications. Khattak [1] also declared that: " (1) Context-aware information fusion is based on data received from a number of sources. (2) Some sensors may give false readings. (3) Some sensors may be offline due to low power levels". As an example of data acquisition, errors and failures sensor can provide erroneous data. At the inference level, the algorithms, on which the calculations are based, may be erroneous. All these situations can cause violations of service level agreements between the provider of context-aware applications and users or customers. In the field of COPD patient monitoring, several COPD patient monitoring systems are implemented but according to the literature, quality control is not fully ensured. This situation can be dangerous for patients in case of extreme exacerbation of patient COPDs health. Indeed, the lack of dynamic QoS monitoring of COPD patients of different severity levels can have dramatic consequences for the patient and affect their quality of life. For example, In light of the large volume of data manipulated by healthcare monitoring platforms, the problem of quality of service(QoS) of these platforms must be addressed by the actors (suppliers and customers) for the preservation of patients' health.. Therefore, how to monitor QoS violations in the context of dynamic COPD? In the Cloud computing, research is in progress in the implementation of SLA for business services, but in the context of monitoring the health of COPD patients, the mechanisms to control dynamically the quality of services is almost absent [4]. The different technical challenges are: 1) how to extract data and knowledge in SLA documents based on XML, WSA and dynamic data from the patient COPD context? 2) how to dynamically compile these data for the calculation of SLA control indicators and then display the main items in the adaptive SLA template? The analysis of existing approaches is important in order to be able to find the most appropriate solutions to address these issues.

III. RELATED WORKS
Shah et al. [16] discuss the concept of QoS for the health care system as a whole. The authors explain that these systems handle large volumes of data and that quality control mechanisms are needed to improve the quality of service. They [16] explain the importance of adapting the SLA approaches of the systems to a patient monitoring system. The quality of transmission of data collected on patients is a very promising area of research in the health field according to Khan et al. [4]. Thus, the field of body area networks (BANs) is an emerging field with applications for monitoring vital signs in addition to other contextual information. Khan et al. [4] proposed a solution for the transmission of patient data. The 'QoS Routing Protocol for Reliability Sensitive Data in Hospital Body Area Networks' [4] is an approach that ensures the quality of transmission of data collected from patients, but it does not guarantee transmission quality regardless of the large number of patients to be monitored. Furthermore, this approach does not provide a means or agreement between the patient and the clinic to monitor the quality of service. The requirements of patients are not addressed in the definition of this approach. In the same service quality approach, Kouame et al. [3] and Abawajy et al. [2] indicate that an SLA model is a document that defines negotiable Service Level Objective (SLO)s and constraints. In addition, other research projects have used SLA to improve System QoS. This is the case of the 'SLA predictive monitoring' project [6]. According to Comuzzi et al. [6], this research project presents a new definition of the reliability of SLA forecasts, which includes terms related to the variability of the service provision scenario in which a prediction is made. These predictions are based on SLOs, but this later project is limited by the lack of dynamic control of the SLA. In addition, the research project [5] indicated that: 'SLA based healthcare big data analysis and computing in cloud network' is proposed by combining big data analysis techniques with data collected from patients'. SLA according to Sahoo [5]: 'A PSNB method is proposed for big data analysis of healthcare and a CAM algorithm is also designed for dimension reduction to improve the accuracy of the PSNB algorithm. In addition, a GPS algorithm is proposed to prioritize patient emergency work'. Despite the contribution of this research project to prioritize patient emergency work, this project has limitations such as, non-dynamic SLA and absence of SLA violation control mechanism. The research project also [7] 'Cloud SLA Terms Analysis Based on Ontology' focused on the problem of SLA and QoS violation in the context of services offered by the Cloud. In the context of service offered by providers, this project allows subscribing consumers to monitor SLA violation, however the data for calculating the metrics are not extracted from a patient context and no adaptation mechanism is implemented. The authors even indicated the limitations of this approach [7]: 'For future work, we opt to enhance process by automatically predict SLA violation using context-aware system'. Finally, in the same vein, the AISel project [8] aims to help emergency physicians or practitioners to have relevant information and knowledge about COPD patients in order to better monitor their health status. This project proposes a VOS virtual organization to share knowledge between patient and practitioner actors in compliance with data protection laws. The organisation is based on SLA, a multi-agent system as explained in [8]:'Conceptual definitions of SLA parameters, metrics, and economic values as well as resource characteristics are given in an OWL DL ontology W3C'. The MORF project of Luke et al. [14], is a mobile patient monitoring system with 2 vital parameters: SAO2 and HR. This monitoring system seamlessly integrates vital data from different health services sensors to identify a patient's condition. The system can then take appropriate measures for timely support. It is an ontology-based system that generates alerts based on the values of vital parameters. This system uses ontology-based reasoning but the quality of service aspects of the system are not addressed. Finally, Labidi et al. [17], worked on an ontology-based SLA project. The objective of this project is to help users to better understand the terms of the SLA as part of the monitoring of its violation. Labidi et al. [17] explain: 'We describe the cloud SLA modeling and analyzing approach that assists consumers automatically analyze terms of various SLA documents'. Their approach is based on static data. They plan to integrate the dynamic aspect in their future work: 'For future work, we opt to enhance the SLA management process by automatically predict SLA violation using context-aware systems'.

IV.1 SLA Concepts & Approach
Telemonitoring is an essential activity to not only improve the quality of life of COPD patients but also to help emergency physicians make monitoring decisions with real-time data. Today, we are experiencing the emergence of several remote monitoring systems for COPD patients. As these systems are extremely important to the health of COPD patients and the quality of care, quality of service (QoS) must be assessed (add a reference HERE). Our proposal is based on a virtual, dynamic SLA that monitors the patient context and updates the violation control interface. According to [9] the SLA is the main document to guarantee the quality of services provided by a computer system. The SLA is defined as a Service Level Agreement. It defines a service agreement between the IT service provider and the consumer of these IT services. Kritikos et al. [10] argue that an SLA comprises a set of service levels (SLs) explicating the different performance behaviors that a service can exhibit. The different activities in the life cycle of an SLA are description, matchmaking, negotiating, monitoring, assessment, settlement and archive [15]. Different languages are used to model and implement the SLA. We distinguish [9]: WSLA, WSA, WSOL, RBSLA, LUA, SLALOM, and Q-SLA. The structure of the SLA document in WSA format allows to translate the SLA document into Preprints (www.preprints.org) | NOT PEER-REVIEWED | Posted: 24 August 2020 doi:10.20944/preprints202008.0526.v1 an XML file. In this XML file, we can easily extract the data with another XML-compatible language. Our approach described in the figure 1, is based on the WSA, XML compatible language. The figure 1 describes our approach to defining dynamic control mechanisms for SLA in a COPD monitoring setting. Indeed, our approach consists of four steps described below.

a) Step1 : Extraction Data and Rules
Data extraction consists in extracting information from the COPD patient context (patient parameters) and from the SLA (metric or KPI-Targets). On the SLA side, the information is the SLA items in WSA format and the rules. On the COPD side, the information source is the real-time database. b) Step 2 and 3: Semantic Analysis The step consist in analyzing the Items, proposing the rules based on the SLA side and on the context-aware system side, the information on the vital parameters data allow to populate in real time the COPDViolationSLaOntology ontology.
Step 3: Semantic Reasoning The COPD rules and patient data will be used in the reasoning process to generate the dynamic control services and populate the adaptive and virtual template.

c) Step 4 : Control Interface
Depending on the period chosen by the user, it is possible to control the SLA monitoring in real time. It is also possible for the user to set the control period. Example every hour. Whenever the patient context changes, the control mechanisms change the information in the template.

V.2 Dynamic control Architecture for COPD diseases based on SLA
The architecture of COPD adaptive control is described in four layers. The application layer which presents the interfaces emergency doctor, patient interface, emergency reception interface and triage. For each interface, two main functionalities are presented.

V.2.1 Application Layer
The application layer provides two categories of services i) Administrator Service and ii) Functional Services for the control of the SLA. The administrator service allows the emergency physician to create or delete vital signs parameters (FIEV, SAo2, HR, Temperature) with their respective limits, triage agent profiles and COPD patient profiles in the system. The functional services for SLA monitoring are available in the different interfaces described below. The control interfaces allow to dynamically monitoring the respect of the SLA according to the period chosen by the user.
▪ Emergency Interface The emergency physician's interface allows you to view the SLA control by period, to have alerts that adapt to the patient and SLA context. Only the emergency physician can cancel the SLA.
▪ Triage Agent Interface The agent interface allows you to view SLA monitoring by period, to have incident alerts that adapt to the patient context and SLA e context. The CODP patients triage dashboard at the emergency reception desk is dynamically updated.
▪ Patient Interface The agent interface allows to view SLA monitoring by period, to have incident alerts that adapt to the patient context and SLA Patient Interface context .V.

Reasoning Layer
The reasoning engine is mainly based on rules, KPI_TARGET extracted from the SLA and income Data sensor. The reasoning process consists of 4 phases: the phase of identification of the metrics items or KPI-TARGET, the detection incident phase result from comparison of the vital data of the four parameters collected on COPD patients, the phase of implementation of the SLA violation control algorithm and the phase of SLA virtual Template. The rules concerning Key Performance Targets or metrics allow to know the metrics of the SLA and specially to know the classes, relationships and properties to which these metrics are attached. These rules are important for the SLA violation evaluation mechanism. The two metrics of the dynamic SLA violation monitoring mechanism in the context of patient COPD monitoring are: The number of incidents from patient data numberIncidentData and the number of incidents of unsuccessful patient queries numBeRequestSend. The SLA violation rules are proposed based on the definition of the concept of violation. In effect, if the number of incidents is greater than the metric defined in the KPI-Target, then there is a violation of the SLA. The rules for the SLA evaluation mechanisms are important for dynamically triggering the control of the SLA according to the data of the context-aware and the data of the SLA document in WSA format. ▪ Identification KPI-TARGETS Phase The information extracted from the SLA can be grouped into two parts: Content Items and KPI-TARGET. The KPI-TARGETs participate in the assessment or dynamic control mechanisms of the SLA. The other Content Items will populate the virtual adaptive SLA template. KPI_IncidentDataValue and KPI_IncidentRequestValue are important items for the mechanism of violation's SLA assessment.

▪ Detection Incident Rules Phase
To design these rules we consider that for every vital sign parameter, there is an interval with a minimum and a maximum value, in which the value of the sensor is considered as data incident. The Table 2 describes the different rules to detect incident data for the SLA evaluation mechanism.  ▪ SLA violation control algorithm Phase There are two approaches to the reasoning process: the data incident approach and the request incident approach. For data incidents, the reasoning is performed as soon as the following data are inserted in the dynamic database: FIEVSensorData, SAo2SensorData, HearateSensorData, TemperatureSensorData. For each data of parameters, the system checks through each rule if it is an aberrant or erroneous value. If it is an aberrant or erroneous value then it is classified as a data incident. The system increments the AlarmLevelIncrement data incident counter. Then the system compares AlarmLevelIncrement with the metric KPI_IncidentValue extracted from the SLA. If AlarmLevelIncrement>KPI_IncidentDataValue then the data quality SLA violation alarm is triggered. For request incidents, the incident counter (IncidentRequestNumber) is calculated as the difference between the number of incidents (RequestSendNumber) sent to the emergency physician by patients and the number of requests (RequestReceiveNumber) confirmed or received by the emergency physician in a period. The system then compares KPI_IncidentRequestValue extracted from the SLA to IncidentRequestNumber. If IncidentRequestNumber >KPI_IncidentRequestValue then the requested QoS SLA violation alert is triggered. All of these mechanisms are implemented in the SLA violation algorithm. This algorithm represents the core of the system's reasoning.

Figure 3: SLA Quality Service Violation Algorithm
▪ Populate Phase The populate phase consists in displaying the results of the evaluation algorithm SLA Violation to the virtual template. These results will therefore be accessible from the interface in a dynamic mode.

IV.2.1 Semantic Layer: Development of COPD Violation SLA Ontology domain
Ajami and Mcheick [18] explain that the semantic approach is a formalism often used to interpret complex information. With the protected SWRL tool, it is possible to perform queries based on concepts or classes [18]. According to Ajami and Mcheick [18]: 'Ontology is considered to be one of the richest semantic structures for facilitating the representation, integration and reasoning of knowledge'.

a) Structure of COPD Violation SLA Ontology
The figure 4 shows the core of the COPDViolationSLaOntology structure. Each component of this structure is an ontology that participates in the implementation of the dynamic evaluation mechanisms of SLA by the different parties. Each component is reusable to enrich other SLA ontologies. This structure is modular. Each module is described in detail in the following sections. This structure can be linked to the standard COPD i.e. COPD ontology from the Patient COPD Ontology component. Finally, our ontology can also be linked to the SLA Ontology from the SLA Ontology component. COPDViolationSLaOntology is therefore not an isolated structure. It is a modular ontology that is reusable and extensible with SLA Ontology Standard, COPD. The objective of this ontology in the construction of SLA control mechanisms is the dynamic collection of COPD patient data. The data come from the vital parameters Fiev, Heartrate, Sao2 and Temperature. The ObjectProperty and Datatype relationships of this ontology are described in Figure4. Only the main relationships that participate in the dynamic control mechanisms of the SLA are described in Figure 3. In the evaluation mechanism, the current value of the parameters will be compared to the Min and Max values of each row of vital parameters. The object property relationships that participate in the SLA violation evaluation mechanisms are: hasTemperatureSensorData, hasHeartRateSenSorData, hasSAO2SensorData, and hasFIEVSensorData. Indeed, these relationships allow the collection of temperature, heart rate, Oxygen Saturation and FIEV data respectively from the sensor installed on COPD patients. The collected data is evaluated according to the rules defined in the reasoning section for each defined collection time period determined by the emergency physician. During this period, if the collected data does not satisfy the rules then the reasoning engine increments the SLA violation incident counter. When the counter reaches the limited trigger threshold defined in the KPI-TARGET Data Incident then the inference engine allows the SLA violation alert to be triggered. Figure 5. COPD Patient Ontology Patient ontology is structured into two main branches: vital parameters, psychological profile parameters and patient's personal information. The vital parameters represent the core of the evaluation mechanism. The SLA control rules are mainly based on the values of these parameters. For example, if the current value of the temperature does not belong to min and max, then there is a data incident. The SLA control counter is then incremented. If the counter value is beyond the KPI-TARGET limits, then the SLA control mechanism triggers the SLA violation alert according to the period chosen by the user. All signatory actors are automatically informed. This is therefore the main ontology.

b) SLA items ontology
This ontology aims to provide information about the SLA context. For this purpose, it only addresses the description of the different Items of the SLA. The items that are mainly involved in the mechanisms of control SLA are KPI-TARGET, Services and SLO. The ObjectProperty and Dataproperty that characterize them are represented in the main table. The hasKPI_Expression_IncidentRequest and hasKPI_Expression_IncidentData relationships will identify the incident levels discussed with the various parties signing the SLA.
Indeed, the value of the data incident counter is compared to the KPI-Target defined in the SLO expression related to the data: KPI_Expression_IncidentData. The same is true for the query incident request counter value, which is also compared to the SLO expression related to the queries requests: KPI_Expression_IncidentRequest. The details of the SLA Item ontology are described in Figure 6 below.
To design the ontology, we first performed an analysis to identify the concepts that will allow better control of the violation in a COPD patient surveillance context. For this purpose, we analyzed the SLA document and the patient surveillance information in order to propose the concepts, ObjectProperty , relations and dataproperty.
Finally, these elements are entered in Protégé software for analysis and reasoning. The classes in blue color are the classes that participate in several modules. The elements in orange color are the dataproperty types. Concepts in gray are important concepts for this module Preprints (www.preprints.org) | NOT PEER-REVIEWED | Posted: 24 August 2020 doi:10.20944/preprints202008.0526.v1 Figure 6: SLA Item Ontology

a) Violation Data Concepts and Alarm Managment
The purpose of this ontology is to record violations with different time periods in relation to the data. It then provides the information to the template dynamically. The Items or concepts that mainly participate in the SLA control mechanisms are the vital, patient and violationSLaDataConcepts parameters. . The hasAlarmViolationSlaManagementProfile and IncrementAlarmLevel links will respectively associate the incident to the patient concerned and increment the incident counter to compare it to the KPI-TARGET extracted from the SLA. The hasAcquisitionRate relationship allows the emergency physician to define data collection periods. This approach makes the SLA control system more flexible. collection period with the request incident control algorithm. If there is an incident request, then an alarm is generated with the hasGenerateAlarmRequest relationship. Then the request incident counter is incremented with the relation hasIncrementAlarmLevelRequest.

Figure 8: Violation SLA Request concepts and alarm managment
The main branch of this ontology that participates in SLA control mechanisms is Request, ViolationRequest_Concepts. A Request incident occurs if the sent request has not been received by the emergency physician i.e. the status of the request is not confirmed. The difference between the number of requests sent and the number of confirmed requests in a period determines the number of Request incidents. The concept or class allows to record these incidents and to populate the virtual template dynamically according to the period.

c) Subscription to Service Monitoring COPD ontology
This ontology is not directly involved in the control mechanisms of the SLA, however it provides important information to enable the control mechanisms to function correctly and, above all, to arrange the interfaces adapted to the context. Indeed, it provides information such as the connected patient, the services concerned by the SLA. Then the dynamic interfaces with different functionalities allow controlling the SLA by selected periods. The items that mainly participate in the SLA control mechanisms are patients, service and SLA actor. The hasSubscribeSystemCOPDMonitoring relationship allows the subscription of the COPD patient, the emergency physician and triage agent. For each contract with the COPD monitoring system, a service or services are assigned to the subscribed patient. No branch of this ontology is directly involved in the control mechanisms of the SLA, but only the interfaces of the actors can make it possible to see the results of the control according to the chosen period.

IV.1.3 Acquisition Layer
The collected data refer to the parameters presented in the table below, but for the evaluation of the SLA, we focus on vital parameters only.  There are two categories of data. On the one side, there are static data: Age, BMI, Gender, Medical history. These data are available in the patient's medical records and only the emergency physician can consult them. On the other side, there are dynamic data collected from the sensors: Vital Parameters and Symptom Parameters. The data incidents for the evaluation of SLA are mainly concerned vital parameters. Decisions in a monitoring system are fundamentally based on the quality of the data. Incorrect data can influence the emergency physician's decision-making process. A wrong decision can have a negative impact on the patient's health. Evaluating the data aspects of the SLA aims to improve the quality of service. The other aspect of the SLA assessment concerns the requests transmitted to the emergency physician by the patient. A request incident occurs when a request sent by the patient has not been received by the emergency physician for any reason.

V Design of Virtual and Adaptative Template SLA
The purpose of Virtual SLA is to dynamically monitor quality of service (QoS) guarantees of SLA in a COPD patient monitoring context. This template has two parts. Part 1 represents the offered service that has been validated by the parties. If the data of the Part 1 is changed the Virtual template will also be modified in real time. In addition, Part 2 presents the dynamic control elements of the SLA. This part adapts dynamically according to the data of the patient context and the context-aware ubiquitous system. Finally, the information described in these two parts is extracted from the ontology presented in the previous sections. To allow a better understanding of the Virtual SLA template, important concepts are presented. According to the literature [17], the SLA template must have important information: SLO, KPI-TARGETS, CONDITION the agreement. Concerning the SLO, Labidi et al. [17]

VI. CONCLUSION
At the end of this research project, several contributions can be noted. One of the major contributions is that, however large or small volume of data manipulated by the COPD monitoring platforms, our SLA violation control mechanism allows us to monitor the quality of the data and thus allow the ER physician to improve the quality of service provided to COPD patients. . Firstly, our solution allows the dynamic evaluation of the SLA by extracting relevant data from the SLA Documents and extracting dynamic data from the patient COPD to populate an SLA violation control ontology. Second, our solution provides Virtual and Adaptive SLA for SLA violation prevention. Thirdly, Virtual SLA is accessible to all SLA stakeholders from their context-aware application-based interface. Finally, the implementation of SLA in health monitoring systems in general and COPD patients' health particularly, is a big step forward. Indeed, physicians will now be able to monitor the quality of service and make quality decisions. Patients will also feel even safer and this contributes to improving their quality of life. In the future experimental article, the proposed model will use this algorithm and rules (SWRL) to populate, dynamically the virtual SLA presented in the previous sections.