CN111773666A - Order data processing method and device, storage medium and electronic device - Google Patents

Order data processing method and device, storage medium and electronic device Download PDF

Info

Publication number
CN111773666A
CN111773666A CN202010814772.4A CN202010814772A CN111773666A CN 111773666 A CN111773666 A CN 111773666A CN 202010814772 A CN202010814772 A CN 202010814772A CN 111773666 A CN111773666 A CN 111773666A
Authority
CN
China
Prior art keywords
server
order data
item
transaction
target database
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
CN202010814772.4A
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.)
Netease Hangzhou Network Co Ltd
Original Assignee
Netease Hangzhou Network 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 Netease Hangzhou Network Co Ltd filed Critical Netease Hangzhou Network Co Ltd
Priority to CN202010814772.4A priority Critical patent/CN111773666A/en
Publication of CN111773666A publication Critical patent/CN111773666A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • AHUMAN NECESSITIES
    • A63SPORTS; GAMES; AMUSEMENTS
    • A63FCARD, BOARD, OR ROULETTE GAMES; INDOOR GAMES USING SMALL MOVING PLAYING BODIES; VIDEO GAMES; GAMES NOT OTHERWISE PROVIDED FOR
    • A63F13/00Video games, i.e. games using an electronically generated display having two or more dimensions
    • A63F13/30Interconnection arrangements between game servers and game devices; Interconnection arrangements between game devices; Interconnection arrangements between game servers
    • A63F13/35Details of game servers
    • AHUMAN NECESSITIES
    • A63SPORTS; GAMES; AMUSEMENTS
    • A63FCARD, BOARD, OR ROULETTE GAMES; INDOOR GAMES USING SMALL MOVING PLAYING BODIES; VIDEO GAMES; GAMES NOT OTHERWISE PROVIDED FOR
    • A63F13/00Video games, i.e. games using an electronically generated display having two or more dimensions
    • A63F13/70Game security or game management aspects
    • A63F13/79Game security or game management aspects involving player-related data, e.g. identities, accounts, preferences or play histories
    • AHUMAN NECESSITIES
    • A63SPORTS; GAMES; AMUSEMENTS
    • A63FCARD, BOARD, OR ROULETTE GAMES; INDOOR GAMES USING SMALL MOVING PLAYING BODIES; VIDEO GAMES; GAMES NOT OTHERWISE PROVIDED FOR
    • A63F13/00Video games, i.e. games using an electronically generated display having two or more dimensions
    • A63F13/85Providing additional services to players
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/903Querying

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Theoretical Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • General Business, Economics & Management (AREA)
  • Computational Linguistics (AREA)
  • Business, Economics & Management (AREA)
  • Data Mining & Analysis (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Security & Cryptography (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The invention discloses a processing method and device of order data, a storage medium and an electronic device. The method comprises the following steps: the method comprises the steps that a first server responds to a first query request sent by a first client side, and first order data of a first article are queried in a target database, wherein the target database is used for storing order data of a plurality of articles, and each article belongs to at least one server; the method comprises the steps that a first server responds to a first transaction request sent by a first client, and first address information of a second server is obtained from first order data, wherein a first article belongs to the second server; and the first server sends a second transaction request to the second server based on the first address information, wherein the second transaction request is used for requesting the second server to perform transaction operation on the first item. By the method and the device, the effect of improving the efficiency of processing the order data is achieved.

Description

Order data processing method and device, storage medium and electronic device
Technical Field
The invention relates to the field of computers, in particular to a method and a device for processing order data, a storage medium and an electronic device.
Background
In the current online game, a user can trade virtual articles through a server, but order data of the articles are loaded into a corresponding server memory, then the user only addresses the current user region according to the ID of the region where the user is located in the game world as an addressing ID, and matching is performed through a trading queue in the corresponding server by looking up the memory of the corresponding server. The servers are deployed according to areas, and corresponding servers are different in different areas.
Therefore, the server can only check the order data of the local article of the server in a limited way, and then only can carry out trading operation on the order data, but cannot check the order data of the article of other servers and cannot trade the article of other servers, so that the technical problem that the efficiency of processing the order data is low exists
Aiming at the technical problem of low efficiency of processing order data in the prior art, no effective solution is provided at present.
Disclosure of Invention
The invention mainly aims to provide a method, a device, a storage medium and an electronic device for processing order data, which solve the technical problem of low efficiency of processing at least the order data.
In order to achieve the above object, according to an aspect of the present invention, there is provided a method of processing order data. The method can comprise the following steps: the method comprises the steps that a first server responds to a first query request sent by a first client side, and first order data of a first article are queried in a target database, wherein the target database is used for storing order data of a plurality of articles, and each article belongs to at least one server; the method comprises the steps that a first server responds to a first transaction request sent by a first client, and first address information of a second server is obtained from first order data, wherein a first article belongs to the second server; and the first server sends a second transaction request to the second server based on the first address information, wherein the second transaction request is used for requesting the second server to perform transaction operation on the first item.
Optionally, the first order data is loaded from the target database, stored in the second server, and used for the second server to perform a transaction operation on the first item.
Optionally, the target database is associated with a server to which the plurality of items belong.
Optionally, the first server, in response to the first query request, queries the target database for first order data of the first item, including: the first server acquires the identification of the first item from the first query request; the first server queries the first order data from the target database based on the identification of the first item.
Optionally, the first server queries the first order data from the target database according to the identifier of the first item, including: the first server inquires multiple pieces of order data from the target database according to the identification of the first article, wherein the first article belongs to the server indicated by the address information in each piece of order data; the first server screens at least one effective order data from the multiple order data; the first server determines first order data from the at least one valid order data.
Optionally, the determining, by the first server, the first order data from the at least one valid order data includes: the first server sends at least one piece of valid order data to the first client; the first server acquires first order data sent by a first client, wherein the first order data is selected from at least one piece of valid order data by the first client.
Optionally, the first server screens at least one valid order data from the plurality of order data, including: the first server determines the order data which is not used for transaction operation and is not expired from the multiple pieces of order data as valid order data.
Optionally, the responding, by the first server, to the first query request sent by the first client includes: and the first server responds to the first query request under the condition that the number of times that the first client sends the first query request is lower than the target number of times.
Optionally, the method further comprises: the first server responds to a third transaction request and carries out transaction operation on a second article, wherein the second article belongs to the first server, the third transaction request is sent by the third server based on second address information of the first server, second order data comprise the second address information, and the second order data are obtained by the third server through inquiring in a target database in response to a second inquiry request sent by a second client.
Optionally, the first server performs a transaction operation on the second item corresponding to the second order data, including: and the first server inserts second order data into the transaction queue so as to perform transaction operation on the second article.
In order to achieve the above object, according to another aspect of the present invention, there is also provided an order data processing apparatus. The apparatus may include: the query unit is used for enabling the first server to respond to a first query request sent by the first client side and query first order data of a first item in a target database, wherein the target database is used for storing the order data of a plurality of items, and each item belongs to at least one server; the acquisition unit is used for enabling the first server to respond to a first transaction request sent by the first client and acquire first address information of the second server from the first order data, wherein the first item belongs to the second server; and the sending unit is used for enabling the first server to send a second transaction request to the second server based on the first address information, wherein the second transaction request is used for requesting the second server to perform transaction operation on the first article.
In order to achieve the above object, according to another aspect of the present invention, there is provided a storage medium. The storage medium stores a computer program, wherein when the computer program is executed by the processor, the apparatus where the storage medium is located is controlled to execute the processing method of the order data according to the embodiment of the present invention.
In order to achieve the above object, according to another aspect of the present invention, an electronic device is provided. The electronic device comprises a memory and a processor, and is characterized in that the memory stores a computer program, and the processor is configured to run the computer program to execute the order data processing method of the embodiment of the invention.
According to the order data processing method, a first server responds to a first query request sent by a first client side, and first order data of a first article are queried in a target database, wherein the target database is used for storing the order data of a plurality of articles, and each article belongs to at least one server; the method comprises the steps that a first server responds to a first transaction request sent by a first client, and first address information of a second server is obtained from first order data, wherein a first article belongs to the second server; and the first server sends a second transaction request to the second server based on the first address information, wherein the second transaction request is used for requesting the second server to perform transaction operation on the first item. That is to say, the transaction operation of each item is deployed to the server to which the item belongs, the corresponding server can be accessed by addressing the address information in the order data of the item, and then the transaction operation is performed on the accessed server, so that the order data is visible across the servers, and the cross-server transaction of the item corresponding to the order data can be realized across the servers.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this application, illustrate embodiments of the invention and, together with the description, serve to explain the invention and not to limit the invention. In the drawings:
fig. 1 is a block diagram of a hardware structure of a mobile terminal of a method for processing order data according to an embodiment of the present invention;
FIG. 2 is a flow chart of a method of processing order data according to an embodiment of the invention;
FIG. 3 is a schematic illustration of local order data viewing and execution trading operations within various galaxy according to one of the related art;
FIG. 4 is a schematic diagram of order data processing in a game according to an embodiment of the invention; and
fig. 5 is a schematic diagram of an order data processing apparatus according to an embodiment of the present invention.
Detailed Description
It should be noted that the embodiments and features of the embodiments in the present application may be combined with each other without conflict. The present invention will be described in detail below with reference to the embodiments with reference to the attached drawings.
In order to make the technical solutions better understood by those skilled in the art, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are only partial embodiments of the present application, but not all embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
It should be noted that the terms "first," "second," and the like in the description and claims of this application and in the drawings described above are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It should be understood that the data so used may be interchanged under appropriate circumstances such that embodiments of the application described herein may be used. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed, but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
The method provided by the embodiment of the application can be executed in a mobile terminal, a computer terminal or a similar operation device. Taking the example of being operated on a mobile terminal, fig. 1 is a hardware structure block diagram of the mobile terminal of a method for processing order data according to an embodiment of the present invention. As shown in fig. 1, the mobile terminal may include one or more (only one shown in fig. 1) processors 102 (the processor 102 may include, but is not limited to, a processing device such as a microprocessor MCU or a programmable logic device FPGA) and a memory 104 for storing data, and optionally may also include a transmission device 106 for communication functions and an input-output device 108. It will be understood by those skilled in the art that the structure shown in fig. 1 is only an illustration, and does not limit the structure of the mobile terminal. For example, the mobile terminal may also include more or fewer components than shown in FIG. 1, or have a different configuration than shown in FIG. 1.
The memory 104 can be used for storing computer programs, for example, software programs and modules of application software, such as a computer program corresponding to a data processing method in the embodiment of the present invention, and the processor 102 executes various functional applications and data processing by running the computer programs stored in the memory 104, so as to implement the above-mentioned method. The memory 104 may include high speed random access memory, and may also include non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some examples, the memory 104 may further include memory located remotely from the processor 102, which may be connected to the mobile terminal over a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
The transmission device 106 is used to receive or transmit data via a network. Specific examples of the network described above may include a wireless network provided by a communication provider of the mobile terminal. In one example, the transmission device 106 includes a Network adapter (NIC) that can be connected to other Network devices through a base station to communicate with the internet. In one example, the transmission device 106 may be a Radio Frequency (RF) module, which is used to communicate with the internet in a wireless manner.
In the embodiment, a method for processing order data running on the mobile terminal is provided. The technical scheme is suitable for the network game which divides the game world into a plurality of areas, each area is provided with a corresponding server, and in the network game, the players can trade virtual articles. The following description will be given by taking an empty sandbox game as an example. In the space sandbox game, the whole universe is divided into a plurality of galaxies, and each galaxies is provided with a corresponding server, namely a galaxies server.
Fig. 2 is a flowchart of a method for processing order data according to an embodiment of the present invention. As shown in fig. 2, the method may include the steps of:
step S202, the first server responds to the first query request sent by the first client, and queries the first order data of the first item in the target database.
In the technical solution provided by step S202 of the present invention, the target database is used for storing order data (order information) of a plurality of items, and each item belongs to at least one server.
In this embodiment, the first server, that is, the galaxy server, may be a galaxy server in a space sandbox game, and is deployed according to galaxy, which may also be referred to as a market server. The first client of this embodiment is also the client used by the user, wherein the user may be called a player, and the first server may be a server of the galaxy where the first client is located.
In this embodiment, the first client sends a first query request to the first server, the first query request requesting to view the first order data for the first item, i.e. to access the first order data. The first server, upon receiving the first query request, may initiate a paging query to the target database in response to the first query request, and query the target database for the first order data of the first item. The paging query is initiated to the target database, so that the utilization rate of the target database can be improved.
In this embodiment, the target database stores order data of a plurality of items, the plurality of items including the first item, wherein the items may also be referred to as commodities, goods, and other objects that need to be traded, and are not limited specifically here. Each item belongs to at least one server, that is, an item is loaded on at least one server, and each item needs to perform a transaction operation on the server to which the item belongs, so as to complete transaction matching, wherein the server to which each item belongs may also be referred to as a matching server where the item is located.
In this embodiment, the order data is queried by the target database, so that all order data of the universe can be queried even if all order data are not loaded on one server.
Step S204, the first server responds to the first transaction request sent by the first client, and obtains the first address information of the second server from the first order data.
In the technical solution provided by step S202 of the present invention, after the first server responds to the first query request sent by the first client, and queries the first order data of the first item in the target database, the first server may respond to the first transaction request sent by the first client, and obtain the first address information of the second server from the first order data. Wherein the first item belongs to the second server.
In this embodiment, the first server may return the first order data of the first item queried from the target database to the client for display, so as to facilitate the user to view the first order data. The first client may then send a first transaction request to the first server in response to a confirmation operation of the user on the first client, where the first transaction request is used to request a transaction for the first item, that is, the user initiates a transaction action for the first item. After the first server receives the first transaction request, first address information may be obtained from the first order data of the first item, where the first address information may be used to indicate an address (ID) of a location (galaxy) where the first item is located, and the first address information has a corresponding second server, and the second server may be addressed through the first address information, that is, the embodiment may address the ID of the location where the first item is located to the second server as an addressing ID, where the first item belongs to the second server, and the second server may also be a galaxy server.
Step S206, the first server sends a second transaction request to the second server based on the first address information, where the second transaction request is used to request the second server to perform a transaction operation on the first item.
In the technical solution provided in step S206 of the present invention, after the first server responds to the first transaction request sent by the first client, and acquires the first address information of the second server from the first order data, the first server sends a second transaction request to the second server based on the first address information, where the second transaction request is used to request the second server to perform a transaction operation on the first item.
In this embodiment, the first server may address the second server based on the first address information, and then send the second transaction request to the second server, and since the first item belongs to the second server, the transaction operation may be performed on the first item on the second server, and may be to insert order data into a transaction queue in a memory of the second server, and wait for a matching operation, where the transaction queue may also be referred to as a transaction matching queue, so as to avoid performing the transaction operation on all items on a single-point server, and the problem of slow matching due to an excessively long transaction queue is solved.
In the related technology, all order data of each galaxy can be inserted into a memory of a server of a user from a database, then the user only addresses the galaxy of the current user according to the galaxy ID of the galaxy of the user as an addressing ID, the checking is performed by checking the memory value of the server of the user, and the transaction operation is also performed by matching a transaction queue in the server of the user, so that only the order data of the article of the current galaxy of the user can be checked and the transaction operation is performed on the article. That is, in the related art, only the memory of a single server can be used, the memory value is checked, the transaction queue is in the own star field and is stored in the memory of the server, each server is irrelevant, the access is performed through the star system ID of the star system where the user is located, and because the user can only be present at one position at the same time, both the order data query and the transaction operation can be performed only in the single star field. If order data of a universe star field and article transaction need to be realized, a user can only log in different galaxy servers by running the universe to see the order data of different star fields respectively, and the operation of running the universe only needs about 1 hour, which is very inconvenient.
However, in the present application, through the above steps S202 to S206, the first server responds to the first query request sent by the first client, and queries the first order data of the first item in the target database, where the target database is used to store order data of a plurality of items, and each item belongs to at least one server; the method comprises the steps that a first server responds to a first transaction request sent by a first client, and first address information of a second server is obtained from first order data, wherein a first article belongs to the second server; and the first server sends a second transaction request to the second server based on the first address information, wherein the second transaction request is used for requesting the second server to perform transaction operation on the first item. That is to say, the embodiment deploys the transaction operation of each item to the server to which the item belongs, addresses the item through the address information in the order data of the item, and can access the corresponding server, and then perform the transaction operation on the accessed server, so that the order data is visible across servers, and the item corresponding to the order data can be transacted across servers, and the transaction matching time is short, so that the embodiment is an implementation method capable of completing the transaction across servers, and is independent of which server the user is located, thereby solving the technical problem of low efficiency in processing the order data, and achieving the technical effect of improving the efficiency in processing the order data.
The above method of this embodiment is further described below.
As an alternative embodiment, the first order data is loaded from the target database and stored in the second server, and is used for the second server to perform a transaction operation on the first item.
In this embodiment, the first order data of the first item may be loaded from the target database, and then the first order data is stored in the memory of the second server, so that the first server addresses the second server based on the first address information in the first order data, and sends the second transaction request to the second server, so that the second server performs a transaction operation on the first item by using the first order data.
In this embodiment, transaction queues of users of multiple servers are collected on one market center transaction server and are respectively deployed on the multiple servers, the market center transaction server is not independently made, but the order data is loaded from the target database according to address information in the order data, for example, the order data is loaded from the database according to a galaxy ID carried by item information in the order data, and then the order data is placed in a server memory corresponding to the galaxy ID. Therefore, under the condition that the player initiates a trading action, the player can address the corresponding server according to the address information in the order data and complete the trading operation on the server, so that the pressure of trading the article is divided, and the problem of slow trading matching caused by overlong trading queue due to the trading operation of the article by the trading server in the market center is solved.
As an alternative embodiment, the target database is associated with a server to which a plurality of items belong.
In this embodiment, the target database may be connected to servers to which a plurality of items belong, for example, each server in the universe is connected to the same target database, so that when order data of a plurality of items are respectively deployed on corresponding servers, viewing the order data from the target data may greatly reduce traffic transmission, reduce load on the servers, and further improve throughput of the servers.
As an optional implementation manner, in step S202, the first server queries, in response to the first query request, the target database for first order data of the first item, including: the first server acquires the identification of the first item from the first query request; the first server queries the first order data from the target database based on the identification of the first item.
In this embodiment, when the first server queries the target database for the first order data of the first item in response to the first query request, the first server may initiate a paging query to the target database, and obtain the identifier of the first item, for example, the item ID, from the first query request, which may be a type identifier (type _ ID) of the item. After the first server obtains the identification of the first item, the corresponding first order data may be queried from the target database based on the identification of the first item.
As an optional implementation, the first server querying the target database for the first order data according to the identifier of the first item includes: the first server inquires multiple pieces of order data from the target database according to the identification of the first article, wherein the first article belongs to the server indicated by the address information in each piece of order data; the first server screens at least one effective order data from the multiple order data; the first server determines first order data from the at least one valid order data.
In this embodiment, the first server may query the order data of all galaxy where the first item is located from the target database according to the identifier of the first item, and may query multiple pieces of order data, where the first item belongs to the server of the galaxy indicated by the address information in each piece of order data. Optionally, to ensure that valid order data is used, the first server of this embodiment may screen at least one valid order data from the plurality of order data, and further determine the first order data from the at least one order data.
As an optional implementation manner, the determining, by the first server, the first order data from the at least one valid order data includes: the first server sends at least one piece of valid order data to the first client; the first server acquires first order data sent by a first client, wherein the first order data is selected from at least one piece of valid order data by the first client.
In this embodiment, the first server may return the screened at least one valid order data to the first client, and then display the at least one valid order data on the first client for the user to view, and the first client may select the first order data from the at least one valid order data in response to a selection operation triggered by the user.
As an optional implementation manner, the first server screens at least one valid order data from the plurality of order data, including: the first server determines the order data which is not used for transaction operation and is not expired from the multiple pieces of order data as valid order data.
In this embodiment, when the first server screens out at least one valid order data from the plurality of order data, the first server may first select, from the plurality of order data, order data that is not used for performing a trade operation and that is not expired, where the order data that is not used for performing a trade operation may refer to order data that is not trade-matched on the corresponding server, and the order data that is not expired may refer to order data that has not exceeded a specified lifetime. The embodiment may determine that order data that has not been used for performing a trading operation and has not expired from a plurality of pieces of order data is valid order data, that is, the first server of the embodiment, when accessing the order data to the database, may filter whether the item identifier and the order data are valid, and if the item identifier is determined, may access all the order data of the item in the target database, and filter out the order data that has not been matched and has not expired.
As an optional implementation manner, in step S202, the responding, by the first server, to the first query request sent by the first client includes: and the first server responds to the first query request under the condition that the number of times that the first client sends the first query request is lower than the target number of times.
In this embodiment, a limit (RPC) may be placed on the number of first query requests. Optionally, when the first client accesses the first server, the first client may first connect to a proxy server, where the proxy server may be a market server that manages at least one galaxy, and a correspondence between the proxy server and the market server is configured in advance. When the first client connects with the proxy server, a session (session) is generated, which includes a key (key) specific to the first client as a mark of the first client, when the session initiates a first query request to the proxy server, the time of initiating the first query request is recorded, and an access interval time and the number of accesses within the access interval time are configured in the access interface, for example, 20 times of accessing the interface through the first query request within 10 seconds, if the session accesses 21 times within 10 seconds, the first query request is not responded at 21 st time, the first client is prompted to request too frequently, and the first query request is attempted to be initiated after waiting for a period of time. Optionally, in this embodiment, after the access interval time elapses, the access times are cleared, and the first query request may be initiated in the next access interval time, so that the purpose of limiting the times of the first query request is achieved, and it is avoided that a large number of first query requests occupy the central processing unit to query the target database.
As an optional implementation, the method further comprises: the first server responds to a third transaction request and carries out transaction operation on a second article, wherein the second article belongs to the first server, the third transaction request is sent by the third server based on second address information of the first server, second order data comprise the second address information, and the second order data are obtained by the third server through inquiring in a target database in response to a second inquiry request sent by a second client.
In this embodiment, the first server has a second item thereon, which can be used for performing transaction operations on the second item. Optionally, the first server responds to a third transaction request sent by a third server, where the third server may be a server corresponding to other galaxy systems in the universe, and the third server may address the first server based on the second address information, and then sends the third transaction request to the first server. The second address information in this embodiment may be carried by second order data, and the second order data may be obtained by querying, in the target database, a third server in response to a second query request sent by a second client, where the third server corresponds to the second client, so that the first server in this embodiment may not only request to perform a transaction operation on articles in servers of other galaxies, but also receive a transaction request sent by servers of other galaxies to perform a transaction on its own second article, thereby improving the efficiency of processing order data.
As an optional implementation manner, the first server performs a transaction operation on the second item corresponding to the second order data, including: and the first server inserts second order data into the transaction queue so as to perform transaction operation on the second article.
In this embodiment, a transaction queue is disposed on the first server, and the transaction queue may include order data in the memory of the first server. Optionally, the embodiment inserts the second order data in the transaction queue and waits for a transaction match to complete the transaction operation for the second item.
The embodiment can not only complete the cross-server matching of the order data of the whole server, but also enable the player to see the order data of the whole server, and can respectively deploy all the order data of the market center server to a plurality of servers, thereby reducing the pressure of the market center server and reducing the matching time in a large amount of transaction. According to the embodiment, the correct matching server can be found according to the position of the star system where the article is located, and transaction matching is completed on the matching server for the article. In addition, all order data of the market center server are respectively deployed on the plurality of servers, so that the order data of the articles are selected to be checked from the target database at the moment, the flow transmission is greatly reduced, the load on the servers is reduced, the throughput of the servers is improved, the target database query is a paging query, the utilization rate of the target database is also improved, and the efficiency of processing the order data is improved.
The above-described method of embodiments of the present invention is further illustrated below in conjunction with the preferred embodiments.
FIG. 3 is a schematic diagram of local order data viewing and execution trading operations within various galaxy according to one of the related art. As shown in fig. 3, the servers are deployed according to galaxy, and the servers belonging to different galaxy are different, for example, galaxy one server and galaxy two server … … galaxy N server, wherein the galaxy one server corresponds to the player where the galaxy one is located, the transaction queue only contains the order data in the memory of the galaxy one server, the order data is loaded to the memory, and the player can only access the memory of the galaxy one server through the memory of the galaxy one server; the two star system servers correspond to players of the two star systems, the trading queues only comprise order data in memories of the two star systems servers, the order data are loaded into the memories, and the players can only access the memories of the two star systems through the memories of the two star systems; the galaxy N server corresponds to the player of the galaxy N, the transaction queue only comprises order data in the memory of the galaxy N server, the order data is loaded into the memory, and the player can only access the memory of the galaxy two servers through the memory of the galaxy N server.
In the scheme, all order data of each galaxy are inserted into a memory of a server from a database, then a player can only address the galaxy where the current player is located according to the galaxy ID of the galaxy where the player is located as an addressing ID, the checking is performed by checking the memory value of the server, and the transaction operation is performed by matching a transaction queue in the server. Therefore, only the items of the current galaxy where the player is located can be transacted, for example, the player in the a star field can only see the order data of the a star field, and only the items corresponding to the order data of the a star field can be transacted. That is, the above method can be performed only on the memory of a single server, the checking is to check the memory value, the transaction queue is in the own star domain and is stored in the memory of the server, each server is irrelevant, and the access is performed through the position of the player. Because the player can only appear in one position at the same time, the inquiry of order data and the transaction operation of the object can only be carried out in a single star field, namely only the memory access and calculation of the player are managed, and the method has limitation, so that the player can only access the order in the star field and the transaction operation of the order in the star field.
Although the player trades the articles freely, the articles are loaded in the memory of the server, so that the market is limited to see only local articles, but the requirement of checking order data of articles in the universe is possible, so that the order data of different star fields can be respectively seen only by running the universe and logging in different galaxy servers, and the operation of running the universe only needs about 1 hour, which is very inconvenient.
If a market-centric trading server is used as the particular market server, where both player viewing and trading operations are performed, access replies are quick, but when players are orders of magnitude large, the queue of orders for trading that needs to wait for a match can be long, and the matching time can be long accordingly.
As can be seen from the above, the related art has not achieved that not only can the order data of the article be made visible across servers, but also cross-server trading can be achieved, and the matching time length cannot be made long.
In order to solve the above problems, the embodiments of the present application may collect the trade queues of the players with 200 servers from one market center trade server, deploy the trade queues to the 200 servers respectively, do not serve as the market center trade server separately, the order data is loaded from the target database according to the address information in the order data, for example, loading the order data from the target database through the star ID contained in the article information contained in the order data, then the order data is put into the memory of the server corresponding to the star ID, the player initiates a transaction, addressing to the server of the article according to the address information in the order data, completing the transaction on the server, therefore, the pressure is shared, and the problem of slow matching caused by overlong transaction queues of the market center transaction server is solved.
In addition, the embodiment changes the action of the player viewing the order from the memory into the action of viewing the order from the target database. Since the user requests data based on the ID of the specific item, the filtering condition may be whether the item ID and the order data are valid when accessing the order data to the target database in this embodiment. If the type _ id of an item is determined, all order data of the item can be accessed in the target database, and unmatched order data which are not expired are screened out from all the order data, so that the aim of seeing the order data of the universe can be fulfilled without loading all the order data to a server.
Fig. 4 is a schematic diagram of order data processing in a game according to an embodiment of the present invention. As shown in fig. 4, the galaxy-server corresponds to the player of the galaxy-server, the transaction queue only contains the order data in the memory of the galaxy-server, and the player can view the order data of the information of the universe from the target database; the galaxy two server corresponds to the player of the galaxy two server, the trade queue only comprises order data in the memory of the galaxy two server, the player can check the order data … … of the information of the universe from the target database, the galaxy N server corresponds to the player of the galaxy one server, the trade queue only comprises the order data in the memory of the galaxy N server, and the player can check the order data of the information of the universe from the target database.
In the embodiment, the galaxy first server can be addressed to the galaxy second server through the galaxy ID where the article is located in the order data inquired from the target database so as to carry out transaction operation on the article on the galaxy second server, and the galaxy second server can also be addressed to the galaxy first server through the galaxy ID where the article is located in the order data inquired from the target database so as to carry out transaction operation on the article on the galaxy first server; the galaxy second server can be addressed to the galaxy N server through the galaxy ID where the article is located in the order data inquired from the target database so as to perform transaction operation on the article on the galaxy N server, and the galaxy N server can also be addressed to the galaxy second server through the galaxy ID where the article is located in the order data inquired from the target database so as to perform transaction operation on the article on the galaxy second server; the star system server can be addressed to the star system N server through the star system ID where the article is located in the order data inquired from the target database so as to conduct transaction operation on the article on the star system N server, and the star system N server can also be addressed to the star system server through the star system ID where the article is located in the order data inquired from the target database so as to conduct transaction operation on the article on the star system server.
In this embodiment, since the transactions in the game are data interactions, from the source, in order to meet the transaction requirements, data needs to be acquired first, and when a player corresponds to hundreds of servers, data interworking needs to be completed first in order to complete interworking between servers. Because many servers are deployed in online network games, if all the servers are loaded on one server for obtaining, the method causes the problem that the matching queue is too long, so that the server is over stressed. In the embodiment, the method shown in fig. 4 changes the addressing of the servers from the ID addressing of the market center trading server to addressing according to the galaxy ID where the article is located in the order data, and determines the corresponding server, so that the pressure is distributed to hundreds of servers from one market center trading server, and the efficiency of processing the order data is improved by hundreds of times.
Alternatively, in this embodiment, when the client accesses the order data, it may be a query request for querying the order data by initiating a query to the server once. Optionally, in this embodiment, the query request of the client is first sent to the corresponding galaxy server, then the galaxy server initiates a paging query to the target database, and according to the item ID, the target database may be queried for order data of the item in all galaxy systems, and after obtaining the order data, the order data is returned to the client for viewing. The embodiment can also make RPC access limitation on the server, thereby avoiding a large number of first query requests occupying a central processor to query the target database.
The embodiment can solve the problems that the order data of the whole server can be matched across servers, players can inquire the order data of the whole server, the pressure of the single-point server is greatly reduced, and the matching time of 2 hours is reduced to millisecond level within the transaction amount of more than 20 million persons; finding a correct server according to the position of the article, finding the order on the server, and completing transaction matching on the server where the article is located; order data are respectively deployed on more than 200 servers, at this time, the flow transmission can be greatly reduced by selecting to check from the target database, the load on the servers is reduced, the throughput of the servers is improved, the target database query is paging query, the utilization rate of the target database is also improved, the technical problem that the processing efficiency of the order data is low is solved, and the technical effect of improving the processing efficiency of the order data is achieved.
The embodiment of the invention also provides a processing device of the order data. It should be noted that the order data processing device of this embodiment can be used to execute the order data processing method shown in fig. 2 according to the embodiment of the present invention.
Fig. 5 is a schematic diagram of an order data processing apparatus according to an embodiment of the present invention. As shown in fig. 5, the order data processing device 50 includes: an inquiring unit 51, an acquiring unit 52 and a sending unit 53.
The query unit 51 is configured to enable the first server to query, in response to a first query request sent by the first client, first order data of a first item in a target database, where the target database is used to store order data of a plurality of items, and each item belongs to at least one server.
The obtaining unit 52 is configured to enable the first server to obtain, from the first order data, the first address information of the second server in response to the first transaction request sent by the first client, where the first item belongs to the second server.
The sending unit 53 is configured to enable the first server to send a second transaction request to the second server based on the first address information, where the second transaction request is used to request the second server to perform a transaction operation on the first item.
The order data processing device of the embodiment deploys the transaction operation of each item to the server to which the item belongs, addresses the item through the address information in the order data of the item, can access the corresponding server, and then performs the transaction operation on the accessed server, so that the order data is visible across the servers, the item corresponding to the order data can be transacted across the servers, and the transaction matching time is short, therefore, the implementation method of the transaction can be completed across the servers, is irrelevant to which server the user is located, solves the technical problem of low processing efficiency of the order data, and achieves the technical effect of improving the processing efficiency of the order data.
The embodiment of the invention also provides a storage medium, wherein a computer program is stored in the storage medium, and when the computer program is executed by a processor, the device where the storage medium is located is controlled to execute the method in the processing device of the order data of the embodiment of the invention.
Optionally, in this embodiment, the storage medium may include, but is not limited to: various media capable of storing computer programs, such as a usb disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a removable hard disk, a magnetic disk, or an optical disk.
Embodiments of the present invention also provide an electronic device comprising a memory having a computer program stored therein and a processor arranged to run the computer program to perform a method in a processing device of order data of an embodiment of the present invention.
Optionally, the electronic apparatus may further include a transmission device and an input/output device, wherein the transmission device is connected to the processor, and the input/output device is connected to the processor.
It will be apparent to those skilled in the art that the modules or steps of the present invention described above may be implemented by a general purpose computing device, they may be centralized on a single computing device or distributed across a network of multiple computing devices, and alternatively, they may be implemented by program code executable by a computing device, such that they may be stored in a storage device and executed by a computing device, and in some cases, the steps shown or described may be performed in an order different than that described herein, or they may be separately fabricated into individual integrated circuit modules, or multiple ones of them may be fabricated into a single integrated circuit module. Thus, the present invention is not limited to any specific combination of hardware and software.
The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention, and various modifications and changes may be made by those skilled in the art. Any modification, equivalent replacement, or improvement made within the principle of the present invention should be included in the protection scope of the present invention.

Claims (13)

1. A method for processing order data is characterized by comprising the following steps:
the method comprises the steps that a first server responds to a first query request sent by a first client side, and first order data of a first item are queried in a target database, wherein the target database is used for storing order data of a plurality of items, and each item belongs to at least one server;
the first server responds to a first transaction request sent by the first client, and first address information of a second server is obtained from the first order data, wherein the first item belongs to the second server;
and the first server sends a second transaction request to the second server based on the first address information, wherein the second transaction request is used for requesting the second server to perform transaction operation on the first item.
2. The method of claim 1, wherein the first order data is loaded from the target database and stored to the second server and used to cause the second server to perform a transaction operation on the first item.
3. The method of claim 1, wherein the target database is associated with a server to which the plurality of items belong.
4. The method of claim 1, wherein the first server queries a target database for first order data for the first item in response to the first query request, comprising:
the first server obtains the identification of the first item from the first query request;
the first server queries the first order data from the target database according to the identification of the first item.
5. The method of claim 4, wherein the first server querying the target database for the first order data based on the identity of the first item comprises:
the first server inquires a plurality of pieces of order data from the target database according to the identification of the first article, wherein the first article belongs to a server indicated by address information in each piece of order data;
the first server screens at least one piece of valid order data from the plurality of pieces of order data;
the first server determines the first order data from the at least one valid order data.
6. The method of claim 5, wherein the first server determining the first order data from the at least one valid order data comprises:
the first server sends the at least one piece of valid order data to the first client;
the first server acquires first order data sent by the first client, wherein the first order data is selected from the at least one piece of valid order data by the first client.
7. The method of claim 5, wherein the first server sifts out at least one valid order data from the plurality of order data, comprising:
and the first server determines the order data which is not used for transaction operation and is not expired in the multiple pieces of order data as the valid order data.
8. The method according to any one of claims 1 to 7, wherein the responding, by the first server, to the first query request sent by the first client comprises:
and the first server responds to the first query request under the condition that the number of times that the first client sends the first query request is lower than a target number of times.
9. The method according to any one of claims 1 to 7, further comprising:
the first server responds to a third transaction request and carries out transaction operation on a second article, wherein the second article belongs to the first server, the third transaction request is sent by a third server based on second address information of the first server, second order data comprise the second address information, and the second order data are obtained by the third server through inquiring in the target database in response to a second inquiry request sent by a second client.
10. The method of claim 9, wherein the first server performs a transaction operation on a second item corresponding to the second order data, comprising:
and the first server inserts the second order data into a transaction queue so as to perform transaction operation on the second article.
11. An order data processing device is characterized in that,
the query unit is used for enabling the first server to respond to a first query request sent by a first client side and query first order data of a first item in a target database, wherein the target database is used for storing order data of a plurality of items, and each item belongs to at least one server;
an obtaining unit, configured to enable the first server to obtain, from the first order data, first address information of a second server in response to a first transaction request sent by the first client, where the first item belongs to the second server;
a sending unit, configured to enable the first server to send a second transaction request to the second server based on the first address information, where the second transaction request is used to request the second server to perform a transaction operation on the first item.
12. A storage medium having a computer program stored thereon, wherein the computer program, when executed by a processor, controls an apparatus in which the storage medium is located to perform the method of any one of claims 1 to 10.
13. An electronic device comprising a memory and a processor, wherein the memory has stored therein a computer program, and wherein the processor is arranged to execute the computer program to perform the method of any of claims 1 to 10.
CN202010814772.4A 2020-08-13 2020-08-13 Order data processing method and device, storage medium and electronic device Pending CN111773666A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010814772.4A CN111773666A (en) 2020-08-13 2020-08-13 Order data processing method and device, storage medium and electronic device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010814772.4A CN111773666A (en) 2020-08-13 2020-08-13 Order data processing method and device, storage medium and electronic device

Publications (1)

Publication Number Publication Date
CN111773666A true CN111773666A (en) 2020-10-16

Family

ID=72762027

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010814772.4A Pending CN111773666A (en) 2020-08-13 2020-08-13 Order data processing method and device, storage medium and electronic device

Country Status (1)

Country Link
CN (1) CN111773666A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112546618A (en) * 2020-12-09 2021-03-26 杭州电魂网络科技股份有限公司 Cross-regional-service prop trading method, system, electronic equipment and medium
CN113762856A (en) * 2020-11-24 2021-12-07 北京京东乾石科技有限公司 Warehouse-out management method and device

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20040137900A1 (en) * 2003-01-13 2004-07-15 Tomi Varonen Method and system for locating a mobile terminal
CN101231722A (en) * 2007-01-22 2008-07-30 阿里巴巴公司 System and method of network payment
CN103854191A (en) * 2012-12-06 2014-06-11 腾讯科技(深圳)有限公司 Online application virtual resource automatic transaction method and device
CN103854218A (en) * 2012-12-06 2014-06-11 腾讯科技(深圳)有限公司 Online application virtual resource transfer method, device and system
CN105469296A (en) * 2015-11-18 2016-04-06 网易(杭州)网络有限公司 Method, device and system for game item transaction
CN109173266A (en) * 2018-11-12 2019-01-11 网易(杭州)网络有限公司 Processing method, device, processor and the server of fictitious assets across game
KR20190130377A (en) * 2018-05-14 2019-11-22 엔에이치엔 주식회사 Network server mediating game item transaction between user terminals and method of operating thereof
CN111080275A (en) * 2019-09-10 2020-04-28 腾讯科技(深圳)有限公司 Cross-region resource transfer method, device, equipment and storage medium

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20040137900A1 (en) * 2003-01-13 2004-07-15 Tomi Varonen Method and system for locating a mobile terminal
CN101231722A (en) * 2007-01-22 2008-07-30 阿里巴巴公司 System and method of network payment
CN103854191A (en) * 2012-12-06 2014-06-11 腾讯科技(深圳)有限公司 Online application virtual resource automatic transaction method and device
CN103854218A (en) * 2012-12-06 2014-06-11 腾讯科技(深圳)有限公司 Online application virtual resource transfer method, device and system
CN105469296A (en) * 2015-11-18 2016-04-06 网易(杭州)网络有限公司 Method, device and system for game item transaction
KR20190130377A (en) * 2018-05-14 2019-11-22 엔에이치엔 주식회사 Network server mediating game item transaction between user terminals and method of operating thereof
CN109173266A (en) * 2018-11-12 2019-01-11 网易(杭州)网络有限公司 Processing method, device, processor and the server of fictitious assets across game
CN111080275A (en) * 2019-09-10 2020-04-28 腾讯科技(深圳)有限公司 Cross-region resource transfer method, device, equipment and storage medium

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113762856A (en) * 2020-11-24 2021-12-07 北京京东乾石科技有限公司 Warehouse-out management method and device
CN112546618A (en) * 2020-12-09 2021-03-26 杭州电魂网络科技股份有限公司 Cross-regional-service prop trading method, system, electronic equipment and medium

Similar Documents

Publication Publication Date Title
CN108234505B (en) Account login method and system
US20220343398A1 (en) Order management methods, system, terminal and electronic device based on multi-person ordering
CN112434996A (en) Cabinet grid distribution method, device and system of intelligent cabinet
CN111639279B (en) Graphic code generation method, target page loading method and device
CN111291079A (en) Data query method and device
CN111773666A (en) Order data processing method and device, storage medium and electronic device
JP2002092366A (en) Cpu time-division purchase-and-sale method and control server in cpu time-division purchase-and-sale system
CN107230116B (en) Transaction request processing method and device and distributed system
CN109885546A (en) User behaviors log storage method, device and electronic equipment
CN110737857A (en) back-end paging acceleration method, system, terminal and storage medium
CN104618388B (en) Fast registration login method and corresponding resetting server, information server
CN110740155B (en) Request processing method and device in distributed system
CN109767285A (en) Method for pushing, the apparatus and system of store information
CN111311360B (en) Resource refund method and device, storage medium and electronic device
CN108925145A (en) Equipment supply
CN111767481B (en) Access processing method, device, equipment and storage medium
CN112598271A (en) Product sale resource management and control method, system, device and storage medium
CN108289086A (en) Request processing method and device, server
CN109213924B (en) Popularization task allocation method and device and computer equipment
CN107277088B (en) High-concurrency service request processing system and method
CN115237960A (en) Information pushing method and device, storage medium and electronic equipment
CN109447293B (en) Product data processing method and device
CN114157720A (en) Method, device, electronic equipment and medium for processing service request
CN108234229A (en) A kind of network speed measuring method and device
CN112257971A (en) Task processing method, device, equipment and storage medium

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