Data processing method, device, equipment, program product and storage medium

HK40091454BActive Publication Date: 2026-07-17TENCENT TECHNOLOGY (SHENZHEN) CO LTD

Patent Information

Authority / Receiving Office
HK · HK
Patent Type
Patents
Current Assignee / Owner
TENCENT TECHNOLOGY (SHENZHEN) CO LTD
Filing Date
2023-09-22
Publication Date
2026-07-17

AI Technical Summary

Technical Problem

In business scenarios with frequent cross-regional service requests, existing technologies are insufficient to effectively improve service response speed. Increasing network bandwidth or optimizing hardware devices have load limits and cannot effectively improve service response speed.

Method used

By deploying cluster systems in multiple regions, access switches are used to receive service requests, query the region to which the business account belongs, and route the request to the corresponding cluster for processing. This includes queries to local caches, routing storage database clusters, and root nodes, ensuring that service requests are processed within the cluster in the region to which they belong, thus reducing cross-regional data transmission.

Benefits of technology

It improves the response speed of service requests by reducing the number of cross-regional data transmissions through proximity access and local processing, thereby improving service response efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 00000000_0000_ABST
    Figure 00000000_0000_ABST
Patent Text Reader

Abstract

The application provides a data processing method and device of a cluster system, electronic equipment, a computer program product and a computer readable storage medium; the cluster system comprises a routing center, a plurality of clusters deployed in a one-to-one correspondence in a plurality of regions, and a plurality of access switches deployed in a one-to-one correspondence in the plurality of regions; the method comprises: receiving a service request of a business account through an access switch, wherein the source position of the service request is within the scope of an access region corresponding to the access switch, and the access region is one of the plurality of regions; querying the home region of the business account through the access switch and the routing center, wherein the home region is one of the plurality of regions; when the home region and the access region are different, routing the service request to the cluster corresponding to the home region in the plurality of clusters through the access switch, and performing response processing on the service request by the cluster corresponding to the home region. Through the application, the response speed of the service request can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the fields of cloud technology and computer technology, and in particular to a data processing method, apparatus, electronic device, computer program product and computer-readable storage medium. Background Technology

[0002] Cloud technology refers to a hosting technology that unifies a series of resources such as hardware, software, and networks within a wide area network or local area network to achieve data computing, storage, processing, and sharing.

[0003] With the popularization and advancement of computer and information technologies, various user-facing services are gradually shifting from offline to online through various clients. This places increasingly higher demands on the backend service capabilities of clients. In particular, in business scenarios with frequent cross-regional service requests, a large number of cross-city service requests will occur, which will increase network latency and lead to service response delays.

[0004] Related technologies may improve service response speed by increasing network bandwidth or optimizing hardware, but this approach has a clear load limit and still cannot maintain a high service response speed in business scenarios with frequent cross-regional service requests. Summary of the Invention

[0005] This application provides a data processing method, apparatus, electronic device, computer program product, and computer-readable storage medium for a cluster system, which can improve the response speed of service requests.

[0006] The technical solution of this application embodiment is implemented as follows:

[0007] This application provides a data processing method for a cluster system, the cluster system including a routing center, multiple clusters deployed one-to-one in multiple regions, and multiple access switches deployed one-to-one in the multiple regions; including:

[0008] The access switch receives service requests from service accounts, wherein the source location of the service request is within the jurisdiction of the access region corresponding to the access switch, and the access region is one of the plurality of regions;

[0009] The access switch queries the routing center to determine the region to which the service account belongs, wherein the region to which the account belongs is one of the plurality of regions;

[0010] When the queried home region is different from the access region, the service request is routed to the cluster corresponding to the home region among the multiple clusters through the access switch, so that the cluster corresponding to the home region can perform response processing for the service request.

[0011] This application provides a data processing apparatus for a cluster system. The cluster system includes a routing center, multiple clusters deployed one-to-one in multiple regions, and multiple access switches deployed one-to-one in the multiple regions. The apparatus includes:

[0012] The receiving module is used to receive service requests from service accounts through the access switch, wherein the source location of the service request is within the jurisdiction of the access region corresponding to the access switch, and the access region is one of the plurality of regions;

[0013] The query module is used to query the routing center through the access switch for the region to which the service account belongs, wherein the region to which the account belongs is one of the plurality of regions;

[0014] The routing module is used to route the service request to the cluster corresponding to the home region among the plurality of clusters through the access switch when the queried home region is different from the access region, so that the cluster corresponding to the home region can perform response processing for the service request.

[0015] In the above scheme, the routing module is further configured to: when the service account's region of origin is the same as the access region, use the access switch to call the routing control tool to route the service request to the cluster in the plurality of clusters corresponding to the access region.

[0016] In the above scheme, the routing center includes a root node, a routing storage database cluster corresponding to each region, and a local cache corresponding to each region; the query module is further configured to: invoke the routing control tool through the access switch to perform any one of the following processes: query the local cache corresponding to the access region to determine the region to which the service account belongs; when the local cache of the routing center does not find the region to which the service account belongs, query the routing storage database cluster corresponding to the access region to determine the region to which the service account belongs; when neither the local cache nor the routing storage database cluster corresponding to the access region finds the region to which the service account belongs, query the root node of the routing center to determine the region to which the service account belongs.

[0017] In the above scheme, the local cache corresponding to the access region is distributed in multiple first storage devices. The query module is further configured to: perform hash processing on the business account to obtain a first hash processing result corresponding to the business account; determine a target first storage device corresponding to the first hash processing result from the multiple first storage devices; and query the region to which the business account belongs in the target first storage device.

[0018] In the above scheme, the query module is further configured to: call the routing control tool through the access switch to perform the following processing: when the region to which the service account belongs is not found at the root node of the routing center, determine that the service request is the first service request of the service account, and determine the access region of the service request as the region to which the service account belongs.

[0019] In the above scheme, the query module is further configured to: when the service request is the first service request of the business account, invoke the routing control tool through the access switch to perform the following processing: write the regional information representing the home region into the root node of the routing center, the routing storage database cluster corresponding to the access region, and the local cache corresponding to the access region; broadcast the regional information to the routing storage database clusters of other regions and other local caches of the routing center; wherein, the other regions are regions other than the access region among the multiple regions, and the other local caches are local caches in the routing center other than the local cache corresponding to the access region.

[0020] In the above scheme, the query module is further configured to: perform query locking processing on the root node of the routing center; when the root node of the routing center is in a query locked state, write the regional information representing the home region into the root node of the routing center; wherein, the root node of the routing center being in a query locked state indicates that the root node of the routing center cannot be subject to query operations.

[0021] In the above scheme, the local cache corresponding to the access region is distributed across multiple first storage devices. The query module is further configured to: perform hash processing on the service account to obtain a first hash processing result corresponding to the service account; perform hash processing on the machine identifier of each of the multiple first storage devices to obtain a second hash processing result corresponding to each of the first storage devices; determine the first storage device corresponding to the second hash processing result that is adjacent to the first hash processing result and is greater than the first hash processing result as the target first storage device corresponding to the service account; and write the region information representing the home region into the local cache of the target first storage device.

[0022] In the above scheme, the regional information representing the access region is the default routing information in the routing control tool. The routing module is further configured to: call the routing control tool through the access switch to perform the following processing: replace the default routing information in the routing control tool with the regional information representing the home region to obtain the routing information of the service request; use the routing information as the header information corresponding to the service request; and route the service request to the cluster corresponding to the home region according to the header information.

[0023] In the above scheme, the cluster corresponding to the home region includes a server that deploys logical services. The routing module is further configured to: when the server is unavailable, route the service request to the cluster in the corresponding other region through the access switch, so that the cluster in the corresponding other region can perform response processing for the service request, wherein the other region is a region other than the home region among the plurality of regions.

[0024] In the above scheme, the cluster corresponding to the home region includes a storage system corresponding to the home region. The storage system includes a main memory corresponding to the home region, a backup memory corresponding to the home region, and a remote backup memory corresponding to other regions. The other regions are regions other than the home region among the plurality of regions. The routing module is further configured to: perform any one of the following processes: when the main memory corresponding to the home region is available, perform a target operation on the main memory corresponding to the home region according to the service request to obtain a response result corresponding to the service request, wherein the target operation includes at least one of the following: a read operation and a write operation; when the main memory corresponding to the home region is unavailable, perform a target operation on the backup memory corresponding to the home region according to the service request to obtain a response result corresponding to the service request, wherein the target operation includes at least one of the following: a read operation and a write operation; when both the main memory corresponding to the home region and the backup memory corresponding to the home region are unavailable, perform a read operation on the remote backup memory corresponding to other regions according to the service request to obtain a response result corresponding to the service request.

[0025] This application provides an electronic device, including:

[0026] Memory, used to store executable instructions;

[0027] The processor, when executing executable instructions stored in the memory, implements the data processing method of the cluster system provided in the embodiments of this application.

[0028] This application provides a computer-readable storage medium storing executable instructions, which, when executed by a processor, implement the data processing method of the cluster system provided in this application.

[0029] The embodiments of this application have the following beneficial effects:

[0030] Service requests from business accounts are received through the access switch. The source location of the service request is within the jurisdiction of the access region corresponding to the access switch, thus ensuring that the service request is accessed from the nearest location. When the business account's home region is different from the access region, it indicates a cross-regional access situation. The access switch routes the service request to the cluster in the corresponding home region among multiple clusters, so that the cluster in the corresponding home region can perform the response processing for the service request. Since the access switch directly routes the service request to the cluster in the corresponding home region, it ensures that the subsequent processing is completed within the cluster in the corresponding home region, controlling the number of cross-regional data transmissions and improving the response speed of service requests. Attached Figure Description

[0031] Figure 1 This is a schematic diagram of the structure of the data processing system of the cluster system provided in the embodiments of this application;

[0032] Figure 2 This is a schematic diagram of the structure of the electronic device provided in the embodiments of this application;

[0033] Figures 3A-3C This is a flowchart illustrating the data processing method of the cluster system provided in an embodiment of this application;

[0034] Figures 4A-4C This is a display interface diagram of the business scenario of the data processing method of the cluster system provided in the embodiments of this application;

[0035] Figure 5 This is a schematic diagram of the cluster system architecture for the data processing method of the cluster system provided in the embodiments of this application;

[0036] Figure 6 This is a schematic diagram of the routing center architecture of the data processing method of the cluster system provided in this application embodiment. Detailed Implementation

[0037] To make the objectives, technical solutions, and advantages of this application clearer, the application will be further described in detail below with reference to the accompanying drawings. The described embodiments should not be regarded as limitations on this application. All other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.

[0038] In the following description, references are made to “some embodiments,” which describe a subset of all possible embodiments. However, it is understood that “some embodiments” may be the same subset or different subsets of all possible embodiments and may be combined with each other without conflict.

[0039] In the following description, the terms "first, second, third" are used merely to distinguish similar objects and do not represent a specific ordering of objects. It is understood that "first, second, third" may be interchanged in a specific order or sequence where permitted, so that the embodiments of this application described herein can be implemented in an order other than that illustrated or described herein.

[0040] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs. The terminology used herein is for the purpose of describing embodiments of this application only and is not intended to limit this application.

[0041] In the implementation of this application, the collection and processing of relevant data should strictly comply with the requirements of relevant laws and regulations, obtain the informed consent or separate consent of the personal information subject, and carry out subsequent data use and processing within the scope of laws and regulations and the authorization of the personal information subject.

[0042] Before providing a further detailed description of the embodiments of this application, the nouns and terms involved in the embodiments of this application will be explained, and the nouns and terms involved in the embodiments of this application shall be interpreted as follows.

[0043] 1) Availability: The probability that the functional services provided by the client to the user can work normally. High availability indicates that the functional services provided by the client to the user are likely to work normally.

[0044] 2) SET modularization: The original overall architecture is split into multiple units, each of which works independently and together supports the functional services of the client.

[0045] 3) Split-brain: Different subjects obtain different data processing results based on the same data, resulting in data processing conflicts, which prevents the subjects from functioning normally.

[0046] With the popularization and advancement of computer and information technologies, various user-facing services are gradually shifting from offline to online through various clients. This places increasingly higher demands on the backend service capabilities of clients. In particular, in business scenarios with frequent cross-regional service requests, a large number of cross-city service requests will occur, which will increase network latency and lead to service response delays.

[0047] Related technologies may improve service response speed by increasing network bandwidth or optimizing hardware, but this approach has a clear load limit and still cannot maintain a high service response speed in business scenarios with frequent cross-regional service requests.

[0048] This application provides a data processing method, apparatus, electronic device, computer program product, and computer-readable storage medium for a cluster system, which can improve the response speed of service requests. The following describes exemplary applications of the electronic device provided in this application, which can be implemented as a server. Exemplary applications when the device is implemented as a server will be described below.

[0049] See Figure 1 , Figure 1 This is a schematic diagram of the data processing system structure of the cluster system provided in this application embodiment. To support an exemplary application, terminal 400 connects to server 200 via network 300, which can be a wide area network (WAN), a local area network (LAN), or a combination of both. Server 200 is equipped with a cluster system, which includes multiple clusters deployed in corresponding regions. Each cluster includes a logical layer service, a data layer service, and a database, all capable of independently processing service requests. The cluster system also includes a routing center and multiple access switches deployed in corresponding regions. Terminal 400 sends service requests for a target service to server 200. Server 200 receives the service request and routes it to the corresponding cluster. Before routing, it queries the routing center to determine the region to which the service account belongs. If the queried region differs from the access region, the service request is routed to the corresponding cluster in the multiple clusters via the access switch, allowing the corresponding cluster to perform the response processing for the service request. During cluster processing, the logical layer service of the cluster calls the data layer service of the cluster to read or write data from the cluster's database to generate a processing result.

[0050] In some embodiments, server 200 may be a standalone physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server providing basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, CDN, and big data and artificial intelligence platforms. Terminal 400 may be a smartphone, tablet computer, laptop computer, desktop computer, smart speaker, smartwatch, etc., but is not limited thereto. Terminals and servers can be directly or indirectly connected via wired or wireless communication, which is not limited in this embodiment.

[0051] See Figure 2, Figure 2 This is a schematic diagram of the structure of the electronic device provided in the embodiments of this application. Figure 2 The server 200 shown includes at least one processor 210, memory 250, and at least one network interface 220. The various components of server 200 are coupled together via a bus system 240. It is understood that the bus system 240 is used to implement communication between these components. In addition to a data bus, the bus system 240 also includes a power bus, a control bus, and a status signal bus. However, for clarity, all buses are labeled as bus system 240 in Figure 3.

[0052] Processor 210 can be an integrated circuit chip with signal processing capabilities, such as a general-purpose processor, a digital signal processor (DSP), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc., where the general-purpose processor can be a microprocessor or any conventional processor, etc.

[0053] The memory 250 may be removable, non-removable, or a combination thereof. Exemplary hardware devices include solid-state storage, hard disk drives, optical disk drives, etc. The memory 250 may optionally include one or more storage devices physically located away from the processor 210.

[0054] The memory 250 may include volatile memory or non-volatile memory, or both. The non-volatile memory may be read-only memory (ROM), and the volatile memory may be random access memory (RAM). The memory 250 described in this application embodiment is intended to include any suitable type of memory.

[0055] In some embodiments, memory 250 is capable of storing data to support various operations, examples of which include programs, modules, and data structures or subsets or supersets thereof, as illustrated below.

[0056] Operating system 251 includes system programs for handling various basic system services and performing hardware-related tasks, such as the framework layer, core library layer, driver layer, etc., for implementing various basic business functions and handling hardware-based tasks;

[0057] The network communication module 252 is used to reach other computing devices via one or more (wired or wireless) network interfaces 220, such as Bluetooth, WiFi, and Universal Serial Bus (USB).

[0058] In some embodiments, the data processing device of the cluster system provided in this application can be implemented in software. Figure 2 A data processing device 255 for a cluster system stored in memory 250 is shown. It can be software in the form of programs and plug-ins, including the following software modules: receiving module 2551, query module 2552, and routing module 2553. These modules are logical and can therefore be arbitrarily combined or further split according to the functions they implement.

[0059] The data processing method of the cluster system provided in the embodiments of this application will be described in conjunction with the exemplary application and implementation of the server provided in the embodiments of this application.

[0060] See Figure 3A , Figure 3A This is a flowchart illustrating the data processing method of the cluster system provided in this application embodiment, which will be combined with... Figure 3A Steps 101-104 shown are explained.

[0061] In step 101, the service request for the service account sent by the terminal is received through the access switch.

[0062] As an example, a cluster system includes a routing center, multiple clusters deployed one-to-one across multiple regions, and multiple access switches deployed one-to-one across multiple regions. For instance, the cluster system might deploy in three regions: Guangzhou, Shanghai, and Beijing, with one cluster deployed in each of Guangzhou, Shanghai, and Beijing. Each cluster includes logical layer services, data layer services, and a storage database. The source location of a service request is within the jurisdiction of the access region corresponding to the access switch. This jurisdiction refers to the jurisdiction over the business request. For example, Shanghai's jurisdiction covers the Jiangsu and Zhejiang regions, and a service request originating from Suzhou is received by the corresponding access switch in Shanghai. Similarly, if a client used by a user at a certain coordinate in Shenzhen sends a service request, since Shenzhen is within the jurisdiction of Guangzhou, Guangzhou is the access region for the service request. The access region is one of multiple regions, and the access switch receiving the service request is the access switch corresponding to Guangzhou, which is determined by the gateway.

[0063] In step 102, the access switch queries the routing center to determine the region to which the service account belongs.

[0064] As an example, the cluster system is deployed in three regions: Guangzhou, Shanghai, and Beijing. The home region is one of multiple regions. When a business account first issues a service request, its location is within the jurisdiction of Shanghai; therefore, Shanghai is the home region of the business account. The region information representing the home region is stored as a key-value pair in the routing center, with the business account as the key, forming a key-value pair. This allows the access switch to query the routing center for the home region of the business account.

[0065] In step 103, when the queried home region is different from the access region, the service request is routed to the corresponding home region cluster in multiple clusters through the access switch.

[0066] In step 104, the cluster corresponding to the region performs response processing for the service request.

[0067] As an example, a user located at a certain coordinate in Shenzhen sends a service request through their client. Since Shenzhen is under the jurisdiction of Guangzhou, Guangzhou is the access region for the service request. However, the region of origin found is Shanghai. Therefore, the service request is routed to the corresponding Shanghai cluster through the access switch. The corresponding Shanghai cluster then performs a straightforward response processing for the service request, that is, the response processing for the service request is performed through the logical layer service, data layer service, and storage database of the corresponding Shanghai cluster.

[0068] Service requests from business accounts are received through the access switch. The source location of the service request is within the jurisdiction of the access region corresponding to the access switch, thus ensuring that the service request is accessed from the nearest location. When the business account's home region is different from the access region, it indicates a cross-regional access situation. The access switch routes the service request to the cluster in the corresponding home region among multiple clusters, so that the cluster in the corresponding home region can perform the response processing for the service request. Since the access switch directly routes the service request to the cluster in the corresponding home region, it ensures that the subsequent processing is completed within the cluster in the corresponding home region, controlling the number of cross-regional data transmissions and improving the response speed of service requests.

[0069] In some embodiments, see Figure 3B , Figure 3B This is a flowchart illustrating the data processing method of the cluster system provided in this application embodiment. Figure 3B Steps 101-104 in the middle Figure 3A Same, combined below Figure 3B Step 105 is illustrated below.

[0070] In step 105, when the service account's region is the same as the access region, the service request is routed to the corresponding access region cluster in multiple clusters by calling the routing control tool through the access switch.

[0071] As an example, a user located at a certain coordinate in Shenzhen sends a service request through their client. Since Shenzhen is under the jurisdiction of Guangzhou, Guangzhou is the access area for the service request. The user also finds that the user's home region is Guangzhou. Therefore, the service request is routed to the corresponding cluster in Guangzhou through the access switch. The cluster in Guangzhou then performs a straightforward response to the service request. That is, the response to the service request is performed through the logical layer service, data layer service, and storage database of the cluster in Guangzhou.

[0072] In some embodiments, the routing center includes a root node, a routing storage database cluster for each region, and a local cache for each region; see also Figure 3C , Figure 3C This is a flowchart illustrating the data processing method of the cluster system provided in this application embodiment. Step 102 queries the routing center for the region to which the service account belongs through the access switch. This can be executed by calling the routing control tool through the access switch. Figure 3C Any one of steps 1021-1023.

[0073] In step 1021, the local cache of the corresponding access region is queried to determine the region to which the service account belongs.

[0074] In step 1022, if the region to which the business account belongs is not found in the local cache of the routing center, the routing storage database cluster of the corresponding access region is queried for the region to which the business account belongs.

[0075] In step 1023, if the region to which the business account belongs is not found in the local cache of the corresponding access region, and the region to which the business account belongs is not found in the routing storage database cluster of the corresponding access region, the root node of the routing center is queried for the region to which the business account belongs.

[0076] By performing source queries layer by layer, the hit rate of the local cache can be improved, thus increasing query efficiency.

[0077] As an example, see Figure 6 , Figure 6 This is a schematic diagram of the routing center architecture of the data processing method for the cluster system provided in this application embodiment. Similar to access switches, the routing center is also deployed in multiple locations. The main storage of the routing center uses a routing storage database cluster, such as a Redis database. The routing center adopts a three-level storage structure. In this three-level storage structure, L3 is the root node, L2 consists of local nodes (routing storage database clusters) in each region, and L1 is the local memory cache for services in each region. When the routing control tool queries the routing center to determine the region to which a business account belongs, it performs a source lookup query layer by layer from L1 to L3.

[0078] In some embodiments, the local cache corresponding to the access region is distributed across multiple first storage devices. The above-mentioned query for the region to which the business account belongs by querying the local cache corresponding to the access region can be achieved by the following technical solution: performing hash processing on the business account to obtain a first hash processing result of the corresponding business account; determining a target first storage device corresponding to the first hash processing result from the multiple first storage devices; and querying the region to which the business account belongs in the target first storage device.

[0079] As an example, since the storage capacity of each memory is limited, but the number of business accounts is infinite, the local cache is distributed across multiple first memories. Each business account can be hashed, resulting in a unique first hash value for each account. Furthermore, each first hash value corresponds to a position on a fixed circle, where 2... 32 Since each first memory also has a corresponding position on the fixed circle, the search starts clockwise from the position mapped by the data, and the first memory found is taken as the target first memory. The region to which the business account belongs is then queried in the target first memory.

[0080] In some embodiments, the following processing is performed by calling the routing control tool through the access switch: when the home region of the service account is not found in the root node of the routing center, it is determined that the service request is the first service request of the service account, and the access region of the service request is determined as the home region of the service account.

[0081] As an example, if the originating region of a business account cannot be found even after tracing back to the root node, it indicates that the business account corresponding to the service request is accessing the cluster system for the first time to use the business service function. The originating location of the service request issued by the business account is the access region. Continuing the above example, when the originating location of the service request issued by the business account is Shenzhen, the access region of the service request is Guangzhou, and Guangzhou is determined as the originating region of the business account.

[0082] In some embodiments, when a service request is the first service request from a business account, the access switch invokes the routing control tool to perform the following processing: writing the region information representing the home region into the root node of the routing center, the routing storage database cluster of the corresponding access region, and the local cache of the corresponding access region; broadcasting the region information to the routing storage database cluster of the corresponding other regions and other local caches of the routing center; wherein, the other regions are regions other than the access region among multiple regions, and the other local caches are local caches in the routing center other than the local cache of the corresponding access region. This broadcast processing effectively backs up the data, thus enabling storage disaster recovery in the event of a failure of any node.

[0083] As an example, if the region to which a business account belongs cannot be found even after tracing back to the root node, it indicates that the business account corresponding to the service request is accessing the cluster system for the first time to use the business service function. In this case, it is necessary to record the region information (origin location region information) of the user corresponding to the business account in real time, and write the region information as routing information to the root node of the routing center, the routing storage database cluster of the corresponding access region, and the local memory cache. The routing information will also be broadcast to routing storage database clusters in other locations (e.g., Redis database) and the local memory cache of the service in various locations. In addition, in order to quickly build the cache in abnormal situations, the full routing information can also be backed up to form persistent storage.

[0084] In some embodiments, the above-mentioned writing of the region information representing the home region to the root node of the routing center can be achieved through the following technical solution: performing query locking processing on the root node of the routing center; when the root node of the routing center is in a query-locked state, writing the region information representing the home region to the root node of the routing center; wherein, the root node of the routing center being in a query-locked state means that the root node of the routing center cannot be subject to query operations. By encapsulating the query processing and the write processing into atomic operations through locking processing, the possibility of data conflicts is reduced.

[0085] As an example, when a user first connects, two requests might be triggered within a short period: one from Guangzhou and one from Shanghai. In absolute chronological order, the request from Guangzhou is the first connection request, but the request from Shanghai follows immediately. The time interval between the two requests is less than a time threshold. For instance, a service request from a user in a remote province could randomly connect to the corresponding cluster in Guangzhou via an access switch in Guangzhou, or to the corresponding cluster in Shanghai via an access switch in Shanghai. Since neither the local cache of the routing center nor the Redis database contains regional information indicating the user's region, the two requests will concurrently read from the root node. At this point, the root node also lacks regional information indicating the user's region. The first request writes to the root node and returns Guangzhou as the region, while the second request overwrites the previous result and returns Shanghai as the region. If two query requests yield different regional information, it may be written to the storage of two different clusters simultaneously, causing a split-brain data processing conflict. Therefore, when accessing the root node, it is necessary to ensure that read and write operations are performed within an atomic operation. This atomicity can be guaranteed using Lua scripts. The script can be configured to read first and then write. For example, the first request reads the root node. If no regional information is found, indicating that this is the first service request from the business account, a query lock is performed on the root node of the routing center. While the root node of the routing center is in a query lock state, the regional information representing the home region is written to the root node of the routing center, and the returned regional information is Guangzhou. During this process, a second read request cannot be performed. If regional information is found when reading the root node, the read regional information is returned directly; otherwise, while the query lock state is active, the regional information is written and returned.

[0086] In some embodiments, the local cache corresponding to the access region is distributed across multiple first memories. The process of writing the region information representing the home region into the local cache of the corresponding access region can be achieved through the following technical solution: hashing the service account to obtain a first hash result for the corresponding service account; hashing the machine identifier of each of the multiple first memories to obtain a second hash result for each first memory; determining the first memory corresponding to the second hash result that is adjacent to the first hash result and greater than the first hash result as the target first memory for the corresponding service account; and writing the region information representing the home region into the local cache of the target first memory. This method ensures the uniqueness of the region information being written, allowing direct querying from a specific first memory and improving query efficiency.

[0087] As an example, consistent hashing organizes the entire hash space into a virtual circle, with the entire space arranged clockwise, and 0 and 2. 32 -1 coincides in the zero-point direction. The identifiers of each first memory are hashed to determine the hash value (second hash processing result) of each first memory. This hash value is then assigned to the corresponding position on the fixed circle. There are 2 on the fixed circle. 32 The first hash processing result of the business account is determined using the same method and mapped to the same fixed circle. Then, starting from the position mapped to the business account, the search proceeds clockwise, and the business account and the corresponding regional information are saved to the first first memory (target first memory) found.

[0088] In some embodiments, the region information representing the access region is the default routing information in the routing control tool. In step 103, the service request is routed to the cluster in the corresponding home region among multiple clusters through the access switch. This can be achieved through the following technical solution: The routing control tool is invoked through the access switch to perform the following processing: The default routing information in the routing control tool is replaced with the region information representing the home region to obtain the routing information of the service request; the routing information is used as the header information of the corresponding service request; and the service request is routed to the cluster in the corresponding home region according to the header information.

[0089] As an example, since the access layer (including multiple access switches) receives numerous types of service requests, to reduce backend development costs, a general SDK can be developed to access the routing center. The access layer calls the general SDK to obtain routing information and injects it into the request header. The request header is then sent to the lower-level services in the cluster, which includes logic layer services, data layer services, and a database. Each service uses the information as needed, and the access layer does not interfere with the processing within the cluster. This eliminates the need for cross-city access in subsequent processing, effectively improving service response speed. Furthermore, since routing information is static and remains unchanged once generated, the SDK can also cache the routing information to reduce the number of queries to the routing center.

[0090] In some embodiments, the cluster corresponding to the home region includes servers that deploy logical services. When a server is unavailable, service requests are routed to clusters in other regions via an access switch, allowing those clusters to handle the service requests. These other regions are regions other than the home region. By deploying services across clusters in different locations, service unavailability is avoided if an anomaly occurs in one location. After a service failure in one location, the system automatically switches to clusters in other available regions, ensuring uninterrupted business operations.

[0091] In some embodiments, the cluster corresponding to the home region includes a storage system corresponding to the home region. The storage system includes a main memory corresponding to the home region, a backup memory corresponding to the home region, and a remote backup memory corresponding to other regions. Other regions are regions other than the home region among multiple regions. In step 104, the cluster corresponding to the home region performs response processing for the service request, which can be implemented by the following technical solutions: performing any of the following processes: when the main memory corresponding to the home region is available, performing a target operation on the main memory corresponding to the home region according to the service request to obtain the response result of the corresponding service request, wherein the target operation includes at least one of the following: a read operation and a write operation; when the main memory corresponding to the home region is unavailable, performing a target operation on the backup memory corresponding to the home region according to the service request to obtain the response result of the corresponding service request, wherein the target operation includes at least one of the following: a read operation and a write operation; when both the main memory corresponding to the home region and the backup memory corresponding to the home region are unavailable, performing a read operation on the remote backup memory corresponding to other regions according to the service request to obtain the response result of the corresponding service request.

[0092] As an example, see Figure 5 , Figure 5 This is a schematic diagram of the cluster system architecture for the data processing method of the cluster system provided in this application embodiment. The cluster system includes multiple clusters deployed in multiple regions, each of which includes a logical layer service, a data layer service, and a database (storage system). In the cluster corresponding to each region, after the failure of the storage single data center (the main storage in the storage system of a certain cluster), it can be switched to the local backup data center (the backup storage in the storage system of a certain cluster). After the complete failure of the storage, only the service requests issued by users in the region are affected. At this time, the off-site disaster recovery storage (the off-site backup storage corresponding to other regions) can be read, but it is not possible to write to the off-site disaster recovery storage. If necessary, manual intervention can be performed to switch the off-site disaster recovery storage to the main storage.

[0093] Service requests from business accounts are received through the access switch. The source location of the service request is within the jurisdiction of the access region corresponding to the access switch, thus ensuring that the service request is accessed from the nearest location. When the business account's home region is different from the access region, it indicates a cross-regional access situation. The access switch routes the service request to the cluster in the corresponding home region among multiple clusters, so that the cluster in the corresponding home region can perform the response processing for the service request. Since the access switch directly routes the service request to the cluster in the corresponding home region, it ensures that the subsequent processing is completed within the cluster in the corresponding home region, controlling the number of cross-regional data transmissions and improving the response speed of service requests.

[0094] Cluster systems can be applied to various business scenarios with frequent cross-regional service requests. For example, a cluster system can be used for payment business systems, game business systems, social business systems, etc. The following uses a cluster system as a social business system as an example to illustrate the data processing method of the cluster system provided in this application embodiment.

[0095] In some embodiments, to ensure that the application provides social service functions to users, this application provides a data processing method for a cluster system. Specifically, a terminal receives a user's social message sending request, connects to a server via a network, and sends the social message sending request to the server. A cluster system is deployed on the server, which includes multiple clusters deployed in multiple regions. Each cluster includes a logical layer service, a data layer service, and a database, all of which can independently process the social message sending request. The cluster system also includes a routing center and multiple access switches deployed in multiple regions. The server routes the received social message sending request to the corresponding cluster. Before routing, it queries the routing center for the region to which the user's social message sending account (the business account that issued the social message sending request) belongs. When the queried region is different from the access region, the social message sending request is routed to the cluster in the corresponding region among the multiple clusters through the access switch, so that the cluster in the corresponding region performs the response processing for the social message sending request. During the cluster processing, the logical layer service of the cluster calls the data layer service of the cluster to read data from and / or write data to the cluster's database to generate a successful social message sending result.

[0096] See Figures 4A-4C , Figures 4A-4C This is a display interface diagram of a business scenario for the data processing method of the cluster system provided in this application embodiment. During the Spring Festival, due to changes in user geographical location, cross-regional service requests become more frequent. Social services can be based on the browser task system, responding to business accounts completing tasks within the browser. Business accounts then qualify for a lottery, with a chance to win prizes. The social service system will also launch other functions to attract users and will conduct unified lottery draws at certain times. Therefore, it is essential to ensure that the social service has very high availability during the Spring Festival to avoid user-perceptible failures or delays that could affect the user experience. Social services surrounding holiday activities receive high user attention during the Spring Festival, thus requiring very high service availability. To ensure high service availability, this application embodiment provides a data processing method for a cluster system, which can improve the response speed of service requests and avoid user-perceptible failures. The cluster system adopts... Figure 5 The diagram shows a multi-site disaster recovery architecture with subdivided units.

[0097] See Figure 5 The cluster system comprises multiple clusters deployed in corresponding regions. Each cluster includes logical layer services, data layer services, and a database, all capable of independently processing service requests. The cluster system also includes a routing center and multiple access switches deployed in corresponding regions. Services are deployed across clusters in various locations, with all services deployed in three locations to prevent service unavailability due to anomalies in one location. In the event of a service failure in one location, the system automatically switches to clusters in other available regions, ensuring uninterrupted business operations. Within each regional cluster, a single data center failure can switch to a backup server within the same city. A complete storage failure only affects users within that region. In this case, users can read from the off-site disaster recovery storage, but writing to it is impossible. If necessary, manual intervention can be used to switch the off-site disaster recovery storage to the primary storage.

[0098] In some embodiments, during the Spring Festival travel rush, a large number of inter-city requests may occur. Excessive inter-city requests can increase network latency and instability. Firstly, a routing center manages the regional information of users (business accounts). The region where a user first enters the system is designated as the user's home region, which directly determines the location of the user's primary storage. The routing center stores multiple key-value pairs, with the user identifier of the business account as the key and the regional information of the business account's home region as the value. Each time a service request is received, the routing center is consulted to determine the business account's home region. Furthermore, after receiving a service request, the request passes through the business gateway to the access layer, and then down to the logical layer within the regional cluster—all following a direct, nearest-neighbor access path.

[0099] In some embodiments, the region to which a user’s business account belongs is the region at which the first nearest access is made, that is, the region where the user is located when the first service request is made. If the user has never migrated, then each subsequent service request will also be accessed from the region where the user is located. After receiving the service request, the service request passes through the business gateway to the access layer, and then to the logic layer below the regional cluster. All of these are direct nearest access within the cluster, and there is no cross-city situation. When a user's location changes, for example, during the launch of a business function, the user migrates from Shanghai to Guangzhou. The user's corresponding business account initially issued a service request in Shanghai, so the user's business account is also located in Shanghai, and the main storage is in the Shanghai cluster. When the user migrates to Guangzhou and continues to issue service requests based on the business function, the request is routed through the gateway to the access layer in Guangzhou (the access switch in Guangzhou), and then further routed to the logical layer of the Guangzhou cluster. Thus, every data request from the logical layer of the Guangzhou cluster (logic service layer accessing the storage layer) is sent across cities to Shanghai. These multiple cross-city transmissions result in excessive time consumption. Therefore, this application provides a cluster system including a routing center, enabling service requests that should have been routed to the Guangzhou cluster to directly access the logical layer service of the Shanghai cluster. After the service request is routed to the Shanghai logical layer, it still uses a direct access method within the Shanghai cluster. Therefore, the entire request-response process only involves one cross-city request at the access layer.

[0100] In some embodiments, see Figure 6The routing center is used to solve the problem of frequent cross-city access, ensuring that service requests for a business account only cross city boundaries at most once. Like the access layer, the routing center is deployed in three locations. The main storage of the routing center uses a Redis database. The routing center adopts a three-level storage structure. In this structure, L3 is the root node, L2 are the local nodes in each region, and L1 is the local memory cache for the service. When the routing control tool queries the routing center for the region of a business account, it performs a back-to-origin query layer by layer from L1 to L3. If the region of the business account is not found even after traversing back to the root node, it indicates that the business account corresponding to the service request is accessing the cluster system for the first time to use the business service function. At this time, it is necessary to record the real-time region information of the user corresponding to the business account, write the corresponding cluster information to the root node and local memory cache of the routing center, and broadcast the cluster information as routing information to the Redis databases in each region and the local memory caches of each server. In addition, to quickly build the cache in abnormal situations, the full routing information can also be backed up to form persistent storage. The routing center requires callers to use proximity access and consistent hashing. Therefore, the access layer switch calls the routing control tool to query the local memory cache of servers in the same region to determine the region of the business account. This ensures that all access layer nodes access the local cache within the same city, guaranteeing a high local cache hit rate. Thus, the routing center's design ensures high availability and high performance. Its high availability is reflected in multi-site disaster recovery; the root node of the routing center, local Redis databases, and local caches all store complete routing information. Its high performance is reflected in its consistent hashing approach for queries, where existing users' business accounts use proximity access. Theoretically, all service requests access nodes within the same city, and the vast majority of queries hit the local cache. Simulation tests show a local cache hit rate as high as 92%, significantly reducing time consumption. When a new user's business account sends its first service request, it only needs to write its current location as the region of origin to the root node and local cache. Upon successful completion, the request returns, and the business account's region of origin is asynchronously broadcast to other nodes in the routing center via a message queue.

[0101] In some embodiments, due to the numerous types of service requests received by the access layer, a general SDK can be developed in conjunction with the protocol to access the routing center to reduce backend development costs. The access layer calls the general SDK to obtain routing information and injects it into the request header. The request header is then sent to the lower-level services in the cluster, which can retrieve it as needed. The access layer does not interfere with the processing within the cluster. Furthermore, since the routing information is static and remains unchanged once generated, the SDK can also cache the routing information to reduce the number of queries to the routing center.

[0102] In some embodiments, for cross-city service requests issued by users, the access layer switch sends the service request across cities to the cluster in the user's home region by calling the SDK. This can be achieved by modifying the routing plugin. The routing plugin itself supports proximity routing, that is, it determines proximity based on the location information (region / city / data center) of the server's data center. For example, if the client's service request is sent through a data center in Guangzhou, and the cluster system has proximity routing enabled, the routing plugin will prioritize accessing the data center in Guangzhou based on the Guangzhou region information. Based on the above method, when a user migrates from Shanghai to Guangzhou, the access layer machine (access switch) in Guangzhou needs to route the service request to the logical layer in the Shanghai cluster. This can be achieved by simply modifying the location information of the access layer machine in Guangzhou in the routing plugin to match the location information of the logical layer machine in Shanghai.

[0103] In some embodiments, when a user first connects, two requests are triggered within a short period: one from Guangzhou and one from Shanghai. For example, a user from a remote province can randomly connect from either Guangzhou or Shanghai. Since the local cache of the routing center and the Redis database do not yet contain regional information representing the user's home region, concurrent reads are performed on the root node. At this time, the root node also does not contain regional information representing the user's home region. The first request writes to the root node and returns Guangzhou as the regional information. The second request overwrites the previous result and returns Shanghai as the regional information. Thus, the two query requests obtain different regional information, which may be written to the storage of two clusters simultaneously, causing a split-brain effect. When accessing the root node, it is necessary to ensure that the read and write operations are within an atomic operation. This atomicity can be guaranteed using Lua scripts, which are set to read first and then write. For example, the first request reads the root node, and if no regional information is found, it writes to it, returning Guangzhou as the regional information. During this process, the second request cannot be performed. If regional information is found when reading the root node, it is returned directly; otherwise, the regional information is written and returned.

[0104] The data processing method of the cluster system provided in this application embodiment has a stable service request response speed in long-term simulation tests. In the simulation tests, it simulates business scenarios with frequent cross-regional service requests. Even when dealing with sudden surges in traffic, the overall service does not fail and maintains a high response speed, thus ensuring the core social experience of users in real business scenarios.

[0105] It is understood that in the embodiments of this application, data such as user information are involved. When the embodiments of this application are applied to specific products or technologies, user permission or consent is required, and the collection, use and processing of related data must comply with the relevant laws, regulations and standards of the relevant countries and centers.

[0106] The following description continues to illustrate the exemplary structure of the data processing device 255 of the cluster system provided in this application embodiment as a software module. In some embodiments, the cluster system includes a routing center, multiple clusters deployed one-to-one in multiple regions, and multiple access switches deployed one-to-one in multiple regions, such as... Figure 2 As shown, the software modules in the data processing device 255 of the cluster system stored in the memory 250 may include: a receiving module 2551, used to receive service requests from service accounts through an access switch, wherein the source location of the service request is governed by the access region corresponding to the access switch, and the access region is one of multiple regions; a query module 2552, used to query the routing center through the access switch for the home region of the service account, wherein the home region is one of multiple regions; and a routing module 2553, used to route the service request to the cluster with the corresponding home region among the multiple clusters through the access switch when the queried home region is different from the access region, so that the cluster with the corresponding home region performs response processing for the service request.

[0107] In some embodiments, the routing module 2553 is further configured to: when the service account's region of origin is the same as the access region, route the service request to the cluster in the corresponding access region among multiple clusters by calling the routing control tool through the access switch.

[0108] In some embodiments, the routing center includes a root node, a routing storage database cluster corresponding to each region, and a local cache corresponding to each region; the query module 2552 is further configured to: invoke the routing control tool through the access switch to perform any of the following processes: query the local cache of the corresponding access region to find the region to which the service account belongs; when the region to which the service account belongs is not found in the local cache of the routing center, query the routing storage database cluster of the corresponding access region to find the region to which the service account belongs; when the region to which the service account belongs is not found in the local cache of the corresponding access region and is not found in the routing storage database cluster of the corresponding access region, query the root node of the routing center to find the region to which the service account belongs.

[0109] In some embodiments, the local cache corresponding to the access region is distributed across multiple first storage devices. The query module 2552 is further configured to: perform hash processing on the business account to obtain a first hash processing result for the corresponding business account; determine a target first storage device corresponding to the first hash processing result from the multiple first storage devices; and query the region to which the business account belongs in the target first storage device.

[0110] In some embodiments, the query module 2552 is further configured to: invoke the routing control tool through the access switch to perform the following processing: when the service account’s home region is not found in the root node of the routing center, determine that the service request is the first service request of the service account, and determine the access region of the service request as the home region of the service account.

[0111] In some embodiments, the query module 2552 is further configured to: when the service request is the first service request of a business account, invoke the routing control tool through the access switch to perform the following processing: write the region information representing the home region into the root node of the routing center, the routing storage database cluster of the corresponding access region, and the local cache of the corresponding access region; broadcast the region information to the routing storage database cluster of the corresponding other regions and other local caches of the routing center; wherein, the other regions are regions other than the access region among multiple regions, and the other local caches are local caches in the routing center other than the local cache of the corresponding access region.

[0112] In some embodiments, the query module 2552 is further configured to: perform query locking processing on the root node of the routing center; when the root node of the routing center is in a query locked state, write the regional information representing the home region into the root node of the routing center; wherein, the root node of the routing center being in a query locked state indicates that the root node of the routing center cannot be subject to query operations.

[0113] In some embodiments, the local cache corresponding to the access region is distributed across multiple first storage devices. The query module 2552 is further configured to: perform hash processing on the service account to obtain a first hash processing result for the corresponding service account; perform hash processing on the machine identifier of each of the multiple first storage devices to obtain a second hash processing result for each first storage device; determine the first storage device corresponding to the second hash processing result that is adjacent to the first hash processing result and is greater than the first hash processing result as the target first storage device for the corresponding service account; and write the region information representing the home region into the local cache of the target first storage device.

[0114] In some embodiments, the region information representing the access region is the default routing information in the routing control tool. The routing module 2553 is further configured to: call the routing control tool through the access switch to perform the following processing: replace the default routing information in the routing control tool with the region information representing the home region to obtain the routing information of the service request; use the routing information as the header information of the corresponding service request; and route the service request to the cluster of the corresponding home region according to the header information.

[0115] In some embodiments, the cluster corresponding to the home region includes a server that deploys logical services. The routing module 2553 is further configured to: when the server is unavailable, route the service request to the cluster in the corresponding other region through an access switch, so that the cluster in the corresponding other region can perform response processing for the service request, wherein the other region is a region other than the home region among multiple regions.

[0116] In some embodiments, the cluster corresponding to the home region includes a storage system corresponding to the home region. The storage system includes a main memory corresponding to the home region, a backup memory corresponding to the home region, and a remote backup memory corresponding to other regions. Other regions are regions other than the home region among multiple regions. The routing module 2553 is further configured to: perform any one of the following processes: when the main memory corresponding to the home region is available, perform a target operation on the main memory corresponding to the home region according to the service request to obtain a response result of the corresponding service request, wherein the target operation includes at least one of the following: a read operation and a write operation; when the main memory corresponding to the home region is unavailable, perform a target operation on the backup memory corresponding to the home region according to the service request to obtain a response result of the corresponding service request, wherein the target operation includes at least one of the following: a read operation and a write operation; when both the main memory corresponding to the home region and the backup memory corresponding to the home region are unavailable, perform a read operation on the remote backup memory corresponding to other regions according to the service request to obtain a response result of the corresponding service request.

[0117] This application provides a computer program product or computer program that includes computer instructions stored in a computer-readable storage medium. An electronic device's processor reads the computer instructions from the computer-readable storage medium and executes the computer instructions, causing the electronic device to perform the data processing method of the cluster system described in this application.

[0118] This application provides a computer-readable storage medium storing executable instructions. When these executable instructions are executed by a processor, the processor will execute the data processing method of the cluster system provided in this application, for example... Figures 3A-3C The data processing method of the cluster system is shown.

[0119] In some embodiments, the computer-readable storage medium may be a memory such as FRAM, ROM, PROM, EPROM, EEPROM, flash memory, magnetic surface memory, optical disk, or CD-ROM; or it may be a variety of devices including one or any combination of the above-mentioned memories.

[0120] In some embodiments, executable instructions may take the form of a program, software, software module, script, or code, written in any form of programming language (including compiled or interpreted languages, or declarative or procedural languages), and may be deployed in any form, including as a standalone program or as a module, component, subroutine, or other unit suitable for use in a computing environment.

[0121] As an example, executable instructions may, but do not necessarily, correspond to files in a file system. They may be stored as part of a file that holds other programs or data, for example, in one or more scripts in a Hyper Text Markup Language (HTML) document, in a single file dedicated to the program in question, or in multiple collaborating files (e.g., a file that stores one or more modules, subroutines, or code sections).

[0122] As an example, executable instructions can be deployed to execute on a single computing device, or on multiple computing devices located in one location, or on multiple computing devices distributed across multiple locations and interconnected via a communication network.

[0123] In summary, the access switch in this embodiment receives service requests from service accounts. The source location of the service request is governed by the access region corresponding to the access switch, thus ensuring that the service request is accessed from the nearest location. When the service account's home region is different from the access region, it indicates a cross-regional access situation. The access switch routes the service request to the cluster in the corresponding home region among multiple clusters, so that the cluster in the corresponding home region can perform the response processing for the service request. Since the access switch directly routes the service request to the cluster in the corresponding home region, it ensures that the subsequent processing is completed within the cluster in the corresponding home region, controlling the number of cross-regional data transmissions and improving the response speed of the service request.

[0124] The above description is merely an embodiment of this application and is not intended to limit the scope of protection of this application. Any modifications, equivalent substitutions, and improvements made within the spirit and scope of this application are included within the scope of protection of this application.

Claims

1. A data processing method for a cluster system, characterized in that, The cluster system includes a routing center, multiple clusters deployed one-to-one in multiple regions, and multiple access switches deployed one-to-one in the multiple regions; the routing center adopts a three-level storage structure, including a root node, a routing storage database cluster corresponding to each region, and a local cache corresponding to each region. The method includes: The access switch receives service requests from service accounts, wherein the source location of the service request is within the jurisdiction of the access region corresponding to the access switch, and the access region is one of the plurality of regions; The access switch invokes the routing control tool to perform any of the following processes: Query the local cache corresponding to the access region to determine the region to which the business account belongs; When the local cache of the routing center does not find the region to which the service account belongs, the routing storage database cluster corresponding to the access region is queried for the region to which the service account belongs. When the service account's home region is not found in the local cache of the corresponding access region, and the service account's home region is not found in the routing storage database cluster of the corresponding access region, the root node of the routing center is queried for the service account's home region, wherein the home region is one of the plurality of regions; When the queried home region is different from the access region, the service request is routed to the cluster corresponding to the home region among the multiple clusters through the access switch, so that the cluster corresponding to the home region can perform response processing for the service request.

2. The method according to claim 1, characterized in that, The method further includes: When the service account belongs to the same region as the access region, the service request is routed to the cluster in the multiple clusters corresponding to the access region by calling the routing control tool through the access switch.

3. The method according to claim 1, characterized in that, The local cache corresponding to the access region is distributed across multiple first storage devices. The step of querying the local cache corresponding to the access region to determine the region to which the service account belongs includes: The business account is hashed to obtain the first hash result corresponding to the business account. Determine the target first memory corresponding to the first hash processing result from the plurality of first memories; The region to which the business account belongs is queried in the target first memory.

4. The method according to claim 1, characterized in that, The method further includes: The following processing is performed by invoking the routing control tool through the access switch: When the root node of the routing center does not find the region to which the service account belongs, it is determined that the service request is the first service request of the service account, and the access region of the service request is determined as the region to which the service account belongs.

5. The method according to claim 4, characterized in that, The method further includes: When the service request is the first service request for the service account, the access switch invokes the routing control tool to perform the following processing: The region information representing the home region is written into the root node of the routing center, the routing storage database cluster corresponding to the access region, and the local cache corresponding to the access region; Broadcast the region information to the routing storage database clusters of other regions and other local caches of the routing center; Wherein, the other regions are regions other than the access region among the plurality of regions, and the other local caches are local caches in the routing center other than the local cache corresponding to the access region.

6. The method according to claim 5, characterized in that, The step of writing the regional information representing the home region into the root node of the routing center includes: Perform a query and lock process on the root node of the routing center; When the root node of the routing center is in a query-locked state, the regional information representing the home region is written into the root node of the routing center; The fact that the root node of the routing center is in a query-locked state indicates that the root node of the routing center cannot be used for query operations.

7. The method according to claim 5, characterized in that, The local cache corresponding to the access region is distributed across multiple first memories. The step of writing the region information representing the home region into the local cache corresponding to the access region includes: The business account is hashed to obtain the first hash result corresponding to the business account. The machine identifier of each of the plurality of first memories is hashed to obtain a second hash result for each of the first memories; The first memory corresponding to the second hash processing result that is adjacent to the first hash processing result and is greater than the first hash processing result is determined as the target first memory corresponding to the business account; The regional information representing the home region is written into the local cache of the target first memory.

8. The method according to claim 1, characterized in that, The region information representing the access region is the default routing information in the routing control tool. The step of routing the service request to the cluster corresponding to the home region among the multiple clusters via the access switch includes: The following processing is performed by invoking the routing control tool through the access switch: The default route information in the routing control tool is replaced using the regional information representing the home region to obtain the route information for the service request; The routing information is determined as the header information corresponding to the service request; The service request is routed to the cluster corresponding to the region based on the header information.

9. The method according to claim 1, characterized in that, The cluster corresponding to the home region includes servers that deploy logical services, and the method further includes: When the server is unavailable, the service request is routed to a cluster in another region via the access switch, so that the cluster in the other region performs the response processing for the service request. The other region is a region other than the home region among the plurality of regions.

10. The method according to claim 1, characterized in that, The cluster corresponding to the home region includes a storage system corresponding to the home region. The storage system includes a main memory corresponding to the home region, a backup memory corresponding to the home region, and an off-site backup memory corresponding to other regions. The other regions are regions other than the home region among the plurality of regions. The cluster corresponding to the home region performs response processing for the service request, including: Perform any of the following processes: When the main memory corresponding to the home region is available, a target operation is performed on the main memory corresponding to the home region according to the service request, and a response result corresponding to the service request is obtained. The target operation includes at least one of the following: a read operation and a write operation. When the main memory corresponding to the home region is unavailable, a target operation is performed on the backup memory corresponding to the home region according to the service request, and a response result corresponding to the service request is obtained. The target operation includes at least one of the following: a read operation and a write operation. When both the main memory corresponding to the home region and the backup memory corresponding to the home region are unavailable, a read operation is performed on the off-site backup memory corresponding to the other region according to the service request, and a response result corresponding to the service request is obtained.

11. A data processing device for a cluster system, characterized in that, The cluster system includes a routing center, multiple clusters deployed in multiple regions, and multiple access switches deployed in multiple regions. The routing center adopts a three-level storage structure, including a root node, a routing storage database cluster corresponding to each region, and a local cache corresponding to each region; The device includes: The receiving module is used to receive service requests from service accounts through the access switch, wherein the source location of the service request is within the jurisdiction of the access region corresponding to the access switch, and the access region is one of the plurality of regions; The query module is configured to invoke the routing control tool through the access switch to perform any of the following processes: query the local cache corresponding to the access region to determine the region to which the service account belongs; if the local cache of the routing center does not find the region to which the service account belongs, query the routing storage database cluster corresponding to the access region to determine the region to which the service account belongs; if the local cache of the access region does not find the region to which the service account belongs, and the routing storage database cluster corresponding to the access region does not find the region to which the service account belongs, query the root node of the routing center to determine the region to which the service account belongs, wherein the region to which the service account belongs is one of the plurality of regions; The routing module is used to route the service request to the cluster corresponding to the home region among the plurality of clusters through the access switch when the queried home region is different from the access region, so that the cluster corresponding to the home region can perform response processing for the service request.

12. The apparatus as claimed in claim 11, characterized in that, The routing module is also used for: When the service account belongs to the same region as the access region, the service request is routed to the cluster in the multiple clusters corresponding to the access region by calling the routing control tool through the access switch.

13. The apparatus as claimed in claim 11, characterized in that, The local cache corresponding to the access region is distributed across multiple first storage devices. The query module is further configured to: The business account is hashed to obtain a first hash result corresponding to the business account; a target first memory corresponding to the first hash result is determined from the plurality of first memories. The region to which the business account belongs is queried in the target first memory.

14. The apparatus as claimed in claim 11, characterized in that, The query module is also used for: The access switch invokes the routing control tool to perform the following processing: when the root node of the routing center does not find the region to which the service account belongs, it determines that the service request is the first service request of the service account, and determines the access region of the service request as the region to which the service account belongs.

15. The apparatus as claimed in claim 14, characterized in that, The query module is also used for: When the service request is the first service request of the business account, the access switch calls the routing control tool to perform the following processing: write the regional information representing the home region into the root node of the routing center, the routing storage database cluster corresponding to the access region, and the local cache corresponding to the access region; The region information is broadcast to the routing storage database cluster corresponding to other regions and other local caches of the routing center; wherein, the other regions are regions other than the access region among the plurality of regions, and the other local caches are local caches in the routing center other than the local cache corresponding to the access region.

16. The apparatus as claimed in claim 15, characterized in that, The query module is also used for: The root node of the routing center is subjected to query locking processing; when the root node of the routing center is in query locking state, the regional information representing the home region is written into the root node of the routing center; wherein, the root node of the routing center being in query locking state means that the root node of the routing center cannot be queried.

17. The apparatus as claimed in claim 15, characterized in that, The local cache corresponding to the access region is distributed across multiple first storage devices. The query module is further configured to: The business account is hashed to obtain a first hash result corresponding to the business account; the machine identifier of each of the plurality of first memories is hashed to obtain a second hash result corresponding to each of the first memories. The first memory corresponding to the second hash processing result that is adjacent to the first hash processing result and is greater than the first hash processing result is determined as the target first memory corresponding to the business account; The regional information representing the home region is written into the local cache of the target first memory.

18. An electronic device, characterized in that, The electronic device includes: Memory, used to store executable instructions; A processor, when executing executable instructions stored in the memory, implements the data processing method of the cluster system according to any one of claims 1 to 10.

19. A computer-readable storage medium storing executable instructions, characterized in that, When the executable instructions are executed by the processor, they implement the data processing method of the cluster system according to any one of claims 1 to 10.

20. A computer program product comprising a computer program or instructions, characterized in that, When the computer program or instructions are executed by the processor, they implement the data processing method of the cluster system according to any one of claims 1 to 10.