Key-based handling of product purchases
A hybrid database system using a relational and key-value database structure addresses scalability issues by converting relational data into efficient file structures, reducing response times and enhancing transaction handling capacity.
Patent Information
- Application Number
- JP2024525125
- Authority / Receiving Office
- JP · JP
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2021-10-26
- Filing Date
- 2022-10-21
- Publication Date
- 2024-11-06
AI Technical Summary
Relational databases struggle to scale with large transaction volumes, particularly in systems handling numerous simultaneous purchase requests, limiting their suitability for large hotel chains or complex product categories due to transaction per second limitations.
A hybrid database system combining a relational database with a key-value database, where relational data is converted into first and second files stored in the key-value database, enabling efficient data retrieval through interface modules and purchasing engines.
The hybrid system significantly reduces response times for product availability queries from approximately 500 ms to less than 80 ms, facilitating real-time data retrieval and high availability services.
Smart Images

Figure 2024541021000001_ABST
Abstract
Description
[Technical field]
[0001] The present invention relates generally to a computerized system and method for merchandise purchasing using large database systems, and more particularly to key-based data retrieval of transformed merchandise information during merchandise purchasing. [Background technology]
[0002] As goods can be purchased worldwide, implementing and supporting computerized goods purchasing has become increasingly complex and resource demanding. Most of the goods information is stored in relational database systems that are queried to receive information about goods that meet a request and to enable the purchase of the goods.
[0003] For example, hotel property managers input hotel rates into their property management system via an interface connected to one or more relational databases. Then, when a traveler makes a purchase request, a purchasing engine accesses one or more relational databases to obtain available rates. However, relational data models are usually not scalable. Relational databases can therefore only handle a limited number of transactions per second. Such an architecture is therefore not suitable for a hotel chain with 6000 hotels and a large number of simultaneous purchase requests, since the number of transactions supported per second is usually around 20, whereas 5000 transactions per second should be handled in practice.
[0004] Computerized implementations of merchandise purchasing for many other merchandise categories also face similar constraints because merchandise management systems traditionally rely on relational databases for atomicity, concurrency, and isolation. Summary of the Invention [Means for solving the problem]
[0005] SUMMARY OF THE PRESENTLY PREFERRED EMBODIMENTS The following presents a simplified summary of the subject matter in order to provide a basic understanding of some aspects of the subject matter. This summary is not an extensive overview of the subject matter and is not intended to identify key / critical elements of the embodiments or to delineate the scope of the subject matter.
[0006] Its sole purpose is to present some concepts of the subject matter in a simplified form as a prelude to the more detailed description that is presented later.
[0007] According to a first aspect, a database system for handling purchases of goods is provided. The database system comprises a relational database storing relational data for a plurality of goods, and a key-value database storing a plurality of first files and a plurality of second files, the first and second files representing the relational data, the first files being accessible by using respective first keys associated with the goods and including respective at least one second key, and the second files being accessible by using respective at least one second key. The database system further comprises an interface module connecting the relational database with the key-value database, and a purchasing engine in communication with the key-value database.
[0008] The interface module is configured to convert, for each product, at least a portion of the relational data stored in the relational database into one of the first files and at least one of the second files, and store the one first file and the at least one second file in the key-value database. Additionally, the purchasing engine is configured to receive an availability request for a product from a client device, query the key-value database by using a first key associated with the product to retrieve a first file associated with the product, process the first file to extract at least one second key and metadata associated with the at least one second key, compare the metadata to the availability request for each second key to determine second keys whose metadata satisfy the availability request, query the key-value database by using the list of second keys that satisfy the availability request to receive a corresponding second file, extract data from the second file, and transmit the data extracted from the second file to the client device.
[0009] According to a second aspect, a method for handling purchases of items in a database system is provided. The method includes converting at least a portion of relational data stored in a relational database into one of a first file and at least one of a second file for each item, and storing the one first file and the at least one second file in a key-value database. The method further includes receiving an availability request for an item from a client device, querying the key-value database by using a first key associated with the item to retrieve a first file associated with the item, processing the first file to extract at least one second key and metadata associated with the at least one second key, comparing the metadata with the availability request for each second key to determine second keys whose metadata satisfy the availability request, querying the key-value database by using a list of the second keys that satisfy the availability request to receive a corresponding second file, extracting data from the second file, and transmitting the data extracted from the second file to the client device.
[0010] According to a third aspect, there is provided a computer program product, either in the form of a machine-readable medium having program code stored thereon, or in the form of a propagated signal containing a representation of the program code, the program code being arranged to, when executed on a computer system, perform a method, the method comprising: converting, for each product, at least a portion of the relational data stored in the relational database into one of the first files and at least one of the second files, and storing the one first file and the at least one second file in a key-value database. The method further includes receiving an availability request for a product from a client device; querying a key-value database by using a first key associated with the product to retrieve a first file associated with the product; processing the first file to extract at least one second key and metadata associated with the at least one second key; for each second key, comparing the metadata with the availability request to determine second keys whose metadata satisfy the availability request; querying a key-value database by using the list of second keys that satisfy the availability request to receive corresponding second files; extracting data from the second files; and transmitting the data extracted from the second files to the client device.
[0011] These and other objects, embodiments and advantages will become readily apparent to those skilled in the art from the following detailed description of the embodiments, which are to be read in conjunction with the accompanying drawings, and the invention is not limited to any particular embodiment.
[0012] The above and further objects, features and advantages of the present subject matter will become apparent from the following description of illustrative embodiments with reference to the accompanying drawings, in which like numerals are used to represent like elements.
[0013] It should be noted, however, that the attached drawings together with the reference numbers merely illustrate exemplary embodiments of the present subject matter and therefore should not be considered as limiting its scope, since the subject matter may admit of other equally effective embodiments.
[0014] Accordingly, embodiments will be described with reference to the following figures. [Brief description of the drawings]
[0015] [Figure 1] FIG. 1 illustrates a database system for handling product purchases according to the present invention. [Diagram 2] FIG. 2 is an expanded view of a database system that handles product purchases. [Diagram 3] FIG. 1 illustrates a key-value database having a first and second file. [Figure 4] 1 is a flowchart for converting relational data into a first and a second file. [Diagram 5] 1 is a flow chart of data retrieval and extraction for product purchases. [Figure 6] FIG. 1 illustrates an example of flattening data to convert relational data into a first and second file. [Figure 7A] FIG. 1 illustrates an example of serializing data to convert relational data into a first and second file. [Figure 7B] FIG. 1 illustrates an example of serializing data to convert relational data into a first and second file. [Figure 8] FIG. 13 illustrates an example of data retrieval in a first, second, and third file. [Figure 9] FIG. 1 illustrates an embodiment having a periodic merger module for travel-related purchases. [Figure 10] 13 is a flowchart for extracting a validity period for converting relational data into a first and a second file. [Figure 11]1 is a diagrammatic representation of an exemplary computing machine for implementing the methods described herein. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS
[0016] 1 shows a database system 100 for handling product purchases according to the present invention. The database system 100 includes a relational database 101, a key-value database 102, an interface module 103, and a purchasing engine 104.
[0017] The relational database 101 stores relational data for multiple products. The products may be travel-related products, food-related products, entertainment-related products, etc., all of the same type. The relational database 101 may also store products of different types. Products of one type may be of the same subtype, for example, the relational database 101 may store travel-related products and hotel reservation products among others. The relational data also includes information of the products, i.e., detailed description, price, availability, shipping cost, additional bookable services, manufacturer, airline / provider of the service, depending on the product purchased more or less. The relational database 101 may be Oracle®, MySQL™, Microsoft® SQL Server, IBM® Db2®, SQLite, MariaDB, Apache Hive™, or any other relational database.
[0018] The key-value database 102 stores a plurality of first files and a plurality of second files, where the first and second files represent the relational data stored in the relational database 101. The relational data of the products stored in the relational database 101 is converted into corresponding first and second files stored in the key-value database 102. The key-value database 102 may be Couchbase, LevelDB, Redis, Riak, or any other key-value database. The relational database 101 as well as the key-value database may be locally stored databases or may be distributed database systems that may also comprise multiple separately stored databases.
[0019] The interface module 103 is a conversion module that connects the relational database 101 and the key-value database 102 and converts data from the relational database 101 to be stored as files in the key-value database 102. For example, the relational database 101 holds data related to hotel reservations. The interface module 103 can be configured to convert the relational data into a first file and at least one second file periodically at a predefined time interval, for example, hourly, daily, or any other suitable time interval.
[0020] The purchasing engine 104 is a module configured to execute a purchasing process by communicating with the key-value database 102. The purchasing engine 104 and the interface module can be stored on the same server, separate servers, a cloud, or any other suitable system or location. The relational database 101, the key-value database 102, the interface module 103, and the purchasing engine 104 can be connected via a network. The network can be a wide area network, a global network, the Internet, or a similar network, can be a public network or a private network, and can include multiple interconnected networks as known in the art.
[0021] FIG. 2 shows an expanded view of database system 100 handling product purchases, where multiple client devices 205 and multiple provider devices 206 are also connected to database system 100 .
[0022] The client device 205 can connect to the purchasing engine to search for and / or purchase products. For example, the client device 205 includes at least one of a computer, a server, a mobile station, a laptop, a smartphone, an application, and / or a further database system. The client device 205 can send a request to the purchasing engine to purchase the product. Such a request can generally be referred to as an availability request when an available product is requested. However, depending on the specific implementation of the purchasing engine 104, currently unavailable products may still be returned to the client device 205 for informational purposes. For example, the client device 205 can also retrieve information of all existing hotel room types in response to an availability request, even if some room types are not available at the specific time requested.
[0023] The provider devices 206 may further connect to the relational database 101 to store data regarding products to be provided to the client devices. The provider devices 206 may each be associated with one or more providers of products that the client devices 205 may purchase. For example, a provider may be a carrier, a leisure / event provider, or a travel provider, such as an airline, a hotel or hotel chain, a taxi company, a car rental agency, a train company, an event agency, a ticketing platform, or a meta-agency that handles and offers multiple different services. Additionally or alternatively, a provider may be a mobile operator, a network operator, a warehouse, a shopping chain, etc.
[0024] The client devices 205 and the provider devices 206 can be connected to the database system 100 via a network, which may be a wide area network, a global network, the Internet, or a similar network, which may be a public or private network, and may include multiple interconnected networks as known in the art. The provider devices 206 can thereby connect directly to the relational database 101 or connect through an interface or other additional module (not shown).
[0025] A provider can store data of products to be offered to clients in the relational database 101, for example in a tree structure according to a given relational database scheme. For example, if the product is an apartment or a hotel room, there may be a table in the relational database 101 that contains all the characteristics, i.e., contains entries for rooms offered by all hotels. The table may have columns for different characteristics of the hotel, such as city code, country code, name, chain, etc. Another table may hold information about the type of room, for example with information such as facilities and view type, another table may hold information about rate plans, another table may hold information about no-show or cancellation rules, etc. Thus, there are multiple tables that specify such a final product, in one example a hotel room, in a tree structure. In the hotel room example, the relational database 101 may store at least the database tables shown in Table 1.
[0026] [Table 1]
[0027] The rate plan is the main element for calculating the final product as it identifies the price, i.e. the rate of a hotel room. The list of hotel room rates and hotel room features constitutes the offer sold to the customer. Thus, the table RatePlan contains a list of all rate plans for a given characteristic. The table PriceGrid contains parameters for the price and references to the amount rules. The table AmountRule specifies the rules for calculating the price, this table contains among other things the amount (fixed amount or relative amount such as a percentage) and the date period for which this amount is applicable. Multiple amount rules allow covering different periodicities and different products. Price grids can be combined to create different prices. Consider for example a first price grid PG1 contains a fixed amount, say 500 USD, and another price grid PG2 contains a relative amount, say -10%. If price grid PG1 is linked to PG2, the resulting price is 450 USD.
[0028] The policy table contains the terms of sale. House policies are terms of sale that are specified for a specific hotel and a given time period. Other policy tables specify the terms of sale for a given rate plan. Taxes are specified using two tables, TaxRule and Tax. These two tables can reference other taxes to create complex tax schemes. Rate plans can have no constraints or one or more constraints. The NoArrivalRule table specifies a constraint that prohibits the use of this rate if the check-in date is before a specific date, and the NoStayRule table specifies a constraint that prohibits the use of this rate when the check-in is within a specific period. The HurdlePoint table is further specified if a rate plan must be set when the calculated price is not available if it is below a certain amount.
[0029] 3 depicts a key-value database 102 having a plurality of first files 310 and a plurality of second files 320. The first files 310 are accessible by using respective first keys 311, which define respective unique identifiers for obtaining data from the first files 310. The second files 320 are accessible by using respective second keys 321, 322, which define respective identifiers unique to the respective second files 320. Thus, each first file 310 or second file 320 is associated with a particular unique key 311, 321, 322 required to access the first file 310 or second file 320, respectively. A first key 311 is stored in the relational database 101 and is associated with a particular product, e.g., each product, having its unique key in the key-value database 102, thereby enabling access to a first file 310 associated with the product.
[0030] Any one of the first files 310 includes at least one second key 321, 322 in its value part. The at least one second key 321, 322 included in the first file 310 can be used to access the second file 320. In the example of FIG. 3, the second key 321 stored in the first file 310 is identical to the second key 321 (indicated by dotted line 323), and the second key 322 stored in the first file 310 is identical to the second key 322 (indicated by dotted line 324). Therefore, based on the second keys 321, 322 stored in the first file 310, efficient retrieval of data related to the goods stored in the first file 310 can be achieved.
[0031] The approach of having a first file 310 and at least one second file 320, with the first file 310 equipped with second keys 321, 322 for accessing at least one second file 320, is based on a technical optimum between data retrieval time and data processing time. If all data related to a concrete product or product series is contained in the first file 310, such as all requested information about all rooms in a hotel, the data retrieval time is short when only one single file, i.e. the first file 310, has to be accessed. However, the time to extract and process the relevant data from the first file 310, which will further have a significant size, will far exceed the acceptable response time. Therefore, when responding to a request, the optimum of data retrieval and data processing time can be achieved by dividing the data in the first file 310 and the multiple second files 320, selecting the relevant second keys 321, 322 from the first file 310, and only retrieving the relevant data from the respective second file 320.
[0032] In the hotel room example, the first file 310 may include basic information about a hotel with multiple hotel rooms. For example, the first file 310 may include property level data that consists of two different pieces of information. The first piece may be a rate plan information piece and the second piece may be a parity group information piece.
[0033] The rate plan information portion can store a list of all rate plans distributed in the property and a list of all possible room types for each rate plan. The rate plan information portion can also contain data replicated from the second file 320 to allow filtering the results and / or accelerating access. For example, the first file 310 can contain meta information dedicated to the listed rate plans that specifies when the rate plan is applicable, e.g., the end or beginning of the sale date and / or the stay date, to allow filtering out inapplicable rate plans to the final candidates. The parity group information portion can store rate plan dependencies. For example, the parity group information describes groups of rates that depend on others. For example, rates B, C, and D depend on rate A, so that if rate A is not available, rates B, C, and D are also not available.
[0034] Similar to the feature level data, the second file 320 includes rate plan data. Rate plans typically have conditioning rules applicable to the rate plan based on the calendar periodicity that allows for transactions. These rules are then stored in the second file 320. Additionally, the second file 320 may also store policies that describe minimum requirements or conditions that a customer must satisfy to be able to book an offering, or penalties & fees if the customer fails to satisfy these rules. Additionally, the second file 320 may also include price grid data that includes data about the price grid, e.g., the code of the price grid, the type of the price grid, etc., and amount rule data that specifies the actual price of the product.
[0035] This specific distribution and reorganization of the hotel room information into a two-level file structure in which the first file 310 and the second file 320 are stored in the key-value database 102 significantly reduces the response time to the purchase request. For example, if all data required for a purchase / search request is retrieved from the relational database 101, the response time is expected to be about 500 ms or more. For the same purchase / search request, but using the two-level file structure in the key-value database 102 as described above, the response time will likely be less than 50 ms and may never exceed 80 ms. The more data stored in the relational database 101, the greater the response time savings when applying the described two-level file structure in the key-value database 102.
[0036] As will be apparent to those skilled in the art from the above description, the data stored in the relational database 101 and the key-value database 102 correspond to each other. Therefore, data conversion is required between the relational data and the key-value data, as shown in FIG.
[0037] The interface module 103 thus implements a two-stage conversion process: the interface module 103 can convert the relational data to the first file 310 and the second file 320 periodically at predefined time intervals, or can convert the relational data in response to changes in the data in the relational database 101.
[0038] As shown in box 401, a portion of the relational data for the item is converted and stored in a first file, such as first file 310. In the hotel room example, where first file 310 stores property data, data related to the properties is extracted from relational database 101, specifically from at least a table named RatePlan, but in some embodiments from other tables as well. As shown in box 402, a portion of the relational data for the item is further converted and stored in a second file, such as second file 320. In some embodiments, at least a portion of the data stored in second file 320 is replicated to first file 310. In the hotel example, both first file 310 and second file 320 may contain information extracted from a table named AmountRule.
[0039] The first file 310 and the second file 320 may be stored in the same data format. In alternative embodiments, the data formats of the first file 310 and the second file 320 may be different. The data format of the first file 310 and / or the second file 320 may be JavaScript Object Notation (JSON), Hypertext Markup Language (HTML), or any other suitable data format.
[0040] The conversion of the data of the relational database 101 into the files stored in the key-value database 102 can therefore include a flattening process, where the data contained in the relational database 101 is stored in the first file 310 and the second file 320. The flattening process can also include further calculations. In the hotel room example, besides storing all the information about the price grid in the second file 320, for example, the general price grid information and the amount rules per calendar period, the second file 320 can also contain the final price of the product by retrieving and resolving the dependency tree. Thus, the conversion process as depicted in FIG. 4 results in a hierarchical functional structure, so that the core information of each second file is stored in the upper layer. This allows retrieving and extracting the data for the product purchase, since only the second files 320 that satisfy the availability requirements are accessed, resulting in efficient retrieval of the data by efficient filtering of the data.
[0041] Retrieving and extracting data for a product purchase includes activities shown in the flowchart of Figure 5. The purchasing engine 104 receives a product availability request from a client device 205 at box 501. The availability request may include information of the product the client wishes to purchase. For example, the availability request may include arrival and departure dates and city / location if the client is looking for a hotel room.
[0042] Next, as depicted in box 502, the key-value database 102 is queried (e.g., by the interface module 103) by using the first key 311 associated with the item to retrieve the first file 310 associated with the item. In an embodiment, the first key 311 may be included in the availability query, i.e., may be entered by a client, or may be retrieved by the purchasing engine 104 through a pre-processing query to the database, which may be the relational database 101 or any other remote or local storage device. The pre-processing query may, for example, request all first keys 311 that satisfy the availability request. In the hotel room example, the purchasing engine 104 may retrieve all unique identification numbers of properties that satisfy the availability request in terms of location, i.e., first keys 311 in this example, such as all hotels located in the city included in the availability request. In another example, if the availability request is a dedicated request, i.e., a request for availability of a room of a specified property, the first key 311 may be retrieved by mapping the property name to the unique identification number.
[0043] Each first file 310 can be accessed by using the first key 311. The first file 310 is then processed to extract at least one second key 321, 322 as well as metadata. This is illustrated in box 503. Metadata is, for example, data that allows the interface module 103 to determine which second files 320 satisfy the availability request or, in other words, apply to the availability request. In the hotel room example, the metadata corresponds to the meta information mentioned above. Thus, the metadata includes information on whether a rate plan is applicable to the availability request. Thus, the metadata is compared with the availability request for each second key 321, 322 to determine the second keys 321, 322 whose metadata satisfy the availability request (illustrated in box 504).
[0044] For those determined second keys 321, 322, the key-value database 102 is queried, as shown in box 505. This can be done by using a list of said second keys 321, 322 that satisfy the availability request, resulting in receiving at least one corresponding second file 320. In box 506, data is extracted from said at least one second file 320 to build a final product. In the hotel room example, the respective conditions and prices stored in the second file 320 for each rate plan are taken and combined with the information in the first file 310 to build at least one final hotel room product available for booking by the requesting client. The extracted data corresponding to the final product to be offered is then transmitted to the requesting client device, as shown by the last box 507.
[0045] The method facilitates real-time data retrieval. The proposed system enables high availability of services with short response times. Conventional systems employing relational databases require a huge number of joint queries to the database to retrieve available products. In the proposed system, data retrieval only requires retrieval of one first file 310 related to the required characteristics and N number of second files 320 depending on the number of tariff plans that satisfy the request. Hence, the response time can be reduced to below 80 ms.
[0046] FIG. 6 illustrates an example of flattening data to convert relational data into a first file 310 and a second file 320. On the left side 601, a tree structure of relational data stored in the relational database 101 is depicted. For example, illustrating an embodiment of a hotel room, there may be one property that offers two rate plans. One rate plan has three dependent rate plans that are only applicable under certain conditions. The other rate plan has two further rules that can be satisfied if a reservation is made. The tree structure is then converted by the interface module 103 into a plurality of first files 310 and second files 320 on the right side 602.
[0047] 7A and 7B show an example of serializing data to convert relational data into a first file 310 and a second file 320. In FIG. 7A, relational data from a relational database 101 is converted via an interface module 103 into a data file that is stored in a key-value database 102. In this embodiment, the interface module 103 applies a serialization protocol 733 to the relational data and stores the serialized data into the first file 310 and the second file 320. Using the serialization protocol, the data structures of the relational database 101 are transformed into data structures that can be stored more efficiently (requiring less memory) and constitute a semantically identical clone of the original data. The serialization protocol may be, for example, the Google Protobuf serialization protocol, the Hessian 2.0 serialization protocol, the Redis serialization protocol, or any other suitable protocol. Serialization can generally be achieved by using protocol buffers or flat buffers.
[0048] 7B, the interface module 103 further applies a compression protocol 734 to the serialized data. Applying the compression protocol to the serialized data enables efficient storage of the first file 310 and the second file 320. The compression protocol may be, for example, the Internet Protocol (IP) Payload compression protocol, the Snappy compression protocol, or any other suitable protocol.
[0049] 8 shows an embodiment in which three layers of files are stored in the key-value database 102. Thus, a first file 310 contains at least one second key 321 of at least one second file 320. The second file 320 in turn contains at least one third key 831 of at least one third file 830. Of course, more than three layers of files are possible if desired.
[0050] 9 illustrates a further embodiment for purchasing travel-related products. Prices of travel-related products usually depend on the time intervals to which they apply. Therefore, the interface module 103 further comprises a periodicity merging module 935. When converting the relational data stored in the relational database 101, the periodicity merging module 935 included in the interface module 103 identifies such time intervals of the price structure and creates entries in the first file 310 and / or the second file 320 of the key-value database 102 reflecting the price structure and the time intervals.
[0051] The workflow of the periodicity merging module 935 is depicted in the flowchart of Figure 10. The periodicity merging module 935 determines a validity period of at least one price of a travel-related product, i.e., a time period for which the price applies, based on the time dependency of the price of the travel-related product. This is shown in box 1001. For example, the periodicity merging module 935 analyzes the data stored in the relational database 101. For every price grid, it is analyzed whether the price is time-dependent. If so, the validity period is determined.
[0052] The periodicity merging module 935 then identifies at least one price periodicity and structure, if any, within the validity period (box 1002). For example, if the price applies only on weekends, the periodicity may be weekly and the validity period may be two days. Additionally, the price structure may be conditions that apply to the price, such as an amount but only for children or seniors, only in combination with late arrival, etc.
[0053] In box 1003, the period merger module 935 creates an identifier for the structure, i.e., a unique identifier for the particular price structure. This identifier is then stored, for example in the first file 310, along with the respective effective periods. The second file 320 can then store the particular price structures. This is depicted in box 1004. By storing the effective periods separately from the particular structure, multiple effective periods can be defined for a structure.
[0054] In another embodiment, a computer program product is provided that includes instructions that, when executed by a computer, cause the computer to perform a method as described herein. The program code embodied in any of the applications / modules described herein may be provided separately or collectively as a program product in a variety of different forms. In particular, the program code may be provided using a computer readable storage medium having computer readable program instructions thereon to cause a processor to perform aspects of an embodiment of the present invention.
[0055] Computer-readable storage media that are non-transitory in nature may include volatile and non-volatile, as well as removable and non-removable tangible media implemented in any manner or technology for storage of information, such as computer-readable instructions, data structures, program modules, or other data. Computer-readable storage media may further include random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other solid-state memory technology, portable compact disc read-only memory (CD-ROM), or other optical storage devices, magnetic cassettes, magnetic tapes, magnetic disk storage devices or other magnetic storage devices, or any other medium that can be used to store the desired information and that can be read by a computer.
[0056] The computer readable storage medium should not be considered as a transitory signal itself (e.g., radio waves or other propagating electromagnetic waves, electromagnetic waves propagating through a transmission medium such as a waveguide, or electrical signals transmitted through wires). The computer readable program instructions can be downloaded from the computer readable storage medium to a computer, another type of programmable data processing device, or another device, or over a network to an external computer or external storage device.
[0057] 11 is a diagrammatic representation of an exemplary computing machine 1100 for implementing at least a portion of the methods described herein. A similar computing machine may also implement one or more of the modules / interfaces 103, 104, client device 205 and / or provider device 206, and databases 101, 102 described above. The computing machine 1100 includes a set of instructions that, when executed by the computing machine 1100, cause the computing machine 1100 to perform any of the methods discussed herein.
[0058] The computing machine 1100 includes at least one processor 1101, a main memory 1106, and a network interface device 1103, which communicate with each other via a bus 1104. Optionally, the computing machine 1100 may further include a static memory 1105 and a disk drive unit. A video display, an alphanumeric input device, and a cursor control device may be provided as examples of a user interface 1102. The network interface device 1103 connects the computing machine 1100 to any of the other components described above.
[0059] The computing machine 1100 includes a memory 1106, such as a main memory, a random access memory (RAM), and / or any further volatile memory. The memory 1106 may store temporary and program data to facilitate the functionality of the database system 100. The memory 106 may also include one or more caches 1107 that store recently retrieved data from the databases 101, 102. The caches may be level 1 (L1), level 2 (L2), and / or level 3 (L3) caches. The memory 1106 may also store computer program data 1108 for implementing the methods as described above.
[0060] A set of computer executable instructions (computer program code 1108) embodying any one or all of the methods described herein reside completely or at least partially in or on a machine readable storage medium, such as, for example, memory 1106. The instructions 1108 may further be transmitted or received as propagated signals, via the Internet through network interface device 1103 or via user interface 1102. Communication with the computing machine is effected via bus 1104. The basic operation of the computing machine 1100 is controlled by an operating system, which is also located in memory 1106, at least one processor 1101, and / or static memory 1105.
[0061] While specific embodiments and variations of the invention have been described herein, it should be understood that further modifications and alternatives will be apparent to those skilled in the relevant art. In particular, examples are provided to explain the principles of the invention and to provide some specific methods and arrangements for carrying out those principles.
[0062] Accordingly, the described embodiments should be understood to be provided by way of example, for the purpose of teaching the general features and principles of the invention, but should not be understood as limiting the scope of the invention as defined in the appended claims. [Explanation of symbols]
[0063] 100 Database Systems 101 Relational Database 102 Key-Value Database 103 Interface Module, Module / Interface 104 Purchasing Engine, Modules / Interfaces 205 client devices 206 Provider Device 310 First File 311 First key, unique key 320 Second File 321 Secondary key, unique key 322 Secondary key, unique key 323 Dotted Line 324 Dotted Line 733 Serialization Protocol 734 Compression Protocol 830 Third File 831 The Third Key 935 Periodic Merger Module 1100 Computing Machine 1101 Processor 1102 User Interface 1103 Network Interface Device 1104 Bus 1105 Static Memory 1106 Main Memory 1107 Cache 1108 Computer program data, computer program code, instructions
Claims
1. 1. A database system for handling purchases of merchandise, comprising: a relational database that stores relational data about a plurality of products; a key-value database storing a plurality of first files and a plurality of second files, the first and second files representing the relational data, the first files being accessible by using a respective first key associated with the product and including a respective at least one second key, and the second files being accessible by using the respective at least one second key; an interface module connecting the relational database with the key-value database; a purchasing engine in communication with the key-value database; Equipped with The interface module includes: converting, for each product, at least a portion of the relational data stored in the relational database into one of the first files and at least one of the second files; storing the one first file and the at least one second file in the key-value database; configured to: The purchasing engine, receiving an availability request for the product from a client device; querying the key-value database using a first key associated with the item to retrieve a first file associated with the item; processing the first file to extract at least one second key and metadata associated with the at least one second key; for each second key, comparing the metadata to the availability requirements to determine second keys whose metadata satisfy the availability requirements; querying the key-value database by using the list of second keys that satisfy the availability request to receive corresponding second files; Extracting data from the second file; and transmitting the data extracted from the second file to the client device; The database system is configured to:
2. 2. The database system of claim 1, wherein the interface module is further configured to convert the relational data into the first file and the at least one second file while flattening a tree structure of the relational database.
3. 2. The database system of claim 1, wherein the interface module is further configured to convert the relational data into the first file and the at least one second file while applying a serialization protocol to the relational data and storing serialized data in the first file and the second file.
4. 4. The database system of claim 3, wherein the interface module is further configured to convert the relational data into the first file and the second file while applying a compression protocol to the serialized data.
5. The database system of claim 1 , wherein the purchasing engine and / or the interface module are configured to store a mapping of the relational data in corresponding the first file and the at least one second file.
6. The database system of claim 1 , wherein the interface module is configured to convert the relational data into the first file and the at least one second file periodically at a predefined time interval.
7. 2. The database system of claim 1, wherein the interface module is configured to convert the relational data into the first file and the at least one second file in response to a change in the relational data.
8. 2. The database system of claim 1, wherein the first file and / or the second file include at least one third key, the key-value database further stores a third file, and the interface module is further configured to convert a portion of the relational data into at least one third file, the third file being accessible by using the at least one third key.
9. The database system according to claim 1 , wherein the purchase of the product is a reservation for a travel-related product.
10. The interface module comprises a periodic merging module, the periodic merging module comprising: determining a validity period for at least one price of the travel-related product based on a time dependency of a price of the travel-related product; identifying a periodicity and structure of said at least one price within said validity period; creating an identifier for the structure; storing said validity periods together with respective identifiers separately from said structures; The database system of claim 9 , configured to:
11. 1. A method for handling purchases of goods in a database system, the database system comprising: a relational database that stores relational data about a plurality of products; a key-value database storing a plurality of first files and a plurality of second files, the first and second files representing the relational data, the first files being accessible by using a respective first key associated with the product and including a respective at least one second key, and the second files being accessible by using the respective at least one second key; an interface module connecting the relational database with the key-value database; a purchasing engine in communication with the key-value database; Equipped with The method further comprising: converting, for each product, at least a portion of the relational data stored in the relational database into one of the first files and at least one of the second files; storing the one first file and the at least one second file in the key-value database; receiving an availability request for the product from a client device; querying the key-value database using a first key associated with the item to retrieve a first file associated with the item; processing the first file to extract at least one second key and metadata associated with the at least one second key; for each second key, comparing the metadata with the availability requirements to determine second keys whose metadata satisfy the availability requirements; querying the key-value database by using the list of second keys that satisfy the availability requirement to receive corresponding second files; extracting data from the second file; transmitting the data extracted from the second file to the client device; A method comprising:
12. 12. The method of claim 11, further comprising converting the relational data into the first file and the at least one second file while flattening a tree structure of the relational database.
13. 12. The method of claim 11, further comprising: converting the relational data into the first file and the at least one second file while applying a serialization protocol to the relational data and storing serialized data in the first file and the second file.
14. 14. The method of claim 13, further comprising converting the relational data into the first file and the second file while applying a compression protocol to the serialized data.
15. The method of claim 11 , further comprising storing the mapping of the relational data in corresponding first and at least one second files.
16. The method of claim 11 , further comprising converting the relational data into the first file and the at least one second file periodically at a predefined time interval.
17. The method of claim 11 , further comprising the step of transforming the relational data into the first file and the at least one second file in response to a change in the relational data.
18. 12. The method of claim 11, wherein the first file and / or the second file include at least one third key, the key-value database further stores a third file, and the method further comprises converting a portion of the relational data into at least one third file, the third file being accessible by using the at least one third key.
19. The method of claim 11 , wherein the purchase of a product is a travel-related reservation.
20. determining a validity period for at least one price of the travel-related product based on a time-dependency of a price of the travel-related product; identifying a periodicity and structure of said at least one price within said validity period; creating an identifier for the structure; storing said validity periods together with respective identifiers separately from said structures; 20. The method of claim 19, further comprising:
21. A non-transitory machine-readable medium storing program code, the program code, when executed on a computer system, converting, for each product of a plurality of products, at least a portion of relational data stored in a relational database into one of a plurality of first files and at least one of a plurality of second files, the relational data relating to the plurality of products; storing the one first file and the at least one second file in a key-value database; receiving an availability request for the product from a client device; querying the key-value database using a first key associated with the item to retrieve a first file associated with the item; processing the first file to extract at least one second key and metadata associated with the at least one second key; for each second key, comparing the metadata with the availability requirements to determine second keys whose metadata satisfy the availability requirements; querying the key-value database by using the list of second keys that satisfy the availability requirement to receive corresponding second files; extracting data from the second file; transmitting the data extracted from the second file to the client device; 16. A non-transitory machine-readable medium configured to perform a method comprising:
22. 22. The non-transitory machine-readable medium of claim 21 , wherein the method further comprises converting the relational data into the first file and the at least one second file while flattening a tree structure of the relational database.
23. 22. The non-transitory machine-readable medium of claim 21, wherein the method further comprises: converting the relational data into the first file and the at least one second file while applying a serialization protocol to the relational data and storing serialized data in the first file and the second file.
24. 24. The non-transitory machine-readable medium of claim 23, wherein the method further comprises converting the relational data into the first file and the second file while applying a compression protocol to the serialized data.
25. 22. The non-transitory machine-readable medium of claim 21, the method further comprising storing the mapping of the relational data in corresponding the first file and the at least one second file.
26. 22. The non-transitory machine-readable medium of claim 21, wherein the method further comprises converting the relational data into the first file and the at least one second file periodically at a predefined time interval.
27. 22. The non-transitory machine-readable medium of claim 21, wherein the method further comprises converting the relational data into the first file and the at least one second file in response to a change in the relational data.
28. 22. The non-transitory machine-readable medium of claim 21, wherein the first file and / or the second file include at least one third key, the key-value database further stores a third file, and the method further includes converting a portion of the relational data into at least one third file, the third file being accessible by using the at least one third key.
29. 22. The non-transitory machine-readable medium of claim 21, wherein the purchase of a product is a reservation for a travel-related product.
30. The method further comprising: determining a validity period for at least one price of the travel-related product based on a time-dependency of a price of the travel-related product; identifying a periodicity and structure of said at least one price within said validity period; creating an identifier for the structure; storing said validity periods together with respective identifiers separately from said structures; 30. The non-transitory machine-readable medium of claim 29, further comprising:
Citation Information
Patent Citations
Device and method for determining changeable service and recording medium
JP2002007590A
Database cache device using key-value store
JP2011008451A
Data search program, database device, and information processing system
JP2014048741A
Information storage system
JP2015184685A
Data storage control apparatus, data storage control system, data storage control method, and data storage control program
JP2016170453A
