CN112540783A - Client upgrading method and device, storage medium and electronic equipment - Google Patents

Client upgrading method and device, storage medium and electronic equipment Download PDF

Info

Publication number
CN112540783A
CN112540783A CN202011511318.8A CN202011511318A CN112540783A CN 112540783 A CN112540783 A CN 112540783A CN 202011511318 A CN202011511318 A CN 202011511318A CN 112540783 A CN112540783 A CN 112540783A
Authority
CN
China
Prior art keywords
client
information
update
server
updating
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.)
Granted
Application number
CN202011511318.8A
Other languages
Chinese (zh)
Other versions
CN112540783B (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.)
Aisino Software Technology Co ltd
Original Assignee
Aisino Software 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 Aisino Software Technology Co ltd filed Critical Aisino Software Technology Co ltd
Priority to CN202011511318.8A priority Critical patent/CN112540783B/en
Publication of CN112540783A publication Critical patent/CN112540783A/en
Application granted granted Critical
Publication of CN112540783B publication Critical patent/CN112540783B/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
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/70Software maintenance or management
    • G06F8/71Version control; Configuration management

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)
  • Information Transfer Between Computers (AREA)

Abstract

The utility model relates to a client upgrading method, device, storage medium and electronic equipment, belonging to the information technology field, wherein the method is applied to a server, the server is connected with the client through an mqtt protocol, the method comprises the following steps: inquiring version configuration information in a database, and caching the version configuration information in a Redis cache; receiving an update request sent by the client, and issuing corresponding target update information in the version configuration information according to the update request, wherein the target update information is used for updating the client version by the client, and the update request is sent to the server according to local information of the client when the client monitors that the topic identifier in a long connection channel is changed based on the mqtt protocol long connection; the version configuration information includes one or more of the update information of the middle station client, the uniform update information and the test point update information, and the test point update information includes update information corresponding to different regions.

Description

Client upgrading method and device, storage medium and electronic equipment
Technical Field
The present disclosure relates to the field of information technologies, and in particular, to a method and an apparatus for upgrading a client, a storage medium, and an electronic device.
Background
For a long time, there is a dispute between using client/server and using browser/server structure on the basis of the type selection of technical architecture, in these disputes, the program maintainability of c/s structure is poor, the arrangement is difficult, the upgrading is inconvenient and the maintenance cost is high, which is a very important factor, many enterprise users abandon using c/s for this reason, but some specific services still need the c/s structure to realize their functions, the deployment and automatic upgrading of the client needs to be solved, because the deployment is very simple, only downloading and installing are needed, but the difficulty lies in how to quickly and effectively upgrade the client becomes the first problem when a new version is released.
Disclosure of Invention
In order to solve technical problems in the related art, the present disclosure provides a client upgrading method, device, storage medium, and electronic device.
The first aspect of the present disclosure provides a client upgrading method, where the method is applied to a server, and the server and a client are connected by an mqtt protocol, where the method includes:
inquiring version configuration information in a database, and caching the version configuration information in a Redis cache;
receiving an update request sent by the client, and issuing corresponding target update information in the version configuration information according to the update request, wherein the target update information is used for updating the client version by the client, and the update request is sent to the server according to local information of the client when the client monitors that the topic identifier in the long connection channel is changed based on the mqtt protocol long connection;
the version configuration information comprises one or more of the update information of the middle station client, the uniform update information and the test point update information, and the test point update information comprises update information corresponding to different regions.
Optionally, the issuing, according to the update request, the corresponding target update information in the version configuration information includes:
inquiring whether the update information of the middle station client exists in the Redis cache or not under the condition that the update request is the update request of the middle station client;
under the condition that update information of a middle station client exists in the Redis cache, the update information of the middle station client is sent to the client;
and under the condition that the update information of the middle station client does not exist in the Redis cache, inquiring the version information of the local information corresponding to the client in the database, and caching the version information serving as the update information of the middle station client into the Redis cache.
Optionally, the issuing, according to the update request, the corresponding target update information in the version configuration information includes:
under the condition that the updating request is a uniform updating request, inquiring whether uniform updating information exists in the Redis cache or not;
under the condition that unified updating information exists in the Redis cache, the unified updating information is sent to the client;
and under the condition that the unified updating information does not exist in the Redis cache, caching the updating information configured as the default version in the database as the unified updating information into the Redis cache and sending the unified updating information to the client.
Optionally, the issuing, according to the update request, the corresponding target update information in the version configuration information includes:
determining a target upgrading version according to the area code and/or the tax number carried in the test point updating request under the condition that the updating request is the test point updating request;
and sending the update information corresponding to the target upgrade version in the trial point update information to the client.
A second aspect of the present disclosure provides a client upgrading method, which is applied to a client that is connected to a server via an mqtt protocol, and the method includes:
monitoring whether the server receives new version configuration information in real time based on the mqtt protocol long connection, wherein when a topic identifier in a long connection channel between the client and the server is changed, the server is indicated to receive the new version configuration information;
under the condition that the server is monitored to receive new version configuration information, an updating request is sent to the server according to the local information of the client, and the updating request is used for requesting the server to send corresponding updating information in the version configuration information to the client;
receiving the updating information sent by the server, and updating the version of the client according to the updating information;
the version configuration information comprises one or more of the update information of the middle station client, the uniform update information and the test point update information, and the test point update information comprises update information corresponding to different regions.
Optionally, the sending an update request to the server according to the local information of the client includes:
under the condition that the local information of the client represents that the client is a middle station client, sending a middle station client updating request to the server;
sending a unified updating request to the server under the condition that the local information of the client represents that the client is a unified client which does not distinguish test points;
and under the condition that the local information of the client represents that the client is a client for distinguishing test points, sending a test point updating request to the server, wherein the test point updating request comprises a regional code and/or a tax number.
A third aspect of the present disclosure provides a client upgrading apparatus as a part of a server, the server being connected to a client by an mqtt protocol, the apparatus comprising:
the query module is used for querying the version configuration information in the database and caching the version configuration information in a Redis cache;
the update module is used for receiving an update request sent by the client, issuing corresponding target update information in the version configuration information according to the update request, wherein the target update information is used for updating the client version by the client, and the update request is sent to the server according to local information of the client when the client monitors that the topic identifier in the long connection channel is changed based on the mqtt protocol long connection;
the version configuration information comprises one or more of the update information of the middle station client, the uniform update information and the test point update information, and the test point update information comprises update information corresponding to different regions.
A fourth aspect of the present disclosure provides a client upgrading apparatus, which is a part of a client connected to a server via an mqtt protocol, the apparatus including:
the monitoring module is used for monitoring whether the server receives new version configuration information in real time based on the mqtt protocol long connection, wherein when a topic identifier in a long connection channel between the client and the server is changed, the server is indicated to receive the new version configuration information;
the request module is used for sending an update request to the server according to the local information of the client under the condition that the server is monitored to receive new version configuration information, wherein the update request is used for requesting the server to send corresponding update information in the version configuration information to the client;
the updating module is used for receiving the updating information sent by the server and updating the version of the client according to the updating information;
the version configuration information comprises one or more of the update information of the middle station client, the uniform update information and the test point update information, and the test point update information comprises update information corresponding to different regions.
A fifth aspect of the present disclosure provides a computer readable storage medium having stored thereon a computer program which, when executed by a processor, provides the steps of the method of any one of the first or second aspects of the present disclosure.
A fifth aspect of the present disclosure provides an electronic device, comprising:
a memory having a computer program stored thereon;
a processor for executing the computer program in the memory to implement the steps of the method of any one of the first or second aspects of the disclosure.
According to the technical scheme, the instant communication between the client and the server is kept through long connection of an mqtt protocol, version updating can be determined for topoic identification updating, so that the client sends an updating request according to local information of the client, the server can issue the updating information according to different requests and different request parameters aiming at different clients and different service requirements, the client can update immediately according to different service requirements, configuration is more flexible through a Redis technology, and more complex requirements can be met.
Additional features and advantages of the disclosure will be set forth in the detailed description which follows.
Drawings
The accompanying drawings, which are included to provide a further understanding of the disclosure and are incorporated in and constitute a part of this specification, illustrate embodiments of the disclosure and together with the description serve to explain the disclosure without limiting the disclosure. In the drawings:
FIG. 1 is a flow diagram illustrating a method for client upgrade in accordance with an exemplary embodiment.
FIG. 2 is another flow diagram illustrating a method for client upgrade in accordance with an exemplary embodiment.
FIG. 3 is a block diagram illustrating a client upgrade apparatus according to an example embodiment.
FIG. 4 is another block diagram illustrating a client upgrade apparatus according to an example embodiment.
FIG. 5 is a block diagram illustrating an electronic device in accordance with an example embodiment.
FIG. 6 is another block diagram illustrating an electronic device in accordance with an exemplary embodiment.
Detailed Description
The following detailed description of specific embodiments of the present disclosure is provided in connection with the accompanying drawings. It should be understood that the detailed description and specific examples, while indicating the present disclosure, are given by way of illustration and explanation only, not limitation.
In order to enable those skilled in the art to quickly understand the improvement of the technical solution provided by the embodiments of the present disclosure compared with the prior art, an application scenario of the present disclosure in specific implementation is first described below. Because different client users have different business requirements, the users can install clients of different versions according to the business requirements, for example, some tax payment organizations of the middlebox business need all functions of the software, namely, the clients of the versions including all functions can be installed, and some tax payment branch organizations in cities and counties only need partial functions of the software, and only the clients of the versions including the partial functions can be installed. Further, in order to avoid unexpected damage caused by client upgrading but a vulnerability exists in the client version, trial updating can be performed on clients in different areas based on division of regions or tax numbers, and further comprehensive updating is performed when the version is determined to have no security vulnerability.
Fig. 1 is a flowchart illustrating a client upgrading method according to an exemplary embodiment, where the method is applied to a server, and the server and a client are connected via a mqtt (Message Queuing Telemetry Transport) protocol long port, as shown in fig. 1, where the method includes the following steps:
s101, inquiring version configuration information in a database, and caching the version configuration information in a Remote Dictionary service (Redis) cache.
Wherein the database may be a MySQL relational database.
S102, receiving an update request sent by the client, and issuing corresponding target update information in the version configuration information according to the update request, wherein the target update information is used for updating the client version by the client.
And the updating request is sent to the server according to the local information of the client when the client monitors that the topic identifier in the long connection channel is changed based on the mqtt protocol.
The version configuration information comprises one or more of the update information of the middle station client, the uniform update information and the test point update information, and the test point update information comprises update information corresponding to different regions.
In a specific implementation, the server may determine what client the client sending the request is according to a request mode of the update request and whether the update request has a parameter, for example, when the update request is a get request, the update request may be determined to be a middle client update request, when the update request is a post request without a parameter, the update request may be determined to be a uniform update request, and when the update request is a post request with a parameter, the update request may be determined to be a trial update request. The present disclosure is not limited with respect to how the server determines what client the requesting client is based on the request mode of the update request and whether or not parameters are included.
In the embodiment of the disclosure, an mqtt protocol long connection is adopted to maintain instant communication between a client and a server, version update can be determined for topoic identifier update by monitoring in time, so that the client sends an update request according to local information of the client, and the server can issue update information according to different requests and different request parameters aiming at different clients and different service requirements, so that the client can perform instant update according to different service requirements, and configuration is more flexible through a Redis technology, and more complex requirements can be met.
In some optional embodiments, the issuing, according to the update request, the target update information corresponding to the version configuration information includes:
inquiring whether the update information of the middle station client exists in the Redis cache or not under the condition that the update request is the update request of the middle station client;
under the condition that update information of a middle station client exists in the Redis cache, the update information of the middle station client is sent to the client;
and under the condition that the update information of the middle station client does not exist in the Redis cache, inquiring the version information of the local information corresponding to the client in a database, and caching the version information serving as the update information of the middle station client into the Redis cache.
By adopting the scheme, the server can respond to the update request of the middle station client and return the update information to update the client, if the relevant update information is not cached in the Redis cache, the version of the current client is taken as the latest version, the update information of the version is inquired from the database and cached in the Redis cache, so that other clients can more quickly return the update information when calling the interface.
In some other optional embodiments, the issuing, according to the update request, the target update information corresponding to the version configuration information includes:
under the condition that the updating request is a uniform updating request, inquiring whether uniform updating information exists in the Redis cache or not;
under the condition that unified updating information exists in the Redis cache, the unified updating information is sent to the client;
and under the condition that the unified updating information does not exist in the Redis cache, sending the updating information of the middle station client configured as the default version or the test point updating information configured as the default version in the Redis cache to the client.
When the scheme is specifically implemented, whether unified updating information exists can be determined by inquiring whether information with key of clientUpdate: defaultntRn in the redis exists, and when the unified updating information does not exist, information with field name of defaultVersion of 1 in the database is inquired, namely updating information configured as a default version is used, and the updating information is used as unified updating information. By adopting the scheme, when the update request is that the client which does not distinguish the test point needs to be updated, the update information can be returned so that the client can be updated, the configuration is more flexible through the Redis technology, and the query efficiency is improved.
In other optional embodiments, the issuing, according to the update request, the target update information corresponding to the version configuration information includes:
determining a target upgrading version according to the area code and/or the tax number carried in the test point updating request under the condition that the updating request is the test point updating request;
and sending the update information corresponding to the target upgrade version in the trial point update information to the client.
By adopting the scheme, the updating information can be sent according to the parameters uploaded by the client and the requirements of the client, so that the clients in different test point areas can be updated according to the preconfigured information.
Fig. 2 is another flowchart of a client upgrading method applied to a client connected with a server via an mqtt protocol according to an exemplary embodiment, and the method includes:
s201, monitoring whether the server receives new version configuration information in real time based on the mqtt protocol long connection.
When a topic identifier in a long connecting channel between the client and the server is changed, indicating that the server receives new version configuration information;
s202, under the condition that the server is monitored to receive the new version configuration information, an updating request is sent to the server according to the local information of the client.
The update request is used for requesting the server to send corresponding update information in the version configuration information to the client.
S203, receiving the updating information sent by the server, and updating the client version according to the updating information.
The version configuration information comprises one or more of the update information of the middle station client, the uniform update information and the test point update information, and the test point update information comprises update information corresponding to different regions.
In the embodiment of the disclosure, an mqtt protocol long connection is adopted to maintain instant communication between a client and a server, version update can be determined for topoic identifier update by monitoring in time, so that the client sends an update request according to local information of the client, and the server can issue update information according to different requests and different request parameters aiming at different clients and different service requirements, so that the client can perform instant update according to different service requirements, and configuration is more flexible through a Redis technology, and more complex requirements can be met.
Optionally, the sending an update request to the server according to the local information of the client includes:
under the condition that the local information of the client represents that the client is a middle station client, sending a middle station client updating request to the server;
sending a unified updating request to the server under the condition that the local information of the client represents that the client is a unified client which does not distinguish test points;
and under the condition that the local information of the client represents that the client is a client for distinguishing test points, sending a test point updating request to the server, wherein the test point updating request comprises a regional code and/or a tax number.
By adopting the scheme, the client can send different updating requests to obtain different updating information according to different client information, so that the client can conveniently perform corresponding updating according to different service requirements.
Fig. 3 is a block diagram illustrating a client upgrade apparatus 30 according to an exemplary embodiment, where the client upgrade apparatus 30 may be a part of a server, and the server and the client are connected by an mqtt protocol, and as shown in fig. 3, the apparatus 30 includes:
the query module 31 is configured to query version configuration information in the database, and cache the version configuration information in the Redis cache.
An update module 32, configured to receive an update request sent by the client, and issue corresponding target update information in the version configuration information according to the update request, where the target update information is used by the client to update the client version, and the update request is sent to the server according to local information of the client when the client monitors that a topic identifier in a long connection channel changes based on the mqtt protocol.
The version configuration information comprises one or more of the update information of the middle station client, the uniform update information and the test point update information, and the test point update information comprises update information corresponding to different regions.
Optionally, the update module 32 includes:
and the first query submodule is used for querying whether the update information of the middle station client exists in the Redis cache or not under the condition that the update request is the update request of the middle station client.
And the first sending submodule is used for sending the update information of the middle station client to the client under the condition that the update information of the middle station client exists in the Redis cache.
And the cache submodule is used for inquiring version information of local information corresponding to the client in the database under the condition that the update information of the middle station client does not exist in the Redis cache, and caching the version information serving as the update information of the middle station client into the Redis cache.
Optionally, the update module 32 includes:
and the second query submodule is used for querying whether unified update information exists in the Redis cache or not under the condition that the update request is a unified update request.
And the second sending submodule is used for sending the unified updating information to the client under the condition that the unified updating information exists in the Redis cache.
And the second sending submodule is used for caching the update information configured as the default version in the database as the uniform update information to the Redis and sending the uniform update information to the client under the condition that the uniform update information does not exist in the Redis cache.
Optionally, the update module 32 includes:
and the determining submodule is used for determining a target upgrading version according to the area code and/or the tax carried in the test point updating request under the condition that the updating request is the test point updating request.
And the third sending submodule is used for sending the update information corresponding to the target upgrade version in the test point update information to the client.
In the embodiment of the disclosure, an mqtt protocol long connection is adopted to maintain instant communication between a client and a server, version update can be determined for topoic identifier update by monitoring in time, so that the client sends an update request according to local information of the client, and the server can issue update information according to different requests and different request parameters aiming at different clients and different service requirements, so that the client can perform instant update according to different service requirements, and configuration is more flexible through a Redis technology, and more complex requirements can be met.
Fig. 4 is a block diagram illustrating a client upgrade apparatus 40 according to an exemplary embodiment, where the apparatus 40 may be part of a client that connects to a server via an mqtt protocol, and the apparatus 40 includes:
a monitoring module 41, configured to monitor, in real time, whether the server receives new version configuration information based on the mqtt protocol long connection, where when a topic identifier in a long connection channel between the client and the server changes, it indicates that the server receives the new version configuration information.
A request module 42, configured to send, according to the local information of the client, an update request to the server when it is monitored that the server receives new version configuration information, where the update request is used to request the server to send corresponding update information in the version configuration information to the client.
And an updating module 43, configured to receive the update information sent by the server, and update the client version according to the update information.
The version configuration information comprises one or more of the update information of the middle station client, the uniform update information and the test point update information, and the test point update information comprises update information corresponding to different regions.
Optionally, the request module 42 includes:
and the first request submodule is used for sending a middle station client updating request to the server under the condition that the local information of the client represents that the client is the middle station client.
And the second request submodule is used for sending a unified updating request to the server under the condition that the local information of the client represents that the client is a unified client which does not distinguish test points.
And the third request submodule is used for sending a test point updating request to the server under the condition that the local information of the client represents that the client is a client for distinguishing test points, wherein the test point updating request comprises a regional code and/or a tax number.
In the embodiment of the disclosure, an mqtt protocol long connection is adopted to maintain instant communication between a client and a server, version update can be determined for topoic identifier update by monitoring in time, so that the client sends an update request according to local information of the client, and the server can issue update information according to different requests and different request parameters aiming at different clients and different service requirements, so that the client can perform instant update according to different service requirements, and configuration is more flexible through a Redis technology, and more complex requirements can be met.
With regard to the apparatus in the above-described embodiment, the specific manner in which each module performs the operation has been described in detail in the embodiment related to the method, and will not be elaborated here.
Fig. 5 illustrates a block diagram of an electronic device 50 in accordance with an exemplary embodiment. As shown in fig. 5, the electronic device 50 may include: a processor 51 and a memory 52. The electronic device 50 may also include one or more of a multimedia component 53, an input/output (I/O) interface 54, and a communications component 55.
The processor 51 is configured to control the overall operation of the electronic device 50, so as to complete all or part of the steps in the client upgrading method. The memory 52 is used to store various types of data to support operations at the electronic device 50, such as instructions for any application or method operating on the electronic device 50, as well as application-related data, such as client version information, client files, tax stamps, and the like. The Memory 52 may be implemented by any type of volatile or non-volatile Memory device or combination thereof, such as Static Random Access Memory (SRAM), Electrically Erasable Programmable Read-Only Memory (EEPROM), Erasable Programmable Read-Only Memory (EPROM), Programmable Read-Only Memory (PROM), Read-Only Memory (ROM), magnetic Memory, flash Memory, magnetic disk or optical disk. The multimedia components 53 may include a screen and an audio component. Wherein the screen may be, for example, a touch screen and the audio component is used for outputting and/or inputting audio signals. For example, the audio component may include a microphone for receiving external audio signals. The received audio signal may further be stored in the memory 52 or transmitted through the communication component 55. The audio assembly also includes at least one speaker for outputting audio signals. The I/O interface 54 provides an interface between the processor 51 and other interface modules, such as a keyboard, mouse, buttons, etc. These buttons may be virtual buttons or physical buttons. The communication component 55 is used for wired or wireless communication between the electronic device 50 and other devices. Wireless Communication, such as Wi-Fi, bluetooth, Near Field Communication (NFC), 2G, 3G, 4G, NB-IOT, eMTC, or other 5G, etc., or a combination of one or more of them, which is not limited herein. The corresponding communication component 55 may thus comprise: Wi-Fi module, Bluetooth module, NFC module, etc.
In an exemplary embodiment, the electronic Device 50 may be implemented by one or more Application Specific Integrated Circuits (ASICs), Digital Signal Processors (DSPs), Digital Signal Processing Devices (DSPDs), Programmable Logic Devices (PLDs), Field Programmable Gate Arrays (FPGAs), controllers, microcontrollers, microprocessors, or other electronic components for performing the above-described client upgrade method.
In another exemplary embodiment, a computer readable storage medium comprising program instructions which, when executed by a processor, implement the steps of the client upgrade method described above is also provided. For example, the computer readable storage medium may be the memory 52 described above including program instructions executable by the processor 51 of the electronic device 50 to perform the client upgrade method described above.
Fig. 6 is a block diagram illustrating an electronic device 60 according to an example embodiment. For example, the electronic device 60 may be provided as a server. Referring to fig. 6, the electronic device 60 comprises a processor 61, which may be one or more in number, and a memory 62 for storing computer programs executable by the processor 61. The computer program stored in memory 62 may include one or more modules that each correspond to a set of instructions. Further, the processor 61 may be configured to execute the computer program to perform the above-described client upgrade method.
Additionally, electronic device 60 may also include a power component 63 and a communication component 64, where power component 63 may be configured to perform power management of electronic device 60, and where communication component 64 may be configured to enable communication, e.g., wired or wireless communication, of electronic device 60. In addition, the electronic device 60 may also include an input/output (I/O) interface 65. The electronic device 60 may operate based on an operating system, such as Windows Server, stored in the memory 62TM,Mac OS XTM,UnixTM,LinuxTMAnd so on.
In another exemplary embodiment, a computer readable storage medium comprising program instructions which, when executed by a processor, implement the steps of the client upgrade method described above is also provided. For example, the computer readable storage medium may be the memory 62 described above including program instructions executable by the processor 61 of the electronic device 60 to perform the client upgrade method described above.
In another exemplary embodiment, a computer program product is also provided, which comprises a computer program executable by a programmable apparatus, the computer program having code portions for performing the above-mentioned client upgrade method when executed by the programmable apparatus.
The preferred embodiments of the present disclosure are described in detail with reference to the accompanying drawings, however, the present disclosure is not limited to the specific details of the above embodiments, and various simple modifications may be made to the technical solution of the present disclosure within the technical idea of the present disclosure, and these simple modifications all belong to the protection scope of the present disclosure.
It should be noted that, in the foregoing embodiments, various features described in the above embodiments may be combined in any suitable manner, and in order to avoid unnecessary repetition, various combinations that are possible in the present disclosure are not described again.
In addition, any combination of various embodiments of the present disclosure may be made, and the same should be considered as the disclosure of the present disclosure, as long as it does not depart from the spirit of the present disclosure.

Claims (10)

1. A client upgrading method is applied to a server, the server and a client are connected through an mqtt protocol, and the method comprises the following steps:
inquiring version configuration information in a database, and caching the version configuration information in a Redis cache;
receiving an update request sent by the client, and issuing corresponding target update information in the version configuration information according to the update request, wherein the target update information is used for updating the client version by the client, and the update request is sent to the server according to local information of the client when the client monitors that the topic identifier in the long connection channel is changed based on the mqtt protocol long connection;
the version configuration information comprises one or more of the update information of the middle station client, the uniform update information and the test point update information, and the test point update information comprises update information corresponding to different regions.
2. The method of claim 1, wherein the issuing the corresponding target update information in the version configuration information according to the update request comprises:
inquiring whether the update information of the middle station client exists in the Redis cache or not under the condition that the update request is the update request of the middle station client;
under the condition that update information of a middle station client exists in the Redis cache, the update information of the middle station client is sent to the client;
and under the condition that the update information of the middle station client does not exist in the Redis cache, inquiring the version information of the local information corresponding to the client in the database, and caching the version information serving as the update information of the middle station client into the Redis cache.
3. The method of claim 1, wherein the issuing the corresponding target update information in the version configuration information according to the update request comprises:
under the condition that the updating request is a uniform updating request, inquiring whether uniform updating information exists in the Redis cache or not;
under the condition that unified updating information exists in the Redis cache, the unified updating information is sent to the client;
and under the condition that the unified updating information does not exist in the Redis cache, caching the updating information configured as the default version in the database as the unified updating information into the Redis cache and sending the unified updating information to the client.
4. The method of claim 1, wherein the issuing the corresponding target update information in the version configuration information according to the update request comprises:
determining a target upgrading version according to the area code and/or the tax number carried in the test point updating request under the condition that the updating request is the test point updating request;
and sending the update information corresponding to the target upgrade version in the trial point update information to the client.
5. A client upgrading method is applied to a client, the client is connected with a server through an mqtt protocol, and the method comprises the following steps:
monitoring whether the server receives new version configuration information in real time based on the mqtt protocol long connection, wherein when a topic identifier in a long connection channel between the client and the server is changed, the server is indicated to receive the new version configuration information;
under the condition that the server is monitored to receive new version configuration information, an updating request is sent to the server according to the local information of the client, and the updating request is used for requesting the server to send corresponding updating information in the version configuration information to the client;
receiving the updating information sent by the server, and updating the version of the client according to the updating information;
the version configuration information comprises one or more of the update information of the middle station client, the uniform update information and the test point update information, and the test point update information comprises update information corresponding to different regions.
6. The method of claim 5, wherein sending an update request to the server according to the client's local information comprises:
under the condition that the local information of the client represents that the client is a middle station client, sending a middle station client updating request to the server;
sending a unified updating request to the server under the condition that the local information of the client represents that the client is a unified client which does not distinguish test points;
and under the condition that the local information of the client represents that the client is a client for distinguishing test points, sending a test point updating request to the server, wherein the test point updating request comprises a regional code and/or a tax number.
7. A client upgrade apparatus, the apparatus being part of a server, the server being connected to a client via an mqtt protocol, the apparatus comprising:
the query module is used for querying the version configuration information in the database and caching the version configuration information in a Redis cache;
the update module is used for receiving an update request sent by the client, issuing corresponding target update information in the version configuration information according to the update request, wherein the target update information is used for updating the client version by the client, and the update request is sent to the server according to local information of the client when the client monitors that the topic identifier in the long connection channel is changed based on the mqtt protocol long connection;
the version configuration information comprises one or more of the update information of the middle station client, the uniform update information and the test point update information, and the test point update information comprises update information corresponding to different regions.
8. A client upgrade apparatus, the apparatus being part of a client, the client being connected to a server via an mqtt protocol, the apparatus comprising:
the monitoring module is used for monitoring whether the server receives new version configuration information in real time based on the mqtt protocol long connection, wherein when a topic identifier in a long connection channel between the client and the server is changed, the server is indicated to receive the new version configuration information;
the request module is used for sending an update request to the server according to the local information of the client under the condition that the server is monitored to receive new version configuration information, wherein the update request is used for requesting the server to send corresponding update information in the version configuration information to the client;
the updating module is used for receiving the updating information sent by the server and updating the version of the client according to the updating information;
the version configuration information comprises one or more of the update information of the middle station client, the uniform update information and the test point update information, and the test point update information comprises update information corresponding to different regions.
9. A computer-readable storage medium, on which a computer program is stored which, when being executed by a processor, carries out the steps of the method according to any one of claims 1 to 6.
10. An electronic device, comprising:
a memory having a computer program stored thereon;
a processor for executing the computer program in the memory to carry out the steps of the method of any one of claims 1 to 6.
CN202011511318.8A 2020-12-18 2020-12-18 Client upgrading method and device, storage medium and electronic equipment Active CN112540783B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011511318.8A CN112540783B (en) 2020-12-18 2020-12-18 Client upgrading method and device, storage medium and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011511318.8A CN112540783B (en) 2020-12-18 2020-12-18 Client upgrading method and device, storage medium and electronic equipment

Publications (2)

Publication Number Publication Date
CN112540783A true CN112540783A (en) 2021-03-23
CN112540783B CN112540783B (en) 2024-05-24

Family

ID=75019270

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011511318.8A Active CN112540783B (en) 2020-12-18 2020-12-18 Client upgrading method and device, storage medium and electronic equipment

Country Status (1)

Country Link
CN (1) CN112540783B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114025207A (en) * 2021-12-07 2022-02-08 贵阳朗玛视讯科技有限公司 Method and device for starting APK plug-in based on IPTV system
CN115914329A (en) * 2021-09-28 2023-04-04 中国联合网络通信集团有限公司 Information pushing method and device, electronic equipment and readable storage medium

Citations (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102868731A (en) * 2012-08-27 2013-01-09 济南大学 Method and device for software online updating and downloading acceleration
CN106406943A (en) * 2016-09-06 2017-02-15 厦门蓝斯通信股份有限公司 Customized upgrading method and system for clients of different versions
CN106790629A (en) * 2017-01-03 2017-05-31 努比亚技术有限公司 Data synchronization unit and its realize the method for data syn-chronization, client access system
KR101818977B1 (en) * 2017-06-27 2018-01-16 주식회사 인터엠 Method of providing batch process of software upgrade for pluralities of heterogeneous broadcasting equipments
CN107608701A (en) * 2017-10-20 2018-01-19 深圳市道通科技股份有限公司 A kind of method and apparatus of firmware updating
CN109495532A (en) * 2017-09-13 2019-03-19 北京京东尚科信息技术有限公司 Client update method and device
CN110908683A (en) * 2019-10-22 2020-03-24 深圳市广和通无线通信软件有限公司 Software system upgrading method and device of hardware module, storage medium and terminal
CN111143383A (en) * 2019-12-20 2020-05-12 五八有限公司 Data updating method and device, electronic equipment and storage medium
CN111147585A (en) * 2019-12-27 2020-05-12 南京甄视智能科技有限公司 Equipment upgrading method, device, storage medium and system
CN111556488A (en) * 2020-04-13 2020-08-18 易视腾科技股份有限公司 OTA (over the air) upgrading method and system for terminal equipment
CN111949302A (en) * 2020-09-18 2020-11-17 苏州浪潮智能科技有限公司 Method, system and equipment for updating instantaneity of industrial computer management system

Patent Citations (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102868731A (en) * 2012-08-27 2013-01-09 济南大学 Method and device for software online updating and downloading acceleration
CN106406943A (en) * 2016-09-06 2017-02-15 厦门蓝斯通信股份有限公司 Customized upgrading method and system for clients of different versions
CN106790629A (en) * 2017-01-03 2017-05-31 努比亚技术有限公司 Data synchronization unit and its realize the method for data syn-chronization, client access system
KR101818977B1 (en) * 2017-06-27 2018-01-16 주식회사 인터엠 Method of providing batch process of software upgrade for pluralities of heterogeneous broadcasting equipments
CN109495532A (en) * 2017-09-13 2019-03-19 北京京东尚科信息技术有限公司 Client update method and device
CN107608701A (en) * 2017-10-20 2018-01-19 深圳市道通科技股份有限公司 A kind of method and apparatus of firmware updating
CN110908683A (en) * 2019-10-22 2020-03-24 深圳市广和通无线通信软件有限公司 Software system upgrading method and device of hardware module, storage medium and terminal
CN111143383A (en) * 2019-12-20 2020-05-12 五八有限公司 Data updating method and device, electronic equipment and storage medium
CN111147585A (en) * 2019-12-27 2020-05-12 南京甄视智能科技有限公司 Equipment upgrading method, device, storage medium and system
CN111556488A (en) * 2020-04-13 2020-08-18 易视腾科技股份有限公司 OTA (over the air) upgrading method and system for terminal equipment
CN111949302A (en) * 2020-09-18 2020-11-17 苏州浪潮智能科技有限公司 Method, system and equipment for updating instantaneity of industrial computer management system

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
张程: "《分布式系统架构:技术栈详解与快速进阶》", 北京:机械工业出版社, pages: 204 - 206 *
曹鹏飞, 等: "云环境下实时消息推送服务构建研究", 《计算机技术与发展》, 31 March 2020 (2020-03-31), pages 204 - 208 *

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115914329A (en) * 2021-09-28 2023-04-04 中国联合网络通信集团有限公司 Information pushing method and device, electronic equipment and readable storage medium
CN114025207A (en) * 2021-12-07 2022-02-08 贵阳朗玛视讯科技有限公司 Method and device for starting APK plug-in based on IPTV system

Also Published As

Publication number Publication date
CN112540783B (en) 2024-05-24

Similar Documents

Publication Publication Date Title
CN109561118B (en) Software upgrading method, device, system, storage medium, electronic equipment and vehicle
CN106897086B (en) Method, device and system for upgrading robot operating system
US7870255B2 (en) Access control system and method for wireless application provisioning
US20110004676A1 (en) Virtual appliance deploying system
US20040098421A1 (en) Scheduling updates of electronic files
CN110855772B (en) Cross-device data storage method, system, device, server and medium
KR20050085836A (en) System to automatically process components on a device
CN112540783A (en) Client upgrading method and device, storage medium and electronic equipment
WO2018133297A1 (en) Advertisement display control method, terminal, and advertisement server
CN101895873A (en) Method for updating Java application of mobile terminal, server and mobile terminal
CN102932325A (en) Registered users of an application
CN105245567A (en) Method for processing update request and server system
CN111371615A (en) Online server, updating method and system of operation and maintenance tool and readable storage medium
CN111208974A (en) Component management method and device
CN113765950B (en) Internet of things equipment, server and software updating method
CN113010238A (en) Permission determination method, device and system for micro application call interface
US20090037493A1 (en) Method and device for updating an object with copyright attribute
CN110543312B (en) Application software installation method and device and server
CN101309490B (en) Support system, method and management platform implementing terminal management
CN113612735B (en) Secure storage system
CN115190064A (en) Method, device, system and storage medium for implementing client dynamic routing
KR100578029B1 (en) Interface architecture of subscriber information management system for mobile network system
JP4608964B2 (en) Module update program
JP6504000B2 (en) Data delivery control program, data delivery control method and data delivery apparatus
EP1909466B1 (en) Access control system and method for wireless application provisioning

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