Cloud application service cost determination method, device, system, equipment and medium
By obtaining and analyzing cloud IaaS instance configuration and user task information in real time, optimizing cloud resource allocation, solving the problem of unreasonable use of public cloud resources, realizing accurate assessment of cloud application service costs and efficient utilization of resources, and improving user experience and Provider revenue.
Patent Information
- Application Number
- CN202411380175.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-30
- Publication Date
- 2024-11-08
AI Technical Summary
In the prior art, the different service models and user uncertainty of public clouds have caused cloud application service providers to be unable to reasonably purchase and allocate resources, resulting in application service providers being unable to perform user tasks efficiently and accurately evaluate cloud application service costs, which harms both parties. Benefit.
By obtaining the configuration information of cloud IaaS instances and the user's cloud application task information in real time, determining the number and duration of instances, and then calculating the cloud application service cost used by the user, and using real-time acquisition of the supply information of multiple IaaS instances, based on the instance type , price and configuration information determine priority, and allocate calculation amount and time according to task type (parallel tasks or workflow tasks) to optimize the purchase and use of instance resources.
It has achieved reasonable purchase and allocation of cloud resources based on user needs, improved the execution efficiency of cloud application tasks, accurately estimated costs, reduced resource waste, and improved the benefits and user experience of application service providers.
Smart Images

Figure CN118916149A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of cloud application technology, and in particular to a method, device, system, equipment and medium for determining cloud application service costs. Background Art
[0002] With the rapid development and popularization of cloud computing technology, many application service providers have turned to using public cloud infrastructure as a service (IaaS) to achieve cost-effectiveness and scale advantages. Generally speaking, public clouds provide two service modes: flexible on-demand instances and economical reserved instances. On-demand instances allow users to adjust the number of instances at any time as needed, which is suitable for rapidly changing business needs, but the price is relatively high. Reserved instances require users to pay in advance to reserve a certain number of instances. They are suitable for long-term stable operations, with relatively low prices and discounts. However, in the relevant technology, there is no method to purchase and allocate resources in real time according to the different service modes of public clouds and the uncertainty and diversified needs of users, which makes it unreasonable for cloud application service providers to purchase and use public cloud resources, resulting in the inability of application service providers to efficiently perform user tasks and accurately evaluate the cost of cloud application services for users, which damages the interests of application service providers and users. Summary of the invention
[0003] The present invention provides a cloud application service cost determination method, device, system, equipment and medium, which are used to solve the problem that there is no method in the prior art to purchase and allocate resources in real time according to different service modes of public clouds and the uncertainty and diversified needs of users, resulting in unreasonable purchase and use of public cloud resources by cloud application service providers, causing the application service provider to be unable to efficiently perform user tasks and accurately evaluate user costs, thereby damaging the interests of the application service provider and users.
[0004] The present invention provides a method for determining cloud application service costs, comprising the following steps: Get the configuration information of cloud IaaS instances in real time; Obtaining the user's cloud application task information, and determining the number of instances and duration corresponding to the cloud application task information based on the cloud application task information and configuration information; Determine the cost of using cloud applications based on the number of instances and duration.
[0005] According to a cloud application service cost determination method provided by the present invention, configuration information of a cloud IaaS instance is obtained in real time, including: Obtain supply information from multiple IaaS instance suppliers in real time, including instance type information, instance price information, and instance specific configuration information; Based on the instance type information, instance price information and instance specific configuration of each supplier, the configuration information of the cloud IaaS instance provided by each supplier is determined. The configuration information is used to indicate the usage priority of the cloud application task.
[0006] According to a cloud application service cost determination method provided by the present invention, cloud application task information of a user is obtained, and based on the cloud application task information and configuration information, the number of instances and duration corresponding to the cloud application task information are determined, including: Obtain the user's cloud application task information and determine the task type based on the cloud application task information; Based on the cloud application task information, task type and configuration information, determine the number of instances and duration corresponding to the cloud application task information.
[0007] According to a cloud application service cost determination method provided by the present invention, the task type includes a parallelizable task and a workflow task. When the task type is a parallelizable task, the number of instances and the duration corresponding to the cloud application task information are determined based on the cloud application task information, the task type and the configuration information, including: Determine the cloud application computing amount and completion time based on the cloud application task information; Evenly distribute the computational amount of parallelizable tasks to the completion time to obtain the computational amount at each moment; The number of instances and duration are determined based on the configuration information and the amount of computation at each moment.
[0008] According to a cloud application service cost determination method provided by the present invention, the task type includes a parallelizable task and a workflow task. When the task type is a workflow task, the number of instances and the duration corresponding to the cloud application task information are determined based on the cloud application task information, the task type and the configuration information, including: Determine the cloud application computing amount and completion time based on the cloud application task information; Assign the completion time from the last subtask of the workflow task forward to obtain the completion time of each subtask; According to the computing amount of cloud applications and the completion time of each subtask, the computing amount at each moment is obtained; The number of instances and duration are determined based on the configuration information and the amount of computation at each moment.
[0009] According to a cloud application service cost determination method provided by the present invention, the cost of a user using a cloud application is determined according to the number of instances and the duration, including: Determine currently available instances based on historical cloud application task information and instance purchase information; Determine the instances that need to be purchased based on the currently available instances, number of instances, and duration; The usage cost is determined based on the currently available instances and the instances that need to be purchased.
[0010] The present invention also provides a cloud application service cost determination device, comprising the following units: An acquisition unit, used to acquire configuration information of a cloud IaaS instance in real time; A determination unit, configured to obtain the user's cloud application task information, and determine the number of instances and duration corresponding to the cloud application task information based on the cloud application task information and configuration information; Processing units are used to determine the cost of using cloud applications based on the number of instances and duration.
[0011] According to a cloud application service cost determination device provided by the present invention, the acquisition unit is specifically used for: Obtain supply information from multiple cloud IaaS instance suppliers in real time, including instance type information, instance price information, and instance specific configuration information; Based on the instance type information, instance price information and instance specific configuration of each supplier, the configuration information of the cloud IaaS instance provided by each supplier is determined. The configuration information is used to indicate the usage priority of the cloud application task.
[0012] According to a cloud application service cost determination device provided by the present invention, the determination unit is specifically used for: Obtain the user's cloud application task information and determine the task type based on the cloud application task information; Based on the cloud application task information, task type and configuration information, determine the number of instances and duration corresponding to the cloud application task information.
[0013] According to a cloud application service cost determination device provided by the present invention, the task type includes a parallelizable task and a workflow task. When the task type is a parallelizable task, the determination unit is specifically used to: Determine the cloud application computing volume and completion time based on the cloud application task information; Evenly distribute the computational amount of parallelizable tasks to the completion time to obtain the computational amount at each moment; The number of instances and duration are determined based on the configuration information and the amount of computation at each moment.
[0014] According to a cloud application service cost determination device provided by the present invention, the task type includes a parallelizable task and a workflow task. When the task type is a workflow task, the determination unit is specifically used to: Determine the cloud application computing volume and completion time based on the cloud application task information; Assign the completion time from the last subtask of the workflow task forward to obtain the completion time of each subtask; According to the computing amount of cloud applications and the completion time of each subtask, the computing amount at each moment is obtained; The number of instances and duration are determined based on the configuration information and the amount of computation at each moment.
[0015] According to a cloud application service cost determination device provided by the present invention, the processing unit is specifically used for: Determine currently available instances based on historical cloud application task information and instance purchase information; Determine the instances that need to be purchased based on the currently available instances, number of instances, and duration; The usage cost is determined based on the currently available instances and the instances that need to be purchased.
[0016] The present invention also provides a cloud application service cost determination system, which includes a unified service entry module, a cloud instance management module, a cloud application service transaction algorithm module, a task execution module and a log recording module, wherein: The unified service entry module is used to provide users with a graphical interface and an accessible programming interface, receive users' cloud application task information and feedback the results of executing cloud application tasks; The cloud instance management module is used to obtain the configuration information of cloud application services in real time, and purchase and manage IaaS instances based on the number and duration of instances required by users; A cloud application service transaction algorithm module, used to determine the number of instances, duration, and cloud application service cost required by the user based on the cloud application task information; The task execution module is used to execute cloud application tasks based on the number of instances and duration corresponding to each user, and to feed back the results of executing the cloud application tasks to the user through the unified service entry module; The logging module is used to record the operation log.
[0017] The present invention also provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, any of the cloud application service cost determination methods described above is implemented.
[0018] The present invention also provides a non-transitory computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements any of the cloud application service cost determination methods described above.
[0019] The present invention also provides a computer program product, including a computer program, which implements any of the above-mentioned cloud application service cost determination methods when executed by a processor.
[0020] The cloud application service cost determination method provided by the present invention first obtains the configuration information of the cloud IaaS instance in real time, then obtains the user's cloud application task information when the user arrives, and determines the number of instances and duration required for the cloud application task based on the cloud application task information and the IaaS instance configuration information; finally, the instances that need to be purchased are determined according to the number of instances and the duration, and then the use cost of the user's use of the cloud application is determined. It can reasonably purchase and allocate the execution of user cloud application tasks according to the user's needs and the configuration of each cloud IaaS instance, and accurately estimate the cloud application service cost, avoid the shortage or waste of instance resources, improve the execution efficiency of cloud application tasks, reduce its costs while increasing the revenue of cloud application providers, and improve user experience. BRIEF DESCRIPTION OF THE DRAWINGS
[0021] In order to more clearly illustrate the technical solutions in the present invention or the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0022] Figure 1 It is a flow chart of the cloud application service cost determination method provided by the present invention.
[0023] Figure 2 It is a specific flow chart of the cloud application service cost determination method provided by the present invention.
[0024] Figure 3 It is a structural diagram of the cloud application service cost determination device provided by the present invention.
[0025] Figure 4 It is a structural diagram of the cloud application service cost determination system provided by the present invention.
[0026] Figure 5 It is a structural schematic diagram of the electronic device provided by the present invention. DETAILED DESCRIPTION
[0027] In order to make the purpose, technical solution and advantages of the present invention clearer, the technical solution of the present invention will be clearly and completely described below in conjunction with the drawings of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0028] With the maturity and popularization of cloud computing technology, considering issues such as cost and economies of scale, many application service providers no longer maintain and operate their own computing centers. Instead, they turn to flexibly purchasing Infrastructure as a Service, or cloud IaaS instances, from public clouds based on actual demand to schedule and complete tasks submitted by users. They charge users based on the performance of the tasks, thus forming a new cloud application service market.
[0029] In order to facilitate users and meet the needs of various users, public cloud IaaS providers have developed different service models for cloud computing instances. Specifically, according to the length of time they can be used, cloud computing instances include on-demand instances and reserved instances, and their pricing strategies are also different. Cloud on-demand instances are instances that can be created and destroyed at any time as needed. Users only need to pay when they use them, and there is no need to commit to the purchase quantity or duration in advance. Therefore, the use of cloud on-demand instances is very flexible. Users can increase or decrease the number of instances at any time as needed, which is suitable for scenarios that require rapid response to changes in business needs. Due to higher flexibility, the unit price of cloud on-demand instances is usually higher than that of cloud reserved instances. Cloud reserved instances require users to reserve a certain number of instances in advance and pay a certain fee to ensure that the required computing resources can be obtained when needed.
[0030] However, due to the uncertainty of cloud application users that have not yet arrived, application service providers are unable to reasonably select and allocate on-demand and reserved instance resources, and are unable to accurately assess users' cloud application service costs, resulting in unreasonable use and allocation of public cloud resources, causing damage to the profits of application service providers and users.
[0031] Therefore, there is an urgent need for a cloud application service cost determination method to solve the above problems.
[0032] Combine the following Figure 1-Figure 5 The cloud application service cost determination method, apparatus, system, device and medium of the present invention are described.
[0033] Figure 1 is one of the flow charts of the cloud application service cost determination method provided by the present invention, such as Figure 1 As shown, the method includes the following: Step 101: Obtain configuration information of the cloud IaaS instance in real time.
[0034] In specific implementation, supply information of multiple cloud IaaS instance suppliers is obtained in real time, and the supply information includes instance type information, instance price information and instance specific configuration.
[0035] Specifically, the number, price, available time, operating status, remaining usage time and other information of cloud computing instances are collected regularly through the application programming (API) interface or tools provided by the IaaS supplier, and saved in the database for cloud instance status monitoring and subsequent task execution. In addition to the general management interface, the IaaS supplier also provides users with a variety of interfaces and tools to help users obtain data closely related to their instances. Considering that different users have different requirements for real-time monitoring, users can adjust the monitoring interval through the detailed monitoring function to obtain instance usage data according to their own needs.
[0036] After obtaining the supply information related to the cloud instance, data cleaning and abstract extraction are required to filter out useless data, standardize the relevant data according to unified specifications and save it in the database to support subsequent instance management functions and service transaction decisions.
[0037] In order to improve the reading and writing efficiency, this embodiment selects a distributed remote dictionary service (RemoteDictionary Server, Redis) database based on memory storage to store relevant information. Redis database is a non-relational (Not OnlySQL, NoSQL) database with high reading and writing performance, supports rich data structures, and is suitable for storing a variety of data. Of course, other storage methods can also be selected, and the embodiment of the present invention does not limit this.
[0038] After obtaining the supply information, the configuration information of the cloud IaaS instance provided by each supplier is determined based on the instance type information, instance price information and instance specific configuration information of each supplier, and the configuration information is used to indicate the usage priority of the cloud application task.
[0039] Step 102: Obtain the user's cloud application task information, and determine the number of instances and duration corresponding to the cloud application task information based on the cloud application task information and configuration information.
[0040] In the specific implementation, the user's cloud application task information is first obtained, and the task type is determined based on the cloud application task information. Then, based on the task type and configuration information, the number of instances and duration corresponding to the cloud application task information are determined. Task types include parallel tasks and workflow tasks. Parallel tasks refer to tasks that can be arbitrarily split into multiple subtasks and scheduled to multiple cloud instances for simultaneous execution. Workflow tasks refer to tasks that consist of multiple subtasks with data and process dependencies. There is a sequential relationship between the subtasks and they cannot be arbitrarily split to multiple cloud instances for execution.
[0041] For parallelizable tasks, the computational workload is evenly distributed to the entire task completion time window according to the computational workload of the task and the required completion time, and the number of instances and duration required to execute the task at each moment can be obtained. This is a simple greedy scheduling method that can efficiently complete task scheduling and resource allocation, and reduce the impact of sudden computational workloads.
[0042] For workflow tasks, the completion time is assigned from the last subtask forward, and the completion time of each subtask is limited to ensure that the workflow task can be completed on time; then the cloud instance that can be completed the fastest is assigned to each subtask to ensure the smooth completion of the workflow task.
[0043] The task scheduling method in this embodiment can be replaced by other types of scheduling methods such as heuristic, meta-heuristic, machine learning, reinforcement learning, etc. according to actual needs, and the embodiment of the present invention is not limited to this.
[0044] Step 103: Determine the cost of using the cloud application for the user based on the number of instances and duration.
[0045] In the specific implementation, the type and quantity of currently available instances are first determined based on historical cloud application task information and instance purchase information, and then the instances that need to be purchased are determined based on the currently available instance types, instance quantity and duration. Finally, the usage cost is determined based on the currently available instances and the instances that need to be purchased.
[0046] Specifically, its execution process is as follows: Figure 2 shown.
[0047] It should be noted that, in this embodiment, instances are allocated by dividing the time axis into discrete time slices. Of course, other forms of allocation may also be selected, and this is not limited in the embodiment of the present invention.
[0048] First, divide the time axis into discrete time slices. The length of each time slice is the available time of the on-demand instance (such as 1 hour or 10 minutes). The usage period of the reserved instance is A time slice is the basic unit for instance purchase and task scheduling. For each time slice during task execution, the existing reserved instances are used first to execute the task. For insufficient instances, it is assumed that all on-demand instances are purchased. Then the historical data of the algorithm operation is extracted to calculate the number of instances before the current time slice. The number of times an on-demand instance is used in a time slice .
[0049] like , then purchase a new reserved instance in the current time slice; if , then purchase on-demand instances, and then repeat the process until an instance purchase plan is determined for each time slice during task execution.
[0050] The above threshold satisfy:
[0051] in, Represents the total price of the reserved instance. represents the price of an on-demand instance. This is the point at which the cost of purchasing a Reserved Instance becomes the same as the cost of purchasing an On-Demand Instance.
[0052] Furthermore, the total price of the reserved instance is:
[0053] in, The upfront cost of the reserved instance. Indicates the usage discount provided by the IaaS provider for the reserved instance. Indicates the validity period of the reserved instance.
[0054] The price of a reserved instance consists of two parts: the prepaid cost and the actual usage cost. The usage cost is significantly discounted compared to the on-demand instance, but the full reservation period must be used, that is, within the reservation period, you need to pay the usage cost for the instance regardless of whether you use it or not.
[0055] Therefore, the total cost of the reserved instance is calculated as: upfront cost + discount rate On-Demand Instance Prices Reservation period.
[0056] Then, determine the total cost of purchasing on-demand and reserved instances based on the above instance purchase plan , where the cost of the reserved instance is calculated over the entire reservation term; The total cost is allocated to the user according to the computational amount of the user task, and the actual execution cost of the user task is obtained. , as shown below:
[0057] in, The total cost of purchasing On-Demand and Reserved Instances at present. is the computational amount of the current user, is the total computational effort of all users.
[0058] Considering that subsequent users continue to arrive, cost allocation needs to take into account all costs and users, so the subsequent costs are further allocated:
[0059] in, is the actual execution cost of the current user after final amortization, For the entire calculation cycle, The total cost of the instance for the entire computing cycle can be calculated using the average data from the previous computing cycle. The time when the current user arrived.
[0060] Considering that cloud application service providers need to pay for manpower, management and other costs in addition to purchasing IaaS instances to execute user tasks, when calculating the cost of cloud application services, in addition to considering the actual payment cost of purchasing IaaS instances to execute user tasks (i.e. the above ), other additional costs should also be considered. In this step, multiple optimization goals are set for cloud application service transactions, including cloud application service provider revenue, cloud application service provider cost, and user satisfaction. The user's cloud application service cost is determined based on the optimization goals. Service provider revenue refers to the service fee received by the application service provider from the user; service provider cost refers to the cost that the application service provider needs to pay for purchasing cloud instances; user satisfaction refers to the proportion of service users to all users. Specifically, the cloud application service provider revenue is shown in the following formula:
[0061] in, For user collection, For users Fees paid.
[0062] The cloud application service provider cost is shown in the following formula:
[0063] in, is the time set, For time Purchase the number of on-demand instances. is the on-demand instance price, For time Purchase the number of reserved instances. The price of the reserved instance.
[0064] User satisfaction is expressed as follows:
[0065] in, The number of users who completed the task on demand, is the total number of users, and S is the user satisfaction.
[0066] The cloud application service cost is determined by comprehensively considering the above multiple optimization objectives. Specifically: First, calculate the current user's cloud application service cost based on the actual execution cost, as shown in the following formula:
[0067] in, It is a constant, not less than 1, representing the rate of return of the cloud application service provider.
[0068] After that, the decision on whether to serve the user is made based on the optimization target increment generated by the service user. Specifically, the multi-optimization target values generated by the service user so far are first calculated, and then the multi-optimization target increment (i.e., difference) generated by serving the current user is calculated based on the service price and instance purchase plan. If the multi-optimization target increment ≥ , then the cloud application service cost for this user is .
[0069] The cloud application service cost determination device provided by the present invention is described below. The cloud application service cost determination device described below and the cloud application service cost determination method described above can be referenced to each other.
[0070] like Figure 3 As shown, the cloud application service cost determination device 300 provided by the present invention includes the following units: The acquisition unit 301 is used to acquire the configuration information of the cloud IaaS instance in real time; The determining unit 302 is used to obtain the user's cloud application task information, and determine the number of instances and duration corresponding to the cloud application task information based on the cloud application task information and configuration information; The processing unit 303 is configured to determine the cost of the user using the cloud application according to the number of instances and the duration.
[0071] According to a cloud application service cost determination device provided by the present invention, the acquisition unit 301 is specifically used for: Obtain supply information from multiple cloud IaaS instance suppliers in real time, including instance type information, instance price information, and instance specific configuration information; Based on the instance type information, instance price information and instance specific configuration of each supplier, the configuration information of the cloud IaaS instance provided by each supplier is determined. The configuration information is used to indicate the usage priority of the cloud application task.
[0072] According to a cloud application service cost determination device provided by the present invention, the determination unit 302 is specifically used for: Obtain the user's cloud application task information and determine the task type based on the cloud application task information; Based on the cloud application task information, task type and configuration information, determine the number of instances and duration corresponding to the cloud application task information.
[0073] According to a cloud application service cost determination device provided by the present invention, the task type includes a parallelizable task and a workflow task. When the task type is a parallelizable task, the determination unit 302 is specifically used to: Determine the cloud application computing volume and completion time based on the cloud application task information; Evenly distribute the computational amount of parallelizable tasks to the completion time to obtain the computational amount at each moment; The number of instances and duration are determined based on the configuration information and the amount of computation at each moment.
[0074] According to a cloud application service cost determination device provided by the present invention, the task type includes a parallelizable task and a workflow task. When the task type is a workflow task, the determination unit 302 is specifically used to: Determine the cloud application computing volume and completion time based on the cloud application task information; Assign the completion time from the last subtask of the workflow task forward to obtain the completion time of each subtask; According to the computing amount of cloud applications and the completion time of each subtask, the computing amount at each moment is obtained; The number of instances and duration are determined based on the configuration information and the amount of computation at each moment.
[0075] According to a cloud application service cost determination device provided by the present invention, the processing unit 303 is specifically used for: Determine currently available instances based on historical cloud application task information and instance purchase information; Determine the instances that need to be purchased based on the currently available instances, number of instances, and duration; The usage cost is determined based on the currently available instances and the instances that need to be purchased.
[0076] like Figure 4 As shown, the cloud application service cost determination system provided by the present invention includes the following modules: a unified service entry module 401, a cloud instance management module 402, a cloud application service transaction algorithm module 403, a task execution module 404 and a log recording module 405, wherein: The unified service entry module 401 is used to provide a graphical interface and an accessible programming interface to the user, receive the user's cloud application task information and feedback the results of executing the cloud application task.
[0077] Specifically, the unified service entry module 401 provides users with a graphical interface and an accessible interactive interface, which can receive the user's task request and corresponding data, and distribute it to the cloud application service transaction algorithm module 403 for processing. After the task is completed, the task execution result is fed back to the user, and the user is charged according to the service price calculated by the cloud application service transaction algorithm module 403. It supports users to monitor and manage the entire life cycle of the task, display the current execution status of the task, and can create, start, pause, delete, and other operations on the task. This embodiment defines a set of standard, unified interactive interface interfaces based on general interface technologies such as RESTful or gRPC. These interfaces follow the design principles of clarity, simplicity, and ease of use to reduce the user's learning cost and difficulty of use. Security measures such as identity authentication, access control, and data encryption are adopted to ensure the security and reliability of the interactive interface. At the same time, detailed interface documentation and instructions for use are provided to help users use these interfaces correctly and safely.
[0078] The cloud instance management module 402 enables users to obtain the configuration information of cloud application services in real time. Specifically, by calling the API interface, the cloud computing instances of multiple cloud IaaS suppliers are integrated, and the price, available time, operating status and remaining usage time of the cloud computing instances are monitored in real time. The cloud application service transaction algorithm module 403 supports the operation, and the collected cloud instance data is intuitively displayed in the form of charts, dashboards, etc., so that users can quickly understand the overall situation and status of resources. It supports querying and viewing instance details, and performing management operations such as starting, stopping, and deleting instances. In this system, a cloud instance purchase module can also be included, and the cloud instance management module 402 can also perform the following content: according to the cloud instance purchase plan calculated by the cloud application service transaction algorithm module 403, according to the specific parameters therein, the resource application API interface of the corresponding cloud IaaS service provider is called to complete the creation and configuration of the instance. Since the instance purchase may involve a long wait (such as image pulling, network configuration, etc.), the cloud instance purchase module supports an asynchronous processing mechanism to avoid blocking the main thread. For purchase failures caused by network problems, IaaS service provider internal errors, etc., the module has an automatic retry mechanism and notifies the administrator to intervene after a certain number of retries. After successfully purchasing an instance, the detailed information of the instance is synchronized to the management page to ensure that the management page can display the status and configuration of all instances in real time, so as to perform unified monitoring and management.
[0079] The cloud application service transaction algorithm module 403 is used to determine the number of instances and duration required by the user based on the cloud application task information, and calculate the cloud application service cost; specifically, it makes a decision based on the user task information received by the unified service entry module 401 and the instance information monitored by the cloud instance management module 402, and determines the number of instances and duration required to execute the user's task (i.e., instance purchase and task scheduling plan), as well as the corresponding cloud application service cost. After the decision is made, the instance purchase plan is sent to the cloud instance management module 402 to implement instance purchase, and the task scheduling plan is sent to the task execution module 404 to implement task execution.
[0080] The task execution module 404 is used to execute cloud application tasks based on the number of instances and duration corresponding to each user, and to feed back the results of executing cloud application tasks to the user through the unified service entry module; specifically, according to the task scheduling scheme calculated by the cloud application service transaction algorithm module 403, the execution order of tasks and the allocation of cloud computing instances are reasonably arranged to ensure efficient execution of tasks and optimal utilization of resources. According to task requirements, the execution environment is automatically configured and managed, including the operating system, dependent libraries, environment variables, etc. The task information and data submitted by the user are securely transmitted to the specified cloud computing instance to ensure the integrity and confidentiality of the data. The execution status of the task is monitored in real time, and possible exceptions and errors are captured and processed to ensure reliable execution of the task. The execution results of the task, including standard output, standard error, log files, etc., are collected and organized into a unified format, and fed back to the user through the unified service entry module 401 for easy viewing and analysis by the user.
[0081] The log recording module 405 is used to record operation logs, such as user operations, administrator operations and system operation logs, to facilitate error backtracking and behavior auditing. Among them, user operations include user login, logout, request submission, data access and other operations; administrator operations include administrator configuration, management, maintenance and other operations on the system; system operation logs include the operation of service transaction algorithms, purchase and release of instances, execution and scheduling of tasks, etc. Define logs of different levels and adjust the level of detail of logs according to actual needs. Use asynchronous logging to avoid blocking the main thread and improve system performance. Realize automatic rotation and archiving of log files to prevent storage problems caused by excessively large log files. Encrypt log data for storage and transmission to ensure the security of logs, while limiting access rights to logs to prevent unauthorized access and tampering.
[0082] Figure 5 An example of a physical structure diagram of an electronic device is shown in FIG. Figure 5As shown, the electronic device may include: a processor 510, a communications interface 520, a memory 530 and a communication bus 540, wherein the processor 510, the communications interface 520 and the memory 530 communicate with each other through the communication bus 540. The processor 510 may call the logic instructions in the memory 530 to execute the cloud application service cost determination method, which includes: Get the configuration information of IaaS instances in real time; Obtaining the user's cloud application task information, and determining the number of instances and duration corresponding to the cloud application task information based on the cloud application task information and configuration information; Determine the cost of using cloud applications based on the number of instances and duration.
[0083] In addition, the logic instructions in the above-mentioned memory 530 can be implemented in the form of a software functional unit and can be stored in a computer-readable storage medium when it is sold or used as an independent product. Based on such an understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art or the part of the technical solution, can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk, etc. Various media that can store program codes.
[0084] On the other hand, the present invention further provides a computer program product, the computer program product includes a computer program, the computer program can be stored in a non-transitory computer-readable storage medium, when the computer program is executed by a processor, the computer can execute the cloud application service cost determination method provided by the above methods, the method includes: Get the configuration information of cloud IaaS instances in real time; Obtaining the user's cloud application task information, and determining the number of instances and duration corresponding to the cloud application task information based on the cloud application task information and configuration information; Determine the cost of using cloud applications based on the number of instances and duration.
[0085] In another aspect, the present invention further provides a non-transitory computer-readable storage medium having a computer program stored thereon, which is implemented when the computer program is executed by a processor to perform the cloud application service cost determination method provided by the above methods, the method comprising: Get the configuration information of cloud IaaS instances in real time; Obtaining the user's cloud application task information, and determining the number of instances and duration corresponding to the cloud application task information based on the cloud application task information and configuration information; Determine the cost of using cloud applications based on the number of instances and duration.
[0086] The device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Ordinary technicians in this field can understand and implement it without paying creative labor.
[0087] Through the description of the above implementation methods, those skilled in the art can clearly understand that each implementation method can be implemented by means of software plus a necessary general hardware platform, and of course, can also be implemented by hardware. Based on this understanding, the above technical solution is essentially or the part that contributes to the prior art can be embodied in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, a disk, an optical disk, etc., including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or some parts of the embodiments.
[0088] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A method for determining cloud application service costs, characterized in that: The method comprises: Get the configuration information of cloud IaaS instances in real time; Acquire the user's cloud application task information, and determine the number and duration of instances corresponding to the cloud application task information based on the cloud application task information and the configuration information; The cost of using the cloud application by the user is determined according to the number of instances and the duration.
2. The cloud application service cost determination method according to claim 1, characterized in that: The real-time acquisition of configuration information of the cloud IaaS instance includes: Acquire supply information of multiple cloud IaaS instance suppliers in real time, wherein the supply information includes instance type information, instance price information, and instance specific configuration information; Based on the instance type information, instance price information and instance specific configuration information of each supplier, the configuration information of the cloud IaaS instance provided by each supplier is determined, and the configuration information is used to indicate the usage priority of the cloud application task.
3. The cloud application service cost determination method according to claim 2, characterized in that: Acquiring the user's cloud application task information, and determining the number of instances and duration corresponding to the cloud application task information based on the cloud application task information and the configuration information, including: Obtaining the user's cloud application task information, and determining the task type according to the cloud application task information; Based on the cloud application task information, the task type and the configuration information, the number of instances and the duration corresponding to the cloud application task information are determined.
4. The cloud application service cost determination method according to claim 3, characterized in that: The task type includes a parallelizable task and a workflow task. When the task type is a parallelizable task, determining the number of instances and duration corresponding to the cloud application task information based on the cloud application task information, the task type and the configuration information includes: Determine the cloud application computing amount and completion time according to the cloud application task information; Evenly distribute the computational amount of the parallelizable tasks to the completion time to obtain the computational amount at each moment; The number of instances and the duration are determined based on the configuration information and the amount of calculation per moment.
5. The cloud application service cost determination method according to claim 3, characterized in that: The task type includes a parallelizable task and a workflow task. When the task type is a workflow task, determining the number of instances and duration corresponding to the cloud application task information based on the cloud application task information, the task type and the configuration information includes: Determine the cloud application computing amount and completion time according to the cloud application task information; Allocating the completion time from the last subtask of the workflow task forward to obtain the completion time of each subtask; Obtaining the computing amount at each moment according to the computing amount of the cloud application and the completion time of each subtask; The number of instances and the duration are determined based on the configuration information and the amount of calculation per moment.
6. The cloud application service cost determination method according to any one of claims 4 or 5, characterized in that: The determining, according to the number of instances and the duration, the cost of the user using the cloud application includes: Determine currently available instances based on historical cloud application task information and instance purchase information; Determining instances that need to be purchased based on the currently available instances, the number of instances, and the duration; The cost may be determined based on the currently available instances and the instances that need to be purchased.
7. A cloud application service cost determination device, characterized in that: include: An acquisition unit, used to acquire configuration information of a cloud IaaS instance in real time; a determination unit, configured to obtain the user's cloud application task information, and determine the number and duration of instances corresponding to the cloud application task information based on the cloud application task information and the configuration information; A processing unit is used to determine a cost for the user to use the cloud application according to the number of instances and the duration.
8. A cloud application service cost determination system, characterized in that: The system includes a unified service entry module, a cloud instance management module, a cloud application service transaction algorithm module, a task execution module and a log recording module, wherein: A unified service entry module is used to provide a graphical interface and an accessible programming interface to users, receive cloud application task information from the users and feedback the results of executing cloud application tasks; A cloud instance management module, used to obtain configuration information of cloud IaaS instances in real time, and purchase and manage IaaS instances based on the number of instances and duration required by the user; A cloud application service transaction algorithm module, used to determine the number of instances and duration required by the user and the cost of the user using the cloud application based on the cloud application task information; A task execution module, used to execute the cloud application task based on the number of instances and duration corresponding to each user, and feed back the result of executing the cloud application task to the user through the unified service entry module; The logging module is used to record the operation log.
9. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein: When the processor executes the computer program, the method for determining the cloud application service cost according to any one of claims 1 to 6 is implemented.
10. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the method for determining the cloud application service cost according to any one of claims 1 to 6 is implemented.
Citation Information
Patent Citations
Cloud workflow configuration and scheduling method supporting preemptive virtual machine instances
CN112463295A
Instance allocation method, system and device
CN114461374A
Computing resource configuration method and device for cloud on enterprise
CN114860430A
Workflow scheduling method in multi-cloud environment under cost constraint
CN117667344A
