CN112181650A - Cloud computing resource metering method, device, system, equipment and medium - Google Patents

Cloud computing resource metering method, device, system, equipment and medium Download PDF

Info

Publication number
CN112181650A
CN112181650A CN202011017625.0A CN202011017625A CN112181650A CN 112181650 A CN112181650 A CN 112181650A CN 202011017625 A CN202011017625 A CN 202011017625A CN 112181650 A CN112181650 A CN 112181650A
Authority
CN
China
Prior art keywords
instance
information
snapshot
module
metering
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202011017625.0A
Other languages
Chinese (zh)
Inventor
周广瑞
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Kingsoft Cloud Network Technology Co Ltd
Original Assignee
Beijing Kingsoft Cloud Network Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Kingsoft Cloud Network Technology Co Ltd filed Critical Beijing Kingsoft Cloud Network Technology Co Ltd
Priority to CN202011017625.0A priority Critical patent/CN112181650A/en
Publication of CN112181650A publication Critical patent/CN112181650A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/50Allocation of resources, e.g. of the central processing unit [CPU]
    • G06F9/5061Partitioning or combining of resources

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

The embodiment of the disclosure relates to a method, a device, a system, equipment and a medium for metering cloud computing resources, wherein the method comprises the following steps: receiving instance updating information, wherein the instance updating information is information sent by an instance module when an instance state changes; generating instance snapshot information based on the instance update information; and sending the instance snapshot information to a metering module so that the metering module can measure the cloud computing resources based on the instance snapshot information. By adopting the technical scheme, the instance snapshot information can be generated according to the instance update information when the instance state changes, further the cloud computing resources can be metered according to the instance snapshot information, the order function and the metering function of the cloud computing resources are decoupled, the metering service complexity can be reduced, the metering efficiency is improved, and the problem of inaccurate bills caused by the metering mode can be solved.

Description

Cloud computing resource metering method, device, system, equipment and medium
Technical Field
The present disclosure relates to the field of data processing technologies, and in particular, to a method, an apparatus, a system, a device, and a medium for metering cloud computing resources.
Background
Cloud computing is a service related to information technology, software and the internet, and can rapidly provide a computing resource sharing pool of resources including networks, servers, storage, application software, services and the like, and is typically characterized by on-demand use, and the metering and charging of the resources therein is the basis of the commercialization of a cloud platform.
At present, because the resource information is not constant in the whole life cycle from opening to releasing the cloud computing resources, a customer can change the size and the use duration of the cloud computing resources according to the needs of the customer, and a cloud computing manufacturer can obtain an order record related to the current charging account period from an order module according to the charging cycle to calculate the use amount and charge. However, the above metering and charging method has low bill billing accuracy, and the problems of high business complexity and low efficiency are caused by the strong business coupling of the metering and charging function to the order function.
Disclosure of Invention
To solve the above technical problem or at least partially solve the above technical problem, the present disclosure provides a cloud computing resource metering method, apparatus, system, device, and medium.
The embodiment of the disclosure provides a cloud computing resource metering method, which comprises the following steps:
receiving instance updating information, wherein the instance updating information is information sent by an instance module when an instance state changes;
generating instance snapshot information based on the instance update information;
and sending the instance snapshot information to a metering module so that the metering module can measure the cloud computing resources based on the instance snapshot information.
The embodiment of the present disclosure further provides a cloud computing resource metering device, where the device includes:
the system comprises an instance update information receiving module, an instance update information transmitting module and an instance update information receiving module, wherein the instance update information is information transmitted by the instance module when an instance state changes;
the instance snapshot generating module is used for generating instance snapshot information based on the instance updating information;
and the cloud computing resource metering module is used for sending the instance snapshot information to the metering module so as to enable the metering module to measure the cloud computing resources based on the instance snapshot information.
The embodiment of the disclosure also provides a cloud computing resource metering system, which comprises an example snapshot module, an example module and a metering module, wherein the example snapshot module is in communication connection with the example module and the metering module, and is used for executing the cloud computing resource metering method provided by the embodiment of the disclosure.
An embodiment of the present disclosure further provides an electronic device, which includes: a processor; a memory for storing the processor-executable instructions; the processor is used for reading the executable instructions from the memory and executing the instructions to realize the cloud computing resource metering method provided by the embodiment of the disclosure.
The embodiment of the disclosure also provides a computer-readable storage medium, where the storage medium stores a computer program, and the computer program is used to execute the cloud computing resource metering method provided by the embodiment of the disclosure.
Compared with the prior art, the technical scheme provided by the embodiment of the disclosure has the following advantages: according to the cloud computing resource metering scheme provided by the embodiment of the disclosure, instance updating information is received, wherein the instance updating information is information sent by an instance module when an instance state changes, instance snapshot information is generated based on the instance updating information, and the instance snapshot information is sent to a metering module, so that the metering module performs metering of cloud computing resources based on the instance snapshot information. By adopting the technical scheme, the instance snapshot information can be generated according to the instance update information when the instance state changes, further the cloud computing resources can be metered according to the instance snapshot information, the order function and the metering function of the cloud computing resources are decoupled, the metering service complexity can be reduced, the metering efficiency is improved, and the problem of inaccurate bills caused by the metering mode can be solved.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present disclosure and together with the description, serve to explain the principles of the disclosure.
In order to more clearly illustrate the embodiments or technical solutions in the prior art of the present disclosure, the drawings used in the description of the embodiments or prior art will be briefly described below, and it is obvious for those skilled in the art that other drawings can be obtained according to the drawings without inventive exercise.
Fig. 1 is a schematic flowchart of a cloud computing resource metering method according to an embodiment of the present disclosure;
fig. 2 is a schematic flow chart of another cloud computing resource metering method provided in the embodiments of the present disclosure;
fig. 3 is a schematic structural diagram of a cloud computing resource metering system according to an embodiment of the present disclosure;
fig. 4 is a schematic structural diagram of a cloud computing resource metering device according to an embodiment of the present disclosure;
fig. 5 is a schematic structural diagram of an electronic device according to an embodiment of the present disclosure.
Detailed Description
In order that the above objects, features and advantages of the present disclosure may be more clearly understood, aspects of the present disclosure will be further described below. It should be noted that the embodiments and features of the embodiments of the present disclosure may be combined with each other without conflict.
In the following description, numerous specific details are set forth in order to provide a thorough understanding of the present disclosure, but the present disclosure may be practiced in other ways than those described herein; it is to be understood that the embodiments disclosed in the specification are only a few embodiments of the present disclosure, and not all embodiments.
Currently, when some public cloud customers purchase cloud computing resources, cloud computing manufacturers adopt a post-payment mode, that is, firstly, the cloud computing resources are put on a bill and opened, then, after an account period, the cloud computing manufacturers perform metering charging according to actual usage of the cloud computing resources used by the customers in a previous bill period, and issue post-payment bills, wherein the bill period generally comprises three granularities of one hour, one day and one month. Alternatively, certain cloud computing resources may require use before payment can be made based on the amount of use.
Because the resource information of the cloud computing resources is not invariable in the whole life cycle from opening to releasing, the size and the use duration of the cloud computing resources can be changed by the client according to the needs of the client, such as updating or charging. The metering and charging module can obtain the order record related to the current charging account period through the order module according to the charging period, calculate the usage and charge. However, the metering charging method has the following disadvantages: 1. the bill posting accuracy is totally dependent on the order module. For all the change records of the resources, order records are required to ensure the billing accuracy of the billing, however, the order module is not identical to the change records of the resources, i.e. some resource operations do not need to place orders, which may affect the billing accuracy. For example, a user making project changes to a resource may affect the accuracy of project billing because there is no order record. 2. The metering and charging module is coupled to the strong service of the order module, which causes the service complexity to be too high. The metering and charging module can only obtain the data required by the charging period through the order module, and the corresponding commodity information is obtained in the commodity module and the corresponding instance information is obtained in the instance module according to the order record. The data are business logic of the order system, so the metering and charging module needs to pay attention to the business logic of the order system to acquire the data to be charged.
Therefore, the metering and charging mode has lower bill billing accuracy, and the problems of overhigh service complexity and lower efficiency are caused by strong service coupling of the metering and charging function to the order function. In order to solve the above problem, an embodiment of the present disclosure provides a cloud computing resource metering method.
Fig. 1 is a schematic flowchart of a cloud computing resource metering method provided in an embodiment of the present disclosure, where the method may be performed by a cloud computing resource metering apparatus, where the apparatus may be implemented by software and/or hardware, and may be generally integrated in an electronic device. As shown in fig. 1, the method includes:
step 101, receiving instance update information, wherein the instance update information is information sent by an instance module when an instance state changes.
In the embodiment of the present disclosure, an instance may be understood as a specific cloud computing resource applied for a user according to a user requirement, and an instance may include a resource of hardware or software, for example, an instance may be a host. The instance module may be understood as a functional module for managing configuration information such as the state and time of an instance.
The case that the instance state changes includes, but is not limited to, creating an instance, creating a new instance based on the user's requirement, modifying an instance project system, changing an instance specific resource size, modifying an instance project system corresponding to the instance, temporarily stopping the instance when the user owes the instance, removing the instance when the user does not need cloud computing resources, the instance does not exist after the removal, and re-creating an instance when the user purchases again.
The instance update information is information related to changes in the instance module, and may specifically include at least one of a change type, instance information, order information, commodity information, a metering and billing method, and the like. The change type may represent a classification of the instance state change situation, and may be classified into a charging update type and a non-charging update type according to whether charging is changed or not, for example. The instance information may include instance latest state related information such as instance identification, instance update time and the like, the order information may include order related information such as order identification and order service time and the like, and the commodity information may include commodity related information such as commodity identification and instance configuration information and the like.
Specifically, the instance snapshot module may receive instance update information sent by the instance module when the instance state changes, so as to be used later. It can be appreciated that when the state change of the instance fails to create the instance, the instance module need not send instance update information to the instance snapshot module since resource metering and billing need not be performed.
And 102, generating current instance snapshot information based on the instance updating information.
The instance snapshot information may be understood as a mapping record of related information when the instance state changes, and is an integrated information.
In the embodiment of the present disclosure, generating the instance snapshot information based on the instance update information may include: determining a snapshot start time based on the change type, the instance information, and the order information; generating a snapshot identifier based on the instance information; acquiring example configuration information based on a commodity identifier in the commodity information; and integrating the default snapshot ending time, the snapshot starting time, the snapshot identifier and the instance configuration information to obtain instance snapshot information.
Specifically, determining the snapshot start time based on the change type, the instance information, and the order information may include: if the change type is a non-charging updating type, the snapshot starting time is the instance updating time in the instance information; otherwise, the snapshot start time is the order service start time in the order information. If the change type is a non-charging update type, it indicates that the current instance state change does not affect charging, for example, an instance project system is changed, no order record exists, and the instance update time in the instance information can be used as the snapshot start time; if the change type is a charging update type, it indicates that the change of the current instance state affects charging, for example, an update instance has an order record, and the order service start time may be obtained from an order module based on an order identifier in the order information, and is taken as a snapshot start time.
The instance information may include the latest state information of the instance, such as instance identification, instance update time, and instance data version, and the snapshot identification corresponds to the instance snapshot information one to one. The snapshot identification is generated based on the instance information, specifically, after a character string obtained by splicing the instance identification (namely, the instance ID), the instance update time, the instance data version and other information is encrypted, the snapshot identification is obtained, the snapshot identification is unique, and one snapshot identification corresponds to one instance snapshot information. The instance configuration information is obtained based on the commodity identification in the commodity information, specifically, the instance configuration information can be obtained from the commodity module through an interface of the commodity module based on the commodity identification, and the instance configuration information refers to resource-related information purchased by a user.
After key fields such as snapshot starting time, snapshot identification, instance configuration information and default snapshot ending time are integrated, instance snapshot information is generated, then the snapshot identification can be a key (key), information integrated by other key fields can be a value (value), and the instance snapshot information is stored in a database. The default snapshot ending time may be a long future time, the representation is not ended, and may be specifically set according to an actual situation, for example, the default snapshot ending time may be 2099, 12, and 31 days.
And 103, sending the instance snapshot information to a metering module so that the metering module can measure the cloud computing resources based on the instance snapshot information.
After the instance snapshot module generates the instance snapshot information, the instance snapshot information may be sent when the metering module needs to perform metering. The specific metering module can send an information acquisition request to the instance snapshot module according to the metering time, and when the instance snapshot module receives the information acquisition request, the instance snapshot information can be sent to the metering module, so that the metering module can perform metering of cloud computing resources based on the instance snapshot information, and further can perform charging and bill charge. In the embodiment of the disclosure, the metering function and the order function are decoupled, so that the problem of inaccurate bill payment caused by no order record generation can be solved, and the metering efficiency is improved.
According to the cloud computing resource metering scheme provided by the embodiment of the disclosure, instance updating information is received, wherein the instance updating information is information sent by an instance module when an instance state changes, instance snapshot information is generated based on the instance updating information, and the instance snapshot information is sent to a metering module, so that the metering module performs metering of cloud computing resources based on the instance snapshot information. By adopting the technical scheme, the instance snapshot information can be generated according to the instance update information when the instance state changes, further the cloud computing resources can be metered according to the instance snapshot information, the order function and the metering function of the cloud computing resources are decoupled, the metering service complexity can be reduced, the metering efficiency is improved, and the problem of inaccurate bills caused by the metering mode can be solved.
In some embodiments, after generating the instance snapshot information based on the instance update information, the cloud computing resource metering method may further include: and modifying the default snapshot end time in the snapshot information of the last instance to the snapshot start time in the snapshot information of the instance. Through modification, errors in subsequent metering and charging can be avoided.
Fig. 2 is a schematic flow chart of another cloud computing resource metering method according to an embodiment of the present disclosure. The present embodiment further specifically describes the cloud computing resource metering method based on the above embodiments. As shown in fig. 2, the method includes:
step 201, receiving instance update information.
The instance update information is information sent by the instance module when the instance state changes, and may include at least one of a change type, instance information, order information, commodity information, a metering and billing method, and the like.
In the embodiment of the present disclosure, a specific process when a user purchases a cloud computing resource may include: the method comprises the steps that commodities are generated according to information of cloud computing resources needed by a user, orders are generated according to the commodities after the user places the orders, and a specific example can be generated after payment; when a user updates an instance, an updated item may be generated, and a new order may be generated based on the item, but no instance may be created. The change type may represent a classification of the instance state change situation, and may be classified into a charging update type and a non-charging update type according to whether charging is changed or not, for example. The instance information may include instance latest state related information such as instance identification, instance update time and the like, the order information may include order related information such as order identification and order service time and the like, and the commodity information may include commodity related information such as commodity identification and instance configuration information and the like.
After step 201, step 202 to step 205 may be executed, where step 202 to step 204 may be executed concurrently, or may be executed according to a sequence, and the sequence of step 202 to step 204 is not limited in this embodiment of the disclosure, and is only an example in fig. 2.
Based on the change type, instance information, and order information, a snapshot start time is determined, step 202.
Specifically, determining the snapshot start time based on the change type, the instance information, and the order information may include: if the change type is a non-charging updating type, the snapshot starting time is the instance updating time in the instance information; otherwise, the snapshot start time is the order service start time in the order information.
Step 203, generating a snapshot identifier based on the instance information.
And step 204, acquiring instance configuration information based on the commodity identification in the commodity information.
And step 205, integrating the default snapshot ending time, the snapshot starting time, the snapshot identifier and the instance configuration information to obtain instance snapshot information.
And step 206, the default snapshot ending time in the snapshot information of the previous instance is modified into the snapshot starting time in the snapshot information of the instance.
The previous instance snapshot information refers to the instance snapshot information of the previous record for the currently generated instance snapshot information. Since the default snapshot end time when each instance snapshot information is generated is a time representing non-end, when new instance snapshot information is generated, it is described that the previous instance change is ended, the default snapshot end time in the previous instance snapshot information needs to be modified to the snapshot start time in the current instance snapshot information, so as to avoid errors occurring in subsequent metering and charging.
And step 207, sending the instance snapshot information and the previous instance snapshot information to a metering module so that the metering module can meter the cloud computing resources based on the instance snapshot information and the previous instance snapshot information.
The instance snapshot module may send all snapshot information, such as the instance snapshot information and the previous instance snapshot information, to the metering module, so that the metering module performs metering and charging based on each instance snapshot information.
The cloud computing resource metering scheme provided by the embodiment of the disclosure receives instance update information, determines snapshot start time based on change types, instance information and order information, generates snapshot identifiers based on the instance information, acquires instance configuration information based on the commodity identifiers in the commodity information, integrates default snapshot end time, snapshot start time, snapshot identifiers and the instance configuration information to obtain instance snapshot information, modifies default snapshot end time in the last instance snapshot information into snapshot start time in the instance snapshot information, and sends the instance snapshot information and the last instance snapshot information to a metering module, so that the metering module performs metering of cloud computing resources based on the instance snapshot information and the last instance snapshot information. By adopting the technical scheme, the instance snapshot information can be generated according to the instance update information when the instance state changes, further the cloud computing resources can be metered according to the instance snapshot information, the order function and the metering function of the cloud computing resources are decoupled, the metering service complexity can be reduced, the metering efficiency is improved, and the problem of inaccurate bills caused by the metering mode can be solved.
Fig. 3 is a schematic structural diagram of a cloud computing resource metering system provided in the embodiment of the present disclosure, where the cloud computing resource metering system may include an example snapshot module 10, an example module 20, and a metering module 30, where the example snapshot module 10 is in communication connection with the example module 20 and the metering module 30, and is used to execute the cloud computing resource metering method provided in the embodiment of the present disclosure, and specifically may receive example update information sent by the example module 20 when an example state changes, generate example snapshot information based on the example update information, and send the example snapshot information to the metering module 30, so that the metering module 30 performs cloud computing resource metering based on the example snapshot information.
The instance module 20 is used for generating and managing instances, and the metering module 30 is used for metering and charging cloud computing resources. In addition, the cloud computing resource metering system may further include a commodity module 40 and an order module 50, where the commodity module 40 is used for managing commodities, and the order module 50 is used for managing orders. The goods module 40 and the order module 50 are both connected with the example snapshot module 10 in a communication way, and can perform data transmission.
Based on the cloud computing resource metering system, the complete process of the cloud computing resource metering method may include:
1. when the instance state changes, the instance module sends instance update information to the instance snapshot module.
2. After receiving the instance updating information, the instance snapshot module performs the following operations on the instance updating information and stores the instance updating information in a storage mode:
a) performing different operations according to the change types, for example, acquiring different time information as the snapshot start time of a snapshot, acquiring the order service start time through the order ID recorded in the order record as the snapshot start time of the current snapshot record, and taking the instance update time recorded in the absence of the order record as the snapshot start time of the current snapshot record;
b) generating a snapshot ID of the snapshot according to the instance ID, the instance updating time and the instance data version, and taking the snapshot ID as a unique key (key) for data storage;
c) acquiring instance configuration information of the commodity module through a commodity module interface according to the commodity ID;
d) storing the processed instance snapshot information into a database, wherein each recorded instance snapshot information in the database includes but is not limited to key fields such as a snapshot ID, a snapshot start time, a default snapshot end time, instance information, instance configuration information and the like, specifically, taking the snapshot ID as a key (key), taking other information in the processed instance snapshot information of each integrated system as a value, and storing the instance snapshot information in the database;
e) and modifying the snapshot ending time of the last instance snapshot information of the instance snapshot information, namely modifying the snapshot starting time of the current instance snapshot information.
3. The metering module can directly acquire the instance snapshot information in the instance snapshot module according to the charging account period to meter and charge the cloud computing resources without paying attention to the business logic related to the order system.
According to the cloud computing resource metering system provided by the embodiment of the disclosure, by adding the instance snapshot module, when the instance state changes, corresponding snapshot records are generated, that is, information such as the current configuration information, the instance information and the event occurrence time point of the instance is subjected to time continuous processing and storage, so that the subsequent metering module can obtain records related to the current charging account period from the instance snapshot module according to the account period for metering and charging, without concerning business logic related to an order system, thereby reducing the business complexity of metering and charging, and solving the problem of inaccurate bills generated by a metering mode.
Fig. 4 is a schematic structural diagram of a cloud computing resource metering apparatus provided in an embodiment of the present disclosure, where the apparatus may be implemented by software and/or hardware, and may be generally integrated in an electronic device. As shown in fig. 4, the apparatus includes:
an instance update information receiving module 301, configured to receive instance update information, where the instance update information is information sent by an instance module when an instance state changes;
an instance snapshot generating module 302, configured to generate instance snapshot information based on the instance update information;
and the cloud computing resource metering module 303 is configured to send the instance snapshot information to a metering module, so that the metering module performs metering of cloud computing resources based on the instance snapshot information.
According to the cloud computing resource metering scheme provided by the embodiment of the disclosure, instance updating information is received, wherein the instance updating information is information sent by an instance module when an instance state changes, instance snapshot information is generated based on the instance updating information, and the instance snapshot information is sent to a metering module, so that the metering module performs metering of cloud computing resources based on the instance snapshot information. By adopting the technical scheme, the instance snapshot information can be generated according to the instance update information when the instance state changes, further the cloud computing resources can be metered according to the instance snapshot information, the order function and the metering function of the cloud computing resources are decoupled, the metering service complexity can be reduced, the metering efficiency is improved, and the problem of inaccurate bills caused by the metering mode can be solved.
Optionally, the instance update information includes at least one of a change type, instance information, order information, commodity information, and a metering and billing method.
Optionally, the instance snapshot generating module 302 is specifically configured to:
determining a snapshot start time based on the change type, the instance information, and the order information;
generating a snapshot identifier based on the instance information;
acquiring instance configuration information based on the commodity identification in the commodity information;
and integrating the default snapshot ending time, the snapshot starting time, the snapshot identifier and the instance configuration information to obtain instance snapshot information.
Optionally, the instance snapshot generating module 302 is specifically configured to:
if the change type is a non-charging update type, the snapshot starting time is the instance update time in the instance information; otherwise, the snapshot starting time is the order service starting time in the order information.
Optionally, the instance information includes an instance identifier, an instance update time, and an instance data version, and the snapshot identifier corresponds to the instance snapshot information one to one.
Optionally, the apparatus further includes an end time modification module, specifically configured to: after generating the instance snapshot information based on the instance update information,
and modifying the default snapshot end time in the snapshot information of the last instance into the snapshot start time in the snapshot information of the instance.
The cloud computing resource metering device provided by the embodiment of the disclosure can execute the cloud computing resource metering method provided by any embodiment of the disclosure, and has the corresponding functional modules and beneficial effects of the execution method.
Fig. 5 is a schematic structural diagram of an electronic device according to an embodiment of the present disclosure. As shown in fig. 5, the electronic device 400 includes one or more processors 401 and memory 402.
The processor 401 may be a Central Processing Unit (CPU) or other form of processing unit having data processing capabilities and/or instruction execution capabilities, and may control other components in the electronic device 400 to perform desired functions.
Memory 402 may include one or more computer program products that may include various forms of computer-readable storage media, such as volatile memory and/or non-volatile memory. The volatile memory may include, for example, Random Access Memory (RAM), cache memory (cache), and/or the like. The non-volatile memory may include, for example, Read Only Memory (ROM), hard disk, flash memory, etc. One or more computer program instructions may be stored on the computer-readable storage medium and executed by the processor 401 to implement the cloud computing resource metering method of the embodiments of the present disclosure described above and/or other desired functions. Various contents such as an input signal, a signal component, a noise component, etc. may also be stored in the computer-readable storage medium.
In one example, the electronic device 400 may further include: an input device 403 and an output device 404, which are interconnected by a bus system and/or other form of connection mechanism (not shown).
The input device 403 may also include, for example, a keyboard, a mouse, and the like.
The output device 404 may output various information to the outside, including the determined distance information, direction information, and the like. The output devices 404 may include, for example, a display, speakers, a printer, and a communication network and its connected remote output devices, among others.
Of course, for simplicity, only some of the components of the electronic device 400 relevant to the present disclosure are shown in fig. 5, omitting components such as buses, input/output interfaces, and the like. In addition, electronic device 400 may include any other suitable components depending on the particular application.
In addition to the above methods and apparatus, embodiments of the present disclosure may also be a computer program product comprising computer program instructions that, when executed by a processor, cause the processor to perform the cloud computing resource metering methods provided by embodiments of the present disclosure.
The computer program product may write program code for carrying out operations for embodiments of the present disclosure in any combination of one or more programming languages, including an object oriented programming language such as Java, C + + or the like and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code may execute entirely on the user's computing device, partly on the user's device, as a stand-alone software package, partly on the user's computing device and partly on a remote computing device, or entirely on the remote computing device or server.
Furthermore, embodiments of the present disclosure may also be a computer-readable storage medium having stored thereon computer program instructions, which, when executed by a processor, cause the processor to perform the cloud computing resource metering method provided by the embodiments of the present disclosure.
The computer-readable storage medium may take any combination of one or more readable media. The readable medium may be a readable signal medium or a readable storage medium. A readable storage medium may include, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or a combination of any of the foregoing. More specific examples (a non-exhaustive list) of the readable storage medium include: an electrical connection having one or more wires, a portable disk, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
It is noted that, in this document, relational terms such as "first" and "second," and the like, may be used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in a process, method, article, or apparatus that comprises the element.
The foregoing are merely exemplary embodiments of the present disclosure, which enable those skilled in the art to understand or practice the present disclosure. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the generic principles defined herein may be applied to other embodiments without departing from the spirit or scope of the disclosure. Thus, the present disclosure is not intended to be limited to the embodiments shown herein but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.

Claims (10)

1. A cloud computing resource metering method is characterized by comprising the following steps:
receiving instance updating information, wherein the instance updating information is information sent by an instance module when an instance state changes;
generating instance snapshot information based on the instance update information;
and sending the instance snapshot information to a metering module so that the metering module can measure the cloud computing resources based on the instance snapshot information.
2. The method of claim 1, wherein the instance update information comprises at least one of a change type, instance information, order information, merchandise information, and a meter billing method.
3. The method of claim 2, wherein generating instance snapshot information based on the instance update information comprises:
determining a snapshot start time based on the change type, the instance information, and the order information;
generating a snapshot identifier based on the instance information;
acquiring instance configuration information based on the commodity identification in the commodity information;
and integrating the default snapshot ending time, the snapshot starting time, the snapshot identifier and the instance configuration information to obtain instance snapshot information.
4. The method of claim 3, wherein determining a snapshot start time based on the change type, the instance information, and the order information comprises:
if the change type is a non-charging update type, the snapshot starting time is the instance update time in the instance information; otherwise, the snapshot starting time is the order service starting time in the order information.
5. The method of claim 3, wherein the instance information comprises an instance identifier, an instance update time, and an instance data version, and wherein the snapshot identifier corresponds to the instance snapshot information one to one.
6. The method of claim 1, wherein after generating instance snapshot information based on the instance update information, further comprising:
and modifying the default snapshot end time in the snapshot information of the last instance into the snapshot start time in the snapshot information of the instance.
7. A cloud computing resource metering device, comprising:
the system comprises an instance update information receiving module, an instance update information transmitting module and an instance update information receiving module, wherein the instance update information is information transmitted by the instance module when an instance state changes;
the instance snapshot generating module is used for generating instance snapshot information based on the instance updating information;
and the cloud computing resource metering module is used for sending the instance snapshot information to the metering module so as to enable the metering module to measure the cloud computing resources based on the instance snapshot information.
8. A cloud computing resource metering system, characterized by comprising an instance snapshot module, an instance module and a metering module, wherein the instance snapshot module is connected in communication with the instance module and the metering module and is used for executing the cloud computing resource metering method of any one of claims 1 to 6.
9. An electronic device, characterized in that the electronic device comprises:
a processor;
a memory for storing the processor-executable instructions;
the processor is configured to read the executable instructions from the memory and execute the instructions to implement the cloud computing resource metering method of any of claims 1-6.
10. A computer-readable storage medium, wherein the storage medium stores a computer program for executing the cloud computing resource metering method according to any one of claims 1 to 6.
CN202011017625.0A 2020-09-24 2020-09-24 Cloud computing resource metering method, device, system, equipment and medium Pending CN112181650A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011017625.0A CN112181650A (en) 2020-09-24 2020-09-24 Cloud computing resource metering method, device, system, equipment and medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011017625.0A CN112181650A (en) 2020-09-24 2020-09-24 Cloud computing resource metering method, device, system, equipment and medium

Publications (1)

Publication Number Publication Date
CN112181650A true CN112181650A (en) 2021-01-05

Family

ID=73955505

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011017625.0A Pending CN112181650A (en) 2020-09-24 2020-09-24 Cloud computing resource metering method, device, system, equipment and medium

Country Status (1)

Country Link
CN (1) CN112181650A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113032704A (en) * 2021-02-24 2021-06-25 广州虎牙科技有限公司 Data processing method, device, electronic equipment and medium

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113032704A (en) * 2021-02-24 2021-06-25 广州虎牙科技有限公司 Data processing method, device, electronic equipment and medium
CN113032704B (en) * 2021-02-24 2024-06-21 广州虎牙科技有限公司 Data processing method, device, electronic equipment and medium

Similar Documents

Publication Publication Date Title
KR102263985B1 (en) Method and system for providing validated, auditable, and immutable inputs to a smart contract
US8024397B1 (en) System for generating a services repository using a target services roadmap
CN110619555A (en) Unified management method and device for order information, terminal equipment and medium
US10511453B2 (en) Information processing system and charge calculation apparatus
TW200917084A (en) Metered pay-as-you-go computing experience
WO2014159296A1 (en) A method, system and program product for matching of transaction records
US20150120479A1 (en) Catalog driven order management for rule definition
US20140156477A1 (en) Platform-as-a-service billing
US20230360145A1 (en) Method and system for processing transactions based on transaction archetypes
CN109885290B (en) Application program service description information generation and release method, device and storage medium
CN112181650A (en) Cloud computing resource metering method, device, system, equipment and medium
CN112258306B (en) Account information checking method, device, electronic equipment and storage medium
CN111144995A (en) Shop purchase reconciliation management system and method based on home decoration industry
US9189299B2 (en) Framework for system communication for handling data
CN110189124A (en) Anti-attack method, equipment and storage medium
KR20170098822A (en) Processing data service
US8468159B2 (en) Data element categorization in a service-oriented architecture
US7882153B1 (en) Method and system for electronic messaging of trade data
CN115391343A (en) Bill data processing method and device, electronic equipment and storage medium
US11593799B2 (en) Message-less B2B transaction processing
JP2013214177A (en) Settlement processing system, settlement processing device, settlement processing method and program
CN113448960A (en) Method and device for importing form file
CN111857876A (en) Service processing method and device, electronic equipment and computer readable medium
KR20140127519A (en) Subcontract management system and performing mehtod thereof
KR102612583B1 (en) System and method for representing licenses for export and computer program for the same

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination