CN109960522B - Software upgrading method and device - Google Patents

Software upgrading method and device Download PDF

Info

Publication number
CN109960522B
CN109960522B CN201910256758.4A CN201910256758A CN109960522B CN 109960522 B CN109960522 B CN 109960522B CN 201910256758 A CN201910256758 A CN 201910256758A CN 109960522 B CN109960522 B CN 109960522B
Authority
CN
China
Prior art keywords
layer
upgrading
file
software
interface
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201910256758.4A
Other languages
Chinese (zh)
Other versions
CN109960522A (en
Inventor
刘幸奇
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhuhai Baohaowan Technology Co Ltd
Original Assignee
Zhuhai Baohaowan Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Zhuhai Baohaowan Technology Co Ltd filed Critical Zhuhai Baohaowan Technology Co Ltd
Priority to CN201910256758.4A priority Critical patent/CN109960522B/en
Publication of CN109960522A publication Critical patent/CN109960522A/en
Application granted granted Critical
Publication of CN109960522B publication Critical patent/CN109960522B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/65Updates

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Stored Programmes (AREA)

Abstract

The embodiment of the application discloses a software upgrading method and a device, wherein the method comprises the following steps: acquiring a software upgrading package corresponding to a software program, wherein the software upgrading package comprises upgrading files corresponding to one or more layers of a User Interface (UI) layer, a logic layer, a data layer and a basic function engine layer of the software program, the presentation forms of the upgrading files of the UI layer and the basic function engine layer are plug-in forms, and the formats of the upgrading files of the logic layer and the data layer are script formats; and upgrading one or more layers corresponding to the software program according to the software upgrading package. By adopting the embodiment of the application, the software can be updated in the software running process without restarting the software, and the software updating efficiency is improved.

Description

Software upgrading method and device
Technical Field
The invention relates to the field of computer application, in particular to a software upgrading method and device.
Background
With the update of software and hardware technologies, many types of notebook computers in the market are equipped with a window10 operating system and an SSD solid state disk. The SSD hard disk can enable the starting speed of a user to become faster; the window10 system provides a mechanism for speeding up the system recovery such as lid-closing sleep, fast start, etc. One result of these mechanisms is that the user's notebook will not actually be powered down and restarted. However, when version numbers of many client software are updated, a program needs to be restarted or a system needs to be restarted to complete an update process, if the system is not restarted, the software may not be updated, and new functions cannot reach the client in time. Therefore, how to complete the upgrade update of the software without restarting the software is a problem that those skilled in the art have been addressing.
Disclosure of Invention
The embodiment of the application provides a software upgrading method and device, aiming at finishing software upgrading without restarting software and improving the efficiency of software upgrading and updating.
In a first aspect, an embodiment of the present application provides a software upgrading method, where the method includes:
acquiring a software upgrading package corresponding to a software program, wherein the software upgrading package comprises upgrading files corresponding to one or more layers of a User Interface (UI) layer, a logic layer, a data layer and a basic function engine layer of the software program, the presentation forms of the upgrading files of the UI layer and the basic function engine layer are plug-in forms, and the formats of the upgrading files of the logic layer and the data layer are script formats;
and upgrading one or more layers corresponding to the software program according to the software upgrading package.
In the embodiment of the application, the UI interface layer and the basic function engine layer are written and realized by files in a plug-in form, the plug-in is a program file capable of independently realizing functions, and the realization of the functions does not depend on other files, so that a new plug-in file can be directly replaced by an original plug-in file in the upgrading process without influencing the operation of the whole software, namely the upgrading and updating of the software can be realized without closing the software; the logic layer and the data layer are script files, and can realize the updating of the software by updating the script files to be updated in the running process of the software without closing the software; in conclusion, the scheme can realize the upgrading and updating of the software in the software running process, and improves the efficiency of upgrading and updating the software.
With reference to the first aspect, in a first possible implementation manner of the first aspect, the upgrading one or more layers corresponding to the software program according to the software upgrade package includes:
if the software upgrading package comprises one or more upgrading files corresponding to the UI interface layer of the software program, respectively upgrading one or more functions of the UI interface layer according to the one or more upgrading files corresponding to the UI interface layer, wherein the one or more upgrading files corresponding to the UI interface layer are upgrading files corresponding to the one or more functions of the UI interface layer;
if the software upgrading package comprises an upgrading file in a script format corresponding to the logic layer of the software program, upgrading the logic layer according to the upgrading file in the script format corresponding to the logic layer;
if the software upgrading package comprises an upgrading file in a script format corresponding to the data layer of the software program, upgrading the data layer according to the upgrading file in the script format corresponding to the data layer;
if the software upgrading package comprises one or more upgrading files corresponding to a basic function engine layer of the software program, respectively and independently upgrading one or more functions of the basic function engine layer according to the one or more upgrading files corresponding to the basic function engine layer, wherein the one or more upgrading files corresponding to the basic function engine layer are upgrading files corresponding to the one or more functions of the basic function engine layer.
In the embodiment of the application, each of the user interface UI interface layer, the logic layer, the data layer and the basic function engine layer included in the software program can be upgraded independently without influencing the operation of other layers, and the software upgrading package can be upgraded as long as the upgrading file of the corresponding layer is included in the software upgrading package, so that the upgrading is completed in the software operation process, the software does not need to be closed, and the software upgrading and updating efficiency is improved.
With reference to the first possible implementation manner of the first aspect, in a second possible implementation manner of the first aspect, the one or more upgrade files corresponding to the UI interface layer include a first file, and the separately upgrading one or more functions of the UI interface layer according to the one or more upgrade files corresponding to the UI interface layer includes:
replacing a second file in a local software package corresponding to the software program with the first file, and modifying the name of the first file into the name of the second file, wherein the second file is a file in one or more files corresponding to the UI layer, and the first file is an upgrade file corresponding to the second file.
With reference to the first possible implementation manner of the first aspect, in a third possible implementation manner of the first aspect, the one or more upgrade files corresponding to the basic function engine layer include a third file, and the upgrading the one or more functions of the basic function engine layer separately according to the one or more upgrade files corresponding to the basic function engine layer includes:
replacing a fourth file in a local software package corresponding to the software program with the third file, and modifying the name of the third file into the name of the fourth file, where the fourth file is a file in one or more files corresponding to the basic function engine layer, and the third file is an upgrade file corresponding to the fourth file.
With reference to the first aspect, the first possible implementation manner of the first aspect, the second possible implementation manner of the first aspect, or the third possible implementation manner of the first aspect, in a fourth possible implementation manner of the first aspect, the updating the one or more layers corresponding to the software program according to the software upgrade package further includes:
determining the version number of the upgraded UI layer;
sending the version number after the UI interface layer is upgraded to an application server, wherein the version number after the UI interface layer is upgraded is used for requesting to acquire the data of the user interface UI layer corresponding to the version number after the UI interface layer is upgraded;
receiving the data of the UI layer corresponding to the version number after the UI interface layer is upgraded and sent by the application server;
and updating the UI interface of the software program according to the data of the UI layer corresponding to the version number after the UI interface layer is upgraded.
According to the embodiment of the application, the version number of the UI interface layer is associated with the data of the user interface layer, so that the upgrading and updating of the user interface layer are realized.
In a second aspect, an embodiment of the present application provides a software upgrading apparatus, including:
the software upgrading system comprises an acquisition unit and a processing unit, wherein the acquisition unit is used for acquiring a software upgrading package corresponding to a software program, the software upgrading package comprises upgrading files corresponding to one or more layers of a User Interface (UI) layer, a logic layer, a data layer and a basic function engine layer of the software program, the presentation forms of the upgrading files of the UI layer and the basic function engine layer are plug-in forms, and the formats of the upgrading files of the logic layer and the data layer are script formats;
and the upgrading unit is used for upgrading one or more layers corresponding to the software program according to the software upgrading package.
With reference to the second aspect, in a first possible implementation manner of the second aspect, the upgrading unit is configured to upgrade, according to the software upgrade package, one or more layers corresponding to the software program specifically:
if the software upgrading package comprises one or more upgrading files corresponding to the UI interface layer of the software program, the software upgrading package is used for respectively upgrading one or more functions of the UI interface layer according to the one or more upgrading files corresponding to the UI interface layer, and the one or more upgrading files corresponding to the UI interface layer are upgrading files corresponding to the one or more functions of the UI interface layer;
if the software upgrading package comprises an upgrading file in a script format corresponding to the logic layer of the software program, the software upgrading package is used for upgrading the logic layer according to the upgrading file in the script format corresponding to the logic layer;
if the software upgrading package comprises an upgrading file in a script format corresponding to the data layer of the software program, the software upgrading package is used for upgrading the data layer according to the upgrading file in the script format corresponding to the data layer;
if the software upgrading package comprises one or more upgrading files corresponding to a basic function engine layer of the software program, the software upgrading package is used for respectively and independently upgrading one or more functions of the basic function engine layer according to the one or more upgrading files corresponding to the basic function engine layer, and the one or more upgrading files corresponding to the basic function engine layer are upgrading files corresponding to the one or more functions of the basic function engine layer.
With reference to the first possible implementation manner of the second aspect, in a second possible implementation manner of the second aspect, the one or more upgrade files corresponding to the UI interface layer include a first file, the upgrade unit includes a first replacing unit and a first modifying unit,
the first replacing unit is used for replacing a second file in a local software package corresponding to the software program with the first file;
the first modification unit is configured to modify the name of the first file into the name of a second file, where the second file is a file in one or more files corresponding to the UI interface layer, and the first file is an upgrade file corresponding to the second file.
With reference to the first possible implementation manner of the second aspect, in a third possible implementation manner of the second aspect, the one or more upgrade files corresponding to the basic function engine layer include a third file, the upgrade unit further includes a second replacing unit and a second modifying unit,
the second replacing unit is configured to replace a fourth file in the local software package corresponding to the software program with the third file;
the second modification unit is configured to modify the name of the third file into the name of a fourth file, where the fourth file is a file in the one or more files corresponding to the basic function engine layer, and the third file is an upgrade file corresponding to the fourth file.
With reference to the second aspect, the first possible implementation manner of the second aspect, the second possible implementation manner of the second aspect, or the third possible implementation manner of the second aspect, in a fourth possible implementation manner of the second aspect, if the one or more layers at least include the UI interface layer, the apparatus further includes a determining unit, a sending unit, a receiving unit, and an updating unit,
the determining unit is configured to determine the version number of the UI interface layer after upgrading the one or more layers corresponding to the software program according to the software upgrade package;
the sending unit is used for sending the version number after the UI interface layer is upgraded to an application server, and the version number after the UI interface layer is upgraded is used for requesting to acquire the data of the user interface UI layer corresponding to the version number after the UI interface layer is upgraded;
the receiving unit is configured to receive the data of the UI layer corresponding to the version number after the UI interface layer is upgraded, where the data is sent by the application server;
and the updating unit is used for updating the UI interface of the software program according to the data of the UI layer corresponding to the version number after the UI interface layer is upgraded.
In a third aspect, an embodiment of the present application provides an electronic device, including a processor, a communication device, a memory, an input apparatus, and an output apparatus, where the processor, the communication device, the memory, the input apparatus, and the output apparatus are connected to each other, where the memory is used to store an application program code, and the processor is configured to call the application program code to perform the method according to any one of the first aspect.
In a fourth aspect, the present application provides a computer-readable storage medium storing a computer program, the computer program comprising program instructions that, when executed by a processor, cause the processor to perform the method of any of the first aspects.
In a fifth aspect, the present application provides a computer program comprising program instructions, which when executed by a processor, cause the processor to perform the method of any one of the above first aspects.
To sum up, in the embodiment of the present application, the UI interface layer and the basic function engine layer of the software program are binary files, but the binary files are written in a form of plug-in, and the software can be updated without closing the software, and the logic layer and the data layer are script files, so that the software can be updated by updating the script files to be updated during the running process of the software, and the software does not need to be closed, thereby improving the efficiency of updating the software.
Drawings
The drawings to be used in the embodiments of the present application will be described below.
FIG. 1 is a software programming framework provided by an embodiment of the present application;
fig. 2 is a schematic flowchart of a software upgrading method according to an embodiment of the present application;
fig. 3 is a schematic structural diagram of a software upgrading apparatus according to an embodiment of the present application;
fig. 4 is a schematic structural diagram of an electronic device according to an embodiment of the present application.
Detailed Description
In order to make those skilled in the art better understand the technical solutions of the present invention, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are only some embodiments of the present invention, and not all embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
The following are detailed below.
A software programming framework provided by the present application is described below. Referring to fig. 1, fig. 1 is a schematic diagram of a software programming framework according to an embodiment of the present disclosure. Software programming framework 100 may include a User Interface (UI) layer 101, a User Interface UI Interface layer 102, a logic layer 103, a data layer 104, and an underlying function engine layer 105. The UI layer 101 is implemented by using a hypertext Markup Language (HTML) technology, interaction between the UI layer 101 and client logic is completely performed through the UI interface layer 102, and the UI layer 101 is mainly used for displaying data and receiving data input from an interface; the UI interface layer 102 includes a plurality of World Wide Web (Web) interfaces, and provides interactive services with the UI layer in a Web interface manner; the logic layer 103 is responsible for implementing interface logic of the UI interface layer; the data layer 104 provides data support for the logic layer in the form of an interface, and can also obtain data of an operating system through the basic function engine layer 105; the engines in the base function engine layer 105 include a script engine that provides the base support for the scripting of the logic layer 103 and the data layer 104, and a web engine that provides the base support for the UI layer 101.
Based on the software programming framework 100 shown in fig. 1, a software upgrading method is provided below, and a flowchart is shown in fig. 2. The method may comprise the steps of:
step 201, obtaining a software upgrading package corresponding to a software program, where the software upgrading package includes upgrading files corresponding to one or more layers of a user interface UI interface layer, a logic layer, a data layer, and a basic function engine layer of the software program.
Specifically, the presentation forms of the upgrade files of the UI interface layer and the basic function engine layer are plug-in forms, and the formats of the upgrade files of the logic layer and the data layer are script formats. In a specific embodiment, the UI interface layer and the basic function engine layer of the software program are implemented by writing a program file in the form of a plug-in, specifically, the program file may be a binary file, that is, the UI interface layer and the basic function engine layer of the software program may be implemented by programming in the form of a binary file plug-in; the logic layer and the data layer of the software program are realized by programming and building script files, and the formats presented by the two layers are script formats. Generally, a software program can be installed on a client terminal, when the software program needs to be upgraded, the client terminal first obtains an upgrade installation package corresponding to the software program, and the upgrade installation package can include upgrade files of one or more layers of a UI interface layer, a logic layer, a data layer and a basic function engine layer of the software program; the upgrade files of the UI interface layer and the basic function engine layer may be files in a plug-in form, specifically, binary files written in a plug-in form, and the upgrade files of the logic layer and the data layer may be script files written in a script format.
Step 202, upgrading one or more layers corresponding to the software program according to the software upgrading package.
In a specific embodiment, after obtaining an upgrade installation package of a software program, a client terminal firstly analyzes files contained in the upgrade installation package, if the upgrade installation package only contains an upgrade file of one of a UI (user interface) layer, a logic layer, a data layer and a basic function engine layer, the layer is upgraded independently, and if the layer finishes upgrading, the whole software program is upgraded; if the software upgrading installation package comprises upgrading files of a plurality of layers in the UI layer, the logic layer, the data layer and the basic function engine layer, upgrading the plurality of layers respectively, and after the plurality of layers are upgraded, the whole software program is upgraded.
In the process of upgrading a software program, no matter which one of a UI interface layer, a logic layer, a data layer and a basic function engine layer is upgraded, if the software is running on a client terminal, the running software does not need to be closed, and the upgrading is directly completed in the process of running the software, because the UI interface layer and the basic function engine layer are written and realized by files in the form of plug-ins, the plug-ins are program files capable of independently realizing functions, and the realization of the functions does not depend on other files, so that the original plug-in files can be directly replaced by new plug-in files in the upgrading process without influencing the running of the whole software, namely the upgrading and updating of the software can be realized without closing the software; the logic layer and the data layer are script files, so that the software can be updated and updated by updating the script files to be updated in the software running process, and the software does not need to be closed; in conclusion, the scheme can realize the upgrading and updating of the software in the software running process, and improves the efficiency of upgrading and updating the software.
In one possible implementation manner, the upgrading one or more layers corresponding to the software program according to the software upgrade package includes:
if the software upgrading package comprises one or more upgrading files corresponding to the UI interface layer of the software program, respectively and independently upgrading one or more functions of the UI interface layer according to the one or more upgrading files corresponding to the UI interface layer, wherein the one or more upgrading files corresponding to the UI interface layer are upgrading files corresponding to the one or more functions of the UI interface layer;
if the software upgrading package comprises an upgrading file in a script format corresponding to the logic layer of the software program, upgrading the logic layer according to the upgrading file in the script format corresponding to the logic layer;
if the software upgrading package comprises an upgrading file in a script format corresponding to the data layer of the software program, upgrading the data layer according to the upgrading file in the script format corresponding to the data layer;
if the software upgrading package comprises one or more upgrading files corresponding to a basic function engine layer of the software program, respectively upgrading one or more functions of the basic function engine layer according to the one or more upgrading files corresponding to the basic function engine layer, wherein the one or more upgrading files corresponding to the basic function engine layer are upgrading files corresponding to the one or more functions of the basic function engine layer.
In a specific embodiment, if the software upgrade installation package includes one or more upgrade files of the UI interface layer of the software program, it means that the UI interface layer of the software program needs to be upgraded; specifically, since the upgrade file of the UI interface layer is a file in a plug-in form, that is, the upgrade file of each UI interface layer corresponds to one function of the UI interface layer, if the software upgrade installation package includes the upgrade file of one UI interface layer, the client terminal upgrades one function of the UI interface layer corresponding to the upgrade file according to the one upgrade file, and if the software upgrade installation package includes the upgrade files of a plurality of UI interface layers, the client terminal upgrades a plurality of functions of the UI interface layers corresponding to the plurality of upgrade files one by one according to the plurality of upgrade files.
If the software upgrading installation package comprises the upgrading file of the logic layer, the client terminal upgrades the logic layer according to the file of the logic layer, specifically, the client terminal firstly obtains the upgrading file of the logic layer included in the software upgrading installation package, and then replaces the file of the logic layer installed in the local memory of the client terminal with the upgrading file of the logic layer included in the software upgrading installation package so as to finish the upgrading of the logic layer; similarly, if the software upgrade installation package includes the upgrade file of the data layer, the client terminal upgrades the data layer according to the file of the data layer, specifically, the client terminal first acquires the upgrade file of the data layer included in the software upgrade installation package, and then replaces the file of the data layer installed in the local memory of the client terminal with the upgrade file of the data layer included in the software upgrade installation package, thereby completing the upgrade of the data layer.
If the software upgrading installation package comprises one or more upgrading files of the basic function engine layer of the software program, the basic function engine layer of the software program needs to be upgraded; specifically, since the upgrade file of the basic function engine layer is a file in a plug-in form, that is, the upgrade file of each basic function engine layer corresponds to one function of the basic function engine layer, if the software upgrade installation package includes the upgrade file of one basic function engine layer, the client terminal upgrades one function of the basic function engine layer corresponding to the upgrade file according to the one upgrade file, and if the software upgrade installation package includes the upgrade files of a plurality of basic function engine layers, the client terminal upgrades a plurality of functions of the basic function engine layers corresponding to the plurality of upgrade files one by one according to the plurality of upgrade files.
In the embodiment of the application, each of the user interface UI interface layer, the logic layer, the data layer and the basic function engine layer included in the software program can be upgraded independently without influencing the operation of other layers, and the software upgrading package can be upgraded as long as the upgrading file of the corresponding layer is included in the software upgrading package, so that the upgrading is completed in the software operation process, the software does not need to be closed, and the software upgrading and updating efficiency is improved.
In one possible implementation manner, the one or more upgrade files corresponding to the UI interface layer include a first file, and the upgrading the one or more functions of the UI interface layer separately according to the one or more upgrade files corresponding to the UI interface layer includes:
replacing a second file in a local software package corresponding to the software program with the first file, and modifying the name of the first file into the name of the second file, wherein the second file is a file in one or more files corresponding to the UI interface layer, and the first file is an upgrade file corresponding to the second file.
In a specific embodiment, there is a process of replacing a file and changing a file name in the process of upgrading the UI interface layer, and specifically, if one or more upgrade files of the UI interface layer are included in the software upgrade installation package, it is assumed that the one or more upgrade files include a first file, the first file may be any one of one or more upgrade files of a UI interface layer included in the software upgrade installation package, assuming that the first file is an upgrade file of the second file, that is, the second file is one of one or more corresponding files in the UI interface layer of the software program already installed in the local memory of the client terminal, during the process of upgrading the function corresponding to the second file, the client terminal replaces a second file of a UI interface layer in a software program installed in a local memory with a first file; since the file of the UI interface layer is a binary file, the binary file is locked by the system during the software operation, and therefore the file name of the first file cannot be the same as the file name of the second file, and after the second file is replaced with the first file, the client terminal modifies the file name of the first file to the file name of the second file.
In one possible implementation manner, the one or more upgrade files corresponding to the basic function engine layer include a third file, and the separately upgrading the one or more functions of the basic function engine layer according to the one or more upgrade files corresponding to the basic function engine layer includes:
replacing a fourth file in a local software package corresponding to the software program with the third file, and modifying the name of the third file into the name of the fourth file, where the fourth file is a file in one or more files corresponding to the basic function engine layer, and the third file is an upgrade file corresponding to the fourth file.
In a specific embodiment, there is a process of replacing files and changing file names in the process of upgrading the basic function engine layer, and particularly, if the software upgrade installation package includes one or more upgrade files of the basic function engine layer, it is assumed that the one or more upgrade files include a third file, the third file may be any one of one or more upgrade files of the basic function engine layer included in the software upgrade installation package, assuming that the third file is an upgrade file of the fourth file, that is, the fourth file is one of the one or more files corresponding to the basic function engine layer of the software program already installed in the local memory of the client terminal, in the process of upgrading the function corresponding to the fourth file, the client terminal replaces a fourth file of a basic function engine layer in a software program installed in a local memory with a third file; since the file of the basic function engine layer is a binary file, the binary file is locked by the system in the software running process, so that the file name of the third file cannot be the same as that of the fourth file, and therefore, after the fourth file is replaced by the third file, the client terminal modifies the file name of the third file into the file name of the fourth file.
In one possible implementation manner, if the one or more layers at least include the UI interface layer, after the upgrading the one or more layers corresponding to the software program according to the software upgrade package, the method further includes:
determining the version number of the upgraded UI layer; sending the version number after the UI interface layer is upgraded to an application server, wherein the version number after the UI interface layer is upgraded is used for requesting to acquire the data of the user interface UI layer corresponding to the version number after the UI interface layer is upgraded; receiving the UI layer data corresponding to the version number after the UI interface layer is upgraded and sent by the application server; and updating the UI interface of the software program according to the data of the UI layer corresponding to the version number after the UI interface layer is upgraded.
In a specific embodiment, the updating of the UI layer of the user interface depends on the updating of the UI interface layer, after the updating of the UI interface layer is completed, the client terminal verifies and determines the version number of the updated UI interface layer through a version verification mechanism of the UI interface layer, then sends the version number of the updated UI interface layer to the application server of the software background, after the application server receives the version number of the updated UI interface layer, finds the data of the UI layer corresponding to the associated version number of the updated UI interface layer according to the version number of the updated UI interface layer, then sends the data of the UI layer to the client terminal, and after the client terminal receives the data of the UI layer, the UI interface of the software is updated according to the data of the UI layer, thereby completing the updating of the UI interface of the software.
To sum up, in the embodiment of the present application, the UI interface layer and the basic function engine layer of the software program are binary files, but the binary files are written in the form of plug-ins, so that the software can be upgraded and updated without shutting down the software, the logic layer and the data layer are script files, so that the software can be upgraded and updated by updating the script files to be upgraded in the running process of the software, and the software does not need to be shut down, thereby improving the efficiency of upgrading and updating the software.
In order to better implement the above solution of the present application, an embodiment of the present application further provides a software upgrading apparatus, which is described in detail below with reference to fig. 3:
fig. 3 is a schematic diagram of a software upgrading apparatus 300. The software upgrading apparatus 300 includes: an acquisition unit 301 and an upgrade unit 302, wherein:
an obtaining unit 301, configured to obtain a software upgrade package corresponding to a software program, where the software upgrade package includes upgrade files corresponding to one or more layers of a UI interface layer, a logic layer, a data layer, and a basic function engine layer of the software program, where presentation forms of the upgrade files of the UI interface layer and the basic function engine layer are plug-in forms, and formats of the upgrade files of the logic layer and the data layer are script formats;
an upgrading unit 302, configured to upgrade one or more layers corresponding to the software program according to the software upgrade package.
In one embodiment, the upgrading unit 302 is configured to upgrade one or more layers corresponding to the software program according to the software upgrade package specifically:
if the software upgrading package comprises one or more upgrading files corresponding to the UI interface layer of the software program, the software upgrading package is used for respectively upgrading one or more functions of the UI interface layer according to the one or more upgrading files corresponding to the UI interface layer, and the one or more upgrading files corresponding to the UI interface layer are upgrading files corresponding to the one or more functions of the UI interface layer;
if the software upgrading package comprises an upgrading file in a script format corresponding to the logic layer of the software program, upgrading the logic layer according to the upgrading file in the script format corresponding to the logic layer;
if the software upgrading package comprises an upgrading file in a script format corresponding to the data layer of the software program, upgrading the data layer according to the upgrading file in the script format corresponding to the data layer;
and if the software upgrading package comprises one or more upgrading files corresponding to a basic function engine layer of the software program, the software upgrading package is used for respectively upgrading one or more functions of the basic function engine layer according to the one or more upgrading files corresponding to the basic function engine layer, and the one or more upgrading files corresponding to the basic function engine layer are upgrading files corresponding to the one or more functions of the basic function engine layer.
In one embodiment, the one or more upgrade files corresponding to the UI interface layer include a first file, the upgrade unit 302 includes a first replacement unit and a first modification unit,
the first replacing unit is used for replacing a second file in a local software package corresponding to the software program with the first file;
the first modification unit is configured to modify the name of the first file into the name of a second file, where the second file is a file in one or more files corresponding to the UI interface layer, and the first file is an upgrade file corresponding to the second file.
In one embodiment, the one or more upgrade files corresponding to the basic function engine layer include a third file, the upgrade unit 302 further includes a second replacement unit and a second modification unit,
the second replacing unit is used for replacing a fourth file in a local software package corresponding to the software program with the third file;
the second modification unit is configured to modify the name of the third file into the name of a fourth file, where the fourth file is a file in one or more files corresponding to the basic function engine layer, and the third file is an upgrade file corresponding to the fourth file.
In one embodiment, the one or more layers include at least the UI interface layer, the software upgrading apparatus 300 further includes a determining unit, a transmitting unit, a receiving unit and an updating unit,
the determining unit is configured to determine the version number of the UI interface layer after upgrading the one or more layers corresponding to the software program according to the software upgrade package;
the sending unit is used for sending the version number after the UI interface layer is upgraded to an application server, and the version number after the UI interface layer is upgraded is used for requesting to acquire the data of the user interface UI layer corresponding to the version number after the UI interface layer is upgraded;
the receiving unit is used for receiving the data of the UI layer corresponding to the version number after the UI interface layer is upgraded and sent by the application server;
and the updating unit is used for updating the UI interface of the software program according to the data of the UI layer corresponding to the version number after the UI interface layer is upgraded.
The specific implementation and beneficial effects of each unit in the software upgrading apparatus 300 shown in fig. 3 may correspond to the corresponding description in the method embodiment shown in fig. 2, and are not described again here.
Referring to fig. 4, fig. 4 is a schematic structural diagram of an electronic apparatus 400 provided in an embodiment of the present application, where the electronic apparatus 400 includes a processor 401, a memory 402, a communication interface 403, an input device 405, and an output device 406, and the processor 401, the memory 402, the communication interface 403, the input device 405, and the output device 406 are connected to each other through a bus 404. The electronic apparatus 400 may be an electronic apparatus such as a tablet computer or a personal computer, the input device 405 may be a device such as a keyboard, a mouse, a voice input device, or a touch panel, and the output device may be a device such as a display.
The memory 402 includes, but is not limited to, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM), or a portable read-only memory (CD-ROM), and the memory 402 is used for storing related instructions and data. The communication interface 403 is used for receiving and transmitting data.
The processor 401 may be one or more Central Processing Units (CPUs), and in the case that the processor 401 is one CPU, the CPU may be a single-core CPU or a multi-core CPU.
The processor 401 in the electronic device 400 is configured to read the program code stored in the memory 402 and perform the following operations:
the processor 401 obtains a software upgrading package corresponding to a software program through a communication interface 403, where the software upgrading package includes upgrading files corresponding to one or more layers of a user interface UI interface layer, a logic layer, a data layer and a basic function engine layer of the software program, where the presentation forms of the upgrading files of the UI interface layer and the basic function engine layer are plug-in forms, and the formats of the upgrading files of the logic layer and the data layer are script formats;
the processor 401 upgrades one or more layers corresponding to the software program according to the software upgrade package.
In one embodiment, the upgrading one or more layers corresponding to the software program by the processor 401 according to the software upgrade package includes:
if the software upgrade package includes one or more upgrade files corresponding to the UI interface layer of the software program, the processor 401 separately upgrades one or more functions of the UI interface layer according to the one or more upgrade files corresponding to the UI interface layer, where the one or more upgrade files corresponding to the UI interface layer are upgrade files corresponding to the one or more functions of the UI interface layer, respectively;
if the software upgrading package comprises an upgrading file in a script format corresponding to the logic layer of the software program, the processor 401 upgrades the logic layer according to the upgrading file in the script format corresponding to the logic layer;
if the software upgrading package comprises an upgrading file in a script format corresponding to the data layer of the software program, the processor 401 upgrades the data layer according to the upgrading file in the script format corresponding to the data layer;
if the software upgrade package includes one or more upgrade files corresponding to a basic function engine layer of the software program, the processor 401 separately upgrades one or more functions of the basic function engine layer according to the one or more upgrade files corresponding to the basic function engine layer, where the one or more upgrade files corresponding to the basic function engine layer are upgrade files corresponding to the one or more functions of the basic function engine layer.
In one embodiment, the one or more upgrade files corresponding to the UI interface layer include a first file, and the processor 401 separately upgrades one or more functions of the UI interface layer by using the one or more upgrade files corresponding to the UI interface layer, including:
the processor 401 replaces a second file in the local software package corresponding to the software program with the first file, and modifies the name of the first file into the name of the second file, where the second file is a file in the one or more files corresponding to the UI interface layer, and the first file is an upgrade file corresponding to the second file.
In one embodiment, the one or more upgrade files corresponding to the basic function engine layer include a third file, and the upgrading of the one or more functions of the basic function engine layer by the processor 401 according to the one or more upgrade files corresponding to the basic function engine layer includes:
the processor 401 replaces a fourth file in the local software package corresponding to the software program with the third file, and modifies the name of the third file into the name of the fourth file, where the fourth file is a file in one or more files corresponding to the basic function engine layer, and the third file is an upgrade file corresponding to the fourth file.
In one embodiment, if the one or more layers at least include the UI interface layer, after the processor 401 upgrades the one or more layers corresponding to the software program according to the software upgrade package, the method further includes:
processor 401 determines the version number of the updated UI interface layer;
the processor 401 sends the version number after the UI interface layer is upgraded to the application server through the communication interface 403, where the version number after the UI interface layer is used to request to obtain data of the user interface UI layer corresponding to the version number after the UI interface layer is upgraded;
the processor 401 receives, through the communication interface 403, the data of the UI layer corresponding to the version number after the UI interface layer is upgraded, which is sent by the application server;
and the processor 401 updates the UI interface of the software program according to the data of the UI layer corresponding to the version number after the UI interface layer is upgraded.
It should be noted that, the implementation and the beneficial effects of the above operations may also correspond to the corresponding description of the method embodiment shown in fig. 2.
Embodiments of the present application further provide a computer-readable storage medium, in which a computer program is stored, where the computer program includes program instructions, and when the program instructions are executed by a processor, the method flow shown in fig. 2 is implemented.
Embodiments of the present application also provide a computer program, which includes program instructions, and when the program instructions are executed by a processor, the method flow shown in fig. 2 is implemented.
To sum up, in the embodiment of the present application, the UI interface layer and the basic function engine layer of the software program are binary files, but the binary files are written in a form of plug-in, and the software can be updated without closing the software, and the logic layer and the data layer are script files, so that the software can be updated by updating the script files to be updated during the running process of the software, and the software does not need to be closed, thereby improving the efficiency of updating the software.
In the several embodiments provided in the present invention, it should be understood that the disclosed apparatus, device and method may be implemented in other manners. For example, the above-described apparatus embodiments are merely illustrative, and for example, the division of the units is only one type of logical functional division, and other divisions may be realized in practice, for example, multiple units or components may be combined or integrated into another system, or some features may be omitted, or not executed.
Finally, it should be noted that: the above embodiments are only used to illustrate the technical solution of the present invention, and not to limit the same; while the invention has been described in detail and with reference to the foregoing embodiments, it will be understood by those skilled in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some or all of the technical features may be equivalently replaced; and these modifications or substitutions do not depart from the spirit of the corresponding technical solutions of the embodiments of the present invention.

Claims (11)

1. A method of upgrading software, comprising:
acquiring a software upgrading package corresponding to a software program, wherein the software upgrading package comprises upgrading files corresponding to one or more layers of a User Interface (UI) interface layer, a logic layer, a data layer and a basic function engine layer of the software program, the presentation forms of the upgrading files of the UI interface layer and the basic function engine layer are plug-in forms, and the formats of the upgrading files of the logic layer and the data layer are script formats; the UI interface provides interactive services with a UI layer in a mode of a global wide area network web interface;
and upgrading one or more layers corresponding to the software program according to the software upgrading package.
2. The method of claim 1, wherein upgrading one or more layers corresponding to the software program according to the software upgrade package comprises:
if the software upgrading package comprises one or more upgrading files corresponding to the UI interface layer of the software program, respectively and independently upgrading one or more functions of the UI interface layer according to the one or more upgrading files corresponding to the UI interface layer, wherein the one or more upgrading files corresponding to the UI interface layer are upgrading files corresponding to the one or more functions of the UI interface layer;
if the software upgrading package comprises an upgrading file in a script format corresponding to the logic layer of the software program, upgrading the logic layer according to the upgrading file in the script format corresponding to the logic layer;
if the software upgrading package comprises an upgrading file in a script format corresponding to the data layer of the software program, upgrading the data layer according to the upgrading file in the script format corresponding to the data layer;
if the software upgrading package comprises one or more upgrading files corresponding to a basic function engine layer of the software program, respectively and independently upgrading one or more functions of the basic function engine layer according to the one or more upgrading files corresponding to the basic function engine layer, wherein the one or more upgrading files corresponding to the basic function engine layer are upgrading files corresponding to the one or more functions of the basic function engine layer.
3. The method according to claim 2, wherein the one or more upgrade files corresponding to the UI interface layer include a first file, and the individually upgrading the one or more functions of the UI interface layer according to the one or more upgrade files corresponding to the UI interface layer comprises:
replacing a second file in a local software package corresponding to the software program with the first file, and modifying the name of the first file into the name of the second file, wherein the second file is a file in one or more files corresponding to the UI interface layer, and the first file is an upgrade file corresponding to the second file.
4. The method according to claim 2, wherein the one or more upgrade files corresponding to the basic function engine layer include a third file, and the individually upgrading the one or more functions of the basic function engine layer according to the one or more upgrade files corresponding to the basic function engine layer includes:
and replacing a fourth file in the local software package corresponding to the software program with the third file, and modifying the name of the third file into the name of the fourth file, wherein the fourth file is a file in one or more files corresponding to the basic function engine layer, and the third file is an upgrade file corresponding to the fourth file.
5. The method according to any one of claims 1 to 4, wherein the one or more layers include at least the UI interface layer, and after the upgrading the one or more layers corresponding to the software program according to the software upgrade package, the method further includes:
determining the version number of the upgraded UI interface layer;
sending the version number after the UI interface layer is upgraded to an application server, wherein the version number after the UI interface layer is upgraded is used for requesting to acquire the data of the user interface UI layer corresponding to the version number after the UI interface layer is upgraded;
receiving the data of the UI layer corresponding to the version number after the UI interface layer is upgraded and sent by the application server;
and updating the UI interface of the software program according to the data of the UI layer corresponding to the version number after the UI interface layer is upgraded.
6. A software upgrading apparatus, comprising:
the software upgrading system comprises an acquisition unit and a processing unit, wherein the acquisition unit is used for acquiring a software upgrading package corresponding to a software program, the software upgrading package comprises upgrading files corresponding to one or more layers of a User Interface (UI) layer, a logic layer, a data layer and a basic function engine layer of the software program, the presentation forms of the upgrading files of the UI layer and the basic function engine layer are plug-in forms, and the formats of the upgrading files of the logic layer and the data layer are script formats; the UI interface provides interactive services with a UI layer in a mode of a global wide area network web interface;
and the upgrading unit is used for upgrading one or more layers corresponding to the software program according to the software upgrading package.
7. The apparatus according to claim 6, wherein the upgrading unit is configured to upgrade, according to the software upgrade package, one or more layers corresponding to the software program, specifically:
if the software upgrading package comprises one or more upgrading files corresponding to the UI interface layer of the software program, the software upgrading package is used for respectively upgrading one or more functions of the UI interface layer according to the one or more upgrading files corresponding to the UI interface layer, and the one or more upgrading files corresponding to the UI interface layer are upgrading files corresponding to the one or more functions of the UI interface layer;
if the software upgrading package comprises an upgrading file in a script format corresponding to the logic layer of the software program, upgrading the logic layer according to the upgrading file in the script format corresponding to the logic layer;
if the software upgrading package comprises an upgrading file in a script format corresponding to the data layer of the software program, upgrading the data layer according to the upgrading file in the script format corresponding to the data layer;
if the software upgrading package comprises one or more upgrading files corresponding to a basic function engine layer of the software program, the software upgrading package is used for respectively and independently upgrading one or more functions of the basic function engine layer according to the one or more upgrading files corresponding to the basic function engine layer, and the one or more upgrading files corresponding to the basic function engine layer are upgrading files corresponding to the one or more functions of the basic function engine layer.
8. The apparatus of claim 7, wherein the one or more upgrade files corresponding to the UI interface layer comprise a first file, the upgrade unit comprises a first replacement unit and a first modification unit,
the first replacing unit is used for replacing a second file in a local software package corresponding to the software program with the first file;
the first modification unit is configured to modify the name of the first file into the name of a second file, where the second file is a file in one or more files corresponding to the UI interface layer, and the first file is an upgrade file corresponding to the second file.
9. The apparatus of claim 7, wherein the one or more upgrade files corresponding to the basic function engine layer include a third file, the upgrade unit further includes a second replacement unit and a second modification unit,
the second replacing unit is used for replacing a fourth file in a local software package corresponding to the software program with the third file;
the second modification unit is configured to modify the name of the third file into the name of a fourth file, where the fourth file is a file in the one or more files corresponding to the basic function engine layer, and the third file is an upgrade file corresponding to the fourth file.
10. The apparatus according to any of claims 6-9, wherein the one or more layers comprise at least the UI interface layer, the apparatus further comprises a determining unit, a transmitting unit, a receiving unit, and an updating unit,
the determining unit is configured to determine the version number of the UI interface layer after upgrading the one or more layers corresponding to the software program according to the software upgrade package;
the sending unit is used for sending the version number after the UI interface layer is upgraded to an application server, and the version number after the UI interface layer is upgraded is used for requesting to acquire the data of the user interface UI layer corresponding to the version number after the UI interface layer is upgraded;
the receiving unit is used for receiving the data of the UI layer corresponding to the version number after the UI interface layer is upgraded and sent by the application server;
and the updating unit is used for updating the UI interface of the software program according to the data of the UI layer corresponding to the version number after the UI interface layer is upgraded.
11. An electronic device comprising a processor, a communication device, a memory, an input means and an output means, the processor, the communication device, the memory, the input means and the output means being interconnected, wherein the memory is configured to store application program code and the processor is configured to invoke the application program code to perform the method of any of claims 1 to 5.
CN201910256758.4A 2019-03-29 2019-03-29 Software upgrading method and device Active CN109960522B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910256758.4A CN109960522B (en) 2019-03-29 2019-03-29 Software upgrading method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910256758.4A CN109960522B (en) 2019-03-29 2019-03-29 Software upgrading method and device

Publications (2)

Publication Number Publication Date
CN109960522A CN109960522A (en) 2019-07-02
CN109960522B true CN109960522B (en) 2022-07-22

Family

ID=67025520

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910256758.4A Active CN109960522B (en) 2019-03-29 2019-03-29 Software upgrading method and device

Country Status (1)

Country Link
CN (1) CN109960522B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112241272B (en) * 2019-07-17 2023-08-01 宇通客车股份有限公司 Vehicle-mounted instrument and upgrading method and system thereof

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP2141591A1 (en) * 2008-07-04 2010-01-06 Oberthur Technologies Portable electronic device comprising a portable application and a secure module which can communicate with one another, and associated communication method
CN108345461A (en) * 2017-01-23 2018-07-31 北京京东尚科信息技术有限公司 Using update method and device and computer readable storage medium
CN108399074A (en) * 2018-01-30 2018-08-14 努比亚技术有限公司 A kind of update method of application program, terminal and computer readable storage medium
CN109002320A (en) * 2018-08-20 2018-12-14 苏州思必驰信息科技有限公司 For the update method of software development kit, system, electronic equipment and storage medium

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104093075A (en) * 2014-06-11 2014-10-08 深圳市九洲电器有限公司 Portal page updating method and system
CN109032691B (en) * 2018-06-25 2020-12-15 腾讯科技(深圳)有限公司 Applet running method and device and storage medium

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP2141591A1 (en) * 2008-07-04 2010-01-06 Oberthur Technologies Portable electronic device comprising a portable application and a secure module which can communicate with one another, and associated communication method
CN108345461A (en) * 2017-01-23 2018-07-31 北京京东尚科信息技术有限公司 Using update method and device and computer readable storage medium
CN108399074A (en) * 2018-01-30 2018-08-14 努比亚技术有限公司 A kind of update method of application program, terminal and computer readable storage medium
CN109002320A (en) * 2018-08-20 2018-12-14 苏州思必驰信息科技有限公司 For the update method of software development kit, system, electronic equipment and storage medium

Also Published As

Publication number Publication date
CN109960522A (en) 2019-07-02

Similar Documents

Publication Publication Date Title
CN113312037B (en) Data processing method, device, equipment and storage medium applied to micro-service
US8495609B2 (en) Methods, systems, and computer program products for taking a snapshot of installed software on a data processing system as part of a software update process
WO2020173128A1 (en) Method and device for generating software development kit, and terminal device
JP2021002317A (en) Method, apparatus, device and storage medium for upgrading application
JP7493053B2 (en) Image file generating method, device and computer program
CN107291481B (en) Component updating method, device and system
CN109408086A (en) Interface updating method, device, computer equipment and the storage medium of APP
US20210240545A1 (en) Information Handling System And Method To Automatically Synchronize Operating System And Boot Firmware Languages
KR102052776B1 (en) Installation engine and package format for parallelizable, reliable installations
US9141385B2 (en) Managing operating system components
US9513762B1 (en) Static content updates
CN115291946A (en) Hongmong system transplanting method, device, electronic equipment and readable medium
CN109960522B (en) Software upgrading method and device
CN114461223A (en) Code generation method and device and terminal equipment
JP6002302B2 (en) Web application generation system, Web application generation system control method, Web application generation system program, Web application generation device, Web application generation device control method, and Web application generation device program
CN111913753A (en) Method and system for changing starting mode in cloud migration of windows system
CN112235132A (en) Method, device, medium and server for dynamically configuring service
CN110599112B (en) Network page development and maintenance method and device
CN102184112B (en) Method and device for upgrading widget
WO2015196524A1 (en) Software upgrade processing method and device, terminal and server
CN112379973A (en) Heavy loading method and device
CN110489140B (en) Software upgrading method and device, computer equipment and computer storage medium
TWI416410B (en) System and method for updating version of the executable file
CN115509634A (en) Input method configuration method, character input method, device and medium
CN116185442A (en) VoIP phone upgrading method and device based on android system

Legal Events

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