Shadow experiment for a non-serviced multi-tenant cloud service
By using a shadow query engine in multi-tenant cloud services to optimize configuration parameters during off-peak periods, the problem of low query execution efficiency was solved, resulting in improved resource utilization, reduced response time, and improved performance to meet peak demand.
Patent Information
- Application Number
- CN202180059868.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Priority Date
- 2020-08-04
- Filing Date
- 2021-08-02
- Publication Date
- 2025-12-30
- Estimated Expiration
- 2041-08-02
AI Technical Summary
In multi-tenant cloud services, existing technologies struggle to efficiently optimize query execution, leading to resource waste and prolonged response times, especially during peak demand periods, which negatively impacts user experience.
By using a shadow query engine to execute historical queries during off-peak periods, recording metadata and analyzing the correlation of configuration parameters, the optimal configuration parameter values are determined and used to optimize the configuration of the main query engine during peak periods. Machine learning is also used for query classification and optimization.
It optimizes query execution, reduces resource waste, improves response speed, adapts to peak demand, and enhances system efficiency without affecting the existing user experience.
Smart Images

Figure CN116158047B_ABST
Abstract
Description
Background Technology
[0001] This invention relates generally to the field of query optimization, and more specifically to the optimization of query execution in multi-tenant cloud services.
[0002] Information retrieval (IR) is the activity of retrieving information system resources relevant to information needs from a collection of resources. Searches can be based on full-text or other content-based indexes. Information retrieval is the science of searching for information within documents, searching the documents themselves, and searching metadata describing data as well as databases of text, images, or sound. The information retrieval process begins when a user enters a query into the system. Queries are formal statements of information needs, such as search strings in web search engines. In information retrieval, a query does not uniquely identify a single object in a collection. Instead, several objects may match a query and may have different levels of relevance.
[0003] Cloud services are any service available to users on demand from a cloud computing provider's servers via the internet, rather than from a company's own on-premises servers. Cloud services are designed to provide easy, scalable access to applications, resources, and services, and are fully managed by the cloud service provider. Cloud storage is a model for storing computer data where digital data is stored in logical pools. Physical storage devices span multiple servers (and sometimes multiple locations), and the physical environment is typically owned and managed by a hosting company. These cloud storage providers are responsible for keeping the data available and accessible, and the physical environment is protected and operational. People and organizations purchase or rent storage capacity from providers to store user, organizational, or application data. Summary of the Invention
[0004] Various aspects of the present invention disclose a method, computer program product, and system for query execution in a multi-tenant cloud service. The method includes one or more processors determining a category class for service queries. The method also includes one or more processors sending a selected number of service queries from one of the determined category classes to a shadow query engine for execution. Relevant service queries in the categorized service queries include different sets of configuration parameter values for the shadow query engine. The method further includes one or more processors recording metadata of the selected number of service queries of the one category class executed on the shadow query engine. The metadata includes performance data, the query category class, and at least one value of relevant configuration parameter values. The method also includes one or more processors determining a correlation between the performance data, the query category class, and at least one value of relevant configuration parameter values. The method further includes one or more processors determining optimal configuration parameter values from the determined correlation, the optimal configuration parameter values including optimal configuration parameters for executing the selected number of service queries of the one category class.
[0005] In another embodiment, the method further includes one or more processors applying a configuration based on optimal configuration parameter values to an extended set of service queries of the same class on the shadow query engine. The method also includes one or more processors validating the applied configuration. In response to a positive validation result, the method further includes one or more processors using the configuration with optimal configuration parameter values to execute future queries of the same class from a query engine that has the same characteristics as the shadow query engine. Attached Figure Description
[0006] It should be noted that embodiments of the invention are described with reference to different subject matter. Specifically, some embodiments are described with reference to method type claims, while others are described with reference to apparatus type claims. However, those skilled in the art will conclude from the above and below description that, unless otherwise indicated, any combination of features relating to different subject matter (specifically, features of method type claims and features of apparatus type claims) is also considered to be disclosed in this document, except for any combination of features belonging to one type of subject matter.
[0007] The aspects defined above and other aspects of the invention will be apparent from examples of the embodiments described below, and will be explained with reference to these examples, but the invention is not limited thereto. Preferred embodiments of the invention will be described by way of example only and with reference to the following drawings.
[0008] Figure 1 A block diagram is shown of an embodiment of a method for optimizing query execution in a multi-tenant cloud service according to an embodiment of the present invention.
[0009] Figure 2 A general block diagram illustrating the establishment between an application and a query engine according to an embodiment of the present invention is depicted.
[0010] Figure 3 A block diagram depicting an embodiment of the proposed inventive concept, describing the main building blocks according to an embodiment of the present invention.
[0011] Figure 4 A block diagram depicts an embodiment of a query optimization system for optimizing query execution in a multi-tenant cloud service according to an embodiment of the present invention.
[0012] Figure 5 The invention describes an embodiment including, according to, Figure 4 An example of a computational system for a query optimization system.
[0013] Figure 6 A cloud computing environment according to an embodiment of the present invention is described.
[0014] Figure 7 An abstract model layer according to an embodiment of the present invention is described. Detailed Implementation
[0015] In the context of this specification, the following conventions, terms and / or expressions may be used:
[0016] The term 'multi-tenant cloud service' can refer to a program that receives data when invoked for execution and, typically in a cloud computing environment, delivers the results back to the calling system. A detailed description of a cloud computing environment can be found below. In any case, a multi-tenant cloud service can be made available to multiple users.
[0017] The term 'service query' can refer to a call from a first service (i.e., the first executed part of the program) to another service (i.e., another executed part of the program, such as a query engine service), which includes parameter values for querying data accessible to the second service. After the query has been executed, the second service can return the retrieved data to the calling service (i.e., the first service). However, this general rule may be broken if a shadow query engine is invoked. Here, the query can be executed only for the optimization process regarding the configuration parameters of the relevant service. The retrieved data does not necessarily need to be delivered back to the original service that initiated the service call to the (main) query engine (not the shadow query engine).
[0018] The term 'shadow query engine' can refer to a program typically implemented as a service in a multi-tenant cloud computing environment that works identically to a query engine in active use or a query service used to retrieve data from a database or other data storage. Specifically, a shadow query engine can be configured, when invoked, to have the same type of configuration and execution parameters as a regular query engine in operational use. Therefore, a shadow query engine can be considered a copy of the query engine in operational use. In one particular embodiment, the query engine and the shadow query engine may be implemented at least partially (or entirely) in hardware.
[0019] The term 'over-provisioned cloud computing environment' refers to a cloud computing environment that can be implemented and configured to provide more computing and service resources than typically required by multiple users and tenants. Excess capacity can be required without response time degradation during peak demand periods for one or more tenants.
[0020] The term 'machine learning-based system' can refer to a system or service operating in a teaching or artificial intelligence paradigm. This system is not programmed to follow procedural instructions, but rather learns how to respond to incoming data based on learned methods through experimentation, according to accepted and understood concepts. Thus, the concepts of supervised, semi-supervised, and unsupervised learning can be used as part of embodiments of the concepts presented herein. The learning concepts can be specifically applied to the current classification task to categorize historical queries into query categories. For example, the maximum number of classes to be used can be a starting parameter for a machine learning service.
[0021] The term 'Spark' (specifically, from...) Apache Spark Foundation TM Spark can represent a known open-source distributed general-purpose cluster computing framework. TM It provides an interface for programming entire clusters with implicit data parallelism and fault tolerance.
[0022] The term 'cloud computing' and its equivalent 'cloud service environment' can be interpreted in this context as a model that allows convenient, on-demand network access to a shared pool of configurable computing resources (e.g., networks, servers, storage, applications, and services) that can be rapidly provisioned and released with minimal management effort or service provider interaction. The cloud model promotes availability and consists of at least five basic characteristics, three service models, and four deployment models.
[0023] It can be noted that cloud software fully leverages the cloud paradigm by focusing on service orientation, statefulness (with exceptions), loose coupling, modularity, and semantic interoperability.
[0024] The proposed computer implementation method for optimizing query execution in multi-tenant cloud services offers several advantages, contributions, and technical benefits.
[0025] The embodiments of this invention recognize that the ever-increasing volume of structured, semi-structured, and unstructured data in enterprise storage systems is constantly increasing the demand for effective data management and retrieval tools. Therefore, in order to generate value from existing data lakes, ever-growing amounts of data must be analyzed, combined, and retrieved. Consequently, the number of databases and the excessively proportional growth in data queries are a consequence. Often, enterprise data is at least partially stored on cloud storage systems and accessed by services operating in cloud computing environments. However, whether deployed on-premises or as cloud services, data retrieval applications and services require increasingly more computing resources.
[0026] As a result, embodiments of the present invention further recognize that programmers are increasingly seeking efficient data retrieval and querying techniques, even in large cloud computing environments where query engines are frequently deployed as query services. Specifically, relational databases (whether row-oriented or column-oriented) have been optimized for query performance for decades. In-memory computing and ever-growing caching systems are currently being used to reduce database query response times. Therefore, there is space and demand for even better querying techniques that help reduce the computational resources required for the same number of queries.
[0027] Embodiments of the present invention allow for continuous optimization of configuration parameter settings for query engines in typically service-based multi-tenant cloud computing environments. Example embodiments of the invention can use spare capacity, typically available in multi-tenant cluster systems, to continuously check numerous configuration variations at a reasonable resource cost to meet peak demand, but not use the spare capacity during normal resource consumption periods.
[0028] Therefore, embodiments of the present invention can optimize complex systems without knowing how different configurations can alter behavior, which can be achieved without disrupting existing customer workloads and negatively impacting the typical response time and resource consumption of conventionally deployed query engines.
[0029] Another advantage is that shadow execution of the shadow query engine can be completed synchronously or deferred (i.e., optimizations are performed based on historical queries). However, in such cases, deferred execution may include handling access token expiration and changes to the input dataset.
[0030] In the following sections, further embodiments of the method applicable to related systems will be described. According to one permissible embodiment of the method, configuration parameters (or more precisely, configuration parameter values) may include at least one selected from the group consisting of: memory size, buffer size, serialization options, compression parameter values, networking parameter values, scheduling-specific values, and execution option values. Values associated with configuration parameters may be Spark... TM Specific, and allows for a wide variety of tuning parameter values to influence the functionality of the shadow query engine as well as the functionality of the query engine actually used after the optimization process.
[0031] According to embodiments of this method, each service query can be associated with a database query. A wide variety of databases can be used. For example, relational databases, object-oriented databases, semi-structured databases, content management systems, text search engines, NoSQL databases (Structured Query Language), and databases like Apache Solr. TM (A known open-source search engine) or another known open-source search engine service. Therefore, according to various embodiments of the invention, the concepts presented herein can be applied to virtually any database affected by the parameter settings of its execution environment.
[0032] According to an advantageous embodiment of the method, the number of service queries for a selected category class can originate from a user group. This user group may involve a tenant in a multi-user cloud computing environment. Assuming comparable queries involve a single tenant, query optimization can be tenant- or customer-specific. In another embodiment, the selected number of service queries may involve selected applications within an application group, such as an enterprise resource management system, a customer relationship management system, or a supply chain management system. Therefore, query optimization can be application- or application group-specific.
[0033] According to another advantageous embodiment of the method, the expanded set of service queries can originate from more than one user group. Therefore, optimizations implemented from a sample query from one tenant can also be used for other tenants, and thus for other user groups or application systems. Thus, query optimizations achieved for one user can also be used for other clients without requiring the same amount of system resources to determine the configuration parameters for the optimization.
[0034] According to an example embodiment of this method, this category typically involves data definition operations. Specifically, data definition operations can be, but are not limited to, SQL statements, spatial queries, time series queries, data join operations, write access, data deletion operations, aggregation operations, union operations, data grouping operations, sorting statements, or string operations. Furthermore, this method can be applied to any type of query in any type of database.
[0035] According to another advantageous embodiment of the method, a shadow query engine can be selected from a set of alternative query engines in an over-provisioned cloud computing environment. Therefore, performance degradation of the production system can be measurable, and no active users may see any response time degradation. Typically, in a cloud computing environment, some additional resources are available to enable the flexibility and resilience that cloud environment services are built for.
[0036] According to another exemplary embodiment of the method, the optimal configuration parameter value can reflect (i.e., be a function of) at least one operational constraint selected from group wait time, throughput, resource usage, and combinations thereof. Therefore, the system administrator can select different priorities for optimization.
[0037] According to an alternative embodiment of this method, the category can be determined by applying a machine learning-based system to a set of historical queries against a query engine. The goal of this feature can be to identify well-distinguished categories. Supervised, semi-supervised, and unsupervised machine learning systems can be used for such classification tasks.
[0038] According to another embodiment of the method, the multi-tenant cloud service can be based on Spark. TM The computing environment is based on Spark. TM Technology (e.g., any version) Spark TM Cloud computing environments are very popular today, and therefore, the large user base of such environments can benefit from the concepts proposed herein. However, the inventive concept is not limited to Apache Spark. TM Furthermore, it can also be implemented on or within other cloud computing frameworks.
[0039] A detailed description of the accompanying drawings is given below. All instructions in the drawings are illustrative. First, block diagrams of embodiments of a method for optimizing query execution in a multi-tenant cloud service are provided according to different embodiments of the present invention. Then, embodiments of a query optimization system for optimizing query execution in a multi-tenant cloud service, and other embodiments according to various embodiments of the present invention, will be described.
[0040] Figure 1 A block diagram depicts an exemplary embodiment of a computer implementation of a method 100 for optimizing query execution in a multi-tenant cloud service according to various embodiments of the present invention.
[0041] In step 102, the computer-implemented method 100 includes determining a category class for service queries. Then, in step 104, the computer-implemented method 100 includes sending a selected number of service queries from one of the category classes (specifically, repeated isolated experiments) to a shadow query engine for query execution. For example, each of the categorically classified service queries includes a different set of configuration parameter values for the shadow query engine. The selected number of service queries from one category class is relatively low compared to the total number of queries sent for execution within a predetermined time period. The time period can be selected in the context of the underlying application that requires query results. This time period can be a few seconds after an hour (e.g., 1s, 10s, 100s, 1 minute, 10 minutes, 1 hour), but can be kept within approximately 10% of the total queries within the selected time period. Furthermore, the shadow query engine should, in terms of characteristics, be equivalent to the query engine in actual use on which queries are executed.
[0042] In another embodiment, instead of running each query of a class with different configuration parameters when executed by the shadow query engine, the shadow query engine can also run the same query with different configuration parameters, which can increase the amount of data logged and analyzed in the next step. In other embodiments, a combination of the two alternatives is considered a viable option.
[0043] In step 106, the computer-implemented method 100 further includes recording metadata about a selected number of service queries of a category class executed on the shadow query engine. Thus, the metadata includes at least one value selected from a group comprising at least one value from performance data, query category class, and related configuration parameter values. Therefore, the computer-implemented method 100 can collect data describing the characteristics and actual functionality of the shadow query engine.
[0044] In step 108, the computer-implemented method 100 further includes determining a correlation. In various embodiments, the computer-implemented method 100 determines a correlation between at least one of performance data, a query category class, and a relevant configuration parameter value. Then, in step 110, the computer-implemented method 100 includes determining an optimal configuration parameter value based on the correlation. In various embodiments, the optimal configuration parameter value includes optimal configuration parameters for performing a selected number of service queries of one of the category classes.
[0045] In step 112, the computer-implemented method 100 includes applying a configuration having initial optimal configuration parameter values for execution to an expanded set of service queries of the same class on a shadow query engine to validate the configuration. The expanded set may (compared to a selected number of queries that may only come from a single user of a single tenant in a multi-user cloud computing environment) originate from individual users of the same tenant or a mixture of queries from different tenants. In an exemplary embodiment, according to an embodiment of the invention, the computer-implemented method 100 initiates step 112 as... Figure 1 The second stage of the process.
[0046] In step 114, the computer-implemented method 100 includes, upon a positive verification result (from step 112), executing future queries of the same class from either the main query engine or the active query engine (as opposed to the shadow query engine) using a configuration with optimal configuration parameter values. In an example embodiment, the query engine and the shadow query engine have the same characteristics. As a result of this method, optimized execution parameter value settings for the active query engine can be implemented based on configuration parameter settings determined by the shadow query engine during idle time in the cloud computing environment.
[0047] Figure 2 A block diagram depicts a general setup 200 between an application 204 and a query engine 210 according to an embodiment of the present invention. The application 204 may have a user interface 202. The user interface 202 may continuously generate queries represented as different classes 206, 208, which are sent to the query engine 210 for execution, and return the query results to the application 203 represented by the data path 214.
[0048] In various embodiments, the described functionality is implemented as a service serving multiple tenants and users in a cloud computing environment. In another exemplary embodiment, the research execution environment (i.e., configuration and / or resources) cannot be maintained for each tenant or each user. Query engine 210 can be any type of engine, such as using Spark. TM This is achieved through a computational framework. On the other hand, different query engines can be used across tenants based on a suitable query model. Different shadow query engines can also be used in this regard. Therefore, the defined system utilizes some over-provisioning to respond to spikes in query demand. Thus, the system can typically have some spare capacity that may not be supplied to customers (i.e., tenants).
[0049] In another embodiment, the query engine can be invoked with different configuration parameter values (e.g., memory size, serialization options, etc.) that can affect the execution characteristics of the query engine instance (e.g., latency, throughput, etc.). Some queries may only run with specific configurations because otherwise, errors such as out-of-memory errors could occur. Furthermore, the configuration parameter settings are determined by the query service, not by the user and other tenants. Additionally, certain categories of queries require different configuration parameter settings for the best user experience given system capacity.
[0050] Therefore, embodiments of the present invention recognize the need to solve optimization problems. Continuously, optimal configuration parameter values must be selected to execute newly arriving queries. An appropriate set of configuration values must be selected so that the system is available in an "idle" state. Therefore, embodiments of the present invention recognize the need to solve and explore complex optimization problems with large variance spaces. Furthermore, the team running the query engine may only have limited insight into the internals of the query engine. Embodiments of the present invention recognize that typical known solutions rely on the operator's experience using a fixed average set of configuration parameters. Furthermore, the set surrounding the selected class of queries 212 (in... Figure 2 In the description), it is in Figure 3 It plays a role in the process.
[0051] Figure 3 A block diagram illustrating an exemplary embodiment 300 of the proposed inventive concept, showing the main components according to an embodiment of the present invention, is shown. From Figure 2 The repeated example is a type of query 208, with a selected set of configuration parameter values 304 associated with this type of query. A shadow query engine 302 is also shown that executes a selected set of queries 212 of a query class. In an exemplary embodiment, the query engine 302 is hidden from the user and is not used in a production environment to return results to the user. In another embodiment, the query results do not serve any further purpose because they are not used for further processing.
[0052] However, the query execution metadata 308 is recorded in a specific storage area 306 and set in relation to the selected set of query and configuration parameter values 304. Embodiments of the invention can now activate the correlation unit 310 to determine the correlation between the query category, the selected set of configuration parameter values, and the resulting performance data (such as memory usage, response time, throughput, etc.). Based on the correlation analysis, embodiments of the invention can subsequently determine an optimized set 312 of configuration parameter values for the shadow query engine 302.
[0053] In determination 314, embodiments of the invention may check whether the optimal set 312 is already an expanded set based on queries of the selected category. If the optimal set 312 is not an expanded set based on queries of the selected category (determination 314, no branch), the process returns to the beginning, and the aforementioned activity flow is repeated using an expanded set 208 of historical queries of the same category. In this second phase, embodiments of the invention may test and determine whether the determined optimal configuration parameter values of the shadow query engine 302 continue to be the same as the selected query set 212. If the determined optimal configuration parameter values of the shadow query engine 302 do not continue to be the same as for the selected query set 212, another set of the selected query set 212 is selected. Thus, embodiments of the invention may subsequently continue to repeat the optimization process until an optimal configuration parameter set 312 of the shadow query engine 302 is determined for the selected query category. An expanded set 208 of historical queries may be selected from multiple tenants and / or users.
[0054] Therefore, if the optimal configuration parameter value set 312 is found in the extended set 208 based on the class-based historical query, the embodiments of the present invention can transmit the set of optimal configuration parameter setting values to ( Figure 2 The query engine 210 is used as the configuration parameter value for future queries of the selected class (determine 314, yes (YES) branch).
[0055] This process is repeated for other (e.g., all) query categories. Thus, embodiments of the invention can utilize the standard capacity of a cloud computing environment. In different embodiments, the optimization process may be performed only during periods when the cloud has spare capacity, and not during peak usage periods of cloud resources.
[0056] It is worth noting that sampling (i.e., selecting the number of queries selected from the selected query set 212) can be based on the fact that query clustering based on machine learning (ML) (based on a dedicated, predefined distance function). The target class can be based on the constructs and / or operators used in the query (e.g., aggregation, geospatial join, etc.) derived from the query parser. Furthermore, the characteristics of the data used as input to the query can be concatenated in the query's classification (e.g., distributed across more / less than n partitions), containing spatial data, originating from a specific source, or targeting data based on predefined data sinks (e.g., from...). Reading, i.e., Apache for stream processing The data is sent to COS (i.e., Cloud Object Store). However, any other combination of data sources / slots is possible.
[0057] Figure 4A block diagram depicts an embodiment of a query optimization system 400 for optimizing query execution in a multi-tenant cloud service according to an embodiment of the present invention. The query optimization system 400 includes a first determining means, particularly a first determining unit 402, adapted to determine a category class of service queries. The query optimization system 400 also includes a sending means, particularly a sending unit 404, adapted to send a selected number of service queries of one of the category classes to a shadow query engine for execution. Thus, according to various embodiments of the present invention, each of the categorized service queries includes a different set of configuration parameter values for the shadow query engine.
[0058] The query optimization system 400 also includes a recording device, specifically a recorder 406, adapted to record metadata of a selected number of service queries of one category executed on the shadow query engine. In an exemplary embodiment, the metadata includes at least one selected from the group consisting of: performance data, query category class, and at least one value of relevant configuration parameter values, and a determining device adapted to determine relevance, specifically a second determining unit 408. For example, at least one correlation between performance data, query category class, and at least one value of relevant configuration parameter values, and the determining device. Specifically, a third determining unit 410 is adapted to determine optimal configuration parameter values based on the correlation, the optimal configuration parameter values including optimal configuration parameters for executing the selected number of service queries of one of the category classes.
[0059] Furthermore, the query optimization system 400 also includes application means, specifically application module 412, which is adapted to apply a configuration with optimal configuration parameter values for execution to an extended set of service queries of the same class on the shadow query engine to verify the configuration. The sending means (i.e., sender 404) is also adapted to: if a positive result of verification has been found, use the configuration with the optimal configuration parameter values for the execution of future queries of the same class in the query engine. Thus, in various embodiments, the query engine and the shadow query engine can have the same characteristics.
[0060] It can be noted that the units and modules of the query optimization system 400 should communicate with each other to exchange signals. Specifically, the first determining unit 402, the transmitter 404, the recorder 406, the second determining unit 408, the third determining unit 410, and the application module 412 are communicatively connected in this manner. Alternatively, these units and modules may communicate via the system's internal bus system 414.
[0061] Embodiments of the present invention can be implemented with virtually any type of computer, regardless of whether the platform is suitable for storing and / or executing program code. As an example, Figure 5A computing system 500, according to various embodiments of the present invention, is described as being suitable for executing program code (e.g., at least one of many nodes in a multi-tenant cloud computing cluster) related to the proposed method.
[0062] The computing system 500 is merely one example of a suitable computer system and is not intended to impose any limitation on the scope or functionality of the embodiments of the invention described herein, regardless of whether the computer system 500 is capable of implementing and / or performing any of the functions set forth above. In the computer system 500, there are components that can operate with many other general-purpose or special-purpose computing system environments or configurations. Examples of well-known computing systems, environments, and / or configurations suitable for use with the computer system / server 500 include, but are not limited to, personal computer systems, server computer systems, thin clients, thick clients, handheld or laptop devices, multiprocessor systems, microprocessor-based systems, set-top boxes, programmable consumer electronics, network PCs, minicomputer systems, mainframe computer systems, and distributed cloud computing environments that include any of the above systems or devices. The computer system / server 500 can be described in the general context of computer system executable instructions, such as program modules, that are executed by the computer system 500. Generally, program modules may include routines, programs, objects, components, logic, data structures, etc., that perform a specific task or implement a specific abstract data type. The computer system / server 500 can be implemented in a distributed cloud computing environment in which tasks are performed by remote processing devices linked via a communication network. In a distributed cloud computing environment, program modules can reside on local and remote computer system storage media (including memory storage devices).
[0063] like Figure 5As shown, the computer system / server 500 is illustrated as a general-purpose computing device. Components of the computer system / server 500 may include, but are not limited to, one or more processors or processing units 502, system memory 504, and a bus 506 coupling the various system components, including system memory 504, to the processor 502. Bus 506 represents one or more of several types of bus architectures, including memory buses or memory controllers, peripheral buses, accelerated graphics ports, and processor or local buses using any of a variety of bus architectures. By way of example and not limitation, such architectures include Industry Standard Architecture (ISA) buses, Micro Channel Architecture (MCA) buses, Enhanced ISA (EISA) buses, Video Electronics Standards Association (VESA) local buses, and Peripheral Component Interconnect (PCI) buses. The computer system / server 500 typically includes a variety of computer system readable media. Such media can be any available media accessible by the computer system / server 500, and includes both volatile and non-volatile media, removable and non-removable media.
[0064] System memory 504 may include computer system readable media in the form of volatile memory, such as random access memory (RAM) 508 and / or cache memory 510. Computer system / server 500 may further include other removable / non-removable, volatile / non-volatile computer system storage media. By way of example only, storage system 512 may be configured to read from and write to non-removable, non-volatile magnetic media (not shown, and generally referred to as 'hard disk drives'). Although not shown, disk drives for reading from and writing to removable, non-volatile disks (e.g., 'floppy disks') and optical disc drives for reading from or writing to removable, non-volatile optical discs such as CD-ROMs, DVD-ROMs, or other optical media may be provided. In such cases, each may be connected to bus 506 via one or more data media interfaces. As will be further described and depicted below, memory 504 may include at least one program product having a set (e.g., at least one) of program modules configured to perform embodiments of the invention.
[0065] A program / utility having a set (at least one) of program modules 516, along with an operating system, one or more applications, other program modules, and program data, may be stored in memory 504 in an exemplary, and not limited, manner. Each or some combination of the operating system, one or more applications, other program modules, and program data may include an implementation of a network environment. Program modules 516 typically perform the functions and / or methods of embodiments of the invention, as described herein.
[0066] The computer system / server 500 can also communicate with one or more external devices 518, such as a keyboard, pointing device, display 520, etc.; one or more devices that enable a user to interact with the computer system / server 500; and / or any device that enables the computer system / server 500 to communicate with one or more other computing devices (e.g., network interface card, modem, etc.). Such communication may occur via input / output (I / O) interface 514. Furthermore, the computer system / server 500 can communicate with one or more networks, such as a local area network (LAN), a general wide area network (WAN), and / or a public network (e.g., the Internet), via network adapter 522. As depicted, network adapter 522 can communicate with other components of the computer system / server 500 via bus 506. It should be understood that, although not shown, other hardware and / or software components may be used in conjunction with the computer system / server 500. Examples include, but are not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data archiving storage systems.
[0067] In addition, a query optimization system 400 for optimizing query execution in multi-tenant cloud services can be attached to a bus system 506.
[0068] It should be understood that while this disclosure includes a detailed description of cloud computing, the implementation of the teachings cited herein is not limited to cloud computing environments. Rather, embodiments of the invention can be implemented in conjunction with any other type of computing environment now known or developed hereafter.
[0069] Cloud computing is a service delivery model that enables convenient, on-demand network access to a shared pool of configurable computing resources (e.g., networks, network bandwidth, servers, processing, memory, storage, applications, virtual machines, and services), which can be rapidly provisioned and released with minimal management effort or interaction with the service provider. This cloud model may include at least five features, at least three service models, and at least four deployment models.
[0070] The features are as follows:
[0071] On-demand self-service: Cloud consumers can unilaterally and automatically provide computing power, such as server time and network storage, as needed, without requiring human interaction with the service provider. Extensive network access: Capabilities are available via the network and accessed through standard mechanisms that facilitate the use of heterogeneous thin or thick client platforms (e.g., mobile phones, laptops, and PDAs).
[0072] Resource pooling: A provider's computing resources are pooled to serve multiple consumers using a multi-tenant model, where different physical and virtual resources are dynamically assigned and reassigned as needed. There is a sense of location independence because consumers typically do not have control or knowledge of the exact location of the resources provided, but may be able to specify the location at a higher level of abstraction (e.g., country, state, or data center).
[0073] Rapid flexibility: The ability to provide capacity quickly and flexibly, automatically scaling down and up rapidly in some situations to scale up rapidly. For consumers, the available supply capacity often appears unlimited and can be purchased in any quantity at any time.
[0074] Measuring services: Cloud systems automatically control and optimize resource usage by leveraging metering capabilities at a level of abstraction appropriate to the service type (e.g., storage, processing, bandwidth, and active user accounts). Resource usage can be monitored, controlled, and reported, providing transparency to both service providers and consumers.
[0075] The service model is as follows:
[0076] Software as a Service (SaaS): This provides consumers with the ability to use the provider's applications running on cloud infrastructure. Applications can be accessed from different client devices via thin client interfaces such as web browsers (e.g., web-based email). Consumers do not manage or control the underlying cloud infrastructure, including the network, servers, operating system, storage, or even individual application capabilities, with possible exceptions such as limited user-specific application configuration settings.
[0077] Platform as a Service (PaaS): This provides consumers with the ability to deploy applications created or acquired by the consumer using programming languages and tools supported by the provider onto cloud infrastructure. Consumers do not manage or control the underlying cloud infrastructure, including networks, servers, operating systems, or storage, but they have control over the deployed applications and the configuration of any application hosting environment.
[0078] Infrastructure as a Service (IaaS): The capabilities offered to consumers are processing, storage, networking, and other basic computing resources that enable consumers to deploy and run arbitrary software, which may include operating systems and applications. Consumers do not manage or control the underlying cloud infrastructure, but rather have control over the operating system, storage, deployed applications, and potentially limited control over selected networking components (e.g., host firewalls).
[0079] The deployment model is as follows:
[0080] Private cloud: The cloud infrastructure operates solely for an organization. It can be managed by the organization or a third party and can exist on-site or off-site. Community cloud: The cloud infrastructure is shared by several organizations and supports a specific community sharing concerns (e.g., tasks, security requirements, policies, and compliance considerations). It can be managed by the organization or a third party and can exist on-site or off-site.
[0081] Public cloud: Makes cloud infrastructure available to the public or large industry groups and is owned by an organization that sells cloud services.
[0082] Hybrid cloud: A cloud infrastructure is a combination of two or more clouds (private, community, or public) that remain a single entity but are bound together by standardized or proprietary technologies that enable data and applications to be ported (e.g., cloud bursting for load balancing between clouds).
[0083] Cloud computing environments are service-oriented, focusing on statelessness, loose coupling, modularity, and semantic interoperability. At the heart of cloud computing is the infrastructure comprising a network of interconnected nodes.
[0084] See now Figure 6 The diagram illustrates an illustrative cloud computing environment 50. As shown, the cloud computing environment 50 includes one or more cloud computing nodes 10 to which local computing devices used by cloud consumers can communicate. These local computing devices include, for example, personal digital assistants (PDAs) or cellular phones 54A, desktop computers 54B, laptop computers 54C, and / or automotive computer systems 54N. The nodes 10 can communicate with each other. They can be physically or virtually grouped (not shown) in one or more networks, such as private clouds, community clouds, public clouds, or hybrid clouds, or combinations thereof, as described above. This allows the cloud computing environment 50 to provide infrastructure, platforms, and / or software as services that cloud consumers do not need to maintain on their local computing devices. It should be understood that... Figure 6 The types of computing devices 54A-N shown are intended to be illustrative only, and computing node 10 and cloud computing environment 50 can communicate with any type of computerized device via any type of network and / or network-addressable connection (e.g., using a web browser).
[0085] See now Figure 7 This demonstrates a cloud computing environment of 50 ( Figure 6 This provides a set of functional abstractions. It should be understood beforehand. Figure 7 The components, layers, and functions shown are intended to be illustrative only, and embodiments of the invention are not limited thereto. As described, the following layers and corresponding functions are provided:
[0086] The hardware and software layer 60 includes hardware and software components. Examples of hardware components include: a mainframe 61; a RISC (Reduced Instruction Set Computer) based server 62; a server 63; a blade server 64; a storage device 65; and network and networking components 66. In some embodiments, software components include network application server software 67 and database software 68.
[0087] The virtualization layer 70 provides an abstraction layer from which the following examples of virtual entities can be provided: virtual server 71; virtual storage 72; virtual network 73, including virtual private network; virtual application and operating system 74; and virtual client 75.
[0088] In one example, management layer 80 may provide the following functionalities: Resource Provisioning 81 provides dynamic procurement of computing resources and other resources used to perform tasks within the cloud computing environment. Metering and Pricing 82 provides cost tracking as resources are utilized within the cloud computing environment and bills or invoices for the consumption of these resources. In one example, these resources may include application software licenses. Security provides authentication for cloud consumers and tasks, as well as protection for data and other resources. User Portal 83 provides access to the cloud computing environment for consumers and system administrators. Service Level Management 84 provides cloud resource allocation and management to ensure that required service levels are met. Service Level Agreement (SLA) Planning and Fulfillment 85 provides pre-scheduling and procurement of cloud resources based on anticipated future needs according to the SLA.
[0089] Workload layer 90 provides examples of functionalities that can leverage a cloud computing environment. Examples of workloads and functionalities that can be provided from this layer include: mapping and navigation 91; software development and lifecycle management 92; virtual classroom education delivery 93; data analytics and processing 94; transaction processing 95; and software 96. In various embodiments of the invention, software 96 represents a query optimization system, for example... Figure 4 The query optimization system 400.
[0090] The procedures described herein are identified based on their implementation in specific embodiments of the invention. However, it should be understood that any particular procedural terminology used herein is for convenience only, and therefore the invention should not be limited to use only in any particular application identified and / or implied by such terminology.
[0091] This invention can be a system, method, and / or computer program product with any possible level of technical detail integration. The computer program product may include a computer-readable storage medium (or media) having computer-readable program instructions thereon for causing a processor to execute aspects of the invention.
[0092] Computer-readable storage media can be tangible means for retaining and storing instructions for use by an instruction execution device.
[0093] Computer-readable storage media can be, for example, but not limited to, electronic storage devices, magnetic storage devices, optical storage devices, electromagnetic storage devices, semiconductor storage devices, or any suitable combination of the foregoing. A non-exhaustive list of more specific examples of computer-readable storage media includes: portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), static random access memory (SRAM), portable compact disc read-only memory (CD-ROM), digital universal disc (DVD), memory sticks, floppy disks, mechanical encoding devices such as punch cards or protrusions in slots having instructions recorded thereon, and any suitable combination of the foregoing. As used herein, computer-readable storage media should not be construed as transient signals themselves, such as radio waves or other freely propagating electromagnetic waves, electromagnetic waves propagating through waveguides or other transmission media (e.g., light pulses passing through fiber optic cables), or electrical signals transmitted through wires.
[0094] The computer-readable program instructions described herein can be downloaded from a computer-readable storage medium to a suitable computing / processing device via a network (e.g., the Internet, a local area network, a wide area network, and / or a wireless network), or to an external computer or external storage device. The network may include copper cables, optical fibers, wireless transmissions, routers, firewalls, switches, gateway computers, and / or edge servers. A network adapter card or network interface in each computing / processing device receives the computer-readable program instructions from the network and forwards them to a computer-readable storage medium within the suitable computing / processing device.
[0095] Computer-readable program instructions used to perform the operations of this invention may be assembly instructions, instruction set architecture (ISA) instructions, machine instructions, machine-dependent instructions, microcode, firmware instructions, state setting data, integrated circuit configuration data, or source code or object code written in any combination of one or more programming languages, including object-oriented programming languages (such as Smalltalk, C++, etc.) and procedural programming languages (such as the "C" programming language or similar programming languages). The computer-readable program instructions may be executed entirely on a user's computer, partially on a user's computer, as a standalone software package, partially on a user's computer and partially on a remote computer, or entirely on a remote computer or server. In the latter case, the remote computer may be connected to the user's computer via any type of network (including a local area network (LAN) or a wide area network (WAN)) or may be connected to an external computer (e.g., via the Internet using an Internet service provider). In some embodiments, electronic circuitry including, for example, programmable logic circuitry, field-programmable gate arrays (FPGAs), or programmable logic arrays (PLAs) may execute computer-readable program instructions by utilizing state information from the computer-readable program instructions to personalize the electronic circuitry in order to perform aspects of this invention.
[0096] The present invention will now be described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It should be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer-readable program instructions.
[0097] These computer-readable program instructions may be provided to a processor of a computer or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions / actions specified in one or more blocks of a flowchart and / or block diagram. These computer-readable program instructions may also be stored in a computer-readable storage medium that causes a computer, programmable data processing apparatus, and / or other device to operate in a particular manner, such that the computer-readable storage medium storing the instructions includes an article of manufacture containing instructions that implement aspects of the functions / actions specified in one or more blocks of a flowchart and / or block diagram.
[0098] Computer-readable program instructions may also be loaded onto a computer, other programmable data processing apparatus, or other device to cause a series of operational steps to be performed on the computer, other programmable apparatus, or other device to produce computer-implemented processing, such that the instructions executed on the computer, other programmable apparatus, or other device perform the functions / actions specified in one or more boxes of a flowchart and / or block diagram.
[0099] The flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to various embodiments of the present invention. Each block in a flowchart or block diagram may represent a module, segment, or portion of instructions, including one or more executable instructions for implementing a specified logical function. In some alternative implementations, the functions marked in the blocks may occur in a different order than those marked in the figures. For example, two blocks shown consecutively may actually be completed as a single step, executed simultaneously, substantially simultaneously, or with partial or complete temporal overlap, or the blocks may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, may be implemented using a dedicated hardware-based system that performs the specified function or action or executes a combination of dedicated hardware and computer instructions.
[0100] Various embodiments of the invention have been described for illustrative purposes, but are not intended to be exhaustive or limited to the disclosed embodiments. Many modifications and variations will be apparent to those skilled in the art without departing from the scope and spirit of the invention. The terminology used herein has been chosen to best explain the principles of the embodiments, their practical application, or technical improvements over those found in the market, or to enable those skilled in the art to understand the embodiments disclosed herein.
Claims
1. A computer-implemented method for query execution in a multi-tenant cloud service, the method comprising: sending, by one or more processors, a selected number of service queries of one category class of one or more category classes to a shadow query engine for execution, wherein a service query of the selected number of service queries includes a different set of configuration parameter values; recording, by one or more processors, metadata of the selected number of service queries of the one category class executed on the shadow query engine, wherein the metadata includes at least one of performance data, query category class, and related configuration parameter values; determining, by one or more processors, one or more correlations between the performance data, the query category class, and at least one of the related configuration parameter values; applying, by one or more processors, a configuration to an expanded set of service queries of the same category class on the shadow query engine based on a best set of configuration parameter values of the selected number of service queries of the one category class, wherein the best set of configuration parameter values is determined based on the determined one or more correlations; in response to applying the configuration to the expanded set of service queries, verifying, by one or more processors, that the configuration applied to the expanded set of service queries of the same category class on the shadow query engine has a positive outcome; and in response to the verification outcome being positive, executing, by one or more processors, future queries of the same category class on an active query engine while the active query engine is in use, wherein the active query engine has the same characteristics as the shadow query engine and is configured with the determined best set of configuration parameter values of the shadow query engine, wherein the determined best set of configuration parameter values is determined by the shadow query engine during off-peak hours of a cloud computing environment associated with the multi-tenant cloud service.
2. The computer-implemented method of claim 1, wherein, The configuration parameters include at least one selected from the group consisting of memory size, buffer size, serialization options, compression parameter values, networking parameter values, scheduling specific values, and execution option values.
3. The computer-implemented method of claim 1, wherein, Each of the service queries is related to a database query.
4. The computer-implemented method of claim 1, wherein, The selected number of service queries of the one category class originates from a group of users.
5. The computer-implemented method of claim 1, wherein, The expanded set of service queries originates from more than one group of users.
6. The computer-implemented method of any one of claims 1 to 5, wherein, The category class relates to data definition operations.
7. The computer-implemented method of claim 6, further comprising: selecting, by one or more processors, the shadow query engine from a group of spare query engines of an over-provisioned cloud computing environment.
8. The computer-implemented method of claim 1, wherein, The best set of configuration parameter values reflects at least one operational constraint selected from the group consisting of latency, throughput, and resource usage.
9. The computer-implemented method of claim 1, further comprising: determining, by one or more processors, the one or more category classes by applying a machine learning based system to a group of historical queries of the shadow query engine.
10. A computer program product for query execution in a multi-tenant cloud service, the computer program product comprising program instructions, the program instructions comprising: program instructions for sending a selected number of service queries of one category class of one or more category classes to a shadow query engine for execution, wherein a service query of the selected number of service queries includes a different set of configuration parameter values; program instructions for recording metadata of the selected number of service queries of the one category class executed on the shadow query engine, wherein the metadata includes at least one of performance data, query category class, and related configuration parameter values; program instructions for determining one or more correlations between the performance data, the query category class, and at least one of the related configuration parameter values; program instructions for applying a configuration to an expanded set of service queries of the same category class on the shadow query engine based on a best set of configuration parameter values of the selected number of service queries of the one category class, wherein the best set of configuration parameter values is determined based on the determined one or more correlations; program instructions for verifying that the configuration applied to the expanded set of service queries of the same category class on the shadow query engine has a positive outcome in response to applying the configuration to the expanded set of service queries; and program instructions for executing future queries of the same category class on an active query engine in use by the active query engine in response to the verification result being positive, wherein the active query engine has the same characteristics as the shadow query engine and is configured with the determined best set of configuration parameter values of the shadow query engine, wherein the determined best set of configuration parameter values is determined by the shadow query engine during off-peak hours of a cloud computing environment associated with the multi-tenant cloud service.
11. The computer program product of claim 10, wherein, The configuration parameters include at least one selected from a group consisting of memory size, buffer size, serialization options, compression parameter values, networking parameter values, scheduling specific values, and execution option values.
12. The computer program product of claim 10, wherein, Each of the service queries is related to a database query.
13. A computer system for query execution in a multi-tenant cloud service, the computer system comprising: one or more computer processors; one or more computer-readable storage media; and program instructions stored on the computer-readable storage media for execution by at least one of the one or more computer processors, the program instructions comprising: program instructions for sending a selected number of service queries of one category class of one or more category classes to a shadow query engine for execution, wherein a service query of the selected number of service queries includes a different set of configuration parameter values; program instructions for recording metadata of the selected number of service queries of the one category class executed on the shadow query engine, wherein the metadata includes at least one of performance data, query category class, and related configuration parameter values; program instructions for determining one or more correlations between the performance data, the query category class, and at least one of the related configuration parameter values; program instructions for applying a configuration to an expanded set of service queries of the same category class on the shadow query engine based on a best set of configuration parameter values of the selected number of service queries of the one category class, wherein the best set of configuration parameter values is determined based on the determined one or more correlations; program instructions for applying the configuration to an expanded set of service queries of the same category class on the shadow query engine based on the selected number of service queries of the one category class, wherein the optimal set of configuration parameter values is determined based on the determined one or more correlations; program instructions for verifying that applying the configuration to the expanded set of service queries has a positive outcome; program instructions for executing, on an active query engine, future queries of the same category class while the active query engine is in use in response to the verification outcome being positive, wherein the active query engine has the same characteristics as the shadow query engine and is configured with the determined optimal set of configuration parameter values of the shadow query engine, wherein the determined optimal set of configuration parameter values is determined by the shadow query engine during off-peak hours of a cloud computing environment associated with the multi-tenant cloud service.
14. The computer system of claim 13, wherein, The configuration parameters include at least one selected from the group consisting of memory size, buffer size, serialization options, compression parameter values, networking parameter values, scheduling specific values, and execution option values.
15. The computer system of claim 13, wherein, Each of the service queries is related to a database query.
16. The computer system of claim 13, wherein, The selected number of service queries of the one category class originate from a group of users.
17. The computer system of claim 13, wherein, The optimal configuration parameter values reflect at least one operational constraint selected from the group consisting of latency, throughput, and resource usage. The configuration parameters include at least one selected from the group consisting of memory size, buffer size, serialization options, compression parameter values, networking parameter values, scheduling specific values, and execution option values. Each of the service queries is related to a database query. The selected number of service queries of the one category class originate from a group of users. The optimal configuration parameter values reflect at least one operational constraint selected from the group consisting of latency, throughput, and resource usage.
Citation Information
Patent Citations
Method, equipment and system for managing shared objects of a plurality of lessees based on cloud computation
CN102651775A
Automatic prevention of run-away query execution
US20050177557A1
Stateful resource pool management for job execution
US20180060132A1
Managed query service
US20180060393A1
Optimizing search system resource usage and performance using multiple query processing systems
US9141665B1