Abstract
The configuration balancing problem with stochastic requests generalizes well-studied resource allocation problems such as load balancing and virtual circuit routing. There are given m resources and n requests; each request has multiple possible configurations, each of which increases the load of each resource by some amount. The goal is to select one configuration for each request to minimize the makespan: the load of the most-loaded resource. In the stochastic setting, the amount by which a configuration increases the resource load is uncertain until the configuration is chosen, but we are given a probability distribution. We develop both offline and online algorithms for configuration balancing with stochastic requests. When the requests are known offline, we give a non-adaptive policy for configuration balancing with stochastic requests that -approximates the optimal adaptive policy, which matches a known lower bound for the special case of load balancing on identical machines. When requests arrive online in a list, we give a non-adaptive policy that is competitive. Again, this result is asymptotically tight due to information-theoretic lower bounds for special cases (e.g., for load balancing on unrelated machines). Finally, we show how to leverage adaptivity in the special case of load balancing on related machines to obtain a constant-factor approximation offline and an -approximation online. A crucial technical ingredient in all of our results is a new structural characterization of the optimal adaptive policy that allows us to limit the correlations between its decisions.
Keywords: Stochastic scheduling, Stochastic routing, Load balancing, Unrelated machines
Introduction
This paper considers the configuration balancing problem: there are m resources and n requests. Request j has configurations . We must choose one configuration per request, which adds to the load vector on the resources. The goal is to minimize the makespan, i.e., the load of the most-loaded resource. Configuration balancing captures many natural resource allocation problems where requests compete for a finite pool of resources and the task is to find a “fair” allocation in which no resource is over-burdened. Two well-studied problems of this form arise in scheduling and routing.
-
(i)
In load balancing a.k.a. makespan minimization, there are m (unrelated) machines and n jobs. Scheduling job j on machine i increases the load of i by . The goal is to schedule each job on some machine to minimize the makespan, i.e., the load of the most-loaded machine.
-
(ii)
In virtual circuit routing or congestion minimization, there is a directed graph on m edges with edge capacities for , and n requests, each request consisting of a source-sink pair in G and a demand . The goal is to route each request j from to via some directed path, increasing the load/congestion of each edge e on the path by
, while the objective is to minimize the load of the most-loaded edge.
Configuration balancing captures both problems by taking the m resources to be the m machines or edges, respectively; each configuration now corresponds to assigning a job to some machine or routing a request along some path.
Typically, job sizes or request demands are not known exactly when solving resource allocation problems in practice. This motivates the study of algorithms under uncertainty, where an algorithm must make decisions given only partial/uncertain information about the input. Uncertainty can be modeled in different ways. In exceptional cases, a non-clairvoyant algorithm that has no knowledge about the loads of requests may perform surprisingly well; an example is Graham’s greedy list scheduling for load balancing on identical machines [2]. In general, a non-clairvoyant algorithm cannot perform well. Hence, we consider a stochastic model, where the unknown input follows some known distribution but the actual realization is a priori unknown. Such a model is natural when there is historical data available from which such distributions can be deduced.
In the configuration balancing with stochastic requests problem, we assume that each configuration c of request j is a random vector with known distribution supported on such that the ’s are independent across different requests j. The actual realized vector of a configuration c of request j is only observed after irrevocably selecting this particular configuration for request j. The objective is to minimize the expected maximum load (makespan)
where is the configuration chosen for request j. We assume that we have oracle access to the ’s; in particular we assume that in constant time, we can compute any needed statistic of the distribution . Thus, configuration balancing with stochastic requests captures natural stochastic generalizations of the above two problems:
-
(i)
In load balancing with stochastic jobs, there are m (unrelated) machines and n jobs. Scheduling job j on machine i increases the load of i by a random size with known distribution such that the ’s are independent across j’s. The goal is to adaptively schedule the jobs (upon scheduling job j to machine i, we observe the realized value of ) to minimize the expected makespan.
-
(ii)
In virtual circuit routing with stochastic requests, there is a directed graph on m edges with edge capacities for , and n requests, each request consisting of a source-sink pair in G and a random demand with known distribution such that the ’s are independent across j’s. The goal is to adaptively choose a - path for each request j such that upon choosing such a path, we observe the realized value of and the load of each edge e on the path increases by
. The objective is to minimize the expected load of the most-loaded edge.
Further, we distinguish whether there is an additional dimension of uncertainty or not, namely the knowledge about the request set. In the offline setting, the set of requests and the distributions of the configurations of each request are known up-front, and they can be selected and assigned to the resources irrevocably in any order. In the online setting, requests are not known in advance and they are revealed one-by-one (online-list model). The algorithm learns the stochastic information on configurations of a request upon its arrival, and must select one of them without knowledge of future arrivals. After a configuration is chosen irrevocably, the next request arrives.
In general, we allow an algorithm to base the next decision on knowledge about the realized vectors of all previously selected request configurations. That is, a policy can select a configuration, say c, of request j, observe the realized values of the vector , and can make subsequent decisions based on this information. We call such policies adaptive. Conversely, a non-adaptive policy is one that fixes the particular configuration chosen for a request without using any knowledge of the realized configuration vectors. We define the adaptivity gap for configuration balancing for stochastic requests as , where the maximum is taken over all instances and and are the makespan of the optimal non-adaptive and adaptive policies, respectively.
The goal of this paper is to investigate the power of adaptive and non-adaptive policies for online and offline configuration balancing with stochastic requests. We quantify the performance of an algorithm Alg by comparing its achieved expected makespan on instance with , the expected makespan of an optimal offline adaptive policy Opt that can process the requests in any order: More precisely, we bound the worst case ratio , where again the maximum is taken over all instances . We say is an -approximation if its approximation ratio is at most . Similarly, for an online algorithm , we say it is -competitive if its approximation ratio is at most .
One subtlety in our stochastic model is that an online algorithm must process the requests in a fixed order, while we allow the offline optimum to adaptively choose an order to process the requests and thus reveal different information about their realized values. Another possible model that has been considered in other works [3] is to compare to the offline optimum that processes the requests in the same fixed order (known offline). In the deterministic setting, the offline adaptive and fixed order optima coincide, but this is not the case in the stochastic setting. Thus, upper bounds on the competitive ratio for our model translate to upper bounds on the gap between adaptive- and fixed-order policies.
Our results
As our first main result, we present non-adaptive algorithms for offline and online configuration balancing with stochastic requests.
Theorem 1
For configuration balancing with stochastic requests there is a randomized offline algorithm that computes a non-adaptive policy that is a -approximation and an efficient deterministic online algorithm that is a -approximation when comparing to the optimal offline adaptive policy. Both algorithms run in polynomial time if the configuration distributions are given explicitly as input.
In the above theorem, we assume that each configuration distribution has finite support and is specified by the value-probability pairs for each atom of the distribution. See Lemma 10 for a more general statement that is agnostic to the encoding of the distributions.
The offline analysis relies on a linear programming (LP) relaxation of configuration balancing, which has a known integrality gap of , even for virtual circuit routing [4], implying that the analysis is tight—see Appendix C for formal definition of integrality gap and proof sketch. In the online setting, our analysis employs a potential function to greedily determine which configuration to choose for each request. In particular, we generalize the idea by [5] to the setting of configuration balancing with stochastic requests and match a known lower bound for online deterministic load balancing on unrelated machines by [6].
If the configurations are not given explicitly as part of the input or the number of configurations is large, then efficiently solving the problem requires us to be able to optimize over configurations in polynomial time.
Applications:
These results would hold for both load balancing on unrelated machines and virtual circuit routing if we could guarantee that either the configurations are given explicitly or the respective subproblems can be solved efficiently. We can ensure this in both cases.
For stochastic load balancing on unrelated machines, the resources are the m machines, and each job has m possible configurations—one corresponding to assigning that job to each machine. Thus, we can efficiently represent all configurations. Further, here the LP relaxation of configuration balancing used in Theorem 1 is equivalent to the LP relaxation of the generalized assignment problem (GAP) solved in [7], which gives a deterministic rounding algorithm. Hence, Theorem 1 implies the following theorem.
Theorem 2
There exist efficient deterministic algorithms that compute a non-adaptive policy for load balancing on unrelated machines with stochastic jobs that achieve an -approximation offline and an -approximation online when comparing to the optimal offline adaptive policy.
These results are asymptotically tight due to the lower bound of on the adaptivity gap [8] and the lower bound of on the competitive ratio of any deterministic online algorithm, even for deterministic requests [6]. This implies that the adaptivity gap for stochastic load balancing is .
For virtual circuit routing, the resources are the m edges and each request has a configuration for each possible routing path. Thus, efficiently solving the subproblems requires more work as the configurations are only given implicitly and there can be exponentially many. For the offline setting, since the LP relaxation has (possibly) exponentially many variables, we design an efficient separation oracle for the dual LP in order to efficiently solve the primal. For the online setting, we carefully select a subset of polynomially many configurations that contain the configuration chosen by the greedy algorithm, even when presented with all configurations. Thus, Theorem 1 implies that stochastic requests are not harder to approximate than deterministic requests.
Theorem 3
For routing with stochastic requests, there exist an efficient randomized offline algorithm computing a non-adaptive policy that is a -approximation and an efficient deterministic online algorithm that computes an -approximation when comparing to the optimal offline adaptive policy.
Adaptive policies for related machines
When each request j has m configurations and configuration can be written as , where is the cth standard unit vector, the problem is also known as load balancing on related machines. We say that is the size of request (or job) j and is the speed of resource (or machine) i. In this special case, we show how to leverage adaptivity to overcome the lower bound on the adaptivity gap. Interestingly, our adaptive algorithms begin with a similar non-adaptive assignment of jobs to machines, but we deviate from the assignment adaptively to obtain our improved algorithms.
Theorem 4
For load balancing on related machines with stochastic jobs, there exist efficient algorithms that compute an adaptive offline 432-approximation and an adaptive online -approximation when comparing to the optimal offline adaptive policy.
We note that we have not tried to optimize the constant for our offline algorithm. It remains an interesting open question whether the online setting admits an O(1)-competitive algorithm.
As adaptivity turns out to be very powerful in load balancing on related machines, it is reasonable to ask whether the (stochastic) information about job sizes is even needed to improve upon Theorem 1. We answer this question to the affirmative in the following sense. In Appendix B, we show that non-clairvoyant algorithms, that have no prior knowledge of the job sizes, approximate the optimal offline schedule only within a factor , even if the size of a job is revealed immediately upon assigning it to a machine. Further, we give a non-clairvoyant algorithm that is -approximate, asymptotically matching this lower bound.
Technical overview
We illustrate the main idea behind our non-adaptive policies, which compare to the optimal offline adaptive policy. Throughout this paper, we let denote the optimal adaptive policy as well as its makespan. As in many other stochastic optimization problems, our goal is to give a good deterministic proxy for the makespan of a policy. Then, our algorithm will optimize over this deterministic proxy to obtain a good solution. First, we observe that if all configurations were bounded with respect to in every entry, then selecting configurations such that each resource has expected load gives the desired -approximation by standard concentration inequalities for independent sums with bounded increments. Thus, in this case the expected load on each resource is a good proxy. However, in general, we have no upper bound on , so we cannot argue as above. We turn these unbounded random variables (RVs) into bounded ones in a standard way by splitting each request into truncated and exceptional parts.
Definition 5
(Truncated and Exceptional Parts) Fix as threshold. For a RV X, its truncated part (w.r.t. threshold ) is and its exceptional part is . Note that .
It is immediate that the truncated parts are bounded in . Taking , we can control their contribution to the makespan using concentration. It remains to find a good proxy for the contribution of exceptional parts to the makespan. This is one of the main technical challenges of our work as we aim to compare against the optimal adaptive policy: adaptive policies have much better control over the exceptional parts than non-adaptive ones.
Concretely, let be the configuration chosen by some fixed policy for request j. Note that itself can be a random variable in . We want to control the quantity
Since we have no reasonable bound on the ’s, for non-adaptive policies, we can only upper bound the expected maximum by the following sum
| 1 |
We call the right hand side total (expected) exceptional load. The above inequality is tight up to constants for non-adaptive policies, so it seems like the total expected exceptional load is a good proxy to use for our algorithm. However, it is far from tight for adaptive policies as the following example shows.
Example 6
Recall that in load balancing on related machines, each request j has m configurations and configuration has the special form of , where is the processing time of job j and is the speed of machine i. We assume that there is one fast machine with speed and slow machines with speed , where is the truncation threshold. There are m jobs: a stochastic one with processing time Ber and deterministic jobs with processing time . The optimal adaptive policy first schedules the stochastic job on the fast machine. If its realized size is 0, then it schedules all deterministic jobs on the fast machine as well. Otherwise the realized size is and it schedules one deterministic job on each slow machine, implying . However, the total expected exceptional load (w.r.t. ) is , where denotes that job j is assigned to machine i, i.e., configuration i is chosen for j.
In the example, the optimal adaptive policy accrues a lot of exceptional load, but this does not have a large effect on the makespan. Concretely, (1) can be loose by a -factor for adaptive policies. Thus, it seems that the total exceptional load is a bad proxy in terms of lower-bounding . However, we show that, by comparing our algorithm to a near-optimal adaptive policy rather than the optimal one, the total exceptional load becomes a good proxy in the following sense. This is the main technical contribution of our work, and it underlies all of our algorithmic techniques.
Theorem 7
For configuration balancing with stochastic requests, there exists an adaptive policy with expected maximum load and total expected exceptional load at most with respect to any truncation threshold . Further, any configuration c selected by this policy satisfies .
The proof of the above relies on carefully modifying the “decision tree” representing the optimal adaptive policy. In light of Theorem 7, the deterministic proxies we consider are the expected truncated load on each resource and the total expected exceptional load. All of our algorithms then proceed by ensuring that both quantities are bounded with respect to . In the offline case, we round a natural assignment-type linear program (LP), and in the online case, we use a potential-function argument. All of these algorithms actually output non-adaptive policies. For the special case of related-machines load balancing, we also compute a non-adaptive assignment but instead of following it exactly, we deviate using adaptivity and give improved solutions.
Related work
While stochastic optimization problems have long been studied [9, 10], approximation algorithms for them are more recent [11, 12]. By now, multi-stage stochastic problems (where uncertain information is revealed in stages) are well-understood [13–15]. In contrast, more dynamic models, where the exact value of an unknown parameter becomes known at times depending on the algorithms decisions (such as serving a request) still remain poorly understood. Some exceptions come from stochastic knapsack [16–19] as well as stochastic scheduling and routing which we discuss below.
For load balancing with deterministic sizes, a 2-approximation in the most general unrelated-machines offline setting [20] is known. For identical machines ( for all jobs j), the greedy algorithm (called list scheduling) is a -approximation algorithm [2]. This guarantee holds even when the jobs arrive online and nothing is known about job sizes. This implies a -approximate adaptive policy for stochastic load balancing on identical machines.
Apart from this, prior work on stochastic scheduling has focused on approximating the optimal non-adaptive policy. There are non-adaptive O(1)-approximations known for identical machines [21], unrelated machines [8], the -norm objective [22], and Top--norms [23].
In contrast, our work focuses on approximating the stronger optimal adaptive policy. The adaptivity gap (the ratio between the expected makespan of the optimal adaptive and non-adaptive policies) can be even for the simplest case of identical machines [8]. Thus, previous work on approximating the optimal non-adaptive policy does not immediately give any non-trivial approximation guarantees for our setting. The only previous work on adaptive stochastic policies for load-balancing (beyond the highly-adaptive list scheduling) is by [24]. They propose scheduling policies whose degree of adaptivity can be controlled by parameters and show an approximation factor of for scheduling on identical machines.
Other objectives have been studied in stochastic scheduling, such as minimizing the expected sum of (weighted) completion times. Most known adaptive policies have an approximation ratio depending on parameters of the distribution [25–30], with the notable (still polylogarithmic) exception in [31].
Online load balancing with deterministic jobs is also well studied [32]. On identical machines, the aforementioned list scheduling algorithm [2] is -competitive. For unrelated machines, there is a deterministic -competitive algorithm [5] and this is best possible [6]. When the machines are uniformly related, [33] design an O(1)-competitive algorithm for minimizing the makespan. Im et al. [34, 35] study the multi-dimensional generalization to vector scheduling under the makespan and the -norm objective.
For our particular formulation of configuration balancing, the techniques of [5] give an -competitive algorithm for deterministic requests. There are also results for packing integer programs [36–38]. Finally, one can generalize the objective from minimizing the -norm of the machine loads to minimizing more general norms, which is studied under the name generalized load balancing in [39].
For oblivious routing with stochastic demands, [40] give an algorithm which is an -approximation with high probability. Here, “oblivious” refers to the requirement that the chosen path between a source-sink pair must not depend on the current congestion of the network. In particular, after specifying a set of paths for each possible source-sink pair, a demand matrix is drawn from an a-priori known distribution and each demand needs to be routed along one of the predefined paths. The obliviousness requirement is very different from our setting and makes the two models essentially incomparable.
When for each source-sink pair, there is an -approximation algorithm by [41], which is best possible, unless [42].
In the online setting, when the source-sink pairs arrive online in a list and have to be routed before the next pair arrives, [5] give a lower bound of on the competitive ratio of any deterministic online algorithm in directed graphs, where n is the number of vertices. They also give a matching upper bound. For more details on online routing we refer to the survey [43].
Configuration balancing with stochastic requests
In this section, we prove our main results for the most general problem we consider: configuration balancing. We give an -approximation offline and an -approximation online; both algorithms are non-adaptive. Before describing the algorithms, we give our main structural theorem that enables all of our results. Roughly, we show that instead of comparing to the optimal adaptive policy, by losing only a constant factor in the approximation ratio, we can compare to a near-optimal policy that behaves like a non-adaptive one (w.r.t. the proxy objectives we consider, namely, the total expected exceptional load).
A structural theorem
In this section, we show that there exists a near-optimal policy as guaranteed by Theorem 7. To this end, we modify the optimal policy by “restarting” whenever an exceptional request is encountered. Additionally, we ensure that this modified policy never selects a configuration c for a request j with .
We let J denote the set of requests. For any subset , we let denote the optimal adaptive policy (and its maximum load) on the set of requests . Note that . Our (existential) algorithm to construct such a policy will begin by running the optimal policy on all requests. However, once an exceptional request is encountered or the next decision will choose a configuration with too large expected maximum, we cancel and instead recurse on all remaining requests, ignoring all previously-accrued loads; see Algorithm 1. The idea of our analysis is that we recurse with small probability.
Algorithm 1.
Policy S(J)
Theorem 7
For configuration balancing with stochastic requests, there exists an adaptive policy with expected maximum load and total expected exceptional load at most with respect to any truncation threshold . Further, any configuration c selected by this policy satisfies .
Proof
We prove the theorem by induction on the number of requests . The base case is trivial. Now we consider . Let J be the set of n requests. Our algorithm to construct the desired policy S(J) is the following. Throughout, we fix a truncation threshold .
Let R be the random set of requests we recurse on after stopping . We first show that indeed , so we can apply induction. Suppose we did not follow to completion because a chosen configuration becomes exceptional (2); denote this event by . In this case, there is at least one request for which we have chosen a configuration. Hence, we have , and therefore there is a policy S with the required properties by induction.
Suppose now that chooses a configuration for request j that is too large (1); denote this event by . We have to show that holds as well. Suppose for the sake of contradiction that j was the first request considered by . As Opt is w.l.o.g. deterministic, this implies , a contradiction. Hence, the desired policy S exists by induction.
The maximum load of this policy is at most , where we set if no decision results in an exceptional or too large configuration when running . In expectation, we have
In the second equality, we use the fact that the realizations of the remaining requests in R are independent of the event . The first inequality uses the inductive hypothesis. The last inequality uses , so , and .
Note that on the event , we have that chooses a configuration that becomes exceptional or that is too large in expectation. By definition of the policy S, the events and are disjoint. By definition of , we have . Observe that the event implies that there is a request with configuration chosen by with . Since the realization of is independent of the choice , this implies . Thus,
Rearranging yields . Hence, we can bound the expected makespan of policy S(J) by
The computation for the total expected exceptional load is similar. We let denote the event that our policy chooses configuration c for request j. Then, we can split the exceptional load into two parts based on whether a configuration is chosen by or S(R)
where we let and denote the events that configuration c is chosen for request j by up to the first too large configuration or up to and including the first exceptional configuration, or by S(R), respectively.
We first bound the former term, corresponding to the configurations chosen in . In case of event or if is run to completion, we have . Otherwise, let be the first (and only) exceptional configuration chosen by . Then, . Combining and taking expectations yields
For the latter term, we condition again on the events and apply the inductive hypothesis. All exceptional parts are defined with respect to the fixed threshold for . Therefore,
Note that we define to be the event that the policy chooses configuration c for request j. In conclusion, by combining our bounds for these two terms we have
To conclude, our constructed policy has expected maximum truncated load and total expected exceptional load both at most (by the above calculations), and it never chooses a configuration with (because we stop running right before it chooses such a configuration, and by induction we subsequently do not as well.)
Having this near-optimal policy at hand, the upshot is that we can bound our subsequent algorithms with respect to the following LP relaxation () for configuration balancing with stochastic requests. The variable denotes selecting configuration c for request j. We take our threshold between the truncated and exceptional parts to be . Using the natural setting of the y-variables as the probabilities of the policy from Theorem 7, it is straight-forward to show that the following LP relaxation has a feasible solution, formalized in Lemma 8. 
Lemma 8
() has a feasible solution for any .
Proof
Consider the adaptive policy guaranteed by Theorem 7, say , and let the events be with respect to . We consider the natural setting of the y-variables given this policy: for all j and , we take . It is clear that for all j and for all j and for all . Moreover, as by Theorem 7 the policy does not select a configuration c with , the pruning constraints if are also satisfied.
It remains to verify the exceptional and truncated load constraints. For the exceptional constraint, we observe
where in the first step we use the fact that the decision to choose configuration c for request j is independent of its realization, and in the second we use the properties of the policy. Similarly, for the truncated constraint for each i,
where we additionally use the fact that almost surely for any non-negative random variable X and truncation threshold. This final expression is exactly the expected load of machine i in policy . To show that all truncated load constraints are satisfied, it suffices to show that the maximum expected load in is at most . Applying Jensen’s inequality and the properties of give
as required.
Offline setting
Our offline algorithm is the natural randomized rounding of (). First, we use a standard guess-and-double approach to find a truncation threshold such that () is feasible. Then once we have a feasible solution , for each request j, we choose configuration c as configuration independently with probability ; see Algorithm 2 for the formal algorithm.
Algorithm 2.
Offline Configuration Balancing with Stochastic Requests
To analyze Algorithm 2, the contribution of the truncated parts to the makespan is bounded by the following inequality, which we prove in Appendix A.
Lemma 9
Let be sums of independent RVs bounded in for some such that for all . Then, .
To bound the contribution of the exceptional parts, we use (1), i.e., the total expected exceptional load. The analysis of Algorithm 2 is summarized in the next lemma.
Lemma 10
Algorithm 2 is a randomized algorithm that solves () for at most -many truncation thresholds and that outputs a non-adaptive policy that -approximates the optimal adaptive policy.
Proof
By Lemma 8, we are guaranteed that () is feasible as soon as . Note that our intial guess of is , which is a trivial lower bound on . A crude upper bound on is , so we are guaranteed to double at most -times, as required.
Further, since our initial is at most and by Lemma 8, our final satisfies . Thus, to show the desired approximation guarantee, it suffices to show that Algorithm 2 returns a non-adaptive policy with expected makespan .
We let denote the event that our algorithm chooses configuration c for request j. Thus, the truncated load on resource i can be written as
Note that the random variables are independent for different j because the are and we sample the configuration independently for each j. Further, they are bounded in by truncation. With the constraints of (), we can bound the expectation by
where we used the independence of and in the second equality. By Lemma 9, . Using (1) we upper bound the total expected exceptional load by
Combining our bounds for the truncated and exceptional parts completes the proof. The expected makespan of our algorithm is given by
as required.
If the configurations are given explicitly as part of the input, then () can be solved in polynomial time, and we do this for polynomially-many truncation thresholds. Thus, Algorithm 2 runs in polynomial time. Hence, the -approximate non-adaptive policy for configuration balancing with stochastic requests (Theorem 1) follows from the lemma.
Online setting
We now consider online configuration balancing where n stochastic requests arrive online one-by-one, and for each request, one configuration has to be irrevocably selected before the next request appears. We present a non-adaptive online algorithm that achieves a competitive ratio of , which is best possible due to the lower bound of [6].
By a standard guess-and-double scheme, we may assume that we have a good guess of . The proof is analogous to [5]; see Appendix D for details.
Lemma 11
Given an instance of online configuration balancing with stochastic requests, suppose there exists an online algorithm that, given parameter , never creates an expected makespan more than , possibly terminating before handling all requests. Further, if the algorithm terminates prematurely, then it certifies that . Then, there exists an -competitive algorithm for online configuration balancing with stochastic requests. Further, the resulting algorithm preserves non-adaptivity.
We will build on the same technical tools as in the offline case. In particular, we wish to compute a non-adaptive assignment online with small expected truncated load on each resource and small total expected exceptional load. To achieve this, we generalize the greedy potential function approach of [5]. Our two new ingredients are to treat the exceptional parts of a request’s configuration as a resource requirement for an additional, artificial resource and to compare the potential of our solution directly with a fractional solution to ().
Now we describe our potential function, which is based on an exponential/soft-max function. Let denote the current guess of the optimum as required by Lemma 11. We take as our truncation threshold. Given load vector , our potential function is
For , we ensure the ith entry of is the expected truncated load on resource i and use the 0th entry as a virtual resource that is the total expected exceptional load. For any request j, let be the expected load vector after handling the first j requests, with denoting its ith entry. Let for all i. Upon arrival of request j, our algorithm tries to choose the configuration that minimizes the increase in potential; see Algorithm 3.
Algorithm 3.
Online Configuration Balancing with Stochastic Requests
To analyze this algorithm, we compare its makespan with a solution to (). This LP has an integrality gap of , which follows immediately from the path assignment LP for virtual circuit routing [4]. Hence, a straightforward analysis of Algorithm 3 comparing to a rounded solution to () gives an assignment with expected truncated load per machine and total expected exceptional load . To get a tight competitive ratio of , we avoid the integrality gap by comparing to a fractional solution to (), and we use a slightly different inequality than Lemma 9 for the regime where the mean of the sums is larger than the increments by at most a -factor. The particular maximal inequality is the following, which we prove in Appendix A.
Lemma 12
Let be sums of independent RVs bounded in for such that for all . Then, .
We give the guarantee for Algorithm 3, which implies the -competitive algorithm for online configuration balancing with stochastic requests.
Lemma 13
Suppose the minimizing configuration in Line 1 can be found in polynomial time. Then Algorithm 3 runs in polynomial time; it is deterministic, non-adaptive and correctly solves the subproblem of Lemma 11 for .
Proof
The running time of Algorithm 3 is clear. It remains to show that the algorithm creates expected makespan at most or correctly certifies if it terminates prematurely.
We first show the former. By definition, upon termination of the algorithm after, say requests, the expected truncated load on each resource and total expected exceptional load are both at most . Let the configuration choices be with respect to our algorithm. We can split the makespan into the contributions by the truncated and exceptional parts.
Each truncated part is bounded in and each resource has expected truncated load at most . By Lemma 12, we can bound the contribution of the truncated parts by .
For the exceptional parts, applying (1) gives
Combining both bounds gives that the expected makespan is at most , as required.
It remains to show that if , then the algorithm successfully assigns all requests. We do so by bounding the increase in the potential function. Note that if , then () is feasible for our choice of by Lemma 8. Thus, let be a feasible solution to (). For simplicity, let be the exceptional part of configuration c and its truncated part on resource i.
For each request j, as Algorithm 3 chooses a configuration minimizing the increase in ,
for all configurations . As by feasibility of , this implies
| 2 |
We recall that . We bound the increase in potential incurred by Algorithm 3:
where the first inequality holds due to (2), and the second inequality holds because the load on machine i only increases over time. Standard estimates of give for . As is feasible, we know that for all c with . Hence,
Using that is feasible and satisfies for resource by the exceptional constraint and for all resources by the truncated constraints, we get
After rearranging, we have by choice of . Taking logarithms and using that is monotonically increasing, we conclude that Note that we chose implying that Algorithm 3 never fails if .
Proof of Theorem 1
Note that the configurations are given explicitly, implying that both, Algorithms 2 and 3, run in polynomial time. Hence, Lemma 10 gives the -approximate offline algorithm and Lemmas 11 and 13 give the -approximate online algorithm.
Unrelated load balancing and virtual circuit routing
In this section, we apply our algorithms for configuration balancing to stochastic load balancing on unrelated machines (Theorem 2) as well as stochastic virtual circuit routing (Theorem 3).
Unrelated load balancing with stochastic jobs
We recall that in load balancing on unrelated machines with stochastic jobs, we have m machines and n jobs such that the size of job j on machine i is a random variable . These s are independent across jobs. This is a special case of configuration balancing with stochastic requests by taking m resources (corresponding to the m machines) and n requests such that each request j has m possible configurations, one for each machine choice job j has. Precisely, we define the configurations for job j by setting
| 3 |
Proof of Theorem 2
Each request has m possible configurations, so the total size of the resulting configuration balancing instance is polynomial. Thus, we may assume the configurations are given explicitly. Hence, Theorem 1 immediately gives a randomized -approximation offline and -approximation online for load balancing on unrelated machines with stochastic jobs.
However, to obtain a deterministic offline algorithm, we can de-randomize Algorithm 2 for this special case because here, () is equivalent to the generalized assignment LP considered by Shmoys and Tardos, which has a constant-factor rounding algorithm [7].
Routing with stochastic demands
Virtual circuit routing is another special case of configuration balancing: Given any instance of the former, which consists of a directed graph with m edges and n source-sink pairs, the resulting configuration balancing instance has m resources, one for each edge, and n requests, one for each source-sink pair, such that there is one configuration per source-sink path in the graph.
Note that unlike load balancing, where a request has at most m configurations, for routing, a request can have exponentially many configurations. Thus, to obtain polynomial-time algorithms for routing, we cannot explicitly represent all configurations. In particular, to prove Theorem 3 in the offline setting, it suffices to show how to solve () efficiently in the special case of routing. This is because, if the request distributions are given explicitly, then by Lemma 10, we solve () polynomially-many times. Similarly, to prove Theorem 3 in the online setting, we need to show how to find the configuration (i.e. the path) that minimizes the increase in the potential .
Offline routing: solving ()
We first re-write () for routing. Recall that is the truncation threshold. For a request j, let be the set of all edges with and let be the collection of all --paths in the auxiliary graph . For each request j and path , the variable denotes the decision to route request j along path P. Thus, we want to solve the following path assignment LP. 
To see that () is equivalent to (), note that the pruning constraints of the latter ensure that any configuration/path P with will not be selected. Re-writing gives . Thus, the pruning constraint ensures that no edge with will be selected. This is exactly encoded by the set of feasible paths .
Note that () has an exponential number of variables. For classical congestion minimization problems, the path-assignment LP formulation is equivalent to a flow formulation [4], which can be solved optimally in polynomial time using results about flows in networks. In our case, however, we additionally have the third constraint (the exceptional load constraint) in the LP, which does not allow for a straight-forward equivalent flow formulation. Therefore, we use LP duality in order to solve it efficiently: We give a separation oracle for its dual LP. For obtaining the dual, we add the trivial objective to maximize to (). Hence, the dual of (), with variables for , for and , is 
For solving (), consider a request j and a path . The expected exceptional part of routing j along P is , which is the expected exceptional part of the smallest-capacity edge along the path. Given this edge , a particular choice of the dual variables is feasible for the first constraint of () if and only if
Hence, for each request j, it remains to find a path that is minimal w.r.t. edge weights . By letting every edge be the smallest-capacity edge and removing any smaller-capacity edges from the graph, this becomes a shortest - path problem.
Algorithm 4.
Separation oracle for ()
Lemma 14
Algorithm 4 is a polynomial time separation oracle for ().
Proof
Since shortest paths can be found in polynomial time [44], Algorithm 4 indeed runs in polynomial time. Further, if there is an edge with or if , then Algorithm 4 correctly outputs the violated constraint.
It remains to consider the case when . In this case, we need to show for each request j that we find some such that achieves .
Consider any request j such that the minimum is achieved by some - path . Let be the smallest-capacity edge along . We claim for the correct guess , achieves the minimum. To see this, observe that is a - path in the graph , so the algorithm will choose with by definition of the edge weights. Further, we have , because the latter maximum is achieved by edge , and by definition of the residual graph, cannot use any edges with smaller capacity than . Combining these two bounds shows that achieves the minimum. This in turn implies that Algorithm 4 returns a constraint violated by if such a constraint exists.
Online routing: minimizing increase in the potential
For online virtual circuit routing, we assume that a sequence of source sink-pairs for arrive online. To implement Algorithm 3 efficiently, given a load vector and source-sink pair with random demand , we need to choose a - path in G that minimizes the increase in with respect to some fixed truncation threshold . Recall that we index the edges of G by , while is the load of an additional, artificial resource that captures the total expected exceptional load.
As in the offline setting, the expected exceptional part of the configuration corresponding to choosing a particular - path is the expected exceptional part of the smallest-capacity edge along the path. Thus, the increase in potential due to choosing a path P is
The first term is the increase due to the exceptional part (the smallest-capacity edge along P), and the remaining terms are the per-edge contributions due to the truncated parts. Analogously to the previous section, we only consider edges in , guess the smallest-capacity edge, and solve a shortest - path problem to find the minimizing path; see Algorithm 5.
Algorithm 5.
Minimizing increase in for virtual circuit routing
Lemma 15
Given a request j and load vector L, Algorithm 5 returns in polynomial time a path that minimizes the increase in .
Proof
It is clear that Algorithm 5 runs in polynomial time. To see that it also finds a path that minimizes the increase in , let be such an optimal path with smallest-capacity edge . For the correct guess , is a - path in the graph . Thus, Algorithm 5 chooses such that the per-edge contributions due to the truncated parts of are at most those due to by definition of the edge weights. Further, the exceptional part of is at most that of , because does not use any edges with capacity smaller than by definition of the graph . We conclude that is also a - path that minimizes the increase in .
Proof of Theorem 3
For offline virtual circuit routing, Lemma 14 guarantees that () can be solved optimally in polynomial time by LP duality. Thus, Lemma 10 implies that Algorithm 2 runs in polynomial time and achieves a maximum congestion of . For the online problem, Lemma 15 guarantees that, for each request j, a path that minimizes the increase in the potential function is found in polynomial time. Thus, Lemma 10 implies that Algorithm 3 runs in polynomial time and guarantees a maximum congestion of .
Load balancing on related machines
In this section, we improve on Theorem 2 in the special case of related machines, where each machine i has a speed parameter and each job j an independent size such that . Recall that we gave a non-adaptive -approximation for unrelated machines. However, the adaptivity gap is even for load balancing on identical machines where every machine has the same speed. Thus, to improve on Theorem 2, we need to use adaptivity.
The starting point of our improved algorithms is the same non-adaptive assignment for unrelated-machines load balancing. However, instead of non-adaptively assigning job j to the specified machine i, we adaptively assign j to the least loaded machine with similar speed to i. We formalize this idea and briefly explain the algorithms for offline and online load balancing on related machines.
Machine smoothing
In this part, we define a notion of smoothed machines. We show that by losing a constant factor in the approximation ratio, we may assume that the machines are partitioned into at most groups such that machines within a group have the same speed and the size of the groups shrinks geometrically. Thus, by “machines with similar speed to i,” we mean machines in the same group.
Formally, we transform an instance of load balancing on m related machines with stochastic jobs into an instance with so-called “smoothed machines” and the same set of jobs with the following three properties:
-
(i)
The machines are partitioned into groups such that group k consists of machines with speed exactly such that .
-
(ii)
For all groups , we have .
-
(iii)
.
To this end, we suitably decrease machine speeds and delete machines from the original instance . Our algorithm is the following.
Algorithm 6.
Machine Smoothing
We show that this algorithm creates the desired smoothed machines instance.
Lemma 16
There is an efficient algorithm that, given an instance of load balancing with m related machines and stochastic jobs, computes an instance of smoothed machines with the same set of jobs satisfying Properties (i) to (iii).
Proof
It is clear that the algorithm is efficient and outputs satisfying (i) and (ii). It remains to show (iii). To do so, we show that each step increases Opt by only a constant factor.
Recall that Opt is an adaptive policy, so when Opt decides to schedule job j on machine i, it immediately learns the realized value of , or equivalently on related machines. Hence, we may assume that the next scheduling decision of Opt is completely determined by the previously realized ’s. In particular, if Opt decides to schedule j on machine i, then we can modify Opt by scheduling j on some other machine and leaving the subsequent decisions (which in general depend on ) unchanged. Similarly, if we modify the speed of machine i, then this does not affect subsequent scheduling decisions.
Let denote the initial optimal policy. Consider the following adaptive policy for the instance after step 1: If Opt schedules j on i such that i is not deleted, then we also schedule j on i. Otherwise, Opt schedules j on i such that i is deleted for being too slow. Then we schedule j on the fastest machine. For every realization of job sizes, the modified policy only increases the load of the fastest machine. We delete at most machines each having speed at most . Thus, we schedule all jobs assigned to these machines on a machine that is at least m times faster. The increase in load on the fastest machine is thus at most . After deleting all slow machines, all machine speeds are in .
We decrease the speed of each machine by at most a factor 2, so the makespan of the optimal policy increases by at most a factor 2. Further, after rounding down the machine speeds, there are at most distinct speeds and thus groups.
- First, we note that we keep at least one group, namely the fastest one. Consider any group k that is deleted, and let be the fastest subsequent group that is kept. Because we delete all groups between k and , we have . Further, because all groups have distinct speeds that differ by at least a factor 2, we also have . Let be the optimal policy after step 2. By the above two steps, we have . We re-assign the jobs that schedules on group k to group as follows. Because , we fix a mapping from the machines in group k to those of such that each machine in is mapped to by at most machines in k. Then, when schedules a job on a machine in group k, we instead schedule it on the machine it maps to in group . This completes the description of our modified policy. To bound the makespan, consider any machine i in a kept group . We upper-bound the increase in load on i due to re-assignments from slower deleted groups. For any deleted group , at most machines from group k map to i. Each such machine in group k under policy has load at most . However, recall that i is at least a -factor faster than any machine in group k, so the increase in load on machine i due to deleted machines from group is at most . Summing over all , the total increase in load on a machine in group is at most
We conclude, the makespan of our final solution after 3 is at most , as required.
To summarize, by losing a constant-factor in our final approximation ratio, we may assume we are working with an instance of smoothed machines. Looking ahead, if our non-adaptive policy assigns job j to machine i, then we instead adaptively assign j to the least-loaded machine in the group containing machine i. We will use the properties of smoothed machines to show that this leads to a O(1)-approximation offline and -approximation online.
A similar idea for machine smoothing has been employed by Im et al. [34] for deterministic load balancing on related machines. In their approach, they ensure that the total processing power of the machines in a group decreases geometrically rather than the number of machines.
Offline setting
We run Algorithm 2 on the configuration balancing instance defined by the load balancing instance with smoothed machines. Given a job-to-machine assignment, we list schedule the jobs assigned to a particular group on the machines of this group. Precisely, our algorithm is the following.
Algorithm 7.
Offline Related Load Balancing
Note that as in the case of unrelated machine load balancing (Theorem 2), we can derandomize this algorithm by employing the GAP LP rounding algorithm by [7] at the loss of another factor 2 in the approximation ratio.
We show that this algorithm gives the desired O(1)-approximation. Note that our previous analysis of Theorem 2 gave a -approximation. We improve on this using the properties of smoothed machines and our adaptive decisions. In the proof, we rely on the following strong bound on the expected maximum of the truncated load; see Appendix A for a proof.
Lemma 17
Let be constants such that for all . Let be sums of independent random variables bounded in such that for all . Then, .
Now we analyze Algorithm 7.
Lemma 18
For offline load balancing on related machines with stochastic jobs, Algorithm 7 efficiently outputs an adaptive policy with expected makespan at most .
Proof
We let denote the optimal makespan of the input instance and the optimal makespan after machine smoothing.
The machine smoothing step runs in polynomial time by Lemma 16. As in the case of unrelated machines, the size of the configuration balancing instance is polynomial in the size of the input (since we have m configurations per job), so we can solve () in polynomial time. Thus, by Lemma 10, Algorithm 7 runs in polynomial time.
Note that we construct () with respect to the smoothed instance, so our final in Algorithm 2 satisfies by Lemma 8. Thus, we obtain a (random) job-to-machine assignment with expected truncated load at most on every machine and expected exceptional load at most . Summing up the truncated loads within each group with respect to the smoothed instance, we have that the total expected truncated load across all machines in group k is at most . Again, we split the makespan of our policy into truncated and exceptional parts
where the events are with respect to our final adaptive assignment. We can upper bound the contribution of the exceptional parts (the latter term) by using (1). It remains to bound the contribution of truncated parts. We do so by considering the makespan on each group. For group k, we let denote the event that we non-adaptively assign job j to a machine in group k, and be the size of job j on any machine in group k (recall that they all have the same speed). Then,
where is the collection of all machines in group k. Similar to the analysis of list scheduling by [2], i.e, by an averaging argument, we obtain
Plugging this into our bound on the contribution of truncated parts, we have
The expected truncated load on group k is at most , and we have for all k by the properties of smoothed instances. Thus, Lemma 17 gives , so we can upper bound the expected contribution of truncated parts by .
To conclude, combining our bounds on the truncated- and exceptional parts, the expected makespan of our algorithm is at most , where we use the facts and .
Online setting
We apply a similar framework as above. Note that our online configuration balancing algorithm loses a logarithmic factor in the number of resources, so to obtain a -approximation, we aggregate each group (in the smoothed-machines instance) to a single resource. Intuitively, this definition captures the fact that we will average all jobs assigned to a group over the machines in this group. Thus, our configuration balancing instance will have only resources and applying Theorem 1 proves Theorem 4.
We first describe how to construct the configuration balancing instance. Suppose we have smoothed machines with groups. We define resources indexed such that the 0th resource is a virtual resource collecting exceptional parts, and the resources index the groups of smoothed machines and collect the respective truncated parts. Each job j has configurations (one per job-to-group assignment) defined by
| 4 |
for a fixed truncation threshold . Note that these configurations are deterministic. Intuitively, this definition captures the fact that we will average all jobs assigned to group k over the machines in the group. Now we give our algorithm for the online setting.
Algorithm 8.
Online Related Load Balancing
Lemma 19
For online load balancing on related machines with stochastic jobs, Algorithm 8 runs in polynomial time and correctly solves the subproblem of Lemma 11 for .
Proof
It is clear that the algorithm runs in polynomial time.
Let be the optimal makespan of the smoothed load balancing instance. We first claim that the resulting configuration balancing instance has optimal makespan at most for any truncation threshold . To see this, observe that () for the smoothed load balancing instance is feasible for . Then, () for the deterministic configuration balancing instance is obtained from this LP by aggregating the truncated constraints for all machines in the same group and dividing by . Thus, this latter LP is also feasible for the same threshold, and it admits a constant-factor approximation by Shmoys-Tardos [7]. Thus, , the optimal solution of the deterministic configuration balancing instance defined by (4), is at most .
Further, by the properties of smoothed machines, the resulting configuration balancing instance has resources. As argued in the proof of Theorem 4, the potential function guarantees that Algorithm 3 never creates makespan (for the configuration balancing instance) more than if . Hence, by (4), the total expected exceptional load and average expected truncated load within each group are at most . We translate these bounds into bounds on the makespan for the load balancing instance.
Similar to Lemma 18, we can upper bound the contribution of the exceptional parts by using (1) and the truncated parts by using Lemma 17. Thus, the expected makespan of the load balancing instance is at most , as required.
Finally, we recall that if Algorithm 3 fails, then , which implies .
The proof of Theorem 4 follows immediately from Lemmas 18 and 19.
Conclusion
We considered the configuration balancing problem under uncertainty. In contrast to the (often overly optimistic) clairvoyant settings and the (often overly pessimistic) non-clairvoyant settings, we consider the stochastic setting where each request j presents a set of random vectors, and we need to (adaptively) pick one of these vectors, to minimize the expected maximum load over the m resources. We give logarithmic bounds for several general settings (which are existentially tight), and a much better O(1) offline and online bound for the related machines setting. Closing the gap for online related-machines load balancing remains an intriguing open problem. More generally, getting a better understanding of both adaptive and non-adaptive algorithms for stochastic packing and scheduling problems remains an exciting direction for research.
Acknowledgements
We would like to thank Viswanath Nagarajan for helpful discussions leading to the machine smoothing idea. The work of the first author was supported by the Dutch Research Council (NWO), Netherlands Vidi grant 016.Vidi.189.087; that of the second author was supported in part by NSF awards CCF-1955785, CCF-2006953, and CCF-2224718. Benjamin Moseley and Rudy Zhou were supported in part by ONR Award N000142212702, a Google Research Award, an Inform Research Award, a Carnegie Bosch Junior Faculty Chair, and NSF grants CCF-2121744 and CCF-1845146.
Appendix A Inequalities and bounds on sums of random variables
In this section, we state some useful probabilistic inequalities. Further, we give the proofs of Lemmas 9, 12, and 17.
Lemma 20
(Bernstein’s inequality) Let the random variables be independent with for each . Let and let be the variance of S. Then, for any ,
Lemma 21
(Bennett’s inequality [45]) Let be independent random variables with zero mean such that for all j. Let and . Then, for all ,
Lemma 22
(Chernoff-Hoeffding type inequality; Theorem 1.1 in [46]) Let where , , are independently distributed in [0, 1]. If , then
Having these inequalities at hand, we are now ready to prove Lemmas 9, 12, and 17, that bound the expected maximum of sums of independent variables.
Lemma 9
Let be sums of independent RVs bounded in for some such that for all . Then, .
Proof
By re-scaling, it suffices to prove the lemma for . Consider one such sum, say , where the s are independent and bounded in [0, 1]. We use Bennett’s inequality (Lemma 21) to bound the upper tail of S. Applying Bennett’s inequality to with and gives for any :
where we use in the third inequality. In particular, for large enough, we have for any :
This tail bound holds for all . Union-bounding over all m sums gives:
Lemma 12
Let be sums of independent RVs bounded in for such that for all . Then, .
Proof
Let be a constant such that for all and fix , where e is the Euler constant. Fixing , we know that the random variables constituting are independent and bounded by . Hence, using the Chernoff-Hoeffding bound in Lemma 22, we have . Therefore,
where the third line uses a union bound over all .
Lemma 17
Let be constants such that for all . Let be sums of independent random variables bounded in such that for all . Then, .
Proof
By re-scaling, we can assume . Fix one sum, say with . Towards applying Bernstein’s inequality, we first bound the variance,
where we used the independence of the ’s, the fact that , and the fact that . Further, note that and for all j. Thus, for any Bernstein’s inequality (Lemma 20) guarantees
Union-bounding over all such sums, we obtain for any
where we used in the second inequality and in the third inequality. For the fourth inequality, we use that, for and , we have . To see this, observe that , using the fact for all . Since , we further have . Taking the exponential of both sides and re-arranging gives the desired inequality.
Hence, we conclude the proof with
Appendix B Clairvoyance gap for load balancing on related machines
In this section, we quantify the power and limitation of non-clairvoyant algorithms for load balancing on related machines. Recall that a non-clairvoyant algorithm has no prior knowledge of the job sizes and must decide where to schedule a job using only the information about current machine loads and speeds. After an algorithm’s decision upon assigning a job, an adversary chooses the realized size of the job, which the algorithm then observes for subsequent decisions. We refer to a non-clairvoyant online algorithm as a non-clairvoyant algorithm that learns about the existence of jobs (of unknown size) online one by one.
Our goal is to approximate the optimal makespan achievable by a clairvoyant offline algorithm, which knows all jobs and sizes in advance, by a non-clairvoyant (online) algorithm. We define the clairvoyance gap as the maximum ratio between the makespan of an optimal non-clairvoyant algorithm and the optimal makespan achievable by a clairvoyant offline algorithm – precisely , where and are the makespan of the optimal non-clairvoyant and clairvoyant algorithms, respectively.
We show the following result.
Theorem 23
The clairvoyance gap for related machine scheduling is .
To show this result, we first give a lower bound on the clairvoyance gap and then complement it by an upper bound achieved by a non-clairvoyant online list scheduling algorithm.
Lemma 24
The clairvoyance gap for scheduling on related machines is .
Proof
Consider an instance with m machines, one fast machine with speed 1 and slow machines with speed . There are m jobs, one big job with size 1 and small jobs with size . There is a schedule of makespan 1, which is achieved by assigning the big job to the fast machine and one small job per slow machine.
We show that any non-clairvoyant algorithm has makespan which implies the lemma. To that end, we define the following adversarial strategy: the adversary reveals only small jobs (unless it runs out of small jobs, in which case the final job is big) until the first time that the algorithm decides to use a slow machine. Then the adversary makes this job big.
If an algorithm only uses the fast machine, then it has makespan . Otherwise, the algorithm must use a slow machine, which receives the big job from the adversary, which also gives makespan . Hence, any non-clairvoyant algorithm incurs a makespan .
In the next lemma, we show an upper bound on the clairvoyance gap. We refer to list scheduling as the algorithm that assigns the next job to the currently least-loaded machine. Here, the load of a machine is the total processing time of jobs that have been assigned to the machine. We use list scheduling only on a subset of machines that are “fast enough” and leave the remaining machines idle. More precisely, we list schedule the jobs in the order of their arrival on the machines with speeds within a factor of the fastest.
Lemma 25
The clairvoyance gap for related machine scheduling is .
Proof
For convenience, we re-scale the instance such that the speed of the fastest machine is 1. Hence, our algorithm uses all machines i with ; we call such machines fast and the remaining ones slow. Clearly, list scheduling on the fast machines is both, online and non-clairvoyant. It remains to bound the competitive ratio. To this end, we observe
where the first term bounds the starting time and the second term bounds the processing time of any job. We bound both terms separately by comparing to the optimal solution Opt, where Opt denotes the optimal schedule as well as its makespan. Clearly, , which implies that the second term is at most .
For the first term, note that the total size of jobs that Opt schedules on fast machines is at most , where is the number of fast machines. The total size of jobs that Opt schedules on slow machines is at most as there are at most m slow machines. Further, the total speed of the fast machines is at least 1 (because the fastest machine has speed 1) and also at least . Therefore,
concluding the proof.
Appendix C Integrality gap of ()
In this section, we define and bound the integrality gap of () by ; let us recall () here. 
For instance , let be the minimal value of such that () is feasible and let be the minimal value of such that () is feasible with the additional constraint that is integer for every and is feasible. Then, integrality gap is defined as , where the maximum is taken over all instances. Observe that is not only the right-hand side but also the truncation threshold.
To give a lower bound on said integrality gap, it is sufficient to restrict to the special case of congestion minimization and the corresponding linear program (). This allows us to use the following theorem from [4], which we rewrite for our purposes. (Note that some of the statement details are actually taken from its proof and not from the original theorem.)
Theorem 26
(Theorem 3 in [4]) For sufficiently large and any constant , there exists a directed graph with k vertices and edges each with unit capacity and a set of unit routing requests for such that there is a fractional flow of congestion at most and any integral flow on has a congestion at least .
Choosing a truncation threshold for the instance guaranteed by Theorem 26 implies that the truncated demand for each request coincides with the actual demand; in particular, the exceptional part equals 0. Hence, on these instances () (and hence ()) is equivalent to the following LP, where we use . 
Now we are ready to bound the integrality gap. It is easy to see that a fractional flow on corresponds to a fractional solution of (): Using the standard flow decomposition, we obtain the amount of flow sent along each path , and we set to be this value. Hence, Theorem 26 guarantees that () is feasible for . Thus, . Conversely, additionally requiring implies that the (unit) demand of each request needs to be sent along exactly one path; this in turn corresponds to an integral flow in network . Hence, Theorem 26 implies that since any integral flow causes congestion at least that big. Combining these two observations indeed implies that the integrality gap of () is at least .
Appendix D Online guess-and-double
Our online algorithm must find a good guess of such that . This requires dynamically doubling throughout the algorithm once our current guess is too small. This subproblem is captured by the next lemma, re-stated from Sect. 2.
Lemma 11
Given an instance of online configuration balancing with stochastic requests, suppose there exists an online algorithm that, given parameter , never creates an expected makespan more than , possibly terminating before handling all requests. Further, if the algorithm terminates prematurely, then it certifies that . Then, there exists an -competitive algorithm for online configuration balancing with stochastic requests. Further, the resulting algorithm preserves non-adaptivity.
The idea again is to guess a good threshold , but the main difference is that we must handle requests online on the way, so we need to bound the expected makespan over all doubling steps.
Concretely, let be the online algorithm assumed by the lemma. Upon arrival of the first request j (before assigning it), we initialize . Note we may assume the first request is non-trivial, i.e. not every configuration is the zero vector, so our initial guess satisfies . We begin running with parameter . If terminates before handling all requests, then we double and re-run with the doubled guess on the remaining requests.
As before, we need to show our final guess satisfies . This holds if the algorithms handles all requests for the initial guess. Otherwise, in every run of except the final one, we certify , so our final guess of satisfies . Note that the expected makespan of this run is at most .
The total expected makespan over all runs is upper bounded by the sum of expected makespans of each run. We can upper bound the expected makespan of a run by times the guess for that run, which geometrically decreases by a 2-factor in each previous run. We conclude, the total expected makespan is also at most , as required.
Funding
Open Access funding provided by Carnegie Mellon University.
Footnotes
An abridged version of this work appeared in the conference Integer Programming and Combinatorial Optimization (IPCO) 2023 [1].
Publisher's Note
Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.
References
- 1.Eberle, F., Gupta, A., Megow, N., Moseley, B., Zhou, R.: Configuration balancing for stochastic requests. In: Integer Programming and Combinatorial Optimization, IPCO 2023, pp. 127–141. 10.1007/978-3-031-32726-1_10
- 2.Graham, R.L.: Bounds on multiprocessing timing anomalies. J. SIAM Appl. Math. 17(2), 416–429 (1969) [Google Scholar]
- 3.Perez-Salazar, S., Singh, M., Toriello, A.: Adaptive bin packing with overflow. Math. Oper. Res. 47(4), 3317–3356 (2022). 10.1287/moor.2021.1239 [Google Scholar]
- 4.Leighton, T., Rao, S., Srinivasan, A.: Multicommodity flow and circuit switching. In: HICSS, pp. 459–465 (1998). 10.1109/HICSS.1998.649241
- 5.Aspnes, J., Azar, Y., Fiat, A., Plotkin, S.A., Waarts, O.: On-line routing of virtual circuits with applications to load balancing and machine scheduling. J. ACM 44(3), 486–504 (1997). 10.1145/258128.258201 [Google Scholar]
- 6.Azar, Y., Naor, J., Rom, R.: The competitiveness of on-line assignments. J. Algorithms 18(2), 221–237 (1995). 10.1006/jagm.1995.1008 [Google Scholar]
- 7.Shmoys, D.B., Tardos, É.: An approximation algorithm for the generalized assignment problem. Math. Program. 62, 461–474 (1993). 10.1007/BF01585178 [Google Scholar]
- 8.Gupta, A., Kumar, A., Nagarajan, V., Shen, X.: Stochastic load balancing on unrelated machines. Math. Oper. Res. 46(1), 115–133 (2021). 10.1287/moor.2019.1049 [Google Scholar]
- 9.Beale, E.M.L.: On minimizing a convex function subject to linear inequalities. J. R. Stat. Soc. Ser. B Methodol. 17, 173–184194203 (1955) [Google Scholar]
- 10.Dantzig, G.B.: Linear programming under uncertainty. Manag. Sci. 1, 197–206 (1955). 10.1287/mnsc.1040.0261 [Google Scholar]
- 11.Dye, S., Stougie, L., Tomasgard, A.: The stochastic single resource service-provision problem. Naval Res. Logist. 50(8), 869–887 (2003). 10.1002/nav.10092 [Google Scholar]
- 12.Möhring, R.H., Schulz, A.S., Uetz, M.: Approximation in stochastic scheduling: the power of lp-based priority policies. J. ACM 46(6), 924–942 (1999). 10.1145/331524.331530 [Google Scholar]
- 13.Charikar, M., Chekuri, C., Pál, M.: Sampling bounds for stochastic optimization. Proceed. APPROX. LNCS 3624, 257–269 (2005). 10.1007/11538462_22 [Google Scholar]
- 14.Gupta, A., Pál, M., Ravi, R., Sinha, A.: Sampling and cost-sharing: approximation algorithms for stochastic optimization problems. SIAM J. Comput. 40(5), 1361–1401 (2011). 10.1137/080732250 [Google Scholar]
- 15.Swamy, C., Shmoys, D.B.: Sampling-based approximation algorithms for multistage stochastic optimization. SIAM J. Comput. 41(4), 975–1004 (2012). 10.1137/100789269 [Google Scholar]
- 16.Bhalgat, A., Goel, A., Khanna, S.: Improved approximation results for stochastic knapsack problems. In: Proceedings of SODA, pp. 1647–1665 (2011). 10.1137/1.9781611973082.127
- 17.Dean, B.C., Goemans, M.X., Vondrák, J.: Approximating the stochastic knapsack problem: the benefit of adaptivity. Math. Oper. Res. 33(4), 945–964 (2008). 10.1287/moor.1080.0330 [Google Scholar]
- 18.Gupta, A., Krishnaswamy, R., Molinaro, M., Ravi, R.: Approximation algorithms for correlated knapsacks and non-martingale bandits. In: Ostrovsky, R. (ed.) Proceedings of FOCS, pp. 827–836 (2011). 10.1109/FOCS.2011.48
- 19.Ma, W.: Improvements and generalizations of stochastic knapsack and Markovian bandits approximation algorithms. Math. Oper. Res. 43(3), 789–812 (2018). 10.1287/moor.2017.0884 [Google Scholar]
- 20.Lenstra, J.K., Shmoys, D.B., Tardos, É.: Approximation algorithms for scheduling unrelated parallel machines. Math. Program. 46, 259–271 (1990). 10.1007/BF01585745 [Google Scholar]
- 21.Kleinberg, J.M., Rabani, Y., Tardos, É.: Allocating bandwidth for Bursty connections. SIAM J. Comput. 30(1), 191–217 (2000). 10.1137/S0097539797329142 [Google Scholar]
-
22.Molinaro, M.: Stochastic
p load balancing and moment problems via the l-function method. In: Proceedings of SODA, pp. 343–354 (2019). 10.1137/1.9781611975482.22
- 23.Ibrahimpur, S., Swamy, C.: Approximation algorithms for stochastic minimum-norm combinatorial optimization. In: Proceedings of FOCS, pp. 966–977 (2020). 10.1109/FOCS46700.2020.00094
- 24.Sagnol, G., Schmidt genannt Waldschmidt, D.: restricted adaptivity in stochastic scheduling. In: Proceedings of ESA. LIPIcs, vol. 204, pp. 79–17914 (2021). 10.4230/LIPIcs.ESA.2021.79
- 25.Gupta, V., Moseley, B., Uetz, M., Xie, Q.: Greed works - online algorithms for unrelated machine stochastic scheduling. Math. Oper. Res. 45(2), 497–516 (2020). 10.1287/moor.2019.0999 [Google Scholar]
- 26.Megow, N., Uetz, M., Vredeveld, T.: Models and algorithms for stochastic online scheduling. Math. Oper. Res. 31(3), 513–525 (2006). 10.1287/moor.1060.0201 [Google Scholar]
- 27.Möhring, R.H., Schulz, A.S., Uetz, M.: Approximation in stochastic scheduling: the power of lp-based priority policies. J. ACM 46(6), 924–942 (1999). 10.1145/331524.331530 [Google Scholar]
- 28.Schulz, A.S.: Stochastic online scheduling revisited. In: Yang, B., Du, D., Wang, C.A. (eds.) Proceedings of COCOA. LNCS, vol. 5165, pp. 448–457 (2008). 10.1007/978-3-540-85097-7_42
- 29.Skutella, M., Uetz, M.: Stochastic machine scheduling with precedence constraints. SIAM J. Comput. 34(4), 788–802 (2005). 10.1137/S0097539702415007 [Google Scholar]
- 30.Skutella, M., Sviridenko, M., Uetz, M.: Unrelated machine scheduling with stochastic processing times. Math. Oper. Res. 41(3), 851–864 (2016). 10.1287/moor.2015.0757 [Google Scholar]
- 31.Im, S., Moseley, B., Pruhs, K.: Stochastic scheduling of heavy-tailed jobs. In: Mayr, E.W., Ollinger, N. (eds.) Proceedings of STACS, vol. 30, pp. 474–486 (2015). 10.4230/LIPIcs.STACS.2015.474
- 32.Azar, Y.: On-line load balancing. In: Online Algorithms. LNCS, vol. 1442, pp. 178–195 (1996). 10.1007/BFb0029569
- 33.Berman, P., Charikar, M., Karpinski, M.: On-line load balancing for related machines. J. Algorithms 35(1), 108–121 (2000). 10.1006/jagm.1999.1070 [Google Scholar]
- 34.Im, S., Kell, N., Panigrahi, D., Shadloo, M.: Online load balancing on related machines. In: Proceedings of STOC, pp. 30–43 (2018). 10.1145/3188745.3188966
- 35.Im, S., Kell, N., Kulkarni, J., Panigrahi, D.: Tight bounds for online vector scheduling. SIAM J. Comput. 48(1), 93–121 (2019). 10.1137/17M111835X [Google Scholar]
- 36.Agrawal, S., Devanur, N.R.: Fast algorithms for online stochastic convex programming. In: Proceedings of SODA, pp. 1405–1424 (2015). 10.1137/1.9781611973730.93
- 37.Agrawal, S., Wang, Z., Ye, Y.: A dynamic near-optimal algorithm for online linear programming. Oper. Res. 62(4), 876–890 (2014). 10.1287/opre.2014.1289 [Google Scholar]
- 38.Gupta, A., Molinaro, M.: How the experts algorithm can help solve lps online. Math. Oper. Res. 41(4), 1404–1431 (2016). 10.1287/moor.2016.0782 [Google Scholar]
-
39.Kesselheim, T., Molinaro, M., Singla, S.: Online and bandit algorithms beyond
norms. In: Proceedings of SODA, pp. 1566–1593 (2023). 10.1137/1.9781611977554.ch58
- 40.Hajiaghayi, M.T., Kim, J.H., Leighton, T., Räcke, H.: Oblivious routing in directed graphs with random demands. In: Proceedings of STOC, pp. 193–201 (2005). 10.1145/1060590.1060619
- 41.Raghavan, P., Thompson, C.D.: Randomized rounding: a technique for provably good algorithms and algorithmic proofs. Combinatorica 7(4), 365–374 (1987). 10.1007/BF02579324 [Google Scholar]
- 42.Chuzhoy, J., Guruswami, V., Khanna, S., Talwar, K.: Hardness of routing with congestion in directed graphs. In: Proceedings of STOC, pp. 165–178 (2007). 10.1145/1250790.1250816
- 43.Leonardi, S.: On-line network routing. In: Online Algorithms. LNCS, vol. 1442, pp. 242–267 (1996). 10.1007/BFb0029572
- 44.Bellman, R.: On a routing problem. Q. Appl. Math. 16, 87–90 (1958) [Google Scholar]
- 45.Bennett, G.: Probability inequalities for the sum of independent random variables. JASA 57(297), 33–45 (1962). 10.1080/01621459.1962.10482149 [Google Scholar]
- 46.Dubhashi, D.P., Panconesi, A.: Concentration of Measure for the Analysis of Randomized Algorithms. Cambridge University Press, Cambridge (2009) [Google Scholar]








