Container file management method, device, equipment and storage medium
By determining and matching container files and containers according to the user instructions in Yunxing Technology, the security and efficiency of container file management have been solved, and the security and effective management of container files is realized.
Patent Information
- Application Number
- CN202410352421.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-03-26
- Publication Date
- 2025-01-28
- Estimated Expiration
- 2044-03-26
AI Technical Summary
How to safely and effectively manage container files in cloud-native technology, especially as the application scale continues to expand.
By determining the target file and target container according to the file management instructions sent by the user, and matching the target file and the target container, if the matching is successful, the target file management is managed by the file management instruction.
The security and effective management of container files is implemented to ensure that the file can be uploaded or downloaded correctly, avoiding unnecessary operations, thereby improving management efficiency and security.
Smart Images

Figure CN118312274B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of cloud native technology, and in particular to a container file management method, device, equipment and storage medium. Background Art
[0002] Cloud native is a new paradigm for software development and deployment. With container technology at its core, it closely integrates applications and infrastructure to achieve high automation and elastic expansion. As the scale of applications continues to expand, the demand for file management in containers is becoming more and more urgent. Therefore, how to safely and effectively manage container files has become a problem that needs to be solved. Summary of the invention
[0003] The main purpose of the present invention is to provide a container file management method, device, equipment and storage medium, aiming to solve the technical problem of how to manage container files safely and effectively.
[0004] To achieve the above object, the present invention provides a container file management method, which comprises the following steps:
[0005] Determine a target file and a target container corresponding to the target file according to a file management instruction sent by a user;
[0006] Matching the target file and the target container to obtain a matching result;
[0007] When the matching result is a successful match, container file management is performed on the target file according to the file management instruction.
[0008] Optionally, the step of determining the target file and the target container corresponding to the target file according to the file management instruction sent by the user specifically includes:
[0009] Obtaining an initial file path in a file management instruction sent by a user, and determining the accuracy of the initial file path;
[0010] When the accuracy determination fails, determining a target file path according to the initial file path, and determining a target file according to the target file path;
[0011] Obtaining an initial container name in the file management instruction, and matching the initial container name with a preset container library;
[0012] When the match fails, the target container name is determined according to the initial container name, and the target container corresponding to the target file is determined according to the target container name.
[0013] Optionally, when the accuracy determination fails, the step of determining the target file path according to the initial file path, and determining the target file according to the target file path specifically includes:
[0014] When the accuracy determination fails, determining the initial file corresponding to the initial file path;
[0015] When the initial file does not exist, performing anomaly detection on the initial file path to obtain an abnormal part;
[0016] Adjust the abnormal part according to the preset path set to obtain the target file path;
[0017] The target file is determined according to the target file path.
[0018] Optionally, when the match fails, the step of determining the target container name according to the initial container name, and determining the target container corresponding to the target file according to the target container name specifically includes:
[0019] When the match fails, extracting keywords from the initial container name to obtain keywords in the initial container name;
[0020] Selecting a plurality of container names from the preset container library according to the keyword;
[0021] Determine container types corresponding to the multiple container names, and perform type matching between the file type corresponding to the target file and the container type;
[0022] A target container name is selected from the multiple container names according to the type matching result, and a target container corresponding to the target file is determined according to the target container name.
[0023] Optionally, the step of matching the target file with the target container to obtain a matching result specifically includes:
[0024] Determine a target file format corresponding to the target file;
[0025] Determine an application corresponding to the target container, and determine an application file corresponding to the application;
[0026] Determine an application file format corresponding to the application file;
[0027] The target file format and the application file format are matched to obtain a matching result.
[0028] Optionally, the step of matching the target file format with the application file format to obtain a matching result specifically includes:
[0029] When the target file format exists in the application file format, determining that the matching result is a successful match;
[0030] When the target file format does not exist in the application file format, determining whether the application program is compatible with the target file format;
[0031] If so, the matching result is determined to be a successful match.
[0032] Optionally, when the matching result is a successful match, the step of performing container file management on the target file according to the file management instruction specifically includes:
[0033] When the matching result is a successful match, determining the instruction type corresponding to the file management instruction;
[0034] A management code corresponding to the instruction type is determined, and container file management is performed on the target file through the management code.
[0035] In addition, to achieve the above-mentioned purpose, the present invention further provides a container file management device, the container file management device comprising:
[0036] An information determination module, used to determine a target file and a target container corresponding to the target file according to a file management instruction sent by a user;
[0037] A matching module, used for matching the target file with the target container to obtain a matching result;
[0038] The file management module is used to perform container file management on the target file according to the file management instruction when the matching result is a successful match.
[0039] In addition, to achieve the above-mentioned purpose, the present invention also proposes a container file management device, which includes: a memory, a processor, and a container file management program stored in the memory and executable on the processor, wherein the container file management program is configured to implement the steps of the container file management method described above.
[0040] In addition, to achieve the above-mentioned purpose, the present invention further proposes a storage medium, on which a container file management program is stored, and when the container file management program is executed by a processor, the steps of the container file management method described above are implemented.
[0041] The present invention determines a target file and a target container corresponding to the target file according to a file management instruction sent by a user, then matches the target file and the target container to obtain a matching result, and when the matching result is a successful match, performs container file management on the target file according to the file management instruction. The present invention first determines a target file and a target container according to a file management instruction sent by a user, and can obtain a target file and a target container that need to be managed as a container file, and then matches the target file and the target container, and can determine whether the target file is in the target container, or can determine whether the target file can be uploaded to the target container, and when the matching result is a successful match, performs container file management on the target file according to the file management instruction, and can perform operations corresponding to the file management instruction on the target file, and does not perform other operations, thereby safely and effectively performing container file management. BRIEF DESCRIPTION OF THE DRAWINGS
[0042] Figure 1 It is a structural diagram of a container file management device in a hardware operating environment involved in an embodiment of the present invention;
[0043] Figure 2 It is a flowchart of the first embodiment of the container file management method of the present invention;
[0044] Figure 3 It is a flowchart of a second embodiment of the container file management method of the present invention;
[0045] Figure 4 It is a flowchart of a third embodiment of the container file management method of the present invention;
[0046] Figure 5 It is a structural block diagram of the first embodiment of the container file management device of the present invention.
[0047] The realization of the purpose, functional features and advantages of the present invention will be further explained in conjunction with embodiments and with reference to the accompanying drawings. DETAILED DESCRIPTION
[0048] It should be understood that the specific embodiments described herein are only used to explain the present invention, and are not used to limit the present invention.
[0049] Reference Figure 1 , Figure 1 The diagram is a schematic diagram of the structure of a container file management device in a hardware operating environment according to an embodiment of the present invention.
[0050] like Figure 1As shown, the container file management device may include: a processor 1001, such as a central processing unit (CPU), a communication bus 1002, a user interface 1003, a network interface 1004, and a memory 1005. Among them, the communication bus 1002 is used to realize the connection and communication between these components. The user interface 1003 may include a display screen (Display), an input unit such as a keyboard (Keyboard), and the optional user interface 1003 may also include a standard wired interface and a wireless interface. The network interface 1004 may optionally include a standard wired interface and a wireless interface (such as a wireless fidelity (Wireless-Fidelity, Wi-Fi) interface). The memory 1005 may be a high-speed random access memory (Random Access Memory, RAM), or a stable non-volatile memory (Non-Volatile Memory, NVM), such as a disk storage. The memory 1005 may also be a storage device independent of the aforementioned processor 1001.
[0051] Those skilled in the art will understand that Figure 1 The structure shown in the figure does not constitute a limitation on the container file management device, and may include more or less components than shown in the figure, or combine certain components, or arrange the components differently.
[0052] like Figure 1 As shown, the memory 1005 as a storage medium may include an operating system, a network communication module, a user interface module, and a container file management program.
[0053] exist Figure 1 In the container file management device shown, the network interface 1004 is mainly used for data communication with the network server; the user interface 1003 is mainly used for data interaction with the user; the processor 1001 and the memory 1005 in the container file management device of the present invention can be set in the container file management device, and the container file management device calls the container file management program stored in the memory 1005 through the processor 1001, and executes the container file management method provided by the embodiment of the present invention.
[0054] Based on the above container file management device, an embodiment of the present invention provides a container file management method, referring to Figure 2 , Figure 2 FIG. 1 is a flow chart of a first embodiment of a container file management method according to the present invention.
[0055] In this embodiment, the container file management method includes the following steps:
[0056] Step S10: determining a target file and a target container corresponding to the target file according to the file management instruction sent by the user.
[0057] It should be noted that the execution subject of this embodiment may be a computing service device with data processing, network communication and program running functions, such as a computer, or an electronic device or container file management device capable of implementing the above functions. The container file management device is taken as an example to illustrate this embodiment and the following embodiments.
[0058] It should be understood that the file management instruction refers to an instruction issued by a user when container file management is required. For example, the file management instruction may be to download file B from container A.
[0059] In a specific implementation, the target file and the target container corresponding to the target file can be determined according to the file management instruction. The target file refers to the file that needs to be managed as a container file, and the target container refers to the container where the target file is located or the container to which the target file needs to be uploaded. If the file management instruction contains information such as files and containers, the file can be used as the target file, and the container can be used as the target container; if the file management instruction does not contain information such as files and containers, the user can be prompted to re-enter the file management instruction according to the preset format, and the preset format can contain information such as files, containers, and operations.
[0060] Step S20: Match the target file and the target container to obtain a matching result.
[0061] It can be understood that this embodiment can match the target file and the target container. Specifically, when the file management instruction is a file download instruction, it can be determined whether the target file can be in the target container. If so, the match is successful; when the file management instruction is a file upload instruction, it can be determined whether the target file can be uploaded to the target container. If so, the match is successful.
[0062] Step S30: When the matching result is successful, container file management is performed on the target file according to the file management instruction.
[0063] Furthermore, in order to effectively perform container file management, in this embodiment, the step S30 includes: when the matching result is a successful match, determining the instruction type corresponding to the file management instruction; determining the management code corresponding to the instruction type, and performing container file management on the target file through the management code.
[0064] It should be understood that when the target file is successfully matched with the target container, the instruction type corresponding to the file management instruction can be determined, and the instruction type may include file download, file upload, and the like.
[0065] In a specific implementation, management codes can be written in advance based on containerization technology, and management codes corresponding to instruction types can be determined. For different instruction types, management codes are also different. Management codes can also include file download codes and file upload codes, and container file management is performed on target files through corresponding management codes, that is, the target file is downloaded from the target container through the file download code, or the target file is uploaded to the target container through the file upload code.
[0066] This embodiment determines the target file and the target container corresponding to the target file according to the file management instruction sent by the user, and then matches the target file and the target container to obtain a matching result. When the matching result is a successful match, container file management is performed on the target file according to the file management instruction. This embodiment first determines the target file and the target container according to the file management instruction sent by the user, and can obtain the target file and the target container that need to be managed as a container file. Then, the target file and the target container are matched, and it can be determined whether the target file is in the target container, or it can be determined whether the target file can be uploaded to the target container. When the matching result is a successful match, container file management is performed on the target file according to the file management instruction, and the operation corresponding to the file management instruction can be performed on the target file without performing other operations, so that container file management can be performed safely and effectively.
[0067] refer to Figure 3 , Figure 3 FIG. 4 is a flow chart of a second embodiment of a container file management method according to the present invention.
[0068] Based on the above first embodiment, in this embodiment, step S10 includes:
[0069] Step S101: obtaining an initial file path in a file management instruction sent by a user, and determining the accuracy of the initial file path.
[0070] It should be noted that the initial file path refers to the file path included in the file management instruction, which may be a complete path or may only include a partial path, that is, a partial path in the complete path.
[0071] It should be understood that this embodiment can determine the accuracy of the initial file path. Specifically, it can determine whether the initial file path exists or whether the initial file path is complete.
[0072] Step S102: When the accuracy determination fails, a target file path is determined according to the initial file path, and a target file is determined according to the target file path.
[0073] It is understandable that when the accuracy judgment fails, that is, when the initial file path does not exist or the initial file is incomplete, it can be determined that the accuracy judgment fails. At this time, the target file path can be determined based on the initial file path. Specifically, the initial file path can be adjusted or supplemented to obtain the target file path, and the file corresponding to the target file path is used as the target file. When the accuracy judgment passes, the file corresponding to the initial file path can be used as the target file.
[0074] Furthermore, in order to effectively determine the target file, in the present embodiment, the step S102 includes: when the accuracy judgment fails, determining the initial file corresponding to the initial file path; when the initial file does not exist, performing anomaly detection on the initial file path to obtain an abnormal part; adjusting the abnormal part according to a preset path set to obtain the target file path; and determining the target file according to the target file path.
[0075] It should be understood that when the accuracy judgment fails, the initial file corresponding to the initial file path may be searched first, and the initial file may be all files on the initial file path. If there is an abnormality in the initial file path, the initial file may not be found.
[0076] It is understandable that this embodiment can first determine whether the corresponding initial file can be found according to the initial file path. When the initial file can be found, that is, when the initial file exists, the initial file path can be used as the target file path. When the initial file cannot be found, that is, when the initial file does not exist, the initial file path can be detected for abnormality to obtain the abnormal part. Specifically, all directories in the initial file path can be identified first, and it can be determined whether the directory exists. For example, the initial file path is / cachi / file, cachi does not exist, and the directory can be used as the abnormal part.
[0077] In a specific implementation, the abnormal part can be adjusted according to a preset path set. The preset path set can include all pre-set existing paths. Specifically, the path most similar to the initial file path can be found from the preset path set, and the initial file path can be replaced by the path. For example, the path in the preset path set that is most similar to the initial file path / cachi / file is / cache / file. At this time, cache can be adjusted to cache to obtain the target file path, and the file corresponding to the target file path can be used as the target file.
[0078] Step S103: obtaining the initial container name in the file management instruction, and matching the initial container name with a preset container library.
[0079] It should be noted that the initial container name refers to the container name included in the file management instruction, and the path may be correct or incorrect.
[0080] It should be understood that, in this embodiment, the initial container name can be matched with a preset container library, which can include all pre-set containers required for container file management, and the container names corresponding to all containers are determined, and then it is determined whether the container names corresponding to the preset container library include the initial container name. If so, the match is successful, and if not, the match fails.
[0081] Step S104: when the match fails, determining a target container name according to the initial container name, and determining a target container corresponding to the target file according to the target container name.
[0082] It is understandable that when the match fails, the target container name can be determined based on the initial container name. Specifically, the initial container name can be adjusted to obtain the target container name, and the container corresponding to the target container name can be used as the target file. When the match succeeds, the container corresponding to the initial container name can be used as the target file.
[0083] Further, in order to effectively determine the target container, in this embodiment, the step S104 includes: when matching fails, performing keyword extraction on the initial container name to obtain keywords in the initial container name; selecting multiple container names from the preset container library according to the keywords; determining container types corresponding to the multiple container names, and performing type matching between the file type corresponding to the target file and the container type; selecting a target container name from the multiple container names according to the type matching result, and determining the target container corresponding to the target file according to the target container name.
[0084] It should be understood that when the initial container name and the preset container library fail to match, keyword extraction can be performed on the initial container name, that is, keywords in the initial container name are extracted, and multiple container names are selected from the preset container library based on the keywords. Specifically, multiple container names containing the above keywords can be selected from all preset container names corresponding to the preset container library.
[0085] It is understandable that after selecting multiple container names, the container type corresponding to each container name can be determined. The container type can be all file formats that the container corresponding to the container name can contain, and the file type corresponding to the target file can be determined. The file type can be determined according to the format of the target file, and then the file type is matched with the container type. When the file type exists in the container type, the type matching result is a successful match. When the file type does not exist in the container type, the type matching result is a failed match.
[0086] In a specific implementation, a target container name may be selected from multiple container names according to the type matching result. Specifically, a container name with a successful type matching may be selected from multiple container names as the target container name. Finally, the container corresponding to the target container name is used as the target container corresponding to the target file.
[0087] This embodiment obtains the initial file path in the file management instruction sent by the user, and performs an accuracy judgment on the initial file path. When the accuracy judgment fails, the target file path is determined according to the initial file path, and the target file is determined according to the target file path. Then, the initial container name in the file management instruction is obtained, and the initial container name is matched with a preset container library. When the match fails, the target container name is determined according to the initial container name, and the target container corresponding to the target file is determined according to the target container name. This embodiment can accurately obtain the target file corresponding to the file management instruction by determining the target file according to the target file path when the accuracy judgment of the initial file path fails, and can accurately obtain the target container corresponding to the file management instruction by determining the target container according to the target container name when the match between the initial container name and the preset container library fails.
[0088] refer to Figure 4 , Figure 4 FIG. 4 is a flow chart of a third embodiment of a container file management method according to the present invention.
[0089] Based on the above embodiments, in this embodiment, after step S20, the method further includes:
[0090] Step S201: Determine the target file format corresponding to the target file.
[0091] It should be understood that the target file format in this embodiment can be obtained according to the suffix of the target file.
[0092] Step S202: Determine the application corresponding to the target container, and determine the application file corresponding to the application.
[0093] It is understandable that before performing container file management, the target container may already have multiple applications. This embodiment can determine the application corresponding to the target container and determine the application file corresponding to the application, that is, the application file that the application needs to use when running.
[0094] Step S203: Determine the application file format corresponding to the application file.
[0095] It should be understood that the application file format in this embodiment can also be obtained according to the suffix of the application file.
[0096] Step S204: Match the target file format and the application file format to obtain a matching result.
[0097] Furthermore, in order to accurately match the target file format and the application file format, in this embodiment, the step S204 includes: when the target file format exists in the application file format, determining that the matching result is a successful match; when the target file format does not exist in the application file format, determining whether the application is compatible with the target file format; if so, determining that the matching result is a successful match.
[0098] It is understandable that when the target file format exists in the application file format, the matching result may be determined to be a successful match.
[0099] It should be understood that when the target file format does not exist in the application file format, it is possible to first determine whether the application is compatible with the target file format, that is, to determine whether the application can run normally when the target file format exists. If so, the matching result is determined to be a successful match; if not, the matching result is determined to be a failed match.
[0100] This embodiment determines the target file format corresponding to the target file, then determines the application corresponding to the target container, determines the application file corresponding to the application, then determines the application file format corresponding to the application file, and then matches the target file format with the application file format to obtain a matching result. This embodiment determines the target file format corresponding to the target file, determines the application file format corresponding to the application, and then matches the target file format with the application file format, thereby improving the matching accuracy.
[0101] Reference Figure 5 , Figure 5 It is a structural block diagram of the first embodiment of the container file management device of the present invention.
[0102] like Figure 5 As shown, the container file management device proposed in the embodiment of the present invention includes:
[0103] An information determination module 10, configured to determine a target file and a target container corresponding to the target file according to a file management instruction sent by a user;
[0104] A matching module 20, used to match the target file with the target container to obtain a matching result;
[0105] The file management module 30 is used to perform container file management on the target file according to the file management instruction when the matching result is a successful match.
[0106] This embodiment determines the target file and the target container corresponding to the target file according to the file management instruction sent by the user, and then matches the target file and the target container to obtain a matching result. When the matching result is a successful match, container file management is performed on the target file according to the file management instruction. This embodiment first determines the target file and the target container according to the file management instruction sent by the user, and can obtain the target file and the target container that need to be managed as a container file. Then, the target file and the target container are matched, and it can be determined whether the target file is in the target container, or it can be determined whether the target file can be uploaded to the target container. When the matching result is a successful match, container file management is performed on the target file according to the file management instruction, and the operation corresponding to the file management instruction can be performed on the target file without performing other operations, so that container file management can be performed safely and effectively.
[0107] It should be noted that the workflow described above is merely illustrative and does not limit the scope of protection of the present invention. In practical applications, technicians in this field can select part or all of them according to actual needs to achieve the purpose of the present embodiment, and no limitation is made here.
[0108] In addition, for technical details not fully described in this embodiment, reference may be made to the container file management method provided in any embodiment of the present invention, and will not be repeated here.
[0109] Based on the first embodiment of the container file management device of the present invention, a second embodiment of the container file management device of the present invention is proposed.
[0110] In this embodiment, the information determination module 10 is further used to obtain the initial file path in the file management instruction sent by the user, and to perform accuracy judgment on the initial file path; when the accuracy judgment fails, determine the target file path according to the initial file path, and determine the target file according to the target file path; obtain the initial container name in the file management instruction, and match the initial container name with a preset container library; when the match fails, determine the target container name according to the initial container name, and determine the target container corresponding to the target file according to the target container name.
[0111] Furthermore, the information determination module 10 is also used to determine the initial file corresponding to the initial file path when the accuracy judgment fails; when the initial file does not exist, perform anomaly detection on the initial file path to obtain the abnormal part; adjust the abnormal part according to a preset path set to obtain the target file path; and determine the target file according to the target file path.
[0112] Furthermore, the information determination module 10 is also used to perform keyword extraction on the initial container name to obtain keywords in the initial container name when the matching fails; select multiple container names from the preset container library based on the keywords; determine the container types corresponding to the multiple container names, and perform type matching between the file type corresponding to the target file and the container type; select a target container name from the multiple container names based on the type matching result, and determine the target container corresponding to the target file based on the target container name.
[0113] Furthermore, the matching module 20 is also used to determine the target file format corresponding to the target file; determine the application corresponding to the target container, and determine the application file corresponding to the application; determine the application file format corresponding to the application file; match the target file format and the application file format to obtain a matching result.
[0114] Furthermore, the matching module 20 is also used to determine that the matching result is a successful match when the target file format exists in the application file format; when the target file format does not exist in the application file format, determine whether the application is compatible with the target file format; if so, determine that the matching result is a successful match.
[0115] Furthermore, the file management module 30 is also used to determine the instruction type corresponding to the file management instruction when the matching result is a successful match; determine the management code corresponding to the instruction type, and perform container file management on the target file through the management code.
[0116] Other embodiments or specific implementations of the container file management device of the present invention may refer to the above-mentioned method embodiments, which will not be described in detail here.
[0117] In addition, an embodiment of the present invention further provides a storage medium, on which a container file management program is stored. When the container file management program is executed by a processor, the steps of the container file management method described above are implemented.
[0118] It should be noted that, in this article, the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, article or system including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or system. In the absence of further restrictions, an element defined by the sentence "comprises a ..." does not exclude the existence of other identical elements in the process, method, article or system including the element.
[0119] The serial numbers of the above embodiments of the present invention are only for description and do not represent the advantages or disadvantages of the embodiments.
[0120] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present invention, or the part that contributes to the prior art, can be embodied in the form of a software product, which is stored in a storage medium (such as a read-only memory / random access memory, a magnetic disk, or an optical disk), and includes a number of instructions for a terminal device (which can be a mobile phone, a computer, a server, or a network device, etc.) to execute the methods described in each embodiment of the present invention.
[0121] The above are only preferred embodiments of the present invention, and are not intended to limit the patent scope of the present invention. Any equivalent structure or equivalent process transformation made using the contents of the present invention specification and drawings, or directly or indirectly applied in other related technical fields, are also included in the patent protection scope of the present invention.
Claims
1. A container file management method, characterized in that: The container file management method comprises the following steps: Determine a target file and a target container corresponding to the target file according to a file management instruction sent by a user; Matching the target file and the target container to obtain a matching result; When the matching result is a successful match, performing container file management on the target file according to the file management instruction; The step of determining the target file and the target container corresponding to the target file according to the file management instruction sent by the user specifically includes: Obtaining an initial file path in a file management instruction sent by a user, and determining the accuracy of the initial file path; When the accuracy determination fails, determining a target file path according to the initial file path, and determining a target file according to the target file path; Obtaining an initial container name in the file management instruction, and matching the initial container name with a preset container library; When the match fails, determining a target container name according to the initial container name, and determining a target container corresponding to the target file according to the target container name; The step of determining the target container name according to the initial container name when the match fails, and determining the target container corresponding to the target file according to the target container name, specifically includes: When the match fails, extracting keywords from the initial container name to obtain keywords in the initial container name; Selecting a plurality of container names from the preset container library according to the keyword; Determine container types corresponding to the multiple container names, and perform type matching between the file type corresponding to the target file and the container type; A target container name is selected from the multiple container names according to the type matching result, and a target container corresponding to the target file is determined according to the target container name.
2. The container file management method according to claim 1, characterized in that: When the accuracy determination fails, determining the target file path according to the initial file path, and determining the target file according to the target file path specifically includes: When the accuracy determination fails, determining the initial file corresponding to the initial file path; When the initial file does not exist, performing anomaly detection on the initial file path to obtain an abnormal part; Adjust the abnormal part according to the preset path set to obtain the target file path; The target file is determined according to the target file path.
3. The container file management method according to claim 1, characterized in that: The step of matching the target file with the target container to obtain a matching result specifically includes: Determine a target file format corresponding to the target file; Determine an application corresponding to the target container, and determine an application file corresponding to the application; Determine an application file format corresponding to the application file; The target file format and the application file format are matched to obtain a matching result.
4. The container file management method according to claim 3, characterized in that: The step of matching the target file format with the application file format to obtain a matching result specifically includes: When the target file format exists in the application file format, determining that the matching result is a successful match; When the target file format does not exist in the application file format, determining whether the application program is compatible with the target file format; If so, the matching result is determined to be a successful match.
5. The container file management method according to any one of claims 1 to 4, characterized in that: When the matching result is a successful match, the step of performing container file management on the target file according to the file management instruction specifically includes: When the matching result is a successful match, determining the instruction type corresponding to the file management instruction; A management code corresponding to the instruction type is determined, and container file management is performed on the target file through the management code.
6. A container file management device, characterized in that: The container file management device comprises: An information determination module, used to determine a target file and a target container corresponding to the target file according to a file management instruction sent by a user; A matching module, used to match the target file with the target container to obtain a matching result; A file management module, configured to perform container file management on the target file according to the file management instruction when the matching result is a successful match; The information determination module is further used to obtain an initial file path in a file management instruction sent by a user, and to perform an accuracy judgment on the initial file path; when the accuracy judgment fails, determine a target file path according to the initial file path, and determine a target file according to the target file path; obtain an initial container name in the file management instruction, and match the initial container name with a preset container library; when the match fails, determine a target container name according to the initial container name, and determine a target container corresponding to the target file according to the target container name; The information determination module is further used to, when matching fails, perform keyword extraction on the initial container name to obtain keywords in the initial container name; select multiple container names from the preset container library based on the keywords; determine container types corresponding to the multiple container names, and perform type matching between the file type corresponding to the target file and the container type; select a target container name from the multiple container names based on the type matching result, and determine a target container corresponding to the target file based on the target container name.
7. A container file management device, characterized in that: The device comprises: a memory, a processor, and a container file management program stored in the memory and executable on the processor, wherein the container file management program is configured to implement the steps of the container file management method according to any one of claims 1 to 5.
8. A storage medium, characterized in that: The storage medium stores a container file management program, and when the container file management program is executed by the processor, the steps of the container file management method according to any one of claims 1 to 5 are implemented.
Citation Information
Patent Citations
File processing method, electronic device, and storage medium
US20240054107A1