Data processing method, system, electronic device, storage medium and program product

By compressing and storing data in an independent compressed cache during system cache reclamation events, the performance problem of data access in file systems when the system cache is not hit is solved, achieving efficient management of metadata and optimized utilization of memory resources, thereby improving the data access performance of the file system.

CN123047852APending Publication Date: 2026-11-06BEIJING X RING TECHNOLOGY CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202610129693.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-01-29
Publication Date
2026-11-06

AI Technical Summary

Technical Problem

When the system cache misses, the file system's data access performance degrades. Existing caching mechanisms cannot effectively identify and manage different data access patterns and priorities, leading to wasted memory resources and frequent disk access.

Method used

By compressing target metadata that meets the data compression conditions when the system cache reclamation event is triggered, and storing it in the compressed cache, an independent compressed cache layer is constructed between the system cache and the storage medium, realizing hierarchical management and efficient utilization of metadata.

Benefits of technology

It improved the metadata cache hit rate, reduced disk access overhead, optimized the file system performance on memory-constrained devices, and improved data access speed and memory utilization.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123047852A_ABST
    Figure CN123047852A_ABST
Patent Text Reader

Abstract

This application provides a data processing method, system, electronic device, storage medium, and program product to solve the technical problem of poor data access performance in file systems in related technologies. The method includes: in response to a triggered system cache reclamation event, compressing target metadata in the system cache that meets data compression conditions to obtain compressed metadata corresponding to the target metadata; storing the compressed metadata corresponding to the target metadata in a compressed cache, wherein the compressed cache is an independent cache set between the system cache and the storage medium. The independent compressed cache shortens the metadata access path, reduces the number of levels, accelerates metadata lookup speed, and quickly responds to upper-layer file access requests. Based on an intelligent decision-making mechanism for data compression conditions, high-value metadata is accurately retained, and memory usage is reduced through compression, improving memory utilization while reducing storage medium I / O overhead. Thus, file system data access performance is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of data processing technology, and in particular to data processing methods, systems, electronic devices, storage media, and program products. Background Technology

[0002] Electronic devices rely on file systems for data interaction and file management functions of their applications. A file system not only defines the data storage format and directory structure but also enables fast file location and efficient management through metadata. File system management of metadata depends on system caching. When requested metadata cannot be found in the system cache, it directly leads to a degrade in file system data access performance. Summary of the Invention

[0003] To overcome the technical problem of poor data access performance in file systems in related technologies, this application provides a data processing method, system, electronic device, storage medium, and program product.

[0004] According to a first aspect of the embodiments of this application, a data processing method is provided. The data processing method includes: in response to triggering a system cache reclamation event, compressing target metadata in the system cache that meets the data compression conditions to obtain compressed metadata corresponding to the target metadata; and storing the compressed metadata corresponding to the target metadata in a compressed cache, wherein the compressed cache is an independent cache set between the system cache and the storage medium.

[0005] In some possible implementations, compressing the target metadata in the system cache that meets the data compression conditions includes: determining, based on the metadata in the system cache corresponding to the system cache eviction event, that the metadata corresponding to the system cache eviction event is the target metadata that meets the data compression conditions; and compressing the target metadata to obtain the compressed metadata corresponding to the target metadata in response to the metadata corresponding to the system cache eviction event being the target metadata that meets the data compression conditions.

[0006] In some possible implementations, determining the metadata corresponding to the system cache reclamation event as target metadata that meets the data compression conditions includes: determining the target metadata in the system cache that meets the data compression conditions based on the attribute information and / or memory status information of the metadata corresponding to the system cache reclamation event; wherein, the attribute information includes at least one of the metadata's data size, data type, and access frequency; and the memory status information includes the remaining storage space of the compressed cache.

[0007] In some possible implementations, the data compression conditions are met, including at least one of the following: the remaining storage space of the compressed cache is greater than the capacity threshold; the data size of the metadata corresponding to the system cache reclamation event is within a preset compression size range; the metadata corresponding to the system cache reclamation event is within a preset access frequency range; and the data type of the metadata corresponding to the system cache reclamation event belongs to a preset compressible data type.

[0008] In some possible implementations, triggering a system cache eviction event includes: in response to a metadata read request, searching for the metadata corresponding to the metadata read request in the system cache; in response to the system cache not finding the metadata corresponding to the metadata read request, determining that the triggering condition for the system cache eviction event is met; and in response to the system cache eviction event being triggered, triggering the system cache eviction event.

[0009] In some possible implementations, storing the compressed metadata corresponding to the target metadata into a compressed cache includes: storing the compressed metadata corresponding to the target metadata into a compressed cache in response to the remaining storage space of the compressed cache being greater than a capacity threshold; and deleting at least one original compressed data in the compressed cache in response to the remaining storage space of the compressed cache being less than or equal to the capacity threshold, and storing the compressed metadata corresponding to the target metadata into the compressed cache.

[0010] In some possible implementations, the method further includes: in response to a metadata read request, searching for the metadata corresponding to the metadata read request in the system cache; in response to the metadata corresponding to the metadata read request not being found in the system cache, searching for the compressed metadata corresponding to the metadata read request in the compressed cache; and in response to the compressed metadata corresponding to the metadata read request not being found in the compressed cache, reading the metadata corresponding to the metadata read request from the storage medium.

[0011] In some possible implementations, the method further includes: in response to finding the compressed metadata corresponding to the metadata read request in the compressed cache, decompressing the compressed metadata corresponding to the metadata read request, and obtaining the metadata information corresponding to the metadata read request.

[0012] In some possible implementations, the method further includes: decompressing the compressed metadata corresponding to the metadata read request in the compressed cache in response to the completion of decompression of the compressed metadata corresponding to the metadata read request and in response to the compressed metadata corresponding to the metadata read request meeting the deletion conditions.

[0013] In some possible implementations, in response to a metadata read request, searching for the metadata corresponding to the metadata read request in the system cache includes: in response to the metadata read request, obtaining metadata tagging information corresponding to the metadata read request; the metadata tagging information includes at least one of an inode number, a directory entry identifier, and a path hash value of a file or directory; and searching for the metadata corresponding to the metadata read request in the system cache based on the tagging information.

[0014] In some possible implementations, the method further includes: updating the compressed cache record based on the access frequency of the compressed metadata in response to storing the compressed metadata corresponding to the target metadata into the compressed cache; and decompressing and loading the compressed metadata with an access frequency higher than a preset frequency threshold into the system cache in response to system startup or file system mounting, according to the compressed cache record.

[0015] In some possible implementations, a system cache reclamation event includes at least one of the following: the remaining system memory storage space is less than or equal to a capacity threshold; the system issues an active memory reclamation command; or the file is closed.

[0016] According to a second aspect of the embodiments of this application, a data processing system is provided, the data processing system comprising: a metadata compression module and a metadata storage module; the metadata compression module is configured to compress target metadata in the system cache that meets the data compression conditions in response to triggering a system cache reclamation event, thereby obtaining compressed metadata corresponding to the target metadata; the metadata storage module is configured to store the compressed metadata corresponding to the target metadata into a compressed cache, the compressed cache being an independent cache set between the system cache and the storage medium.

[0017] In some possible implementations, the data processing system further includes: a compression decision module: the compression decision module is configured to determine, based on the metadata in the system cache corresponding to the system cache eviction event, that the metadata corresponding to the system cache eviction event is the target metadata that meets the data compression conditions; and a metadata compression module is configured to compress the target metadata to obtain compressed metadata corresponding to the target metadata in response to the metadata corresponding to the system cache eviction event being the target metadata that meets the data compression conditions.

[0018] In some possible implementations, the compression decision module is configured to: determine the target metadata in the system cache that meets the data compression conditions based on the attribute information of the metadata corresponding to the system cache reclamation event and the memory state information of the system; wherein, the attribute information includes at least one of the metadata's data size, data type, and access frequency; and the memory state information includes the remaining storage space of the compression cache.

[0019] In some possible implementations, the metadata reading module is configured to: search for the metadata corresponding to the metadata reading request in the system cache in response to the metadata reading request; search for the compressed metadata corresponding to the metadata reading request in the compressed cache in response to the fact that the metadata corresponding to the metadata reading request is not found in the system cache; and read the metadata corresponding to the metadata reading request from the storage medium in response to the fact that the compressed metadata corresponding to the metadata reading request is not found in the compressed cache.

[0020] In some possible implementations, the metadata reading module is configured to: in response to a metadata reading request, obtain metadata tagging information corresponding to the metadata reading request; the metadata tagging information includes at least one of inode number, directory entry identifier, and path hash value of file or directory; and search for the metadata corresponding to the metadata reading request in the system cache based on the tagging information.

[0021] According to a third aspect of the present application, an electronic device is provided, comprising: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, the instructions being executed by the at least one processor to enable the at least one processor to perform the method described in any one of the first aspects.

[0022] According to a fourth aspect of the embodiments of this application, a non-transitory computer-readable storage medium is provided that stores computer instructions for causing a computer to perform the method described in any one of the first aspects.

[0023] According to a fifth aspect of the embodiments of this application, a computer program product is provided, including a computer program and computer instructions for causing a computer to perform the method described in any one of the first aspects.

[0024] The data processing method provided in this application has the following beneficial effects: By performing compression operations on target metadata that meets the data compression conditions and storing it in the compressed cache when the system cache space is triggered by a system cache reclamation event, some metadata originally in the system cache can be stored in the compressed cache. The compression conditions, acting as filtering rules, can accurately retain high-value (e.g., frequently accessed) target metadata that meets the conditions. In other words, metadata that does not meet the compression conditions will not be stored in the compressed cache. Thus, storing high-value target metadata in the compressed cache achieves the optimization goal of retaining high-value metadata while preventing low-value data (e.g., infrequently accessed data) from occupying cache resources. When responding to upper-layer file access requests, if the system cache misses, the search can continue in the compressed cache, avoiding the need to search in the storage medium if the system cache misses, significantly accelerating the search speed. Simultaneously, frequent readings from the storage medium (disk / flash memory) are eliminated, greatly reducing the overhead of low-speed I / O interactions. As can be seen, this application improves the metadata cache hit rate, reduces disk access overhead, and optimizes the file system's performance on memory-constrained devices at the cost of relatively low memory consumption, thereby improving the file system's data access performance.

[0025] Furthermore, the compressed cache, as an independent cache layer between the system cache and the storage medium, forms a two-level cache structure of system cache and compressed cache, and a three-level access path between the system cache, compressed cache, and storage medium. This eliminates the need to traverse redundant cache layers during metadata lookups, significantly reducing the time overhead of layer jumps. Shorter cache access paths and fewer layers accelerate metadata lookups, quickly respond to upper-level file access requests, and improve data access performance.

[0026] Furthermore, the original target metadata is significantly reduced in size after compression. With the same memory space, the compressed cache can store more high-value metadata, and the memory cost per piece of metadata is significantly reduced. At the same time, because the system cache reclaims the space of the compressed metadata, it can be reallocated to new metadata (such as file metadata accessed in real time), avoiding the waste of memory resources and achieving high memory utilization.

[0027] It should be understood that the above general description and the following detailed description are exemplary and explanatory only, and do not limit this application. Attached Figure Description

[0028] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this application and, together with the description, serve to explain the principles of this application.

[0029] Figure 1 A flowchart illustrating a data processing method provided in an embodiment of this application;

[0030] Figure 2 A flowchart illustrating a data processing method provided in an embodiment of this application; Figure 3 A flowchart illustrating a data processing method provided in an embodiment of this application; Figure 4 A flowchart illustrating a data processing method provided in an embodiment of this application; Figure 5 This is a schematic diagram of the architecture of a data processing apparatus according to some embodiments of this application; Figure 6 This is a schematic diagram illustrating an application scenario of a data processing apparatus according to some embodiments of this application; Figure 7 This is a schematic diagram of the structure of an electronic device according to some embodiments of this application. Detailed Implementation

[0031] Some embodiments of this application will be described in detail herein, examples of which are illustrated in the accompanying drawings. When the following description refers to the drawings, unless otherwise indicated, the same numbers in different drawings represent the same or similar elements. Various changes, modifications, and equivalents of the methods, apparatus, and / or systems described herein will become apparent upon understanding this application. For example, the order of operations described herein is merely illustrative and is not limited to those orders set forth herein, but can be changed as will become apparent upon understanding this application, except for operations that must be performed in a specific order. Furthermore, for clarity and brevity, descriptions of features known in the art may be omitted.

[0032] The embodiments described in the following examples of this application do not represent all embodiments consistent with this application. Rather, they are merely examples of apparatuses and methods consistent with some aspects of this application as detailed in the appended claims.

[0033] Electronic devices, as the core carriers of data processing and interaction, need to continuously perform basic operations such as data storage, retrieval, modification, and deletion. The efficient execution of these operations relies on the operating system's unified coordination and management control of hardware resources and software behavior. As the core software layer of electronic devices, the operating system undertakes key responsibilities such as hardware abstraction, resource scheduling, process management, and data management. Among these, data management is a crucial link in ensuring the stable operation of applications and convenient user operation. How to organize, quickly retrieve, and securely manage massive amounts of data on storage devices such as disks and flash memory is one of the key problems that operating systems need to solve.

[0034] To address the aforementioned data management issues, the file system, as a core component of the operating system, was developed.

[0035] A file system, a core component of an operating system, is a mechanism for managing and organizing file data on storage devices. It provides users and applications with structured data storage, retrieval, updating, and management capabilities, shielding users from the physical storage details of data on the storage medium. The file system not only defines the file storage format and logical organizational structure but also manages and controls file access permissions, attribute information, directory hierarchy, and the physical location mapping of files on storage media such as disks. This allows users and applications to access data without needing to concern themselves with the physical storage address, achieving data access solely through logical methods such as filenames and paths, thus reducing the complexity of data operations.

[0036] To overcome the access bottleneck of low-speed storage media such as disks and improve the read and write performance and response speed of file systems, related technologies introduce memory caching mechanisms in operating systems to temporarily store frequently accessed data in high-speed memory, thereby reducing the frequency of access to low-speed storage media.

[0037] However, the overall performance of a file system depends on cache hit rate and available memory capacity, and the performance constraints caused by this dependency are particularly prominent. When system memory is insufficient, the operating system will actively trigger a cache reclamation strategy, discarding some cached content to free up space for critical tasks. This leads to a sharp drop in cache hit rate, requiring the system to frequently access the underlying storage medium, resulting in slower response times, increased access latency, and other problems that severely impact business efficiency. Among the various factors affecting the overall performance of a file system, metadata access efficiency is the core determining factor, and the rationality of its cache management directly determines the file system's cache hit rate and overall performance.

[0038] For example, page caching can be used as a core caching mechanism to uniformly cache metadata and file content. However, in practical applications, this mechanism exposes many adaptability flaws and struggles to meet the needs of memory-constrained devices. First, the existing page cache mechanism adopts a uniform management strategy for all cached data, lacking the ability to identify and differentiate different data access patterns and priorities. This easily leads to high-priority, frequently accessed critical metadata being squeezed out by low-priority data and prematurely reclaimed, resulting in a low cache hit rate, low memory utilization efficiency, increased unnecessary disk access requests, and dragging down overall system performance. Second, metadata often consists of a large number of small data blocks, while the design philosophy of page cache focuses on optimizing the caching efficiency of large sequential data blocks. The poor compatibility between the two not only easily causes memory fragmentation but also wastes valuable memory resources, further exacerbating the caching pressure on memory-constrained devices.

[0039] To address the above issues, this application provides a data processing method suitable for memory-constrained electronic devices. By independently compressing and caching metadata, it shortens the metadata access path, reduces the number of layers, accelerates metadata lookup, and quickly responds to upper-layer file access requests. Based on an intelligent decision-making mechanism for data compression conditions, it accurately retains high-value metadata and reduces memory usage through compression, improving metadata cache hit rate and memory utilization while reducing storage media I / O overhead. This, in turn, enhances file system data access performance.

[0040] Figure 1 This is a flowchart illustrating a data processing method provided in an embodiment of this application. Figure 1 As shown, in some embodiments, the data processing method includes: S101, in response to the triggering of the system cache reclamation event, compresses the target metadata in the system cache that meets the data compression conditions to obtain the compressed metadata corresponding to the target metadata.

[0041] In some embodiments, a system cache reclamation event is used to characterize an operation instruction for reclamating system cache space. It can be a cache resource release action triggered collaboratively by the operating system's memory management module and the file system, used to alleviate memory resource pressure and optimize cache utilization.

[0042] In some embodiments, the system cache recycling event includes at least one of the following: The remaining system memory storage space is less than or equal to a capacity threshold. For example, the kernel's Memory Management (MM) subsystem in the operating system continuously monitors the total available system memory. When the remaining system memory storage space falls below a preset capacity threshold, a system cache reclamation event is triggered. For instance, the total system cache capacity is 10GB, and the preset capacity threshold is 1GB. When the remaining space is less than or equal to 1GB, the triggering condition is met, and old metadata needs to be reclaimed to make room for new metadata.

[0043] The system issues proactive memory reclamation commands. These commands are used to selectively reclaim replaceable cache within the file system. For example, in response to the system needing to reserve memory for sudden tasks, the kernel's memory management module can trigger proactive memory reclamation commands. Another example is when executing periodic memory optimization strategies; the kernel issues proactive memory reclamation commands when it receives a memory optimization request from an upper-layer framework.

[0044] The file is closed. For example, the file handle of the target file is closed. For instance, after the application completes file operations and closes the file handle of the target file via a system call (such as "close()"), the file system determines that the cache for that file is no longer referenced by the current process. At this point, the memory management module marks the cache as "reclaimable," thereby triggering a system cache reclamation event.

[0045] For example, the total capacity of the system memory cache is 10GB, and the preset capacity threshold is 1GB. If the size of the metadata to be stored is 2GB, and the remaining space in the main cache is only 1.5GB (even if the remaining space is greater than the 1GB threshold), the triggering condition can still be determined to be met.

[0046] This application does not limit the "method of triggering system cache reclamation event" and the "system cache reclamation event".

[0047] In some embodiments, compressing target metadata in the system cache that meets data compression conditions includes: determining, based on the metadata in the system cache corresponding to a system cache eviction event, that the metadata corresponding to the system cache eviction event is target metadata that meets data compression conditions; and, in response to the fact that the metadata corresponding to the system cache eviction event is target metadata that meets data compression conditions, compressing the target metadata to obtain compressed metadata corresponding to the target metadata. In one implementation, when the metadata corresponding to the system cache eviction event is deleted from the system cache, it is determined that the metadata corresponding to the system cache eviction event is target metadata that meets data compression conditions.

[0048] In some embodiments, determining that the metadata corresponding to the system cache reclamation event is the target metadata that meets the data compression conditions includes: determining the target metadata in the system cache that meets the data compression conditions based on the attribute information and / or memory state information of the metadata corresponding to the system cache reclamation event.

[0049] The attribute information includes at least one of the following: data size, data type, and access frequency of the metadata.

[0050] Memory state information is used to characterize the memory state of the system. In some embodiments, the memory state information includes the remaining storage space of the compressed cache and / or the remaining storage space of the system cache.

[0051] In some embodiments, satisfying the data compression conditions includes at least one of the following: The remaining storage space in the compressed cache is greater than the preset storage space threshold. At this point, the compressed cache has the storage resources to accommodate the compressed metadata corresponding to the target metadata, making it possible for the target metadata to enter the compressed cache.

[0052] The size of the metadata corresponding to system cache reclamation events in the system cache is within a preset compression size range. This avoids the computational overhead of compression and decompression exceeding the storage benefits, ensuring that metadata compression provides actual storage gains.

[0053] The metadata corresponding to system cache eviction events in the system cache is within a preset access frequency range. By limiting the access frequency, the impact of metadata compression and decompression operations on system file access performance can be reduced, thus adapting to the access performance requirements of the file system metadata cache.

[0054] The metadata corresponding to system cache eviction events in the system cache belongs to a preset compressible data type. For example, data types include file inodes, direct nodes, and indirect nodes. The preset compressible data types include inodes and direct nodes.

[0055] In some embodiments, target metadata that meets the data compression conditions in the system cache is compressed using a compression algorithm (such as lz4, zstd, etc.) to obtain compressed metadata corresponding to the target metadata. The size of the compressed metadata is reduced compared to the original metadata, thus reducing the data storage space.

[0056] S102, store the compressed metadata corresponding to the target metadata into the compressed cache.

[0057] A compressed cache is an independent cache located between the system cache and the storage medium. In some embodiments, the system cache may be a cache area allocated for file system metadata in the main memory of an electronic device, such as a volatile cache area allocated for file system metadata in Dynamic Random Access Memory (DRAM). In some embodiments, the storage medium may be a persistent storage medium of the electronic device. For example, it may be a non-volatile storage medium such as a solid-state drive (SSD), a hard disk drive (HDD), an embedded multi-media card (eMMC), or universal flash storage (UFS). In some embodiments, the compressed cache may be a partition in the main memory of the electronic device that is independent of the system cache.

[0058] In some embodiments, storing compressed metadata corresponding to the target metadata in a compressed cache includes: storing the compressed metadata corresponding to the target metadata in the compressed cache in response to the remaining storage space of the compressed cache being greater than a capacity threshold; and deleting at least one existing compressed data in the compressed cache in response to the remaining storage space of the compressed cache being less than or equal to the capacity threshold, and storing the compressed metadata corresponding to the target metadata in the compressed cache. By using a capacity threshold determination and a mechanism for cleaning up existing compressed data as needed, the overflow problem caused by insufficient storage space in the compressed cache is avoided, ensuring that the compressed metadata corresponding to the target metadata can be stably stored. This allows the compressed cache, as an intermediate cache layer between the system cache and the storage medium, to have a continuous function of storing compressed metadata. Simultaneously, the processing method of "directly storing when there is sufficient remaining space and cleaning up as needed when insufficient space" reduces unnecessary cleaning operations and system overhead. This further improves the overall access performance and operational stability of the file system metadata caching system. Furthermore, by deleting at least one existing compressed data as needed, a large amount of data does not need to be cleaned up at once. This allows for the retention of valuable existing compressed metadata in the cache while meeting new data storage requirements, reducing the cost of recompressing and re-accessing invalid metadata. Differentiated operations are performed by comparing simple capacity thresholds. The logic is lightweight and the execution efficiency is high. While implementing compressed cache storage management, it does not introduce additional complex computational burden.

[0059] By executing steps S101 and S102, compressed metadata of the target metadata is stored in a compressed cache, serving as an extension and backup of the system cache, thus constructing a multi-level caching system. This achieves hierarchical management of metadata, reducing cache memory usage, improving cache hit rate, and reducing unnecessary disk accesses.

[0060] In some embodiments, when performing such Figure 1 After steps S101 and S102 as shown, that is, after the metadata writing process is completed, the following can be executed: Figure 3 Steps S301 to S303 are used to complete the metadata reading process.

[0061] like Figure 2 As shown, in some embodiments, triggering a system cache reclamation event includes the following steps: S201, in response to a metadata read request, retrieves the metadata corresponding to the metadata read request from the system cache.

[0062] In some embodiments, a metadata read request can be a data acquisition request initiated by various upper-layer applications or application-level functional modules of an electronic device to the underlying file system when performing task operations. In some embodiments, data acquisition requests initiated by applications include at least one of file content reading, file creation, file attribute modification, file deletion, directory creation, directory traversal, and file path query.

[0063] In some embodiments, the file system obtains the metadata of a file or directory based on the metadata read request to complete the application's business operation response. In one implementation, the metadata read request carries metadata identification information, such as at least one of a metadata index, associated file, or directory identifier.

[0064] For example, when the navigation application in the car's infotainment system performs the "load offline map" task, the media application performs the "play local music" task, or the file manager performs the "open in-vehicle storage directory" task, it initiates a metadata read request to the file system to obtain metadata such as the file's storage address, size, and permissions.

[0065] For example, when a photo album app on a phone or tablet performs a task to "load local images or videos", it triggers a metadata read request.

[0066] This application does not limit the implementation form of the metadata reading request.

[0067] S202, in response to the fact that the metadata corresponding to the metadata read request was not found in the system cache, it is determined that the triggering conditions of the system cache reclamation event are met.

[0068] The metadata corresponding to the metadata read request was not found in the system cache, meaning there was a system cache miss. In other words, the metadata to be read was not loaded into the system cache at this time, and it needs to be loaded from the storage medium or compressed cache into the system cache to respond to the read request.

[0069] To ensure that metadata is successfully loaded, in some embodiments, the system determines whether it needs to trigger the cache space reclamation process by verifying preset cache space thresholds, cache utilization rates, or metadata loading space requirements, so as to reserve effective resources for subsequent cache loading of metadata.

[0070] S203, in response to the fulfillment of the triggering conditions for the system cache reclamation event, trigger the system cache reclamation event.

[0071] In some embodiments, in response to the current system cache's available storage space being insufficient to meet the loading requirements of metadata to be read, a system cache reclamation event is triggered in the system cache space. This initiates a process of filtering and cleaning up existing metadata in the system cache. For example, it releases storage space occupied by idle, infrequently accessed, and low-priority metadata in the system cache, freeing up matching cache resources for metadata that will soon be loaded from the underlying storage medium. This ensures both the final response to metadata read requests and maintains the resource utilization efficiency and access performance of the system cache.

[0072] In some embodiments, the metadata in the released system cache retains high-value metadata by performing steps S101 and S102, thereby achieving hierarchical management of metadata.

[0073] The following describes a feasible implementation method for reading data in the data processing method provided in this application.

[0074] like Figure 3 As shown, in some embodiments, the data processing method further includes the following steps: S301, in response to a metadata read request, retrieves the metadata corresponding to the metadata read request from the system cache.

[0075] In response to finding the target metadata corresponding to the metadata read request in the system cache, the metadata is returned to the upper-layer application.

[0076] In some embodiments, in response to a metadata read request, searching for the metadata corresponding to the metadata read request in the system cache includes: in response to the metadata read request, obtaining metadata tagging information corresponding to the metadata read request; and searching for the metadata corresponding to the metadata read request in the system cache based on the tagging information.

[0077] The metadata tagging information includes at least one of the following: inode number, directory entry identifier, and path hash value of file or directory.

[0078] S302, in response to the fact that the metadata corresponding to the metadata read request is not found in the system cache, the compressed metadata corresponding to the metadata read request is searched in the compressed cache.

[0079] In response to the failure to find the target metadata corresponding to the metadata read request in the system cache, the intermediate layer retrieval is achieved by searching the compressed cache, avoiding direct access to the underlying storage medium, thereby improving read efficiency and optimizing system memory usage.

[0080] In some embodiments, the method further includes: in response to finding compressed metadata corresponding to the metadata read request in the compressed cache, decompressing the compressed metadata corresponding to the metadata read request to obtain the metadata information corresponding to the metadata read request. This decompression restores the complete metadata information required for the metadata read request, thus satisfying the metadata read requirements of the upper-layer application. The compressed cache stores compressed metadata processed by a lightweight compression algorithm. This compressed storage method effectively reduces the overall memory footprint of the metadata cache while freeing up valuable storage resources of the system cache, allowing the system cache to prioritize high-frequency access metadata.

[0081] In some embodiments, the method further includes: decompressing the compressed metadata corresponding to the metadata read request in the compressed cache in response to the completion of decompression of the compressed metadata corresponding to the metadata read request and in response to the compressed metadata corresponding to the metadata read request meeting the deletion conditions. Based on this, invalid and infrequent compressed metadata is prevented from residing in the compressed cache for extended periods, thus avoiding the occupation of the compressed cache's storage resources. This ensures that the remaining storage space of the compressed cache can be used to carry new compressed metadata, achieving efficient utilization of the compressed cache's storage resources and further optimizing the overall memory usage configuration of the hierarchical caching system.

[0082] S303, in response to the fact that the compressed metadata corresponding to the metadata read request is not found in the compressed cache, the metadata corresponding to the metadata read request is read from the storage medium.

[0083] like Figure 4 As shown, in some embodiments, the method further includes the following steps: S401, in response to storing the compressed metadata corresponding to the target metadata into the compressed cache, update the compressed cache record based on the access frequency of the compressed metadata.

[0084] In some embodiments, the compressed cache record may include a compressed metadata identifier and a management table of access frequency. For each compressed metadata in the compressed cache, the access frequency is incremented sequentially, and the access time is refreshed synchronously to complete the dynamic update based on the access frequency.

[0085] For example, when a car infotainment application plays local music A, the corresponding inode and direct node metadata are compressed and stored in a compressed cache. In the compressed cache record, the access frequency for this compressed metadata is initialized to "1" and an identifier is entered. When the car infotainment application plays music A again, the compressed metadata is accessed, and its access frequency in the compressed cache record is incremented sequentially, while the access time is updated synchronously, completing a dynamic update based on the access frequency.

[0086] S402, in response to system startup or file system mounting, decompresses compressed metadata with access frequency higher than a preset frequency threshold and loads it into the system cache based on compressed cache records.

[0087] For example, after the vehicle's infotainment system starts up, the file system initializes, reads the compressed cache records, and iterates through and filters out compressed metadata (such as compressed metadata corresponding to offline navigation maps and frequently used music folders) that have been accessed more frequently than a preset frequency threshold. After decompressing these metadata, they are loaded into the system cache. Low-frequency compressed metadata (accessed less frequently than the preset frequency threshold) remains in the compressed storage state in the compressed cache and is not loaded.

[0088] For example, after the vehicle system file system completes its first mounting or remounting (such as mounting after external storage), the module, according to the above logic, selects the high-frequency compressed metadata in the mounted storage medium from the compressed cache records, decompresses it, and loads it into the system cache.

[0089] This application provides a data processing system for performing the data processing method of any of the above embodiments.

[0090] like Figure 5 As shown, in some embodiments, the data processing system 700 includes a metadata compression module 701 and a metadata storage module 702.

[0091] The metadata compression module 701 is configured to compress the target metadata in the system cache that meets the data compression conditions in response to a system cache reclamation event, so as to obtain the compressed metadata corresponding to the target metadata.

[0092] Metadata storage module 702 is configured to store compressed metadata corresponding to the target metadata in a file such as... Figure 6 The compressed cache shown is set as follows: Figure 6 This illustrates an independent cache between the system cache and the storage medium. Optionally, a compressed cache is a cache space independent of the system cache.

[0093] like Figure 6As shown, when an application initiates a file access request, the Virtual File System (VFS) receives the request and parses it. Based on the metadata read request, it calls the corresponding interface of the underlying file system to search for the metadata corresponding to the metadata read request in the system cache. If the target metadata corresponding to the metadata read request is found in the system cache, the metadata is returned to the upper-layer application. If the metadata corresponding to the metadata read request is not found in the system cache, it searches for the corresponding compressed metadata in the compressed cache. If the target metadata corresponding to the metadata read request is not found in the system cache, the intermediate layer retrieval is achieved by searching the compressed cache. If the compressed metadata corresponding to the metadata read request is found in the compressed cache, it is decompressed to obtain the metadata information corresponding to the metadata read request. In this way, the complete metadata information required for the metadata read request is restored through decompression to meet the metadata read requirements of the upper-layer application. The compressed cache stores compressed metadata processed by a lightweight compression algorithm. This compressed storage method effectively reduces the overall memory usage of the metadata cache while freeing up valuable storage resources of the system cache, allowing the system cache to prioritize high-frequency access metadata.

[0094] In some embodiments, the data processing system 700 further includes: a compression decision module: the compression decision module is configured to determine, based on the metadata in the system cache corresponding to the system cache reclamation event, that the metadata corresponding to the system cache reclamation event is the target metadata that meets the data compression conditions; and a metadata compression module 701 is configured to compress the target metadata to obtain compressed metadata corresponding to the target metadata in response to the metadata corresponding to the system cache reclamation event being the target metadata that meets the data compression conditions.

[0095] In some embodiments, the compression decision module is configured to determine the metadata corresponding to the system cache reclamation event as target metadata that meets the data compression conditions in response to the deletion of metadata corresponding to the system cache reclamation event in the system cache.

[0096] In some embodiments, the compression decision module is configured to: determine the target metadata in the system cache that meets the data compression conditions based on the attribute information of the metadata corresponding to the system cache reclamation event and the system's memory state information. The attribute information includes at least one of the metadata's data size, data type, and access frequency. The memory state information includes the remaining storage space of the compressed cache.

[0097] In some embodiments, the data processing system 700 further includes: a cache management module: in response to a metadata read request, the cache management module searches for the metadata corresponding to the metadata read request in the system cache; in response to the fact that the metadata corresponding to the metadata read request is not found in the system cache, it determines that the triggering condition for a system cache eviction event is met; in response to the fact that the triggering condition for a system cache eviction event is met, it triggers a system cache eviction event.

[0098] In some embodiments, the metadata storage module 702 is configured to store compressed metadata corresponding to the target metadata into the compressed cache in response to the remaining storage space of the compressed cache being greater than the capacity threshold; and to delete at least one original compressed data in the compressed cache in response to the remaining storage space of the compressed cache being less than or equal to the capacity threshold, and to store compressed metadata corresponding to the target metadata into the compressed cache.

[0099] In some embodiments, the data processing system 700 further includes a metadata reading module: the metadata reading module is configured to, in response to a metadata reading request, search for the metadata corresponding to the metadata reading request in the system cache; if the metadata corresponding to the metadata reading request is not found in the system cache, search for the compressed metadata corresponding to the metadata reading request in the compressed cache; and if the compressed metadata corresponding to the metadata reading request is not found in the compressed cache, read the metadata corresponding to the metadata reading request from the storage medium.

[0100] In some embodiments, the metadata storage module 702 is configured to: store compressed metadata corresponding to the target metadata into the compressed cache in response to the remaining storage space of the compressed cache being greater than the capacity threshold; and delete at least one original compressed data in the compressed cache and store compressed metadata corresponding to the target metadata into the compressed cache in response to the remaining storage space of the compressed cache being less than or equal to the capacity threshold.

[0101] In some embodiments, the metadata storage module 702 is configured to: in response to finding the compressed metadata corresponding to the metadata read request in the compressed cache, decompress the compressed metadata corresponding to the metadata read request and obtain the metadata information corresponding to the metadata read request.

[0102] In some embodiments, the metadata storage module 702 is configured to: delete the compressed metadata corresponding to the metadata read request in the compressed cache in response to the completion of decompression of the compressed metadata corresponding to the metadata read request and in response to the completion of the deletion condition of the compressed metadata corresponding to the metadata read request.

[0103] In some embodiments, the metadata reading module is configured to: in response to a metadata reading request, obtain metadata tagging information corresponding to the metadata reading request. The metadata tagging information includes at least one of an inode number, a directory entry identifier, and a path hash value of a file or directory. Based on the tagging information, the metadata corresponding to the metadata reading request is searched in the system cache.

[0104] In some embodiments, the metadata storage module 702 is configured to: update the compressed cache record based on the access frequency of the compressed metadata in response to storing the compressed metadata corresponding to the target metadata into the compressed cache; and decompress and load the compressed metadata with an access frequency higher than a preset frequency threshold into the system cache in response to system startup or file system mounting, according to the compressed cache record.

[0105] The data processing system provided in this application embodiment uses a compressed cache as an independent cache layer between the system cache and the storage medium, forming a two-level cache structure of system cache and compressed cache, and a three-level access path between the system cache, compressed cache, and storage medium. This eliminates the need to traverse redundant cache layers during metadata lookup, significantly reducing the time overhead of layer jumps. Shorter cache access paths and fewer layers accelerate metadata lookup, quickly respond to upper-level file access requests, and improve data access performance. Furthermore, the original target metadata is significantly reduced in size after compression; with the same memory space, the compressed cache can store more high-value metadata, significantly reducing the memory cost per piece of metadata. Simultaneously, the system cache, by reclaiming the space of compressed metadata, can reallocate it to new metadata (such as file metadata accessed in real time), avoiding wasted memory resources and achieving high memory utilization.

[0106] This embodiment also provides an electronic device for performing the data processing method of any of the above embodiments. Figure 7 This is a schematic diagram illustrating the structure of an electronic device according to some embodiments of this application. For example... Figure 7 As shown, the electronic device 800 includes at least one processor 820; and a memory 804 communicatively connected to the at least one processor 820; wherein the memory 804 stores instructions executable by the at least one processor 820, the instructions being executed by the at least one processor 820 to enable the at least one processor to perform a data processing method.

[0107] Electronic device 800 can be a mobile phone, computer, digital broadcasting terminal, messaging device, game console, tablet device, medical device, fitness equipment, personal digital assistant, etc.

[0108] Electronic device 800 may include one or more of the following components: processing component 802, memory 804, power component 806, multimedia component 808, audio component 810, input / output (I / O) interface 812, sensor component 814, and communication component 816.

[0109] Processing component 802 typically controls the overall operation of electronic device 800, such as operations associated with display, telephone calls, data communication, camera operation, and recording operations. Processing component 802 may include one or more processors 820 to execute instructions to complete all or part of the steps of the methods described above. Furthermore, processing component 802 may include one or more modules to facilitate interaction between processing component 802 and other components. For example, processing component 802 may include a multimedia module to facilitate interaction between multimedia component 808 and processing component 802.

[0110] Memory 804 is configured to store various types of data to support the operation of electronic device 800. Examples of such data include instructions for any application or method operating on electronic device 800, contact data, phonebook data, messages, pictures, videos, etc. Memory 804 can be implemented by any type of volatile or non-volatile storage device or a 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 storage, flash memory, magnetic disk, or optical disk.

[0111] Power component 806 provides power to various components of electronic device 800. Power component 806 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power to electronic device 800.

[0112] Multimedia component 808 includes a screen that provides an output interface between the electronic device 800 and the user. In some embodiments, the screen may include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen may be implemented as a touchscreen to receive input signals from the user. The touch panel includes one or more touch sensors to sense touches, swipes, and gestures on the touch panel. The touch sensors may sense not only the boundaries of the touch or swipe action but also the duration and pressure associated with the touch or swipe operation. In some embodiments, multimedia component 808 includes a front-facing camera and / or a rear-facing camera. When the electronic device 800 is in an operating mode, such as a shooting mode or a video mode, the front-facing camera and / or the rear-facing camera may receive external multimedia data. Each front-facing camera and rear-facing camera may be a fixed optical lens system or have focal length and optical zoom capabilities.

[0113] Audio component 810 is configured to output and / or input audio signals. For example, audio component 810 includes a microphone (MIC) configured to receive external audio signals when electronic device 800 is in an operating mode, such as call mode, recording mode, and voice recognition mode. The received audio signals may be further stored in memory 804 or transmitted via communication component 816. In some embodiments, audio component 810 also includes a speaker for outputting audio signals.

[0114] I / O interface 812 provides an interface between processing component 802 and peripheral interface modules, such as keyboards, click wheels, buttons, etc. These buttons may include, but are not limited to, home buttons, volume buttons, power buttons, and lock buttons.

[0115] Sensor assembly 814 includes one or more sensors for providing state assessments of various aspects of electronic device 800. For example, sensor assembly 814 can detect the on / off state of electronic device 800, the relative positioning of components such as the display and keypad of electronic device 800, changes in position of electronic device 800 or a component of electronic device 800, the presence or absence of user contact with electronic device 800, orientation or acceleration / deceleration of electronic device 800, and temperature changes of electronic device 800. Sensor assembly 814 may include a proximity sensor configured to detect the presence of nearby objects without any physical contact. Sensor assembly 814 may also include a light sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, sensor assembly 814 may also include an accelerometer, gyroscope, magnetometer, pressure sensor, or temperature sensor.

[0116] Communication component 816 is configured to facilitate wired or wireless communication between electronic device 800 and other devices. Electronic device 800 can access wireless networks based on communication standards, such as WiFi, 3G, 4G, 5G, other communication standards, or combinations thereof. In some embodiments of this application, communication component 816 receives broadcast signals or broadcast-related information from an external broadcast management system via a broadcast channel. In some embodiments of this application, communication component 816 further includes a near-field communication (NFC) module to facilitate short-range communication. For example, the NFC module may be implemented based on radio frequency identification (RFID) technology, Infrared Data Association (IrDA) technology, ultra-wideband (UWB) technology, Bluetooth (BT) technology, and other technologies.

[0117] In some embodiments of this application, the electronic device 800 may be implemented by one or more application-specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field-programmable gate arrays (FPGAs), controllers, microcontrollers, microprocessors, or other electronic components to perform the methods of any of the above embodiments.

[0118] In some embodiments of this application, a non-transitory computer-readable storage medium storing computer instructions is also provided, such as a memory 804 including instructions that can be executed by a processor 820 of an electronic device 800 to perform the above-described method. For example, the non-transitory computer-readable storage medium may be a ROM, random access memory (RAM), CD-ROM, magnetic tape, floppy disk, and optical data storage device, etc.

[0119] In some embodiments of this application, a computer program product is also provided, including a computer program and computer instructions for causing a computer to perform the method described in any one of the first aspects.

[0120] In the above detailed description, reference has been made to the accompanying drawings, which illustrate specific aspects of how this application can be practiced. In this regard, terms indicating direction or positional relationship, such as “center,” “longitudinal,” “lateral,” “length,” “width,” “thickness,” “upper,” “lower,” “front,” “rear,” “left,” “right,” “vertical,” “horizontal,” “top,” “bottom,” “inner,” “outer,” “clockwise,” “counterclockwise,” “axial,” “radial,” and “circumferential,” can be used with reference to the orientation of the described figures. Since components of the described device can be positioned in multiple different orientations, directional terms are used for illustrative purposes and are not restrictive. It should be understood that other aspects can be utilized and structural or logical changes can be made without departing from the concept of this application. Therefore, the following detailed description should not be considered limiting.

[0121] It should be understood that, unless otherwise specifically indicated, features of various embodiments of this application described herein can be combined with each other. As used herein, the term “and / or” includes any one of the relevant listed items and any combination of any two or more; similarly, “at least one of…” includes any one of the relevant listed items and any combination of any two or more.

[0122] It should be understood that, unless otherwise expressly specified and limited, the terms "joining," "attaching," "installing," "connecting," "linking," and "fixing," as used in the embodiments of this application, should be interpreted broadly. For example, they can refer to a fixed connection, a detachable connection, or an integral part; they can refer to a mechanical connection, an electrical connection, or a connection that allows communication between them; they can refer to a direct connection or an indirect connection through an intermediate medium; they can refer to the internal communication of two components or the interaction between two components, unless otherwise expressly limited. Those skilled in the art can understand the specific meaning of the above terms herein based on the specific circumstances.

[0123] Furthermore, the term "above" as used herein with respect to components, elements, or material layers formed or located "above" a surface may be used to indicate that the component, element, or material layer is "indirectly" positioned (e.g., placed, formed, deposited, etc.) on the surface such that one or more additional components, elements, or layers are arranged between the surface and the component, element, or material layer. However, the term "above" as used with respect to components, elements, or material layers formed or located "above" a surface may also optionally have a specific meaning: that the component, element, or material layer is "directly" positioned (e.g., placed, formed, deposited, etc.) on the surface, for example, in direct contact with the surface.

[0124] Although terms such as “first,” “second,” and “third” may be used herein to describe various components, parts, regions, layers, or sections, these components, parts, regions, layers, or sections are not limited to these terms. Rather, these terms are used only to distinguish one component, part, region, layer, or section from another. Therefore, without departing from the teachings of the examples described herein, the first component, part, region, layer, or section mentioned in the examples may also be referred to as the second component, part, region, layer, or section. Furthermore, the terms “first” and “second” are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of indicated technical features. Thus, a feature defined as “first” or “second” may explicitly or implicitly include at least one feature. In the description herein, “a plurality” means at least two, such as two, three, etc., unless otherwise explicitly specified.

[0125] It should be understood that spatial relative terms, such as “above,” “upper,” “below,” and “lower,” are used herein to describe the relationship between one element and another shown in the figures. In addition to the orientation depicted in the figures, these spatial relative terms are also intended to encompass different orientations of the device in use or operation. For example, if the device in the figures is flipped, an element described as “above” or “upper” relative to another element would be “below” or “lower” relative to that element. Thus, depending on the spatial orientation of the device, the term “above” encompasses both above and below orientations. Devices may have other orientations (e.g., rotated 90 degrees or in other orientations), and the spatial relative terms used herein should be interpreted accordingly.

[0126] Furthermore, the term “exemplary” is used herein to mean serving as an example, instance, or illustration. Any aspect or design described herein as “exemplary” is not necessarily to be construed as advantageous compared to other aspects or designs. Rather, the use of the term “exemplary” is intended to present the concept in a concrete manner. As used herein, the term “or” is intended to mean an inclusive “or” rather than an exclusive “or.” That is, unless otherwise specified or clear from the context, “X applies A or B” is intended to mean any of the natural inclusive arrangements. That is, “X applies A or B” satisfies any of the foregoing instances if X applies A; X applies B; or both X applies A and B. Additionally, unless otherwise specified or clear from the context to refer to the singular form, the articles “a” and “an” as used in the application and appended claims are generally understood to mean “one or more.”

[0127] Similarly, although this application has been shown and described with respect to one or more implementations, equivalent variations and modifications will occur to those skilled in the art upon reading and understanding the specification and drawings. This application includes all such modifications and variations and is limited only by the scope of the claims. In particular, with respect to the various functions performed by the components described above (e.g., elements, resources, etc.), unless otherwise indicated, the terminology used to describe such components is intended to correspond to any component (functionally equivalent) that performs the specific function of the described component, even if structurally not equivalent to the disclosed structure. Furthermore, although a particular feature of this application may have been disclosed with respect to only one of several implementations, such features may be combined with one or more other features of other implementations, as may be desired and advantageous to any given or particular application. Moreover, with regard to the terms “comprising,” “owning,” “having,” “having,” or variations thereof as used in the Detailed Description or the claims, such terms are intended to be inclusive in a manner similar to the term “including.”

[0128] Other embodiments of this application will readily occur to those skilled in the art upon consideration of the specification and practice of the invention disclosed herein. This application is intended to cover any variations, uses, or adaptations of this application that follow the general principles of this application and include common knowledge or customary techniques in the art not disclosed herein. The specification and examples are to be considered exemplary only, and the true scope and spirit of this application are indicated by the following claims.

[0129] It should be understood that this application is not limited to the precise structure described above and shown in the accompanying drawings, and various modifications and changes can be made without departing from its scope. The scope of this application is limited only by the appended claims.

Claims

1. A data processing method, characterized by, include: In response to triggering a system cache reclamation event, the target metadata in the system cache that meets the data compression conditions is compressed to obtain the compressed metadata corresponding to the target metadata; The compressed metadata corresponding to the target metadata is stored in a compressed cache, which is an independent cache set between the system cache and the storage medium.

2. The method according to claim 1, characterized in that, The step of compressing the target metadata in the system cache that meets the data compression conditions includes: Based on the metadata in the system cache corresponding to the system cache reclamation event, determine that the metadata corresponding to the system cache reclamation event is the target metadata that satisfies the data compression conditions; In response to the system cache reclamation event, if the metadata corresponding to the target metadata satisfies the data compression conditions, the target metadata is compressed to obtain the compressed metadata corresponding to the target metadata.

3. The method according to claim 2, characterized in that, The step of determining that the metadata corresponding to the system cache reclamation event is the target metadata that meets the data compression conditions includes: Based on the attribute information and / or memory state information of the metadata corresponding to the system cache reclamation event, determine the target metadata in the system cache that meets the data compression conditions; The attribute information includes at least one of the metadata's data size, data type, and access frequency; the memory status information includes the remaining storage space of the compressed cache.

4. The method according to claim 3, characterized in that, The conditions for satisfying data compression include at least one of the following: The remaining storage space of the compressed cache is greater than the capacity threshold; The size of the metadata corresponding to the system cache reclamation event is within a preset compressed size range; The metadata corresponding to the system cache recycling event is within a preset access frequency range; The metadata corresponding to system cache recycling events belongs to a preset compressible data type.

5. The method according to claim 1, characterized in that, The event that triggers the system cache reclamation includes: In response to a metadata read request, the metadata corresponding to the metadata read request is retrieved from the system cache; In response to the fact that the metadata corresponding to the metadata read request is not found in the system cache, it is determined that the triggering condition of the system cache eviction event is met; The system cache reclamation event is triggered in response to the fulfillment of the triggering conditions.

6. The method according to claim 1, characterized in that, The step of storing the compressed metadata corresponding to the target metadata into the compressed cache includes: In response to the remaining storage space of the compressed cache being greater than the capacity threshold, the compressed metadata corresponding to the target metadata is stored in the compressed cache; In response to the remaining storage space of the compressed cache being less than or equal to the capacity threshold, at least one original compressed data in the compressed cache is deleted, and the compressed metadata corresponding to the target metadata is stored in the compressed cache.

7. The method according to any one of claims 1-6, characterized in that, Also includes: In response to a metadata read request, the metadata corresponding to the metadata read request is retrieved from the system cache; In response to the fact that the metadata corresponding to the metadata read request is not found in the system cache, the compressed metadata corresponding to the metadata read request is searched in the compressed cache; In response to the fact that the compressed metadata corresponding to the metadata read request is not found in the compressed cache, the metadata corresponding to the metadata read request is read from the storage medium.

8. The method according to claim 7, characterized in that, Also includes: In response to finding the compressed metadata corresponding to the metadata read request in the compressed cache, the compressed metadata corresponding to the metadata read request is decompressed to obtain the metadata information corresponding to the metadata read request.

9. The method according to claim 8, characterized in that, Also includes: In response to the completion of decompression of the compressed metadata corresponding to the metadata read request, and in response to the completion of deletion of the compressed metadata corresponding to the metadata read request, the compressed metadata corresponding to the metadata read request is deleted from the compressed cache.

10. The method according to claim 7, characterized in that, The step of responding to a metadata read request by searching for the metadata corresponding to the metadata read request in the system cache includes: In response to the metadata read request, the metadata tag information corresponding to the metadata read request is obtained; the metadata tag information includes at least one of inode number, directory entry identifier, and path hash value of file or directory; Based on the tagging information, the metadata corresponding to the metadata read request is searched in the system cache.

11. The method according to any one of claims 1-6, characterized in that, The method further includes: In response to storing the compressed metadata corresponding to the target metadata into the compressed cache, the compressed cache record is updated based on the access frequency of the compressed metadata; In response to system startup or file system mounting, compressed metadata with access frequency higher than a preset frequency threshold is decompressed and loaded into the system cache according to the compressed cache record.

12. The method according to any one of claims 1-6, characterized in that, The system cache reclamation event includes at least one of the following: The remaining system memory storage space is less than or equal to the capacity threshold; The system issues an active memory reclamation command; The file is closed.

13. A data processing system, characterized in that, include: The metadata compression module is configured to compress target metadata in the system cache that meets the data compression conditions in response to a system cache reclamation event, so as to obtain compressed metadata corresponding to the target metadata. The metadata storage module is configured to store the compressed metadata corresponding to the target metadata into a compressed cache, wherein the compressed cache is an independent cache set between the system cache and the storage medium.

14. The system according to claim 13, characterized in that, Also includes: Compressed decision-making module: The compression decision module is configured to determine, based on the metadata in the system cache corresponding to the system cache reclamation event, that the metadata corresponding to the system cache reclamation event is the target metadata that satisfies the data compression conditions; The metadata compression module is configured to compress the target metadata to obtain compressed metadata corresponding to the target metadata in response to the metadata corresponding to the system cache reclamation event, which meets the data compression conditions.

15. The system according to claim 14, characterized in that, The compression decision module is configured as follows: Based on the attribute information of the metadata corresponding to the system cache reclamation event and the system memory state information, the target metadata in the system cache that meets the data compression conditions is determined; The attribute information includes at least one of the metadata's data size, data type, and access frequency; the memory status information includes the remaining storage space of the compressed cache.

16. The system according to claim 15, characterized in that, Also includes: Metadata reading module: The metadata reading module is configured to, in response to a metadata reading request, search for the metadata corresponding to the metadata reading request in the system cache; In response to the fact that the metadata corresponding to the metadata read request is not found in the system cache, the compressed metadata corresponding to the metadata read request is searched in the compressed cache; In response to the fact that the compressed metadata corresponding to the metadata read request is not found in the compressed cache, the metadata corresponding to the metadata read request is read from the storage medium.

17. The system according to claim 16, characterized in that, The metadata reading module is configured as follows: In response to the metadata read request, the metadata tag information corresponding to the metadata read request is obtained; the metadata tag information includes at least one of inode number, directory entry identifier, and path hash value of file or directory; Based on the tagging information, the metadata corresponding to the metadata read request is searched in the system cache.

18. An electronic device, characterized in that, include: At least one processor; as well as A memory communicatively connected to the at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor to enable the at least one processor to perform the method of any one of claims 1-12.

19. A computer-readable storage medium storing computer instructions, characterized in that, The computer instructions are used to cause the computer to perform the method according to any one of claims 1-12.

20. A program product, characterized in that, Includes computer instructions for causing a computer to perform the method of any one of claims 1 to 12.