Patch installation method and device based on plug-in implementation, medium and program product
By registering the detection plug-in in the installer, the problem of inability to detect installation environment matching in the prior art is solved, and the effect of reducing the on-site patch installation error rate and improving deployment efficiency is achieved.
Patent Information
- Application Number
- CN202411605741.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-12
- Publication Date
- 2025-02-28
AI Technical Summary
The prior art cannot detect whether the installation environment matches before installing patches, resulting in high on-site installation error rates and low deployment efficiency.
By registering the detection plug-in in the installer, and using the plug-in to verify whether the patch-dependent tools, plug-ins, and installer versions match the current installation environment before installation. If they do not match, the installation will be terminated and a prompt is given.
It effectively reduces the error rate of on-site patch installation, improves installation and deployment efficiency, and ensures the matching of the installation environment and data integrity.
Smart Images

Figure CN119536781A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of patch installation, and in particular to a patch installation method, device, medium and program product based on plug-in implementation. Background Art
[0002] The installer is released throughout the entire release process. The upgrade patch needs to be verified by the platform and field tests before it can be upgraded and installed on site. During the upgrade installation, the site uses the stable version of the installer, and some sites will not upgrade to the latest version, but will continue to use a certain version.
[0003] When problems or requirements arise during on-site use, the corresponding QP / SP patch needs to be used to solve the problem. When the QP / SP patch is tested in the test environment, the installer, plug-in, and tool upgrades may be performed in the test environment, resulting in inconsistencies between the test environment and the on-site installation environment. This may cause the QP / SP patch to be installed properly in the test environment but have problems during on-site installation.
[0004] At the same time, the installation version number needs to be strictly controlled. Take the R2_2302 Gold Disk released by a certain group as an example. After the R2_2302 Gold Disk is released, the R2_2302 version needs to be used before the next version number comes out, and the exclusive new developed functions also need to be released for testing. In order to distinguish the R2_2302 Gold Disk version, the R2_2302-2 version of the product disk appeared. The QP / SP patches normally given to the site are based on the R2_2302 Gold Disk. If the QP / SP patch package based on R2_2302-2 is given to the site and installed successfully, some new R&D functions will be brought to the site, resulting in the leakage of undisclosed R&D functions.
[0005] The existing technology solves the problem that the installation site of the QP / SP patch is inconsistent with the group test environment. The solution is that the QP / SP patch comes with several frequently updated tool packages (such as data import tools, translators, etc.) and when problems occur, contact the installer-related personnel to handle them. These methods have the following disadvantages: In addition to the packages required for their own services, the QP / SP patch also needs to carry an additional 300M or 400M tool package, which makes the overall package larger and reduces the efficiency of package transmission. In some on-site network disconnection environments, the package transmission time is longer; contacting the installer-related personnel to handle it will cause the overall installation time to be extended, and the installation data needs to be repaired to ensure subsequent installation, and garbage data will also be generated on the business side.
[0006] Therefore, it is urgent to invent a patch installation method based on plug-in implementation to solve the problems that the prior art cannot detect whether the installation environment matches before installing the patch, the on-site installation error rate is high, and the on-site deployment efficiency is low. Summary of the invention
[0007] In view of this, the embodiments of the present invention provide a patch installation method, device, medium and program product based on plug-in implementation, which at least partially solve the problems existing in the prior art.
[0008] Other features and advantages of the present invention will become apparent from the following detailed description, or may be learned in part by practice of the present invention.
[0009] In order to achieve the above purpose, the embodiment of the present invention provides the following technical solutions:
[0010] According to a first aspect of an embodiment of the present invention, a plug-in-based patch installation method is provided, the method comprising:
[0011] Registering the detection plug-in to the installer and declaring the detection plug-in as a global plug-in;
[0012] Register the patch to be installed to the installer and decompress it;
[0013] Arrange a corresponding detection task for the patch to be installed according to the running status of the detection plug-in;
[0014] After the detection task corresponding to the patch to be installed is triggered, the rule file of the patch to be installed is read by using the detection plug-in, and the rule file is parsed to obtain the rule parsing result;
[0015] According to the rule parsing result, trigger the corresponding rule service;
[0016] Using the detection plug-in to read the installation environment data in the installer;
[0017] Performing installation verification processing using the rule service and the installation environment data to obtain an installation verification result;
[0018] According to the verification result, it is determined whether to continue installing the patch to be installed.
[0019] Furthermore, according to the running status of the detection plug-in, a corresponding detection task is arranged for the patch to be installed, including:
[0020] Determine whether the running state of the detection plug-in is in the enabled state;
[0021] If the detection plug-in is in the enabled state, a corresponding detection task is arranged for the patch to be installed;
[0022] If the detection plug-in is in a closed state, the patch to be installed is directly installed.
[0023] Furthermore, the installation verification process includes installer version verification, dependent plug-in verification, preset product verification and / or preset service verification.
[0024] Furthermore, the installer version verification includes:
[0025] According to the installer version serial number in the installation environment data, determining whether the current installer version is a version allowed to be installed by the rule service;
[0026] If the current installer version is the version allowed to be installed by the rule service, the installer version verification passes;
[0027] If the current installer version is a version that the rule service does not allow installation, the installer version verification fails.
[0028] Furthermore, the dependency plug-in verification includes:
[0029] Determine, based on the installation environment data, whether there is a dependent plug-in required to install the patch to be installed in the current installation environment;
[0030] If the installation environment contains dependent plug-ins required for installing the patch to be installed, the dependent plug-in verification passes;
[0031] If the dependent plug-in required to install the patch to be installed does not exist in the installation environment, the dependent plug-in verification fails.
[0032] Furthermore, the preset product verification includes:
[0033] According to the installation environment data, determining whether the product corresponding to the patch to be installed is a special product that is prohibited from installation;
[0034] If the product corresponding to the patch to be installed is a special product that is prohibited from installation, the preset product verification fails and the installation of the product is prohibited;
[0035] If the product corresponding to the patch to be installed is not a special product that is prohibited from installation, the preset product verification passes;
[0036] The preset service verification includes:
[0037] According to the installation environment data, determining whether each service under the product corresponding to the patch to be installed is a special service that is prohibited from installation;
[0038] If the service under the product corresponding to the patch to be installed is a special service that is prohibited from installation, the preset service verification fails and the installation of the service is prohibited;
[0039] If the service under the product corresponding to the patch to be installed is not a special service prohibited from installation, the preset service verification passes.
[0040] Further, judging whether to continue installing the patch to be installed according to the verification result includes:
[0041] Determine whether the verification result is passed;
[0042] If the verification result is passed, continue to install the patch to be installed;
[0043] If the verification result is not passed, the installation of the patch to be installed is prohibited, and a prohibition prompt is given.
[0044] According to a second aspect of an embodiment of the present invention, there is provided a patch installation device based on plug-in implementation, the device comprising: a processor and a memory;
[0045] The memory is used to store one or more program instructions;
[0046] The processor is used to run one or more program instructions to execute the steps of a plug-in-based patch installation method as described in any one of the above items.
[0047] According to a third aspect of an embodiment of the present invention, a computer-readable storage medium is provided, characterized in that a computer program is stored on the computer-readable storage medium, and when the computer program is executed by a processor, the steps of a plug-in-based patch installation method as described in any one of the above items are implemented.
[0048] According to a fourth aspect of an embodiment of the present invention, a computer program product is provided, the computer program product comprising a computer program stored on a non-transitory computer-readable storage medium, the computer program comprising program instructions, which, when executed by a computer, enable the computer to implement the steps of a plug-in-based patch installation method as described in any one of the above items.
[0049] The embodiments of the present invention have the following advantages:
[0050] The detection plug-in registered to the installer provided by the embodiment of the present invention is pluggable and can be applied to all field versions; the detection plug-in verifies whether the tool, plug-in and installer version that the patch depends on match the current installation environment before installation, and if not, terminates in time and gives a prompt message to ensure that the database, function code and installer environment data will not generate dirty data, and the installation site can intuitively know the problem; in addition, the detection plug-in of the present invention is extensible, and the user can add the required detection logic based on the standard template to ensure that the QP / SP patch is installed in the field environment within the user's expected range. In summary, the embodiment of the present invention effectively reduces the error rate of field patch installation and effectively improves the efficiency of field installation and deployment. BRIEF DESCRIPTION OF THE DRAWINGS
[0051] In order to more clearly illustrate the implementation methods of the present invention or the technical solutions in the prior art, the following briefly introduces the drawings required for the implementation methods or the description of the prior art. Obviously, the drawings in the following description are only exemplary, and for ordinary technicians in this field, other implementation drawings can be derived from the provided drawings without creative work.
[0052] Figure 1 A schematic diagram of a flow chart of a patch installation method based on a plug-in implementation provided by an embodiment of the present invention;
[0053] Figure 2 A schematic block diagram of the principle of a patch installation method based on a plug-in implementation provided by an embodiment of the present invention;
[0054] Figure 3 A schematic block diagram of the principles of installation verification processing of a patch installation method based on plug-in implementation provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0055] In order to enable those skilled in the art to better understand the scheme of the present invention, the technical scheme in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present invention.
[0056] In addition, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover non-exclusive inclusions. For example, a process, method, system, product, or apparatus that includes a series of steps or elements is not necessarily limited to those steps or elements explicitly listed, but may include other steps or elements not explicitly listed or inherent to such process, method, product, or apparatus.
[0057] Figure 1 The figure shows a flow chart of a patch installation method based on a plug-in according to an embodiment of the present invention.
[0058] like Figure 1 As shown, the patch installation method based on plug-in implementation according to an embodiment of the present invention may include step S100, step S200, step S300, step S400, step S500, step S600 and step S700.
[0059] refer to Figure 2 In step S100, the detection plug-in is registered to the installer, and the detection plug-in is declared as a global patch plug-in, and the above plug-in can be turned off and on freely.
[0060] Next, in step S200, the patch to be installed is registered to the installer and decompressed.
[0061] In step S300, a corresponding detection task is arranged for the patch to be installed according to the running status of the detection plug-in.
[0062] Specifically, the above steps include:
[0063] After the patch to be installed is decompressed, select Install the patch to be installed on the installer page to determine whether the current detection plug-in is running in the enabled state;
[0064] If the current detection plug-in is enabled, the corresponding detection task is arranged for the patch to be installed;
[0065] If the current detection plug-in is disabled, the patch to be installed is installed directly without arranging a detection task.
[0066] If the security environment does not require detection, you can directly turn off the detection plug-in globally. By freely choosing to turn the detection plug-in on and off, you can easily and simply implement patch installation detection.
[0067] Next, in step S400, after the detection task corresponding to the patch to be installed is triggered, the detection plug-in is used to read the rule file of the patch to be installed, and the rule file is parsed to obtain the rule parsing result, and the corresponding rule service is triggered according to the rule parsing result.
[0068] Specifically, the above steps include:
[0069] After the detection task corresponding to the patch to be installed is triggered, the detection plug-in applies to read the rule file of the patch to be installed;
[0070] After reading the rule file of the patch to be installed, the rule file is parsed to obtain the rule parsing result;
[0071] According to different rule parsing results, different rule services are triggered.
[0072] In step S500, the leveldb installation environment data in the installer is read using the detection plug-in.
[0073] Then, in step S600, the above rule service and the above installation environment data are used to perform installation verification processing to obtain an installation verification result.
[0074] Specifically, the above steps include:
[0075] refer to Figure 3, using the above-mentioned rule service and the above-mentioned installation environment data to perform installation verification processing, wherein the above-mentioned installation verification processing includes installer version verification, dependency plug-in verification, preset product verification and / or preset service verification.
[0076] The above installer version verification includes:
[0077] According to the installer version serial number in the installation environment data, determine whether the current installer version is the version allowed to be installed in the rule service;
[0078] If the current installer version is the version allowed to be installed by the rule service, the installer version verification passes;
[0079] If the current installer version is a version that the rule service does not allow installation, the installer version verification fails.
[0080] The above dependency plugin verification includes:
[0081] Based on the installation environment data and rule services, determine whether there are dependent plug-ins required to install the patch to be installed in the current installation environment;
[0082] If the installation environment contains dependent plug-ins required for installing the patch to be installed, the dependent plug-in verification passes;
[0083] If the dependent plug-in required to install the patch to be installed does not exist in the installation environment, the dependent plug-in verification fails.
[0084] The above preset product verification includes:
[0085] According to the installation environment data and rule service, determine whether the product corresponding to the patch to be installed is a special product that is prohibited from being installed in the installation environment;
[0086] If the product corresponding to the patch to be installed is a special product that is prohibited from installation, the preset product verification fails and the installation of the product is prohibited;
[0087] If the product corresponding to the patch to be installed is not a special product that is prohibited from installation, the preset product verification passes.
[0088] The above preset service verification includes:
[0089] According to the installation environment data and rule services, determine whether the services under the product corresponding to the patch to be installed are special services that are prohibited from being installed in the installation environment;
[0090] If the service under the product corresponding to the patch to be installed is a special service that is prohibited from installation, the preset service verification fails and the installation of the service is prohibited;
[0091] If the service under the product corresponding to the patch to be installed is not a special service prohibited from installation, the preset service verification passes.
[0092] The embodiment of the present invention is based on the global detection plug-in of the installer, dynamically loads the rule file through the rule file of the patch to be installed, performs various installation checks, and continues to execute if it passes, otherwise intercepts and reports an error.
[0093] Finally, in step S700, it is determined whether to continue installing the patch to be installed based on the verification result.
[0094] Specifically, the above steps include:
[0095] Determine whether the verification result is passed;
[0096] If the verification result is passed, continue to install the patch to be installed;
[0097] If the verification result is not passed, the subsequent installation task steps such as SQL and deployment services of the patch to be installed are prohibited, and a prohibition prompt is given.
[0098] In addition, an embodiment of the present invention further provides a device, which includes: a processor and a memory; the memory is used to store one or more program instructions; the processor is used to run one or more program instructions to execute the steps of a patch installation method based on plug-in implementation as described above.
[0099] In addition, an embodiment of the present invention further provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the steps of the above-mentioned patch installation method based on plug-in are implemented.
[0100] In addition, an embodiment of the present invention further provides a computer program product, which includes computer program instructions. When the computer program instructions are executed by a processor, the steps of the above-mentioned patch installation method based on plug-in are implemented.
[0101] The detection plug-in registered to the installer provided by the embodiment of the present invention is pluggable and can be applied to all field versions; the detection plug-in verifies whether the tool, plug-in and installer version that the patch depends on match the current installation environment before installation, and if not, terminates in time and gives a prompt message to ensure that the database, function code and installer environment data will not generate dirty data, and the installation site can intuitively know the problem; in addition, the detection plug-in of the present invention is extensible, and the user can add the required detection logic based on the standard template to ensure that the QP / SP patch is installed in the field environment within the user's expected range. In summary, the embodiment of the present invention effectively reduces the error rate of field patch installation and effectively improves the efficiency of field installation and deployment.
[0102] In the embodiment of the present invention, the processor may be an integrated circuit chip with signal processing capability. The processor may be a general-purpose processor, a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field programmable gate array (FPGA), or other programmable logic devices, discrete gates or transistor logic devices, or discrete hardware components. The methods, steps, and logic block diagrams disclosed in the embodiments of the present invention may be implemented or executed. The general-purpose processor may be a microprocessor or the processor may be any conventional processor, etc. The steps of the method disclosed in the embodiment of the present invention may be directly embodied as being executed by a hardware decoding processor, or may be executed by a combination of hardware and software modules in a decoding processor. The software module may be located in a mature storage medium in the art such as a random access memory, a flash memory, a read-only memory, a programmable read-only memory, or an electrically erasable programmable memory, a register, etc. The processor reads the information in the storage medium and completes the steps of the above method in combination with its hardware. The storage medium may be a memory, for example, a volatile memory or a non-volatile memory, or may include both volatile and non-volatile memories. Among them, the non-volatile memory can be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory. The volatile memory can be a random access memory (RAM), which is used as an external cache. By way of example but not limitation, many forms of RAM are available, such as static random access memory (SRAM), dynamic random access memory (DRAM), synchronous dynamic random access memory (SDRAM), double data rate synchronous dynamic random access memory (DDRSDRAM), enhanced synchronous dynamic random access memory (ESDRAM), synchronous link dynamic random access memory (SLDRAM) and direct memory bus random access memory (Direct Rambus RAM, DRRAM).The storage medium described in the embodiment of the present invention is intended to include but is not limited to these and any other suitable types of memory. Those skilled in the art should be aware that in one or more of the above examples, the functions described in the present invention can be implemented by a combination of hardware and software. When the software is applied, the corresponding function can be stored in a computer-readable medium or transmitted as one or more instructions or codes on a computer-readable medium. Computer-readable media include computer storage media and communication media, wherein the communication medium includes any medium that is convenient for transmitting a computer program from one place to another. The storage medium can be any available medium that a general or special-purpose computer can access. Although the present invention has been described in detail above with general descriptions and specific embodiments, it is obvious to those skilled in the art that some modifications or improvements can be made to it on the basis of the present invention. Therefore, these modifications or improvements made on the basis of not departing from the spirit of the present invention all belong to the scope of protection claimed in the present invention.
Claims
1. A patch installation method based on plug-in, characterized in that: The method comprises: Registering the detection plug-in to the installer and declaring the detection plug-in as a global plug-in; Register the patch to be installed to the installer and decompress it; Arrange a corresponding detection task for the patch to be installed according to the running status of the detection plug-in; After the detection task corresponding to the patch to be installed is triggered, the rule file of the patch to be installed is read by using the detection plug-in, and the rule file is parsed to obtain the rule parsing result; According to the rule parsing result, trigger the corresponding rule service; Using the detection plug-in to read the installation environment data in the installer; Performing installation verification processing using the rule service and the installation environment data to obtain an installation verification result; According to the verification result, it is determined whether to continue installing the patch to be installed.
2. A plug-in-based patch installation method as claimed in claim 1, characterized in that: Arranging a corresponding detection task for the patch to be installed according to the running status of the detection plug-in, including: Determine whether the running state of the detection plug-in is in the enabled state; If the detection plug-in is in the enabled state, a corresponding detection task is arranged for the patch to be installed; If the detection plug-in is in a closed state, the patch to be installed is directly installed.
3. A plug-in-based patch installation method as claimed in claim 1, characterized in that: The installation verification process includes installer version verification, dependent plug-in verification, preset product verification and / or preset service verification.
4. A plug-in-based patch installation method as claimed in claim 3, characterized in that: The installer version verification includes: According to the installer version serial number in the installation environment data, determining whether the current installer version is a version allowed to be installed by the rule service; If the current installer version is the version allowed to be installed by the rule service, the installer version verification passes; If the current installer version is a version that the rule service does not allow installation, the installer version verification fails.
5. A plug-in-based patch installation method as claimed in claim 3, characterized in that: The dependency plug-in verification includes: Determine, based on the installation environment data, whether there is a dependent plug-in required to install the patch to be installed in the current installation environment; If the installation environment contains dependent plug-ins required for installing the patch to be installed, the dependent plug-in verification passes; If the dependent plug-in required to install the patch to be installed does not exist in the installation environment, the dependent plug-in verification fails.
6. A plug-in-based patch installation method as claimed in claim 3, characterized in that: The preset product verification includes: According to the installation environment data, determining whether the product corresponding to the patch to be installed is a special product that is prohibited from installation; If the product corresponding to the patch to be installed is a special product that is prohibited from installation, the preset product verification fails and the installation of the product is prohibited; If the product corresponding to the patch to be installed is not a special product that is prohibited from installation, the preset product verification passes; The preset service verification includes: According to the installation environment data, determining whether each service under the product corresponding to the patch to be installed is a special service that is prohibited from installation; If the service under the product corresponding to the patch to be installed is a special service that is prohibited from installation, the preset service verification fails and the installation of the service is prohibited; If the service under the product corresponding to the patch to be installed is not a special service prohibited from installation, the preset service verification passes.
7. A plug-in-based patch installation method as claimed in claim 1, characterized in that: Determining whether to continue installing the patch to be installed according to the verification result includes: Determine whether the verification result is passed; If the verification result is passed, continue to install the patch to be installed; If the verification result is not passed, the installation of the patch to be installed is prohibited, and a prohibition prompt is given.
8. A patch installation device based on plug-in, characterized in that: The device comprises: a processor and a memory; The memory is used to store one or more program instructions; The processor is used to run one or more program instructions to execute the steps of a plug-in-based patch installation method as described in any one of claims 1 to 7.
9. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the plug-in-based patch installation method according to any one of claims 1 to 7 are implemented.
10. A computer program product, characterized in that The computer program product includes computer program instructions, which, when executed by a processor, implement the steps of a plug-in-based patch installation method as claimed in any one of claims 1 to 7.