A data query method, device, apparatus and storage medium

By optimizing the data query process through a pre-defined hierarchical structure and data compression algorithm, the pressure problem of the configuration center under complex business scenarios was solved, and efficient data query and stability improvement were achieved.

CN116303563BActive Publication Date: 2026-04-07政采云股份有限公司
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-01-16
Publication Date
2026-04-07

AI Technical Summary

Technical Problem

In existing technologies, configuration centers provide services in a single-dimensional manner, which cannot meet the data query needs of complex business scenarios. This results in excessive pressure on the configuration center, stringent stability requirements, and impacts business risks.

Method used

By employing a pre-defined hierarchical structure and data compression algorithm, configuration data can be quickly determined. Furthermore, the data query process is optimized through local caching and remote service calls, reducing data consumption and improving query efficiency.

Benefits of technology

It effectively reduced data usage, improved data query efficiency, reduced pressure on the configuration center, and enhanced system stability.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116303563B_ABST
    Figure CN116303563B_ABST
Patent Text Reader

Abstract

This application discloses a data query method, apparatus, device, and storage medium, relating to the field of data processing. The method includes: determining whether an application configuration read request is being received for the first time; if so, retrieving business data corresponding to the business category of the application configuration read request from a preset configuration center; rendering a preset hierarchical structure based on the business data, and using the rendered hierarchical structure to determine configuration data coordinate parameters corresponding to the next application configuration read request; compressing the configuration data coordinate parameters using a preset compression algorithm, and generating a target request characteristic value corresponding to the configuration data coordinate parameters based on the compressed data; determining the configuration data corresponding to the next application configuration read request using preset data hitting rules and the target request characteristic value, and returning the configuration data to the client. In this way, data querying through a preset hierarchical structure and a preset compression algorithm can effectively reduce data consumption and improve data query efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of data processing, and in particular to a data query method, apparatus, device, and storage medium. Background Technology

[0002] As business grows, its complexity and differentiation also increase. Given this, a single-dimensional configuration center is insufficient to support data queries, leading to the emergence of multi-dimensional configuration centers based on business identities. Furthermore, any configuration item within a business may have... Figure 1 The multi-level differentiated configuration shown can be configured at the platform level or at the most granular "instance + region + organization" dimension. In the most complex scenario, a single configuration item may have tens of millions to hundreds of millions of configuration values. In scenarios with a large number of configuration items, the general SDK (Software Development Kit) cannot achieve local caching and needs to rely on the centralized service provided by the configuration center. If the number of applications is too large, it will put a lot of pressure on the configuration center. In addition, the configuration center requires very stringent stability. If a failure occurs, it will pose a great risk to the business.

[0003] In existing technologies, configuration centers typically provide services in a single-dimensional manner, with the SDK internally using local caching and long-term polling to receive changes. However, this single-dimensional configuration of controllable configuration items cannot meet the demands of complex business scenarios. Therefore, there is a need for an SDK algorithm that does not overly rely on the configuration center, has a controllable impact on memory, and provides accurate configuration retrieval to address the problems existing in current technologies. Summary of the Invention

[0004] In view of this, the purpose of this invention is to provide a data query method, apparatus, device, and storage medium that, upon receiving a request, can quickly determine the configuration data corresponding to the request using a preset hierarchical structure and data compression algorithm, compress the parameter data generated during the search process, and return the finally determined configuration data to the client to complete the data query. This allows for...

[0005] This effectively reduces data usage and improves data query efficiency. The specific solution is as follows:

[0006] Firstly, this application discloses a data query method applied to a server, including:

[0007] Determine whether the application configuration read request is being received for the first time. If so, retrieve the business data corresponding to the business category of the application configuration read request from the preset configuration center based on the application configuration read request.

[0008] Based on the business data, the preset hierarchical structure is rendered, and the rendered hierarchical structure is used to determine the configuration data coordinate parameters corresponding to the next application configuration read request.

[0009] The configuration data coordinate parameters are compressed using a preset compression algorithm, and a target request characteristic value corresponding to the configuration data coordinate parameters is generated based on the compressed data.

[0010] The configuration data corresponding to the next application configuration read request is determined by using preset data hit rules and the target request characteristic value, and the configuration data is returned to the client.

[0011] Optionally, determining whether an application configuration read request is being received for the first time, and if so, retrieving business data corresponding to the business category of the application configuration read request from a preset configuration center based on the application configuration read request, includes:

[0012] Determine whether the application configuration read request is received for the first time. If it is received for the first time, determine the business category of the application configuration read request and generate a business category determination result.

[0013] The application configuration read request is used to interact with the preset configuration center so that the preset configuration center can return the corresponding business data based on the business category.

[0014] Receive the business data returned by the preset configuration center and save the business data to the local cache.

[0015] Optionally, the step of determining whether an application configuration read request is being obtained for the first time, and if so, after obtaining business data corresponding to the business category of the application configuration read request from a preset configuration center based on the application configuration read request, further includes:

[0016] The configuration data corresponding to the application configuration read request is determined from the business data, and the configuration data corresponding to the application configuration read request is returned to the client.

[0017] Optionally, the step of rendering the preset hierarchical structure based on the business data and determining the configuration data coordinate parameters corresponding to the next application configuration read request using the rendered hierarchical structure includes:

[0018] The preset hierarchical structure is rendered using the business data to obtain the rendered hierarchical structure;

[0019] Determine whether a next application configuration read request has been received. If a next application configuration read request has been received, process the next application configuration read request using the rendered hierarchical structure to determine the configuration level corresponding to the next application configuration read request and generate configuration data coordinate parameters corresponding to the configuration level.

[0020] Optionally, the step of compressing the configuration data coordinate parameters using a preset compression algorithm and generating a target request characteristic value corresponding to the configuration data coordinate parameters based on the compressed data includes:

[0021] Generate a request characteristic value corresponding to the next application configuration read request based on the configuration data coordinate parameters;

[0022] The request characteristic value is verified using a bitmap, and a first verification return value is generated;

[0023] If the first verification returns false, the next application configuration read request corresponding to the configuration data coordinate parameter will interact with the preset configuration center to obtain new business data corresponding to the business category of the next application configuration read request.

[0024] If the first verification returns true, then the request characteristic value is verified again using the bitmap, and a second verification return value is generated.

[0025] If the second verification returns true, it indicates that a request feature value corresponding to the configuration data coordinate parameter already exists, and the configuration data corresponding to the request feature value is searched in the local cache using the request feature value.

[0026] If the second verification returns false, it indicates that the configuration data coordinate parameter does not have a request characteristic value. Then, the request characteristic value is recursively processed to obtain the target request characteristic value.

[0027] Optionally, the step of determining the configuration data corresponding to the next application configuration read request using preset data hitting rules and the target request characteristic value, and returning the configuration data to the client, includes:

[0028] Use the target request characteristic value to find the configuration data corresponding to the request characteristic value in the local cache;

[0029] If configuration data corresponding to the target request characteristic value is found in the local cache, the configuration data is returned to the client.

[0030] If the configuration data corresponding to the target request characteristic value cannot be found in the local cache, the configuration data corresponding to the target request characteristic value will be searched in the preset Redis using the target request characteristic value.

[0031] If configuration data corresponding to the target request characteristic value is found in the preset Redis, the configuration data is returned to the client;

[0032] If the configuration data corresponding to the target request characteristic value cannot be found in the preset Redis, the configuration data corresponding to the target request characteristic value in the preset configuration center is obtained through remote service call, and the configuration data is returned to the client.

[0033] Optionally, after obtaining the configuration data corresponding to the target request characteristic value in the preset configuration center through remote call service, the method further includes:

[0034] The configuration data obtained through the remote call service is synchronized to the local cache and the preset Redis, and the configuration data obtained through the remote call service is used to render the preset hierarchical structure.

[0035] Secondly, this application discloses a data query device applied to a server, comprising:

[0036] The business data acquisition module is used to determine whether the application configuration read request is obtained for the first time. If so, it retrieves business data corresponding to the business category of the application configuration read request from the preset configuration center based on the application configuration read request.

[0037] The coordinate parameter determination module is used to render the preset hierarchical structure based on the business data, and use the rendered hierarchical structure to determine the configuration data coordinate parameters corresponding to the next application configuration read request.

[0038] The feature value generation module is used to compress the configuration data coordinate parameters using a preset compression algorithm, and generate a target request feature value corresponding to the configuration data coordinate parameters based on the compressed data.

[0039] The configuration data return module is used to determine the configuration data corresponding to the next application configuration read request using preset data hit rules and the target request characteristic value, and return the configuration data to the client.

[0040] Thirdly, this application discloses an electronic device, including:

[0041] Memory, used to store computer programs;

[0042] A processor for executing the computer program to implement the data query method as described above.

[0043] Fourthly, this application discloses a computer-readable storage medium for storing computer programs.

[0044] The computer program, when executed by the processor, implements the data query method as described above.

[0045] In this application, it is first necessary to determine whether the application configuration read request is being received for the first time. If so, business data corresponding to the business category of the application configuration read request is obtained from the preset configuration center based on the application configuration read request. Then, the preset hierarchical structure is rendered based on the business data. The rendered hierarchical structure is used to determine the configuration data coordinate parameters corresponding to the next application configuration read request. The configuration data coordinate parameters are compressed using a preset compression algorithm. Based on the compressed data, a target request characteristic value corresponding to the configuration data coordinate parameters is generated. Finally, the configuration data corresponding to the next application configuration read request is determined using preset data hitting rules and the target request characteristic value, and the configuration data is returned to the client. Therefore, the data query algorithm described in this application can, upon receiving an application configuration request for the first time, obtain business data corresponding to the business category of the application configuration request using a preset configuration center, and render a preset hierarchical structure using the business data. Upon receiving the next application configuration request for the business category, the algorithm can quickly determine the configuration data corresponding to the next application configuration request using the preset hierarchical structure and a preset data compression algorithm, compress the parameter data generated during the search process, and return the final determined configuration data to the client to complete the data query. This effectively reduces data consumption and improves the efficiency of data query. Attached Figure Description

[0046] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on the provided drawings without creative effort.

[0047] Figure 1 A hierarchical structure diagram provided for this application;

[0048] Figure 2 A flowchart of a data query method provided in this application;

[0049] Figure 3 A flowchart illustrating a specific data query method provided in this application;

[0050] Figure 4 A sequence diagram of a data query method provided in this application;

[0051] Figure 5 A flowchart illustrating a specific data query method provided in this application;

[0052] Figure 6 A schematic diagram of a compression algorithm provided in this application;

[0053] Figure 7 A flowchart illustrating a specific data query method provided in this application;

[0054] Figure 8 A schematic diagram of a data query method provided in this application;

[0055] Figure 9 A schematic diagram of a data query device provided in this application;

[0056] Figure 10 This application provides a structural diagram of an electronic device. Detailed Implementation

[0057] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0058] In existing technologies, in scenarios with a large number of configuration items, SDKs generally cannot achieve local caching and need to rely on centralized services provided by configuration centers. If the number of applications is too large, it will put a lot of pressure on the configuration center. Configuration centers require very stringent stability, and failures will pose a great risk to the business. Furthermore, configuration centers generally provide services in a single-dimensional manner, and SDKs internally receive changes through local caching and long polling. However, the single-dimensional configuration of controllable configuration items cannot meet the requirements of complex business scenarios.

[0059] To overcome the aforementioned technical problems, this application provides a data query method, apparatus, device, and storage medium. Upon receiving a request, it can quickly determine the configuration data corresponding to the request using a preset hierarchical structure and data compression algorithm, compress the parameter data generated during the search process, and return the finally determined configuration data to the client to complete the data query. This can effectively reduce data usage and improve the efficiency of data query.

[0060] See Figure 2As shown, this embodiment of the invention discloses a data query method applied to a server, including:

[0061] Step S11: Determine whether the application configuration read request is obtained for the first time. If so, obtain the business data corresponding to the business category of the application configuration read request from the preset configuration center based on the application configuration read request.

[0062] In this embodiment, after receiving an application configuration request, it is necessary to determine the service category of the application configuration request. If the service category of the application configuration request is the first service category received, then it is necessary to interact with a preset configuration center using the application configuration request so that the configuration center can return service data corresponding to the service category of the application configuration request. For example, upon receiving a service configuration request...

[0063] For application configuration requests categorized as "service marketplace," it's necessary to determine if a similar request has been received before. If not, the request needs to interact with a pre-defined configuration center to retrieve data indicating a "service marketplace" business category. It's important to note that the configuration center is a platform providing unified management and services for business configurations. A business category is an abstract solution for a business scenario based on user needs. Depending on user requirements, the same business category can be reused, or different business categories can be configured differently, such as project procurement, online supermarkets, contract supply, service marketplaces, stadiums, and educational centers.

[0064] It should be further explained that after obtaining the business data corresponding to the business category of the application configuration read request from the preset configuration center based on the application configuration read request, the process further includes: determining the configuration data corresponding to the application configuration read request from the business data, and returning the configuration data corresponding to the application configuration read request to the client. That is, after obtaining the business data of the business category from the preset configuration center through the application configuration read request, it is necessary to return the configuration data corresponding to the application configuration read request to the client. The specific implementation method for determining the configuration data is as follows: saving the business data to a local cache, determining the configuration data corresponding to the application configuration read request from the business data, and returning the configuration data corresponding to the application configuration read request to the client.

[0065] Step S12: Render the preset hierarchical structure based on the business data, and use the rendered hierarchical structure to determine the configuration data coordinate parameters corresponding to the next application configuration read request.

[0066] In this embodiment, after obtaining the business data returned by the preset configuration center, it is necessary to use the business data to render the pre-established hierarchical structure to obtain the rendered hierarchical structure. It should be noted that without rendering the hierarchical structure using the business data, the hierarchical structure is empty, and the unrendered hierarchical structure cannot determine the configuration data corresponding to the application configuration read request. After obtaining the rendered hierarchical structure, it is necessary to determine whether the next application configuration read request of the same business category has been received. If so, the rendered hierarchical structure is used to process the next application configuration read request and determine the corresponding configuration data coordinate parameters. These parameters are then compressed, and the characteristic values ​​generated during the compression process are used to determine the corresponding configuration data. Furthermore, during a single business data query, a large number of application configuration read requests may be received, potentially reaching millions depending on the business volume. After rendering the hierarchical structure using the business data, each time an application configuration read request of the same business category is received, the rendered hierarchical structure can be used to render the hierarchical structure.

[0067] The structure enables rapid processing of requests, avoiding the need to interact with a pre-defined configuration center for each request. This hierarchical structure effectively improves the efficiency of data retrieval by processing application configuration read requests.

[0068] Step S13: Compress the configuration data coordinate parameters using a preset compression algorithm, and generate a target request characteristic value corresponding to the configuration data coordinate parameters based on the compressed data.

[0069] In this embodiment, the application configuration read request is processed using the post-rendered hierarchical structure, generating corresponding configuration data coordinate parameters. After obtaining these parameters, a request characteristic value corresponding to the next application configuration read request needs to be generated. Furthermore, data compression is achieved by locally caching the configuration data coordinate parameters, transforming them to obtain the corresponding request characteristic value, and reusing the characteristic value to achieve compression. It should be noted that the conversion of the configuration data coordinate parameters is achieved by generating corresponding characteristic values ​​based on the configuration data coordinate parameters. The reuse of characteristic values ​​is achieved by introducing a bitmap for verification. The specific implementation method of using a bitmap to verify characteristic values ​​is as follows: The request characteristic value is verified using a bitmap, and a first verification return value is generated. Based on the first verification return value, it is determined whether the corresponding business data exists locally. If it exists, the request characteristic value is verified again using the bitmap, and a second verification return value is generated. Based on the second return value, it is determined whether a request characteristic value corresponding to the configuration data coordinate parameters already exists. If it exists, the configuration data corresponding to the request characteristic value is searched in the local cache using the request characteristic value. If it does not exist, the request characteristic value is recursively processed to obtain the target request characteristic value. It should be noted that when the business volume reaches millions or tens of millions, the configuration data coordinate parameters will occupy a large amount of memory. Using a preset compression algorithm to compress the configuration data coordinate parameters can effectively alleviate memory pressure and improve the stability of the data query method described in this application.

[0070] Step S14: Determine the configuration data corresponding to the next application configuration read request using the preset data hit rules and the target request characteristic value, and return the configuration data to the client.

[0071] In this embodiment, after obtaining the target request characteristic value corresponding to the next application configuration read request, it is necessary to determine the configuration data corresponding to the next application configuration read request using the target request characteristic value. The specific implementation method for determining the configuration data using the preset data hit rule and the target request characteristic value is as follows: First, use the target request characteristic value to query the local cache for the configuration data corresponding to the target request characteristic value; if it can be found, then directly...

[0072] The system returns the retrieved configuration data to the client. If the data is not found, it queries a pre-configured Redis (RemoteDictionary Server) for the configuration data corresponding to the target requested feature value. If the data is found in the pre-configured Redis, it is returned to the client. If the data is still not found, it retrieves the configuration data corresponding to the target requested feature value from a pre-configured configuration center via a remote call service and returns it to the client. This effectively reduces interaction with the configuration center, alleviates its pressure, and avoids the scenario in the original technology where every configuration data query required interaction with the configuration center, potentially leading to configuration center crashes.

[0073] Therefore, in this embodiment, it is first necessary to determine whether the application configuration read request is being received for the first time. If so, business data corresponding to the business category of the application configuration read request is obtained from the preset configuration center based on the application configuration read request. Then, the preset hierarchical structure is rendered based on the business data. The rendered hierarchical structure is used to determine the configuration data coordinate parameters corresponding to the next application configuration read request. The configuration data coordinate parameters are compressed using a preset compression algorithm. Based on the compressed data, a target request characteristic value corresponding to the configuration data coordinate parameters is generated. Finally, the configuration data corresponding to the next application configuration read request is determined using preset data hitting rules and the target request characteristic value, and the configuration data is returned to the client. Therefore, the data query algorithm described in this application can, upon receiving an application configuration request for the first time, obtain business data corresponding to the business category of the application configuration request using a preset configuration center, and render a preset hierarchical structure using the business data. Upon receiving the next application configuration request for the business category, the algorithm can quickly determine the configuration data corresponding to the next application configuration request using the preset hierarchical structure and a preset data compression algorithm, compress the parameter data generated during the search process, and return the final determined configuration data to the client to complete the data query. This effectively reduces data consumption and improves the efficiency of data query.

[0074] As described in the previous embodiment, this application renders the hierarchical structure and uses the rendered hierarchical structure to process the received request. Therefore, this embodiment provides a detailed description of how to render the hierarchical structure and how to use the rendered hierarchical structure to generate configuration data coordinate parameters corresponding to the request. See [link to relevant documentation]. Figure 3 As shown, an embodiment of the present invention discloses a data query method, including:

[0075] Step S21: Determine whether the application configuration read request is received for the first time. If the application configuration read request is received for the first time, determine the service category of the application configuration read request to generate a service category determination result.

[0076] In this embodiment, after receiving an application configuration read request, it is necessary to determine the business category of the application configuration read request and whether it is the first time that an application configuration read request of the business category type has been received. For example, if an application configuration read request is received and it is determined that the business category of the application configuration read request is online supermarket, then the next step is to determine whether it is the first time that a request with the business category of online supermarket has been received, so as to generate the corresponding determination result.

[0077] Step S22: Interact with the preset configuration center using the application configuration read request so that the preset configuration center returns the corresponding business data based on the business category determination result.

[0078] In this embodiment, if it is determined that the result represents the first time that a request for the corresponding business category of the application configuration read request has been received, it is necessary to use the application configuration read request to interact with the preset configuration center so that the preset configuration center can return the business data of the corresponding business category.

[0079] Step S23: Receive the service data returned by the preset configuration center and save the service data to the local cache.

[0080] In this embodiment, after the preset configuration center returns the business data of the corresponding business category of the application configuration read request, it is necessary to receive the business data and save the business data to the local cache. In this way, the business data can be directly called from the local cache when needed later, avoiding re-interaction with the preset configuration center, effectively reducing the number of interactions with the configuration center and effectively alleviating the pressure on the configuration center.

[0081] Step S24: Render the preset hierarchical structure using the business data to obtain the rendered hierarchical structure.

[0082] In this embodiment, as Figure 4 As shown, the preset hierarchical structure is an empty structure when no business data is used for rendering. After rendering the preset hierarchical structure using locally cached business data, corresponding data can be added to different levels in the preset hierarchical structure to obtain the rendered hierarchical structure. It should be noted that the hierarchical structure is rendered step by step during each request.

[0083] Step S25: Determine whether a next application configuration read request has been received. If a next application configuration read request has been received, process the next application configuration read request using the rendered hierarchical structure to determine the configuration level corresponding to the next application configuration read request and generate configuration data coordinate parameters corresponding to the configuration level.

[0084] In this embodiment, after rendering the preset hierarchical structure using business data, the rendered hierarchical structure can be used to process the next application configuration read request of the same business category.

[0085] Therefore, after obtaining the rendered hierarchical structure, it is necessary to determine whether a next application configuration read request has been received. If so, the rendered hierarchical structure can be used to process the next application configuration read request. During processing, it is necessary to determine whether the next application configuration read request has configuration at a specified level. If configuration exists, configuration data coordinate parameters corresponding to the next application configuration read request are generated. For example, combined with... Figure 4 As shown, if the next application configuration read request specifies a level with configuration, then the isConfig of that level is 1, the isConfig of the offline level of that level is 0, and the isConfig of the online level of that level is -1. The isConfig value can take three values: 0 (no configuration at that level), -1 (unknown configuration at that level), and 1 (configuration at that level). If the business category of the next application configuration read request is "NetSuper"; the business instance is "Zhejiang NetSuper"; the district is "Hangzhou"; and the organization is "Hangzhou A Company", then when processing the next application configuration read request using the rendered hierarchical structure, there may be five cases. The first case returns a configuration value at the organization level, and the generated configuration data coordinate parameters are [1:-1]. [2:-1],[3:-1],[4:-1],[5:1]; The second case returns a configuration value level of zone-level configuration, and the generated configuration data coordinate parameters are [1:-1],[2:-1],[3:-1],[4:1],[5:0]; The third case returns a configuration value level of instance-level configuration, and the generated configuration data coordinate parameters are [1:-1],[2:-1],[3:1],[4:0],[5:0]; The fourth case returns a configuration value level of category-level configuration, and the returned configuration value level is instance-level configuration [1:-1],[2:1],[3:0],[4:0],[5:0]; The fifth case returns a configuration value level of platform-level configuration, and the tree will be automatically rendered as [1:1],[2:0],[3:0],[4:0],[5:0].

[0086] Step S26: Compress the configuration data coordinate parameters using a preset compression algorithm, and generate a target request characteristic value corresponding to the configuration data coordinate parameters based on the compressed data.

[0087] Step S27: Determine the configuration data corresponding to the next application configuration read request using the preset data hit rules and the target request characteristic value, and return the configuration data to the client.

[0088] It should be noted that for a more detailed explanation of steps S26 and S27 in this embodiment, please refer to the foregoing embodiments, and they will not be repeated here.

[0089] Therefore, in this embodiment, after determining that an application configuration read request has been received for the first time, it is necessary to interact with a preset configuration center using the application configuration read request. The preset configuration center then returns corresponding business data based on the business category determination result, and uses this business data to render a preset hierarchical structure. This rendered hierarchical structure is then used to process the next received application configuration read request and generate corresponding configuration data coordinate parameters. In this way, by processing the received request through the hierarchical structure, the generated configuration data coordinate parameters can be used to configure the data.

[0090] This allows for rapid location tracking, effectively improving data retrieval efficiency.

[0091] As can be seen from the previous embodiment, in this application, the request can be processed through the rendered hierarchical structure to obtain the corresponding configuration data coordinate parameters. However, when the request volume is large, the memory consumption of the parameter data is also large. Therefore, it is necessary to use a preset compression algorithm to compress the configuration data coordinate parameters. For this reason, this embodiment describes in detail how to use a preset compression algorithm to compress the configuration data coordinate parameters. See [link to documentation]. Figure 5 As shown, an embodiment of the present invention discloses a data query method, including:

[0092] Step S31: Determine whether the application configuration read request is obtained for the first time. If so, obtain the business data corresponding to the business category of the application configuration read request from the preset configuration center based on the application configuration read request.

[0093] Step S32: Render the preset hierarchical structure based on the business data, and use the rendered hierarchical structure to determine the configuration data coordinate parameters corresponding to the next application configuration read request.

[0094] Step S33: Generate a request characteristic value corresponding to the next application configuration read request based on the configuration data coordinate parameters.

[0095] In this embodiment, after obtaining the corresponding configuration data coordinate parameters generated by the rendered hierarchical structure based on the next application configuration read request, and quickly locating the configuration data, as follows: Figure 6 As shown, based on the generated configuration data coordinate parameters and the rendered hierarchical structure, the configuration corresponding to the next application configuration read request needs to be processed using a preset compression algorithm to generate the corresponding request characteristic value. For example, if the business category of the next application configuration read request is "NetSuper"; the business instance is "Zhejiang NetSuper"; the region is "Hangzhou"; and the organization is "Hangzhou A Company", then a three-digit long integer 002 is generated by incrementing from 2 according to the business category type; a three-digit long integer 001 is generated by incrementing from 1 according to the business instance type; a five-digit long integer 00001 is generated by incrementing from 1 according to the region type; and a six-digit long integer 000001 is generated by incrementing from 1 according to the organization type. It should be noted that there may be hundreds of business categories and business instances, which need to be represented by three-digit long integers; tens of thousands of region types, which need to be represented by five-digit long integers; and hundreds of thousands of organization types, which need to be represented by six-digit long integers. After generating the corresponding long integers, they need to be concatenated according to the hierarchy to generate the corresponding request characteristic values. For example, the request characteristic value generated based on the above process is 200100001000001. In this way, using the generated request characteristic value to find the configuration data of the application configuration read request can effectively reduce memory usage due to the small memory footprint of long integers.

[0096] Step S34: Verify the requested characteristic value using a bitmap and generate a first verification return value.

[0097] In this embodiment, a bitmap is used to verify the request characteristic value and generate a first verification return value. That is, after generating the characteristic value corresponding to the next application configuration read request, the characteristic value needs to be verified to determine whether it is necessary to interact with the preset configuration center based on the next application configuration read request, and whether it is necessary to query the corresponding configuration data based on the request characteristic value corresponding to the next application configuration read request.

[0098] Step S35: If the first verification return value is false, then the next application configuration read request corresponding to the configuration data coordinate parameter will interact with the preset configuration center to obtain new business data corresponding to the business category of the next application configuration read request.

[0099] In this embodiment, if the request characteristic value is verified based on the bitmap and the generated first verification return value is false, it indicates that the request for the next application configuration read request business category has been received for the first time, and the preset hierarchical structure has not been rendered by the business data corresponding to the business category. In this case, it is necessary to use the next application configuration read request to interact with the preset configuration center so that the configuration center can return the corresponding business data to obtain new business data corresponding to the business category of the next application configuration read request. The preset hierarchical structure is then rendered using the business data so that when an application configuration read request of the same business category is received, the rendered hierarchical structure can be used for processing.

[0100] Step S36: If the first verification return value is true, then the request characteristic value is verified again using bitmap, and a second verification return value is generated.

[0101] In this embodiment, if the request characteristic value is verified based on the bitmap and the generated first verification return value is true, it indicates that a request with the service category of the next application configuration read request has been received, and the request characteristic value needs to be verified again using the bitmap, so as to determine whether the request return value needs to be recursively processed according to the generated second verification return value.

[0102] Step S37: If the second verification returns true, it indicates that a request characteristic value corresponding to the configuration data coordinate parameter already exists, and the configuration data corresponding to the request characteristic value is searched in the local cache using the request characteristic value.

[0103] In this embodiment, if the request characteristic value is verified based on the bitmap and the generated second verification return value is true, it indicates that the next application configuration read request has configuration, and the corresponding configuration data can be directly found in the local cache using the request characteristic value.

[0104] Step S38: If the second verification returns false, it indicates that the configuration data coordinate parameter does not have a request characteristic value. Then, the request characteristic value is recursively processed to obtain the target request characteristic value.

[0105] In this embodiment, if the request characteristic value is verified based on the bitmap and the generated second verification return value is false, it indicates that the next application configuration read request is not configured. The request characteristic value needs to be recursively processed, and the corresponding configuration data is searched in the local cache based on the target characteristic value obtained after processing. It should be noted that the generation of the target characteristic value requires a recursive algorithm to verify the request characteristic value level by level according to the configuration hierarchy, stopping when a configured or unknown value is encountered. For example, using a recursive algorithm to verify the request characteristic value 200100001000001, if it is not configured at the organization level, it returns 200100001000001 and verifies at the zone level. If it is not configured at the zone level, it returns 200100001000000 and verifies at the instance level. If it is not configured at the instance level, it returns 200100000. The system checks if the configuration is configured at the category level (e.g., 000000) and performs validation at the category level. If it is configured at the category level, validation stops, and the system searches for the corresponding configuration data in the local cache using the value 200100000000000. If it is not configured at the category level, the system returns 2000000000000000 and performs validation at the platform level. It should be noted that the configuration is always configured at the platform level, and the system will return 1000000000000000. The system searches for the corresponding configuration data in the local cache using the characteristic value 100000000000000 and returns all business data.

[0106] Step S39: Determine the configuration data corresponding to the next application configuration read request using the preset data hit rules and the target request characteristic value, and return the configuration data to the client.

[0107] It should be noted that for more detailed explanations of steps S31, S32, and S39, please refer to the foregoing embodiments, and will not be repeated here.

[0108] Therefore, in this embodiment, after obtaining the configuration data coordinate parameters, it is necessary to transform the configuration data coordinate parameters to obtain the corresponding request characteristic values, and reuse the characteristic values ​​to achieve the compression effect. As a result, when the business volume reaches millions or tens of millions, the configuration data coordinate parameters will occupy a large amount of memory. Using a preset compression algorithm to compress the configuration data coordinate parameters can effectively alleviate the memory occupation pressure and improve the stability of the data query method described in this application.

[0109] As can be seen from the previous embodiment, after obtaining the target request characteristic value, this application needs to use the request characteristic value to query the corresponding configuration data. Therefore, this embodiment provides a detailed description of how to use the target characteristic value to query the corresponding configuration data. See [link to relevant documentation]. Figure 7 As shown, an embodiment of the present invention discloses a

[0110] Methods for querying the number of species include:

[0111] Step S41: Determine whether the application configuration read request is obtained for the first time. If so, obtain the business data corresponding to the business category of the application configuration read request from the preset configuration center based on the application configuration read request.

[0112] Step S42: Render the preset hierarchical structure based on the business data, and use the rendered hierarchical structure to determine the configuration data coordinate parameters corresponding to the next application configuration read request.

[0113] Step S43: Compress the configuration data coordinate parameters using a preset compression algorithm, and generate a target request characteristic value corresponding to the configuration data coordinate parameters based on the compressed data.

[0114] Step S44: Use the target request characteristic value to find the configuration data corresponding to the request characteristic value in the local cache.

[0115] In this embodiment, as Figure 8 As shown, after obtaining the business data for the first time, the business data needs to be saved to the local cache. After obtaining the target request characteristic value, the configuration data corresponding to the next application configuration read request needs to be determined from the business data in the local cache using the target request characteristic value.

[0116] Step S45: If configuration data corresponding to the target request characteristic value is found in the local cache, the configuration data is returned to the client.

[0117] In this embodiment, if configuration data corresponding to the target request characteristic value is found in the local cache, the configuration data is returned to the client. That is, if configuration data corresponding to the next application configuration read request can be found in the locally cached business data using the target request characteristic value, the found configuration data can be directly returned to the client, and the query process ends.

[0118] Step S46: If the configuration data corresponding to the target request characteristic value cannot be found in the local cache, then the configuration data corresponding to the target request characteristic value is searched in the preset Redis using the target request characteristic value.

[0119] In this embodiment, if the configuration data corresponding to the next application configuration read request cannot be found in the locally cached business data using the target request characteristic value, then the configuration data corresponding to the target request characteristic value needs to be found in a preset Redis using the target request characteristic value.

[0120] Step S47: If configuration data corresponding to the target request characteristic value is found in the preset Redis, the configuration data is returned to the client.

[0121] In this embodiment, if the configuration data corresponding to the target request characteristic value can be found in a preset Redis, the found configuration data can be directly returned to the client, and the query process can be ended.

[0122] Step S48: If the configuration data corresponding to the target request characteristic value cannot be found in the preset Redis, the configuration data corresponding to the target request characteristic value in the preset configuration center is obtained through remote call service, and the configuration data is returned to the client.

[0123] In this embodiment, if the configuration data corresponding to the target request feature value cannot be found in either the local cache or the preset Redis, it indicates that the configuration data for the next application configuration read request corresponding to the target request feature value may have been updated in the preset configuration center, but has not yet been synchronized to the local cache and the preset Redis. It is necessary to use the remote call service to obtain the configuration data corresponding to the target request feature value in the preset configuration center, and after receiving the configuration data, return the relevant configuration data to the client and end the data query.

[0124] It should be noted that after obtaining the configuration data corresponding to the target request characteristic value from the preset configuration center through the remote call service, the process further includes: synchronizing the configuration data obtained through the remote call service to the local cache and the preset Redis, and using the configuration data obtained through the remote call service to perform data rendering on the preset hierarchical structure. That is, after obtaining the configuration data returned by the preset configuration center through the remote call service, the configuration data needs to be synchronized to the local cache and the preset Redis so that the configuration data can be retrieved in the local cache or the preset Redis during the next data query. Furthermore, after obtaining the configuration data returned by the preset configuration center, the preset hierarchical structure needs to be refreshed using the configuration data, i.e., data rendering is performed.

[0125] It should be noted that for more detailed explanations of steps S41, S42, and S43, please refer to the foregoing embodiments, and will not be repeated here.

[0126] Therefore, in this embodiment, after obtaining the request characteristic value, the system can use the target request characteristic value to search for configuration data corresponding to the request characteristic value in the local cache. If the configuration data corresponding to the target request characteristic value is found in the local cache, the configuration data is returned to the client. If the configuration data corresponding to the target request characteristic value is not found in the local cache, the system uses the target request characteristic value to search for configuration data corresponding to the target request characteristic value in a preset Redis. If the configuration data corresponding to the target request characteristic value is found in the preset Redis, the configuration data is returned to the client. If the configuration data is not found in the preset Redis...

[0127] The configuration data corresponding to the target request characteristic value is obtained from the preset configuration center through remote service invocation, and the configuration data is returned to the client. In this way, by determining the configuration data through preset data matching rules, the accuracy of the retrieved configuration data is effectively improved, thus enhancing the reliability of the data query method described in this application.

[0128] See Figure 9 As shown in the figure, an embodiment of the present invention discloses a data query device applied to a server, comprising:

[0129] The business data acquisition module 11 is used to determine whether the application configuration read request is obtained for the first time. If so, it obtains business data corresponding to the business category of the application configuration read request from the preset configuration center based on the application configuration read request.

[0130] The coordinate parameter determination module 12 is used to perform data rendering on the preset hierarchical structure based on the business data, and to determine the configuration data coordinate parameters corresponding to the next application configuration read request using the rendered hierarchical structure.

[0131] The feature value generation module 13 is used to compress the configuration data coordinate parameters using a preset compression algorithm, and generate a target request feature value corresponding to the configuration data coordinate parameters based on the compressed data.

[0132] The configuration data return module 14 is used to determine the configuration data corresponding to the next application configuration read request using preset data hit rules and the target request characteristic value, and return the configuration data to the client.

[0133] Therefore, in this embodiment, it is first necessary to determine whether an application configuration read request is being received for the first time. If so, business data corresponding to the business category of the application configuration read request is obtained from a preset configuration center based on the application configuration read request. Then, based on the business data, a preset hierarchical structure is rendered. The rendered hierarchical structure is used to determine the configuration data coordinate parameters corresponding to the next application configuration read request. The configuration data coordinate parameters are compressed using a preset compression algorithm. Based on the compressed data, a target request characteristic value corresponding to the configuration data coordinate parameters is generated. Finally, the configuration data corresponding to the next application configuration read request is determined using preset data hitting rules and the target request characteristic value, and the configuration data is returned to the client. Thus, the data query algorithm described in this application can, after receiving the application configuration request for the first time, obtain business data corresponding to the business category of the application configuration request from a preset configuration center, and utilize the preset data to obtain business data corresponding to the business category of the application configuration request from a preset configuration center.

[0134] The business data is rendered according to a preset hierarchical structure so that after receiving the next application configuration request for the business category, the preset hierarchical structure and preset data compression algorithm are used to quickly determine the configuration data corresponding to the next application configuration request. The parameter data generated during the search process is compressed, and the finally determined configuration data is returned to the client to complete the data query. In this way, data consumption can be effectively reduced and the efficiency of data query can be improved.

[0135] In some embodiments, the form determination module 11 may specifically include:

[0136] The business category determination unit is used to determine whether the application configuration read request is received for the first time. If the application configuration read request is received for the first time, the business category of the application configuration read request is determined to generate a business category determination result.

[0137] The data interaction unit is used to interact with the preset configuration center using the application configuration read request, so that the preset configuration center returns the corresponding business data based on the business category determination result;

[0138] The data storage unit is used to receive the business data returned by the preset configuration center and save the business data to the local cache.

[0139] In some embodiments, the data query device may further include:

[0140] The first data return unit is used to determine the configuration data corresponding to the application configuration read request from the business data, and return the configuration data corresponding to the application configuration read request to the client.

[0141] In some embodiments, the coordinate parameter determination module 12 may specifically include:

[0142] A hierarchical rendering unit is used to render the preset hierarchical structure using the business data to obtain the rendered hierarchical structure.

[0143] The parameter generation unit is used to determine whether a next application configuration read request has been received. If a next application configuration read request has been received, the next application configuration read request is processed using the rendered hierarchical structure to determine the configuration level corresponding to the next application configuration read request and generate configuration data coordinate parameters corresponding to the configuration level.

[0144] In some embodiments, the feature value generation module 13 may specifically include:

[0145] The first feature value generation unit is used to generate a request feature value corresponding to the next application configuration read request based on the configuration data coordinate parameters.

[0146] The first return value generation unit is used to verify the request characteristic value using a bitmap and generate a first verification return value.

[0147] The first data acquisition unit is configured to, if the first verification return value is false, interact with the preset configuration center with the next application configuration read request corresponding to the configuration data coordinate parameter to obtain new business data corresponding to the business category of the next application configuration read request.

[0148] The second return value generation unit is used to verify the request characteristic value again using bitmap if the first verification return value is true, and generate a second verification return value.

[0149] The second data acquisition unit is used to indicate that a request feature value corresponding to the configuration data coordinate parameter already exists if the second verification return value is true, and to use the request feature value to search for the configuration data corresponding to the request feature value in the local cache;

[0150] The first feature value generation unit is used to recursively process the request feature value to obtain the target request feature value if the second verification return value is false, indicating that the configuration data coordinate parameter does not have a request feature value.

[0151] In some embodiments, the configuration data return module 14 may specifically include:

[0152] The first data lookup unit is used to look up configuration data corresponding to the target request characteristic value in the local cache.

[0153] The second data return unit is used to return the configuration data to the client if the configuration data corresponding to the target request characteristic value is found in the local cache.

[0154] The second data lookup unit is used to look up configuration data corresponding to the target request characteristic value in a preset Redis if the configuration data corresponding to the target request characteristic value cannot be found in the local cache.

[0155] The third data return unit is used to return the configuration data to the client if the configuration data corresponding to the requested characteristic value is found in the preset Redis.

[0156] The fourth data return unit is used to obtain the configuration data corresponding to the target request characteristic value from the preset configuration center through remote call service if the configuration data corresponding to the target request characteristic value cannot be found in the preset Redis, and then return the configuration data to the client.

[0157] In some embodiments, the data query device may further include:

[0158] The configuration data storage module is used to synchronize the configuration data obtained through the remote call service to the local cache and the preset Redis, and to use the configuration data obtained through the remote call service to perform data rendering on the preset hierarchical structure.

[0159] Furthermore, embodiments of this application also disclose an electronic device, Figure 10 It is based on an example

[0160] The schematic diagram of the electronic device 20 shown in the embodiment is not intended to limit the scope of this application.

[0161] Figure 10 This is a schematic diagram of the structure of an electronic device 20 provided in an embodiment of this application. Specifically, the electronic device 20 may include: at least one processor 21, at least one memory 22, a power supply 23, a communication interface 24, an input / output interface 25, and a communication bus 26. The memory 22 stores a computer program, which is loaded and executed by the processor 21 to implement the relevant steps in the data query method disclosed in any of the foregoing embodiments. Furthermore, the electronic device 20 in this embodiment may specifically be an electronic computer.

[0162] In this embodiment, the power supply 23 is used to provide operating voltage for each hardware device on the electronic device 20; the communication interface 24 can create a data transmission channel between the electronic device 20 and external devices, and the communication protocol it follows can be any communication protocol applicable to the technical solution of this application, and is not specifically limited here; the input / output interface 25 is used to acquire external input data or output data to the outside world, and its specific interface type can be selected according to specific application needs, and is not specifically limited here.

[0163] In addition, the memory 22, as a carrier for resource storage, can be a read-only memory, random access memory, disk or optical disk, etc. The resources stored thereon can include operating system 221, computer program 222, etc., and the storage method can be temporary storage or permanent storage.

[0164] The operating system 221 is used to manage and control the various hardware devices on the electronic device 20 and the computer program 222, which may be Windows Server, Netware, Unix, Linux, etc. In addition to including a computer program capable of performing the data query method executed by the electronic device 20 as disclosed in any of the foregoing embodiments, the computer program 222 may further include a computer program capable of performing other specific tasks.

[0165] Furthermore, this application also discloses a computer-readable storage medium for storing a computer program; wherein, when the computer program is executed by a processor, it implements the aforementioned disclosed data query method. The specific steps of this method can be found in the corresponding content disclosed in the foregoing embodiments, and will not be repeated here.

[0166] The various embodiments in this specification are described in a progressive manner, with each embodiment focusing on its differences from other embodiments. Similar or identical parts between embodiments can be referred to interchangeably. For the apparatus disclosed in the embodiments, since it corresponds to the method disclosed in the embodiments, the description is relatively simple; relevant parts can be referred to in the method section.

[0167] Those skilled in the art will further recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of both. To clearly illustrate the interchangeability of hardware and software, the components and steps of the various examples have been generally described in terms of functionality in the foregoing description. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.

[0168] The steps of the methods or algorithms described in conjunction with the embodiments disclosed herein can be implemented directly by hardware, a software module executed by a processor, or a combination of both. The software module can be located in random access memory (RAM), main memory, read-only memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disk, removable disk, CD-ROM, or any other form of storage medium known in the art.

[0169] Finally, it should be noted that in this document, relational terms such as "first" and "second" are used only to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.

[0170] The technical solutions provided in this application have been described in detail above. Specific examples have been used to illustrate the principles and implementation methods of this application. The descriptions of the above embodiments are only for the purpose of helping to understand the methods and core ideas of this application. At the same time, for those skilled in the art, there will be changes in the specific implementation methods and application scope based on the ideas of this application. Therefore, the content of this specification should not be construed as a limitation of this application.

Claims

1. A data query method, characterized in that, Applied to the server side, including: Determine whether the application configuration read request is being received for the first time. If so, retrieve the business data corresponding to the business category of the application configuration read request from the preset configuration center based on the application configuration read request. The preset hierarchical structure is rendered based on the business data, and the rendered hierarchical structure is used to determine the configuration data coordinate parameters corresponding to the next application configuration read request; the preset hierarchical structure is a hierarchical structure that includes hierarchical relationships. The configuration data coordinate parameters are compressed using a preset compression algorithm, and a target request characteristic value corresponding to the configuration data coordinate parameters is generated based on the compressed data. The configuration data corresponding to the next application configuration read request is determined by using preset data hit rules and the target request characteristic value, and the configuration data is returned to the client; The step of rendering the preset hierarchical structure based on the business data and determining the configuration data coordinate parameters corresponding to the next application configuration read request using the rendered hierarchical structure includes: The preset hierarchical structure is rendered using the business data to obtain the rendered hierarchical structure; Determine whether a next application configuration read request has been received. If a next application configuration read request has been received, process the next application configuration read request using the rendered hierarchical structure to determine the configuration level corresponding to the next application configuration read request and generate configuration data coordinate parameters corresponding to the configuration level. The step of compressing the configuration data coordinate parameters using a preset compression algorithm and generating a target request characteristic value corresponding to the configuration data coordinate parameters based on the compressed data includes: Generate a request characteristic value corresponding to the next application configuration read request based on the configuration data coordinate parameters; The request characteristic value is verified using a bitmap, and a first verification return value is generated; If the first verification returns false, the next application configuration read request corresponding to the configuration data coordinate parameter will interact with the preset configuration center to obtain new business data corresponding to the business category of the next application configuration read request. If the first verification returns true, then the request characteristic value is verified again using the bitmap, and a second verification return value is generated. If the second verification returns true, it indicates that a request feature value corresponding to the configuration data coordinate parameter already exists, and the configuration data corresponding to the request feature value is searched in the local cache using the request feature value. If the second verification returns false, it indicates that the configuration data coordinate parameter does not have a request characteristic value. Then, the request characteristic value is recursively processed to obtain the target request characteristic value.

2. The data query method according to claim 1, characterized in that, The determination of whether an application configuration read request is received for the first time, and if so, the process of obtaining business data corresponding to the business category of the application configuration read request from a preset configuration center based on the application configuration read request, includes: Determine whether the application configuration read request is received for the first time. If it is received for the first time, determine the business category of the application configuration read request and generate a business category determination result. The application configuration read request is used to interact with the preset configuration center so that the preset configuration center can return the corresponding business data based on the business category. Receive the business data returned by the preset configuration center and save the business data to the local cache.

3. The data query method according to claim 2, characterized in that, The step of determining whether an application configuration read request is being received for the first time, and if so, then after obtaining business data corresponding to the business category of the application configuration read request from the preset configuration center based on the application configuration read request, further includes: The configuration data corresponding to the application configuration read request is determined from the business data, and the configuration data corresponding to the application configuration read request is returned to the client.

4. The data query method according to claim 1, characterized in that, The step of determining the configuration data corresponding to the next application configuration read request using preset data hitting rules and the target request characteristic value, and returning the configuration data to the client, includes: Use the target request characteristic value to find the configuration data corresponding to the request characteristic value in the local cache; If configuration data corresponding to the target request characteristic value is found in the local cache, the configuration data is returned to the client. If the configuration data corresponding to the target request characteristic value cannot be found in the local cache, the configuration data corresponding to the target request characteristic value will be searched in the preset Redis using the target request characteristic value. If configuration data corresponding to the target request characteristic value is found in the preset Redis, the configuration data is returned to the client; If the configuration data corresponding to the target request characteristic value cannot be found in the preset Redis, the configuration data corresponding to the target request characteristic value in the preset configuration center is obtained through remote service call, and the configuration data is returned to the client.

5. The data query method according to claim 4, characterized in that, After obtaining the configuration data corresponding to the target request characteristic value from the preset configuration center through remote call service, the method further includes: The configuration data obtained through the remote call service is synchronized to the local cache and the preset Redis, and the configuration data obtained through the remote call service is used to render the preset hierarchical structure.

6. A data query device, characterized in that, Applied to the server side, including: The business data acquisition module is used to determine whether the application configuration read request is obtained for the first time. If so, it retrieves business data corresponding to the business category of the application configuration read request from the preset configuration center based on the application configuration read request. The coordinate parameter determination module is used to render the preset hierarchical structure based on the business data, and use the rendered hierarchical structure to determine the configuration data coordinate parameters corresponding to the next application configuration read request; the preset hierarchical structure is a hierarchical structure containing hierarchical relationships; The feature value generation module is used to compress the configuration data coordinate parameters using a preset compression algorithm, and generate a target request feature value corresponding to the configuration data coordinate parameters based on the compressed data. The configuration data return module is used to determine the configuration data corresponding to the next application configuration read request using preset data hit rules and the target request characteristic value, and return the configuration data to the client; The coordinate parameter determination module includes: A hierarchical rendering unit is used to render the preset hierarchical structure using the business data to obtain the rendered hierarchical structure. The parameter generation unit is used to determine whether a next application configuration read request has been received. If a next application configuration read request has been received, the next application configuration read request is processed using the rendered hierarchical structure to determine the configuration level corresponding to the next application configuration read request and generate configuration data coordinate parameters corresponding to the configuration level. The feature value generation module includes: The first feature value generation unit is used to generate a request feature value corresponding to the next application configuration read request based on the configuration data coordinate parameters. The first return value generation unit is used to verify the request characteristic value using a bitmap and generate a first verification return value. The first data acquisition unit is configured to, if the first verification return value is false, interact with the preset configuration center with the next application configuration read request corresponding to the configuration data coordinate parameter to obtain new business data corresponding to the business category of the next application configuration read request. The second return value generation unit is used to verify the request characteristic value again using bitmap if the first verification return value is true, and generate a second verification return value. The second data acquisition unit is used to indicate that a request feature value corresponding to the configuration data coordinate parameter already exists if the second verification return value is true, and to use the request feature value to search for the configuration data corresponding to the request feature value in the local cache; The first feature value generation unit is used to recursively process the request feature value to obtain the target request feature value if the second verification return value is false, indicating that the configuration data coordinate parameter does not have a request feature value.

7. An electronic device, characterized in that, include: Memory, used to store computer programs; A processor for executing the computer program to implement the data query method as described in any one of claims 1 to 5.

8. A computer-readable storage medium, characterized in that, Used to store a computer program, which, when executed by a processor, implements the data query method as described in any one of claims 1 to 5.

Citation Information

Patent Citations

  • Data caching method and device, electronic equipment and storage medium

    CN114490521A

  • Service request processing method and device, electronic equipment and storage medium

    CN114629883A