CN118093316A - Application control method, system, equipment and medium - Google Patents

Application control method, system, equipment and medium Download PDF

Info

Publication number
CN118093316A
CN118093316A CN202410233107.4A CN202410233107A CN118093316A CN 118093316 A CN118093316 A CN 118093316A CN 202410233107 A CN202410233107 A CN 202410233107A CN 118093316 A CN118093316 A CN 118093316A
Authority
CN
China
Prior art keywords
application
monitoring
file
applications
control
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
CN202410233107.4A
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.)
BOE Technology Group Co Ltd
Original Assignee
BOE Technology Group 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 BOE Technology Group Co Ltd filed Critical BOE Technology Group Co Ltd
Priority to CN202410233107.4A priority Critical patent/CN118093316A/en
Publication of CN118093316A publication Critical patent/CN118093316A/en
Pending legal-status Critical Current

Links

Landscapes

  • Stored Programmes (AREA)

Abstract

The disclosure provides a control method, a system, equipment and a medium for an application, which belong to the technical field of the internet of things and aim to realize the application control of the cooperation of an equipment end and a cloud end, and reduce the calculation power consumption of the equipment end, wherein the method comprises the following steps: monitoring a plurality of applications on the equipment side based on the monitoring file; uploading monitoring results of a plurality of applications to a cloud; in response to arrival of a target event for a target application of a plurality of the applications, performing a first control on the target application based on the target event, the first control including at least one of launching the application, closing the application, uninstalling the application, and upgrading the application; the target event comprises receiving a control instruction sent by the cloud based on the monitoring result, and/or the device side monitors that the monitoring result of the target application meets a preset condition, wherein the preset condition is recorded in the monitoring file.

Description

Application control method, system, equipment and medium
Technical Field
The disclosure relates to the technical field of internet of things, and in particular relates to a control method, a system, equipment and a medium for application.
Background
In the internet of things technology, a simple application program is installed on the edge equipment so as to facilitate communication with the internet of things platform; wherein the edge device is capable of achieving simple control of the installed application.
Disclosure of Invention
Based on the background technology, the disclosure provides a control method, a system, equipment and a medium of an application.
In a first aspect of the present disclosure, a control method of an application is provided, and the method is applied to a device side, where the method includes:
Monitoring a plurality of applications on the equipment side based on a monitoring file, wherein the monitoring file is generated based on configuration information of the applications when the applications are installed, and the monitoring file is used for indicating the applications to be monitored and monitoring contents;
Uploading monitoring results of a plurality of applications to a cloud;
In response to arrival of a target event for a target application of a plurality of the applications, performing a first control on the target application based on the target event, the first control including at least one of launching the application, closing the application, uninstalling the application, and upgrading the application;
The target event comprises receiving a control instruction sent by the cloud based on the monitoring result, and/or the device side monitors that the monitoring result of the target application meets a preset condition, wherein the preset condition is recorded in the monitoring file.
Optionally, before the monitoring of the plurality of applications on the device side based on the monitoring file, the method further includes:
receiving installation information issued by the cloud, wherein the installation information comprises a storage path of at least one application file required by an application to be installed and configuration information corresponding to each application file;
Downloading the at least one application file from the storage path, and installing the at least one application file based on the configuration information.
Optionally, before the monitoring of the plurality of applications on the device side based on the monitoring file, the method further includes:
Receiving a packaging file issued by the cloud, wherein the packaging file comprises a plurality of application files required by an application to be installed, and a script file is carried in a catalog of the packaging file;
Decompressing the packaged files to obtain a plurality of application files;
generating configuration information corresponding to each application file based on the script file;
And sequentially installing a plurality of application files based on the configuration information according to the installation sequence of the plurality of application files.
Optionally, after monitoring the plurality of applications on the device side based on the monitoring file, the method further includes at least one of:
responding to the arrival of a task of a new application to be installed, and updating the monitoring file based on configuration information corresponding to the new application to be installed;
Responding to the modification information of the installed application sent by the cloud, and updating the monitoring file based on the modification information;
Wherein the modification information is used to modify at least one of an attribute of the installed application and a monitoring configuration of the installed application.
Optionally, the method further comprises:
And responding to updating the monitoring file, and monitoring a plurality of applications based on the updated monitoring file.
Optionally, the monitoring result includes an operation state of the application, and the preset condition includes: the operating state of the target application is at least one of not running, running failure, and the operating state of the application associated with the target application is running and the target application is not running.
Optionally, the executing the first control on the target application based on the target event includes:
When the target event is that the control instruction sent by the cloud based on the running state is received or the equipment side monitors that the monitoring result of the target application accords with any one of preset conditions, executing the first control on the target application according to the control instruction or based on the preset conditions;
when the target event comprises the received control instruction sent by the cloud based on the monitoring result and the monitoring result of the target application monitored by the equipment end accords with a preset condition, the first control is executed on the target application based on the control instruction, the preset condition and the control priority between the cloud and the equipment end.
Optionally, the method further comprises:
receiving an adjustment instruction sent by the cloud; the adjustment instruction is generated by the cloud based on the received progress change information;
executing second control corresponding to the adjustment instruction on the application to be installed;
wherein the second control includes at least one of canceling installation of the application to be installed, suspending installation of the application to be installed, and deleting the application file.
In a second aspect of the present disclosure, a control method of an application is provided, and the method is applied to a cloud, and includes:
Receiving monitoring results of a plurality of applications sent by a device side; the monitoring result is obtained by the equipment side monitoring a plurality of applications based on a monitoring file, and the monitoring file is generated by the equipment side based on configuration information of the applications when the applications are installed and is used for indicating the applications to be monitored and monitoring contents on the equipment side;
Based on the monitoring results of the plurality of applications, issuing control instructions aiming at target applications in the plurality of applications to the equipment end;
the device side is used for executing first control on the target application based on a target event, wherein the first control comprises at least one of starting the application, closing the application, unloading the application and upgrading the application;
The target event comprises the control instruction and/or the monitoring result of the target application monitored by the equipment end accords with a preset condition, and the preset condition is recorded in the monitoring file.
Optionally, before receiving the monitoring results of the plurality of applications sent by the device side, the method further includes:
responding to the creation of a task, acquiring created task information, wherein the task information comprises configuration information of an application to be installed and a packaging file, and the packaging file comprises a plurality of application files required by the application to be installed;
analyzing the task information to generate installation information, wherein the installation information comprises storage paths of a plurality of application files required by the application to be installed and configuration information corresponding to each application file;
and transmitting the installation information to the equipment end so that the equipment end downloads the application files from the storage path, and sequentially installing a plurality of application files based on the configuration information according to the installation sequence of the application files.
Optionally, before receiving the monitoring results of the plurality of applications sent by the device side, the method further includes:
Responding to the creation of a task, acquiring created task information, wherein the task information comprises a packaging file, and the packaging file comprises a plurality of application files required by an application to be installed, wherein a script file is carried in a catalog of the packaging file;
The packaged file is issued to the equipment end, so that after the equipment end decompresses the packaged file, configuration information corresponding to each application file is generated based on the script file; and installing a plurality of application files in turn according to the installation sequence of the application files based on the configuration information.
Optionally, the installation sequence is recorded in the task information, or the installation sequence is obtained by the cloud based on association relations among a plurality of application files.
Optionally, the method further comprises:
Receiving task progress changing information aiming at the task information, wherein the task progress changing information is used for indicating the installation progress adjustment of the application to be installed;
Acquiring progress information corresponding to the equipment end, wherein the progress information comprises the current progress of the application to be installed;
Based on the progress information, performing a second control corresponding to the task progress change information, the second control including at least one of canceling installation of the application to be installed, suspending installation of the application to be installed, and deleting the application file.
Optionally, the performing, based on the progress information, a second control corresponding to the task progress change information on the task letter includes:
Determining an execution end where the current progress is located based on the progress information;
if the execution end is the cloud end, executing the second control by the cloud end;
and if the executing end is the equipment end, sending an adjustment instruction corresponding to the progress change information to the equipment end so as to enable the equipment end to execute the second control.
Optionally, the issuing, based on the monitoring results of the plurality of applications, a control instruction for a target application in the plurality of applications to the device end includes at least one of the following:
Displaying a plurality of monitoring results, and responding to control operation of the monitoring results of the target application, and issuing a control instruction of the target application to the equipment end;
Determining a target application of which the monitoring result is in a target running state in a plurality of applications, and issuing a control instruction aiming at the target application to the equipment end so as to enable the target application to deviate from the target running state;
And generating a control instruction aiming at the target application based on the monitoring result and the application required by the current service.
Optionally, the monitoring result includes an operation state of the application, and the generating, based on the monitoring result and the application required by the current service, a control instruction for the target application includes:
acquiring a plurality of first applications supporting the current service;
acquiring running states of a plurality of first applications at the equipment end;
And generating a starting command corresponding to a second application in which the running state is not running in the plurality of first applications, so that the equipment end starts the second application.
Optionally, the generating, for a second application whose running state is not running in the plurality of first applications, a start command corresponding to the second application includes:
determining whether the second application is a master application of the current service;
If yes, after the starting command is sent, whether the main application is started successfully or not is detected;
And after the main application is successfully started, sending a starting command to a third application, wherein the third application is an application which is not the main application in the second application.
In a third aspect of the disclosure, a control system for an application is provided, including a cloud end and a plurality of device ends connected with the cloud end; wherein,
The device side is configured to monitor a plurality of applications on the device side based on a monitoring file, wherein the monitoring file is generated based on configuration information of the applications when the applications are installed, and the monitoring file is used for indicating the applications to be monitored;
The cloud end is configured to receive monitoring results of a plurality of applications sent by the equipment end and send control instructions to the equipment end based on the monitoring results;
The device side is further configured to perform a first control on a target application of a plurality of the applications based on a target event in response to arrival of the target event, the first control including at least one of starting the application, closing the application, uninstalling the application, and upgrading the application;
The target event includes receiving the control instruction, and/or the device side monitors that a monitoring result of the target application meets a preset condition, where the preset condition is recorded in the monitoring file.
The application control method provided by the disclosure is applied to a device side and comprises the following steps: monitoring a plurality of applications on the equipment side based on a monitoring file, wherein the monitoring file is generated based on configuration information of the applications when the applications are installed, and the monitoring file is used for indicating the applications to be monitored and monitoring contents; uploading monitoring results of a plurality of applications to a cloud; in response to arrival of a target event for a target application of a plurality of the applications, performing a first control on the target application based on the target event, the first control including at least one of launching the application, closing the application, uninstalling the application, and upgrading the application; the target event comprises receiving a control instruction sent by the cloud based on the monitoring result, and/or the equipment side monitors that the monitoring result of the target application meets a preset condition, wherein the preset condition is recorded in the monitoring file;
Therefore, the cloud end can monitor a plurality of applications installed at the equipment end through the equipment end, the monitoring result is uploaded to the cloud end, and then the equipment end is monitored through the cloud end, because the cloud end has higher computing power, the application control under a complex strategy can be supported, the computing power consumption of the equipment end is reduced, meanwhile, the cloud end can monitor the state of the application in real time, the application can be shut down in time when the application does not need to run, the power consumption of the equipment end is reduced, and the control of the target application can be realized by the equipment end according to whether the monitoring result meets preset conditions or not, so that the automation degree of the equipment end is improved.
The disclosed embodiments also provide an electronic device comprising a processor and a memory, and a computer program stored on the memory and executable on the processor, the processor executing the control method of the application as described in the first aspect or implementing the control method of the application as described in the second aspect.
Embodiments of the present disclosure also provide a computer-readable storage medium storing a computer program causing a processor to execute the control method of the application as described in the first aspect above, or to implement the control method of the application as described in the second aspect above.
The foregoing description is merely an overview of the technical solutions of the present disclosure, and may be implemented according to the content of the specification in order to make the technical means of the present disclosure more clearly understood, and in order to make the above and other objects, features and advantages of the present disclosure more clearly understood, the following specific embodiments of the present disclosure are specifically described.
Drawings
In order to more clearly illustrate the embodiments of the present disclosure or the technical solutions in the related art, a brief description will be given below of the drawings required for the embodiments or the related technical descriptions, and it is obvious that the drawings in the following description are some embodiments of the present disclosure, and other drawings may be obtained according to the drawings without any inventive effort for a person of ordinary skill in the art. It should be noted that the scale in the drawings is merely schematic and does not represent actual scale.
FIG. 1 illustrates a communication architecture diagram of a control method of an application of an embodiment of the present disclosure;
fig. 2 is a schematic flow chart illustrating a connection between a device side and a cloud end in an embodiment of the disclosure;
Fig. 3 is a schematic diagram illustrating an information flow path between a device side and a cloud end in an embodiment of the disclosure;
fig. 4 is a schematic step flow diagram of a control method of an application according to an embodiment of the disclosure;
FIG. 5 is a flow chart illustrating steps of a control method for an application according to another embodiment of the present disclosure;
FIG. 6 illustrates a schematic creation flow diagram of a task to install an application to be installed in an embodiment of the present disclosure;
FIG. 7 illustrates a schematic creation flow diagram of a task to install an application to be installed in an embodiment of the present disclosure;
FIG. 8 illustrates a schematic diagram of a conversion relationship of tasks in an embodiment of the present disclosure;
FIG. 9 shows a monitoring flow diagram for monitoring an application in an embodiment of the present disclosure;
Fig. 10 shows a schematic structural diagram of a control system of an application provided in an embodiment of the present disclosure.
Detailed Description
In order that the above-recited objects, features and advantages of the present disclosure will become more apparent, a more particular description of embodiments of the disclosure will be rendered by reference to the appended drawings, which together with the appended drawings illustrate embodiments of the disclosure, wherein it is obvious that the described embodiments are some, but not all, of the embodiments of the disclosure. All other embodiments, which can be made by one of ordinary skill in the art without inventive effort, based on the embodiments in this disclosure are intended to be within the scope of this disclosure.
With the development of semiconductor technology, the performance of the device is improved so that the terminal has certain calculation power and can run software with certain algorithm. However, the application program at the current device side is started and runs all the time when the device is started, and is difficult to adapt to the complicated control strategy requirement.
In view of this, the present disclosure provides a control method for an application, by monitoring a plurality of applications on a device side according to a monitoring file, controlling the applications on the device side from a cloud according to monitoring results of the plurality of applications, or automatically controlling the applications by the device side according to monitoring results of the plurality of applications, controlling the applications together by the cloud or the device side, so as to improve automation of the device side, and simultaneously, to stop the applications in time when the applications do not need to run, thereby reducing power consumption of the device side.
First, the implementation environment of the present disclosure will be specifically described:
Referring to fig. 1, fig. 1 illustrates a communication architecture diagram of an implementation environment of an application control method provided by an embodiment of the present disclosure, where the communication architecture diagram includes a device end and a cloud end, the device end may be an intelligent door lock, an automobile, an air conditioner, an intelligent coffee pot, and the like, and the cloud end may be an internet of things platform; the cloud end communicates with the edge device through the device gateway. The cloud design comprises a device connection management layer, a task management layer and a strategy management layer; the equipment connection management layer realizes the connection authentication, security, maintenance and other works of the equipment end and is used for ensuring the connectivity of a cloud end and a secure communication link of the equipment end; the task management layer is responsible for task generation, priority ordering, task cancellation and deletion; the policy management layer is responsible for the management policies of the application, and relates to the starting policies, stopping policies, time policies, deployment policies and equipment policies of the application.
When a connection needs to be established between a device side and a cloud end, referring to fig. 2, fig. 2 shows a flow diagram of establishing a connection between the device side and the cloud end in the embodiment of the disclosure, as shown in fig. 2, first, the device side sends an authentication application to the cloud end, where the authentication application carries an initial authentication key. The information uploaded by the primary power-up adopts system initial symmetric key encryption, and the encryption method can use AES128-CBC or other general encryption algorithms.
The cloud end decrypts the received initial authentication key and then compares the initial authentication key with the initial authentication key in the cloud end device database, and if the initial authentication key is matched with the initial authentication key, the cloud end feeds back a device certificate to the device end according to the initial authentication key, wherein the device certificate comprises a session encryption key, a session encryption method and a consistency signature.
And then, the equipment end verifies whether the signature is consistent with the content of the equipment certificate, and under the condition of consistency, the initial encryption key is used for decrypting the data, the session encryption and decryption method and the session encryption and decryption key are extracted, cloud information is fed back, and then the session between the equipment end and the cloud end is encrypted and decrypted by adopting a new encryption and decryption algorithm and a new key.
After the cloud passes the authentication of the edge equipment, the socket connection field of the equipment, the unique identifier SN of the equipment, the uplink message queue and the downlink message queue of the equipment are packaged into corresponding structure body examples, and the examples (hereinafter referred to as equipment connection examples) are stored into queues so as to facilitate the follow-up application to carry out addition, deletion and verification. The message queue may be replaced by an unix byte stream file sokcet, a pipeline, a socketpair and other inter-process communication modes, so that a message or a cloud instruction at the device end is transferred between cloud processes, so as to realize the issuing of a command and the uploading of the message.
On the cloud side, the management of device connection is implemented by a device connection management program, which needs to register at least two functions, one is a disconnection processing function and the other is a wake-up connection processing function.
The method comprises the steps that a connection signal processing function is disconnected, and when other processes send disconnection signals, the connection between a cloud end and a device end is actively disconnected; when the wake-up connection processing function is used for actively issuing instructions to the equipment end, a corresponding socket connection socket is searched in the equipment connection instance, and the message is actively issued to the equipment end. Therefore, compared with the connection mode that the equipment can issue instructions only after heartbeat information is needed in the past, the cloud can actively issue instructions when the information of the equipment end is not received, repetition of invalid information is avoided, and after connection is established between the cloud and the equipment end, the cloud can maintain connection or keep connection with the equipment end in one end time. In this case, as long as a socket can be found, based on the TCPIP protocol, the cloud can realize active issuing of instructions to the device side.
The communication connection establishment process between the device end and the cloud end can be realized in a process that the device end is introduced, or can be realized at a moment when the device end needs to communicate with the cloud end.
After the device side and the cloud side are connected, the information flow path between the cloud side and the device side may refer to fig. 3, as shown in fig. 3, taking a command issued by the cloud side to the device side as an example, firstly, the cloud side starts HTTP SERVER to monitor the configuration port, issues the task control command to the device side through the issuing path of the task control command when the information to be issued is the task control command, issues the application control command to the device side through the issuing path of the application control command when the information to be issued is the application control command, and then, the device side executes corresponding operation according to the control command and reports an execution result to the cloud side after executing.
Referring to fig. 4 specifically, fig. 4 shows a schematic step flow diagram of a control method of an application provided by an embodiment of the present disclosure, where the control method is applied to an equipment end, and the equipment end in the present disclosure is an internet of things terminal for installing an application program, and the control method of the application specifically includes:
S101, monitoring a plurality of applications on the equipment side based on the monitoring file.
The monitoring file is generated based on configuration information of the application when the application is installed, and is used for indicating the application to be monitored and monitoring content.
Specifically, by loading the monitoring file, the name, the installation path, version information and the like of the application are obtained from the monitoring file, the application to be monitored is found out, and then the application is monitored according to the monitoring content. The monitoring file comprises monitoring content, names, installation paths, version information and the like of a plurality of applications, and all the applications on the corresponding equipment can be monitored based on one monitoring file.
The monitoring content may include one or more monitoring matters, for example, the monitoring matters may be monitoring the running state of the application, monitoring the running time of the application, monitoring the starting time and the stopping time of the application, and the like.
It can be understood that when the monitored application changes, or the monitored content changes, the monitored file changes, and the application needs to be monitored again based on the monitored file, so that the monitoring action is consistent with the monitored file. The condition of monitoring file change can be that the monitored application is updated and changed according to the path, or that the application to be monitored is added or the application monitored in the past is removed, or that the monitored content is changed.
S102, uploading monitoring results of a plurality of applications to the cloud.
The monitoring result is fed back to the result of the monitoring content, and if the monitoring content is the state of the application, the monitoring result comprises the real-time states of a plurality of applications; if the monitoring content is to monitor the running time of the application, the monitoring result comprises the running time of a plurality of applications; if the monitoring content is that the starting and stopping time of the application is monitored, the monitoring result comprises the starting time and the stopping time of each application. When uploading the monitoring results of the plurality of applications to the cloud, the monitoring results of each application in the plurality of applications can be respectively uploaded to the cloud, or the results of the plurality of applications can be packaged and uploaded to the cloud together, and the cloud can control the application of the device end according to the state of the application and the like by uploading the monitoring results to the cloud.
In this embodiment, the monitoring results of the applications may be uploaded to the cloud end in real time, or may be uploaded to the cloud end on time, or may determine whether to upload the monitoring results to the cloud end according to the state change of the applications. For example, in the case of uploading monitoring results of a plurality of applications to the cloud in real time, each time a record of the monitored application is generated, the record is uploaded to the cloud; under the condition that monitoring results of a plurality of applications are uploaded to the cloud end on time, the monitoring results can be uploaded periodically, if the monitoring results of the previous day are uploaded at the zero point of each day, the monitoring records of the monitored applications in the previous day are recorded; and under the condition that whether the monitoring result is uploaded to the cloud is determined according to the change of the monitored state of the application, the monitoring result is determined to be uploaded to the cloud when the state of the application is changed from stop to start or the state of the application is changed from start to stop, and at this time, all the recorded monitoring results are uploaded.
S103, in response to arrival of a target event for a target application in the plurality of applications, performing first control on the target application based on the target event, wherein the first control comprises at least one of starting the application, closing the application, unloading the application and upgrading the application.
The target event comprises receiving a control instruction sent by the cloud based on the monitoring result, and/or the equipment side monitors that the monitoring result of the target application accords with a preset condition, and the preset condition is recorded in the monitoring file.
In this embodiment, the monitoring file may further include a trigger condition corresponding to a control instruction of the device side, and when the application is monitored based on the monitoring file, if the target application is monitored to meet the trigger condition, the device side may directly trigger the control instruction, and control the application through the control instruction. For example, the monitoring file includes the name, the installation path and the version of the application a at the device side, the running time of the application a is monitored, and when the running time of the application a reaches 24 hours, the application a needs to be controlled to stop running, if the running time of the application a reaches 24 hours during actual monitoring, at this time, the device side triggers a control instruction for controlling the application a to stop running, and controls the application a to stop, so that the device side can control the application without passing through a cloud.
Of course, the target event may also be that a control instruction sent by the cloud based on the monitoring result is received, in this case, the user may execute the target operation at the cloud, so that the cloud generates the control instruction, and then the cloud issues the control instruction to the device side, where the device side controls the target application according to the control instruction.
The cloud end and the equipment end can simultaneously send control instructions for target applications, and the equipment end can determine whether to execute the control instructions sent by the cloud end or the control instructions triggered by the equipment end according to the priority of the instructions; the priority may be set by a user, or may be determined according to the complexity of the control policy, for example, a control instruction under a complex condition implemented by the cloud is set, for example, a control instruction determined according to a plurality of application states when a plurality of applications are linked is set, and a control instruction under a simpler condition is executed by the device side, for example, a control instruction determined according to the running time and the start-stop state of the application is set as a control instruction with a higher priority, so that the application control under the complex condition can be preferentially satisfied.
By adopting the application control method provided by the embodiment of the disclosure, the equipment end can monitor the application on the equipment end, and the monitoring result of the application is returned to the cloud end, so that the cloud end can control target applications in a plurality of applications according to the monitoring result; meanwhile, the equipment end can control the target application according to whether the monitoring result accords with the preset condition, and therefore remote control of the application program on the equipment end by the cloud end can be achieved, so that the application control can be achieved jointly by the cloud end and the equipment end, the calculation power consumption of the equipment end can be reduced, meanwhile, under the condition that the remote control and the equipment end conduct autonomous control according to the monitoring result, the application program on the equipment end can be started as required, and the problem that the power consumption of the application program on the equipment end increases due to the fact that the application program on the equipment end is started and stopped along with startup is avoided, and automatic control of the application on the equipment end is achieved.
In an embodiment, a plurality of application files are installed on the device side when monitoring a plurality of applications on the device side, and the generation of the monitoring file is realized according to configuration information of the installed application files.
When an application is installed on the equipment side, a plurality of application files exist in part of the application, and then the plurality of application files are required to be downloaded on the equipment side. At this time, in the installation process of the application program, whether the installation process of the plurality of application files is performed as a plurality of tasks or whether the installation process of the plurality of application files is performed as one task is determined according to whether the task issued by the cloud is a single task or a task group.
In one implementation manner, if the cloud end is characterized in that the cloud end manages each application file as an independent task, when the application is installed, the downloading process of each application file is performed as an independent task, and at this time, the installation process of the application file may specifically be: firstly, receiving installation information issued by a cloud, wherein the installation information comprises a storage path of at least one application file required by an application to be installed and configuration information corresponding to each application file; next, at least one application file is downloaded from the storage path and installed based on the configuration information.
When the number of application files to be installed is one, the application files are downloaded according to the storage paths read from the installation information, when the application to be installed comprises a plurality of application files, the installation information received by the equipment is the storage paths of the application to be installed, and after the configuration information of each application file of the application to be installed, the installation of each application file is executed as a single task, after the installation of one application file is finished, the current task is considered to be finished, then the next task is continuously executed, and when all tasks are finished, the application is characterized to be installed to the equipment end. In this case, the downloading process of each application file is a single task, and the downloading processes of a plurality of application files do not affect each other, and even if a problem occurs in the downloading process of one application, the downloading process of other application files is not affected.
In another implementation manner, if the installation information issued by the cloud characterizes that the cloud manages the plurality of application files as an overall task, when the application is installed, the plurality of application files are packaged and installed, and the specific process may be: firstly, receiving a packaging file issued by a cloud, wherein the packaging file comprises a plurality of application files required by an application to be installed, and a script file is carried in a catalog of the packaging file; then decompressing the package file to obtain a plurality of application files; then, generating configuration information corresponding to each application file based on the script file; and then, sequentially installing the plurality of application files based on the configuration information according to the installation sequence of the plurality of application files.
In this embodiment, the configuration information may include a name of an application, an operation platform of the application, parameters of an installation device of the application, a path of a configuration file corresponding to the application, and the like. The running platform of the application characterizes that the running environment of the application is Android, windows or linux, and the parameters of the installation equipment of the application can comprise the identification of the equipment, the number of the equipment and the like.
The method comprises the steps that sequence information of a plurality of application files can be carried in a packaging file, and in the installation process, the plurality of application files can be installed in sequence according to the read sequence information, when the plurality of application files are all installed on a device side, the current task execution is completed, and the fact that the application is installed on the device side is represented, and in this case, the installation of the plurality of application files is carried out as a whole task, so that the situation that the application files are missed possibly is avoided.
In an embodiment, considering that the installation process of the application may be terminated, suspended, etc. by the user, the cloud may control the application to be installed in the device, where the process may be: firstly, receiving an adjustment instruction sent by a cloud, wherein the adjustment instruction is generated by progress change information received by the cloud; then, executing a second control corresponding to the adjustment instruction on the application to be installed; wherein the second control includes at least one of canceling installation of the application to be installed, suspending installation of the application to be installed, and deleting the application file.
The progress change information can be an instruction sent by a user, when the user subjectively considers that the application to be installed needs to be canceled in installation, is paused in installation or is wrong in application files, the user can input the instruction for canceling the installation in the cloud, and at the moment, the cloud generates an adjustment instruction according to the instruction for canceling the installation input by the user; and then, the equipment end cancels the installation of the application to be installed according to the adjustment instruction of the cloud end.
Illustratively, whether the installation process of the application to be installed downloads a plurality of application files based on the installation information or packages the plurality of application files into one file, the installation is performed based on one packaged file, and the execution control method is the same when the second control is performed on the application to be installed. Specifically, when the second control is to cancel the installation of the application to be installed, canceling the task of installing the application file currently executed, and deleting the application file already installed; suspending downloading of the current application file when the second control is to suspend the installation of the application to be installed; and deleting the application file which is already installed when the second control is to delete the application file.
It can be understood that when a new application is installed at the device end or a monitored application is updated, or the monitored content is changed, the original monitored file cannot correspond to the plurality of currently monitored applications, and then the monitored file needs to be updated to ensure that the monitoring of the application is performed normally.
In the case of installing a new application on the device side, the monitoring file can be updated based on configuration information corresponding to the new application to be installed in response to the arrival of a task of the new application to be installed; for the situation that the configuration change occurs to the installed application at the equipment end or the monitoring content changes, the monitoring file can be updated based on the modification information in response to the modification information of the installed application sent by the cloud end. Wherein the modification information is used to modify at least one of an attribute of the installed application and a monitoring configuration of the installed application.
Specifically, when a task of a new application to be installed arrives, the device is stated to install the new application, and the addition of the application to the monitoring file may be to directly add configuration information in the monitoring file; the modification information of the installed application may be version information after upgrading the version of the monitored application, or may be a name after modifying the name of the monitored application, for example, when the version of the monitored application is upgraded, the version information changes, and the configuration information in the monitoring file is modified according to the new version information.
It will be appreciated that after the monitor file has been updated, which may be regarded as being different from the original monitor file, a new monitor file is regenerated, and then after the monitor file is updated, the monitor file needs to be read again to monitor a plurality of applications, in which case, in response to the monitor file being updated, the plurality of applications are monitored based on the updated monitor file.
At this time, the updated monitoring file is regarded as the regenerated monitoring file, so that in order to ensure the real-time performance of monitoring, the monitoring tasks of a plurality of applications can be immediately executed after the monitoring file is updated, so that the monitoring result can be consistent with the configuration information in the updated monitoring file.
In this embodiment, the monitoring result includes an operation state of the application, and the preset condition includes: the operational state of the target application is not operational, operational failure, and the operational state of the application associated with the target application is operational, and the target application is at least one of not operational.
For example, the monitoring result may include configuration information of the monitored application, and a state of the application, such as whether the application is in an operating state, an unoperated state, or may be in an operating failure state; if the currently monitored application has the associated application, the monitoring result may further include a state of the associated application.
Note that, when there is a coordinated control of a plurality of applications in a part of tasks, for example, when it is necessary to control the linkage of application 1, application 2, and application 3 in a certain task, it is considered that application 1, application 2, and application 3 are associated. In this case, it is necessary to determine whether the state of the target application is reasonable according to the state associated with the target application, and thus control the target application. For example, when the monitoring result shows that the application 1 is in an un-running state and the application 2 and the application 3 are in running states, if a task needs to be started, the application 1 needs to be started to realize the task. At this time, the control of the target application based on the monitoring result may be implemented by the cloud end or may be implemented by the device end.
In one implementation, for the linkage of multiple applications, the device end may control the target application based on whether the monitoring result meets the preset condition, where the associated application of the target application may be obtained from the cloud. For example, the device may obtain, from the cloud, a service name of a service with multiple applications linked, and when the service needs to be implemented, determine, according to the service name, an application 1, an application 2, and an application 3 associated with the service, and then the device may determine, according to a monitoring result, a state of the application 1, the application 2, and the application 3, and if the application 1 is in an un-running state and the application 2 and the application 3 are in an running state, control opening of the application 1.
In another implementation manner, for a situation that a certain service is implemented by linking a plurality of applications, when the service of linking the plurality of applications needs to be implemented, the cloud end determines the running states of the application 1, the application 2 and the application 3 according to the monitoring result uploaded by the device end, if the application 1 is in an unoperated state and the application 2 and the application 3 are in the running state, an instruction for controlling the opening of the application 1 is sent to the device end, and the device end executes the control instruction for controlling the opening of the application 1.
It should be noted that, the device side controls the target application based on a target event, where the target event may be a control instruction sent by the cloud end based on an operation state, or may be that a monitoring result of the device side monitoring the target application meets a preset condition, or may include a control instruction sent by the cloud end based on a motion state, and a monitoring result of the device side monitoring the target application meets a preset condition, and executing the first control on the target application based on the target event may be specifically classified into a case one: when a target event is that a control instruction sent by a cloud based on an operation state is received or a device side monitors that a monitoring result of a target application accords with any one of preset conditions, executing first control on the target application according to the control instruction or based on the preset conditions;
And, case two: when the target event comprises receiving a control instruction sent by the cloud based on the monitoring result and the monitoring result monitored by the equipment end is in accordance with the preset condition, executing first control on the target application based on the control instruction, the preset condition and the control priority between the cloud and the equipment end.
The method comprises the steps that in the case of only cloud control execution or only control instructions of a device side, a target application is controlled according to the only control instructions; and two control instructions exist in the second case, one control instruction is a control instruction of the cloud end for the target application, and the other control instruction is a control instruction of the equipment end for the target application, and if two control instructions possibly have conflict, the control priorities of the cloud end and the equipment end can be configured in advance, so that when the control instructions with two different sources exist, the control instruction with high priority is selected for execution.
The method includes the steps that a control priority of a cloud is preset to be higher than that of a device end, when a target event includes receiving a control instruction sent by the cloud and the control end monitors that a monitoring result of a target application meets a preset condition, the control instruction of the cloud is determined to be executed preferentially, and at the moment, first control is executed on a first target application according to the control instruction of the cloud; if the control priority of the preset equipment end is higher than the cloud end, the target application is directly controlled according to the preset condition when the target event comprises the preset equipment end and the cloud end.
According to the application control method provided by the embodiment of the disclosure, through monitoring results of a plurality of applications on the equipment side, the cloud side determines a control instruction of a target application in the plurality of applications according to the monitoring results, and/or the equipment side monitors that the monitoring results of the target application meet preset conditions, and further controls the target application according to the control instruction and/or the preset conditions, wherein under the condition that the target application is associated with other applications in the plurality of applications, the equipment side or the cloud side can control the target application according to the associated applications, so that the equipment side or the cloud side can control the application according to business requirements, application control under a complex strategy can be realized, and cooperative application control of the cloud side and the equipment side can also be realized, and the calculation power consumption of the equipment side is reduced.
Based on the same inventive concept, the present disclosure further provides an application control method, where the method is applied to a cloud end, and referring to fig. 5, fig. 5 shows a schematic step flow diagram of another application control method provided by an embodiment of the present disclosure, and as shown in fig. 5, the control method specifically includes:
s201, receiving monitoring results of a plurality of applications sent by a device side.
The monitoring result includes configuration information or application representations of a plurality of applications on the device side, and a monitoring result corresponding to each application, where the monitoring result may be an operation state of the application, the fault states may also include a monitored operation duration, a monitored start time, a monitored stop time, and the like, and the obtaining of the monitoring result is implemented by the device side, and a specific process may refer to an embodiment of the device side and is not described herein.
S202, based on monitoring results of a plurality of applications, a control instruction aiming at a target application in the plurality of applications is issued to the equipment end.
The device side is used for executing first control on the target application based on the target event, wherein the first control comprises at least one of starting the application, closing the application, unloading the application and upgrading the application; the target event comprises a control instruction and/or a monitoring result of the equipment side monitoring the target application accords with a preset condition, and the preset condition is recorded in the monitoring file.
In this embodiment, the control instruction for the target application in the multiple applications may be generated according to a preset condition, or may be generated according to a service triggered by the user. For example, when the application a is running according to a time period, and needs to be turned off for 1 hour every 10 minutes when the application a is turned on, so as to avoid larger electricity consumption, the running duration of the conditional application a can be set to reach 10 minutes, an instruction for stopping running the application a is generated, and an instruction for starting the application a is generated when the non-running duration of the application a reaches 1 hour; furthermore, the generation of the control instruction can be realized according to whether the running time of the application A in the device-side uploading monitoring result reaches the preset condition; and for the case that the user intends to start the service I, if the user triggers the service I, determining the application B required for realizing the service I, determining the state of the application B according to the monitoring result, and generating an instruction for starting the application B when the application B does not run.
According to the application control method provided by the embodiment of the disclosure, the cloud end can monitor the states of a plurality of applications on the equipment end according to the monitoring result uploaded by the equipment end, and then the cloud end can generate control instructions for target applications in the plurality of applications according to the monitoring result.
In an embodiment, the generation mode of the control instruction may include various modes, and may directly generate the control instruction according to the monitoring result, or may be control information for the target application input by the user according to the monitoring result, and the cloud end may generate the control instruction according to the control instruction, or may generate the control instruction according to the service to be performed and the monitoring result that are currently received by the cloud end.
Under the condition that the control instruction is directly generated according to the monitoring result, the specific control instruction generating method may be to determine that the monitoring result in the plurality of applications is a target application in a target running state, and issue a control instruction for the target application to the equipment end so as to make the target application deviate from the target running state.
For example, when the device is not in use, the plurality of applications on the device side are all in an unoperated state, and if the state of the target application is determined to be an operational state according to the monitoring result, the cloud end may generate a control instruction for the target application, so that the target application is separated from the operational state and returns to the unoperated state.
Under the condition that the cloud side generates the control instruction according to the input control information, the specific control instruction generation method can be to display a plurality of monitoring results and respond to the control operation of the monitoring results aiming at the target application to issue the control instruction aiming at the target application to the equipment side.
The cloud end can be configured with a display screen, the display screen is used for displaying a monitoring result to a user, the monitoring result can be a current running state of each application, if a name of each application is displayed and the current running state of the application is displayed after the name, the user can input control operation on a target application according to needs, the cloud end generates a control instruction according to the control operation input by the user, and the control operation input by the user can be a switching operation on the running state or a control operation input by a text box.
The method comprises the steps that an application A, an application B and an application C on a device side are displayed to a user through a display screen at a cloud end, wherein the application A is displayed in an operating state, the application B is displayed in a stopping state, and the application C is displayed in the stopping state; when the user intends to stop the application A, the user can click the application A on the display screen and click state switching, the user is characterized in that the user intends to switch the application A from the running state to the stop state, and the cloud end generates an instruction for controlling the application A to stop running according to the operation of the user.
Under the condition that the cloud generates the control instruction according to the service triggered by the user and the monitoring result, the specific control instruction generation method can be based on the monitoring result and the application required by the current service, and generate the control instruction for the target application.
The cloud end can be configured with a service end, the service end is used for sending the current service to the cloud end, then the application required by the current service can be determined, and further the cloud end can determine the current state of the application required by the current service according to the application required by the current service and the monitoring result, so that when the application required by the current service is not started, a control instruction for starting the application is generated.
In this embodiment, the number of applications required by the current service may be one or more, and when the number of applications required by the current service is one, the applications required by the current service may be controlled directly according to the monitoring result, and when the number of applications required by the current service is more than one, the number of applications required to be controlled is determined according to the monitoring result, and then the applications are controlled respectively.
In the case that the number of applications required by the current service is multiple, a specific process of generating the control instruction may be that first, multiple first applications supporting the current service are acquired; next, acquiring running states of a plurality of first applications in the equipment; and then, generating a starting command corresponding to the second application for the second application with the running state of not running in the plurality of first applications, so that the equipment end starts the second application.
Specifically, a plurality of first applications with the same service identifier can be determined according to the service identifier of the current service, or a plurality of first applications can be determined according to the application names associated with the current service identifier; after determining the plurality of first applications, determining the running state of each first application at the equipment end based on the received monitoring result, and generating a corresponding control instruction according to the running state. The cloud may generate a control instruction for starting the application X and the application Y, or may generate a control instruction for starting the application X first, and then generate a control instruction for starting the application Y.
In an embodiment, there are different degrees of association between multiple applications associated with a current service, an application with a strong degree of association is a main factor of whether the service can be implemented or not, and other applications are secondary factors of whether the service can be implemented or not, so that the application cannot be started, and even if the other applications are started, the service cannot be implemented, the application with the strong degree of association can be controlled first, and when the application is started successfully, the other applications are controlled. The process may be to determine whether the second application is a master application of the current service, and if so, after sending the start command, detect whether to start the master application successfully; after the main application is successfully started, a starting command is sent to a third application, wherein the third application is an application which is not the main application in the second application.
The method comprises the steps that a main application can characterize an application playing a main role in the realization process of a service, and whether a second application is the main application of the current service or not can be determined according to service information sent by a service end; if the application M supports the core function of the service and the application N only supports the edge function of the service according to the service information, the application M is the main application.
After determining the main application, the cloud end can firstly send a starting command to the main application, after the equipment end controls the main application to start according to the starting command of the main application, the cloud end can firstly detect the current monitoring result, determine whether the main application is started successfully according to the monitoring result, if the running state of the main application is switched from the non-running state to the running state, the starting command of other applications is regenerated, and the starting command of other applications is sent to the equipment end.
It can be understood that, when receiving the monitoring result of the device side on the plurality of applications requires that the device side installs the applications, the applications need to be installed on the device side before the installation of the plurality of applications on the device side is achieved. The application to be installed is divided into an application file and a matched configuration file, and the application file is a code.
In some embodiments, an application exists that includes multiple application files and corresponding configuration files. The installation process of the application can be implemented in two different ways for this case, namely, a separate creation task and a package creation task.
Mode one: after the cloud decompresses the packaged application files and the corresponding configuration files, configuration information is created for each application file to serve as an independent task, then the tasks serve as a task group, and the equipment side can directly realize the installation process of the application based on the task group; the above process may specifically include: firstly, responding to creation of a task, acquiring created task information, wherein the task information comprises configuration information of an application to be installed and a packaging file, and the packaging file comprises a plurality of application files required by the application to be installed; then, analyzing the task information to generate installation information, wherein the installation information comprises storage paths of a plurality of application files required by the application to be installed and configuration information corresponding to each application file; and then, the installation information is issued to the equipment end, so that the equipment end downloads the application files from the storage path, and the application files are sequentially installed based on the configuration information according to the installation sequence of the application files.
Specifically, referring to fig. 6, fig. 6 shows a flow chart of a task generating process in the provision of the embodiment of the present disclosure, and as shown in fig. 6, when a package file uploaded by a user is received, the cloud end decompresses the package file to obtain a plurality of application files and configuration files, and creates a task corresponding to a current application file by reading configuration information in the configuration files corresponding to the plurality of application files; then, creating a task for the next application file until individual tasks are created for all application files; then, a plurality of tasks are created as a task group, and the device side directly executes the installation process of a plurality of application files by issuing the task group to the device side.
The decompression process of the packaged files is realized by the cloud end in a separate creation mode, and each application file creates separate tasks respectively, so that the cloud end can manage each task independently conveniently. It can be understood that the cloud end issues the tasks to the device end in the form of task groups, and the tasks in the task groups are considered to be successfully installed under the condition that all the tasks in the task groups are successfully executed.
Mode two: the cloud can directly create tasks for the packaged files, and the decompression process is realized through the equipment end, and the process specifically can be as follows: firstly, responding to the creation of a task, acquiring created task information, wherein the task information comprises a packaging file, and the packaging file comprises a plurality of application files required by an application to be installed, wherein a script file is carried in a catalog of the packaging file; then, the packaged file is issued to the equipment end, so that after the equipment end decompresses the packaged file, configuration information corresponding to each application file is generated based on the script file; and sequentially installing the plurality of application files based on the configuration information according to the installation sequence of the plurality of application files.
Specifically, referring to fig. 7, fig. 7 shows a flow chart of a task generating process in the embodiment of the disclosure, as shown in fig. 7, when a cloud end receives a package file, a single task is directly created according to the package file, wherein, firstly, after the cloud end can receive the package file, the cloud end can directly create the task according to the package file, and configure an installed and uninstalled script file in a top directory of the package file, so that a device end can generate configuration information corresponding to an application file according to the script file, and further the device end can install a plurality of application files in the package file according to the configuration information.
In the embodiment, the task creation is performed by taking the packaged file as a whole, so that the task generation process is simpler and more convenient, the cloud can rapidly issue the installation task to the equipment terminal, and the application installation process is rapidly performed.
It can be understood that, whether the packaged file is taken as a whole task or each file after the packaged file is decompressed is taken as a single task, the equipment end needs to carry out the downloading process of the application file in an installation sequence, the installation sequence is recorded in the task information summary, or the installation information is obtained by the cloud based on the association relationship of a plurality of application files. For example, the cloud may sort the application files according to names, sizes, and the like of the application files, and obtain an installation order of the plurality of application files according to the sorting.
In the process of installing the application file, task progress change information input by a user can be received, and in the process of installing the application at the equipment end, the cloud can control the installation progress of the application to be installed according to the received task progress change information. The control process of the application to be installed specifically may include first receiving task progress change information for task information, where the task progress change information is used to indicate adjustment of an installation progress of the application to be installed; next, progress information corresponding to the equipment end is obtained, wherein the progress information comprises the current progress of the application to be installed; thereafter, based on the progress information, a second control corresponding to the task progress change information is performed, the second control including at least one of canceling installation of the application to be installed, suspending installation of the application to be installed, and deleting the application file.
The progress of the task characterizes the progress of the task created at the cloud end, and can also characterize the execution degree of the task at the equipment end, the current progress of the task can be determined through the state of the task, if the task state is the creation state, the task is just started to be generated, if the task state is the completion state is generated, the progress of the task is about to be issued to the equipment end, and the like, wherein the states of the task comprise various states, such as task creation, task generation, task operation, task cancellation, and the like, and conversion relations exist among the states of the various tasks, and the conversion relations can be shown in fig. 8.
As can be seen from fig. 8, first, after related information of a task, such as a task id, a task group id, an execution terminal list, a start time, a deadline, and the like, the task is created according to the related information, the created task is stored in a database, the task is regarded as a task generating state at this time, after the task is generated, the task is listed in a task queue and is issued to a device end for execution, wherein if the information of changing the task progress is received, the task can be suspended without being listed in the task queue if the execution of the task is canceled, and at this time, the task is in a task suspending state; and if the task is to be re-executed, restoring the suspended task to the queue, and if the task is to be deleted, deleting the task directly, or deleting the task directly in the database when the task is generated, wherein the state of the task is a task deleting state.
When a task is issued to an execution end, namely a device end, the device end executes the task, at the moment, the task is in an execution state, after execution is completed, the device end returns an execution result to the cloud end no matter whether the execution is failed or successful, and if the execution failure information is returned, the task is represented to be in the execution failure state; and if the information of successful execution is returned, the task is represented to be in a successful execution state.
The task progress change information can be input into the cloud by a user, and whether task progress change is needed or not can be judged by the cloud; for example, if the user intends to cancel the application currently being installed, task progress change information for canceling the installation task of the application to be installed may be input to the cloud; when the cloud transmits a task for installing an application to be installed, a user creates a task with higher priority, the cloud can judge that the installation task of the current application to be installed needs to be suspended according to the priority, and execute the task with higher priority first, and at the moment, the cloud generates task progress change information for indicating suspension of installation of the application to be installed.
The progress information can be the current task creation progress of the application to be installed or the installation progress of the application to be installed, and the installation progress can be sent to the cloud end by the equipment end in real time in the installation process, so that the cloud end can master the installation progress of the application to be installed at any time.
In an embodiment, when a user inputs task progress change information to a cloud end or the cloud end generates task progress change information, a task for installing an application to be installed may also execute a task generating process at the cloud end, or may execute an installing process at a device end, that is, when different task progresses, execution ends for controlling the task may be different, the current execution end may be firstly determined, then an operation executed by the cloud end is determined according to the execution end, and the process may specifically be that the execution end where the current progress is located is determined based on the progress information; if the execution end is the equipment end, executing the second control by the cloud end; if the executing end is the equipment end, an adjusting instruction corresponding to the progress changing information is sent to the equipment end, so that the equipment end executes the second control.
Specifically, when the cloud receives task progress change information, the cloud acquires progress information, wherein the progress information comprises task progress information of the cloud and installation progress information of the equipment end, if the progress information indicates that a task is being created or a task is being issued, the current task execution end is determined to be the cloud, and at the moment, second control can be directly realized by the cloud, such as canceling installation of an application to be installed, deleting part of application files of the application to be installed or suspending issuing of the task; if the progress information indicates that the device side is installing the application to be installed, determining that the current task execution side is the device side, and at the moment, sending an adjustment instruction to the device side by the cloud end to instruct the device side to perform second control, such as canceling the installation of the application to be installed, deleting the installed application file, suspending the installation of the application to be installed, and the like.
By adopting the control system of the application provided by the embodiment of the disclosure, the cloud can generate a target control instruction according to the monitoring result sent by the equipment end and by combining the control operation of the user on the application or the realization of the application required by the service, thereby realizing the application control under various conditions and improving the accuracy of the application control; meanwhile, as the application control can be realized through cooperation of the cloud end and the equipment end, the calculation power consumption of the equipment can be reduced.
The following describes a control method of an application provided by an embodiment of the present disclosure in detail with reference to a specific example:
Firstly, before monitoring an application, a cloud end creates a task according to a file package of the application to be installed, which is sent by a user, so that a device end installs the application to be installed according to the task. When creating the task, the packaging file may be decompressed to obtain the application file and the corresponding configuration file, the configuration file is read to generate configuration information, and the installation task of the application file is created according to the configuration information, or the script file may be directly configured for the packaging file, the configuration information is generated according to the script file, and then the installation task is created for the packaging file, where the task carries the installation information, and the installation information includes the storage path of the application file and the configuration information.
After generating the task, issuing the task to the equipment end for execution, wherein if the equipment end receives the task of installing the application file, the application file is directly downloaded to a corresponding storage path according to the installation information; if the equipment receives the task of installing the package file, firstly decompressing the package file to obtain the application file, then determining the configuration information of the application file according to the script file in the catalogue of the package file, and then downloading the application file according to the configuration information.
After the application is installed, the application is monitored by reading the file information of the monitor App.yaml file and registering the application to be monitored to a monitoring module at the equipment end. The file content of the monitor app.yaml file comprises information such as the name of an application, a storage path and the like, and also has a certain organization architecture, so that a strategy and a control mode for monitoring the application can be embodied.
The specific flow of the monitoring application may refer to fig. 9, and fig. 9 shows a schematic flow diagram of the device-side monitoring application in this embodiment, and when the monitoring application is monitored, a monitor app.yaml file is read first, then the application is registered in the monitoring module, and then a pipeline signal is added, and an instruction for scanning the application is triggered at the same time.
When the instruction is triggered, whether a preset time interval is reached or not and whether a monitor app.yaml file is changed or not are determined, and if one of the monitor app.yaml file is met, scanning of the application is executed to determine the current running state of the application.
And reporting the running state to the cloud. After the running state of the application is reported this time, whether the last scanning reaches a preset time interval or not and whether a monitor app.yaml file is changed or not are determined, so that the application is scanned again, and the running state of the application is determined.
The flow of the monitoring module may include: firstly, starting a monitoring module, then, reading and analyzing the YAML configuration file, and acquiring 'apps' field information in the YAML configuration file, wherein the field information comprises related information such as the name, the path, the version and the like of each application. Then, a timing task or a timer is set, and the following steps are executed regularly: traversing each configured application, and acquiring the name and path of the application according to the configuration information; then, checking whether the application is running, if so, recording the state of the application as running; if the application is not operated, recording the state of the application as not operated; then, updating the state information of the response according to the recorded state; if the configuration file is monitored to change, if the configuration file is modified, reloading the YAML configuration file, analyzing the updated configuration file, and acquiring the latest apps field information; updating the running state of the application and related information according to the latest apps field information; and then continuing to execute a timing task or a timer, and periodically acquiring and recording the state of the application. And if the monitoring module needs to stop, corresponding stopping operations such as resource cleaning, timing task cancellation and the like are executed.
After reporting the running state of the application to the cloud, the cloud determines the running state of the installed application according to the received monitoring result, and further generates a control instruction for controlling the opening of the installed application if the installed application is not running, and issues the control instruction to the equipment end. And finally, the equipment end controls the application to be started according to the control instruction.
In another implementation scenario, the cloud end further includes a service end, where the service end is configured to send a service to be executed by the device end to the cloud end. In this implementation scenario, the installation process of the plurality of applications is the same as the above embodiment.
After the service end sends the service to be realized currently by the device end to the cloud end, the cloud end can determine the application required by realizing the service according to the service information sent by the device end, so as to realize the support of the application A, the application B and the application C required by the current service.
After determining the application needed by the current service, determining the running states of the application A, the application B and the application C through the monitoring result. If the application A and the application B are in an operating state and the application C is in an unoperated state in the three applications, the cloud end generates an instruction for starting the application C and sends the instruction to the equipment end.
And then, the equipment end controls the application C to be started according to the instruction for starting the application C.
Based on the above inventive concept, the embodiment of the present disclosure further provides an application control system, referring to fig. 10, fig. 10 shows a schematic structural diagram of the application control system provided by the embodiment of the present disclosure, as shown in fig. 10, where the control system includes: the cloud 301 and a plurality of device ends 302 connected with the cloud 301; wherein,
The device side 302 is configured to monitor a plurality of applications on the device side 402 based on a monitoring file, where the monitoring file is generated based on configuration information of the applications when the applications are installed, and the monitoring file is used to indicate the applications to be monitored;
the cloud 301 is configured to receive monitoring results of a plurality of applications sent by the device side 302, and send a control instruction to the device side 302 based on the monitoring results;
The device side 302 is further configured to, in response to arrival of a target event of a target application of the plurality of applications, perform a first control on the target application based on the target event, the first control including at least one of starting the application, closing the application, uninstalling the application, and upgrading the application;
the target event includes receiving a control instruction, and/or the device side 302 monitors that a monitoring result of the target application meets a preset condition, where the preset condition is recorded in a monitoring file.
The disclosed embodiments also provide an electronic device comprising a processor and a memory, and a computer program stored on the memory and executable on the processor to cause the processor to execute the control method of the application as described in any of the embodiments above.
The disclosed embodiments also provide a computer-readable storage medium storing a computer program for causing a processor to execute the control method of the application according to any one of the above embodiments.
In this specification, each embodiment is described in a progressive manner, and each embodiment is mainly described by differences from other embodiments, and identical and similar parts between the embodiments are all enough to be referred to each other.
Finally, it is further noted that relational terms such as first and second, and the like are used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Moreover, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one … …" does not exclude the presence of other like elements in a process, method, article or apparatus that comprises the element.
The foregoing has described in detail the control method, system, apparatus and medium of an application provided by the present disclosure, and specific examples have been applied herein to illustrate the principles and embodiments of the present disclosure, the above examples being only for aiding in the understanding of the method of the present disclosure and its core ideas; meanwhile, as one of ordinary skill in the art will have variations in the detailed description and the application scope in light of the ideas of the present disclosure, the present disclosure should not be construed as being limited to the above description.
Other embodiments of the disclosure will be apparent to those skilled in the art from consideration of the specification and practice of the disclosure disclosed herein. This disclosure is intended to cover any adaptations, uses, or adaptations of the disclosure following the general principles of the disclosure and including such departures from the present disclosure as come within known or customary practice within the art to which the disclosure pertains. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of the disclosure being indicated by the following claims.
It is to be understood that the present disclosure is not limited to the precise arrangements and instrumentalities shown in the drawings, and that various modifications and changes may be effected without departing from the scope thereof. The scope of the present disclosure is limited only by the appended claims.
Reference herein to "one embodiment," "an embodiment," or "one or more embodiments" means that a particular feature, structure, or characteristic described in connection with the embodiment is included in at least one embodiment of the present disclosure. Furthermore, it is noted that the word examples "in one embodiment" herein do not necessarily all refer to the same embodiment.
In the description provided herein, numerous specific details are set forth. However, it is understood that embodiments of the disclosure may be practiced without these specific details. In some instances, well-known methods, structures and techniques have not been shown in detail in order not to obscure an understanding of this description.
In the claims, any reference signs placed between parentheses shall not be construed as limiting the claim. The word "comprising" does not exclude the presence of elements or steps not listed in a claim. The word "a" or "an" preceding an element does not exclude the presence of a plurality of such elements. The disclosure may be implemented by means of hardware comprising several distinct elements, and by means of a suitably programmed computer. In the unit claims enumerating several means, several of these means may be embodied by one and the same item of hardware. The use of the words first, second, third, etc. do not denote any order. These words may be interpreted as names.
Finally, it should be noted that: the above embodiments are merely for illustrating the technical solution of the present disclosure, and are not limiting thereof; although the present disclosure has been described in detail with reference to the foregoing embodiments, it should be understood by those of ordinary skill in the art that: the technical scheme described in the foregoing embodiments can be modified or some technical features thereof can be replaced by equivalents; such modifications and substitutions do not depart from the spirit and scope of the corresponding technical solutions of the embodiments of the present disclosure.

Claims (20)

1. An application control method, which is characterized by being applied to a device side, comprising:
Monitoring a plurality of applications on the equipment side based on a monitoring file, wherein the monitoring file is generated based on configuration information of the applications when the applications are installed, and the monitoring file is used for indicating the applications to be monitored and monitoring contents;
Uploading monitoring results of a plurality of applications to a cloud;
In response to arrival of a target event for a target application of a plurality of the applications, performing a first control on the target application based on the target event, the first control including at least one of launching the application, closing the application, uninstalling the application, and upgrading the application;
The target event comprises receiving a control instruction sent by the cloud based on the monitoring result, and/or the device side monitors that the monitoring result of the target application meets a preset condition, wherein the preset condition is recorded in the monitoring file.
2. The method for controlling applications according to claim 1, wherein before the monitoring of the plurality of applications on the device side based on the monitoring file, the method further comprises:
receiving installation information issued by the cloud, wherein the installation information comprises a storage path of at least one application file required by an application to be installed and configuration information corresponding to each application file;
Downloading the at least one application file from the storage path, and installing the at least one application file based on the configuration information.
3. The method for controlling applications according to claim 1, wherein before the monitoring of the plurality of applications on the device side based on the monitoring file, the method further comprises:
Receiving a packaging file issued by the cloud, wherein the packaging file comprises a plurality of application files required by an application to be installed, and a script file is carried in a catalog of the packaging file;
Decompressing the packaged files to obtain a plurality of application files;
generating configuration information corresponding to each application file based on the script file;
And sequentially installing a plurality of application files based on the configuration information according to the installation sequence of the plurality of application files.
4. The method for controlling applications according to claim 1, wherein after the monitoring of the plurality of applications on the device side based on the monitoring file, the method further comprises at least one of:
responding to the arrival of a task of a new application to be installed, and updating the monitoring file based on configuration information corresponding to the new application to be installed;
Responding to the modification information of the installed application sent by the cloud, and updating the monitoring file based on the modification information;
Wherein the modification information is used to modify at least one of an attribute of the installed application and a monitoring configuration of the installed application.
5. The method for controlling an application according to claim 4, further comprising:
And responding to updating the monitoring file, and monitoring a plurality of applications based on the updated monitoring file.
6. The method for controlling an application according to claim 1, wherein the monitoring result includes an operation state of the application, and the preset condition includes: the operational state of the target application is at least one of not running, running failed, and the operational state of an application associated with the target application is running and the target application is not running.
7. The method according to claim 1, wherein the performing the first control on the target application based on the target event includes:
When the target event is that the control instruction sent by the cloud based on the running state is received or the equipment side monitors that the monitoring result of the target application accords with any one of preset conditions, executing the first control on the target application according to the control instruction or based on the preset conditions;
when the target event comprises the received control instruction sent by the cloud based on the monitoring result and the monitoring result of the target application monitored by the equipment end accords with a preset condition, the first control is executed on the target application based on the control instruction, the preset condition and the control priority between the cloud and the equipment end.
8. A control method for an application according to claim 2 or 3, characterized in that the method further comprises:
receiving an adjustment instruction sent by the cloud; the adjustment instruction is generated by the cloud based on the received progress change information;
executing second control corresponding to the adjustment instruction on the application to be installed;
wherein the second control includes at least one of canceling installation of the application to be installed, suspending installation of the application to be installed, and deleting the application file.
9. An application control method, which is characterized by being applied to a cloud, the method comprising:
Receiving monitoring results of a plurality of applications sent by a device side; the monitoring result is obtained by the equipment side monitoring a plurality of applications based on a monitoring file, and the monitoring file is generated by the equipment side based on configuration information of the applications when the applications are installed and is used for indicating the applications to be monitored and monitoring contents on the equipment side;
Based on the monitoring results of the plurality of applications, issuing control instructions aiming at target applications in the plurality of applications to the equipment end;
the device side is used for executing first control on the target application based on a target event, wherein the first control comprises at least one of starting the application, closing the application, unloading the application and upgrading the application;
The target event comprises the control instruction and/or the monitoring result of the target application monitored by the equipment end accords with a preset condition, and the preset condition is recorded in the monitoring file.
10. The method for controlling applications according to claim 9, wherein before receiving the monitoring results of the plurality of applications sent by the device side, the method further comprises:
responding to the creation of a task, acquiring created task information, wherein the task information comprises configuration information of an application to be installed and a packaging file, and the packaging file comprises a plurality of application files required by the application to be installed;
analyzing the task information to generate installation information, wherein the installation information comprises storage paths of a plurality of application files required by the application to be installed and configuration information corresponding to each application file;
and transmitting the installation information to the equipment end so that the equipment end downloads the application files from the storage path, and sequentially installing a plurality of application files based on the configuration information according to the installation sequence of the application files.
11. The method for controlling applications according to claim 9, wherein before receiving the monitoring results of the plurality of applications sent by the device side, the method further comprises:
Responding to the creation of a task, acquiring created task information, wherein the task information comprises a packaging file, and the packaging file comprises a plurality of application files required by an application to be installed, wherein a script file is carried in a catalog of the packaging file;
The packaged file is issued to the equipment end, so that after the equipment end decompresses the packaged file, configuration information corresponding to each application file is generated based on the script file; and installing a plurality of application files in turn according to the installation sequence of the application files based on the configuration information.
12. The method according to claim 10 or 11, wherein the installation order is recorded in the task information, or the installation order is obtained by the cloud based on an association relationship between a plurality of the application files.
13. The control method for an application according to claim 10 or 11, characterized in that the method further comprises:
Receiving task progress changing information aiming at the task information, wherein the task progress changing information is used for indicating the installation progress adjustment of the application to be installed;
Acquiring progress information corresponding to the equipment end, wherein the progress information comprises the current progress of the application to be installed;
Based on the progress information, performing a second control corresponding to the task progress change information, the second control including at least one of canceling installation of the application to be installed, suspending installation of the application to be installed, and deleting the application file.
14. The method according to claim 13, wherein the performing, based on the progress information, the second control corresponding to the task progress change information includes:
Determining an execution end where the current progress is located based on the progress information;
if the execution end is the cloud end, executing the second control by the cloud end;
and if the executing end is the equipment end, sending an adjustment instruction corresponding to the progress change information to the equipment end so as to enable the equipment end to execute the second control.
15. The method for controlling applications according to claim 9, wherein the issuing, to the device side, a control instruction for a target application among the plurality of applications based on the monitoring results of the plurality of applications includes at least one of:
Displaying a plurality of monitoring results, and responding to control operation of the monitoring results of the target application, and issuing a control instruction of the target application to the equipment end;
Determining a target application of which the monitoring result is in a target running state in a plurality of applications, and issuing a control instruction aiming at the target application to the equipment end so as to enable the target application to deviate from the target running state;
And generating a control instruction aiming at the target application based on the monitoring result and the application required by the current service.
16. The method for controlling an application according to claim 15, wherein the monitoring result includes an operation state of the application, and the generating a control instruction for the target application based on the monitoring result and an application required by a current service includes:
acquiring a plurality of first applications supporting the current service;
acquiring running states of a plurality of first applications at the equipment end;
And generating a starting command corresponding to a second application in which the running state is not running in the plurality of first applications, so that the equipment end starts the second application.
17. The method for controlling an application according to claim 16, wherein the generating a start command corresponding to a second application, which is not running in the running state among the plurality of first applications, includes:
determining whether the second application is a master application of the current service;
If yes, after the starting command is sent, whether the main application is started successfully or not is detected;
And after the main application is successfully started, sending a starting command to a third application, wherein the third application is an application which is not the main application in the second application.
18. The application control system is characterized by comprising a cloud end and a plurality of equipment ends connected with the cloud end; wherein,
The device side is configured to monitor a plurality of applications on the device side based on a monitoring file, wherein the monitoring file is generated based on configuration information of the applications when the applications are installed, and the monitoring file is used for indicating the applications to be monitored;
The cloud end is configured to receive monitoring results of a plurality of applications sent by the equipment end and send control instructions to the equipment end based on the monitoring results;
The device side is further configured to perform a first control on a target application of a plurality of the applications based on a target event in response to arrival of the target event, the first control including at least one of starting the application, closing the application, uninstalling the application, and upgrading the application;
The target event includes receiving the control instruction, and/or the device side monitors that a monitoring result of the target application meets a preset condition, where the preset condition is recorded in the monitoring file.
19. An electronic device comprising a processor and a memory, and a computer program stored on the memory and executable on the processor, which processor when executed implements the method of controlling an application according to any one of claims 1-8, or implements the method of controlling an application according to any one of claims 9-17.
20. A computer-readable storage medium, characterized in that a computer program stored thereon causes a processor to execute the control method of an application according to any one of claims 1-8 or to implement the control method of an application according to any one of claims 9-17.
CN202410233107.4A 2024-02-29 2024-02-29 Application control method, system, equipment and medium Pending CN118093316A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202410233107.4A CN118093316A (en) 2024-02-29 2024-02-29 Application control method, system, equipment and medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202410233107.4A CN118093316A (en) 2024-02-29 2024-02-29 Application control method, system, equipment and medium

Publications (1)

Publication Number Publication Date
CN118093316A true CN118093316A (en) 2024-05-28

Family

ID=91158545

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202410233107.4A Pending CN118093316A (en) 2024-02-29 2024-02-29 Application control method, system, equipment and medium

Country Status (1)

Country Link
CN (1) CN118093316A (en)

Similar Documents

Publication Publication Date Title
US11637837B2 (en) Secure, non-disruptive firmware updating
US20140075438A1 (en) Method, server, and system for starting an application
US9253265B2 (en) Hot pluggable extensions for access management system
US9003392B2 (en) Use of cloning in maintenance of virtual appliances
CN108196915B (en) Code processing method and device based on application container engine and storage medium
US8239557B2 (en) Virtualization management using a centralized server
CN109120678A (en) The method and apparatus of service tray for distributed memory system
JP2019145129A (en) System and method for workflow orchestration for use with cloud computing environment
US20040060035A1 (en) Automated method and system for building, deploying and installing software resources across multiple computer systems
US11106453B2 (en) Method and system for a client to server deployment via an online distribution platform
US20140259009A1 (en) Performing unattended software installation
CN113569987A (en) Model training method and device
US20160342408A1 (en) Rolling upgrade of a distributed application
GB2333865A (en) Synchronised updating of interoperating software
US8423996B2 (en) Delivery system, server device, terminal device, and delivery method
CN104899116B (en) Method, source server, destination server and the system of data backup
CN103617058B (en) QNX-based system and method for installing and uninstalling application software
US20100293201A1 (en) Nfs agent upgrade
CN110543335A (en) Application program configuration management method and system
CN118093316A (en) Application control method, system, equipment and medium
CN115309457A (en) Application instance restarting method and device, electronic equipment and readable storage medium
CN114115943A (en) Version updating method, system, medium and equipment supporting breakpoint continuous transmission
CN108733391A (en) A kind of method and apparatus of dynamic resource allocation
CN110572442A (en) Method and system for configuring file path
CN111008035B (en) Software operation and maintenance method, electronic equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication