CN117193817A - Method, apparatus, device and computer readable medium for software upgrade - Google Patents

Method, apparatus, device and computer readable medium for software upgrade Download PDF

Info

Publication number
CN117193817A
CN117193817A CN202311146314.8A CN202311146314A CN117193817A CN 117193817 A CN117193817 A CN 117193817A CN 202311146314 A CN202311146314 A CN 202311146314A CN 117193817 A CN117193817 A CN 117193817A
Authority
CN
China
Prior art keywords
software
proxy node
installing
new version
proxy
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.)
Pending
Application number
CN202311146314.8A
Other languages
Chinese (zh)
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.)
CCB Finetech Co Ltd
Original Assignee
CCB Finetech 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 CCB Finetech Co Ltd filed Critical CCB Finetech Co Ltd
Priority to CN202311146314.8A priority Critical patent/CN117193817A/en
Publication of CN117193817A publication Critical patent/CN117193817A/en
Pending legal-status Critical Current

Links

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The invention discloses a method, a device, equipment and a computer readable medium for upgrading software, and relates to the technical field of cloud computing. One embodiment of the method comprises the following steps: setting proxy nodes in the available areas of different partitions, and setting copies of the proxy nodes in the different available areas; after the proxy node installs the new version of software, the proxy node installs the new version of software and the proxy node installs the old version of software, and receives and processes the read-write request of the available area; and after the leading copy of the available area is migrated to the proxy node for installing the new version of software, upgrading the proxy node for installing the old version of software to the new version of software. The implementation method can shorten the time consumption of software upgrading.

Description

Method, apparatus, device and computer readable medium for software upgrade
Technical Field
The present invention relates to the field of cloud computing technologies, and in particular, to a method, an apparatus, a device, and a computer readable medium for upgrading software.
Background
With the development of cloud computing technology, the trend of business data storage at the cloud is irreversible, and as a support for a key function facing a user, a distributed event storage and stream processing platform is one of key points for storing data at the cloud.
Currently, most of the important components are deployed in the cloud, and proxy nodes of the search engine are deployed in the available area.
In the process of implementing the present invention, the inventor finds that at least the following problems exist in the prior art: in the process of upgrading the proxy node software, all proxy nodes need to be shut down and upgraded. The process of upgrading the software needs to take a long time.
Disclosure of Invention
In view of this, embodiments of the present invention provide a method, apparatus, device, and computer readable medium for software upgrade, which can shorten the time spent for software upgrade.
To achieve the above object, according to an aspect of an embodiment of the present invention, there is provided a method for upgrading software, including:
setting proxy nodes in the available areas of different partitions, and setting copies of the proxy nodes in the different available areas;
after the proxy node installs the new version of software, the proxy node installs the new version of software and the proxy node installs the old version of software, and receives and processes the read-write request of the available area;
and after the leading copy of the available area is migrated to the proxy node for installing the new version of software, upgrading the proxy node for installing the old version of software to the new version of software.
The setting copies of the proxy nodes in different available areas comprises the following steps:
a copy of a topic is taken as a copy of a proxy node, and the copy of the proxy node is arranged in different available areas.
After the proxy node installs the new version of software, the proxy node installs the new version of software and the proxy node installs the old version of software, receives and processes the read-write request of the available area, and comprises the following steps:
copying an installation file of new version software to install the new version software in a proxy node;
and the proxy node for installing the new version of software and the proxy node for installing the old version of software receive and process the read-write request of the available area.
The migration of the leading copy of the available area to the proxy node for installing new software comprises the following steps:
searching the proxy node for installing the new version of software;
and establishing a migration file according to the identification of the proxy node for installing the new version of software so as to migrate the leading copy of the available area to the proxy node for installing the new version of software.
The migration of the leading copy of the available area to the proxy node for installing new software comprises the following steps:
and determining that all the leading copies of the available areas are migrated to the proxy node for installing the new software based on the identification of the leading copies of the available areas and the identification of the leading copies migrated to the proxy node for installing the new software.
The upgrading the proxy node for installing the old version of software to the new version of software comprises the following steps:
copying an installation file of new version software to install the new version software on a proxy node for installing old version software;
and after the proxy node for installing the old version of software is updated to the new version of software, installing the new version of software on the next proxy node for installing the old version of software.
The upgrading the proxy node for installing the old version of software to the new version of software comprises the following steps:
closing the proxy node for installing the old version of software, and upgrading the proxy node for installing the old version of software in different available areas to the new version of software.
Before receiving and processing the read-write request of the available area, the method comprises the following steps:
and distributing the read-write requests of the available area to the proxy node for loading new version software or the proxy node for loading old version software according to the number of the read-write requests currently processed by the proxy node so as to ensure the load balance of the proxy node.
The setting copies of the proxy nodes in different available areas comprises the following steps:
3 copies of the proxy node are set in one available area.
According to a second aspect of an embodiment of the present invention, there is provided an apparatus for software upgrade, including:
The setting module is used for setting the proxy nodes in the available areas of different partitions and setting copies of the proxy nodes in the different available areas;
the processing module is used for installing the proxy node of the new version of software and the proxy node of the old version of software after the proxy node installs the new version of software, and receiving and processing the read-write request of the available area;
and the upgrading module is used for upgrading the proxy node for installing the old version of software to the new version of software after the leading copy of the available area is migrated to the proxy node for installing the new version of software.
According to a third aspect of an embodiment of the present invention, there is provided an electronic device for software upgrade, including:
one or more processors;
storage means for storing one or more programs,
the one or more programs, when executed by the one or more processors, cause the one or more processors to implement the methods as described above.
According to a fourth aspect of embodiments of the present invention, there is provided a computer readable medium having stored thereon a computer program which when executed by a processor implements a method as described above.
According to a fifth aspect of embodiments of the present invention, there is provided a computer program product comprising a computer program which, when executed by a processor, implements a method as provided by embodiments of the present invention.
One embodiment of the above invention has the following advantages or benefits: setting proxy nodes in the available areas of different partitions, and setting copies of the proxy nodes in the different available areas; after the proxy node installs the new version of software, the proxy node installs the new version of software and the proxy node installs the old version of software, and receives and processes the read-write request of the available area; and after the leading copy of the available area is migrated to the proxy node for installing the new version of software, upgrading the proxy node for installing the old version of software to the new version of software. The proxy nodes are upgraded one by one, and the proxy nodes can still process read-write requests in the upgrading process, so that the time consumption of software upgrading is shortened.
Further effects of the above-described non-conventional alternatives are described below in connection with the embodiments.
Drawings
The drawings are included to provide a better understanding of the invention and are not to be construed as unduly limiting the invention. Wherein:
FIG. 1 is a schematic flow diagram of a method of software upgrade according to an embodiment of the present invention;
FIG. 2 is a schematic diagram of a proxy node according to an embodiment of the invention;
FIG. 3 is a schematic representation of a copy of an available region storage proxy node according to an embodiment of the present invention;
FIG. 4 is a flow diagram of a proxy node for installing new version software and a proxy node for installing old version software running simultaneously according to an embodiment of the present application;
FIG. 5 is a flow diagram of migrating a leading copy according to an embodiment of the present application;
FIG. 6 is a flow diagram of updating proxy nodes with new versions of software according to an embodiment of the application;
FIG. 7 is a schematic diagram of the main structure of a device for software upgrade according to an embodiment of the present application;
FIG. 8 is an exemplary system architecture diagram in which embodiments of the present application may be applied;
fig. 9 is a schematic diagram of a computer system suitable for use in implementing an embodiment of the application.
Detailed Description
Exemplary embodiments of the present application will now be described with reference to the accompanying drawings, in which various details of the embodiments of the present application are included to facilitate understanding, and are to be considered merely exemplary. Accordingly, those of ordinary skill in the art will recognize that various changes and modifications of the embodiments described herein can be made without departing from the scope and spirit of the application. Also, descriptions of well-known functions and constructions are omitted in the following description for clarity and conciseness. The technical scheme of the application obtains, stores, uses, processes and the like the data, which all meet the relevant regulations of national laws and regulations.
The distributed event storage and stream processing platform acts as a high throughput distributed messaging system and plays an important role in the data transmission process. In a distributed system, each Partition (Partition) has multiple copies, one copy is elected as a leader (leader) copy of the current Partition, and is responsible for reading and writing data, and the other copies are backed up as follow-up (follower) copies. If the leader copy is down or the network is abnormal, a new leader copy needs to be reelected. As one example, the distributed event storage and stream processing platform includes a Kafka cluster.
The Kafka cluster contains one or more servers called proxy nodes (brooker). The Kafka cluster contains a plurality of producers (producers), a plurality of brookers, a plurality of consumer groups (consumer groups), and a Zookeeper cluster. The Kafka cluster manages cluster configuration through Zookeeper, producer publishes messages to the broker using push (push) mode, and consumer subscribes to and consumes messages from the broker using pull (pull) mode.
In the process of upgrading software, all proxy nodes need to be shut down for upgrading. The process of upgrading the software needs to take a long time.
In order to solve the problem that software upgrading takes a long time, the following technical scheme in the embodiment of the invention can be adopted.
Referring to fig. 1, fig. 1 is a schematic flow chart of a software upgrading method according to an embodiment of the present invention, where a plurality of proxy nodes process read-write requests and install new software to implement software upgrading. As shown in fig. 1 and 100, the method specifically comprises the following steps:
s101, setting proxy nodes in available areas of different partitions, and setting copies of the proxy nodes in the different available areas.
In an embodiment of the invention, the proxy node is used for processing read-write requests. As one example, the proxy node includes a kafka server. And the proxy node receives a processing read-write request sent by the user. The available area is included in each Partition (Partition). It will be appreciated that the available area is a preset location in the partition. In the availability zone, a copy of the proxy node may be set. As an example, the available area is an area corresponding to the application end. As an example, the application terminal 1 corresponds to the available area 1; the application end 2 corresponds to the available area 2.
Specifically, proxy nodes are set in the available areas of different partitions, and copies of proxy nodes are set in the different available areas. If proxy nodes are arranged in the available areas of different partitions, software upgrading can be realized in the available areas. Copies of the proxy node are set in different available areas, meaning that the proxy node can backup data in the available areas.
The available zones and/or copies are used to achieve fault tolerance at the zone level. As one example, a Kafka agent is divided into three distinct partitions, each containing 16 agent nodes. That is, 16 proxy nodes are set in the available area of one partition. Each proxy node has a corresponding copy. In the event of failure of some of the available regions, only the proxy nodes and copies of some of the available regions are affected, and not all of the proxy nodes and all of the copies.
Referring to fig. 2, 200, fig. 2 is a schematic diagram of a proxy node according to an embodiment of the present invention. The available zones in FIG. 2 include zone1, zone2, and zone3. 4 proxy nodes are set in each available area. Specifically, proxy node 0, proxy node 3, proxy node 6, and proxy node 9 are set in zone 1; setting a proxy node 1, a proxy node 4, a proxy node 7 and a proxy node 10 in zone 2; proxy node 2, proxy node 5, proxy node 8, and proxy node 11 are set in zone3.
In one embodiment of the present invention, the number of proxy nodes is set in the available area, and may be preset based on the actual application scenario. As one example, the number of available area proxy nodes is set based on the number of kafka service proxies. Such as: the number of agent nodes is the same as the number of kafka service agents.
In one embodiment of the invention, a method of performing a software upgrade may be employed with a script. Specifically, scripts are used to set proxy nodes in the available areas of different partitions, and copies of proxy nodes are set in the different available areas. The adoption of script reduces the chance and error of manual intervention. The process may also be reviewed and refined periodically to ensure its efficiency and reliability. As one example, the scripts include shell scripts and/or python scripts.
In one embodiment of the invention, a copy of a topic is taken as a copy of a proxy node, and the copies of the proxy node are arranged in different available areas. Wherein the different available areas include different available areas than the available areas where the proxy node is located. In this way, even if a proxy node in one available region is closed, the proxy node is not affected to process data to achieve a partition upgrade because there is a copy of the proxy node in the other available region.
Referring to fig. 3, 300, fig. 3 is a schematic diagram of a copy of an available area storage proxy node according to an embodiment of the present invention. The usable area of fig. 3 includes: zone-A, zone-B and zone-C. Copies of topic (topic) 1 and topic2 were stored in zone-A, zone-B and zone-C, respectively. Such as: in zone-A, 3 copies of topic1 and 3 copies of topic2 are stored.
the copy distribution of topic1 is now distributed over three areas. The proxy in zone-A is closed and the proxy node is not affected to process data because there are copies of the proxy node in zone-B and zone-C.
Different proxy nodes are distributed in different available areas of different partitions. The same copies are distributed in different available areas. When the proxy node fails or goes wrong, only a single available area is affected, and the whole cluster is not affected.
S102, after the proxy node installs the new version of software, the proxy node installs the new version of software and the proxy node installs the old version of software, and the read-write request of the available area is received and processed.
Software needs to be upgraded for proxy nodes. The plurality of proxy nodes do not interrupt service, namely receive and process the read-write request of the available area, in the process of upgrading the software. The agent node upgrade software is upgraded one by one to ensure continuity and availability of service.
Specifically, after the new version of software is released, the new version of software is installed on one or more proxy nodes. Wherein, the proxy node for installing the new version of software can be determined based on the available area. As one example, a proxy node to install new version of software is selected based on the importance of the availability zone. Such as: the importance of the usable area 1 is higher than that of the usable area 2. The agent node of the new edition software is firstly arranged in the available area 1, and then the agent node of the new edition software is arranged in the available area 2. This facilitates the early installation of new versions of software in important available areas.
As another example, a proxy node for installing new version software is selected based on the amount of data stored in the available region. The larger the amount of data stored in the available area, the more important the proxy node is, and the new software can be installed first.
And when the proxy node installs the new version of software, the proxy node installing the new version of software and the proxy node installing the old version of software run simultaneously, and the read-write request of the available area is received and processed.
Referring to fig. 4 and 400, fig. 4 is a schematic flow chart of a process of simultaneously running a proxy node for installing new version software and a proxy node for installing old version software according to an embodiment of the present invention. The method specifically comprises the following steps:
s401, copying an installation file of the new version of software to install the new version of software in a proxy node.
And downloading and decompressing the installation file of the new software. The installation file of the new version of software is copied to install the new version of software in a proxy node.
It should be noted that, while the proxy node installs the new version of software, the proxy node installing the old version of software may receive and process the read-write request of the available area.
S402, the proxy node for installing the new version of software and the proxy node for installing the old version of software receive and process the read-write request of the available area.
After the proxy node installs the new version of software, the proxy node is called as a proxy node for installing the new version of software. The proxy node for installing the new version of software and the proxy node for installing the old version of software can continuously receive and process the read-write request of the available area.
In the embodiment of fig. 4, the proxy nodes may each install new versions of software. The proxy node for installing the new version of software and the proxy node for installing the old version of software receive and process the read-write request of the available area.
And S103, after the leading copy of the available area is migrated to the proxy node for installing the new version of software, upgrading the proxy node for installing the old version of software to the new version of software.
And the proxy node copy is updated by being migrated to the proxy node on which the new version of software is installed. Specifically, after the leading copy of the available area is migrated to the proxy node for installing the new version of software, the proxy node for installing the old version of software is upgraded to the new version of software. Wherein the leading copy of the available region is determined from the copies of the proxy nodes. As one example, the leading copy of the available region is elected among the copies of the proxy node.
Referring to fig. 5, 500, fig. 5 is a schematic flow diagram of migrating a leader copy according to an embodiment of the present invention. The method specifically comprises the following steps:
S501, searching for a proxy node for installing new software.
After the proxy node installs the new version of software, the migration of the copy needs to be considered. First, a proxy node that installs new version software is searched. As one example, a proxy node that installs new version software is searched based on the identity of the new version software.
S502, a migration file is established according to the identification of the proxy node for installing the new software, so that the leading copy of the available area is migrated to the proxy node for installing the new software.
After searching the proxy node for installing the new version of software, establishing a migration file according to the identification of the proxy node for installing the new version of software. As one example, the migration file is a json file.
And migrating the leading copy of the available area to a proxy node for installing the new software according to the migration file. After the leader copy is migrated to the proxy node where the new version of software is installed, a new leader copy is selected from the follower copies. Further, the leader copy is migrated again to the proxy node where the new version of software is installed.
In the embodiment of FIG. 5, the leading copy of the available region is migrated to the proxy node that installed the new version of software based on the migration file.
In one embodiment of the invention, it is necessary to confirm that all leader copies are migrated to the proxy node where the new version of software is installed. Specifically, based on the identification of the leader copies of the available regions and the identification of the leader copies migrated to the agent node that installed the new version of software, it is determined that all of the leader copies of the available regions have been migrated to the agent node that installed the new version of software.
As one example, if the identity of the leading copies of all available regions is the same as the identity of the leading copies migrated to the proxy node that installed the new version of software, then it is determined that all leading copies of the available regions have been migrated to the proxy node that installed the new version of software.
After confirming that all the leading copies are migrated to the proxy node for installing the new version software, the proxy node for installing the old version software is updated by the new version software.
Referring to fig. 6, fig. 6 is a schematic flow chart of updating proxy nodes with new versions of software according to an embodiment of the present invention. The method specifically comprises the following steps:
s601, copying an installation file of the new version of software to install the new version of software on an agent node for installing the old version of software.
After all the leading copies of the available areas are migrated to the proxy node for installing the new version of software, the need of accelerating the upgrade of the software of the proxy node is described. Then the installation file of the new version of software may be copied to install the new version of software at a proxy node where the old version of software is installed.
S602, after the proxy node for installing the old version of software is updated to the new version of software, the new version of software is installed on the next proxy node for installing the old version of software.
After an agent node for installing old version software is upgraded to new version software, the next agent node for installing old version software can be continuously upgraded. That is, the new version of software is installed on the next proxy node on which the old version of software is installed.
In the embodiment of FIG. 6, after all of the leader copies have been migrated to the proxy node that installed the new version of software, the new version of software may be installed for the proxy node that installed the old version of software.
In one embodiment of the invention, in order to accelerate the speed of upgrading software by the proxy node, the proxy node for installing old version software can be closed, and the proxy node for installing old version software in different available areas can be upgraded to new version software.
After the leading copy of the available area is migrated to the proxy node for installing the new software, the proxy node for installing the new software provides service. The proxy node for installing the old version software is not required to provide service, the proxy node for installing the old version software is closed firstly, and the proxy nodes for installing the old version software in different available areas can be updated to the new version software. In this way, the software of multiple proxy nodes can be upgraded at once.
As one example, after migrating the leading copy of the available region onto the proxy node that installed the new version of software, the proxy node that installed the old version of software includes proxy node a in available region A, proxy node B in available region B, and proxy node C in available region C. Agent node a, agent node b, and agent node c may be shut down first, and then upgraded to new versions.
In one embodiment of the invention, to avoid negatively impacting the production environment during proxy node upgrades, load control measures are implemented to ensure that proxy nodes do not overload by limiting the number of client connections and traffic. The available region read-write request may also be allocated before the upgrade receives and processes the available region read-write request.
Specifically, according to the number of the read-write requests currently processed by the proxy node, the read-write requests of the available area are distributed to the proxy node for loading new version software or the proxy node for loading old version software, so that the load balance of the proxy node is ensured.
As one example, multiple read and write requests need to be processed for each proxy node. The read-write requests of the available area may be allocated based on the number of currently processed read-write requests of the proxy node.
Such as: the read-write requests of the available area are allocated based on the principle that the number of the read-write requests processed by each node is the same. The proxy node of the new version of software comprises a node a and a node b, and the proxy node for installing the old version of software comprises a node c. And counting the number of the current processing requests of each node. The same number of read-write requests processed by each node is preset. Node a currently processes 4 read-write requests; node b currently processes 3 read-write requests; node c may send 4 read-write requests from the current process to node b for processing.
And the following steps: considering that the proxy node for installing the old version of software also needs software upgrade, the number of the proxy nodes for setting the new version of software to process the read requests is greater than the number of the proxy nodes for the old version of software to process the read requests. That is, the read-write requests of the available area are allocated based on the principle that the number of read requests processed by the agent node of the new version of software is greater than the number of read requests processed by the agent node of the old version of software. The proxy node of the new version of software comprises a node a and a node b, and the proxy node for installing the old version of software comprises a node c. And counting the number of the current processing requests of each node. The same number of read-write requests processed by each node is preset. Node a currently processes 4 read-write requests; node b currently processes 3 read-write requests; node c may send the newly received read-write requests of the available area to node b for processing, if 3 read-write requests are currently processed.
In one embodiment of the invention, copies of the proxy node are set in different availability zones to handle traffic through the copies. Specifically, 3 copies of the proxy node are set in one available area. Through multiple practices, the data parallel processing efficiency is high and the data load balance is met under the condition that the number of copies of the proxy node is 3 in consideration of data parallel processing and data load balance in the software upgrading process.
As an example, in a Kafka cluster, each Topic (Topic) may be divided into multiple partitions, each of which may be assigned to a different proxy node process to enable parallel processing of data. Each Topic is divided into 4 partitions, and each partition is replicated and synchronized on 3 copies within one available area, respectively, to improve parallelism and reliability.
Specifically, after each topic is divided into 4 partitions, each partition is respectively allocated to 3 copies in each available area for replication and synchronization. And 3 copies, wherein one copy is a leader (leader) copy and is responsible for processing read-write requests and data copying, and the other two copies are follower copies and are responsible for copying data of the leader copies. Thus, each available area can be processed and copied on 3 copies at the same time, and parallel processing and load balancing of data are realized.
3 copies of the proxy node are arranged in one available area, so that the parallelism of the Kafka cluster is improved to 3 times, and meanwhile, the reliability and the availability of data are guaranteed. When the leader copy fails, the Kafka cluster automatically performs leader election, and reliability and consistency of data are ensured.
In the embodiment of the invention, the proxy nodes are arranged in the available areas of different partitions, and the copies of the proxy nodes are arranged in the different available areas; after the proxy node installs the new version of software, the proxy node installs the new version of software and the proxy node installs the old version of software, and receives and processes the read-write request of the available area; and after the leading copy of the available area is migrated to the proxy node for installing the new version of software, upgrading the proxy node for installing the old version of software to the new version of software. The proxy nodes are upgraded one by one, and the leader copy is migrated based on the upgraded proxy nodes. After the leading copy completes migration, the proxy node for installing the old version of software is started again for upgrading. In the upgrading process, the proxy node can still process the read-write request, so that the time spent on software upgrading is shortened.
In the whole updating process, the read-write request can be smoothly transferred between the proxy node for installing the new version software and the proxy node for installing the old version software. In addition, as the copies of the proxy nodes are arranged in different available areas, all data can be reserved, and the situation of data loss can not occur. Meanwhile, the proxy node is adopted to realize rolling software upgrading, so that the performance and stability of the whole cluster are not affected in the software upgrading process.
Referring to fig. 7, fig. 7 is a schematic main structural diagram of a software upgrade apparatus according to an embodiment of the present invention, where the software upgrade apparatus may implement a software upgrade method, as shown in fig. 7, 700, and the software upgrade apparatus specifically includes:
a setting module 701, configured to set proxy nodes in available areas of different partitions, and set copies of proxy nodes in different available areas;
the processing module 702 is configured to receive and process a read-write request of the available area after the proxy node installs the new version of software, and installs the proxy node of the new version of software and the proxy node of the old version of software;
and the upgrade module 703 is configured to upgrade the proxy node for installing the old version of software to the new version of software after migrating the leading copy of the available area to the proxy node for installing the new version of software.
In one embodiment of the present invention, the setting module 701 is specifically configured to take a copy of a theme as a copy of a proxy node, and set the copy of the proxy node in different available areas.
In one embodiment of the present invention, the processing module 702 is specifically configured to copy an installation file of a new version of software, so as to install the new version of software in a proxy node;
And the proxy node for installing the new version of software and the proxy node for installing the old version of software receive and process the read-write request of the available area.
In one embodiment of the present invention, the upgrade module 703 is specifically configured to search for the proxy node for installing the new version of software;
and establishing a migration file according to the identification of the proxy node for installing the new version of software so as to migrate the leading copy of the available area to the proxy node for installing the new version of software.
In one embodiment of the present invention, the upgrade module 703 is specifically configured to determine that all the leading copies of the available area have been migrated to the proxy node that installs the new software based on the identification of the leading copies of the available area and the identification of the leading copies migrated to the proxy node that installs the new software.
In one embodiment of the present invention, the upgrade module 703 is specifically configured to copy an installation file of a new version of software, so as to install the new version of software in a proxy node where the old version of software is installed;
and after the proxy node for installing the old version of software is updated to the new version of software, installing the new version of software on the next proxy node for installing the old version of software.
In one embodiment of the present invention, the upgrade module 703 is specifically configured to close the proxy node for installing the old version of software, and upgrade the proxy node for installing the old version of software in different available areas to the new version of software.
In one embodiment of the present invention, the setting module 701 is further configured to distribute the read-write request of the available area to the proxy node that installs the new version of software or the proxy node that installs the old version of software according to the number of the currently processed read-write requests of the proxy node, so as to ensure the load balance of the proxy node.
In one embodiment of the present invention, the setting module 701 is further configured to set 3 copies of the proxy node in one available area.
Fig. 8 illustrates an exemplary system architecture 800 of a method of software upgrade or an apparatus of software upgrade to which embodiments of the present invention may be applied.
As shown in fig. 8, a system architecture 800 may include terminal devices 801, 802, 803, a network 804, and a server 805. The network 804 serves as a medium for providing communication links between the terminal devices 801, 802, 803 and the server 805. The network 804 may include various connection types, such as wired, wireless communication links, or fiber optic cables, among others.
A user may interact with the server 805 through the network 804 using the terminal devices 801, 802, 803 to receive or send messages or the like. Various communication client applications such as shopping class applications, web browser applications, search class applications, instant messaging tools, mailbox clients, social platform software, etc. (by way of example only) may be installed on the terminal devices 801, 802, 803.
The terminal devices 801, 802, 803 may be a variety of electronic devices having a display screen and supporting web browsing, including but not limited to smartphones, tablets, laptop and desktop computers, and the like.
The server 805 may be a server providing various services, such as a background management server (by way of example only) that provides support for shopping-type websites browsed by users using the terminal devices 801, 802, 803. The background management server may analyze and process the received data such as the product information query request, and feedback the processing result (e.g., the target push information, the product information—only an example) to the terminal device.
It should be noted that, the method for upgrading software provided by the embodiment of the present invention is generally executed by the server 805, and accordingly, the device for upgrading software is generally disposed in the server 805.
It should be understood that the number of terminal devices, networks and servers in fig. 8 is merely illustrative. There may be any number of terminal devices, networks, and servers, as desired for implementation.
A computer program product according to an embodiment of the present invention includes a computer program that, when executed by a processor, implements a method for upgrading software according to an embodiment of the present invention.
Referring now to FIG. 9, there is illustrated a schematic diagram of a computer system 900 suitable for use in implementing an embodiment of the present invention. The terminal device shown in fig. 9 is only an example, and should not impose any limitation on the functions and the scope of use of the embodiment of the present invention.
As shown in fig. 9, the computer system 900 includes a Central Processing Unit (CPU) 901, which can execute various appropriate actions and processes according to a program stored in a Read Only Memory (ROM) 902 or a program loaded from a storage section 908 into a Random Access Memory (RAM) 903. In the RAM 903, various programs and data necessary for the operation of the system 900 are also stored. The CPU 901, ROM 902, and RAM 903 are connected to each other through a bus 904. An input/output (I/O) interface 905 is also connected to the bus 904.
The following components are connected to the I/O interface 905: an input section 906 including a keyboard, a mouse, and the like; an output portion 907 including a display such as a Cathode Ray Tube (CRT), a Liquid Crystal Display (LCD), and a speaker; a storage portion 908 including a hard disk or the like; and a communication section 909 including a network interface card such as a LAN card, a modem, or the like. The communication section 909 performs communication processing via a network such as the internet. The drive 910 is also connected to the I/O interface 905 as needed. A removable medium 911 such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, or the like is installed as needed on the drive 910 so that a computer program read out therefrom is installed into the storage section 908 as needed.
In particular, according to embodiments of the present disclosure, the processes described above with reference to flowcharts may be implemented as computer software programs. For example, embodiments of the present disclosure include a computer program product comprising a computer program embodied on a computer readable medium, the computer program comprising program code for performing the method shown in the flow chart. In such an embodiment, the computer program may be downloaded and installed from the network via the communication portion 909 and/or installed from the removable medium 911. The above-described functions defined in the system of the present invention are performed when the computer program is executed by a Central Processing Unit (CPU) 901.
The computer readable medium shown in the present invention may be a computer readable signal medium or a computer readable storage medium, or any combination of the two. The computer readable storage medium can be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or a combination of any of the foregoing. More specific examples of the computer-readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the context of this document, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. In the present invention, however, the computer-readable signal medium may include a data signal propagated in baseband or as part of a carrier wave, with the computer-readable program code embodied therein. Such a propagated data signal may take any of a variety of forms, including, but not limited to, electro-magnetic, optical, or any suitable combination of the foregoing. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, fiber optic cable, RF, etc., or any suitable combination of the foregoing.
The flowcharts and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present invention. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams or flowchart illustration, and combinations of blocks in the block diagrams or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
The modules involved in the embodiments of the present invention may be implemented in software or in hardware. The described modules may also be provided in a processor, for example, as: a processor includes a setup module, a processing module, and an upgrade module. Where the names of the modules do not constitute a limitation on the module itself in some cases, for example, the setup module may also be described as "for setting up proxy nodes in the available areas of different partitions, and for setting up copies of proxy nodes in different available areas".
As another aspect, the present invention also provides a computer-readable medium that may be contained in the apparatus described in the above embodiments; or may be present alone without being fitted into the device. The computer readable medium carries one or more programs which, when executed by a device, cause the device to include:
setting proxy nodes in the available areas of different partitions, and setting copies of the proxy nodes in the different available areas;
after the proxy node installs the new version of software, the proxy node installs the new version of software and the proxy node installs the old version of software, and receives and processes the read-write request of the available area;
and after the leading copy of the available area is migrated to the proxy node for installing the new version of software, upgrading the proxy node for installing the old version of software to the new version of software.
According to the technical scheme of the embodiment of the invention, proxy nodes are arranged in the available areas of different partitions, and copies of the proxy nodes are arranged in the different available areas; after the proxy node installs the new version of software, the proxy node installs the new version of software and the proxy node installs the old version of software, and receives and processes the read-write request of the available area; and after the leading copy of the available area is migrated to the proxy node for installing the new version of software, upgrading the proxy node for installing the old version of software to the new version of software. The proxy nodes are upgraded one by one, and the proxy nodes can still process read-write requests in the upgrading process, so that the time consumption of software upgrading is shortened.
The above embodiments do not limit the scope of the present invention. It will be apparent to those skilled in the art that various modifications, combinations, sub-combinations and alternatives can occur depending upon design requirements and other factors. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present invention should be included in the scope of the present invention.
In the technical scheme of the invention, the aspects of acquisition, analysis, use, transmission, storage and the like of the related user personal information all meet the requirements of related laws and regulations, are used for legal and reasonable purposes, are not shared, leaked or sold outside the aspects of legal use and the like, and are subjected to supervision and management of a supervision department. Necessary measures should be taken for the personal information of the user to prevent illegal access to such personal information data, ensure that personnel having access to the personal information data comply with the regulations of the relevant laws and regulations, and ensure the personal information of the user. Once these user personal information data are no longer needed, the risk should be minimized by limiting or even prohibiting the data collection and/or deletion.
User privacy is protected, when applicable, by de-identifying the data, including in some related applications, such as by removing a particular identifier (e.g., date of birth, etc.), controlling the amount or specificity of stored data (e.g., collecting location data at a city level rather than at a specific address level), controlling how the data is stored, and/or other methods.

Claims (13)

1. A method of software upgrade, comprising:
setting proxy nodes in the available areas of different partitions, and setting copies of the proxy nodes in the different available areas;
after the proxy node installs the new version of software, the proxy node installs the new version of software and the proxy node installs the old version of software, and receives and processes the read-write request of the available area;
and after the leading copy of the available area is migrated to the proxy node for installing the new version of software, upgrading the proxy node for installing the old version of software to the new version of software.
2. The method of software upgrade according to claim 1, wherein the setting copies of proxy nodes in different available areas comprises:
a copy of a topic is taken as a copy of a proxy node, and the copy of the proxy node is arranged in different available areas.
3. The method for upgrading software according to claim 1, wherein after the proxy node installs the new version of software, the proxy node installing the new version of software and the proxy node installing the old version of software receive and process the read-write request of the available area, and the method comprises:
copying an installation file of new version software to install the new version software in a proxy node;
and the proxy node for installing the new version of software and the proxy node for installing the old version of software receive and process the read-write request of the available area.
4. The method of software upgrade according to claim 1, wherein said migrating the leading copy of the available area to the proxy node where the new version of software is installed comprises:
searching the proxy node for installing the new version of software;
and establishing a migration file according to the identification of the proxy node for installing the new version of software so as to migrate the leading copy of the available area to the proxy node for installing the new version of software.
5. The method of software upgrade according to claim 1, wherein said migrating the leading copy of the available area to the proxy node where the new version of software is installed comprises:
and determining that all the leading copies of the available areas are migrated to the proxy node for installing the new software based on the identification of the leading copies of the available areas and the identification of the leading copies migrated to the proxy node for installing the new software.
6. The method of software upgrade according to claim 1, wherein said upgrading said proxy node installing old version software to said new version software comprises:
copying an installation file of new version software to install the new version software on a proxy node for installing old version software;
and after the proxy node for installing the old version of software is updated to the new version of software, installing the new version of software on the next proxy node for installing the old version of software.
7. The method of software upgrade according to claim 1, wherein said upgrading said proxy node installing old version software to said new version software comprises:
closing the proxy node for installing the old version of software, and upgrading the proxy node for installing the old version of software in different available areas to the new version of software.
8. The method of claim 1, wherein prior to receiving and processing the read-write request for the usable area, comprising:
and distributing the read-write requests of the available area to the proxy node for loading new version software or the proxy node for loading old version software according to the number of the read-write requests currently processed by the proxy node so as to ensure the load balance of the proxy node.
9. The method of software upgrade according to claim 1, wherein the setting copies of proxy nodes in different available areas comprises:
3 copies of the proxy node are set in one available area.
10. An apparatus for upgrading software, comprising:
the setting module is used for setting the proxy nodes in the available areas of different partitions and setting copies of the proxy nodes in the different available areas;
the processing module is used for installing the proxy node of the new version of software and the proxy node of the old version of software after the proxy node installs the new version of software, and receiving and processing the read-write request of the available area;
and the upgrading module is used for upgrading the proxy node for installing the old version of software to the new version of software after the leading copy of the available area is migrated to the proxy node for installing the new version of software.
11. A software-upgraded electronic device, comprising:
one or more processors;
storage means for storing one or more programs,
when executed by the one or more processors, causes the one or more processors to implement the method of any of claims 1-9.
12. A computer readable medium, on which a computer program is stored, characterized in that the program, when being executed by a processor, implements the method according to any of claims 1-9.
13. A computer program product comprising a computer program which, when executed by a processor, implements the method according to any one of claims 1-9.
CN202311146314.8A 2023-09-06 2023-09-06 Method, apparatus, device and computer readable medium for software upgrade Pending CN117193817A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202311146314.8A CN117193817A (en) 2023-09-06 2023-09-06 Method, apparatus, device and computer readable medium for software upgrade

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202311146314.8A CN117193817A (en) 2023-09-06 2023-09-06 Method, apparatus, device and computer readable medium for software upgrade

Publications (1)

Publication Number Publication Date
CN117193817A true CN117193817A (en) 2023-12-08

Family

ID=88993620

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202311146314.8A Pending CN117193817A (en) 2023-09-06 2023-09-06 Method, apparatus, device and computer readable medium for software upgrade

Country Status (1)

Country Link
CN (1) CN117193817A (en)

Similar Documents

Publication Publication Date Title
US11425194B1 (en) Dynamically modifying a cluster of computing nodes used for distributed execution of a program
US9276987B1 (en) Identifying nodes already storing indicated input data to perform distributed execution of an indicated program in a node cluster
US10891122B2 (en) Rolling upgrade of a distributed application
US8060892B2 (en) Executing business logic extensions on a client computing system
US8943496B2 (en) Providing a hosted appliance and migrating the appliance to an on-premise environment
EP3944082A1 (en) Extending the kubernetes api in-process
CN109245908B (en) Method and device for switching master cluster and slave cluster
US20150058461A1 (en) Image management in cloud environments
US20150178184A1 (en) Test management using distributed computing
CN110750592A (en) Data synchronization method, device and terminal equipment
US20150355892A1 (en) Resources provisioning based on a set of discrete configurations
US20210176122A1 (en) Pre-scheduling for cloud resource provisioning
US10474696B2 (en) Replication groups for content libraries
US11531526B1 (en) Creating portable serverless applications
US10466991B1 (en) Computing instance software package installation
US8930967B2 (en) Shared versioned workload partitions
CN113128197A (en) Method and device for managing application production versions
US20200272453A1 (en) Real-Time Version Controller
CN117193817A (en) Method, apparatus, device and computer readable medium for software upgrade
US11336518B2 (en) Staging configuration changes with deployment freeze options
US11513833B1 (en) Event listener interface for container-based execution of serverless functions
CN114827177A (en) Deployment method and device of distributed file system and electronic equipment
US10684840B1 (en) Software package installation and monitoring
CN113761075A (en) Method, device, equipment and computer readable medium for switching databases
US10824476B1 (en) Multi-homed computing instance processes

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