Dynamic library file loading method and device, equipment and storage medium

By deleting the dynamic library files in the APP installation package and using the redirect path search method of the preset class loader, the problem of increasing download time and increasing error rate caused by excessive APP installation package is solved, and the problem of increasing download time and increasing error rate is achieved. Reduce download time and reduce error rate effects.

CN119473419APending Publication Date: 2025-02-18JD DIGITS HAIYI INFORMATION TECHNOLOGY CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311000222.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-08-09
Publication Date
2025-02-18

AI Technical Summary

Technical Problem

As the business functions of the APP continue to enrich, the volume of the APP installation package continues to increase, resulting in an increase in download time and an increase in download error rate.

Method used

By deleting the candidate dynamic library files in the original installation package of the target APP, the target installation package is obtained, and the required dynamic library is found and the APP runtime search method is used to search and load the default class loader's redirect path search method during the APP. document.

Benefits of technology

The size of the installation package is reduced, the download time is reduced, and the download error rate is reduced, while ensuring the normal operation of the APP and the normal use of extended business functions.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119473419A_ABST
    Figure CN119473419A_ABST
Patent Text Reader

Abstract

The embodiment of the invention discloses a dynamic library file loading method and device, equipment and a storage medium, and relates to the technical field of computers.The method can comprise the steps that in response to an installation instruction for a target APP, installation operation is conducted on the target APP based on a target installation package carried by the installation instruction; wherein the target installation package is an installation package obtained by deleting each candidate dynamic library file in an original installation package of the target APP; under the condition that a dynamic library file loading request is obtained, a target dynamic library file corresponding to a file identifier carried by the dynamic library file loading request is searched based on a predefined path by executing a redirection path searching method of a preset class loader, and the searched target dynamic library file is loaded. By adopting the technical scheme of the embodiment of the invention, the downloading duration of the installation package can be reduced and the downloading error rate of the installation package can be reduced under the condition of ensuring the normal operation of the APP.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present invention relate to the field of computer technology, and in particular to a method, device, equipment and storage medium for loading a dynamic library file. Background Art

[0002] With the rapid development of Internet technology and the popularization of mobile terminals, a large number of applications (Application, APP) that can be used in mobile terminals have emerged. These APPs have provided great convenience to our daily life and work.

[0003] However, in the process of implementing the present invention, it was found that there are at least the following problems in the prior art: as the business functions of APP are continuously enriched, the size of APP installation package continues to increase, resulting in an increase in the download time and download error rate of the installation package. Summary of the invention

[0004] The embodiments of the present invention provide a method, device, equipment and storage medium for loading a dynamic library file, which can reduce the download time of an installation package and reduce the download error rate of the installation package.

[0005] In the first aspect, an embodiment of the present invention provides a method for loading a dynamic library file, which may include: in response to an installation instruction for a target APP, performing an installation operation on the target APP based on a target installation package carried by the installation instruction; wherein the target installation package is an installation package obtained by deleting each candidate dynamic library file in an original installation package of the target APP; when a dynamic library file loading request is obtained, a redirection path search method of a preset class loader is executed, and a target dynamic library file corresponding to a file identifier carried by the dynamic library file loading request is searched based on a predefined path, and the found target dynamic library file is loaded.

[0006] In a second aspect, an embodiment of the present invention further provides a dynamic library file loading device, which may include: an installation module and a loading module;

[0007] Specifically, the installation module is used to respond to the installation instruction for the target application APP and perform an installation operation on the target APP based on the target installation package carried by the installation instruction; wherein the target installation package is an installation package obtained by deleting each candidate dynamic library file in the original installation package of the target APP;

[0008] The loading module is used to, when a dynamic library file loading request is obtained, search for the target dynamic library file corresponding to the file identifier carried in the dynamic library file loading request based on the predefined path by executing the redirection path search method of the preset class loader, and load the found target dynamic library file.

[0009] In a third aspect, an embodiment of the present invention provides a dynamic library file loading device, the dynamic library file loading device comprising:

[0010] one or more processors;

[0011] A memory for storing one or more programs;

[0012] When the one or more programs are executed by the one or more processors, the one or more processors implement the dynamic library file loading method provided by any embodiment of the present invention.

[0013] In a fourth aspect, an embodiment of the present invention further provides a computer-readable storage medium on which a computer program is stored, and when the program is executed by a processor, a method for loading a dynamic library file as provided in any embodiment of the present invention is implemented.

[0014] The embodiments of the above invention have the following advantages or beneficial effects:

[0015] In the technical solution provided by the embodiment of the present invention, when the installation instruction for the target APP is obtained, the target APP can be installed based on the target installation package carried by the installation instruction in response to the installation instruction. Among them, the target installation package can be an installation package obtained by pre-deleting the candidate dynamic library files in the original installation package of the target APP. Generally, most of the volume in the installation package of the APP is occupied by the dynamic library (Shared Object, SO) file. Therefore, the embodiment of the present invention deletes the candidate dynamic library files in the original installation package, which can greatly reduce the volume of the installation package, thereby reducing the download time of the installation package, and can reduce the download error rate of the installation package. In addition, in order to ensure the normal operation of the business functions implemented by the deleted candidate dynamic library files, the embodiment of the present invention can pre-define a preset class loader, and through the redirection path search method of the preset class loader, the search and loading of the deleted candidate dynamic library files can be realized. Specifically, during the APP running phase, when the operation of a certain business function requires loading a target dynamic library file, a dynamic library file loading request carrying a file identifier can be obtained. When the dynamic library file loading request is obtained, the target dynamic library file corresponding to the file identifier can be found based on the predefined path by executing the redirection path search method of the preset class loader, and the found target dynamic library file can be loaded. It can be seen that in the technical solution provided by the embodiment of the present invention, the size of the installation package can be reduced by deleting the dynamic library files in the installation package while ensuring the normal operation of the APP, thereby reducing the download time of the installation package and reducing the download error rate of the installation package. BRIEF DESCRIPTION OF THE DRAWINGS

[0016] Figure 1 It is a flow chart of a method for loading a dynamic library file provided by an embodiment of the present invention;

[0017] Figure 2 It is a flow chart of another method for loading a dynamic library file provided by an embodiment of the present invention;

[0018] Figure 3 It is a flowchart of another method for loading a dynamic library file provided by an embodiment of the present invention;

[0019] Figure 4 It is a structural schematic diagram of a dynamic library file loading device provided by an embodiment of the present invention;

[0020] Figure 5 It is a structural schematic diagram of a dynamic library file loading device provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0021] The present invention will be further described in detail below in conjunction with the accompanying drawings and embodiments. It is to be understood that the specific embodiments described herein are only used to explain the present invention, rather than to limit the present invention. In addition, it should be noted that, for ease of description, only parts related to the present invention, rather than all structures, are shown in the accompanying drawings.

[0022] The term "and / or" in this article is merely a description of the association relationship of associated objects, indicating that three relationships may exist. For example, A and / or B can mean: A exists alone, A and B exist at the same time, and B exists alone.

[0023] In addition, the terms "including" and "having" and any variations thereof mentioned in the description of the embodiments of the present invention are intended to cover non-exclusive inclusions. For example, a process, method, system, product or device including a series of steps or units is not limited to the listed steps or units, but may optionally include other steps or units that are not listed, or may optionally include other steps or units that are inherent to these processes, methods, products or devices.

[0024] It should be noted that, in the embodiments of the present invention, words such as "exemplary" or "for example" are used to indicate examples, illustrations or explanations. Any embodiment or design scheme described as "exemplary" or "for example" in the embodiments of the present invention should not be interpreted as being more preferred or more advantageous than other embodiments or designs. Specifically, the use of words such as "exemplary" or "for example" is intended to present related concepts in a specific way.

[0025] In the description of the embodiments of the present invention, unless otherwise specified, “plurality” or “each” means two or more than two.

[0026] Figure 1 A flowchart of a method for loading a dynamic library file provided by an embodiment of the present invention. The method can be executed by a dynamic library file loading device provided by an embodiment of the present invention, and the device can be implemented in software and / or hardware and integrated in a dynamic library file loading device.

[0027] Exemplarily, the dynamic library file loading device can be different types of user terminals such as mobile phones, tablet computers, desktop computers, laptop computers, notebook computers, ultra-mobile personal computers (UMPC), handheld computers, netbooks, personal digital assistants (PDA), wearable electronic devices, virtual reality devices, etc. In the following description of the embodiments of the present invention, the dynamic library file loading device is an example of a user terminal.

[0028] like Figure 1 As shown, the method for loading a dynamic library file provided by an embodiment of the present invention specifically includes the following steps:

[0029] S110 . In response to an installation instruction for a target APP, perform an installation operation on the target APP based on a target installation package carried in the installation instruction.

[0030] The target APP may be any type of APP for providing services to users. For example, the target APP may be a shopping APP.

[0031] In one possible implementation, when a user wants to install a target APP to use the services provided by the target APP, the user can perform trigger operations such as clicking, sliding, or long pressing on the application distribution control (for example, it can be an icon of the application market) in the display interface of the user terminal, triggering the user terminal to display the installation controls of each candidate APP in the display interface. Afterwards, the user can find the installation control of the target APP from the installation controls of each displayed candidate APP, and trigger the installation control of the target APP. The user terminal can obtain the target installation package corresponding to the target APP based on the trigger operation, and then display the installation confirmation area in the display interface. Exemplarily, the installation confirmation area may include a confirmation installation control and a cancel installation control. The user can trigger the installation instruction by selecting the confirmation installation control in the installation confirmation area, so that the user terminal can install the target APP based on the target installation package carried by the installation instruction.

[0032] It is understandable that, in actual applications, the installation instruction may also be triggered by other methods, and the method of triggering the installation instruction provided in the embodiment of the present invention is only an example and does not constitute a limitation on the method of triggering the installation instruction.

[0033] The target installation package is an installation package obtained by deleting each candidate dynamic library file in the original installation package of the target APP. Exemplarily, taking the Android operating system as an example, the installation package may be an Android application package (APK).

[0034] Exemplarily, the original installation package of the target APP may consist of the following files: a META-INF folder (i.e., a signature file directory), a res folder (i.e., a resource library directory, for storing XML layout files and icons), an AndroidMainifest.xml file (i.e., a configuration list, generally in binary format), a classes.dex file (i.e., an executable file on the Android operating system), a resources.arsc file (i.e., a resource index file), an assets folder (i.e., a resource target, for storing images), and a lib folder (i.e., a dynamic library directory, for storing dynamic library files).

[0035] Generally, most of the volume in the original installation package of the APP is occupied by dynamic library files, and among these dynamic library files, some dynamic library files are not necessary files in the startup process of the APP. Therefore, in an embodiment of the present invention, for the target APP, the non-essential dynamic library files in its original installation package (that is, the candidate dynamic library files in the embodiment of the present invention) can be deleted to obtain the target installation package. In this way, by separating the non-essential dynamic library files from the original installation package, the purpose of reducing the size of the installation package can be achieved. When the target APP is installed, the target installation package with reduced size is installed, which can reduce the download time of the installation package, and can reduce the download error rate of the installation package, thereby reducing the occurrence of situations where users do not want to download the installation package.

[0036] In one possible implementation, in the process of deleting the original installation package of the target APP, the necessary dynamic library files and non-essential dynamic library files can be determined from each dynamic library file according to the business functions implemented by each dynamic library file in the dynamic library directory of the original installation package, and then the non-essential dynamic library files in the original installation package are deleted to obtain the target installation package. Among them, the business functions implemented by the necessary dynamic library files can be the basic business functions provided by the target APP, and the business functions implemented by the non-essential dynamic library files can be the extended business functions provided by the target APP.

[0037] Exemplarily, taking the target APP as a shopping APP, the business functions implemented by each dynamic library file in the original installation package of the shopping APP may include: shopping function, payment function, chat function, and entertainment function, etc. Among them, the shopping function and the payment function are the basic business functions used by the user during the use of the shopping APP, and the chat function and the entertainment function are the extended business functions that the user may use during the use of the shopping APP. Then, in the process of deleting the original installation package of the shopping APP, the dynamic library files used to implement the shopping function and the payment function in the dynamic library files of the original installation package of the shopping APP can be determined as necessary dynamic library files; and the dynamic library files used to implement the chat function and the entertainment function in the dynamic library files of the original installation package of the shopping APP can be determined as non-essential dynamic library files. After that, the non-essential dynamic library files in the original installation package of the shopping APP can be deleted to obtain the target installation package of the shopping APP. Since the chat function and the entertainment function are not business functions that all users must use during the use of the shopping APP, after deleting the non-essential dynamic library files used to implement the chat function and the entertainment function in the original installation package of the shopping APP, it will not affect the normal startup of the shopping APP and the operation of the basic business functions.

[0038] It is understandable that in actual applications, necessary dynamic library files and non-essential dynamic library files may also be determined from various dynamic library files based on other classification methods, and the embodiment of the present invention does not limit this.

[0039] It should be noted that, in the embodiment of the present invention, the process of deleting the original installation package of the target APP is performed before the installation package of the target APP is released. That is, when the target APP is released, the released installation package is the deleted target installation package. In this way, when the user triggers the installation instruction, the installation package obtained by the user terminal is already the deleted target installation package.

[0040] After the user terminal obtains the target installation package, the target APP can be installed. In one possible implementation, the steps of installing the target APP may include: copying the target installation package to the system installation directory; unpacking the target installation package to obtain other files except the candidate dynamic library files; parsing the configuration list in the other unpacked files; creating a shortcut control of the target APP (for example, the icon of the target APP) in the display interface of the user terminal. Specifically, the process of the user terminal installing the target APP can refer to the relevant description in the prior art, and the embodiments of the present invention will not be repeated here.

[0041] It should also be noted that, although the deletion of the candidate dynamic library files in the original installation package will not affect the normal startup of the target APP and the operation of the basic business functions, the user may have the need to use the extended business functions at any time during the use of the target APP. Therefore, in the embodiment of the present invention, in order to ensure that the user can normally use the services provided by these extended business functions when there is a need to use the extended business functions, after deleting the candidate dynamic library files in the original installation package, each candidate dynamic library file can be stored in a certain address (i.e., the dynamic library file download address in the embodiment of the present invention). When the user needs to use a certain extended business function, the user terminal can obtain the dynamic library file used to implement the extended business function from the address. In this way, it can be ensured that the user can normally use the services provided by the extended business function.

[0042] S120. When a dynamic library file loading request is obtained, a redirection path search method of a preset class loader is executed to search for a target dynamic library file corresponding to a file identifier carried in the dynamic library file loading request based on a predefined path, and the found target dynamic library file is loaded.

[0043] The dynamic library file loading request may be a request triggered by a user through a trigger operation in the display interface of the target APP. For example, still taking the shopping APP as an example, if the user needs to use the chat function while using the shopping APP, the user may trigger the control corresponding to the chat function in the display interface of the shopping APP, thereby triggering the user terminal to obtain the dynamic library file loading request.

[0044] Existing, when the APP runs normally, a class loader (i.e., the original class loader in the embodiment of the present invention) will be saved in the memory. When the APP needs to load a dynamic library file during operation, the class loader can find the dynamic library file from the system installation directory where the dynamic library files are stored and load it. In the embodiment of the present invention, when the APP needs to load a candidate dynamic library file (for example, the dynamic library file corresponding to the extended business function of the shopping APP) during operation, since the target installation package of the APP does not contain the candidate dynamic library files, then the system installation directory will not store the candidate dynamic library files. Therefore, at this time, the user terminal cannot find the candidate dynamic library file from the system installation directory, and of course, it is impossible to load the candidate dynamic library file. In this way, it will affect the user's use of the business function implemented by the candidate dynamic library file.

[0045] In order not to affect the user's use of the extended business function, it can be considered that each candidate target dynamic library file to be deleted is stored separately in the system installation directory. However, other files in the system installation directory (files that are not deleted in the original installation package) are written to the system installation directory by the system during the APP installation phase, and the APP itself does not have the write permission of the system installation directory. Then, after each candidate dynamic library file in the original installation package is deleted and stored at a certain address, since there is no write permission of the system installation directory, it is impossible to write each candidate dynamic library file separately to the system installation directory after the APP installation is completed. Based on this, the embodiment of the present invention can write each candidate dynamic library file to other paths (i.e., the predefined path in the embodiment of the present invention). Specifically, when the user terminal obtains the dynamic library file loading request, it can search for each candidate dynamic library file for implementing the extended business function based on the predefined path through the redirection path search method of the predefined preset class loader. In this way, the normal operation of the business function implemented by each deleted candidate dynamic library file can be ensured without modifying the write permission of the system installation directory.

[0046] The preset class loader may be a predetermined class loader. The embodiment of the present invention redefines the path search method of the user terminal when loading a dynamic library file for the preset class loader, that is, the redirection path search method in the embodiment of the present invention, and the redirection path search method can redirect the search path. When the user terminal executes the redirection path search method, it can find the required target dynamic library file from the predefined path.

[0047] The predefined path may be a storage path determined in advance.

[0048] Optionally, after performing the installation operation on the target APP based on the target installation package carried by the installation instruction, and before searching for the target dynamic library file corresponding to the file identifier carried by the dynamic library file loading request based on a predefined path, the dynamic library file loading method provided by an embodiment of the present invention may further include: when a startup instruction for the target APP is obtained, replacing the original class loader with a preset class loader.

[0049] The original class loader may be a class loader created by the system.

[0050] In a possible implementation, after the user terminal completes the installation operation of the target APP, a shortcut control of the target APP can be added to the display interface, and the user can trigger the shortcut control of the target APP to trigger the user terminal to obtain a startup instruction for the target APP. After the user terminal obtains the startup instruction, the target APP can be started. After the target APP is started, the user can start using the services provided by the target APP.

[0051] Since the system has provided the APP with the original class loader used to load the dynamic library file during the operation of the APP, in order to ensure that during the operation of the APP, the user terminal can use the redirection path search method of the preset class loader to successfully find the deleted candidate dynamic library files, the embodiment of the present invention needs to replace the original class loader provided by the system with the preset class loader. In addition, after the target APP is started, the user may have the need to use the business functions provided by the candidate dynamic library files at any time, that is, the user may trigger the dynamic library file loading request at any time. Therefore, in the embodiment of the present invention, the class loader can be replaced in the startup phase of the target APP before the user uses the service provided by the target APP. In this way, it can be ensured that when the user terminal obtains the dynamic library file loading request, the original class loader has been replaced with the preset class loader, thereby satisfying the user's need to use the business functions provided by the candidate dynamic library files at any time.

[0052] Optionally, replacing the original class loader with the preset class loader may include: in the entry function of the target APP, replacing the original class loader with the preset class loader.

[0053] The target APP's entry function is the first function executed by the target APP during startup, and may be a piece of executable code. In the embodiment of the present invention, the class loader may be replaced by executing the code corresponding to the target APP's entry function.

[0054] In an embodiment of the present invention, in order to further ensure that the original class loader has been replaced with the preset class loader when a dynamic library file loading request is obtained, the code corresponding to the entry function of the target APP can be recompiled in advance so that the recompiled code is used to replace the original class loader with the preset class loader. In this way, when the user terminal starts the target APP, after the original class loader loads the entry function of the target APP, the class loader can be replaced in the first step of starting the target APP by executing the recompiled code of the entry function of the target APP.

[0055] In the method for loading dynamic library files provided by an embodiment of the present invention, when an installation instruction for a target APP is obtained, the target APP can be installed based on the target installation package carried by the installation instruction in response to the installation instruction. Among them, the target installation package can be an installation package obtained by pre-deleting the candidate dynamic library files in the original installation package of the target APP. Generally, most of the volume in the installation package of the APP is occupied by the dynamic library files. Therefore, the embodiment of the present invention deletes the candidate dynamic library files in the original installation package, which can greatly reduce the volume of the installation package, thereby reducing the download time of the installation package and reducing the download error rate of the installation package. In addition, in order to ensure the normal operation of the business functions implemented by the deleted candidate dynamic library files, the embodiment of the present invention can pre-define a preset class loader, and through the redirection path search method of the preset class loader, the search and loading of the deleted candidate dynamic library files can be realized. Specifically, during the APP running phase, when the operation of a certain business function requires loading a target dynamic library file, a dynamic library file loading request carrying a file identifier can be obtained. When the dynamic library file loading request is obtained, the target dynamic library file corresponding to the file identifier can be found based on the predefined path by executing the redirection path search method of the preset class loader, and the found target dynamic library file can be loaded. It can be seen that in the technical solution provided by the embodiment of the present invention, the size of the installation package can be reduced by deleting the dynamic library files in the installation package while ensuring the normal operation of the APP, thereby reducing the download time of the installation package and reducing the download error rate of the installation package.

[0056] Reference Figure 2 , is a flow chart of another method for loading a dynamic library file provided by an embodiment of the present invention. The method in this embodiment can be combined with various optional solutions in the method for loading a dynamic library file provided by the previous embodiment, and the method for loading a dynamic library file provided by the previous embodiment is further optimized. Figure 2 As shown, the specific steps include:

[0057] S210: In response to an installation instruction for a target APP, perform an installation operation on the target APP based on a target installation package carried in the installation instruction.

[0058] Optionally, in a possible implementation, the target installation package in the embodiment of the present invention can be obtained by the target APP's service server processing the target APP's original installation package. Specifically, during the process of compiling the original installation package, the service server can delete each candidate dynamic library file in the original installation package to obtain the target installation package.

[0059] Optionally, in another possible implementation, the target installation package in the embodiment of the present invention can be obtained in advance by the compilation server of the target APP in the following manner: the candidate dynamic library files in the original installation package are deleted by the compilation plug-in, and the original installation package after the deletion is determined as the target installation package.

[0060] The compilation plug-in may be a plug-in developed in advance by a developer using a compilation tool, and the compilation plug-in is used to delete each candidate dynamic library file in the original installation package.

[0061] In one possible implementation, the compilation server can be a unified platform for deleting the original installation package. Exemplarily, after the developer of the target APP uploads the source code of the original installation package to the business server of the target APP, the business server can send the acquired source code of the original installation package to the compilation server. After the compilation server receives the source code of the original installation package, it can call the internal compilation plug-in to compile the source code of the original installation package. During the compilation process, each candidate dynamic library file is dynamically deleted to obtain the target installation package. Afterwards, the compilation server can return the target installation package to the business server, and the business server will publicly release the target installation package.

[0062] In another possible implementation, the compilation server may be the business server itself. For example, after the developer of the target APP uploads the source code of the original installation package to the business server of the target APP, the business server may call the compilation plug-in to compile the source code of the original installation package. During the compilation process, each candidate dynamic library file is dynamically deleted to obtain the target installation package.

[0063] In addition, before the target APP's developer uploads the source code of the original installation package to the target APP's business server, the developer can mark the files corresponding to each part of the code in the source code of the original installation package. For example, the part corresponding to the extended business function can be marked in the source code of the original installation package. When the compilation server calls the compilation plug-in to compile the source code of the original installation package, it can identify the parts corresponding to each candidate dynamic library file based on the marked declaration, thereby realizing the deletion of each candidate dynamic library file in the original installation package during the compilation period.

[0064] The method for loading dynamic library files provided in an embodiment of the present invention can achieve the purpose of reducing the installation package of the APP by deleting the candidate dynamic library files in the original installation package. However, most of the components used by the business server are common components provided by a third-party server, so it is difficult to modify the components of the business server. Therefore, an embodiment of the present invention can complete the deletion of the candidate dynamic library files in the original installation package by compiling a plug-in, so that the modification of the components of the business server can be avoided.

[0065] S220. When a dynamic library file loading request is obtained, a target dynamic library file corresponding to the file identifier is obtained based on the dynamic library file download address by executing a redirection path search method of a preset class loader, and the obtained target dynamic library file is downloaded to a predefined directory in a predefined path, and the target dynamic library file corresponding to the file identifier is searched from the predefined directory, and the found target dynamic library file is loaded.

[0066] The dynamic library file download address is the storage address of each candidate dynamic library file after being deleted from the original installation package. The predefined directory can be a folder created in advance in a predefined path.

[0067] In a possible implementation, the compilation server can upload the deleted candidate dynamic library files to a predetermined storage server during the deletion process of the original installation package. The dynamic library file download address can be the address for storing the candidate dynamic library files generated by the storage server after acquiring the candidate dynamic library files.

[0068] Exemplary, still taking the shopping APP as an example, in the process of deleting the original installation package on the compilation server, the target dynamic library file corresponding to the chat function provided by the shopping APP can be deleted and uploaded to the storage server. After the storage server obtains the target dynamic library file, it can generate a dynamic library file download address for storing the target dynamic library file. During the use of the shopping APP, if the user needs to use the chat function, a dynamic library file loading request carrying a file identifier corresponding to the target dynamic library file can be triggered. After the user terminal obtains the dynamic library file loading request, the target dynamic library file corresponding to the file identifier can be obtained from the dynamic library file download address by executing the redirection path search method of the preset class loader. The download path defined in the redirection path search method is a predefined directory in the predefined path. The predefined directory is not a system installation directory, so the target APP has the authority to write files to the predefined directory. Then, after the user terminal obtains the target dynamic library file from the dynamic library file download address, the target dynamic library file can be successfully downloaded to the predefined directory, and the target dynamic library file in the predefined directory can be successfully loaded. After the user terminal loads the target dynamic library file, the user can use the chat function provided by the shopping APP normally.

[0069] Optionally, before obtaining the target dynamic library file corresponding to the file identifier based on the dynamic library file download address, the dynamic library file loading method provided by the embodiment of the present invention may also include: querying the dynamic library file download address through a preset access interface; or, obtaining the dynamic library file download address parsed from the target installation package.

[0070] The preset access interface may be a pre-determined access interface, which is used to link to the dynamic library file download address.

[0071] In a possible implementation, the user terminal can obtain the dynamic library file download address through a preset access interface during the process of starting the target APP, and then store the dynamic library file download address locally. Afterwards, when a dynamic library file loading request is obtained, the user terminal can obtain the dynamic library file download address locally. Alternatively, the user terminal can also obtain the dynamic library file download address through a preset access interface after obtaining the dynamic library file loading request.

[0072] In another possible implementation, after the compilation server uploads each candidate dynamic library file to the storage server, the storage server can return the dynamic library file download address to the compilation server, and the compilation server can add the dynamic library file download address to the target installation package. When installing the target APP, the user terminal can parse the dynamic library file download address from the target installation package and store the parsed dynamic library file download address locally. After obtaining the dynamic library file loading request, the user terminal can obtain the dynamic library file download address previously parsed from the target installation package from the local.

[0073] Optionally, loading the found target dynamic library file may include: verifying the found target dynamic library file to obtain a verification result; and loading the found target dynamic library file when it is determined that the verification result is passed.

[0074] Because before the target dynamic library file is loaded, the target dynamic library file may be invaded at any time and illegally tampered. For example, the transmission process of the user terminal obtaining the target dynamic library file from the dynamic library file download address, the download process of the user terminal downloading the obtained target dynamic library file to the predefined directory, and the process from the user terminal downloading the predefined directory to the loading of the target dynamic library file, the target dynamic library file all has data security risks. Therefore, in the embodiment of the present invention, before loading the target dynamic library file, the target dynamic library file can be subjected to a security check, and the target dynamic library file can be loaded after the check is passed, so that the data security of the target dynamic library file can be ensured, thereby ensuring the normal operation of the business corresponding to the target dynamic library file.

[0075] Optionally, after verifying the found target dynamic library file and obtaining the verification result, the dynamic library file loading method provided by the embodiment of the present invention may further include: when it is determined that the verification result is a verification failure, deleting the target dynamic library file in the predefined directory; based on the dynamic library file download address, re-obtaining the target dynamic library file corresponding to the file identifier, and downloading the re-obtained target dynamic library file to the predefined directory; re-searching for the target dynamic library file corresponding to the file identifier from the predefined directory, and loading the re-found target dynamic library file.

[0076] Since the target dynamic library file is at risk of being invaded during the entire process from obtaining the target dynamic library file to loading the target dynamic library file, in an embodiment of the present invention, when the verification result of the target dynamic library file is that the verification fails, the target dynamic library file in the predefined directory can be deleted, and the target dynamic library file can be re-obtained from the most original storage path (that is, the dynamic library file download address) and loaded. In this way, after the target dynamic library file is invaded, the user can be prevented from reinstalling the target APP, which affects the user's experience.

[0077] Optionally, verifying the found target dynamic library file to obtain a verification result may include: determining a first encryption parameter of the found target dynamic library file; comparing the first encryption parameter with the second encryption parameter; when it is determined that the first encryption parameter is consistent with the second encryption parameter, determining the verification result as a passed verification; when it is determined that the first encryption parameter is inconsistent with the second encryption parameter, determining the verification result as a failed verification.

[0078] The second encryption parameter is an encryption parameter for the target dynamic library file determined in the process of storing each candidate dynamic library file in the dynamic library file download address.

[0079] In a possible implementation, before uploading each candidate dynamic library file to the storage server, the compiling server can calculate each candidate dynamic library file separately to determine the second encryption parameter of each candidate dynamic library file. During the process of verifying the found target dynamic library file, the user terminal can obtain the second encryption parameter of the target dynamic library file through a preset access interface.

[0080] In another possible implementation, after receiving the dynamic library file download address returned by the storage server, the compiling server can also calculate each candidate dynamic library file separately to determine the second encryption parameter of each candidate dynamic library file, and then add the dynamic library file download address and the second encryption parameter of each candidate dynamic library file to the target installation package. In the process of verifying the found target dynamic library file, the user terminal can obtain the second encryption parameter of the target dynamic library file parsed from the target installation package.

[0081] The first encryption parameter and the second encryption parameter may be encryption parameters obtained by a preset encryption algorithm. Exemplarily, the preset encryption algorithm may be an MD5 message digest algorithm (MD5 Message-Digest Algorithm), and the first encryption parameter and the second encryption parameter may be MD5 values. It is understandable that in actual applications, the first encryption parameter and the second encryption parameter may also be other parameters, which is not limited in the embodiments of the present invention.

[0082] Optionally, searching for the target dynamic library file corresponding to the file identifier carried in the dynamic library file loading request based on a predefined path may include: searching for the target dynamic library file corresponding to the file identifier in the system installation directory of the target installation package; and when it is determined that the target dynamic library file corresponding to the file identifier is not found in the system installation directory, searching for the target dynamic library file corresponding to the file identifier based on the predefined path.

[0083] In an embodiment of the present invention, each candidate dynamic library file used to implement the extended business function in the original installation package can be deleted. However, in actual applications, the user's utilization rate for some extended business functions (i.e., the target extended business function described below) may be very high. Therefore, in order to meet the use requirements of most users for the target APP, the dynamic library file used to implement the target extended business function can also be determined as a non-candidate dynamic library file, that is, the dynamic library file corresponding to the target extended business function can be retained in the target installation package. The dynamic library file corresponding to the target extended business function can be written to the system installation directory during the installation phase of the target APP. In this way, when the user needs to use the target extended business function, the dynamic library file corresponding to the target extended business function can be found directly from the system installation directory, and the dynamic library file corresponding to the target extended business function can be loaded without re-downloading the dynamic library file corresponding to the target extended business function, which can reduce the response rate of the user terminal to the dynamic library file loading request corresponding to the target extended business function, thereby improving the user experience. It can be seen that in an embodiment of the present invention, some of the dynamic library files that need to be loaded during the operation of the APP still exist in the system installation directory. Based on this, before searching for the target dynamic library file, the embodiment of the present invention can first search in the system installation directory of the target installation package. If it is determined that the target dynamic library file corresponding to the file identifier is not found in the system installation directory, the target dynamic library file corresponding to the file identifier can be searched based on the predefined path.

[0084] In an embodiment of the present invention, based on the above-mentioned embodiment, when a dynamic library file loading request is obtained, a target dynamic library file corresponding to the file identifier can be obtained based on the dynamic library file download address by executing a redirection path search method of a preset class loader, and the obtained target dynamic library file can be downloaded to a predefined directory in a predefined path, and then the target dynamic library file corresponding to the file identifier can be searched from the predefined directory. In this way, after deleting each candidate dynamic library file in the original installation package, the dynamic download of the candidate dynamic library file can be realized according to the user's usage requirements, thereby ensuring the normal operation of the business functions realized by each deleted candidate dynamic library file.

[0085] It should be noted that the embodiment of the present invention and the method for loading dynamic library files proposed in the aforementioned embodiment belong to the same inventive concept. The technical details not fully described in this embodiment can be found in the aforementioned embodiment, and the beneficial effects of the aforementioned embodiment are also applicable to this embodiment.

[0086] Reference Figure 3 , is a flow chart of another method for loading a dynamic library file provided by an embodiment of the present invention. The method for loading a dynamic library file can be applied to a dynamic library file loading system including a compilation server, a storage server, and a user terminal. Figure 3 As shown, the method for loading the dynamic library file may specifically include the following steps:

[0087] S310, the compilation server deletes each candidate dynamic library file in the original installation package through the compilation plug-in, determines the original installation package after the deletion process as the target installation package, and uploads each deleted candidate dynamic library file to the storage server.

[0088] S320: The storage server stores the target installation package and generates a dynamic library file download address for storing each candidate dynamic library file.

[0089] S330: The user terminal responds to the installation instruction for the target APP and performs an installation operation on the target APP based on the target installation package carried in the installation instruction.

[0090] S340: When the user terminal obtains the startup instruction for the target APP, the user terminal replaces the original class loader with the preset class loader in the entry function of the target APP.

[0091] S350. When the user terminal obtains a dynamic library file loading request, it obtains the target dynamic library file corresponding to the file identifier based on the dynamic library file download address by executing the redirection path search method of the preset class loader, and downloads the obtained target dynamic library file to a predefined directory in the predefined path.

[0092] S360: The user terminal verifies the found target dynamic library file to obtain a verification result; if the verification result is determined to be passed, the found target dynamic library file is loaded.

[0093] Among them, step S310 and step S320 are executed in the compilation phase of the target APP, step S330 is executed in the installation phase of the target APP, step S340 is executed in the startup phase of the target APP, and step S350 and step S360 are executed in the running phase of the target APP.

[0094] In addition, in the prior art, a plug-in solution is proposed for the problem of reducing the size of the installation package. This plug-in solution is implemented by injecting the plug-in path of the dynamic library file into nativeLibraryDirectories (native library file path). Since the specific implementation of nativeLibraryDirectories is an ArrayList (dynamic array) instance, the read and write operations of its elements themselves do not guarantee thread safety. In the process of implementing the plug-in solution, after downloading the deleted dynamic library file, it is necessary to inject the path of the new dynamic library file into the ArrayList. If another thread is traversing the ArrayList because of performing a read operation (so loading) at this time, the path of the new dynamic library file cannot be injected into the ArrayList due to a read-write conflict. The technical solution provided by the embodiment of the present invention does not cause a read-write conflict when searching for the target dynamic library file in the predefined directory. Therefore, compared with this plug-in solution, the embodiment of the present invention can ensure thread safety.

[0095] The dynamic library file loading method provided in the embodiment of the present invention belongs to the same inventive concept as the dynamic library file loading method of the aforementioned embodiments. For details not described in detail in this embodiment, reference can be made to the embodiments of the dynamic library file loading method described above.

[0096] Figure 4 A schematic diagram of the structure of a dynamic library file loading device provided by an embodiment of the present invention, the device comprises: an installation module and a loading module.

[0097] Exemplarily, the installation module 410 may execute S110 in the above method embodiment, and the loading module 420 may execute S120 in the above method embodiment.

[0098] Specifically, the installation module 410 is used to respond to the installation instruction for the target application APP and perform an installation operation on the target APP based on the target installation package carried in the installation instruction; wherein the target installation package is an installation package obtained by deleting each candidate dynamic library file in the original installation package of the target APP;

[0099] The loading module 420 is used to, when a dynamic library file loading request is obtained, search for the target dynamic library file corresponding to the file identifier carried in the dynamic library file loading request based on a predefined path by executing a redirection path search method of a preset class loader, and load the found target dynamic library file.

[0100] Optionally, in a possible implementation manner, the loading module 420 is specifically used for:

[0101] Based on the dynamic library file download address, the target dynamic library file corresponding to the file identifier is obtained, and the obtained target dynamic library file is downloaded to a predefined directory in a predefined path; wherein the dynamic library file download address is the storage address of each candidate dynamic library file after being deleted from the original installation package; the target dynamic library file corresponding to the file identifier is searched from the predefined directory.

[0102] Optionally, in another possible implementation, the target installation package is pre-obtained by the compilation server of the target APP in the following manner: each candidate dynamic library file in the original installation package is deleted by a compilation plug-in, and the original installation package after the deletion is determined as the target installation package.

[0103] Optionally, in another possible implementation manner, the dynamic library file loading device provided by the embodiment of the present invention may further include an acquisition module;

[0104] An acquisition module, used to query the dynamic library file download address through a preset access interface before the loading module 420 acquires the target dynamic library file corresponding to the file identifier based on the dynamic library file download address;

[0105] Alternatively, the acquisition module is further configured to acquire the dynamic library file download address parsed from the target installation package before the loading module 420 acquires the target dynamic library file corresponding to the file identifier based on the dynamic library file download address.

[0106] Optionally, in another possible implementation manner, the loading module 420 is further configured to:

[0107] The found target dynamic library file is verified to obtain a verification result; when it is determined that the verification result is passed, the found target dynamic library file is loaded.

[0108] Optionally, in another possible implementation, the loading module 420 is further used for:

[0109] When it is determined that the verification result is a verification failure, the target dynamic library file in the predefined directory is deleted; based on the dynamic library file download address, the target dynamic library file corresponding to the file identifier is re-obtained, and the re-obtained target dynamic library file is downloaded to the predefined directory; the target dynamic library file corresponding to the file identifier is re-searched from the predefined directory, and the re-found target dynamic library file is loaded.

[0110] Optionally, in another possible implementation manner, the loading module 420 is further configured to:

[0111] Determine a first encryption parameter of the target dynamic library file found; compare the first encryption parameter with the second encryption parameter; wherein the second encryption parameter is an encryption parameter for the target dynamic library file determined during the process of storing each candidate dynamic library file in the dynamic library file download address; when it is determined that the first encryption parameter is consistent with the second encryption parameter, determine the verification result as a passed verification; when it is determined that the first encryption parameter is inconsistent with the second encryption parameter, determine the verification result as a failed verification.

[0112] Optionally, in another possible implementation manner, the loading module 420 is further configured to:

[0113] Search the target dynamic library file corresponding to the file identifier in the system installation directory of the target installation package;

[0114] When it is determined that the target dynamic library file corresponding to the file identifier is not found in the system installation directory, the target dynamic library file corresponding to the file identifier is searched based on a predefined path.

[0115] Optionally, in another possible implementation manner, the dynamic library file loading device provided by the embodiment of the present invention may further include a replacement module;

[0116] The replacement module is used to replace the original class loader with a preset class loader after the installation module 410 performs an installation operation on the target APP based on the target installation package carried by the installation instruction and obtains a startup instruction for the target APP.

[0117] Optionally, in another possible implementation manner, the replacement module is specifically used to:

[0118] In the entry function of the target APP, replace the original class loader with the preset class loader.

[0119] The dynamic library file loading device provided in the embodiment of the present invention belongs to the same inventive concept as the dynamic library file loading method provided in the aforementioned embodiments. For details not fully described in the embodiment of the dynamic library file loading device, reference can be made to the relevant contents of the aforementioned method embodiments, and the corresponding beneficial effects can also be referred to the beneficial effect analysis of the aforementioned method embodiments.

[0120] Figure 5 A schematic diagram of the structure of a dynamic library file loading device provided by an embodiment of the present invention. Figure 5 A block diagram of an exemplary dynamic library file loading device 12 suitable for implementing the embodiment of the present invention is shown. Figure 5 The dynamic library file loading device 12 shown is only an example and should not bring any limitation to the functions and scope of use of the embodiment of the present invention.

[0121] like Figure 5 As shown, the dynamic library file loading device 12 is in the form of a general computing device. The components of the dynamic library file loading device 12 may include, but are not limited to: one or more processors or processing units 16, a system memory 28, and a bus 18 connecting different system components (including the system memory 28 and the processing unit 16).

[0122] Bus 18 represents one or more of several types of bus structures, including a memory bus or memory controller, a peripheral bus, an accelerated graphics port, a processor or a local bus using any of a variety of bus architectures. By way of example, these architectures include, but are not limited to, an Industry Standard Architecture (ISA) bus, a Micro Channel Architecture (MAC) bus, an Enhanced ISA bus, a Video Electronics Standards Association (VESA) local bus, and a Peripheral Component Interconnect (PCI) bus.

[0123] The dynamic library file loading device 12 typically includes a variety of computer system readable media. These media can be any available media that can be accessed by the dynamic library file loading device 12, including volatile and non-volatile media, removable and non-removable media.

[0124] System memory 28 may include computer system readable media in the form of volatile memory, such as random access memory (RAM) 30 and / or cache memory (i.e., Figure 5 The dynamic library file loading device 12 may further include other removable / non-removable, volatile / non-volatile computer system storage media. By way of example only, the storage system 34 may be used to read and write non-removable, non-volatile magnetic media ( Figure 5 not shown, usually called a "hard drive"). Although Figure 5 Not shown in the figure, a disk drive for reading and writing to a removable non-volatile disk (e.g., a "floppy disk"), and an optical disk drive for reading and writing to a removable non-volatile optical disk (e.g., a CD-ROM, a DVD-ROM, or other optical media) may be provided. In these cases, each drive may be connected to the bus 18 via one or more data medium interfaces. The system memory 28 may include at least one program product having a set (e.g., at least one) of program modules that are configured to perform the functions of the various embodiments of the present invention.

[0125] A program / utility 40 having a set (at least one) of program modules 42 may be stored, for example, in system memory 28, such program modules 42 including, but not limited to, an operating system, one or more application programs, other program modules, and program data, each of which or some combination may include an implementation of a network environment. Program modules 42 generally perform the functions and / or methods of the embodiments described herein.

[0126] The dynamic library file loading device 12 may also communicate with one or more external devices 14 (e.g., keyboard, pointing device, display 24, etc.), may also communicate with one or more devices that enable a user to interact with the dynamic library file loading device 12, and / or communicate with any device that enables the dynamic library file loading device 12 to communicate with one or more other computing devices (e.g., network card, modem, etc.). Such communication may be performed through an input / output (I / O) interface 22. Furthermore, the dynamic library file loading device 12 may also communicate with one or more networks (e.g., local area network (LAN), wide area network (WAN) and / or public network, such as the Internet) through a network adapter 20. Figure 5 As shown, the network adapter 20 communicates with other modules of the dynamic library file loading device 12 via the bus 18. It should be understood that although Figure 5 Not shown, other hardware and / or software modules may be used in conjunction with the dynamic library file loading device 12, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage systems.

[0127] The processing unit 16 executes various functional applications and data processing by running the program stored in the system memory 28, such as implementing the steps of the dynamic library file loading method provided in an embodiment of the present invention, the method comprising: responding to the installation instruction for the target APP, installing the target APP based on the target installation package carried by the installation instruction; wherein the target installation package is an installation package obtained by deleting each candidate dynamic library file in the original installation package of the target APP; when a dynamic library file loading request is obtained, the target dynamic library file corresponding to the file identifier carried by the dynamic library file loading request is searched based on the predefined path by executing the redirection path search method of the preset class loader, and the found target dynamic library file is loaded.

[0128] Of course, those skilled in the art can understand that the processor can also implement the technical solution of the dynamic library file loading method provided by any embodiment of the present invention.

[0129] The present embodiment provides a computer-readable storage medium having a computer program stored thereon. When the program is executed by a processor, the program implements the steps of a method for loading a dynamic library file as provided in the aforementioned embodiment of the present invention, the method comprising: in response to an installation instruction for a target APP, performing an installation operation on the target APP based on a target installation package carried by the installation instruction; wherein the target installation package is an installation package obtained by deleting each candidate dynamic library file in an original installation package of the target APP; when a dynamic library file loading request is obtained, searching for a target dynamic library file corresponding to a file identifier carried in the dynamic library file loading request based on a predefined path by executing a redirection path search method of a preset class loader, and loading the found target dynamic library file.

[0130] The computer storage medium of the embodiment of the present invention can adopt any combination of one or more computer-readable media. The computer-readable medium can be a computer-readable signal medium or a computer-readable storage medium. The computer-readable storage medium can be, for example, but not limited to: an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples (non-exhaustive list) of computer-readable storage media include: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In this document, a computer-readable storage medium can be any tangible medium containing or storing a program, which can be used by an instruction execution system, device or device or used in combination with it.

[0131] Computer-readable signal media may include data signals propagated in baseband or as part of a carrier wave, which carry computer-readable program code. Such propagated data signals may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. Computer-readable signal media may also be any computer-readable medium other than a computer-readable storage medium, which may send, propagate, or transmit a program for use by or in conjunction with an instruction execution system, apparatus, or device.

[0132] The program code embodied on the computer readable medium may be transmitted using any appropriate medium, including but not limited to wireless, wireline, optical fiber cable, RF, etc., or any suitable combination of the foregoing.

[0133] Computer program code for performing the operation of the present invention may be written in one or more programming languages ​​or a combination thereof, including object-oriented programming languages ​​such as Java, Smalltalk, C++, and conventional procedural programming languages ​​such as "C" or similar programming languages. The program code may be executed entirely on the user's computer, partially on the user's computer, as a separate software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or a loading device for a dynamic library file. In the case of a remote computer, the remote computer may be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., using an Internet service provider to connect through the Internet).

[0134] It should be understood by those skilled in the art that the modules or steps of the present invention described above can be implemented by a general-purpose computing device, they can be concentrated on a single computing device, or distributed on a network composed of multiple computing devices, optionally, they can be implemented by a program code executable by a computer device, so that they can be stored in a storage device and executed by the computing device, or they can be made into individual integrated circuit modules, or multiple modules or steps therein can be made into a single integrated circuit module for implementation. Thus, the present invention is not limited to any specific combination of hardware and software.

[0135] Note that the above are only preferred embodiments of the present invention and the technical principles used. Those skilled in the art will understand that the present invention is not limited to the specific embodiments described herein, and that various obvious changes, readjustments and substitutions can be made by those skilled in the art without departing from the scope of protection of the present invention. Therefore, although the present invention has been described in more detail through the above embodiments, the present invention is not limited to the above embodiments, and may include more other equivalent embodiments without departing from the concept of the present invention, and the scope of the present invention is determined by the scope of the appended claims.

Claims

1. A method for loading a dynamic library file, characterized in that: The method comprises: In response to an installation instruction for a target application APP, an installation operation is performed on the target APP based on a target installation package carried by the installation instruction; wherein the target installation package is an installation package obtained by deleting each candidate dynamic library file in an original installation package of the target APP; When a dynamic library file loading request is obtained, the redirection path search method of the preset class loader is executed to search for the target dynamic library file corresponding to the file identifier carried by the dynamic library file loading request based on the predefined path, and the found target dynamic library file is loaded.

2. The method for loading a dynamic library file according to claim 1, characterized in that: The searching for a target dynamic library file corresponding to the file identifier carried by the dynamic library file loading request based on a predefined path includes: Based on the dynamic library file download address, the target dynamic library file corresponding to the file identifier is obtained, and the obtained target dynamic library file is downloaded to a predefined directory in the predefined path; wherein the dynamic library file download address is the storage address of each candidate dynamic library file after being deleted from the original installation package; The target dynamic library file corresponding to the file identifier is searched from the predefined directory.

3. The method for loading a dynamic library file according to claim 2, characterized in that: The target installation package is obtained in advance by the compilation server of the target APP in the following manner: the candidate dynamic library files in the original installation package are deleted by a compilation plug-in, and the original installation package after the deletion is determined as the target installation package.

4. The method for loading a dynamic library file according to claim 2, wherein: Before acquiring the target dynamic library file corresponding to the file identifier based on the dynamic library file download address, the method further includes: Query the download address of the dynamic library file through a preset access interface; Alternatively, the download address of the dynamic library file parsed from the target installation package is obtained.

5. The method for loading a dynamic library file according to claim 2, characterized in that: The step of loading the found target dynamic library file comprises: Verify the found target dynamic library file to obtain a verification result; When it is determined that the verification result is passed, the found target dynamic library file is loaded.

6. The method for loading a dynamic library file according to claim 5, wherein after verifying the found target dynamic library file and obtaining the verification result, the method further comprises: If it is determined that the verification result is a verification failure, deleting the target dynamic library file in the predefined directory; Based on the dynamic library file download address, reacquire the target dynamic library file corresponding to the file identifier, and download the reacquired target dynamic library file to the predefined directory; The target dynamic library file corresponding to the file identifier is searched again from the predefined directory, and the searched target dynamic library file is loaded.

7. The method for loading a dynamic library file according to claim 5, characterized in that: The step of verifying the found target dynamic library file to obtain a verification result includes: Determine a first encryption parameter of the target dynamic library file found; Comparing the first encryption parameter with the second encryption parameter; wherein the second encryption parameter is an encryption parameter for the target dynamic library file determined in the process of storing the candidate dynamic library files in the dynamic library file download address; When it is determined that the first encryption parameter is consistent with the second encryption parameter, the verification result is determined to be a passed verification; when it is determined that the first encryption parameter is inconsistent with the second encryption parameter, the verification result is determined to be a failed verification.

8. The method for loading a dynamic library file according to claim 1, characterized in that: The searching for a target dynamic library file corresponding to the file identifier carried by the dynamic library file loading request based on a predefined path includes: Searching the target dynamic library file corresponding to the file identifier in the system installation directory of the target installation package; When it is determined that the target dynamic library file corresponding to the file identifier is not found in the system installation directory, the target dynamic library file corresponding to the file identifier is searched based on the predefined path.

9. The method for loading a dynamic library file according to any one of claims 1 to 8, characterized in that: After performing the installation operation on the target APP based on the target installation package carried by the installation instruction, the method further includes: When the startup instruction for the target APP is obtained, the original class loader is replaced with the preset class loader.

10. The method for loading a dynamic library file according to claim 9, characterized in that: The replacing the original class loader with the preset class loader includes: In the entry function of the target APP, the original class loader is replaced with the preset class loader.

11. A dynamic library file loading device, characterized in that: include: An installation module, configured to respond to an installation instruction for a target application APP and perform an installation operation on the target APP based on a target installation package carried by the installation instruction; wherein the target installation package is an installation package obtained by deleting each candidate dynamic library file in an original installation package of the target APP; The loading module is used to, when a dynamic library file loading request is obtained, search for a target dynamic library file corresponding to the file identifier carried in the dynamic library file loading request based on a predefined path by executing a redirection path search method of a preset class loader, and load the found target dynamic library file.

12. A dynamic library file loading device, characterized in that: The loading device of the dynamic library file includes: one or more processors; A memory for storing one or more programs; When the one or more programs are executed by the one or more processors, the one or more processors implement the dynamic library file loading method as described in any one of claims 1-10.

13. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the method for loading a dynamic library file as described in any one of claims 1 to 10 is implemented.