CN114356970A - Storage system resource caching method and device - Google Patents

Storage system resource caching method and device Download PDF

Info

Publication number
CN114356970A
CN114356970A CN202111384244.0A CN202111384244A CN114356970A CN 114356970 A CN114356970 A CN 114356970A CN 202111384244 A CN202111384244 A CN 202111384244A CN 114356970 A CN114356970 A CN 114356970A
Authority
CN
China
Prior art keywords
resource
resources
cache
caching
end cache
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202111384244.0A
Other languages
Chinese (zh)
Other versions
CN114356970B (en
Inventor
马聪
谢鹏
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Suzhou Inspur Intelligent Technology Co Ltd
Original Assignee
Suzhou Inspur Intelligent Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Suzhou Inspur Intelligent Technology Co Ltd filed Critical Suzhou Inspur Intelligent Technology Co Ltd
Priority to CN202111384244.0A priority Critical patent/CN114356970B/en
Publication of CN114356970A publication Critical patent/CN114356970A/en
Application granted granted Critical
Publication of CN114356970B publication Critical patent/CN114356970B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

The invention relates to the field of resource caching of storage systems, and particularly discloses a resource caching method and device for a storage system. Meanwhile, the execution state of the resources is monitored in real time, the identification of the resources being executed is unavailable and displayed, a user can check which resources are available and which resources are unavailable, the problem caused by the fact that multiple users/multiple clients operate the same resources at the same time is solved, the system pressure is relieved, and the user experience is improved.

Description

Storage system resource caching method and device
Technical Field
The invention relates to the field of storage system resource caching, in particular to a storage system resource caching method and device.
Background
Browser/Server (Browser/Server mode, B/S for short) architecture utilizes the mature web Browser technology to realize the powerful functions which can be realized only by special software originally, and the development cost is saved. The existing storage management software is based on a B/S framework, so that the interface management of a storage system is realized, a user can realize the resource management of storage through interface operation, and can visually check storage information and perform related operation through a management software interface.
In the face of more and more stored information, especially resource information acquisition in a large-scale cluster, great pressure is brought to management software, much time is consumed for acquiring much information, especially when different clients or multiple users operate and issue requests simultaneously, repeated operation requests of resources may cause operation failure, and the problem directly causes unfriendliness of user experience.
The general method for solving the problems is that the back end caches the information of the query time consumption, and after the management interface queries the data issuing request, the back end directly reads the data from the cache and returns the data. However, this method is too single, which may also cause waste of backend resources, and cannot avoid operation failure caused by simultaneous operation of multiple clients.
Disclosure of Invention
In order to solve the above problems, the present invention provides a method and an apparatus for caching storage resources, which cache storage resources by a method combining local cache and backend cache, and update the status information of the cached resources in real time, thereby not only solving the problem of slow resource information query, but also avoiding the problem caused by the simultaneous operation of the same resources by multiple users/multiple clients, alleviating the system pressure, and improving the user experience.
In a first aspect, a technical solution of the present invention provides a method for caching resources of a storage system, including the following steps:
according to the resource response duration and the access frequency, performing front-end caching and back-end caching on the resources, wherein the front-end caching resources are located in local storage, and the back-end storage resources are located in a database;
when a user issues a resource request operation, if a resource is located in a front-end cache, directly reading resource information from a local storage;
monitoring the resource execution states in the front-end cache and the back-end cache in real time, and marking the resource which is being executed as unavailable;
and displaying the resource identification state.
Further, according to the resource response duration and the access frequency, performing front-end caching and back-end caching on the resource, specifically comprising:
and storing the resources with the response duration exceeding the duration threshold and the access frequency lower than the frequency threshold into a back-end cache, and storing other resources into a front-end cache.
Further, monitoring the resource execution state in the front-end cache in real time, and identifying the resource being executed as unavailable, specifically including:
the front end monitors a task manager interface to obtain the execution state of a resource operation task in a task manager;
identifying resources being executed in the task manager as unavailable in a front-end cache;
and after the resource operation task is executed, updating the resource identification state in the front-end cache according to the execution result.
Further, monitoring the resource execution state in the front-end cache in real time, and identifying the resource being executed as unavailable, the method further comprises the following steps:
when the back end receives the resource operation request, if the resource is located in the front-end cache, pushing a message to the front end through the websocket to update the identification state of the corresponding resource in the front-end cache to be unavailable;
and when the back end receives the resource operation completion information, if the resource is located in the front-end cache, pushing a message to the front end through the websocket, and updating the identification state of the corresponding resource in the front-end cache according to the resource operation execution result.
Further, monitoring the resource execution state in the back-end cache in real time, and identifying the resource being executed as unavailable, specifically including:
when the back end receives the resource operation request, if the resource is located in the back end cache, updating the identification state of the corresponding resource in the back end cache to be unavailable;
and when the back end receives the resource operation completion information, if the resource is positioned in the back end cache, updating the identification state of the corresponding resource in the back end cache according to the resource operation execution result.
In a second aspect, an embodiment of the present invention provides a storage system resource caching apparatus, including,
the resource caching module: according to the resource response duration and the access frequency, performing front-end caching and back-end caching on the resources, wherein the front-end caching resources are located in local storage, and the back-end storage resources are located in a database;
a resource reading module: when a user issues a resource request operation, if a resource is located in a front-end cache, directly reading resource information from a local storage;
a resource state identification module: monitoring the resource execution states in the front-end cache and the back-end cache in real time, and marking the resource which is being executed as unavailable;
a resource state display module: and displaying the resource identification state.
Further, the resource caching module performs front-end caching and back-end caching on the resource according to the resource response duration and the access frequency, and specifically includes:
and storing the resources with the response duration exceeding the duration threshold and the access frequency lower than the frequency threshold into a back-end cache, and storing other resources into a front-end cache.
Further, the resource status identification module monitors the resource execution status in the front-end cache in real time, and identifies the resource being executed as unavailable, specifically including:
the front end monitors a task manager interface to obtain the execution state of a resource operation task in a task manager;
identifying resources being executed in the task manager as unavailable in a front-end cache;
and after the resource operation task is executed, updating the resource identification state in the front-end cache according to the execution result.
Further, the resource status identification module monitors the execution status of the resource in the front-end cache in real time, and identifies the resource being executed as unavailable, and the method further includes:
when the back end receives the resource operation request, if the resource is located in the front-end cache, pushing a message to the front end through the websocket to update the identification state of the corresponding resource in the front-end cache to be unavailable;
and when the back end receives the resource operation completion information, if the resource is located in the front-end cache, pushing a message to the front end through the websocket, and updating the identification state of the corresponding resource in the front-end cache according to the resource operation execution result.
Further, the resource status identification module monitors the resource execution status in the back-end cache in real time, and identifies the resource being executed as unavailable, specifically including:
when the back end receives the resource operation request, if the resource is located in the back end cache, updating the identification state of the corresponding resource in the back end cache to be unavailable;
and when the back end receives the resource operation completion information, if the resource is positioned in the back end cache, updating the identification state of the corresponding resource in the back end cache according to the resource operation execution result.
In a third aspect, a technical solution of the present invention provides a terminal, including:
the memory is used for storing and storing a system resource caching program;
a processor, configured to implement the steps of the storage system resource caching method according to any one of the above descriptions when executing the storage system resource caching program.
In a fourth aspect, an embodiment of the present invention provides a readable storage medium, where a storage system resource caching program is stored on the readable storage medium, and when executed by a processor, the storage system resource caching program implements the steps of the storage system resource caching method according to any one of the above.
Compared with the prior art, the resource caching method, the resource caching device, the terminal and the storage medium of the storage system provided by the invention have the following beneficial effects: and performing front-end caching and back-end caching on the resources according to the response time and the access frequency of the resources, and directly reading resource information from local storage for the operation request of the front-end cached resources, so as to solve the problem of slow query of the resource information. Meanwhile, the execution state of the resources is monitored in real time, the identification of the resources being executed is unavailable and displayed, a user can check which resources are available and which resources are unavailable, the problem caused by the fact that multiple users/multiple clients operate the same resources at the same time is solved, the system pressure is relieved, and the user experience is improved.
Drawings
For a clearer explanation of the embodiments or technical solutions of the prior art of the present application, the drawings needed for the description of the embodiments or prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present application, and for those skilled in the art, other drawings can be obtained according to these drawings without creative efforts.
Fig. 1 is a flowchart illustrating a method for caching resources of a storage system according to an embodiment of the present invention.
Fig. 2 is a schematic block diagram of a structure of a resource caching apparatus of a storage system according to a third embodiment of the present invention.
Fig. 3 is a schematic structural diagram of a terminal according to a fourth embodiment of the present invention.
Detailed Description
In order that those skilled in the art will better understand the disclosure, the following detailed description will be given with reference to the accompanying drawings. It is to be understood that the embodiments described are only a few embodiments of the present application and not all embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
In the face of more and more stored information, especially resource information acquisition in a large-scale cluster, great pressure is brought to management software, much time is consumed for acquiring much information, especially when different clients or multiple users operate and issue requests simultaneously, repeated operation requests of resources may cause operation failure, and the problem directly causes unfriendliness of user experience. The general method for solving the problems is that the back end caches the information of the query time consumption, and after the management interface queries the data issuing request, the back end directly reads the data from the cache and returns the data. However, this method is too single, which may also cause waste of backend resources, and cannot avoid operation failure caused by simultaneous operation of multiple clients.
Therefore, the invention provides a storage resource caching scheme, which caches storage resources by a method of combining local caching and back-end caching, and updates the status information of the cached resources in real time, thereby solving the problem of slow resource information query, avoiding the problem caused by the simultaneous operation of the same resources by multiple users/multiple clients, relieving the pressure of the system and improving the user experience.
Example one
Fig. 1 is a schematic flow chart of a method for caching resources of a storage system according to a first embodiment of the present invention, which includes the following steps.
And S101, performing front-end caching and back-end caching on the resources according to the response time length and the access frequency of the resources, wherein the front-end caching resources are located in a local storage, and the back-end storage resources are located in a database.
It should be noted that the resources include cluster node information and hardware information such as a disk.
In this embodiment, the resources are divided into a front-end cache and a back-end cache according to the response time length and the access frequency of the resources, and specifically, the resources whose response time length exceeds a time length threshold and whose access frequency is lower than a frequency threshold are stored in the back-end cache, and other resources are stored in the front-end cache. Wherein, the access frequency can be 1 month.
That is, the resources with short response time and high access frequency are placed in the front-end cache, and the front-end cache is the local cache. The local cache is a permanent storage, data still exists after the browser is turned off and turned on again, and the browser with the upper limit of the capacity generally defaults to 4M.
S102, when the user issues the resource request operation, if the resource is located in the front-end cache, the resource information is directly read from the local storage.
The resource is divided into a front-end cache and a back-end cache, when a user issues a resource request operation, whether the resource is cached at the front end or the back end is judged firstly, and for the resource located at the front-end cache, the resource information is directly read from the local storage.
In addition, when the user operation interface is used for resource creation or query, the request is not sent to the back end, and the resource information is directly read from the local cache.
Because the resources with short response time and high access frequency are cached at the front end, the resources are cached at the front end with high probability when the request is issued by the user, most of the resources can be directly read from the front end cache, and the problem of slow resource information query is greatly solved.
Of course, for resources stored in the back-end cache, the resource information needs to be read from the back-end database.
It should be noted that, as the running time is prolonged and the access frequency of the resource changes, the resource can be dynamically adjusted in the front-end cache and the back-end cache.
S103, monitoring the resource execution states in the front-end cache and the back-end cache in real time, and marking the resource being executed as unavailable.
And S104, displaying the resource identification state.
In order to solve the problem that the request fails because the request is simultaneously issued by multi-user operation aiming at the same resource, the embodiment monitors the execution state of the resource in real time and identifies the resource which is being executed and can not be used, so that a user can check the resource use state at any time, the request is not issued to the resource which can not be used any more, and the operation failure is avoided. For example, if user a is using disk a, disk a is identified as unavailable, and no other users issue requests to disk a.
In the resource caching method for the storage system provided by this embodiment, the resources are subjected to front-end caching and back-end caching according to the resource response time and the access frequency, and for the operation request of the front-end caching resources, the resource information is directly read from the local storage, so that the problem of slow query of the resource information is solved. Meanwhile, the execution state of the resources is monitored in real time, the identification of the resources being executed is unavailable and displayed, a user can check which resources are available and which resources are unavailable, the problem caused by the fact that multiple users/multiple clients operate the same resources at the same time is solved, the system pressure is relieved, and the user experience is improved.
Example two
In view of the process of monitoring the execution state of the resource and identifying the resource, the second embodiment provides a method for caching the resource of the storage system, where the resource is monitored at the front end through a task manager interface, and when a resource operation request is received at the rear end and the resource operation is completed, a message is pushed to the front end through a websocket (a protocol for performing full duplex communication on a single TCP connection) for the resource at the front end, so that the resource identification state is updated by the resource cached at the front end, and the resource identification state in the database is directly updated for the resource at the rear end.
The second embodiment provides a method for caching resources of a storage system, which includes the following steps.
The method comprises the following steps that firstly, a front end monitors a task manager interface, and the execution state of a resource operation task in a task manager is obtained.
And step two, identifying the resources which are executing in the task manager as unavailable in the front-end cache.
And step three, after the resource operation task is executed, updating the resource identification state in the front-end cache according to the execution result.
It should be noted that, in step two, the resource being executed is identified as unavailable, and other resources that are not executed may be identified as available, or not identified, so that the user knows which resources are available.
In the third step, the resource is released or not released according to the resource execution result, and for the released resource, the resource is indicated to be available, and the identification state of the resource is set to be available.
And for the resource operation request received by the back end, the back end interacts with the front end, and the resource identification state in the front end cache or the back end cache is updated in real time.
Therefore, the method for caching the resources of the storage system provided by the second embodiment further includes the following steps.
Step one, when a back end receives a resource operation request, if a resource is located in a front-end cache, pushing a message to the front end through a websocket to update the identification state of the corresponding resource in the front-end cache to be unavailable; and if the resource is positioned in the back-end cache, updating the identification state of the corresponding resource in the back-end cache to be unavailable.
Step two, when the back end receives the resource operation completion information, if the resource is located in the front-end cache, pushing a message to the front end through the websocket, and updating the identification state of the corresponding resource in the front-end cache according to the resource operation execution result; and if the resource is positioned in the back-end cache, updating the identification state of the corresponding resource in the back-end cache according to the resource operation execution result.
EXAMPLE III
The third embodiment provides a storage system resource caching device, which is used for implementing the storage system resource caching method.
Fig. 2 is a schematic block diagram of a structure of a resource caching apparatus of a storage system according to a third embodiment of the present invention, which includes the following functional modules.
The resource caching module 101: and performing front-end caching and back-end caching on the resources according to the response time length and the access frequency of the resources, wherein the front-end caching resources are located in a local storage, and the back-end storage resources are located in a database.
The resource reading module 102: when a user issues a resource request operation, if the resource is located in the front-end cache, the resource information is directly read from the local storage.
The resource status identification module 103: and monitoring the resource execution states in the front-end cache and the back-end cache in real time, and identifying the resource which is being executed as unavailable.
The resource status display module 104: and displaying the resource identification state.
In some specific embodiments, the resource caching module 101 performs front-end caching and back-end caching on the resource according to the resource response duration and the access frequency, specifically: and storing the resources with the response duration exceeding the duration threshold and the access frequency lower than the frequency threshold into a back-end cache, and storing other resources into a front-end cache.
In some specific embodiments, the resource status identification module 103 monitors the execution status of the resource in the front-end cache in real time, and identifies the resource being executed as unavailable, specifically including:
the front end monitors a task manager interface to obtain the execution state of a resource operation task in a task manager;
identifying resources being executed in the task manager as unavailable in a front-end cache;
after the resource operation task is executed, updating the resource identification state in the front-end cache according to the execution result;
when the back end receives the resource operation request, if the resource is located in the front-end cache, pushing a message to the front end through the websocket to update the identification state of the corresponding resource in the front-end cache to be unavailable;
and when the back end receives the resource operation completion information, if the resource is located in the front-end cache, pushing a message to the front end through the websocket, and updating the identification state of the corresponding resource in the front-end cache according to the resource operation execution result.
In some specific embodiments, the resource status identification module 103 monitors the execution status of the resource in the back-end cache in real time, and identifies the resource being executed as unavailable, specifically including:
when the back end receives the resource operation request, if the resource is located in the back end cache, updating the identification state of the corresponding resource in the back end cache to be unavailable;
and when the back end receives the resource operation completion information, if the resource is positioned in the back end cache, updating the identification state of the corresponding resource in the back end cache according to the resource operation execution result.
The storage system resource caching device of this embodiment is used to implement the foregoing storage system resource caching method, and therefore a specific implementation of the device may be found in the foregoing embodiment section of the storage system resource caching method, and therefore, the specific implementation thereof may refer to the description of the corresponding respective embodiment sections, and is not described herein again.
In addition, since the storage system resource caching apparatus of this embodiment is used to implement the foregoing storage system resource caching method, the role thereof corresponds to that of the foregoing method, and details are not described here.
Example four
Fig. 3 is a schematic structural diagram of a terminal device 300 according to an embodiment of the present invention, including: a processor 310, a memory 320, and a communication unit 330. The processor 310 is configured to implement the storage system resource cache program stored in the memory 320 by:
according to the resource response duration and the access frequency, performing front-end caching and back-end caching on the resources, wherein the front-end caching resources are located in local storage, and the back-end storage resources are located in a database;
when a user issues a resource request operation, if a resource is located in a front-end cache, directly reading resource information from a local storage;
monitoring the resource execution states in the front-end cache and the back-end cache in real time, and marking the resource which is being executed as unavailable;
and displaying the resource identification state.
According to the method and the device, the resources are subjected to front-end caching and rear-end caching according to the response time length and the access frequency of the resources, the resource information is directly read from the local storage for the operation request of the front-end caching resources, and the problem of slow resource information query is solved. Meanwhile, the execution state of the resources is monitored in real time, the identification of the resources being executed is unavailable and displayed, a user can check which resources are available and which resources are unavailable, the problem caused by the fact that multiple users/multiple clients operate the same resources at the same time is solved, the system pressure is relieved, and the user experience is improved.
In some embodiments, when the processor 310 executes the storage system resource cache subprogram stored in the memory 320, the following may be specifically implemented: and storing the resources with the response duration exceeding the duration threshold and the access frequency lower than the frequency threshold into a back-end cache, and storing other resources into a front-end cache.
In some embodiments, when the processor 310 executes the storage system resource cache subprogram stored in the memory 320, the following may be specifically implemented: the front end monitors a task manager interface to obtain the execution state of a resource operation task in a task manager; identifying resources being executed in the task manager as unavailable in a front-end cache; and after the resource operation task is executed, updating the resource identification state in the front-end cache according to the execution result.
In some embodiments, when the processor 310 executes the storage system resource cache subprogram stored in the memory 320, the following may be specifically implemented: when the back end receives the resource operation request, if the resource is located in the front-end cache, pushing a message to the front end through the websocket to update the identification state of the corresponding resource in the front-end cache to be unavailable; and when the back end receives the resource operation completion information, if the resource is located in the front-end cache, pushing a message to the front end through the websocket, and updating the identification state of the corresponding resource in the front-end cache according to the resource operation execution result.
In some embodiments, when the processor 310 executes the storage system resource cache subprogram stored in the memory 320, the following may be specifically implemented: when the back end receives the resource operation request, if the resource is located in the back end cache, updating the identification state of the corresponding resource in the back end cache to be unavailable; and when the back end receives the resource operation completion information, if the resource is positioned in the back end cache, updating the identification state of the corresponding resource in the back end cache according to the resource operation execution result.
The terminal device 300 includes a processor 310, a memory 320, and a communication unit 330. The components communicate via one or more buses, and those skilled in the art will appreciate that the architecture of the servers shown in the figures is not intended to be limiting, and may be a bus architecture, a star architecture, a combination of more or less components than those shown, or a different arrangement of components.
The memory 320 may be used for storing instructions executed by the processor 310, and the memory 320 may be implemented by any type of volatile or non-volatile storage terminal or combination thereof, such as Static Random Access Memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic disk or optical disk. The executable instructions in memory 320, when executed by processor 310, enable terminal 300 to perform some or all of the steps in the method embodiments described below.
The processor 310 is a control center of the storage terminal, connects various parts of the entire electronic terminal using various interfaces and lines, and performs various functions of the electronic terminal and/or processes data by operating or executing software programs and/or modules stored in the memory 320 and calling data stored in the memory. The processor may be composed of an Integrated Circuit (IC), for example, a single packaged IC, or a plurality of packaged ICs connected with the same or different functions. For example, the processor 310 may include only a Central Processing Unit (CPU). In the embodiment of the present invention, the CPU may be a single operation core, or may include multiple operation cores.
A communication unit 330, configured to establish a communication channel so that the storage terminal can communicate with other terminals. And receiving user data sent by other terminals or sending the user data to other terminals.
EXAMPLE five
The present invention also provides a computer storage medium, wherein the storage medium may be a magnetic disk, an optical disk, a read-only memory (ROM) or a Random Access Memory (RAM).
The computer storage medium stores a storage system resource caching program that when executed by a processor performs the steps of:
according to the resource response duration and the access frequency, performing front-end caching and back-end caching on the resources, wherein the front-end caching resources are located in local storage, and the back-end storage resources are located in a database;
when a user issues a resource request operation, if a resource is located in a front-end cache, directly reading resource information from a local storage;
monitoring the resource execution states in the front-end cache and the back-end cache in real time, and marking the resource which is being executed as unavailable;
and displaying the resource identification state.
According to the method and the device, the resources are subjected to front-end caching and rear-end caching according to the response time length and the access frequency of the resources, the resource information is directly read from the local storage for the operation request of the front-end caching resources, and the problem of slow resource information query is solved. Meanwhile, the execution state of the resources is monitored in real time, the identification of the resources being executed is unavailable and displayed, a user can check which resources are available and which resources are unavailable, the problem caused by the fact that multiple users/multiple clients operate the same resources at the same time is solved, the system pressure is relieved, and the user experience is improved.
In some embodiments, when the storage system resource caching sub-program stored in the readable storage medium is executed by the processor, the method may specifically implement: and storing the resources with the response duration exceeding the duration threshold and the access frequency lower than the frequency threshold into a back-end cache, and storing other resources into a front-end cache.
In some embodiments, when the storage system resource caching sub-program stored in the readable storage medium is executed by the processor, the method may specifically implement: the front end monitors a task manager interface to obtain the execution state of a resource operation task in a task manager; identifying resources being executed in the task manager as unavailable in a front-end cache; and after the resource operation task is executed, updating the resource identification state in the front-end cache according to the execution result.
In some embodiments, when the storage system resource caching sub-program stored in the readable storage medium is executed by the processor, the method may specifically implement: when the back end receives the resource operation request, if the resource is located in the front-end cache, pushing a message to the front end through the websocket to update the identification state of the corresponding resource in the front-end cache to be unavailable; and when the back end receives the resource operation completion information, if the resource is located in the front-end cache, pushing a message to the front end through the websocket, and updating the identification state of the corresponding resource in the front-end cache according to the resource operation execution result.
In some embodiments, when the storage system resource caching sub-program stored in the readable storage medium is executed by the processor, the method may specifically implement: when the back end receives the resource operation request, if the resource is located in the back end cache, updating the identification state of the corresponding resource in the back end cache to be unavailable; and when the back end receives the resource operation completion information, if the resource is positioned in the back end cache, updating the identification state of the corresponding resource in the back end cache according to the resource operation execution result.
Those skilled in the art will readily appreciate that the techniques of the embodiments of the present invention may be implemented as software plus a required general purpose hardware platform. Based on such understanding, the technical solutions in the embodiments of the present invention may be embodied in the form of a software product, where the computer software product is stored in a storage medium, such as a usb disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and the like, and the storage medium can store program codes, and includes instructions for enabling a computer terminal (which may be a personal computer, a server, or a second terminal, a network terminal, and the like) to perform all or part of the steps of the method in the embodiments of the present invention.
In the embodiments provided in the present invention, it should be understood that the disclosed system, apparatus and method may be implemented in other ways. For example, the above-described apparatus embodiments are merely illustrative, and for example, the division of the units is only one logical division, and other divisions may be realized in practice, for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may be in an electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present invention may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit.
The above disclosure is only for the preferred embodiments of the present invention, but the present invention is not limited thereto, and any non-inventive changes that can be made by those skilled in the art and several modifications and amendments made without departing from the principle of the present invention shall fall within the protection scope of the present invention.

Claims (10)

1. A method for caching storage system resources is characterized by comprising the following steps:
according to the resource response duration and the access frequency, performing front-end caching and back-end caching on the resources, wherein the front-end caching resources are located in local storage, and the back-end storage resources are located in a database;
when a user issues a resource request operation, if a resource is located in a front-end cache, directly reading resource information from a local storage;
monitoring the resource execution states in the front-end cache and the back-end cache in real time, and marking the resource which is being executed as unavailable;
and displaying the resource identification state.
2. The method for caching resources of a storage system according to claim 1, wherein the front-end caching and the back-end caching of the resources are performed according to the response duration and the access frequency of the resources, and specifically comprises:
and storing the resources with the response duration exceeding the duration threshold and the access frequency lower than the frequency threshold into a back-end cache, and storing other resources into a front-end cache.
3. The method for caching resources in a storage system according to claim 2, wherein the monitoring of the execution state of resources in the front-end cache in real time and the identification of the executing resources as unavailable includes:
the front end monitors a task manager interface to obtain the execution state of a resource operation task in a task manager;
identifying resources being executed in the task manager as unavailable in a front-end cache;
and after the resource operation task is executed, updating the resource identification state in the front-end cache according to the execution result.
4. The method for caching resources in a storage system according to claim 3, wherein the resource execution status in the front-end cache is monitored in real time, and the resource being executed is identified as unavailable, and further comprising:
when the back end receives the resource operation request, if the resource is located in the front-end cache, pushing a message to the front end through the websocket to update the identification state of the corresponding resource in the front-end cache to be unavailable;
and when the back end receives the resource operation completion information, if the resource is located in the front-end cache, pushing a message to the front end through the websocket, and updating the identification state of the corresponding resource in the front-end cache according to the resource operation execution result.
5. The method for caching resources in a storage system according to claim 4, wherein the monitoring of the execution state of resources in the back-end cache in real time and the identification of the executing resources as unavailable includes:
when the back end receives the resource operation request, if the resource is located in the back end cache, updating the identification state of the corresponding resource in the back end cache to be unavailable;
and when the back end receives the resource operation completion information, if the resource is positioned in the back end cache, updating the identification state of the corresponding resource in the back end cache according to the resource operation execution result.
6. A storage system resource caching apparatus, comprising,
the resource caching module: according to the resource response duration and the access frequency, performing front-end caching and back-end caching on the resources, wherein the front-end caching resources are located in local storage, and the back-end storage resources are located in a database;
a resource reading module: when a user issues a resource request operation, if a resource is located in a front-end cache, directly reading resource information from a local storage;
a resource state identification module: monitoring the resource execution states in the front-end cache and the back-end cache in real time, and marking the resource which is being executed as unavailable;
a resource state display module: and displaying the resource identification state.
7. The device for caching resources in a storage system according to claim 6, wherein the resource caching module performs front-end caching and back-end caching on the resources according to the response time and the access frequency of the resources, and specifically comprises:
and storing the resources with the response duration exceeding the duration threshold and the access frequency lower than the frequency threshold into a back-end cache, and storing other resources into a front-end cache.
8. The device for caching resources in a storage system according to claim 7, wherein the resource status identification module monitors an execution status of a resource in the front-end cache in real time, and identifies the resource being executed as unavailable, and specifically includes:
the front end monitors a task manager interface to obtain the execution state of a resource operation task in a task manager;
identifying resources being executed in the task manager as unavailable in a front-end cache;
and after the resource operation task is executed, updating the resource identification state in the front-end cache according to the execution result.
9. The apparatus of claim 8, wherein the resource status identification module monitors the execution status of the resource in the front-end cache in real time, and identifies the resource being executed as unavailable, further comprising:
when the back end receives the resource operation request, if the resource is located in the front-end cache, pushing a message to the front end through the websocket to update the identification state of the corresponding resource in the front-end cache to be unavailable;
and when the back end receives the resource operation completion information, if the resource is located in the front-end cache, pushing a message to the front end through the websocket, and updating the identification state of the corresponding resource in the front-end cache according to the resource operation execution result.
10. The device for caching resources in a storage system according to claim 9, wherein the resource status identification module monitors an execution status of a resource in a back-end cache in real time, and identifies the resource being executed as unavailable, and specifically includes:
when the back end receives the resource operation request, if the resource is located in the back end cache, updating the identification state of the corresponding resource in the back end cache to be unavailable;
and when the back end receives the resource operation completion information, if the resource is positioned in the back end cache, updating the identification state of the corresponding resource in the back end cache according to the resource operation execution result.
CN202111384244.0A 2021-11-19 2021-11-19 Storage system resource caching method and device Active CN114356970B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111384244.0A CN114356970B (en) 2021-11-19 2021-11-19 Storage system resource caching method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111384244.0A CN114356970B (en) 2021-11-19 2021-11-19 Storage system resource caching method and device

Publications (2)

Publication Number Publication Date
CN114356970A true CN114356970A (en) 2022-04-15
CN114356970B CN114356970B (en) 2023-11-07

Family

ID=81096117

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111384244.0A Active CN114356970B (en) 2021-11-19 2021-11-19 Storage system resource caching method and device

Country Status (1)

Country Link
CN (1) CN114356970B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117614956A (en) * 2024-01-24 2024-02-27 合肥综合性国家科学中心人工智能研究院(安徽省人工智能实验室) Intra-network caching method and system for distributed storage and storage medium

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112015674A (en) * 2020-08-27 2020-12-01 平安科技(深圳)有限公司 Cache resource access method and device based on multiple hierarchies and computer equipment

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112015674A (en) * 2020-08-27 2020-12-01 平安科技(深圳)有限公司 Cache resource access method and device based on multiple hierarchies and computer equipment

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117614956A (en) * 2024-01-24 2024-02-27 合肥综合性国家科学中心人工智能研究院(安徽省人工智能实验室) Intra-network caching method and system for distributed storage and storage medium
CN117614956B (en) * 2024-01-24 2024-03-29 合肥综合性国家科学中心人工智能研究院(安徽省人工智能实验室) Intra-network caching method and system for distributed storage and storage medium

Also Published As

Publication number Publication date
CN114356970B (en) 2023-11-07

Similar Documents

Publication Publication Date Title
US20180285216A1 (en) Virtual Machine Recovery Method and Virtual Machine Management Device
CN112235136B (en) Network file system backup method, system, terminal and storage medium
CN114257551A (en) Distributed current limiting method and system and storage medium
CN111475519A (en) Data caching method and device
CN110928681A (en) Data processing method and device, storage medium and electronic device
CN113051102B (en) File backup method, device, system, storage medium and computer equipment
CN114356970A (en) Storage system resource caching method and device
CN109710679B (en) Data extraction method and device
CN111124437A (en) Bare computer resource configuration information acquisition method, system and equipment based on OpenStack
CN114448972A (en) Distributed storage log compression downloading method, system, terminal and storage medium
CN112804330B (en) Application communication method and device
CN111049913B (en) Data file transmission method and device, storage medium and electronic equipment
CN109992420B (en) Parallel PCIE-SSD performance optimization method and system
CN112181942A (en) Time sequence database system and data processing method and device
CN111092774A (en) Configuration method and equipment of acquisition gateway
CN109962941B (en) Communication method, device and server
CN112463399A (en) Server BMC information management method, system, terminal and storage medium
CN115658745A (en) Data processing method, data processing device, computer equipment and computer readable storage medium
CN113704177B (en) Storage method, system and related components of server firmware upgrade file
CN114995770A (en) Data processing method, device, equipment, system and readable storage medium
CN113297516A (en) Customer interaction interface generation method and device and electronic equipment
CN110290435B (en) Optical fiber network management method and device and terminal equipment
CN114020214A (en) Storage cluster capacity expansion method and device, electronic equipment and readable storage medium
CN111752911A (en) Data transmission method, system, terminal and storage medium based on Flume
CN113656378A (en) Server management method, device and medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant