# Profit-Efficient Elastic Allocation of Cloud Resources Using Two-Stage Adaptive Workload Prediction
###### Abstract  
Internet services are increasingly being deployed using cloud computing. However, the workload of an Internet service is not constant; therefore, the required cloud computing resources need to be allocated elastically to minimize the associated costs. Thus, this study proposes a proactive cloud resource scheduling framework. First, we propose a new workload prediction method--named the adaptive two-stage multi-neural network based on long short-term memory (LSTM)--which can adaptively route prediction tasks to the corresponding LSTM sub-model according to the workload change trend (i.e., uphill and downhill categories), in order to improve the predictive accuracy. To avoid the cost associated with manual labeling of the training data, the first-order gradient feature is used with the \(k\)-means algorithm to cluster and label the original training data set automatically into uphill and downhill training data sets. Then, based on stochastic queueing theory and the proposed prediction method, a maximum cloud service profit resource search algorithm based on the network workload prediction algorithm is proposed to identify a suitable number of virtual machines (VMs) in order to avoid delays in resource adjustment and increase the service profit. The experimental results demonstrate that the proposed proactive adaptive elastic resource scheduling framework can improve the workload prediction accuracy (MAPE: 0.0276, RMSE: 3.7085, \(R^{2}\): 0.9522) and effectively allocate cloud resources. cloud computing; elastic resource allocation; workload prediction; queueing theory; maximum service profit +
Footnote †: journal: Applied sciences  
To solve these problems, resource managers in cloud computing should allocate resources adaptively, according to the on-demand workload requirements (i.e., adaptive elastic resource allocation). This solution avoids resource over- or under-provision, guarantees QoS, and decreases service costs. Adaptive elastic resource allocation in cloud computing requires finding the correct amount of computing resources at a given time to automatically meet QoS requirements under variable workloads. The challenge has been addressed in two ways: First, reactive methods, such as those presented in [4; 5; 6], use pre-defined thresholds to adjust the resources adaptively after a change in workload. Due to the large-scale distributed structure of cloud centers, computing resource schedulers that use these methods may lag behind the workload changes, thus impairing the QoS. Other methods include proactive methods, such as those in [7; 8; 9], which adjust the resources depending on the predicted future workload. These methods can adapt to the future workload before its occurrence, in order to avoid delays in resource adjustment. However, the workload prediction accuracy impacts the correction of the resource scheduling. Thus, improving the accuracy of such predictions is a key research direction in cloud computing. Meanwhile, the cost of computing resource management in the cloud is high due to the large-scale distributed structure of cloud centers. Moreover, it is difficult to achieve the real- and small-time granularity requirements for resource scheduling and adjustment. Most popular platforms for infrastructure-as-a-service (IaaS), such as Amazon Web Service, Rackspace, and Aliyun, use one hour as the billing time interval and time granularity. This approach requires building a task processing model in the cloud center using one-hour intervals to obtain a suitable resource size under the optimization objective (e.g., cost or profit optimization). However, real- or fine-time granularity methods cannot solve this problem. Above all, this study focuses on a proactive method for elastic cloud computing resource allocation, including improving the workload prediction accuracy and designing a resource allocation method.