From the Real Vehicle to the Virtual Vehiclecpcc.berkeley.edu/papers/VV.pdf · Our scheduling...

16
From the Real Vehicle to the Virtual Vehicle Jiangchuan Huang Systems Engineering Group Univ. of California, Berkeley Email: [email protected] Christoph M. Kirsch Dept. of Computer Sciences Univ. of Salzburg, Austria Email: [email protected] Raja Sengupta Systems Engineering Group Univ. of California, Berkeley Email: [email protected] Abstract—We apply virtual machine abstractions to net- worked autonomous vehicles enabling what we call cloud comput- ing in space. In analogy to traditional system virtualization and cloud computing, there are (customer-operated) virtual vehicles that essentially perform like real vehicles although they are hosted by possibly fewer, shared (provider-operated) real vehicles. Here the focus is, however, on motion rather than computation. In the service-level agreement, a virtual vehicle is a virtual machine plus a virtual speed. We define virtual deadline for each task based on virtual speed, and make the spatial cloud a soft real-time system [7], [1]. The performance isolation is measured by the average of tardiness and delivery probability. We use Voronoi tessellation to allocate the tasks to the real vehicles, and design scheduling policies such as Earliest Virtual Deadline First (EVDF), Earliest Dynamic Virtual Deadline First (EDVDF) and credit scheduling policy for the real vehicles. EVDF is shown to minimize the tardiness. Under EVDF, we identify a worst case arrival process maximizing tardiness. We show in simulation that abstracting real vehicles such as cars or planes to virtual vehicles enables virtual vehicles to move in space like real vehicles with guaranteed tardiness (e.g. 1%) while being hosted by significantly fewer, e.g. 1-for-7.5, shared real vehicles. I. I NTRODUCTION Consider the following systems with tasks arriving in time and space: (i) Google Street View, Google is running numerous data-collection vehicles with mounted cameras, lasers, a GPS and several computers to collect street views while minimizing the distance travelled [3]. (ii) Real-time traffic reporting, a radio station uses a helicopter to overfly accident scenes and other areas of high traffic volume for real-time traffic infor- mation. (iii) Unmanned aerial vehicle (UAV)-based sensing, a fleet of UAVs equipped with greenhouse gas sensors collect airborne measurements of greenhouse gases at several sites in California and Nevada, executing every task at its location before its deadline [19]. (iv) Enabling mobility in wireless sensor networks (WSN), mobile elements (vehicles) capable of short-range communications collect data from nearby sensor nodes as they approach on a schedule [36]. In these applications, a task is a triple (T a ,X,T S ) where T a is the arrival time of the task, X its location in space, and T S its execution time (task size). Servers, henceforth referred to as real vehicles, are networked vehicles each having all or some of the sensing, computation, communication, and locomotion capabilities. A real vehicle is considered to serve a task by visiting the location X and staying there for execution time T S after the task has arrived, i.e., after time T a . The Research supported in part by the National Science Foundation (CNS1136141) and by the National Research Network RiSE on Rigorous Systems Engineering (Austrian Science Fund S11404-N23). performance metrics include system time (latency), throughput, delivery probability, and total distance traveled by the vehicles. Traditionally, these applications were modeled by (i) the vehicle routing problem (VRP) [13], its variations such as (ii) the Dynamic Travelling Repairman Problem (DTRP) [5], (iii) the stochastic and dynamic vehicle routing problem with time windows (SDVRPTW) [29], and (iv) the mobile element scheduling (MES) problem [36]. Tasks are allocated and sequenced based on their arrival times T a , e.g., first come first served (FCFS) [5], locations X, e.g., nearest neighbor (NN) [5], and sizes T S , e.g., shortest job first [38], to minimize the distance traveled [13], the average time each task spent in the system [5], or the deadline violation ratio [29]. A richer set of scheduling policies include direct tree search, dynamic programming, and integer linear programming for VRP [24]; FCFS, stochastic queue median (SQM), travelling salesman policy (TSP), NN [5], divide and conquer [30] for DTRP and SDVRPTW [29]; earliest deadline first, earliest deadline first with k-lookahead, the minimum weight sum first [36] and partition based scheduling [14] for MES. While the current scheduling policies work for the single customer systems, they do not create performance isolation in multi- customer systems. In the VRP tasks from different customers are indistinguishable to the scheduling policies, meaning a customer submitting more tasks would use more resources, possibly to the detriment of other customers. To resolve this problem, we formulate the multi-customer VRP by borrowing the concept of a virtual machine from cloud computing. In cloud computing, the virtual machine abstraction creates performance isolation so that resources consumed by one virtual machine do not necessarily harm the performance of other virtual machines [34]. To extend the idea of the virtual machine [34] used in cloud computing, we define an idea called the virtual vehicle. The virtual vehicle is an analog of the virtual machine for location specific computing tasks. Just as the cloud computing customer has a service-level agreement (SLA) for a virtual machine, our customer would have an SLA for a virtual vehicle. To a customer, a virtual vehicle is exactly like a real vehicle that travels at the virtual speed specified in the SLA. For example, suppose a radio station (the customer) uses a helicopter to overfly accident scenes (the task) at 100 mile per hour (mph) for real-time traffic reporting. Such a helicopter would arrive at an accident scene 10 miles away in 6 minutes. We now virtualize this helicopter. Instead of buying or renting, and operating a real helicopter, the radio station would buy a virtual helicopter that travels at 100 mph using an SLA. Our spatial cloud would then take responsibility for flying some real helicopter to the accident site in 6 minutes or some near approximation to this

Transcript of From the Real Vehicle to the Virtual Vehiclecpcc.berkeley.edu/papers/VV.pdf · Our scheduling...

Page 1: From the Real Vehicle to the Virtual Vehiclecpcc.berkeley.edu/papers/VV.pdf · Our scheduling algorithms are designed to have the real vehicles travel to and execute each task such

From the Real Vehicle to the Virtual Vehicle

Jiangchuan HuangSystems Engineering GroupUniv. of California, Berkeley

Email: [email protected]

Christoph M. KirschDept. of Computer SciencesUniv. of Salzburg, Austria

Email: [email protected]

Raja SenguptaSystems Engineering GroupUniv. of California, Berkeley

Email: [email protected]

Abstract—We apply virtual machine abstractions to net-worked autonomous vehicles enabling what we call cloud comput-ing in space. In analogy to traditional system virtualization andcloud computing, there are (customer-operated) virtual vehiclesthat essentially perform like real vehicles although they are hostedby possibly fewer, shared (provider-operated) real vehicles. Herethe focus is, however, on motion rather than computation. In theservice-level agreement, a virtual vehicle is a virtual machine plusa virtual speed. We define virtual deadline for each task based onvirtual speed, and make the spatial cloud a soft real-time system[7], [1]. The performance isolation is measured by the averageof tardiness and delivery probability. We use Voronoi tessellationto allocate the tasks to the real vehicles, and design schedulingpolicies such as Earliest Virtual Deadline First (EVDF), EarliestDynamic Virtual Deadline First (EDVDF) and credit schedulingpolicy for the real vehicles. EVDF is shown to minimize thetardiness. Under EVDF, we identify a worst case arrival processmaximizing tardiness. We show in simulation that abstractingreal vehicles such as cars or planes to virtual vehicles enablesvirtual vehicles to move in space like real vehicles with guaranteedtardiness (e.g. ≤ 1%) while being hosted by significantly fewer,e.g. 1-for-7.5, shared real vehicles.

I. INTRODUCTION

Consider the following systems with tasks arriving in timeand space: (i) Google Street View, Google is running numerousdata-collection vehicles with mounted cameras, lasers, a GPSand several computers to collect street views while minimizingthe distance travelled [3]. (ii) Real-time traffic reporting, aradio station uses a helicopter to overfly accident scenes andother areas of high traffic volume for real-time traffic infor-mation. (iii) Unmanned aerial vehicle (UAV)-based sensing, afleet of UAVs equipped with greenhouse gas sensors collectairborne measurements of greenhouse gases at several sitesin California and Nevada, executing every task at its locationbefore its deadline [19]. (iv) Enabling mobility in wirelesssensor networks (WSN), mobile elements (vehicles) capableof short-range communications collect data from nearby sensornodes as they approach on a schedule [36].

In these applications, a task is a triple (T a, X, TS) whereT a is the arrival time of the task, X its location in space,and TS its execution time (task size). Servers, henceforthreferred to as real vehicles, are networked vehicles each havingall or some of the sensing, computation, communication, andlocomotion capabilities. A real vehicle is considered to serve atask by visiting the location X and staying there for executiontime TS after the task has arrived, i.e., after time T a. The

Research supported in part by the National Science Foundation(CNS1136141) and by the National Research Network RiSE on RigorousSystems Engineering (Austrian Science Fund S11404-N23).

performance metrics include system time (latency), throughput,delivery probability, and total distance traveled by the vehicles.

Traditionally, these applications were modeled by (i) thevehicle routing problem (VRP) [13], its variations such as(ii) the Dynamic Travelling Repairman Problem (DTRP) [5],(iii) the stochastic and dynamic vehicle routing problem withtime windows (SDVRPTW) [29], and (iv) the mobile elementscheduling (MES) problem [36]. Tasks are allocated andsequenced based on their arrival times T a, e.g., first come firstserved (FCFS) [5], locations X , e.g., nearest neighbor (NN)[5], and sizes TS , e.g., shortest job first [38], to minimizethe distance traveled [13], the average time each task spentin the system [5], or the deadline violation ratio [29]. Aricher set of scheduling policies include direct tree search,dynamic programming, and integer linear programming forVRP [24]; FCFS, stochastic queue median (SQM), travellingsalesman policy (TSP), NN [5], divide and conquer [30] forDTRP and SDVRPTW [29]; earliest deadline first, earliestdeadline first with k-lookahead, the minimum weight sumfirst [36] and partition based scheduling [14] for MES. Whilethe current scheduling policies work for the single customersystems, they do not create performance isolation in multi-customer systems. In the VRP tasks from different customersare indistinguishable to the scheduling policies, meaning acustomer submitting more tasks would use more resources,possibly to the detriment of other customers.

To resolve this problem, we formulate the multi-customerVRP by borrowing the concept of a virtual machine fromcloud computing. In cloud computing, the virtual machineabstraction creates performance isolation so that resourcesconsumed by one virtual machine do not necessarily harm theperformance of other virtual machines [34]. To extend the ideaof the virtual machine [34] used in cloud computing, we definean idea called the virtual vehicle. The virtual vehicle is ananalog of the virtual machine for location specific computingtasks. Just as the cloud computing customer has a service-levelagreement (SLA) for a virtual machine, our customer wouldhave an SLA for a virtual vehicle. To a customer, a virtualvehicle is exactly like a real vehicle that travels at the virtualspeed specified in the SLA. For example, suppose a radiostation (the customer) uses a helicopter to overfly accidentscenes (the task) at 100 mile per hour (mph) for real-timetraffic reporting. Such a helicopter would arrive at an accidentscene 10 miles away in 6 minutes. We now virtualize thishelicopter. Instead of buying or renting, and operating a realhelicopter, the radio station would buy a virtual helicopter thattravels at 100 mph using an SLA. Our spatial cloud wouldthen take responsibility for flying some real helicopter to theaccident site in 6 minutes or some near approximation to this

Page 2: From the Real Vehicle to the Virtual Vehiclecpcc.berkeley.edu/papers/VV.pdf · Our scheduling algorithms are designed to have the real vehicles travel to and execute each task such

time. The radio station can estimate the completion time ofeach task by dividing the consecutive distances between tasksby the virtual speed just as they did for their real helicopterbefore. The task completion time expected by the radio station(customer) is given by (4) in Section II. The radio stationwould enjoy the advantage of reserving the virtual helicopteronly when the traffic reporting program is on, and not payingfor other times. If the real helicopters executing the virtualhelicopters could serve other customers at these other times,the enhanced vehicle utilization would reduce costs for allcustomers much like cloud computing. The analysis in thispaper quantifies these gains.

Our scheduling algorithms are designed to have the realvehicles travel to and execute each task such that the realcompletion time is no later than the expected completiontime. The system achieves high performance isolation if astatistically dominant subset [32], e.g., 98%, of the virtualvehicle’s tasks are completed no later than their expectedcompletion times. The fraction must be small enough forthe customer to consider herself adequately compensated forthis loss by the reduced costs delivered by the spatial cloud.We design the spatial cloud to treat the expected completiontime as a “deadline” and call it the virtual deadline. Thevirtual deadlines make the spatial cloud a soft real-time system[7], [1], meaning performance metrics such as tardiness anddelivery probability defined in (5) and (6) can be used tomeasure performance isolation. These performance metrics arethe performance isolation measures [39] and Jain’s fairnessindices [18] defined separately in (12) and (13), and in (14)and (15) in Section II. The slack defined in (7) measures theearliness of a task completion. How the provider realizes thevirtual deadlines of the tasks is of no concern to the customer.For example, the provider can use a real vehicle to travel toand execute a task as the virtual vehicle does, or migrate theinformation of the virtual vehicle through a network to anotherreal vehicle closer to the task. In the latter case, the realdistance traveled is smaller than the virtual distance resultingin the phenomenon we have called migration gain. The ideaworks when the communication costs of migrating a virtualvehicle over the network are small. The migration cost of avirtual vehicle is defined in (11).

We proposed cloud computing in space as a concept thatmakes sensing a service in [11] and described our work onthe software engineering required to build a virtual vehicle.The protocols required for migration are described in [23].The results of this paper show that the provider can support agiven number of virtual vehicles with significantly fewer realvehicles that travel at the virtual speed while guaranteeing highperformance isolation. We quantify the gain by the ratio of thenumber of virtual vehicles over the number of real vehicles.The gain arises from two phenomena. (i) A customer maynot fully utilize her virtual vehicle, enabling the spatial cloudto multiplex several virtual vehicles onto one real vehicle.This type of gain is called multiplexing gain. It is known incommunication networks [16] and cloud computing [33]. (ii)The real vehicles save travel distance by migrating the virtualvehicle hosting a task to another real vehicle closer to thetask, creating migration gain. This paper focuses on migrationgain since it is unique to this spatial cloud. We use a verysimple model of the task size TS itself since we focus onthe migration gain arising from the spatial distribution of the

tasks. Migration gain is the reason spatial cloud computingoutperforms conventional cloud computing.

We analyze the system in Section III using results inqueueing theory [10], [2], stochastic and dynamic vehiclerouting [5], [30], [17], and soft real-time systems [7], [1].Figure 1 depicts the GI/GI/1 queue [10] of each virtualvehicle (Theorem 1), and the ΣGI/GI/1 queue [2] of eachreal vehicle (Theorem 2) under the Voronoi tessellation [28]in Definition 1. We propose scheduling policies adapted fromconventional cloud computing [8], named Earliest VirtualDeadline First (EVDF) when task size is known a priori(Definition 5), its variation Earliest Dynamic Virtual DeadlineFirst (EDVDF) when task size is not known a priori (Definition6), and the credit scheduling policy (Definition 7) in SectionIV. Theorem 3 asserts that EVDF minimizes tardiness. Thisis based on the optimality of earliest deadline first schedulingfor real-time queues [27]. Theorem 4 identifies a worst-casearrival process maximizing tardiness called the η = 1 arrivalprocess in Definition 8. Theorem 5 asserts task size dependenteconomy of scale [26] in the sense that the largest achievablegain without compromising performance isolation increases asthe square root of the number of real vehicles when the tasksize is zero, and increases but is upper bounded by a constantwhen the task size is greater than zero. Theorem 6 bounds themigration cost. Theorem 7 bounds the slack under the η = 1arrival process.

We simulate the system with homogeneous real vehicles(Definition 3) and homogeneous virtual vehicles (Definition4) under the EVDF, EDVDF and credit scheduling policiesin Section V. Each virtual vehicle generates an η = 1 arrivalprocess that maximizes tardiness, and excludes multiplexinggain by having each virtual vehicle fully utilized. Thus, thisis a worst-case simulation and the gain is migration gain only.Figure 4 shows the performance isolation and fairness indexbased on tardiness and delivery probability, together with slackand migration costs under the EVDF for different numbersof real vehicles and gains and different number of virtualvehicles. We conclude that (i) the provider can support agiven number of virtual vehicles with significantly fewer realvehicles that travel at the virtual speed while guaranteeinghigh performance isolation, e.g., the gain equals 7.5 whileguaranteeing tardiness ≤ 1% when the number of real vehiclesis 100 as shown in Figure 5. (ii) The migration gain increaseswith the number of real vehicles while guaranteeing the sameperformance isolation as shown in Figure 5, and asserted inTheorem 5. (iii) The migration cost is bounded (Figure 4).(iv) The virtual vehicle concept works best when the tasksizes are small and the vehicle spends more time travelingto tasks than it does loitering or standing still. As the virtualvehicles spend more time standing still, cloud computing inspace converges to conventional cloud computing as shown inFigure 6. (v) The provider can easily determine the appropriatenumber of real vehicles for a given number of virtual vehiclesand a guaranteed performance isolation because the transitionbetween low and high performance isolation is sharp as shownin Figure 7. (vi) EVDF has better performance than EDVDF,and EDVDF has better performance than the credit schedulingpolicy as shown in Figure 8.

Page 3: From the Real Vehicle to the Virtual Vehiclecpcc.berkeley.edu/papers/VV.pdf · Our scheduling algorithms are designed to have the real vehicles travel to and execute each task such

II. MODEL

The spatial cloud is defined as follows: A service providercontrols M ∈ N real vehicles (RVs), RVmMm=1, in a convexregion A of area A to host K ∈ N virtual vehicles (VVs),V VkKk=1. Each RV travels at constant speed vR. Each VVhas virtual speed vV in the service-level agreement.

To a customer, a virtual vehicle with speed vV is a replicaof a real vehicle with speed vV . It can be reserved to hosta sequence of tasks 〈Taskki〉∞i=1, where k denotes the k-thVV and i the i-th task hosted by it. Each Taskki has arrivaltimes T aki, location Xki, and size TSki. 〈Taskki〉 is orderedby the arrival time T aki. The sequences of tasks hosted bydifferent VVs are independent of each other, i.e., Taskki areindependent in k.

Each task arrival process T aki∞i=1 is assumed to be a

renewal process. Thus the interarrival time, Iaki ≡ T aki−T ak(i−1)is independent and identically distributed (i.i.d.) in i, whereT ak0 ≡ 0. The generic interarrival time Iak is assumed to beintegrable. Thus the task arrival rate of each VV is

λVk =1

E [Iak ](1)

Xki is i.i.d. in k and i, and uniformly distributed in A withprobability density function (pdf) fX(x) = 1

A , x ∈ A. Thetask size TSki is i.i.d. in k and i with pdf fTS (t), t ∈ [0,∞).We denote by TS the generic term of TSki. Then E

[TSki]

=E[TS], which is assumed to be finite.

Let Lki denote the distance between Taskk(i−1) andTaskki hosted by V Vk. Then

Lki =‖ Xki −Xk(i−1) ‖ (2)

where ‖ . ‖ is the Euclidean norm defined on region A, i =1, 2, . . .. Xk0 is the initial position of the first RV hostingV Vk given by the provider, which is assumed to be uniformlydistributed in A, and independent of Xki. From (2) we knowLki is i.i.d. in k and i. We thus denote by L the generic termof Lki.

V Vk is assumed to serve the sequence of tasks 〈Taskki〉∞i=1under the first come first served (FCFS) policy. It travels tothe location Xki of each task and executes it taking time TSki.Then the virtual service time of Taskki, denoted by TV servki ,includes the flying time and execution time as follows

TV servki =LkivV

+ TSki (3)

Thus TV servki is i.i.d. in k and i. We denote by TV serv thegeneric term of TV servki .

Each V Vk is a queue. The virtual departure time of Taskkifrom this queue is

T deadki = maxT aki, T

deadk(i−1)

+ TV servki (4)

where T deadk0 ≡ 0. We use the superscript dead for deadlinebecause this virtual departure time is used by our schedulingpolicies as a task deadline.

Each task, upon arrival, is passed to one of the M realvehicles. Thus we have M real vehicle queues. Each Taskkiis served by some real vehicle RVm as per an allocation policygiven in Definition 1 in Section III-B. The order of service isdetermined by a scheduling policy. The scheduling policies,discussed in Section IV, are the main subject of this chapter.

Each Taskki will be completed by an RV at some timeT compki . We assume customer k will be satisfied if T compki ≤T deadki . Then the aim of the provider is to achieve T compki ≤T deadki for as many tasks as possible. Thus T deadki is like a“deadline” for Taskki. We call the T deadki the virtual deadlinefor Taskki. This makes the spatial cloud a soft real-timesystem [7], [1].

We define the relative expected tardiness of V Vk as

TDk =1

E [TV serv]limn→∞

∑ni=1 max

T compki − T deadki , 0

n

(5)

The delivery probability of V Vk is

DPk = limn→∞

∑ni=1 1

T compki ≤ T deadki

n

(6)

where 1Ω is the indicator function defined as 1Ω = 1 ifΩ is true, and = 0 otherwise.

The relative expected slack of V Vk is

SLk =1

E [TV serv]limn→∞

∑ni=1 max

T deadki − T compki , 0

n

(7)

We define the virtual system time of Taskki as TV syski =

T deadki − T aki, and the real system time of Taskki as TRsyski =

T compki − T aki. Thus T compki − T deadki = TRsyski − TV syski , andT compki ≤ T deadki ⇔ TRsyski ≤ TV syski . When the queue at V Vkis stable, TV syski → TV sysk in distribution. When the M realvehicle queues are stable, TV syski → TV sysk in distribution.

Thus (5) is equivalent to

TDk =E[max

TRsysk − TV sysk , 0

]E [TV serv]

(8)

(6) is equivalent to

DPk = P(TRsysk ≤ TV sysk

)(9)

(7) is equivalent to

SLk =E[max

TV sysk − TRsysk , 0

]E [TV serv]

(10)

These three measures are determined by the virtual vehiclequeues and the real vehicle queues as shown in Section III.

Two consecutive tasks of an VV might be executed bytwo different RVs, which involves migrating the VV from onevirtual vehicle to another. Let Zki be an indicator set to 1 ifthere is a migration between Taskk(i−1) and Taskki, and 0otherwise. When the M real vehicle queues are stable, Zki →Zk in distribution. BV k is the number of bits to migrate V Vk

Page 4: From the Real Vehicle to the Virtual Vehiclecpcc.berkeley.edu/papers/VV.pdf · Our scheduling algorithms are designed to have the real vehicles travel to and execute each task such

Tcomp(11) Tcomp(12) Tcomp(13)!

Tcomp(m1) Tcomp(m2) Tcomp(m3)!

Ta11! Ta12! Ta13!

Tdead11 Tdead12 Tdead13!

VV1#GI/GI/1#

Ta(11)! Ta(12)! Ta(13)!

RV1#ΣGI/GI/1#

t!

t!

Tak1! Tak2! Tak3!

VVk"GI/GI/1# t!

TaK1!TaK2! TaK3!

VVK"GI/GI/1# t!

Ta(m1)! Ta(m2)! Ta(m3)!

RVm"ΣGI/GI/1# t!

Ta(M1)! Ta(M1)! Ta(M1)!

RVM"ΣGI/GI/1# t!

Voronoi##Alloca1on#

Tdeadk1 Tdeadk2 Tdeadk3!

TdeadK1 TdeadK2 TdeadK3!

Tdead(11) Tdead(12) Tdead(13)!

Tdead(m1) Tdead(m2) Tdead(m3)!

Tdead(M1) Tdead(M2) Tdead(M3)! Tcomp(M1) Tcomp(M2) Tcomp(M3)!

Fig. 1. The spatial cloud with virtual vehicle queues and real vehicle queues.

at the migration time. We assume BV k = 1 or equivalently aconstant. L is the generic distance between two consecutivetasks. We define the inter-virtual deadline time as Ideadki =T deadki −T deadk(i−1). Since TV servki is i.i.d. in k and i, then Ideadki →Ideadk in distribution. The migration cost of V Vk is

MCk = BV kE [ZkL]

E[Ideadk

] (11)

The migration cost has the same unit (bit-meters/second) as in[15].

A. Performance Isolation

We measure performance isolation by the average of thetardiness and delivery probability.

TD =1

K

K∑k=1

TDk (12)

TD = 0 implies TDk = 0 for all virtual vehicle k, meaningthe system achieves perfect performance isolation. ConverselyTD →∞ means the relative expected tardiness of some VVsis unbounded, the system has very poor performance isolation.

DP =1

K

K∑k=1

DPk (13)

DP = 1 implies DPk = 1 for all virtual vehicle k, meaningthe system achieves perfect performance isolation. ConverselyDP = 0 means the delivery probability of each virtual vehicleis zero, meaning the system has no performance isolation.

Fairness is the equality of work divided among differentconcurrent environments [6]. We use Jain’s fairness index [18]to quantify the fairness between virtual vehicles. The fairnessindex based on tardiness TDk is

FI (TDk) =

(∑Kk=1 e

−TDk)2

K∑Kk=1 (e−TDk)

2(14)

where we use e−TDk to map TDk from [0,∞) to (0, 1], thelower TDk, the higher e−TDk , indicating higher performance.

The fairness index based on delivery probability DPk is

FI (DPk) =

(∑Kk=1DPk

)2

K∑Kk=1DP

2k

(15)

Jain’s fairness index is the ratio of the square of the firstmoment over the second moment of the set of performancemetrics of all the VVs. If TDk = TDl > 0 (resp. DPk =DPl > 0), ∀k, l, then FI (TDk) = 1 (resp. FI (DPk) = 1),indicating completely fair. If TDk > 0 and TDl = 0 (resp.DPk > 0 and DPl = 0), ∀l 6= k, then FI (TDk) = 1

K(resp. FI (DPk) = 1

K ), indicating completely unfair. ThusFI (TDk) (resp. FI (DPk)) ranges between 1

K and 1. Thegreater the fairness index, the more fair the system. Jain’sfairness index has been used to evaluate virtualization systems[40], [20], [4]. Other performance metrics in this literatureinclude throughput, latency and response time.

B. Gain

When a provider supports K virtual vehicles with M realvehicles we define the gain κ to be

κ =K

M(16)

The provider gains if κ > 1. There are two ways a providercan gain:

• Multiplexing gain: a customer may not utilize hervirtual vehicle fully, enabling the provider to multiplexseveral virtual vehicles onto one real vehicle.

• Migration gain: the provider gains by migrating theVV hosting the task to another RV closer to the tasklocation.

The multiplexing gain is observed in communication networks[16] and cloud computing [33]. Migration gain is unique to

Page 5: From the Real Vehicle to the Virtual Vehiclecpcc.berkeley.edu/papers/VV.pdf · Our scheduling algorithms are designed to have the real vehicles travel to and execute each task such

cloud computing in space. When every virtual vehicles arefully utilized, there is no multiplexing gain, but there is stillmigration gain.

III. SYSTEMS

The system has queues at the virtual vehicles and queuesat the real vehicles as depicted in Figure 1.

A. Virtual Vehicle Queues

The task arrival rate for V Vk is λVk = 1

E[Iak ]by (1), where

Iak is the generic interarrival time of V Vk. The service timeTV servki is i.i.d. in k and i with generic term TV servk . We definethe generic virtual vehicle service rate as

µV =1

E [TV serv]=

1E[L]vV

+ E [TS ](17)

as usual, with TV servki defined in (3).

The random process at the output of V Vk is the virtualdeadline process

T deadki

∞i=1

. The virtual deadline rate isdefined as

λV deadk = limi→∞

1

E[T deadki − T deadk(i−1)

] (18)

Since V Vk is a work-conserving server, it is busy if it hasa queue and idle if not. Thus V Vk repeats cycles of busy andidle periods. We define ΘV

kl as the l-th busy period and IVkl asthe l-th idle period. We define virtual vehicle utilization as

uVk = liml→∞

E[ΘVkl

]E[ΘVkl

]+ E

[IVkl] (19)

A single server queuing system is GI/GI/1 if the interar-rival times at the input and the service times are positive i.i.d.random variables, separately [10].

The tasks created by a customer are passed to the cloudat the rate chosen by the customer. The following theoremasserts that when the arrival rate is less than the service rate, thevirtual deadline rate is equal to the arrival rate. However, if thecustomer exceeds the service rate determined by the contractedvirtual speed, the virtual deadline rate is equal to the servicerate, i.e., the contract throttles the customer’s virtual deadlinerate. A higher virtual deadline rate requires more tasks to becompleted in a unit time. A customer cannot require more thanher share of resources by simply generating tasks faster andfaster because the virtual deadline rate is throttled by the VVservice rate.

Theorem 1: Each virtual vehicle V Vk is a GI/GI/1queue. Moreover,If λVk < µV , then uVk < 1 and λV deadk = λVk .If λVk ≥ µV , then uVk = 1 and λV deadk = µV .

Proof: By assumption the task arrival process of V Vkis renewal. Thus the interarrival times are positive and i.i.d..Also the service times TV servki are positive and i.i.d.. Thus eachvirtual vehicle V Vk is a GI/GI/1 queue.

(i) When λVk < µV , the GI/GI/1 queue is stable byTheorem 1.1 in [10, p. 168]. The number of tasks waiting

in the queue is finite almost surely, the mean interdeparturetime E

[T deadki − T deadk(i−1)

]of the VV is 1

λVkbecause no tasks

are lost and no extra task is created. Thus λV deadk = λVk .Stability also ensures that liml→∞E

[ΘVkl

]= E

[ΘVk

]and

liml→∞E[IVkl]

= E[IVk], where ΘV

k and IVk are the genericbusy period and idle period. Thus uVk =

E[ΘVk ]

E[ΘVk ]+E[IVk ]. Ac-

cording to [37, p. 21], uVk =λVkµV

since no tasks are lost or

created in the system. Thus uVk =λVkµV

< 1.

(ii) When λVk > µV , the GI/GI/1 queue is unstable byTheorem 1.1 in [10, p. 168], the number of tasks waiting inthe queue goes to infinity as time goes to infinity. The busyperiod tends to infinity and the idle period tends to 0, Thus

uVk = liml→∞E[ΘVkl]

E[ΘVkl]+E[IVkl]= 1, and the interdeparture time

equals the VV service time. Then λV deadk = µV .

(iii) When λVk = µV , the number of tasks waiting in thequeue can either be finite, or goes to infinity as time goes toinfinity depending on the arrival process T aki. So this caseeither goes to case (i) or (ii). In either case, we have uVk = 1and λV deadk = µV .

When λVk > µV , the GI/GI/1 queue at V Vk is unstable,thus the virtual system time TV syski = T deadki − T aki → ∞almost surely [10, p. 168]. Since the customer regards a VV areplica of an RV, we assume the customer will never run theVV under the unstable condition. Thus we assume λVk ≤ µV

from now on. Also, when λVk = µV , we assume the customeronly provide task arrival process that results in finite virtualsystem time, i.e., TV syski → TV sysk in distribution.

B. Real Vehicle Queues

Each task, upon arrival, is passed to one of the M realvehicles. Inside each RV subregion, the RV runs a schedulingpolicy to decide which task of which VV to execute when theRV becomes available. The scheduling policies are discussedin Section IV. We allocate the tasks hosted by each VV asfollows.

Definition 1: The VV allocation has the following steps:

(i) Divide the region A into M subregions by computingan M -median of A that induces a Voronoi tessellation thatis equitable with respect to fX(x) following [28]. An M -partition AmMm=1 is equitable with respect to fX(x) if∫Am

fX(x) dx = 1M for all m ∈ 1, . . . ,M.

(ii) The real vehicles assign themselves to the subregionsin a one-to-one manner.

(iii) Each RV serves the tasks that fall within its own sub-region according to some scheduling policy. The VV hostingthe task is migrated to the RV prior to task execution if theprevious task was served by another RV. This migration incursthe cost quantified in (11).

We sequence the tasks contributed by all the virtual ve-hicles to subregion Am by their arrival times. The sequenceis denoted 〈Task(mj)〉∞j=1. Thus Task(mj) is the j-th taskarrived at real vehicle m. Note each Task(mj) correspondsto some Taskki hosted by a virtual vehicle k at time T aki.

Page 6: From the Real Vehicle to the Virtual Vehiclecpcc.berkeley.edu/papers/VV.pdf · Our scheduling algorithms are designed to have the real vehicles travel to and execute each task such

Task(mj) has arrival time T a(mj) = T aki, location X(mj) =

Xki and size TS(mj) = TSki. Note T a(m(j−1)) ≤ T a(mj) andX(mj) ∈ Am by construction. We write Task(mj) if the taskis labeled according to the RV, and write Taskki if the taskis labeled according to the VV. For the different labels of thesame task, Taskki and Task(mj), since T ak(i−1) ≤ T aki andT a(m(j−1)) ≤ T

a(mj), then

i→∞⇔ T aki →∞⇔ T a(mj) →∞⇔ j →∞ (20)

Since the task locations Xki are i.i.d. in k and i, anduniformly distributed in region A, then X(mj) are i.i.d. in jand uniformly distributed in each subregion Am. We denoteby D(m) the distances between two random task locations insubregion Am. Thus,

D(m) =‖ X(mj) −X(ml) ‖ (21)

where X(mj) and X(ml) are two random task locations insubregion Am.

Let D(mj) denote the distance between Task(mj) andthe task executed before it under a scheduling policy φ insubregion Am. In general, D(mj) is policy dependent. Wedefine a class of policies that produce i.i.d. D(mj) as follows.

Definition 2: A scheduling policy φ in a real vehiclesubregion Am is called non-location based if the distancebetween two consecutively executed tasks is i.i.d..

The common policies in queueing theory such as FCFS,last come first served (LCFS), random order of service (ROS),and shortest job first (SJF) [38] are non-location based policiesin the sense of Definition 2. The scheduling policies wepropose in Section IV such as Earliest Virtual Deadline First(EVDF), Earliest Dynamic Virtual Deadline First (EDVDF)and credit scheduling policy are shown to satisfy Definition 2in Theorem 3.

The scheduling policies that utilize the location of the taskssuch as nearest neighbor (NN) and traveling salesman policy(TSP) on a given set of tasks are not non-location basedbecause the distances between two consecutively executedtasks are not independent.

Definition 3: The set of M real vehicle subregionsAmMm=1 are said to be homogeneous if they all have thesame scheduling policy, and D(m) is i.i.d. for all m =1, . . . ,M .

In this section and next, we only consider the homogeneousRV subregions under non-location based scheduling policies.We denote by D the generic term of D(m). Then D(mj) isi.i.d. in m and j, and has the same distribution as D.

The service time of Task(mj) by RVm, denoted by TRserv(mj) ,is

TRserv(mj) =D(mj)

vR+ TS(mj) (22)

Since D(mj) and TS(mj) are i.i.d. in m and j, separately,then TRserv(mj) is i.i.d. in m and j. We denote by TRserv thegeneric term of TRserv(mj) , and define the generic real vehicle

service rate µR as

µR =1

E [TRserv]=

1E[D]vR

+ E [TS ](23)

We define

κc =µR

µV=

E[L]vV

+ E[TS]

E[D]vR

+ E [TS ](24)

Before analyzing the queues at the real vehicles, we listsome of the basic results of the thinning and superposition ofstochastic processes for convenience below.

(i) Example 4.3(a) in [12, pp. 75-76], thinning of renewalprocesses: Given a renewal process Sn with rate λ, let eachpoint Sn for n = 1, 2, . . . be omitted from the sequence withprobability 1 − p and retained with probability p for someconstant p in 0 < p < 1, each such point Sn being treatedindependently. The sequence of retained points, denoted bySpn, is called the thinned process with retaining probabilityp. Then Spn is also renewal with rate pλ.

(ii) From [21, Section 14], we know the following propo-sition for the superposition of independent, stationary pro-cesses. Let Nk(t) be a stationary process with rate λk, thenthe superposition of K such independent processes N(t) =∑Kk=1Nk(t) is also stationary with rate λ =

∑Kk=1 λk.

(iii) Two stationary stochastic processes are said to beprobabilistic replicas of each other if their generic interarrivaltimes are identically distributed [37, p. 21].

The following theorem asserts the queueing systems ateach real vehicle is ΣGI/GI/1 [2] under non-location basedpolicies. This means the arrival process at each real vehicle isthe superposition of independent renewal processes and theservice time process has positive i.i.d. interarrival times. Italso establishes the critical role of κc in stability of thesequeues under the assumption that every customer keeps theirVV stable, i.e., λVk ≤ µV .

Theorem 2: Under non-location based scheduling policies,each real vehicle RVm is a ΣGI/GI/1 queue with task arrivalrate λR =

∑Kk=1 λ

Vk

M . Moreover, assume homogeneous realvehicle subregions as in Definition 3. Then

(i) all the real vehicle ΣGI/GI/1 queues are probabilisticreplicas of each other, i.e., the interarrival time and servicetime of each queue are identically distributed, separately.

(ii) Let λVk ≤ µV . When κ < κc, the ΣGI/GI/1 queueat each real vehicle is stable and TDk exists. When κ > κc,the ΣGI/GI/1 queue at each real vehicle is unstable whenλVk = µV , with κ and κc defined in (16) and (24).

Proof: (i) By Definition 1, our M -Voronoi tessellationcreates equitable subregions and Am is a Voronoi subregion.Then each task in the sequence 〈Taskki〉∞i=1 falls in subregionAm with probability 1

M . Hence the arrival time of tasks in thesequence 〈Taskki〉∞i=1 that fall in Am is a thinned processof T aki

∞i=1 with retaining probability p = 1

M . We denotethe thinned arrival process as T apki

∞i=1

. Since T aki∞i=1 is

renewal with rate λVk , then T apki ∞i=1

is renewal with rateλVkM by Example 4.3(a) in [12, pp. 75-76]. Thus the arrival

Page 7: From the Real Vehicle to the Virtual Vehiclecpcc.berkeley.edu/papers/VV.pdf · Our scheduling algorithms are designed to have the real vehicles travel to and execute each task such

process in subregion Am,T a(mj)

∞j=1

, is the superposition of

T apki ∞i=1

, k = 1, . . . ,K, or K independent renewal processes.This proves the ΣGI . By non-location based the distancebetween two consecutively executed tasks is i.i.d.. Since thetask size is i.i.d., then the service times at RVm, TRserv(mj) , arei.i.d. in j. This proves the second GI . A renewal process isalso stationary, so

T a(mj)

∞j=1

is stationary, and the arrival

rate at RVm is λR =∑Kk=1 λ

Vk

M by [21, Section 14].

Moreover, the M thinned processes T apki ∞i=1

generatedfrom the same V Vk arrival process are probabilistic replicasof each other because the retaining probabilities are all 1

M .

Since the arrival process of each RV subregion,T a(mj)

∞j=1

,

is the superposition of thinned replicas from each VV, thenT a(mj)

∞j=1

are probabilistic replicas in m. Homogeneous RV

subregions ensures that the service times at RVm, TRserv(mj) , arei.i.d. in m and j. Thus all the real vehicle ΣGI/GI/1 queuesare probabilistic replicas of each other. (i) follows.

(ii) When λVk ≤ µV , when κ < κc, λR =∑Kk=1 λ

Vk

M ≤∑Kk=1 µ

V

M = κµV < κcµV = µR, thus each ΣGI/GI/1 queueat RVm is stable by Loynes’ stability condition [25]. Taskkicorresponds to Task(mj), we denote by Taskki(mj) for thesame task. By (20) we know

TRsyski(mj) →p TRsysk(m) (25)

Since the all the RV ΣGI/GI/1 queues are probabilisticreplicas of each other, then TRsysk(m) is i.i.d. in m, we denote byTRsysk the generic term of TRsysk(m) . Since a task from V Vk canfall in any of the RV subregions with probability 1

M , thus (25)becomes

TRsyski(mj) →p TRsysk (26)

Also, when λVk < µV , the GI/GI/1 queue at each VVis stable, TV syski → TV sysk in distribution. When λVk = µV ,by our assumption that follows Theorem 1, the customer willprovide arrival process that guarantees TV syski → TV sysk indistribution. Thus both TRsyski and TV syski converges to TRsysk

and TV sysk in distribution. The tardiness TDk defined in (8)exists.

When κ > κc and λVk = µV , λR =∑Kk=1 λ

Vk

M =∑Kk=1 µ

V

M = κµV > κcµV = µR. Thus each ΣGI/GI/1 queueat RVm is unstable by Loynes’ stability condition [25].

IV. SCHEDULING POLICIES

In this section, we design the scheduling policies insideeach RV subregion. We assumed that the task arrival processT aki of V Vk is renewal with generic interarrival time Iak inSection II. In this section we further assume that Iak is i.i.d. ink, i.e., the interarrival times Iaki = T aki−T ak(i−1) are i.i.d. in kand i. We thus denote by Ia the generic term of Iak . Then thetask arrival rate are the same for each V V , λVk = λV = 1

E[Ia] .

Definition 4: The set of K virtual vehicles are said to hosthomogeneous tasks if the task interarrival times Iaki, locations

Xki and sizes TSki are all i.i.d. in k and i, separately, k =1, . . . ,K and i = 1, 2, . . ..

In this section we assume that all the VVs host homoge-neous tasks. Then the steady state real system time for V Vk,TRsysk , is identically distributed in k. We denote by TRsys thegeneric term of TRsysk . Then (25) and (26) become

TRsyski(mj) →p TRsys (27)

Also the steady state virtual system time of V Vk, TV sysk ,is i.i.d. in k. We denote by TV sys the generic value of TV sysk .Thus

TV syski(mj) →p TV sys (28)

Then the tardiness TDk are the same for all the VVs, thusTD is not only the average value but also the generic term ofTDk. We have

TDk = TD =E[max

TRsys − TV sys, 0

]E [TV serv]

(29)

From (27), (28) and (29) we know that when the virtualvehicles are homogeneous and the real vehicle subregions arehomogeneous, it suffices to analyze only one RV subregion,and the results represent the generic results of the system.

Let Φ denote a class of non-location based schedulingpolicies that are non-preemptive and deadline smooth. Ascheduling policy is said to be non-preemptive if under thispolicy the real vehicle always complete an initiated task evenwhen a priority task enters the system in the meanwhile.A scheduling policy is said to be deadline smooth if underthis policy the RV serves all the tasks including those whosedeadline has passed [27]. The common policies in queueingtheory such as FCFS, LCFS, ROS and SJF [38] are non-location based, non-preemptive and deadline smooth policies.Our scheduling policies introduced in this section such asEVDF, EDVDF and credit scheduling policy are shown tobe non-location based, non-preemptive and deadline smoothpolicies in Theorem 3.

Let TDφ denote the tardiness as defined by (29) underscheduling policy φ ∈ Φ. We consider the following optimiza-tion problem:

Find ψ ∈ Φ s.t.

TDψ = minφ∈Φ

TDφ (30)

for every k = 1, . . . ,K.

We propose the scheduling policies Earliest Virtual Dead-line First (EVDF) when the task size is known a priori inDefinition 5, its variation Earliest Dynamic Virtual DeadlineFirst (EDVDF) when the task size is not known a priori inDefinition 6, and the credit scheduling policy in Definition 7.These scheduling policies are motivated by the simple earliestdeadline first and credit scheduler in the cloud computingliterature [8]. The scheduling quantum for us is the task size.The size cannot be preempted. The Xen schedulers [8] havea constant scheduling quantum and can preempt tasks. In ourkind of cloud computing preemption would waste the timespent traveling to the location. In this chapter we analyze

Page 8: From the Real Vehicle to the Virtual Vehiclecpcc.berkeley.edu/papers/VV.pdf · Our scheduling algorithms are designed to have the real vehicles travel to and execute each task such

the value of cloud computing with moving servers withoutpreemption.

Definition 5: Under the Earliest Virtual Deadline First(EVDF) scheduling policy, when a real vehicle becomes avail-able, the real vehicle always hosts the virtual vehicle whosecurrent task has the earliest virtual deadline as defined in (4)from the pool of virtual vehicles whose current task falls inthe real vehicle subregion.

Definition 6: Under the Earliest Dynamic Virtual DeadlineFirst (EDVDF) scheduling policy, when a real vehicle becomesavailable, the real vehicle always hosts the virtual vehiclewhose current task has the earliest dynamic virtual deadlineas defined in (36) from the pool of virtual vehicles whosecurrent task falls in the real vehicle subregion.

Definition 7: Under the credit scheduling policy, whena real vehicle becomes available, the real vehicle alwayshosts the virtual vehicle with the maximum current credit asdescribed in Section IV-C from the pool of virtual vehicleswhose current task falls in the real vehicle subregion.

A. Earliest Virtual Deadline First

The optimality of our EVDF scheduling policy among allthe non-location based non-preemtive and deadline smoothscheduling policies follows from Theorem 1 of [27]. We restatethis result for convenience below.

Theorem 1 of [27]: For any convex function g : R → R,E[g(Rφ)]≤ E

[g(Rψ)]

whenever φ ψ.

Theorem 1 of [27] assumes a G/GI/1 queue served bynon-preemtive and deadline smooth scheduling policies. The Gin a G/GI/1 queue means the task arrival process is stationaryand ergodic. φ and ψ denote two admissible non-preemptiveand deadline smooth scheduling policies. φ ψ when φalways chooses a customer having a deadline earlier thanthat of the customer chosen by ψ. In particular the earliestdeadline first (EDF) scheduling policy always gives priorityto the customer having the earliest deadline, and the latestdeadline first (LDF) one gives priority to the customer havingthe latest deadline. Then, by definition EDF φ LDFfor any admissible scheduling policy φ. Rφ is the steady-statevalue of Rn = Dn− Tn−Wn under policy φ, where Dn, Tnand Wn are the deadline, arrival time and waiting time of then-th task.

The following theorem shows that our EVDF, EDVDF andcredit scheduling policy are in the class of non-location based,non-preemptive, and deadline smooth scheduling policies Φ.Moreover, EVDF optimizes tardiness within this class.

Theorem 3: (i) Let φ ∈ EVDF,EDV DF,Credit, asin Definitions 5, 6 and 7, then φ ∈ Φ, i.e., φ is non-locationbased, non-preemptive, and deadline smooth.

(ii) Assume homogeneous virtual vehicles and homoge-neous real vehicle subregions, let λR < µR, with λR andµR defined in Theorem 2 and (23). Then TDEVDF =minφ∈Φ TD

φ.

Proof: (i) The EVDF, EDVDF and credit scheduling poli-cies schedule only based on virtual deadlines, dynamic virtualdeadlines of each task and credit of each VV, separately. They

are independent of the distance between two consecutivelyexecuted tasks, D(mj). Thus D(mj) is the distance betweentwo random task locations in subregion Am. Thus D(mj) isi.i.d. in j and has the same distribution as D(m). Thus the threepolicies are non-location based. The three policies always serveall tasks, even if deadlines have passed. Thus they are smoothwith respect to the virtual deadlines as defined in (4). Thethree policies always completes an initiated task even whena priority task enters the system in the meanwhile. Thus thethree policies are non-preemptive. This proves part (i).

(ii) Since φ ∈ Φ is non-location based, the queue in an RVsubregion is ΣGI/GI/1 by Theorem 2. Since ΣGI is a subsetof G, then a ΣGI/GI/1 queue is also a G/GI/1 queue. Also,φ is non-preemptive and deadline smooth, Thus Theorem 1 of[27] holds in each RV subregion under φ ∈ Φ.

We define R(mj) = T dead(mj) −Ta(mj)−W

R(mj), where WR

(mj)is the waiting time of Task(mj), and is defined as the timedifference between the arrival time T a(mj) and when RVm

begins to travel to Task(mj). Thus TRsys(mj) = WR(mj) +TRserv(mj) .

Thusmax

TRsys(mj) − T

V sys(mj) , 0

= −min

TV sys(mj) − T

Rsys(mj) , 0

= −min

T dead(mj) − T

a(mj) −W

R(mj) − T

Rserv(mj) , 0

= −min

R(mj) − TRserv(mj) , 0

.

When λR < µR, the ΣGI/GI/1 queue at RVm is stable,we have R(mj) → R(m) = T dead(m) − T a(m) − WR

(m) indistribution. Since all the RV subregions are homogeneous,we can write the generic term R = T dead − T a −WR.

Thus E[max

TRsys − TV sys, 0

]= E

[−min

R− TRserv, 0

]=∫∞t=0

E [−min R− t, 0] dFTRserv (t),where FTRserv (t) is the cumulative distribution function (cdf)of TRserv . Since function g(x) = −min x− t, 0 is a convexfunction when t is a constant, and R has the same definitionas R in Theorem 1 of [27], then E

[−min

Rφ − t, 0

]≤

E[−min

Rψ − t, 0

]when φ ψ for any constant t by

Theorem 1 of [27]. Thus E[max

TRsys − TV sys, 0

]φ ≤E[max

TRsys − TV sys, 0

]ψwhen φ ψ, where the

superscript φ means the value is obtained when the schedulingpolicy is φ.

We know TD =E[maxTRsys−TV sys,0]

E[TV serv]by (29). Notice

that E[TV serv

]is a constant, then TDφ ≤ TDψ when φ

ψ. In particular, TDEVDF ≤ TDφ since EVDF φ forany φ ∈ Φ. Thus TDEVDF = minφ∈Φ TD

φ.

Different task arrival processes will generate differenttardiness values. We identify a worst-case arrival processmaximizing tardiness. We prove the special case η = 1 ofDefinition 8 generates the worst case. This is Theorem 4.

Definition 8: An arrival process T aki is called an η-arrivalprocess if

T aki =

0, i ≤ ηT deadk(i−η), i > η (31)

where η ∈ N.

Page 9: From the Real Vehicle to the Virtual Vehiclecpcc.berkeley.edu/papers/VV.pdf · Our scheduling algorithms are designed to have the real vehicles travel to and execute each task such

For η = 1 the definition implies the arrival of the currenttask is the virtual deadline of the previous task. Thus theservice times are also the interarrival times and the processat the output of the VV is identical to the arrival process, i.e.,it is also an η = 1 process. The following theorem establishesthe special role of the η = 1 process.

Theorem 4: Assume homogeneous virtual vehicles and ho-mogeneous real vehicle subregions under the EVDF schedulingpolicy, let κ ≤ κc, then the η-arrival process with η = 1 forall the virtual vehicles achieves the maximum TD among allthe renewal processes.

Proof: To prove the η-arrival process with η = 1 max-imizes TD, we show for any given task locations Xkiand task sizes

TSki

, an arbitrary renewal arrival processT aki will have a TD less than that of the η = 1 ar-rival process. We denote by

Ta(η=1)ki

the η = 1 arrival

process. Thus Ta(η=1)ki = T

dead(η=1)k(i−1) by Definition 8. For

an arbitrary renewal arrival process T aki, we construct anarrival process

T a1ki

such that T a1

ki = maxT aki, T

a(η=1)ki

for all k and i. Thus T a1

ki = maxT aki, T

dead(η=1)k(i−1)

. We

construct another arrival processT a2ki

such that T a2

ki =

maxT a1ki , T

dead1k(i−1)

. Note the three processes are constructed

to have the same Xki andTSki

. With the same Xkiand

TSki

, we denote by TDφ (T aki) the tardiness underpolicy φ when the arrival processes of the V Vk are T aki. Wewant to show TDEVDF (T aki) ≤ TDEVDF

(T a2ki

)and

TDEVDF(T a2ki

)≤ TDEVDF

(Ta(η=1)ki

), separately.

Since Xki andTSki

are the same for all three pro-cesses, then the service times TV servki are the same for theprocesses. For an arbitrary arrival process T aki, we haveT deadki ≥ T dead(η=1)

ki by (4) and Definition 8.

Comparing T aki andT a1ki

, we have T aki ≤ T a1

ki , andT deadki = T dead1

ki for all k and i. The latter can be seen byinduction on (4). First, T deadk1 = T dead1

k1 . Second, if T deadk(i−1) =

T dead1k(i−1), then T deadki = max

T aki, T

deadk(i−1)

+ TV servki ,

and T dead1ki = max

max

T aki, T

dead(η=1)k(i−1)

, T dead1k(i−1)

+

TV servki = maxT aki, T

dead1k(i−1)

+ TV servki since T dead1

k(i−1) ≥Tdead(η=1)k(i−1) . Thus T deadk(i−1) = T dead1

k(i−1) implies T deadki = T dead1ki .

This is true for every i by induction. Similarly, comparingT a1ki

and

T a2ki

, we have T a1

ki ≤ T a2ki , and T dead1

ki = T dead2ki

by induction. Thus T aki ≤ T a1ki ≤ T a2

ki and T deadki = T dead1ki =

T dead2ki for all k and i.

In each RVm subregion, we construct a scheduling policyφ ∈ Φ, possibly non-work-conserving, such that under φ andT aki, k = 1, . . . ,K, RVm will copy the behavior of RVmunder EVDF and

T a2ki

, i.e., RVm flies to, executes, and

completes each task at the same time, separately, comparingthe two cases. Such φ exists because the set of tasks availableto RVm under

T a2ki

is always a subset of the set of tasks

available to RVm under T aki at any time since T aki ≤ T a2ki

for all k and i. Thus TDφ (T aki) = TDEVDF(T a2ki

).

Also TDEVDF (T aki) ≤ TDφ (T aki) by Theorem 3. So

TDEVDF (T aki) ≤ TDEVDF(T a2ki

)for any given Xki

andTSki

.

Under the arrival processT a2ki

, we have T a2

ki =

maxT a1ki , T

dead1k(i−1)

and T dead1

k(i−1) = T dead2k(i−1). By (4)

T dead2ki = max

max

T a1ki , T

dead1k(i−1)

, T dead2k(i−1)

+ TV servki =

maxT a1ki , T

dead1k(i−1)

+ TV servki = T a2

ki + TV servki . Thus

TV sys2ki = T dead2ki − T a2

ki = TV servki . Thus the virtual systemtime is the same under both

T a2ki

and

Ta(η=1)ki

, and

equals TV servki . Also, T a2ki −T dead2

k(i−1) = maxT a1ki , T

dead1k(i−1)

T dead2k(i−1) = max

T a1ki , T

dead2k(i−1)

− T dead2

k(i−1) ≥ 0. Thus underT a2ki

, V Vk idles for T a2

ki − T dead2k(i−1) ≥ 0 before generat-

ing Taskki. But underTa(η=1)ki

, V Vk never idles, i.e.,

Ta(η=1)ki − T dead(η=1)

k(i−1) = 0.

When every VV is underTa(η=1)ki

, the interarrival time

is TV servki . The arrival process of the subregion of RVm,Ta(η=1)(mj)

, is the superposition of K thinned renewal pro-

cesses ofTa(η=1)ki

by Theorem 2. When every VV is under

T a2ki

, the interarrival time is TV servki +Idki, where Idki ≥ 0

is the idle time between two consecutive tasks. Thus thearrival process of the subregion of RVm,

T a2

(mj)

, is the

superposition of K thinned renewal processes ofT a2ki

. Thus

the generic interarrival time ofT a2

(mj)

, Ia2

(m), is stochasti-

cally greater than that ofTa(η=1)(mj)

, Ia(η=1)

(m) , i.e., Ia2(m) ≥st

Ia(η=1)(m) . A random variable A is stochastically greater thanB, denoted A ≥s tB, if P (A > t) ≥ P (B > t) for all−∞ < t < ∞. Thus, we can construct a scheduling policyφ ∈ Φ in the subregion of RVm under

T a2

(mj)

such that under

φ, RVm executes tasks in the same order as EVDF but alwaysidles for Ia2

(m)−Ia(η=1)(m) right after the completion of each task.

Since the virtual system time of each task are the same for bothcases. Thus TDφ

(T a2ki

)= TDEVDF

(Ta(η=1)ki

). Also

TDEVDF(T a2ki

)≤ TDφ

(T a2ki

)by Theorem 3. Thus

TDEVDF(T a2ki

)≤ TDEVDF

(Ta(η=1)ki

)for any given

Xki andTSki

.

So we have TDEVDF (T aki) ≤ TDEVDF(Ta(η=1)ki

)for an arbitrary renewal arrival process T aki for any givenXki and

TSki

. Thus this is also true when we takeexpectation on Xki and

TSki

. So the η-arrival processwith η = 1 achieves the maximum TD among all the renewalprocesses.

The provider wants to know the right gain κ for a givennumber of real vehicles M and a given task arrival processT aki for each virtual vehicle for a guaranteed level oftardiness. We assume homogeneous virtual vehicles and homo-geneous real vehicle subregions, and consider the case whenevery customer is fully utilizing their VVs, i.e., λV = µV .Under a scheduling policy φ, if one fixes the number of real

Page 10: From the Real Vehicle to the Virtual Vehiclecpcc.berkeley.edu/papers/VV.pdf · Our scheduling algorithms are designed to have the real vehicles travel to and execute each task such

vehicles M and increases the number of virtual vehicles, oneincreases the gain κ, but increases the tardiness TD, thusreducing the performance isolation. Conversely at any level,say TD = α for the tardiness there is a largest value of κ inthe sense that any increase in the number of virtual vehicleswithout increase in M will increase the tardiness TD abovethe level α. We denote this largest value of κ by κφα(M) at eachα. We denote by TDφ(M,κ) the tardiness when the numberof RVs is M and the gain is κ under scheduling policy φ. Thusκφα(M) is defined as

κφα(M) = maxTDφ(M,κ)≤α,λV =µV

κ (32)

Recall that L is the generic term of Lki as defined in (2),and D is the generic term of D(m) as defined in (21). Weassume each RV subregion satisfies

E[D] =c1E[L]√

M,E[D2]

=c2E

[L2]

M(33)

where c1 and c2 are positive constants. In particular, whenregion A and subregions Am are squares, c1 = c2 = 1.

The following theorem asserts the largest achievablegain without compromising performance isolation actuallyincreases with the number of real vehicles M . In other words,larger systems are able to support more customers per realvehicle without compromising performance isolation. We callthis economy of scale [26].

Theorem 5: Assume homogeneous virtual vehicles andhomogeneous real vehicle subregions satisfying (33) underthe EVDF scheduling policy. κEVDFα (M) increases with M .Moreover, when TSki = 0, κEVDFα (M) is Θ

(√M)

. When

E[TS]> 0, κEVDFα (M) < 1 + E[L]

vV E[TS ].

Proof: Since this theorem is only about the EVDFscheduling policy, we omit the superscript EVDF in thenotations.

From (29) we know it suffices to analyze only one RVsubregion to obtain the average tardiness of the system TD =E[maxTRsys−TV sys,0]

E[TV serv].

From Theorem 2 we know that each RVm is a ΣGI/GI/1

queue with arrival rate λR =∑Kk=1 λ

Vk

M = KλV

M = κλV =κµV . Let TRsys(M,κ) denote the real system time when thenumber of RVs is M and the gain is κ. Let E[D](M) andµR(M) denote the E[D] and µR values when the number ofRVs is M . If M1 < M2, then E[D] (M1) > E[D] (M2) by(33). Thus µR (M1) < µR (M2) by (23). Notice that the arrivalrate of both the ΣGI/GI/1 queues under M1 and M2 arethe same λR = κµV . Then TRsys(M1, κ) >st T

Rsys(M2, κ)because the arrival rate does not change but service rateincreases. Utilizing the fact that A ≥st B if and only iffor all non-decreasing functions g, E [g(A)] ≥ E [g(B)], andnoticing that the virtual system time TV sys does not changewith M or κ, and g(x) = max(x, 0) is non-decreasing,we have TD (M1, κ) > TD (M2, κ). Thus ∃κ′ > κ, s.t.TD (M1, κ) = TD (M2, κ

′). Thus κα (M1) < κα (M2) by(32). Thus κα(M) increases with M .

κα(M) is defined based on λV = µV . By Theorem 2we know that the ΣGI/GI/1 queue at each real vehicle

is unstable when κ > κc, then we should keep κ ≤ κc.

Thus κα(M) ≤ κc =E[L]

vV+E[TS]

E[D]

vR+E[TS ]

by (24). When TSki = 0,

substituting (33) we have κα(M) ≤ κc = vR√M

c1vV. Then

κα(M) is O(√

M)

.

To establish the lower bound of κα(M), we first ana-lyze the tardiness under FCFS. Since K = κα(M)M , andκα(M) increases with M , then as M → ∞, K → ∞. Thesuperposition of independent renewal processes converges toa Poisson process as the number of component processes tendto infinity [9]. Then the ΣGI/GI/1 queue of each subregionbecomes an M/GI/1 queue with arrival rate λR = κα(M)µV

as both M and K goes to infinity. Since the task sizeTSki = 0, the service rate of the queue is vR

E[D] by (23). ByPollaczek-Khinchine formula [31], [22] we have the expectedwaiting time of a task in the M/GI/1 queue under FCFS,

E[WR(FCFS)

]=

λRE[D2](vR)2

2(1−λR E[D]

vR)

.

TRsys(FCFS) = WR(FCFS) + DvR

, TV sys = WV + LvV

,where WV is the steady state waiting time of a task in theGI/GI/1 queue at each virtual vehicle. TV sys and TV serv

is only determined by the GI/GI/1 queue at each virtualvehicle, and do not depend on the scheduling policy of eachRV subregion. When M →∞, D

vR≤ L

vValmost surely (a.s.).

Thus TRsys(FCFS)−TV sys = WR(FCFS)+ DvR−WV − L

vV≤

WR(FCFS) a.s..

Thus TDFCFS =E[maxTRsys(FCFS)−TV sys,0]

E[TV serv]

≤ E[maxWR(FCFS),0]E[TV serv]

= E[WR(FCFS)]E[TV serv]

=λR

E[D2](vR)2

2E[TV serv](1−λR E[D]

vR)

a.s. when M →∞.

Since EVDF achieves minimum TD by Theorem 3,

TDEVDF = α implies α ≤λR

E[D2](vR)2

2E[TV serv](1−λR E[D]

vR)

.

Substituting (33) and λR = κα(M)µV we have

κα(M) ≥ 2αE[TV serv]

2αE[TV serv]µV c1E[L]

vR√M

+µV c2E[L2]

(vR)2M

≥ 2αE[TV serv]2αE[TV serv]µV c′1

E[L]

vR√M

= vR√M

µV c′1E[L]for some c′1 > c1 when

M →∞. Thus κα(M) is Ω(√

M)

.

Thus we have κ(α) is Θ(√

M)

when TSki = 0.

When E[TS]> 0, κα(M) ≤ κc =

E[L]

vV+E[TS]

E[D]

vR+E[TS ]

<

E[L]

vV+E[TS]E[TS ]

= 1 + E[L]vV E[TS ]

.

We define the travel ratio of V Vk as the expected traveltime over the expected service time of a task.

rtr =E[L]vV

E [TV serv]=

E[L]vV

E[L]vV

+ E [TS ](34)

The following theorem asserts that the migration cost isbounded.

Page 11: From the Real Vehicle to the Virtual Vehiclecpcc.berkeley.edu/papers/VV.pdf · Our scheduling algorithms are designed to have the real vehicles travel to and execute each task such

Theorem 6: Under the allocation policy in Definition 1,MCk ≤ rtrBV kv

V . Moreover, when V Vk is fully utilizedMCk ≥

(1− 1

M

)rtrBV kv

V .

Proof: By definition, MCk = BV kE[ZkL]

E[Ideadk ]. Zk indicates

migration between two consecutive tasks. Thus E [ZkL] ≤E[L]. By Theorem 1 λV deadk ≤ µV . Since λV deadk = 1

E[Ideadk ]and µV = 1

E[TV serv], then E

[Ideadk

]≥ E

[TV serv

]. Thus

MCk ≤ BV kE[L]

E[TV serv]= BV k

E[L]

vV

E[TV serv ]vV = BV krtrv

V

when substituting (34).

When V Vk is fully utilized, λV deadk = µV by Theorem 1,thus E

[Ideadk

]= E

[TV serv

]. Greater L implies the distance

between two consecutive tasks are larger, then it is more prob-able that the two tasks will fall in different RV subregions andcause a migration, i.e., P (Zk = 1 |L ) increases with L. ThusL and Zk are positively correlated. Then Cov (Zk, L) ≥ 0.Thus E [ZkL] = E [Zk]E[L] + Cov (Zk, L) ≥ E [Zk]E[L].Also, P (Zk = 0) = 1

M and P (Zk = 1) = 1− 1M since Zk in-

dicates whether two consecutive tasks fall in the same RV sub-region. Thus E [Zk] = 1− 1

M . Then MCk ≥ BV k E[Zk]E[L]E[TV serv]

=(1− 1

M

)BV k

E[L]E[TV serv]

=(1− 1

M

)BV krtrv

V .

The following theorem asserts that the slack under the η =1 arrival process is bounded.

Theorem 7: Under the η-arrival process with η = 1,SLk ≤ rtr ≤ 1.

Proof: By Definition 8, TV sysk = LvV

+TS . Also TRsysk ≥Dv + TS . Thus TV sysk − TRsysk ≤ L

vV+ TS − D

v − TS ≤LvV

. Thus SLk =E[maxTV sysk −TRsysk ,0]

E[TV serv]≤ E[max L

vV,0]

E[TV serv]=

E[ LvV

]E[TV serv ]

= rtr =E[L]

vV

E[L]

vV+E[TS ]

≤ 1.

B. Earliest Dynamic Virtual Deadline First

When the task sizes are not known a priori, the provideronly knows the task size after execution, the RV hosts the VVwhose current task has the earliest dynamic virtual deadline.

The task size may not be known a priori in practiceas assumed by our EVDF scheduling policy. Therefore wedefine and evaluate another scheduling policy named EarliestDynamic Virtual Deadline First (EDVDF) which assigns taskvirtual deadlines based on an estimated task size prior to taskcompletion and updates size to the true value after completion.(35) and (36) specify the deadline computation. TS

ki denotesthe task size estimate. We define the estimated service time ofV Vk on Taskki as

TV serv′

ki =LkivV

+ TS′

ki (35)

The dynamic virtual deadline T deadki (t) is calculated asfollows.

T deadki (t) =

maxT aki, T

deadk(i−1)(t)

+ TV serv

ki , t < T compki

maxT aki, T

deadk(i−1)(t)

+ TV servki , t ≥ T compki

(36)where T deadk0 ≡ 0 and TV servki is given in (3).

When Taskki is completed at t = T compki by an RV, TSkiis known, T deadki (t) is updated, the scheduling policy updatesall the tasks hosted by V Vk following Taskki, i.e., updatesT deadk(i+1)(t), T

deadk(i+2)(t), . . . according to equation (36). The real

vehicle then serves the next task with the earliest T deadki (t). Inthis way the scheduling policy utilizes the actual task sizes asthey become known.

In our implementation of EDVDF in Section V, the tasksize estimate is set to be TS

ki = E[TSexek

], where

TSexek

denotes the sizes of the set of previously executed tasks hostedby V Vk. E

[TSexek

]= 0 if

TSexek

is empty. Time-series

methods can also be used to estimate TS′

ki .

C. Credit Scheduling Policy

We adopt the credit scheduler described in [41] with somechanges for the our spatial case. Under the credit schedulingpolicy, each VV keeps a balance of credits which can benegative. Each credit has a value of 1 second of RV time whileit emulates the VV perfectly. A token bucket algorithm [35]is implemented to manage the credits of each VV. Each VVhas a bucket. Credits are added to the bucket at constant rate 1per second, and are expended during service. The bucket canhold at most c credits. The inflow credits are discarded whenthe bucket is full.

As shown in Figure 2, VVs are divided into three states:UNDER, with a nonnegative credit balance, OVER, with anegative credit balance, and INACTIVE or halted. The VVsare listed in decreasing order of credit balance. Thus, those inUNDER state are ahead of those in OVER state. The VV atthe head of the queue has the most credits and is selected forexecution when an RV becomes available. In work-conserving(WC) mode, when no VVs are in the UNDER state, one in theOVER state will be chosen, allowing it to receive more thanits share of RV time. In non-work-conserving (NWC) mode,the RV will go idle instead.

Current'VV'

Become&ac(ve&with&0&or&remaining&credits&

Un" U2' U1'On" O2' O1'When&

credits&>&0&

INACTIVE&VVs&

Head&of&the&run&queue&

Ac(ve?&

No&

Yes&

Enqueue&in&the&order&of&decreasing&credits&

OVER& UNDER&

Sorted&in&decreasing&order&of&credits&

credits'credits' credits'credits'credits' credits' credits'

RVs&

Fig. 2. The credit scheduling policy.

The VV with the most credits is called the current VV, sayV Vk. The token bucket algorithm is illustrated in Figure 3.When an RV becomes available, the RV will travel to andexecute the current task hosted by V Vk, say Taskki. Thescheduler debits TV serv

ki credits from the bucket of V Vk.TV serv

ki is calculated according to (35). The scheduler findsthe VV with the maximum credit balance, and the VV with themost credits will become the new current VV. When Taskki iscompleted, the scheduler will know the size TSki and computethe true service time TV servki . The consumed credits of Taskki,TV servki , is calculated according to (3). This is the appropriate

Page 12: From the Real Vehicle to the Virtual Vehiclecpcc.berkeley.edu/papers/VV.pdf · Our scheduling algorithms are designed to have the real vehicles travel to and execute each task such

Credit inflow at rate 1!

Debit TV’ki credits when an

RV begins to serve task Cki!

Maximum credits:!c!γ(t)!

Return TV’ki - TV

ki credits

when task Cki is completed!

Fig. 3. The token bucket algorithm.

credits, or RV time, the scheduler should debit for executingTaskki. The scheduler returns TV serv

ki − TV servki credits toV Vk to adjust the debited credits to be exactly TV servki . Thismethod of debiting TV serv

ki before execution and adjustingto TV servki after execution is because the scheduler does notknow the size of Taskki, and thus does not know TV servki ,before execution. If the task size TSki is known a priori, thenTV serv

ki = TV servki . The right amount of credits will be debitedat beginning and the adjusted amount equals 0.

When Taskki is completed, there are two ways V Vk goes:

(i) Enqueue according to the credit balance such that thelist of VVs is in decreasing order of credits.

(ii) Go INACTIVE if the next Taskk(i+1) has not arrivedyet, or if the customer’s reservation of V Vk ends.

VVs in an INACTIVE state are divided into two categories:

(i) The VV is still under the reservation of a customer,all the arrived tasks hosted by the VV have been executedand the next task has not arrived yet. In this case, the creditscontinue flowing into the bucket up to a maximum of c. TheVV becomes active again with the remaining credit balanceand enqueues in decreasing order of credits upon arrival ofthe next task.

(ii) The VV is not under reservation. In this case, the creditsstop flowing to the bucket. The VV becomes active again with0 credit balance and enqueues the active VVs in decreasingorder of credits when a customer begins to reserve it.

V. EXPERIMENTS

We simulate the system under homogeneous real vehiclesand homogeneous virtual vehicles under Earliest Virtual Dead-line First (EVDF), Earliest Dynamic Virtual Deadline First(EDVDF) and credit scheduling policies in this section.

A. Simulation Setup

All the simulations are done in a square region A of sizea× a, where a = 10 m. The number of RVs is M ,

√M ∈ N.

The square region A is divided into M square subregions,each with edge length a√

M. The M RVs are assigned to the M

subregions in a one-to-one manner. Each RV runs a schedulingpolicy in its subregion. The scheduling policies include theEVDF, EDVDF and the credit scheduling policy. The speedof the RVs equals the virtual speed vR = vV = 1 m/s. Eachvirtual vehicle hosts tasks with η = 1 arrival process. The η =1 process maximizes tardiness, and excludes multiplexing gain

by having each virtual vehicle fully utilized. So this is a worst-case simulation, and the gain observed is migration gain only.The performance measures include the performance isolationand fairness index based on tardiness and delivery probability,together with slack and migration cost. We simulate 1300 tasksper VV but calculate the metrics using only the 100-th to 600-th tasks to ensure the metrics are computed at steady-state.When the 600-th task of each VV is under execution, all theother VVs still have tasks. Each task is uniformly distributedin region A. Table I summarizes the simulation setup.

TABLE I. SIMULATION SETUP

Size of region A 10 m × 10 mVirtual speed, vV 1 m/s

RV speed, vR 1 m/sTask size, TSki Uniformly distributed

Task location, Xki Uniformly distributed in region ATask arrival process, Taki η = 1 arrival process

# Tasks per VV 1300Tasks used in metric calculation 100th - 600th task of each VV

Scheduling policies EVDF, EDVDF and Credit scheduling policy

B. Simulation Results

Figure 4 shows the performance isolations and fairnessindices based on tardiness and delivery probability, togetherwith slacks and migration costs under EVDF for differentnumbers of real vehicles and gains, or different numbers ofvirtual vehicles, when the task size is zero.

Figure 5 verifies Theorem 5. Subfigures 5(a) and 5(b) arethe contours of performance isolations based on tardiness anddelivery probability shown in subfigures 4(a) and 4(b) whenthe task size is zero. We can see that the provider supports agiven number of virtual vehicles with significantly fewer realvehicles that travel at the virtual speed while guaranteeinghigh performance isolation, for example, 750 VVs Vs. 100RVs while guaranteeing the relative expected tardiness tobe less than 1% in 5(a), and 560 VVs Vs. 100 RVs whileguaranteeing the average delivery probability is greater than98%. The migration gain increases in the order of the squareroot of the number of real vehicles while guaranteeing thesame performance isolation based on tardiness and deliveryprobability, showing economy of scale. Subfigures 5(c) and5(d) are the contours of performance isolations based ontardiness and delivery probability when the mean task sizeis 25% of the mean flying time, i.e., E

[TS]

= E[L]4vV

. Wecan see that the gain is upper bounded by a constant asasserted in Theorem 5. Also, for a given performance isolationlevel and number of real vehicles, the gain or the numberof virtual vehicles hosted decreases as the task size increasescomparing Subfigures 5(a) and 5(c), 5(b) and 5(d), separately,for example, 150 VVs Vs. 100 RVs while guaranteeing therelative expected tardiness to be less than 1% in 5(a), and 130VVs Vs. 100 RVs while guaranteeing the average deliveryprobability is greater than 98%. The gain diminishes as thetask size increases. The virtual vehicle generates gain whentraveling, not when standing still.

Figure 6 also shows the diminishing gain as the relative

task sizeE[TS]vV

E[L] increases. For example, to guarantee theaverage relative tardiness to be less than 1% using 100 RVs,the number of VVs hosted decreases from 750 to 150 as therelative task size increases from 0 to 25%.

Page 13: From the Real Vehicle to the Virtual Vehiclecpcc.berkeley.edu/papers/VV.pdf · Our scheduling algorithms are designed to have the real vehicles travel to and execute each task such

020

4060

80100

02

46

810

0%

100%

200%

300%

400%

500%

600%

700%

# RVs, M

EVDF: Tardiness − M − κ Relation when η = 1 and TSki = 0

# VVs / # RVs, κ

Tard

ines

s, T

D

020

4060

80100

02

46

810

0

0.2

0.4

0.6

0.8

1

# RVs, M

EVDF: Delivery Probability − M − κ Relation when η = 1 and TSki = 0

# VVs / # RVs, κ

Del

iver

y pr

obab

ility,

DP

(a) (b)

020

4060

80100

02

46

810

0.4

0.5

0.6

0.7

0.8

0.9

1

# RVs, M

EVDF: Fairness on Tardiness when η = 1 and TSki = 0

# VVs / # RVs, κ

Fairn

ess

inde

x, F

I(TD k)

020

4060

80100

02

46

810

0.975

0.98

0.985

0.99

0.995

1

1.005

# RVs, M

EVDF: Fairness on Delivery Probability when η = 1 and TSki = 0

# VVs / # RVs, κ

Fairn

ess

inde

x, F

I(DP k)

(c) (d)

020

4060

80100

02

46

810

0

1

2

3

4

5

# RVs, M

EVDF: Slack − M − κ Relation when η = 1 and TSki = 0

# VVs / # RVs, κ

Slac

k, S

L

020

4060

80100

02

46

810

0.98

0.985

0.99

0.995

1

1.005

# RVs, M

EVDF: Migration Cost − M − κ Relation when η = 1 and TSki = 0

# VVs / # RVs, κ

Mig

ratio

n co

st, M

C

(e) (f)

Fig. 4. Tardinesses, delivery probabilities, fairness indices, slacks, and migration costs with different numbers of RVs and gains when the task size is zerounder the η = 1 process under the EVDF scheduling policy.

Page 14: From the Real Vehicle to the Virtual Vehiclecpcc.berkeley.edu/papers/VV.pdf · Our scheduling algorithms are designed to have the real vehicles travel to and execute each task such

10 20 30 40 50 60 70 80 90 1001

2

3

4

5

6

7

8

9

10

0.05

0.05

0.05

0.05

0.02

0.02

0.02

0.02

0.01

0.01

0.01

EVDF: Contour of Tardiness when η = 1 and TSki = 0

# RVs, M

# VV

s / #

RVs

, κ κc

10 20 30 40 50 60 70 80 90 1001

2

3

4

5

6

7

8

9

10

0.9

0.9

0.9

0.9

0.95

0.95

0.95

0.98

0.98

EVDF: Contour of Delivery Probability when η = 1 and TSki = 0

# RVs, M

# VV

s / #

RVs

, κ κc

(a) (b)

10 20 30 40 50 60 70 80 90 1001

1.5

2

2.5

3

3.5

0.05

0.050.05

0.05

0.02

0.02

0.020.01

0.01

EVDF: Contour of Tardiness when η = 1 and E[TS] = E[L] / 4vV

# RVs, M

# VV

s / #

RVs

, κ

κc < 5

0.0510 20 30 40 50 60 70 80 90 100

1

1.5

2

2.5

3

3.5

0.90.9

0.9

0.90.95

0.95

EVDF: Contour of Delivery Probability when η = 1 and E[TS] = E[L] / 4vV

# RVs, M

# VV

s / #

RVs

, κκc < 5

(c) (d)

Fig. 5. Contours of tardiness and delivery probability with different numbers of RVs and gains when the task size is zero and E[TS

]=

E[L]

4vVunder the

η = 1 process under the EVDF scheduling policy.

0 0.05 0.1 0.15 0.2 0.25100

200

300

400

500

600

700

800

900Number of VVs vs. Relative task size: M = 100

E[TS] vV / E[L]

Num

ber o

f VVs

, K

TD = 0.01TD = 0.02TD = 0.05

Fig. 6. The number of virtual vehicles hosted by 100 real vehicles toguarantee a certain level of tardiness under EVDF with different task sizes.

Figure 7 shows the performance isolations based on tardi-ness with different numbers of RVs M to host the same numberof VVs K under EVDF with different task sizes. We can seein Subfigure 7(a) that when TSki = 0 and the number of VVsK is fixed, average relative expected tardiness decreases as thenumber of RVs M increases. This change becomes very sharpwhen M ≈ 23 for the case K = 100. The average tardinessis very small once M is greater than 28. This sharp change isalso revealed in the case when K = 300 and K = 500, wherethe average tardiness becomes very small once M ≥ 52 andM ≥ 74, respectively. The transition between low and highperformance isolations is sharp. This implies that the system isvery easy to operate because the provider can easily determinethe appropriate number of real vehicles to host a give numberof virtual vehicle and a guaranteed performance isolation. Forthe case when the mean task size E

[TS]

= E[L]4vV

as shown inSubfigure 7(b), similar phenomenon follows, but the numberof RVs needed to guarantee the same performance isolationincreases to host the same number of VVs. This also impliesthat the gain diminishes as the task size increases.

Page 15: From the Real Vehicle to the Virtual Vehiclecpcc.berkeley.edu/papers/VV.pdf · Our scheduling algorithms are designed to have the real vehicles travel to and execute each task such

100100100

100100

300300

300300

500

500500

Tardiness with Different M for the Same K, TSki = 0

# RVs, M

Tard

ines

s, T

D

10 20 30 40 50 60 70 80 90 100

100%

200%

300%

400%

500%

600%

700%

100100

100 300

Tardiness with Different M for the Same K, E[TS] = E[L] / 4vV

# RVs, M

Tard

ines

s, T

D

10 20 30 40 50 60 70 80 90 100

200%

400%

600%

800%

1000%

1200%

1400%

1600%

1800%

(a) (b)

Fig. 7. Tardiness with different numbers of RVs M for the same number of VVs under EVDF for different task sizes.

Figure 8 compares EVDF, EDVDF and credit schedulingpolicies on the same settings as Subfigures 5(c) and 5(d). Wecan see that EVDF achieves higher gain than EDVDF, andEDVDF achieves higher gain than the credit scheduling policyfor a given number of RVs and a guaranteed performanceisolation based on both tardiness and delivery probability.

VI. CONCLUSION

We proposed virtual vehicle in multi-customer systemswith location specific tasks to create performance isolation[34], which enables cloud computing in space. In Section II,we illustrated virtual vehicle and its role in cloud computingin space. In the service-level agreement (SLA), each virtualvehicle has a virtual speed vV , its performance is measuredby the tardiness. We used the measure PI [39] to quantifyperformance isolation, and Jain’s fairness indices FI [18] tomeasure fairness across virtual vehicles. In Section III, wedesign virtual vehicle allocation and scheduling policies. Theallocation is done by dividing the service region into equalsubregions. The real vehicles travel less by this division. Thescheduling policies include earliest virtual deadline first, earli-est dynamic virtual deadline first and credit scheduler, adaptedfrom the CPU schedulers in conventional cloud computing [8].We simulated the system under the three scheduling policiesunder the η-arrival process with η = 1. The η = 1 case isshown to be the worst case that achieves the largest tardinessamong all the renewal processes. Simulation results show that(i) a virtual vehicle performs as well as a real vehicle withhigh performance isolation. (ii) The provider can support agiven number of virtual vehicles with significantly fewer realvehicles that travels at the virtual speed while guaranteeinghigh performance isolation and bounded migration cost.

REFERENCES

[1] L. Abeni and G. Buttazzo. Qos guarantee using probabilistic dead-lines. In Real-Time Systems, 1999. Proceedings of the 11th EuromicroConference on, pages 242–249, 1999.

[2] S. L. Albin. On poisson approximations for superposition arrivalprocesses in queues. Management Science, 28(2):126–137, 1982.

[3] Dragomir Anguelov, Carole Dulong, Daniel Filip, Christian Frueh,Stphane Lafon, Richard Lyon, Abhijit Ogale, Luc Vincent, and JoshWeaver. Google street view: Capturing the world at street level.Computer, 43, 2010.

[4] Fabienne Anhalt and Pascale Vicat-Blanc Primet. Analysis and exper-imental evaluation of data plane virtualization with xen. Internationalconference on Networking and Services (ICNS’06), 0:198–203, 2009.

[5] Dimitris J Bertsimas and Garrett Van Ryzin. A stochastic and dynamicvehicle routing problem in the euclidean plane. Operations Research,39(4):601–615, 1991.

[6] David Boutcher and Abhishek Chandra. Does virtualization make diskscheduling passe? ACM SIGOPS Operating Systems Review, 44(1):20–24, 2010.

[7] G.C. Buttazzo. Soft real-time systems: predictability vs. efficiency.Series in computer science. Springer, 2005.

[8] Ludmila Cherkasova, Diwaker Gupta, and Amin Vahdat. Comparisonof the three CPU schedulers in Xen. SIGMETRICS PerformormanceEvaluation Review, 35(2):42–51, September 2007.

[9] E. Cinlar. Superposition of point processes. In In Stochastic PointProcesses: Statistical Analysis, Theory and Applications (P. A. W. Lewis,ed.), pages 549–606. New York: Wiley, 1972.

[10] J.W. Cohen. The single server queue. North-Holland series in appliedmathematics and mechanics. North-Holland Pub. Co., 1982.

[11] S.S. Craciunas, A. Haas, C.M. Kirsch, H. Payer, H. Rock, A. Rottmann,A. Sokolova, R. Trummer, J. Love, and R. Sengupta. Information-Acquisition-as-a-Service for Cyber-Physical Cloud Computing. In Proc.Workshop on Hot Topics in Cloud Computing (HotCloud), 2010.

[12] D.J. Daley and D. Vere-Jones. An introduction to the theory of pointprocesses. Springer series in statistics. Springer-Verlag, 1988.

[13] G. B. Dantzig and J. H. Ramser. The truck dispatching problem.Management Science, 6(1):pp. 80–91, 1959.

[14] Yaoyao Gu, Doruk Bozdag, Eylem Ekici, Fsun zgner, and Chang-GunLee. Partitioning based mobile element scheduling in wireless sensornetworks. In In. Proc. Second Annual IEEE Conference on Sensorand Ad Hoc Communications and Networks (SECON), pages 386–395,2005.

[15] P. Gupta and P.R. Kumar. The capacity of wireless networks. Informa-tion Theory, IEEE Transactions on, 46(2):388–404, 2000.

[16] A. Host-Madsen and A. Nosratinia. The multiplexing gain of wirelessnetworks. In Information Theory, 2005. ISIT 2005. Proceedings.International Symposium on, pages 2065–2069, 2005.

[17] Jiangchuan Huang and Raja Sengupta. Stability of dynamic travelingrepairman problem under polling-sequencing policies. In EuropeanControl Conference, July 2013.

Page 16: From the Real Vehicle to the Virtual Vehiclecpcc.berkeley.edu/papers/VV.pdf · Our scheduling algorithms are designed to have the real vehicles travel to and execute each task such

10 20 30 40 50 60 70 80 90 1001

1.2

1.4

1.6

1.8

2

2.2

# RVs, M

# VV

s / #

RVs

, κEVDF, EDVDF and Credit: Contour of Tardiness

0.05

0.05

0.05

0.02

0.02

0.02

0.05

0.05

0.05

0.02

0.02

0.02

0.05

0.05

0.05

0.02

0.02

0.05

EVDFEDVDFCredit

10 20 30 40 50 60 70 80 90 1001

1.1

1.2

1.3

1.4

1.5

1.6

1.7

1.8

1.9

2

# RVs, M

# VV

s / #

RVs

, κ

EVDF, EDVDF and Credit: Contour of Delivery Probability

0.9

0.9

0.9 0.95

0.9

0.9

0.9 0.95

0.9

0.9

0.90.95

EVDFEDVDFCredit

(a) (b)

Fig. 8. Comparison of EVDF, EDVDF and Credit scheduling policies on tardiness and delivery probability when the mean task size E[TS

]=

E[L]

4vVunder

the η = 1 process.

[18] Raj Jain, Dah-Ming Chiu, and William R Hawe. A quantitativemeasure of fairness and discrimination for resource allocation in sharedcomputer system. Eastern Research Laboratory, Digital EquipmentCorporation, 1984.

[19] Karen Jenvey. NASA Unmanned Aircraft Measures Low AltitudeGreenhouse Gases, December 2011.

[20] Mukil Kesavan, Ada Gavrilovska, and Karsten Schwan. On disk i/oscheduling in virtual machines. In Proceedings of the 2nd conferenceon I/O virtualization, pages 6–6. USENIX Association, 2010.

[21] A.I.A. Khinchin. Mathematical methods in the theory of queueing.Griffin’s statistical monographs & courses. Griffin, 1969.

[22] A.Y. Khinchin and RAND CORP SANTA MONICA CALIF. TheMathematical Theory of a Stationary Queue. Defense TechnicalInformation Center, 1967.

[23] C. Kirsch, E. Pereira, R. Sengupta, H. Chen, R. Hansen, J. Huang,F. Landolt, M. Lippautz, A. Rottmann, R. Swick, R. Trummer, andD. Vizzini. Cyber-Physical Cloud Computing: The Binding and Migra-tion Problem. In Design, Automation and Test in Europe, 2012.

[24] Gilbert Laporte and Yves Nobert. Exact algorithms for the vehiclerouting problem. In Michel Minoux Silvano Martello, Gilbert Laporteand Celso Ribeiro, editors, Surveys in Combinatorial Optimization,volume 132 of North-Holland Mathematics Studies, pages 147 – 184.North-Holland, 1987.

[25] RM Loynes. The stability of a queue with non-independent inter-arrivaland service times. In Proc. Cambridge Philos. Soc, volume 58, pages497–520. Cambridge Univ Press, 1962.

[26] A. Mas-Colell, M.D. Whinston, and J.R. Green. Microeconomic theory.Oxford University Press, 1995.

[27] P. Moyal. Convex comparison of service disciplines in real time queues.Operations Research Letters, 36(4):496 – 499, 2008.

[28] M. Pavone, A. Arsie, E. Frazzoli, and F. Bullo. Equitable partitioningpolicies for robotic networks. In Robotics and Automation, 2009. ICRA’09. IEEE International Conference on, pages 2356 –2361, 2009.

[29] M. Pavone, N. Bisnik, E. Frazzoli, and V. Isler. A stochastic anddynamic vehicle routing problem with time windows and customerimpatience. Mob. Netw. Appl., 14(3):350–364, June 2009.

[30] M. Pavone, E. Frazzoli, and F. Bullo. Adaptive and distributedalgorithms for vehicle routing in a stochastic and dynamic environment.Automatic Control, IEEE Transactions on, 56(6):1259–1274, June 2011.

[31] Felix Pollaczek. Uber eine aufgabe der wahrscheinlichkeitstheorie. i.Mathematische Zeitschrift, 32(1):64–100, 1930.

[32] Gerald J. Popek and Robert P. Goldberg. Formal requirements for

virtualizable third generation architectures. Commun. ACM, 17(7):412–421, July 1974.

[33] Benny Rochwerger, David Breitgand, Amir Epstein, David Hadas,Irit Loy, Kenneth Nagin, Johan Tordsson, Carmelo Ragusa, MassimoVillari, Stuart Clayman, et al. Reservoir-when one cloud is not enough.Computer, 44(3):44–51, 2011.

[34] Mendel Rosenblum. The reincarnation of virtual machines. Queue,2(5):34–40, July 2004.

[35] Scott Shenker and John Wroclawski. General characterization parame-ters for integrated service network elements. RFC 2215, sept. 1997.

[36] Arun A. Somasundara, Aditya Ramamoorthy, and Mani B. Srivastava.Mobile element scheduling for efficient data collection in wirelesssensor networks with dynamic deadlines. In Proceedings of the 25thIEEE International Real-Time Systems Symposium, RTSS ’04, pages296–305, Washington, DC, USA, 2004.

[37] H. Takagi. Queueing analysis: a foundation of performance evaluation,vol. 1 : vacation and priority systems. Queueing Analysis. North-Holland, 1991.

[38] Adam Wierman. Scheduling for today’s computer systems: bridgingtheory and practice. PhD thesis, Pittsburgh, PA, USA, 2007.

[39] Kejiang Ye, Xiaohong Jiang, Deshi Ye, and Dawei Huang. Twooptimization mechanisms to improve the isolation property of serverconsolidation in virtualized multi-core server. In Proceedings of the2010 IEEE 12th International Conference on HPCC, pages 281–288,Washington, DC, USA, 2010.

[40] Alin Zhong, Hai Jin, Song Wu, Xuanhua Shi, and Wei Gao. Perfor-mance implications of non-uniform vcpu-pcpu mapping in virtualizationenvironment. Cluster Computing, pages 1–12, 2012.

[41] Fangfei Zhou, Manish Goel, Peter Desnoyers, and Ravi Sundaram.Scheduler vulnerabilities and attacks in cloud computing. CoRR,abs/1103.0759, 2011.