Resource management method, system and device, electronic equipment and storage medium

By querying the target URL and version information in the heap cache, generating key-value pairs, and retrieving resource files from the off-heap cache, combined with the synchronization mechanism of the configuration server cluster, the timeliness problem when web application versions change is solved, and real-time and efficient resource management is achieved.

CN117131295BActive Publication Date: 2025-12-16BEIJING WODONG TIANJUN INFORMATION TECH CO LTD +1
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202210546738.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-05-18
Publication Date
2025-12-16
Estimated Expiration
2042-05-18

AI Technical Summary

Technical Problem

Existing resource management methods for web applications are not timely enough when versions change, resulting in low efficiency in version rollback.

Method used

By querying the target URL and version information in the heap cache, target key-value pair information is generated, and resource files are obtained from the off-heap cache. Combined with the information synchronization mechanism of the configuration server cluster, the cache is updated in real time to support the launch of new versions or rollback.

Benefits of technology

It improves the response speed of web application browsing requests, ensures the real-time performance of resource file management, and overcomes the timeliness issues when versions change.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117131295B_ABST
    Figure CN117131295B_ABST
Patent Text Reader

Abstract

The present disclosure provides a resource management method, system, device, electronic equipment and storage medium, which can be applied to the technical field of Internet. The method comprises: in response to a browsing request for a first target application, obtaining target website information carried in the browsing request; based on the target website information, querying a plurality of configuration information stored in an in-heap cache to determine target version information of the first target application, wherein the plurality of configuration information is obtained from a configuration server cluster by executing an information synchronization instruction; based on the target website information and the target version information, determining target key-value pair information; and based on the target key-value pair information, obtaining a resource file of the first target application from an out-of-heap cache.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present disclosure relates to the technical field of Internet, and more particularly, to a resource management method, system, device, electronic device and storage medium. BACKGROUND

[0002] With the development of Internet technology, more and more enterprises use front-end and back-end separation technology to develop web applications. In the related art, after the development of a web application is completed, the source code is usually packaged as a static resource file and stored, and a proxy server or a content distribution network is used to manage and call the static resource file.

[0003] In the process of implementing the present disclosure, the inventors found that the resource management method in the related art has poor timeliness when the version of a web application changes. SUMMARY

[0004] Therefore, the present disclosure provides a resource management method, a resource management device, an electronic device, a readable storage medium and a computer program product.

[0005] One aspect of the present disclosure provides a resource management method, comprising: in response to a browsing request for a first target application, obtaining target URL information carried in the browsing request; based on the target URL information, querying a plurality of configuration information stored in an in-memory cache to determine target version information of the first target application, wherein the plurality of configuration information is obtained from a configuration server cluster by executing an information synchronization instruction; based on the target URL information and the target version information, determining target key-value pair information; and based on the target key-value pair information, obtaining a resource file of the first target application from an out-of-memory cache.

[0006] According to an embodiment of the present disclosure, the configuration information includes URL information and version information; wherein the querying, based on the target URL information, the plurality of configuration information stored in the in-memory cache to determine the target version information of the first target application, comprises: matching the target URL information with the URL information in the plurality of configuration information respectively to determine first target configuration information matched with the target URL information; and determining the target version information based on the version information in the first target configuration information.

[0007] According to an embodiment of the present disclosure, the target URL information includes domain name information and a resource identifier; the method further includes: determining a domain name type of the domain name information based on the domain name information, wherein the domain name type includes a custom domain name and a general domain name; and wherein the querying, based on the target URL information, the plurality of configuration information stored in the in-memory cache to determine the target version information of the first target application includes: in a case where the domain name type of the domain name information is determined to be the custom domain name, querying the plurality of configuration information based on the domain name information to determine the target version information; and in a case where the domain name type of the domain name information is determined to be the general domain name, querying the plurality of configuration information based on the domain name information and the resource identifier to determine the target version information.

[0008] According to an embodiment of the present disclosure, the plurality of configuration information includes being obtained from the configuration server cluster by executing an information synchronization instruction, including: listening to the configuration server cluster; in a case where it is detected that the configuration server cluster triggers a configuration change event, determining second target configuration information that has changed; and executing the information synchronization instruction to obtain the second target configuration information from the configuration server cluster.

[0009] According to an embodiment of the present disclosure, the method further includes: in a case where the resource file of the first target application does not exist in the off-heap cache, determining a target folder in the cloud storage based on the target key-value pair information; reading the resource file of the first target application from the target folder; and storing the resource file of the first target application in the off-heap cache.

[0010] According to an embodiment of the present disclosure, the method further includes: when storing the resource file of the first target application in the off-heap cache, setting an expiration condition for the resource file of the first target application, so as to delete the resource file of the first target application in the off-heap cache in a case where the expiration condition is met.

[0011] Another aspect of the present disclosure provides a resource management method, including: generating a browsing request for a first target application based on target URL information; and sending the browsing request to a response server cluster, so that the response server cluster, in response to the browsing request, queries a plurality of configuration information stored in an in-memory cache based on the target URL information to determine target version information of the first target application, and determines target key-value pair information based on the target URL information and the target version information, and further obtains a resource file of the first target application from an off-heap cache based on the target key-value pair information, wherein the plurality of configuration information includes being obtained from a configuration server cluster by the response server cluster through an information synchronization instruction.

[0012] According to an embodiment of the present disclosure, the method further includes: in response to a version release request, determining a second target application associated with the version release request and version information of a to-be-released version of the second target application; determining third target configuration information associated with the second target application in the configuration server cluster; updating the third target configuration information by using the version information of the to-be-released version to obtain fourth target configuration information; replacing the third target configuration information in the configuration server cluster by using the fourth target configuration information, so that the response server cluster synchronizes the fourth target configuration information from the configuration server cluster; and uploading resource files of the second target application to a cloud storage, so that the response server cluster acquires the resource files of the second target application from the cloud storage based on the fourth target configuration information.

[0013] According to an embodiment of the present disclosure, the uploading of the resource files of the second target application to the cloud storage includes: creating a target folder associated with the version information of the to-be-released version under a preset directory of the cloud storage; and uploading the resource files of the second target application to the cloud storage based on path information of the target folder.

[0014] Another aspect of the present disclosure provides a resource management system, including: a response server cluster configured to: in response to a browsing request for a first target application, acquire target URL information carried in the browsing request; based on the target URL information, query a plurality of configuration information stored in an in-heap cache to determine target version information of the first target application; based on the target URL information and the target version information, determine target key-value pair information; based on the target key-value pair information, acquire resource files of the first target application from an out-of-heap cache; and a configuration server cluster configured to: in response to an information synchronization instruction, send the configuration information to the in-heap cache of the response server cluster.

[0015] Another aspect of the present disclosure provides a resource management apparatus, including: a first acquisition module configured to: in response to a browsing request for a first target application, acquire target URL information carried in the browsing request; a query module configured to: based on the target URL information, query a plurality of configuration information stored in an in-heap cache to determine target version information of the first target application, wherein the plurality of configuration information includes configuration information acquired from a configuration server cluster by executing an information synchronization instruction; a first determination module configured to: based on the target URL information and the target version information, determine target key-value pair information; and a second acquisition module configured to: based on the target key-value pair information, acquire resource files of the first target application from an out-of-heap cache.

[0016] Another aspect of the present disclosure provides a resource management apparatus, comprising:

[0017] a generating module configured to generate a browsing request for a first target application based on target URL information; and a sending module configured to send the browsing request to a response server cluster, so that the response server cluster queries a plurality of configuration information stored in an in-heap cache based on the target URL information, to determine target version information of the first target application, and determines target key-value pair information based on the target URL information and the target version information, and acquires a resource file of the first target application from an out-of-heap cache based on the target key-value pair information, wherein the plurality of configuration information is acquired from a configuration server cluster by the response server cluster through execution of an information synchronization instruction.

[0018] Another aspect of the present disclosure provides an electronic device, comprising: one or more processors; a memory configured to store one or more instructions, wherein the one or more instructions, when executed by the one or more processors, cause the one or more processors to implement the method as described above.

[0019] Another aspect of the present disclosure provides a computer-readable storage medium storing computer-executable instructions, wherein the instructions, when executed, implement the method as described above.

[0020] Another aspect of the present disclosure provides a computer program product, comprising computer-executable instructions, wherein the instructions, when executed, implement the method as described above.

[0021] According to embodiments of the present disclosure, when a browsing request is received, version information can be acquired from an in-heap cache, and key-value pair information is assembled according to the version information, and a resource file is acquired from an out-of-heap cache by using the key-value pair information. By using the cache to implement the processing of information and the storage of resource files, the response speed of the browsing request for the target application is improved. By synchronizing the configuration information from the configuration server cluster, the new version of the target application or the version rollback information can be synchronized to the in-heap cache in real time, at least partially overcoming the technical problem of poor timeliness of the resource management method in related technologies when the version of the web application changes, effectively ensuring the real-time performance of the resource file management, and improving the resource management performance. BRIEF DESCRIPTION OF DRAWINGS

[0022] The above and other objects, features and advantages of the present disclosure will become more apparent from the following description of embodiments of the present disclosure taken in conjunction with the accompanying drawings, in which:

[0023] Figure 1 An architecture diagram of a resource management system in related technologies is schematically shown.

[0024] Figure 2 An exemplary system architecture to which the resource management method and apparatus according to embodiments of the present disclosure can be applied is schematically shown.

[0025] Figure 3 A flowchart of a resource management method according to an embodiment of the present disclosure is schematically shown.

[0026] Figure 4A A flowchart of a resource management method according to another embodiment of the present disclosure is schematically shown.

[0027] Figure 4B A timing diagram of a resource management method according to another embodiment of the present disclosure is schematically shown.

[0028] Figure 5 A flowchart of a resource management method according to yet another embodiment of the present disclosure is schematically shown.

[0029] Figure 6 A flowchart of a version release method according to an embodiment of the present disclosure is schematically shown.

[0030] Figure 7 An architecture diagram of a resource management system according to an embodiment of the present disclosure is schematically shown.

[0031] Figure 8 A block diagram of a resource management apparatus according to an embodiment of the present disclosure is schematically shown.

[0032] Figure 9 A block diagram of a resource management apparatus according to yet another embodiment of the present disclosure is schematically shown.

[0033] Figure 10 A block diagram of an electronic device suitable for implementing a resource management method according to an embodiment of the present disclosure is schematically shown. DETAILED DESCRIPTION

[0034] Hereinafter, embodiments of the present disclosure will be described with reference to the accompanying drawings. It is to be understood, however, the description is merely exemplary and is not intended to limit the scope of the present disclosure. In the following detailed description, numerous specific details are set forth in order to provide a thorough understanding of embodiments of the present disclosure. However, it would be apparent to those skilled in the art that one or more embodiments can be practiced without these specific details. In other instances, well-known structures and techniques have not been described in detail in order to avoid obscuring aspects of the present disclosure.

[0035] The terminology used herein is for the purpose of describing particular embodiments only and is not intended to limit this disclosure. The terms “comprising,” “including,” etc., as used herein indicate the presence of the stated features, steps, operations, and / or components, but do not exclude the presence or addition of one or more other features, steps, operations, or components.

[0036] All terms used herein (including technical and scientific terms) have the meanings commonly understood by those skilled in the art, unless otherwise defined. It should be noted that the terms used herein are to be interpreted in a manner consistent with the context of this specification, and not in an idealized or overly rigid way.

[0037] When using expressions such as "at least one of A, B, and C," the expression should generally be interpreted in accordance with the meaning commonly understood by a person skilled in the art (e.g., "a system having at least one of A, B, and C" should include, but is not limited to, systems having A alone, having B alone, having C alone, having A and B, having A and C, having B and C, and / or having A, B, and C, etc.). Similarly, when using expressions such as "at least one of A, B, or C," the expression should generally be interpreted in accordance with the meaning commonly understood by a person skilled in the art (e.g., "a system having at least one of A, B, or C" should include, but is not limited to, systems having A alone, having B alone, having C alone, having A and B, having A and C, having B and C, and / or having A, B, and C, etc.).

[0038] In related technologies, static resource files for web applications can be managed and accessed using proxy servers and content delivery networks.

[0039] Figure 1 The diagram illustrates the architecture of a resource management system in the relevant technology.

[0040] like Figure 1 As shown, the resource management system in the related technology may include a build server 101, a code repository 102, a proxy server cluster 103, cloud storage 104, and a content delivery network 105.

[0041] When a new version of a web application is released, the user can upload the source code of the compiled new version of the web application to the build server 101. The build server 101 can upload the html code in the source code to the code repository 102, and the html code can also be packaged into an html file which can be sent to the proxy server cluster 103 through an interface such as JDOS. The build server 101 can also package the codes in the source code other than the HTML code into js, css and other static resource files which can be uploaded to the cloud storage 104 by the build server 101.

[0042] When the web application is browsed, the html file can be requested from the proxy server cluster 103, and the js, css and other static resource files can be requested from the content distribution network 105. In the case that the js, css and other static resource files of the web application do not exist in the content distribution network 105, the content distribution network 105 can also obtain the static resource files of the web application from the cloud storage 104.

[0043] When the version of the web application is rolled back, the build server 101 can obtain the source code of the version to be rolled back from the code repository 102, package the source code and upload it to the proxy server cluster 103 to complete the version rollback.

[0044] In the related art, since multiple web applications share the code repository, each time a web application is online, it may affect other web applications, and when the version is rolled back, the historical version package needs to be pushed to the proxy server cluster, and the efficiency of the rollback processing is low.

[0045] Therefore, embodiments of the present disclosure provide a resource management method, system, device, electronic equipment, storage medium and computer program product. The method comprises: in response to a browsing request for a first target application, obtaining target website information carried in the browsing request; based on the target website information, querying a plurality of configuration information stored in the in-memory cache to determine target version information of the first target application, wherein the plurality of configuration information is obtained from the configuration server cluster by executing an information synchronization instruction; based on the target website information and the target version information, determining target key-value pair information; and based on the target key-value pair information, obtaining resource files of the first target application from the out-of-memory cache.

[0046] Figure 2 An example system architecture to which the resource management method and device according to embodiments of the present disclosure can be applied is schematically shown. It should be noted that, Figure 2The shown is only an example of a system architecture to which the embodiments of the present disclosure can be applied, to help those skilled in the art understand the technical content of the present disclosure, but does not mean that the embodiments of the present disclosure cannot be used in other devices, systems, environments or scenarios.

[0047] As shown in the figure, the system architecture 200 according to the embodiment can include terminal devices 201, 202, a cloud storage server 203 and servers 204, 205. Figure 2

[0048] The terminal devices 201, 202 can be various electronic devices with display screens and supporting web browsing, including but not limited to smartphones, tablet computers, laptop computers and desktop computers, etc.

[0049] Various communication client applications can be installed on the terminal devices 201, 202, such as web browser applications, search applications, instant messaging tools, email clients and / or social platform software, etc.

[0050] The cloud storage server 203 can refer to a virtual server hosted by a third party, which can be used to implement online storage of data.

[0051] The servers 204, 205 can be a server cluster providing various services, which can provide services including but not limited to content distribution services, proxy services, static resource management services, etc.

[0052] The terminal devices 201, 202 and the servers 204, 205, the servers 204, 205 and the cloud storage server 203, and the servers 204, 205 can interact through a network, which can include various connection types, such as wired and / or wireless communication links, etc.

[0053] It should be noted that the resource management method provided by the embodiments of the present disclosure can generally be executed by the servers 204, 205. Correspondingly, the resource management apparatus provided by the embodiments of the present disclosure can generally be arranged in the servers 204, 205. The resource management method provided by the embodiments of the present disclosure can also be executed by a server or server cluster different from the servers 204, 205 and capable of communicating with the terminal devices 201, 202 and / or the servers 204, 205. Correspondingly, the resource management apparatus provided by the embodiments of the present disclosure can also be arranged in a server or server cluster different from the servers 204, 205 and capable of communicating with the terminal devices 201, 202 and / or the servers 204, 205.

[0054] It should be understood that, Figure 2 ​The number of terminal devices, cloud storage servers and server clusters in the system is merely illustrative. Any number of terminal devices, cloud storage servers and server clusters can be provided according to implementation needs.

[0055] It should be noted that, unless explicitly stated otherwise, the order of execution of the operations shown in the flowcharts in the embodiments of the present disclosure can not be sequential, or the order of execution of the operations can be simultaneous.

[0056] Figure 3 A flowchart of a resource management method according to an embodiment of the present disclosure is illustratively shown.

[0057] As shown in Figure 3 , the method includes operations S301-S304.

[0058] In operation S301, target URL information carried in a browsing request is acquired in response to a browsing request for a first target application.

[0059] In operation S302, based on the target URL information, a plurality of configuration information stored in the in-heap cache is queried to determine target version information of the first target application. The plurality of configuration information includes information obtained from the configuration server cluster by executing the information synchronization instruction.

[0060] In operation S303, based on the target URL information and the target version information, target key-value pair information is determined.

[0061] In operation S304, based on the target key-value pair information, a resource file of the first target application is acquired from the out-of-heap cache.

[0062] According to an embodiment of the present disclosure, the first target application can be an application program written in a web language, which can be executed through a browser, such as a web application, an H5 application, etc. The web language can include, but is not limited to, HTML, Java, Javascript, etc.

[0063] According to an embodiment of the present disclosure, the target URL information can refer to an address input by a user in an address bar of a browser when initiating a browsing request for the first target application. The target URL information can be composed of application layer protocol name, domain name, application name, etc. For example, the target URL information can be http: / / a.com / app1 / minapp1.

[0064] According to an embodiment of the present disclosure, the in-heap cache can be a cache that allocates memory objects within the heap of a virtual machine.

[0065] According to an embodiment of the present disclosure, the target version information can be a version number of a target version of the first target application that needs to be queried, for example, 1.0.0, 1.0.2, etc. It can also be any character or string of version numbers that can uniquely represent the target version, for example, V1, V2, etc.

[0066] According to an embodiment of the present disclosure, the configuration server cluster can be a distributed service cluster capable of providing configuration management functions, and the configuration server cluster can include, but is not limited to, a zookeeper cluster, a Hadoop cluster, etc.

[0067] According to an embodiment of the present disclosure, the target key-value pair information can include primary key information and attribute value information. The primary key information can be obtained by splicing the target website information and the target version information. For example, the target website information is a.com / app1 / minapp1, and the target version information is 2.0.0, and the primary key information can be key=a.com / app1 / minapp1 / 2.0.0. The attribute value information can be obtained by splicing the root directory address of the resource file stored in the off-heap cache, and the target website information and the target version information. For example, the root directory address of the resource file stored in the off-heap cache is / bucket, and the file name of the resource file is index.html, and the attribute value information can be value= / bucket / app1 / minapp1 / 2.0.0 / index.html.

[0068] According to an embodiment of the present disclosure, the off-heap cache can be a cache that allocates memory objects outside the heap of a virtual machine.

[0069] According to an embodiment of the present disclosure, the resource file of the first target application can be obtained by packaging the source code of the first target application. The resource file of the first target application can include html, js, css, etc. static resource files, and the resource file can be rendered in the browser to obtain the display page of the first target application.

[0070] According to an embodiment of the present disclosure, when the browsing request is received, the version information can be obtained from the in-heap cache, the key-value pair information can be assembled according to the version information, and the resource file can be obtained from the off-heap cache by using the key-value pair information. By using the cache to implement the processing of information and the storage of resource files, the response speed of the browsing request of the target application is improved. By synchronizing the configuration information from the configuration server cluster, the new version of the target application or the version rollback information can be synchronized to the in-heap cache in real time, at least partially overcoming the poor timeliness of the resource management method in related technologies when the version of the web application changes, effectively ensuring the real-time performance of the resource file management, and improving the resource management performance.

[0071] The method shown in the specific embodiments is further described below with reference to the accompanying drawings. Figure 4A and Figure 4B Figure 3

[0072] According to an embodiment of the present disclosure, the configuration information can include website information and version information.

[0073] According to an embodiment of the present disclosure, operation S302 can include the following operations:

[0074] The target website information is matched with the website information in the plurality of configuration information respectively to determine first target configuration information matched with the target website information; and based on the version information in the first target configuration information, target version information is determined.

[0075] According to an embodiment of the present disclosure, the target website information can include domain name information and resource identifier. The domain name information can be the name of a computer or a group of computers on the Internet composed of a string of characters separated by dots, and can be used for positioning identification of the computer during data transmission. The resource identifier can be a Uniform Resource Identifier (URI), which can be a string used to identify the name of an Internet resource. For example, the target website information can be a.com / app1 / minapp1, and the domain name information therein can be a.com, and the resource identifier can be / app1 / minapp1.

[0076] In some embodiments of the present disclosure, before determining the target version information, the domain name type of the domain name information can also be determined based on the domain name information. The domain name type of the domain name information can include a custom domain name and a general domain name. The custom domain name can be a domain name predefined by the user when publishing the version and different from the default domain name, for example, the default domain name can be a.com, and the custom domain name can be b.com, a.cn, c.com, etc. The custom domain name can correspond to only one version of the web application. The general domain name can refer to the default domain name. In the case where the user does not specify the domain name when publishing the version, the general domain name can be used as the domain name information of the version.

[0077] ​​According to an embodiment of the present disclosure, the domain name type of the domain name information can be determined by matching the domain name information with a preset general domain name. If a match is found, the domain name type of the domain name information is determined to be a general domain name. If no match is found, the domain name type of the domain name information is determined to be a custom domain name. The domain name type of the domain name information can also be determined by querying a plurality of configuration information using the domain name information. If a uniquely corresponding target configuration information can be queried, the domain name type of the domain name information is determined to be a custom domain name. If a uniquely corresponding target configuration information cannot be queried, the domain name type of the domain name information is determined to be a general domain name.

[0078] According to an embodiment of the present disclosure, operation S302 can further include the following operations.

[0079] In a case where the domain name type of the domain name information is determined to be a custom domain name, a plurality of configuration information are queried based on the domain name information to determine target version information. In a case where the domain name type of the domain name information is determined to be a general domain name, a plurality of configuration information are queried based on the domain name information and a resource identifier to determine target version information.

[0080] Figure 4A A flowchart of a resource management method according to another embodiment of the present disclosure is schematically shown.

[0081] As shown in FIG. 4, the method includes operations S401-S410. Figure 4A

[0082] In operation S401, a user's browsing request for a target application is received.

[0083] In operation S402, the browsing request is parsed to obtain domain name information and a resource identifier.

[0084] In operation S403, it is determined whether target configuration information is queried from the in-memory cache according to the domain name information. In a case where it is determined that the target configuration information cannot be queried, operation S404 is performed. In a case where it is determined that the target configuration information is queried, operation S406 is performed.

[0085] In operation S404, it is determined whether target configuration information is queried from the in-memory cache according to the domain name information and the resource identifier. In a case where it is determined that the target configuration information cannot be queried, operation S405 is performed. In a case where it is determined that the target configuration information is queried, operation S406 is performed.

[0086] In operation S405, a default page is returned and output to the user's browser end.

[0087] In operation S406, target version information is determined according to the target configuration information.

[0088] ​In operation S407, the target key-value pair information is assembled according to the target version information.

[0089] In operation S408, it is determined whether the resource file is queried from the off-heap cache according to the target key-value pair information. In a case where it is determined that the resource file is not queried, operation S409 is performed; in a case where it is determined that the resource file is queried, operation S410 is performed.

[0090] In operation S409, the resource file is read from the cloud storage according to the target key-value pair information and is cached in the off-heap cache. After operation S409 is completed, operation S408 is returned to be performed.

[0091] In operation S410, the resource file is output to the user browser end in the form of an output stream.

[0092] According to an embodiment of the present disclosure, determining whether the target configuration information is queried from the in-heap cache can be determining whether the uniquely corresponding target configuration information is queried.

[0093] According to an embodiment of the present disclosure, in a case where the target configuration information is not queried from the cloud storage based on the domain name information and the resource identifier, it can be considered that the version of the target application represented by the target web address information is not online. The returned default page can be a blank page about: blank.

[0094] In other embodiments of the present disclosure, the default page can also refer to a page of a baseline version of the target application. At this time, operation S405 can be returning the version information of the default page, and after operation S405 is completed, the method of operation S407 is performed to obtain the resource file of the baseline version from the off-heap cache or the cloud storage and output the resource file to the user browser end.

[0095] According to an embodiment of the present disclosure, operation S409 can include the following operations:

[0096] Based on the target key-value pair information, a target folder in the cloud storage is determined; a resource file of the target application is read from the target folder; and the resource file of the first target application is stored in the off-heap cache.

[0097] According to an embodiment of the present disclosure, the target folder in the cloud storage can refer to a folder in the cloud storage for storing the resource file of the target application. The directory where the target folder is located can include folders for storing resource files of each version of the target application.

[0098] According to an embodiment of the present disclosure, an LRU (Least Recently Used) algorithm can be configured in the off-heap cache, that is, when the resource file of the first target application is stored in the off-heap cache, an expiration condition can be set for the resource file of the first target application, so that the resource file of the target application in the off-heap cache is deleted when the expiration condition is met. The expiration condition can be that the resource file has not been accessed for a preset time period. The preset time period can be set according to a specific application scenario, which is not limited herein. By configuring the LRU algorithm, the resource files stored in the off-heap cache can be the resource files of web applications frequently accessed by users, and the resource files of web applications that have not been accessed for a long time will automatically expire, thereby ensuring that the memory of the service does not overflow while determining the access speed of the application.

[0099] Figure 4B A timing diagram of a resource management method according to another embodiment of the present disclosure is schematically shown.

[0100] As shown in Figure 4B , the cache of the response server cluster can be divided into an in-heap cache and an off-heap cache.

[0101] According to an embodiment of the present disclosure, the response server cluster can use Servlet / * / * to receive a browsing request of a target application from a user, and the target URL information carried in the browsing request can include a domain name, an application name, and a micro-application name, for example, a.com / app1 / minapp1.

[0102] According to an embodiment of the present disclosure, after receiving the browsing request, the response server cluster can parse the target URL information to obtain domain name information and a URI. For example, the target URL information is a.com / app1 / minapp1, the domain name information is a.com, and the URI is / app1 / minapp1.

[0103] According to an embodiment of the present disclosure, the response server cluster can use the domain name information and the URI to query the configuration information in the in-heap cache. The specific query method can refer to the method of operations S403-S406, which will not be repeated herein. After the query, the information that can be obtained is the information of the currently online version of the target application. For example, the configuration information in the in-heap cache is queried with the domain name information a.com and the URI / app1 / minapp1, and the target configuration information that can be queried is a.com / app1 / minapp1=2.0.0, so it can be determined that the information of the currently online version of the target application is 2.0.0.

[0104] According to an embodiment of the present disclosure, the configuration information in the in-heap cache can be obtained from the configuration server cluster by executing the information synchronization instruction. Specifically, the response server cluster can monitor the configuration server cluster by inserting a watcher monitoring node into the configuration server cluster. In the case of monitoring that the configuration server cluster triggers a configuration change event, the target configuration information that has changed is determined, and the information synchronization instruction is executed to obtain the target configuration information from the configuration server cluster. The configuration change event can include an event generated when a version is updated online or a version is rolled back, indicating that the current online version has changed. With the configuration synchronization of the configuration server cluster, the version information of the online or rollback of the application can be synchronized to the in-heap cache of the response server cluster in real time, ensuring the real-time performance of resource management and improving the performance of resource management.

[0105] According to an embodiment of the present disclosure, after the response server cluster determines the version information in the out-of-heap cache, the response server cluster can query the resource file of the corresponding version from the out-of-heap cache based on the version information. After obtaining the resource file from the out-of-heap cache, the resource file can be output to the user's browser end using an output stream to complete the response to the browsing request.

[0106] According to an embodiment of the present disclosure, in the case that the response server cluster fails to obtain the resource file from the out-of-heap cache, the response server cluster can query the resource file of the corresponding version from the cloud storage based on the version information. After successfully obtaining the resource file, the resource file can be cached in the out-of-heap cache to improve the response speed when accessing the target application multiple times in a short period of time. After successful caching, the resource file can be output to the user's browser end using an output stream to complete the response to the browsing request.

[0107] Figure 5 A flowchart of a resource management method according to still another embodiment of the present disclosure is schematically shown.

[0108] As shown in Figure 5 , the method includes operations S501-S502.

[0109] In operation S501, a browsing request for a first target application is generated based on target website information.

[0110] In operation S502, the browsing request is sent to the response server cluster, so that the response server cluster responds to the browsing request, queries a plurality of configuration information stored in the in-heap cache based on the target website information, determines target version information of the first target application, and determines target key-value pair information based on the target website information and the target version information, and obtains a resource file of the first target application from the out-of-heap cache based on the target key-value pair information. The plurality of configuration information is obtained from the configuration server cluster by the response server cluster executing the information synchronization instruction.

[0111] According to an embodiment of the present disclosure, the target website information can be website information input by a user in a browser of a client device.

[0112] According to an embodiment of the present disclosure, the method for the response server cluster to acquire the resource file in response to the browsing request can refer to the method of operations S301-S304, which will not be repeated here.

[0113] According to an embodiment of the present disclosure, when the terminal device accesses the target application, the input target website information can be generated as a browsing request, which can be sent to the response server cluster, and the response server cluster can acquire the resource file from the off-heap cache of the response server cluster in response to the browsing request. The response server cluster improves the response speed of the browsing request of the target application by using the cache to implement the processing of the information and the storage of the resource file. The response server cluster synchronizes the configuration information from the configuration server cluster, so that the new version of the target application or the version rollback information can be synchronized to the in-heap cache in real time, at least partially overcoming the technical problem of poor timeliness of the resource management method in the related art when the version of the web application changes, effectively guaranteeing the real-time performance of the resource file management, and improving the resource management performance.

[0114] Figure 6 A flowchart of a version publishing method according to an embodiment of the present disclosure is schematically shown.

[0115] As shown in Figure 6 , the method includes operations S601-S605.

[0116] In operation S601, in response to a version publishing request, a second target application associated with the version publishing request and version-to-be-published information of the second target application are determined.

[0117] In operation S602, third target configuration information associated with the second target application in the configuration server cluster is determined.

[0118] In operation S603, the third target configuration information is updated using the version-to-be-published information to obtain fourth target configuration information.

[0119] In operation S604, the third target configuration information in the configuration server cluster is replaced using the fourth target configuration information, so that the response server cluster synchronizes the fourth target configuration information from the configuration server cluster.

[0120] In operation S605, the resource file of the second target application is uploaded to the cloud storage, so that the response server cluster acquires the resource file of the second target application from the cloud storage based on the fourth target configuration information.

[0121] According to an embodiment of the present disclosure, the to-be-published version can have different version information from the current online version or a historical version of the second target application.

[0122] According to an embodiment of the present disclosure, at the time of version publishing, the new version online information or the old version rollback information can be synchronized to the response server cluster in real time by using the configuration server cluster, thereby improving the efficiency of version publishing and enabling the response server cluster to efficiently respond to user browsing requests.

[0123] According to an embodiment of the present disclosure, operation S605 can include the following operations:

[0124] creating, under a preset directory of the cloud storage, a target folder associated with the to-be-published version information; and uploading, based on path information of the target folder, the resource file of the second target application to the cloud storage.

[0125] According to an embodiment of the present disclosure, the preset directory can refer to a root directory for storing resource files of all versions of the second target application. The target folder can be created using the to-be-published version information as the folder name.

[0126] Figure 7 An architecture diagram of a resource management system according to an embodiment of the present disclosure is schematically shown.

[0127] As shown in Figure 7 , the resource management system 700 can include a response server cluster 710 and a configuration server cluster 720.

[0128] According to an embodiment of the present disclosure, the response server cluster 710 can be configured to, in response to a browsing request for a first target application, acquire target URL information carried in the browsing request, query a plurality of configuration information stored in an in-heap cache based on the target URL information to determine target version information of the first target application, determine target key-value pair information based on the target URL information and the target version information, and acquire a resource file of the first target application from an out-of-heap cache based on the target key-value pair information.

[0129] According to an embodiment of the present disclosure, the configuration server cluster 720 can be configured to, in response to an information synchronization instruction, send configuration information to an in-heap cache of the response server cluster 710.

[0130] In some embodiments, the resource management system 700 can further include a build server 730, a cloud storage 740, and a content distribution network 750.

[0131] According to an embodiment of the present disclosure, at the time of version publishing, the build server 730 can package source code of a web application uploaded by a user into a resource file and upload the resource file to the cloud storage 740.

[0132] According to an embodiment of the present disclosure, in response to the browsing request, the response server cluster 710 can obtain the html file from the cloud storage, and the content distribution network 750 can also obtain the js, css and other files from the cloud storage in response to the browsing request.

[0133] According to an embodiment of the present disclosure, the content distribution network 750 can accelerate the access of js, css and other static resource files, and improve the response speed of the browser.

[0134] Figure 8 A block diagram of a resource management apparatus according to an embodiment of the present disclosure is shown schematically.

[0135] As shown in Figure 8 The resource management apparatus 800 includes a first obtaining module 810, a querying module 820, a first determining module 830 and a second obtaining module 840.

[0136] The first obtaining module 810 is configured to obtain target website information carried in a browsing request in response to the browsing request for a first target application.

[0137] The querying module 820 is configured to query a plurality of configuration information stored in the in-heap cache based on the target website information, to determine target version information of the first target application, wherein the plurality of configuration information is obtained from the configuration server cluster by executing the information synchronization instruction.

[0138] The first determining module 830 is configured to determine target key-value pair information based on the target website information and the target version information.

[0139] The second obtaining module 840 is configured to obtain resource files of the first target application from the out-of-heap cache based on the target key-value pair information.

[0140] According to an embodiment of the present disclosure, when the browsing request is received, the version information can be obtained from the in-heap cache, and the key-value pair information is assembled according to the version information, and then the resource files are obtained from the out-of-heap cache by using the key-value pair information. By using the cache to realize the processing of information and the storage of resource files, the response speed of the browsing request for the target application is improved. By synchronizing the configuration information from the configuration server cluster, the new version of the target application or the version rollback information can be synchronized to the in-heap cache in real time, at least partially overcoming the technical problem that the related art resource management method has poor timeliness when the version of the web application changes, effectively ensuring the real-time performance of the resource file management, and improving the resource management performance.

[0141] According to an embodiment of the present disclosure, the configuration information includes website information and version information.

[0142] According to an embodiment of the present disclosure, the query module 820 comprises a first query unit and a second query unit.

[0143] The first query unit is configured to match the target website information with website information in the plurality of configuration information respectively, to determine first target configuration information matched with the target website information.

[0144] The second query unit is configured to determine target version information based on version information in the first target configuration information.

[0145] According to an embodiment of the present disclosure, the target website information comprises domain name information and resource identifier.

[0146] According to an embodiment of the present disclosure, the resource management apparatus 800 further comprises a second determination module.

[0147] The second determination module is configured to determine a domain name type of the domain name information based on the domain name information, wherein the domain name type comprises a custom domain name and a general domain name.

[0148] According to an embodiment of the present disclosure, the query module 820 comprises a third query unit and a fourth query unit.

[0149] The third query unit is configured to, in a case where the domain name type of the domain name information is determined as the custom domain name, query the plurality of configuration information based on the domain name information, to determine the target version information.

[0150] The fourth query unit is configured to, in a case where the domain name type of the domain name information is determined as the general domain name, query the plurality of configuration information based on the domain name information and the resource identifier, to determine the target version information.

[0151] According to an embodiment of the present disclosure, the resource management apparatus 800 further comprises a synchronization module. The synchronization module comprises a first synchronization unit, a second synchronization unit and a third synchronization unit.

[0152] The first synchronization unit is configured to listen to the configuration server cluster.

[0153] The second synchronization unit is configured to, in a case where it is listened that the configuration server cluster triggers a configuration change event, determine second target configuration information which is changed.

[0154] The third synchronization unit is configured to execute an information synchronization instruction, to obtain the second target configuration information from the configuration server cluster.

[0155] According to an embodiment of the present disclosure, the resource management apparatus 800 further comprises a third determination module, a reading module and a storage module.

[0156] The third determining module is configured to, in the case that the resource file of the first target application does not exist in the off-heap cache, determine a target folder in the cloud storage based on the target key-value pair information.

[0157] The reading module is configured to read the resource file of the first target application from the target folder.

[0158] The storage module is configured to store the resource file of the first target application into the off-heap cache.

[0159] According to an embodiment of the present disclosure, the resource management apparatus 800 further comprises a first processing module.

[0160] The first processing module is configured to, when storing the resource file of the first target application into the off-heap cache, set an expiration condition for the resource file of the first target application, so as to delete the resource file of the first target application in the off-heap cache in the case that the expiration condition is met.

[0161] Figure 9 A block diagram of a resource management apparatus according to still another embodiment of the present disclosure is schematically shown.

[0162] As shown in Figure 9 The resource management apparatus 900 comprises a generating module 910 and a sending module 920.

[0163] The generating module 910 is configured to generate a browsing request for the first target application based on the target website information.

[0164] The sending module 920 is configured to send the browsing request to a response server cluster, so that the response server cluster, in response to the browsing request, queries a plurality of configuration information stored in an in-heap cache based on the target website information, to determine target version information of the first target application, and determines target key-value pair information based on the target website information and the target version information, and further acquires the resource file of the first target application from an off-heap cache based on the target key-value pair information, wherein the plurality of configuration information is acquired by the response server cluster from a configuration server cluster by executing an information synchronization instruction.

[0165] According to an embodiment of the present disclosure, when a terminal device accesses a target application, input target website information can be generated as a browsing request, which can be sent to a response server cluster, and the response server cluster can respond to the browsing request and obtain a resource file from an off-heap cache of the response server cluster. The response server cluster improves the response speed of the browsing request of the target application by using the cache to implement information processing and resource file storage. The response server cluster synchronizes configuration information from the configuration server cluster, so that the online of a new version of the target application or version rollback information can be synchronized to the in-heap cache in real time, at least partially overcoming the poor timeliness of the resource management method in related technologies when the version of the web application changes, effectively ensuring the real-time performance of resource file management, and improving the resource management performance.

[0166] According to an embodiment of the present disclosure, the resource management apparatus 900 further includes a fourth determination module, a fifth determination module, a second processing module, a third processing module, and an uploading module.

[0167] The fourth determination module is configured to determine, in response to a version release request, a second target application associated with the version release request and to-be-released version information of the second target application.

[0168] The fifth determination module is configured to determine third target configuration information associated with the second target application in the configuration server cluster.

[0169] The second processing module is configured to update the third target configuration information by using the to-be-released version information to obtain fourth target configuration information.

[0170] The third processing module is configured to replace the third target configuration information in the configuration server cluster with the fourth target configuration information, so that the response server cluster synchronizes the fourth target configuration information from the configuration server cluster.

[0171] The uploading module is configured to upload resource files of the second target application to cloud storage, so that the response server cluster obtains the resource files of the second target application from the cloud storage based on the fourth target configuration information.

[0172] According to an embodiment of the present disclosure, the uploading module includes a first uploading unit and a second uploading unit.

[0173] The first uploading unit is configured to create a target folder associated with the to-be-released version information under a preset directory of the cloud storage.

[0174] The second uploading unit is configured to upload the resource files of the second target application to the cloud storage based on path information of the target folder.

[0175] Any of the modules, sub-modules, units, sub-units according to the embodiments of the present disclosure, or at least part of functions of any of them, can be implemented in one module. Any of the modules, sub-modules, units, sub-units according to the embodiments of the present disclosure can be split into multiple modules for implementation. Any of the modules, sub-modules, units, sub-units according to the embodiments of the present disclosure can be implemented at least in part as a hardware circuit, such as a field-programmable gate array (FPGA), a programmable logic array (PLA), a system on chip, a system on board, a system on package, an application-specific integrated circuit (ASIC), or any other reasonable way of hardware or firmware by integrating or packaging circuits, or in any one of software, hardware and firmware, or in a proper combination of any of them. Alternatively, one or more of the modules, sub-modules, units, sub-units according to the embodiments of the present disclosure can be implemented at least in part as computer program modules, which can perform corresponding functions when running.

[0176] For example, any of the first obtaining module 810, the querying module 820, the first determining module 830 and the second obtaining module 840, or the generating module 910 and the sending module 920 can be combined in one module / unit / sub-unit for implementation, or any of them can be split into multiple modules / units / sub-units. Alternatively, at least part of the functions of one or more of the modules / units / sub-units can be combined with at least part of the functions of other modules / units / sub-units, and implemented in one module / unit / sub-unit. According to the embodiments of the present disclosure, at least one of the first obtaining module 810, the querying module 820, the first determining module 830 and the second obtaining module 840, or the generating module 910 and the sending module 920 can be implemented at least in part as a hardware circuit, such as a field-programmable gate array (FPGA), a programmable logic array (PLA), a system on chip, a system on board, a system on package, an application-specific integrated circuit (ASIC), or any other reasonable way of hardware or firmware by integrating or packaging circuits, or in any one of software, hardware and firmware, or in a proper combination of any of them. Alternatively, at least one of the first obtaining module 810, the querying module 820, the first determining module 830 and the second obtaining module 840, or the generating module 910 and the sending module 920 can be implemented at least in part as computer program modules, which can perform corresponding functions when running.

[0177] It should be noted that the resource management device part in the embodiments of this disclosure corresponds to the resource management method part in the embodiments of this disclosure. The description of the resource management device part is specifically referred to in the resource management method part, and will not be repeated here.

[0178] Figure 10 A block diagram of an electronic device suitable for implementing a resource management method according to an embodiment of the present disclosure is shown schematically. Figure 10 The electronic device shown is merely an example and should not be construed as limiting the functionality and scope of the embodiments disclosed herein.

[0179] like Figure 10 As shown, a computer electronic device 1000 according to an embodiment of the present disclosure includes a processor 1001, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 1002 or a program loaded from a storage portion 1008 into a random access memory (RAM) 1003. The processor 1001 may include, for example, a general-purpose microprocessor (e.g., a CPU), an instruction set processor and / or an associated chipset and / or a special-purpose microprocessor (e.g., an application-specific integrated circuit (ASIC)), etc. The processor 1001 may also include onboard memory for caching purposes. The processor 1001 may include a single processing unit or multiple processing units for performing different actions of the method flow according to an embodiment of the present disclosure.

[0180] RAM 1003 stores various programs and data required for the operation of electronic device 1000. Processor 1001, ROM 1002, and RAM 1003 are interconnected via bus 1004. Processor 1001 performs various operations of the method flow according to embodiments of the present disclosure by executing programs in ROM 1002 and / or RAM 1003. It should be noted that the programs may also be stored in one or more memories other than ROM 1002 and RAM 1003. Processor 1001 may also perform various operations of the method flow according to embodiments of the present disclosure by executing programs stored in said one or more memories.

[0181] According to an embodiment of the present disclosure, the electronic device 1000 can further include an input / output (I / O) interface 1005 that is also connected to the bus 1004. The electronic device 1000 can further include one or more of the following components connected to the I / O interface 1005: an input part 1006 including, for example, a keyboard and a mouse; an output part 1007 including, for example, a cathode ray tube (CRT), a liquid crystal display (LCD), and a speaker; a storage part 1008 including, for example, a hard disk; and a communication part 1009 including, for example, a LAN card, a modem, and the like. The communication part 1009 performs communication processing via a network such as the Internet. A drive 1010 is also connected to the I / O interface 1005 as necessary. A removable medium 1011 such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, and the like is attached to the drive 1010 as necessary, so that a computer program read therefrom is installed into the storage part 1008 as necessary.

[0182] According to an embodiment of the present disclosure, the method flow according to the embodiment of the present disclosure can be implemented as a computer software program. For example, the embodiment of the present disclosure includes a computer program product including a computer program carried on a computer-readable storage medium, the computer program containing program codes for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from a network by the communication part 1009, and / or installed from the removable medium 1011. When the computer program is executed by the processor 1001, the above-described functions defined in the system implementing the embodiment of the present disclosure are performed. According to an embodiment of the present disclosure, the system, device, apparatus, module, unit, and the like described above can be implemented by computer program modules.

[0183] The present disclosure also provides a computer-readable storage medium, which can be included in the device / apparatus / system described in the above embodiments; or can exist separately without being assembled into the device / apparatus / system. The above computer-readable storage medium carries one or more programs, which, when executed, implement the method according to the embodiment of the present disclosure.

[0184] According to an embodiment of the present disclosure, the computer readable storage medium can be a non-volatile computer readable storage medium. For example, it can include, but is not limited to, a portable computer diskette, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the present disclosure, a computer readable storage medium can be any tangible medium that contains or stores a program, which can be used by or in connection with an instruction execution system, apparatus, or device.

[0185] For example, according to an embodiment of the present disclosure, the computer readable storage medium can include one or more memories other than the ROM 1002 and / or the RAM 1003 and / or the ROM 1002 and the RAM 1003 described above.

[0186] Embodiments of the present disclosure also include a computer program product, which includes a computer program containing program codes for executing the method provided by the embodiments of the present disclosure, and when the computer program product is run on an electronic device, the program codes are used to make the electronic device implement the resource management method provided by the embodiments of the present disclosure.

[0187] When the computer program is executed by the processor 1001, the above-mentioned functions defined in the system / apparatus of the embodiments of the present disclosure are performed. According to an embodiment of the present disclosure, the system, apparatus, module, unit, etc. described above can be implemented by computer program modules.

[0188] In one embodiment, the computer program can rely on a tangible storage medium such as an optical storage device, a magnetic storage device, etc. In another embodiment, the computer program can also be transmitted, distributed, and downloaded in the form of a signal on a network medium, and be downloaded and installed through the communication part 1009, and / or be installed from the detachable medium 1011. The program codes contained in the computer program can be transmitted by any appropriate network medium, including but not limited to wireless, wired, etc., or any suitable combination of the foregoing.

[0189] According to embodiments of the present disclosure, program code of a computer program provided by embodiments of the present disclosure can be written in any combination of one or more programming languages, and specifically, can be implemented using a high-level procedural and / or object-oriented programming language, and / or an assembly / machine language. Programming languages include, but are not limited to, Java, C++, python, "C" language, or similar programming languages. Program code can execute entirely on a user's computing device, partly on a user device, partly on a remote computing device, or entirely on a remote computing device or server. In the latter scenario, the remote computing device can be connected to the user's computing device through any kind of network, including a local area network (LAN) or a wide area network (WAN), or the connection can be made to an external computing device, such as through the Internet using an Internet Service Provider.

[0190] The flow diagrams and the block diagrams in the drawings are illustrations of architectures, functionalities, and operations of possible implementations of systems, methods, and computer program products according to various embodiments of the present disclosure. In this regard, each block in the flow diagrams or block diagrams can represent a module, a segment, or a portion of code, which comprises one or more executable instructions for implementing the specified logical functions. It should also be noted that in some alternative implementations, the functions noted in the blocks can occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently or the blocks may

[0191] Embodiments of the present disclosure have been described above. However, these embodiments are merely intended to illustrate the present disclosure, and are not intended to limit the scope of the present disclosure. Although each of the embodiments is described above separately, this does not mean that the measures in each of the embodiments cannot be used advantageously in combination. The scope of the present disclosure is defined by the appended claims and their equivalents. Those skilled in the art who possess the present disclosure can make various substitutions and modifications without departing from the scope of the present disclosure, and these substitutions and modifications should fall within the scope of the present disclosure.​​

Claims

1. A resource management method, comprising: In response to a browsing request for a first target application, obtain the target URL information carried in the browsing request; Based on the target URL information, multiple configuration information stored in the heap cache are queried to determine the target version information of the first target application, wherein the multiple configuration information includes information obtained from the configuration server cluster by executing information synchronization instructions; Based on the target URL information and the target version information, determine the target key-value pair information; and Based on the target key-value pair information, the resource file of the first target application is obtained from the off-heap cache; Among them, the in-heap cache is a cache that allocates memory objects within the virtual machine's heap, while the off-heap cache is a cache that allocates memory objects outside the virtual machine's heap. The target key-value pair information includes primary key information and attribute value information. The primary key information is obtained by concatenating the target URL information and the target version information. The attribute value information is obtained by concatenating the root directory address of the resource file stored in the off-heap cache with the target URL information and the target version information.

2. The method according to claim 1, wherein, The configuration information includes website information and version information; The step of querying multiple configuration information stored in the heap cache based on the target URL information to determine the target version information of the first target application includes: The target URL information is matched with URL information in multiple configuration information sets to determine the first target configuration information that matches the target URL information; and The target version information is determined based on the version information in the first target configuration information.

3. The method according to claim 1, wherein, The target URL information includes domain name information and resource identifier; The method further includes: Based on the domain name information, the domain name type of the domain name information is determined, wherein the domain name type includes custom domain names and generic domain names; The step of querying multiple configuration information stored in the heap cache based on the target URL information to determine the target version information of the first target application includes: If the domain name type of the domain name information is determined to be a custom domain name, then based on the domain name information, multiple configuration information items are queried to determine the target version information; and If the domain name type of the domain name information is determined to be a general domain name, multiple configuration information are queried based on the domain name information and the resource identifier to determine the target version information.

4. The method according to claim 1, wherein, The plurality of configuration information includes those obtained from the configuration server cluster by executing information synchronization instructions, including: Monitor the configured server cluster; Upon detecting a configuration change event triggered by the configuration server cluster, determine the changed second target configuration information; and Execute the information synchronization command to obtain the second target configuration information from the configuration server cluster.

5. The method according to claim 1, further comprising: If the resource file of the first target application does not exist in the off-heap cache, the target folder in cloud storage is determined based on the target key-value pair information; Read the resource files of the first target application from the target folder; as well as The resource files of the first target application are stored in the off-heap cache.

6. The method according to claim 5, further comprising: When storing the resource files of the first target application in the off-heap cache, an expiration condition is set for the resource files of the first target application so that the resource files of the first target application in the off-heap cache are deleted when the expiration condition is met.

7. A resource management method, comprising: Based on the target URL information, generate a browsing request for the first target application; as well as The browser request is sent to the response server cluster so that the response server cluster can respond to the browser request, query multiple configuration information stored in the heap cache based on the target URL information to determine the target version information of the first target application, and determine the target key-value pair information based on the target URL information and the target version information. Then, based on the target key-value pair information, the resource file of the first target application is obtained from the off-heap cache. The multiple configuration information includes information obtained by the response server cluster from the configuration server cluster by executing information synchronization instructions. Among them, the in-heap cache is a cache that allocates memory objects within the virtual machine's heap, while the off-heap cache is a cache that allocates memory objects outside the virtual machine's heap. The target key-value pair information includes primary key information and attribute value information. The primary key information is obtained by concatenating the target URL information and the target version information. The attribute value information is obtained by concatenating the root directory address of the resource file stored in the off-heap cache with the target URL information and the target version information.

8. The method according to claim 7, further comprising: In response to a version release request, determine the second target application associated with the version release request and the release version information of the second target application; Determine the third target configuration information associated with the second target application in the configuration server cluster; The third target configuration information is updated using the information of the version to be released, to obtain the fourth target configuration information; The fourth target configuration information is used to replace the third target configuration information in the configuration server cluster, so that the response server cluster can synchronize the fourth target configuration information from the configuration server cluster; as well as The resource files of the second target application are uploaded to cloud storage so that the response server cluster can retrieve the resource files of the second target application from the cloud storage based on the fourth target configuration information.

9. The method according to claim 8, wherein, Uploading the resource files of the second target application to cloud storage includes: Create a target folder associated with the version information to be released in the preset directory of the cloud storage; and Based on the path information of the target folder, the resource files of the second target application are uploaded to the cloud storage.

10. A resource management system, comprising: A response server cluster is used to respond to a browsing request for the first target application and obtain the target URL information carried in the browsing request; Based on the target URL information, multiple configuration information stored in the heap cache are queried to determine the target version information of the first target application; Based on the target URL information and the target version information, determine the target key-value pair information; Based on the target key-value pair information, the resource file of the first target application is obtained from the off-heap cache; as well as Configure a server cluster to send the configuration information to the heap cache of the responding server cluster in response to an information synchronization command; Among them, the in-heap cache is a cache that allocates memory objects within the virtual machine's heap, while the off-heap cache is a cache that allocates memory objects outside the virtual machine's heap. The target key-value pair information includes primary key information and attribute value information. The primary key information is obtained by concatenating the target URL information and the target version information. The attribute value information is obtained by concatenating the root directory address of the resource file stored in the off-heap cache with the target URL information and the target version information.

11. A resource management device, comprising: The first acquisition module is used to acquire the target URL information carried in the browsing request in response to a browsing request for the first target application. The query module is used to query multiple configuration information stored in the heap cache based on the target URL information to determine the target version information of the first target application, wherein the multiple configuration information includes information obtained from the configuration server cluster by executing information synchronization instructions; The first determining module is used to determine target key-value pair information based on the target URL information and the target version information; and The second acquisition module is used to acquire the resource files of the first target application from the off-heap cache based on the target key-value pair information; Among them, the in-heap cache is a cache that allocates memory objects within the virtual machine's heap, while the off-heap cache is a cache that allocates memory objects outside the virtual machine's heap. The target key-value pair information includes primary key information and attribute value information. The primary key information is obtained by concatenating the target URL information and the target version information. The attribute value information is obtained by concatenating the root directory address of the resource file stored in the off-heap cache with the target URL information and the target version information.

12. A resource management device, comprising: The generation module is used to generate a browsing request for the first target application based on the target URL information; as well as The sending module is configured to send the browsing request to the response server cluster, so that the response server cluster responds to the browsing request by querying multiple configuration information stored in the heap cache based on the target URL information to determine the target version information of the first target application, and by determining the target key-value pair information based on the target URL information and the target version information, and then by retrieving the resource file of the first target application from the off-heap cache based on the target key-value pair information, wherein the multiple configuration information includes information obtained by the response server cluster from the configuration server cluster by executing information synchronization instructions; Among them, the in-heap cache is a cache that allocates memory objects within the virtual machine's heap, while the off-heap cache is a cache that allocates memory objects outside the virtual machine's heap. The target key-value pair information includes primary key information and attribute value information. The primary key information is obtained by concatenating the target URL information and the target version information. The attribute value information is obtained by concatenating the root directory address of the resource file stored in the off-heap cache with the target URL information and the target version information.

13. An electronic device, comprising: One or more processors; Memory, used to store one or more instructions. When the one or more instructions are executed by the one or more processors, the one or more processors cause the one or more processors to implement the method of any one of claims 1 to 9.

14. A computer-readable storage medium having stored thereon executable instructions that, when executed by a processor, cause the processor to perform the method of any one of claims 1 to 9.

15. A computer program product comprising computer-executable instructions, which, when executed, are used to implement the method of any one of claims 1 to 9.

Citation Information

Patent Citations

  • Access request processing method and device, computing equipment and medium

    CN111913738A

  • Embedded web-based management method

    US20060218305A1