CN113220367A - Applet running method and device, electronic equipment and storage medium - Google Patents

Applet running method and device, electronic equipment and storage medium Download PDF

Info

Publication number
CN113220367A
CN113220367A CN202110518939.7A CN202110518939A CN113220367A CN 113220367 A CN113220367 A CN 113220367A CN 202110518939 A CN202110518939 A CN 202110518939A CN 113220367 A CN113220367 A CN 113220367A
Authority
CN
China
Prior art keywords
version information
applet
target
execution file
candidate
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
CN202110518939.7A
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.)
Beijing Baidu Netcom Science and Technology Co Ltd
Original Assignee
Beijing Baidu Netcom Science and Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Baidu Netcom Science and Technology Co Ltd filed Critical Beijing Baidu Netcom Science and Technology Co Ltd
Priority to CN202110518939.7A priority Critical patent/CN113220367A/en
Publication of CN113220367A publication Critical patent/CN113220367A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/445Program loading or initiating
    • G06F9/44521Dynamic linking or loading; Link editing at or after load time, e.g. Java class loading
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/54Interprogram communication
    • G06F9/546Message passing systems or structures, e.g. queues
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/54Interprogram communication
    • G06F9/547Remote procedure calls [RPC]; Web services
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2209/00Indexing scheme relating to G06F9/00
    • G06F2209/54Indexing scheme relating to G06F9/54
    • G06F2209/541Client-server

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Stored Programmes (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The disclosure provides an applet running method and device, electronic equipment and a storage medium, and relates to the technical field of computers, in particular to the technical field of artificial intelligence such as deep learning and cloud computing. The specific implementation scheme is as follows: receiving a request message sent by a client of a host application program, wherein the request message comprises: a target applet identifier, and current version information of a host application; determining a target small program according to the target small program identification, wherein the target small program is provided with a plurality of corresponding candidate execution file packages; determining a target execution file package from a plurality of candidate execution file packages according to the current version information; and the target execution file packet is sent to the client, and the target execution file packet matched with the current version information of the host application program is provided for the client of the host application program, so that the loading performance of the host application program for the applet is effectively improved, and the overall operation performance of the applet is effectively improved.

Description

Applet running method and device, electronic equipment and storage medium
Technical Field
The present disclosure relates to the field of computer technologies, and in particular, to the field of artificial intelligence technologies such as deep learning and cloud computing, and in particular, to an applet running method and apparatus, an electronic device, and a storage medium.
Background
Artificial intelligence is the subject of research that makes computers simulate some human mental processes and intelligent behaviors (such as learning, reasoning, thinking, planning, etc.), both at the hardware level and at the software level. Artificial intelligence hardware technologies generally include technologies such as sensors, dedicated artificial intelligence chips, cloud computing, distributed storage, big data processing, and the like; the artificial intelligence software technology mainly comprises a computer vision technology, a voice recognition technology, a natural language processing technology, a machine learning technology, a deep learning technology, a big data processing technology, a knowledge map technology and the like.
In the related art, a developer develops an execution file package of an applet on a developer tool platform, the execution file package of the applet is issued to an applet package management platform, the applet package management platform verifies the execution file package, and after the verification is passed, the application program of a host can be supported to load the applet.
Disclosure of Invention
The disclosure provides an applet running method, an applet running device, an electronic device, a storage medium and a computer program product.
According to a first aspect of the present disclosure, there is provided an applet operating method including: receiving a request message sent by a client of a host application program, wherein the request message comprises: a target applet identity, and current version information of the host application; determining a target applet according to the target applet identifier, wherein the target applet has a plurality of corresponding candidate execution file packages; determining a target execution file package from the candidate execution file packages according to the current version information; and sending the target execution file package to the client.
According to a second aspect of the present disclosure, there is provided an applet operating method including: when an opening request of an applet is received, acquiring a target applet identifier of the applet and current version information of a host application program; generating a request message according to the target small program identification and the current version information, and sending the request message to a server; and receiving a target execution file packet sent by the server, wherein the target execution file packet is determined by the server according to the target applet identifier and the current version information, and the target execution file packet is matched with the current version information.
According to a third aspect of the present disclosure, there is provided an applet operating apparatus including: a first receiving module, configured to receive a request message sent by a client of a host application, where the request message includes: a target applet identity, and current version information of the host application; a first determining module, configured to determine a target applet according to the target applet identifier, where the target applet has a plurality of corresponding candidate execution packages; a second determining module, configured to determine a target execution portfolio from among the multiple candidate execution portfolios according to the current version information; and the sending module is used for sending the target execution file packet to the client.
According to a fourth aspect of the present disclosure, there is provided an applet operating apparatus including: the second acquisition module is used for acquiring the target applet identification of the applet and the current version information of the host application program when receiving an applet opening request; the third generation module is used for generating a request message according to the target applet identifier and the current version information and sending the request message to a server; and the second receiving module is used for receiving a target execution file packet sent by the server, wherein the target execution file packet is determined by the server according to the target applet identifier and the current version information, and the target execution file packet is matched with the current version information.
According to a fifth aspect of the present disclosure, there is provided an electronic device comprising: at least one processor; and a memory communicatively coupled to the at least one processor; wherein the memory stores instructions executable by the at least one processor to enable the at least one processor to perform a method of operating an applet of an embodiment of the disclosure.
According to a sixth aspect of the present disclosure, a non-transitory computer-readable storage medium storing computer instructions for causing a computer to perform a method of running a applet disclosed in an embodiment of the present disclosure is presented.
According to a seventh aspect of the present disclosure, a computer program product is proposed, which comprises a computer program, which when executed by a processor implements a method of running an applet as disclosed in an embodiment of the present disclosure.
It should be understood that the statements in this section do not necessarily identify key or critical features of the embodiments of the present disclosure, nor do they limit the scope of the present disclosure. Other features of the present disclosure will become apparent from the following description.
Drawings
The drawings are included to provide a better understanding of the present solution and are not to be construed as limiting the present disclosure. Wherein:
FIG. 1 is a schematic diagram according to a first embodiment of the present disclosure;
FIG. 2 is a schematic diagram according to a second embodiment of the present disclosure;
FIG. 3 is a schematic diagram of an application in an embodiment of the present disclosure;
FIG. 4 is a schematic diagram according to a third embodiment of the present disclosure;
FIG. 5 is a schematic diagram according to a fourth embodiment of the present disclosure;
FIG. 6 is a schematic diagram according to a fifth embodiment of the present disclosure;
FIG. 7 is a schematic diagram according to a sixth embodiment of the present disclosure;
FIG. 8 shows a schematic block diagram of an example electronic device that may be used to implement embodiments of the present disclosure.
Detailed Description
Exemplary embodiments of the present disclosure are described below with reference to the accompanying drawings, in which various details of the embodiments of the disclosure are included to assist understanding, and which are to be considered as merely exemplary. Accordingly, those of ordinary skill in the art will recognize that various changes and modifications of the embodiments described herein can be made without departing from the scope and spirit of the present disclosure. Also, descriptions of well-known functions and constructions are omitted in the following description for clarity and conciseness.
Fig. 1 is a schematic diagram according to a first embodiment of the present disclosure.
It should be noted that the main execution body of the method for running the applet in this embodiment is a device for running the applet, the device may be implemented in a software and/or hardware manner, the device may be configured in an electronic device, and the electronic device may include, but is not limited to, a terminal, a server, and the like.
The embodiment of the disclosure relates to the technical field of artificial intelligence such as deep learning and cloud computing.
Wherein, Artificial Intelligence (Artificial Intelligence), english is abbreviated as AI. The method is a new technical science for researching and developing theories, methods, technologies and application systems for simulating, extending and expanding human intelligence.
Deep learning is the intrinsic law and expression level of the learning sample data, and the information obtained in the learning process is very helpful for the interpretation of data such as characters, images and sounds. The final goal of deep learning is to make a machine capable of human-like analytical learning, and to recognize data such as characters, images, and sounds.
And cloud computing refers to accessing a flexibly extensible shared physical or virtual resource pool through a network, and resources may include servers, operating systems, networks, software, applications, storage devices, and the like, and may be a technical system that deploys and manages resources in a self-service manner on demand. Through the cloud computing technology, high-efficiency and strong data processing capacity can be provided for technical application and model training of artificial intelligence, block chains and the like.
The method for operating the applet in this embodiment may be applied to a server, so that the server issues the corresponding applet execution file package to a client of a host application program, so as to support the host application program to load and open the corresponding applet execution file package.
As shown in fig. 1, the method for running the applet includes:
s101: receiving a request message sent by a client of a host application program, wherein the request message comprises: a target applet identification, and current version information of the host application.
As one example, an applet in embodiments of the disclosure may be hosted on a host application that is installable on an electronic device. The electronic device may be a mobile terminal, and the mobile terminal may be a hardware device with various operating systems, such as a mobile phone, a tablet computer, and a personal digital assistant.
The host application program is provided with a corresponding client, and the client can be installed and run in the electronic equipment to provide corresponding program functions for the outside.
In some embodiments, the client of the host application may provide an interface for loading an applet to a user, and when it is monitored that the interface is called, may provide a plurality of candidate applet identifiers to the user, and in response to an applet selecting instruction input by the user, the candidate applet identifier selected by the applet selecting instruction is used as a target applet identifier, which indicates that the user currently has a need to load a target applet to which the target applet identifier belongs in the host application.
The target applet identifier may be used to uniquely identify the target applet.
In the embodiment of the present disclosure, when the electronic device monitors that the host application triggers loading of the target applet to which the target applet identifier belongs, the electronic device may trigger obtaining of the version information of the host application, so that the currently obtained version information is used as the current version information, where the current version information may specifically be, for example, a current version number, or may also be any other possible information capable of identifying the current version of the host application, and the information is not limited thereto.
When it is monitored that the host application triggers loading of the target applet belonging to the target applet identifier, a request message can be generated according to the target applet identifier and the current version information, and the request message is sent to the server.
S102: and determining a target small program according to the target small program identification, wherein the target small program is provided with a plurality of corresponding candidate execution file packages.
In some embodiments, after receiving the request message, the server may analyze the request message to obtain the target applet identifier and the current version information therein, and then may determine, based on a plurality of candidate applets pre-stored in the applet package management platform, a candidate applet corresponding to the target applet identifier as the target applet, and read a plurality of candidate execution file packages corresponding to the target applet.
That is to say, in the embodiment of the present disclosure, for each candidate applet, a plurality of matching execution file packages are generated in advance and serve as a plurality of corresponding candidate execution file packages, different candidate execution file packages may be used to adapt to different version information of the host application program, so as to assist in subsequently acquiring a candidate execution file package adapted to the current version information of the host application program, avoid that the execution file package delivered to the client of the host application program is too bulky, assist in improving the delivery efficiency of the execution file package, and thereby effectively improve the loading performance of the host application program for the applet.
It is understood that the applet execution package may be similar to the EXE execution file of the software, the applet execution package may include not only the service logic code file, but also a style file, a configuration file, and the like, and the client of the host application may load the service function provided by the corresponding applet by loading and running the service logic code file and the like in the applet execution package.
When the candidate execution file packages corresponding to the target applet are obtained, the target applet identifier can be used to obtain the candidate execution file packages of the corresponding target applet. The obtaining position of the candidate execution file package may be obtained from a local cache of the server, or may be obtained from a cloud platform of a service corresponding to the applet, which is not limited to this.
S103: and determining a target execution file package from the plurality of candidate execution file packages according to the current version information.
After the target applet is determined according to the target applet identifier and a plurality of candidate execution file packages corresponding to the target applet are obtained, the matching condition of each candidate execution file package and the current version information can be determined, and therefore the candidate execution file packages obtained through matching are used as the target execution file packages.
In the embodiment of the present disclosure, in order to effectively improve matching efficiency, reduce complexity of program code development, and implement function optimization of an execution file package of an applet on different version information of a host application, candidate applet version information (candidate applet version information, which may be, for example, an applet version number) corresponding to a candidate execution file package may also be configured in advance for the candidate execution file package, that is, different candidate execution file packages may all be loaded to implement a service function of a corresponding applet, but version information of applets corresponding to different candidate execution file packages may be different.
Therefore, in the embodiment of the disclosure, the target execution file package can be determined from the multiple candidate execution file packages according to the current version information, the multiple candidate applet version information corresponding to the multiple candidate execution file packages respectively can be determined, the candidate applet version information matched with the current version information can be selected from the multiple candidate applet version information, and the candidate execution file package corresponding to the matched candidate applet version information is used as the target execution file package, so that the matching efficiency can be effectively improved, the complexity of program code development is reduced, the applet execution file package matched with the current version information of the host application program can be quickly and accurately located, and the loading and issuing performance of the whole applet is improved.
S104: and sending the target execution file packet to the client.
After the target execution file package is determined from the multiple candidate execution file packages, the target execution file package can be sent to the client side of the host application program, so that the host application program is supported to load and open the corresponding applet.
In this embodiment, by receiving a request message sent by a client of a host application, the request message includes: the target applet has a plurality of corresponding candidate execution file packages, the target execution file packages are determined from the candidate execution file packages according to the current version information, and the target execution file packages are sent to the client.
Fig. 2 is a schematic diagram according to a second embodiment of the present disclosure.
As shown in fig. 2, the method for running the applet includes:
s201: and acquiring a compatible execution file package of the target applet.
The compatible execution file package may be an execution file package compatible with the lowest version information of the host application program, and generally, the transmission resource occupied by the compatible execution file package is small.
The compatible execution file package is matched with the target version information of the host application program, and the target version information is the lowest version information in the plurality of reference version information.
It is to be understood that, as the host application program is continuously upgraded and developed, the host application program may have a plurality of version information, and the plurality of version information may be referred to as a plurality of reference version information, and the target version information may be the lowest version information among the plurality of reference version information, or may be lower version information among the plurality of reference version information, which is not limited thereto.
The obtained compatible execution file package of the target applet can be used for assisting in performing the subpackage optimization compilation, and the execution file package obtained by the subpackage optimization compilation can be called a subsequent stable execution file package.
That is to say, in the embodiment of the present disclosure, it is supported that the sub-package compilation optimization is performed with the compatible execution file package adapted to the minimum version information of the host application as a reference to generate a plurality of stable execution file packages adapted to different version information, and since the transmission resource generally occupied by the compatible execution file package adapted to the minimum version information of the host application is small, the data transmission efficiency in the generation process of the execution file package can be effectively ensured, the consumption of the computation resource is reduced, and the operation efficiency of the applet is comprehensively ensured.
S202: and generating a plurality of stable execution file packages respectively corresponding to a plurality of reference version information of the host application program according to the compatible execution file package, wherein the current version information belongs to the plurality of reference version information.
After obtaining the compatible execution package of the target applet, a plurality of stable execution packages respectively corresponding to the plurality of reference version information of the host application program may be generated according to the compatible execution package.
The host application may have multiple version information, and the multiple version information may be referred to as multiple reference version information, and the stable execution file package adapted to different reference version information may have different optimization functions, for example, the stable execution file package adapted to the reference version information a may carry the optimization function a, and the stable execution file package adapted to the reference version information B may carry the optimization function B.
Therefore, in the embodiment of the present disclosure, a plurality of stable execution file packages respectively corresponding to a plurality of reference version information of the host application program may be generated according to the compatible execution file package, so that the plurality of stable execution file packages can carry a plurality of corresponding optimization functions for the target applet, and thus, while performing the sub-package compilation optimization, the optimization functions carried by the stable execution file packages can meet the personalized version requirements of the host application program, and the operation effect of the applet is improved.
Optionally, in some embodiments, the generating, according to the compatible execution package, a plurality of stable execution packages corresponding to the plurality of reference version information of the host application program may be to acquire a plurality of program code files corresponding to the plurality of reference version information, respectively, and generate, according to the compatible execution package, a plurality of stable execution packages corresponding to the plurality of reference version information of the host application program, respectively, in combination with the plurality of program code files.
The program code file may be a service logic code file carrying an optimization function of the applet, or a style file, a configuration file, or the like corresponding to the optimization function.
The program code file carrying the optimization function of the applet may be determined according to a development document of the applet, which is not limited to this.
The plurality of program code files respectively corresponding to the plurality of reference version information refer to the optimization function of the applet carried by the corresponding program code file, and can be compatible with the host application program corresponding to the reference version information.
Therefore, the compatible execution file package is combined with the program code files to generate a plurality of stable execution file packages corresponding to the reference version information of the host application program, the host application program compatibility of the corresponding reference version information can be supported, the compatible stability of the stable execution file packages in the host application program can be effectively guaranteed, and the loading performance of the host application program on the corresponding stable execution file packages can be effectively improved in an auxiliary mode.
S203: and taking the plurality of stable execution file packages as a plurality of candidate execution file packages.
S204: a plurality of candidate applet version information corresponding to the plurality of reference version information, respectively, is generated.
After the plurality of stable execution packages are generated, the plurality of stable execution file packages can be directly used as a plurality of candidate execution file packages, and then a plurality of candidate small program version information respectively corresponding to the plurality of reference version information can be generated, so that the subsequent steps are triggered.
If the reference version information is 1.0, the candidate small program version information corresponding to the reference version information of 1.0 may also be configured to be 1.0, if the reference version information is 2.0, the candidate small program version information corresponding to the reference version information of 2.0 may also be configured to be 2.0, and if the reference version information is 3.0, the candidate small program version information corresponding to the reference version information of 3.0 may also be configured to be 3.0, which is not limited thereto.
S205: and marking a plurality of corresponding candidate execution file packages by adopting a plurality of candidate applet version information.
The candidate applet version information corresponding to the reference version information is generated, and the candidate execution file packets corresponding to the candidate applet version information can be directly marked by the candidate applet version information, so that the marking processing logic of the version information of the execution file packet is simpler, and the search efficiency of the target execution file packet is effectively improved in an auxiliary manner.
As shown in fig. 3, fig. 3 is a schematic diagram of an application in the embodiment of the present disclosure, which includes: the small program package management platform manages a plurality of candidate execution file packages, the candidate execution file packages are respectively provided with a plurality of corresponding candidate small program version information, different candidate execution file packages are used for adapting host application programs with different version information, and therefore when the host application programs load the execution file packages of the target small programs from the small program package management platform, the candidate execution file packages which are adapted to the current version information of the host application programs can be used as the target execution file packages and are issued to the corresponding host application programs.
S206: receiving a request message sent by a client of a host application program, wherein the request message comprises: a target applet identification, and current version information of the host application.
S207: and determining a target small program according to the target small program identification, wherein the target small program is provided with a plurality of corresponding candidate execution file packages.
S208: and determining a target execution file package from the plurality of candidate execution file packages according to the current version information.
S209: and sending the target execution file packet to the client.
For the description of S206-S209, reference may be made to the above embodiments, which are not described herein again.
In this embodiment, by receiving a request message sent by a client of a host application, the request message includes: the target applet has a plurality of corresponding candidate execution file packages, the target execution file packages are determined from the candidate execution file packages according to the current version information, and the target execution file packages are sent to the client. The method supports the sub-packet compiling optimization executed by taking the compatible execution file packet which is adapted to the lowest version information of the host application program as a reference so as to generate a plurality of stable execution file packets which are adapted to different version information. When the candidate applet version information corresponding to the reference version information is generated, the candidate execution file packages corresponding to the candidate applet version information can be directly marked by the candidate applet version information, so that the marking processing logic of the version information of the execution file package is simpler, and the search efficiency of the target execution file package is effectively improved in an auxiliary manner.
Fig. 4 is a schematic diagram according to a third embodiment of the present disclosure.
The method for operating the applet in this embodiment may be applied to a client, where the client may specifically be a client of a host application, and the client of the host application may receive an execution file package of the corresponding applet, which is issued by a server, and load and open the execution file package of the corresponding applet.
As shown in fig. 4, the method for running the applet includes:
s401: when an opening request of the small program is received, the target small program identification of the small program and the current version information of the host application program are obtained.
It should be noted that, for the description and explanation of the terms in this embodiment that are the same as those in the above embodiment, reference may be made to the above embodiment, and details are not described herein.
The method includes the steps of receiving an applet opening request, and triggering loading of a target applet in a host application program, so that in the embodiment of the disclosure, when the applet opening request is received, a target applet identifier of the applet and current version information of the host application program can be obtained, and then, subsequent steps are triggered.
S402: and generating a request message according to the target applet identification and the current version information, and sending the request message to a server.
After the target applet identifier of the applet and the current version information of the host application program are obtained, the corresponding request generation interface can be called in real time to generate a request message according to the target applet identifier and the current version information, and the request message is sent to the server, so that the target execution file package is requested to the server based on the request message.
For the processing logic for obtaining the target execution file package by the server side search, reference may be made to the foregoing embodiment specifically, and details are not described here.
S403: and receiving a target execution file packet sent by the server, wherein the target execution file packet is determined by the server according to the target applet identifier and the current version information, and the target execution file packet is matched with the current version information.
After receiving the target execution file packet sent by the server, the target execution file packet can be directly loaded and run locally at the client of the host application program, and the target execution file packet is determined by the server according to the target applet identifier and the current version information and is matched with the current version information, so that better applet loading performance can be achieved.
In the embodiment, when an opening request of the applet is received, a target applet identifier of the applet and current version information of the host application program are obtained, a request message is generated according to the target applet identifier and the current version information, the request message is sent to the server, and a target execution file package sent by the server is received, wherein the target execution file package is determined by the server according to the target applet identifier and the current version information and is matched with the current version information.
Fig. 5 is a schematic diagram according to a fourth embodiment of the present disclosure.
As shown in fig. 5, the applet running device 50, applied to a server, includes:
a first receiving module 501, configured to receive a request message sent by a client of a host application, where the request message includes: a target applet identification, and current version information of the host application.
A first determining module 502, configured to determine a target applet according to a target applet identifier, where the target applet has a plurality of corresponding candidate execution packages.
The second determining module 503 is configured to determine the target execution portfolio from the multiple candidate execution portfolios according to the current version information.
A sending module 504, configured to send the target execution file package to the client.
In some embodiments of the present disclosure, the second determining module 503 is specifically configured to:
determining a plurality of candidate applet version information corresponding to the plurality of candidate execution file packages, respectively;
selecting candidate small program version information matched with the current version information from the plurality of candidate small program version information; and
and taking the candidate execution file packet corresponding to the matched candidate applet version information as a target execution file packet.
In some embodiments of the present disclosure, as shown in fig. 6, the applet running device 60 includes: the first receiving module 601, the first determining module 602, the second determining module 603, and the sending module 604 further include:
a first obtaining module 605, configured to obtain a compatible execution package of the target applet;
a first generating module 606, configured to generate, according to the compatible execution package, multiple stable execution packages corresponding to multiple pieces of reference version information of the host application program, respectively, where the current version information belongs to the multiple pieces of reference version information, and the multiple stable execution packages are used as multiple candidate execution packages.
In some embodiments of the present disclosure, the first generating module 606 is specifically configured to:
acquiring a plurality of program code files respectively corresponding to a plurality of reference version information;
and combining the compatible execution file package with the program code files to generate a plurality of stable execution file packages respectively corresponding to the reference version information of the host application program.
In some embodiments of the present disclosure, as shown in fig. 6, further comprising:
a second generating module 607, configured to generate a plurality of candidate applet version information corresponding to the plurality of reference version information, respectively.
The marking module 608 is configured to mark a plurality of candidate execution file packages corresponding to the plurality of candidate applet version information.
In some embodiments of the present disclosure, wherein the compatible execution package matches target version information of the host application, the target version information is the lowest version information among the plurality of reference version information.
It is understood that the applet running device 60 in fig. 6 of this embodiment and the applet running device 50 in the above embodiment, the first receiving module 601 and the first receiving module 501 in the above embodiment, the first determining module 602 and the first determining module 502 in the above embodiment, the second determining module 603 and the second determining module 503 in the above embodiment, and the sending module 604 and the sending module 504 in the above embodiment may have the same functions and structures.
It should be noted that the foregoing explanation of the applet running method is also applicable to the applet running apparatus of this embodiment, and is not repeated herein.
In this embodiment, by receiving a request message sent by a client of a host application, the request message includes: the target applet has a plurality of corresponding candidate execution file packages, the target execution file packages are determined from the candidate execution file packages according to the current version information, and the target execution file packages are sent to the client.
Fig. 7 is a schematic diagram according to a sixth embodiment of the present disclosure.
As shown in fig. 7, the applet running device 70, applied to the client, includes:
a second obtaining module 701, configured to obtain a target applet identifier of the applet and current version information of the host application program when an applet opening request is received.
A third generating module 702, configured to generate a request message according to the target applet identifier and the current version information, and send the request message to the server.
The second receiving module 703 is configured to receive a target execution file package sent by the server, where the target execution file package is determined by the server according to the target applet identifier and the current version information, and the target execution file package is adapted to the current version information.
It should be noted that the foregoing explanation of the applet running method is also applicable to the applet running apparatus of this embodiment, and is not repeated herein.
In the embodiment, when an opening request of the applet is received, a target applet identifier of the applet and current version information of the host application program are obtained, a request message is generated according to the target applet identifier and the current version information, the request message is sent to the server, and a target execution file package sent by the server is received, wherein the target execution file package is determined by the server according to the target applet identifier and the current version information and is matched with the current version information.
The present disclosure also provides an electronic device, a readable storage medium, and a computer program product according to embodiments of the present disclosure.
FIG. 8 shows a schematic block diagram of an example electronic device that may be used to implement embodiments of the present disclosure. Electronic devices are intended to represent various forms of digital computers, such as laptops, desktops, workstations, personal digital assistants, servers, blade servers, mainframes, and other appropriate computers. The electronic device may also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions, are meant to be examples only, and are not meant to limit implementations of the disclosure described and/or claimed herein.
As shown in fig. 8, the apparatus 800 includes a computing unit 801 that can perform various appropriate actions and processes according to a computer program stored in a Read Only Memory (ROM)802 or a computer program loaded from a storage unit 808 into a Random Access Memory (RAM) 803. In the RAM 803, various programs and data required for the operation of the device 800 can also be stored. The calculation unit 801, the ROM 802, and the RAM 803 are connected to each other by a bus 804. An input/output (I/O) interface 805 is also connected to bus 804.
A number of components in the device 800 are connected to the I/O interface 805, including: an input unit 806, such as a keyboard, a mouse, or the like; an output unit 807 such as various types of displays, speakers, and the like; a storage unit 808, such as a magnetic disk, optical disk, or the like; and a communication unit 809 such as a network card, modem, wireless communication transceiver, etc. The communication unit 809 allows the device 800 to exchange information/data with other devices via a computer network such as the internet and/or various telecommunication networks.
Computing unit 801 may be a variety of general and/or special purpose processing components with processing and computing capabilities. Some examples of the computing unit 801 include, but are not limited to, a Central Processing Unit (CPU), a Graphics Processing Unit (GPU), various dedicated Artificial Intelligence (AI) computing chips, various computing units running machine learning model algorithms, a Digital Signal Processor (DSP), and any suitable processor, controller, microcontroller, and the like. The calculation unit 801 executes the respective methods and processes described above, such as the execution method of the applet.
For example, in some embodiments, the method of execution of the applet may be implemented as a computer software program tangibly embodied in a machine-readable medium, such as storage unit 808. In some embodiments, part or all of the computer program can be loaded and/or installed onto device 800 via ROM 802 and/or communications unit 809. When the computer program is loaded into the RAM 803 and executed by the computing unit 801, one or more steps of the method of execution of the applet described above may be performed. Alternatively, in other embodiments, the computing unit 801 may be configured to perform the method of execution of the applet by any other suitable means (e.g., by means of firmware).
Various implementations of the systems and techniques described here above may be implemented in digital electronic circuitry, integrated circuitry, Field Programmable Gate Arrays (FPGAs), Application Specific Integrated Circuits (ASICs), Application Specific Standard Products (ASSPs), system on a chip (SOCs), load programmable logic devices (CPLDs), computer hardware, firmware, software, and/or combinations thereof. These various embodiments may include: implemented in one or more computer programs that are executable and/or interpretable on a programmable system including at least one programmable processor, which may be special or general purpose, receiving data and instructions from, and transmitting data and instructions to, a storage system, at least one input device, and at least one output device.
Program code for implementing the methods of the present disclosure may be written in any combination of one or more programming languages. These program codes may be provided to a processor or controller of a general purpose computer, special purpose computer, or other programmable data processing apparatus, such that the program codes, when executed by the processor or controller, cause the functions/operations specified in the flowchart and/or block diagram to be performed. The program code may execute entirely on the machine, partly on the machine, as a stand-alone software package partly on the machine and partly on a remote machine or entirely on the remote machine or server.
In the context of this disclosure, a machine-readable medium may be a tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. The machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. More specific examples of a machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
To provide for interaction with a user, the systems and techniques described here can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to a user; and a keyboard and a pointing device (e.g., a mouse or a trackball) by which a user can provide input to the computer. Other kinds of devices may also be used to provide for interaction with a user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user may be received in any form, including acoustic, speech, or tactile input.
The systems and techniques described here can be implemented in a computing system that includes a back-end component (e.g., as a data server), or that includes a middleware component (e.g., an application server), or that includes a front-end component (e.g., a user computer having a graphical user interface or a web browser through which a user can interact with an implementation of the systems and techniques described here), or any combination of such back-end, middleware, or front-end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: local Area Networks (LANs), Wide Area Networks (WANs), the internet, and blockchain networks.
The computer system may include clients and servers. A client and server are generally remote from each other and typically interact through a communication network. The relationship of client and server arises by virtue of computer programs running on the respective computers and having a client-server relationship to each other. The Server can be a cloud Server, also called a cloud computing Server or a cloud host, and is a host product in a cloud computing service system, so as to solve the defects of high management difficulty and weak service expansibility in the traditional physical host and VPS service ("Virtual Private Server", or simply "VPS"). The server may also be a server of a distributed system, or a server incorporating a blockchain.
It should be understood that various forms of the flows shown above may be used, with steps reordered, added, or deleted. For example, the steps described in the present disclosure may be executed in parallel, sequentially, or in different orders, as long as the desired results of the technical solutions disclosed in the present disclosure can be achieved, and the present disclosure is not limited herein.
The above detailed description should not be construed as limiting the scope of the disclosure. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions may be made in accordance with design requirements and other factors. Any modification, equivalent replacement, and improvement made within the spirit and principle of the present disclosure should be included in the scope of protection of the present disclosure.

Claims (17)

1. An applet running method applied to a server includes:
receiving a request message sent by a client of a host application program, wherein the request message comprises: a target applet identity, and current version information of the host application;
determining a target applet according to the target applet identifier, wherein the target applet has a plurality of corresponding candidate execution file packages;
determining a target execution file package from the candidate execution file packages according to the current version information; and
and sending the target execution file packet to the client.
2. The method of claim 1, wherein said determining a target execution portfolio from among the plurality of candidate execution portfolios based on the current version information comprises:
determining a plurality of candidate applet version information corresponding to the plurality of candidate execution file packages, respectively;
selecting candidate small program version information matched with the current version information from the plurality of candidate small program version information; and
and taking the candidate execution file packet corresponding to the matched candidate applet version information as the target execution file packet.
3. The method of claim 2, further comprising, prior to the receiving a request message sent by a client of a host application:
acquiring a compatible execution file package of the target applet;
generating a plurality of stable execution file packages respectively corresponding to a plurality of reference version information of the host application program according to the compatible execution file package, wherein the current version information belongs to the plurality of reference version information;
and taking the plurality of stable execution file packages as the plurality of candidate execution file packages.
4. The method of claim 3, wherein the generating, from the compatible execution bundle of files, a plurality of stable execution bundles of files corresponding to a plurality of reference version information of the host application, respectively, comprises:
acquiring a plurality of program code files respectively corresponding to the plurality of reference version information;
and combining the plurality of program code files according to the compatible execution file package to generate a plurality of stable execution file packages respectively corresponding to a plurality of reference version information of the host application program.
5. The method of claim 3, further comprising, after said treating the plurality of stable execution portfolios as the plurality of candidate execution portfolios:
generating a plurality of candidate applet version information respectively corresponding to the plurality of reference version information;
and marking the corresponding candidate execution file packages by adopting the candidate applet version information.
6. The method of any of claims 3-5, wherein the compatible execution package of files matches target version information of the host application, the target version information being the lowest version information among the plurality of reference version information.
7. An applet running method applied to a client comprises the following steps:
when an opening request of an applet is received, acquiring a target applet identifier of the applet and current version information of a host application program;
generating a request message according to the target small program identification and the current version information, and sending the request message to a server;
and receiving a target execution file packet sent by the server, wherein the target execution file packet is determined by the server according to the target applet identifier and the current version information, and the target execution file packet is matched with the current version information.
8. An applet running device applied to a server side comprises:
a first receiving module, configured to receive a request message sent by a client of a host application, where the request message includes: a target applet identity, and current version information of the host application;
a first determining module, configured to determine a target applet according to the target applet identifier, where the target applet has a plurality of corresponding candidate execution packages;
a second determining module, configured to determine a target execution portfolio from among the multiple candidate execution portfolios according to the current version information; and
and the sending module is used for sending the target execution file packet to the client.
9. The apparatus of claim 8, wherein the second determining module is specifically configured to:
determining a plurality of candidate applet version information corresponding to the plurality of candidate execution file packages, respectively;
selecting candidate small program version information matched with the current version information from the plurality of candidate small program version information; and
and taking the candidate execution file packet corresponding to the matched candidate applet version information as the target execution file packet.
10. The apparatus of claim 9, further comprising:
the first acquisition module is used for acquiring the compatible execution file package of the target applet;
and the first generation module is used for generating a plurality of stable execution file packages which respectively correspond to a plurality of reference version information of the host application program according to the compatible execution file package, wherein the current version information belongs to the plurality of reference version information, and the plurality of stable execution file packages are used as the plurality of candidate execution file packages.
11. The apparatus of claim 10, wherein the first generating module is specifically configured to:
acquiring a plurality of program code files respectively corresponding to the plurality of reference version information;
and combining the plurality of program code files according to the compatible execution file package to generate a plurality of stable execution file packages respectively corresponding to a plurality of reference version information of the host application program.
12. The apparatus of claim 10, further comprising:
a second generation module, configured to generate a plurality of candidate applet version information corresponding to the plurality of reference version information, respectively;
and the marking module is used for marking the corresponding candidate execution file packages by adopting the candidate applet version information.
13. The apparatus of any of claims 10-12, wherein the compatible execution package of files matches target version information of the host application, the target version information being a lowest version information among the plurality of reference version information.
14. An applet running device applied to a client, comprising:
the second acquisition module is used for acquiring the target applet identification of the applet and the current version information of the host application program when receiving an applet opening request;
the third generation module is used for generating a request message according to the target applet identifier and the current version information and sending the request message to a server;
and the second receiving module is used for receiving a target execution file packet sent by the server, wherein the target execution file packet is determined by the server according to the target applet identifier and the current version information, and the target execution file packet is matched with the current version information.
15. An electronic device, comprising:
at least one processor; and
a memory communicatively coupled to the at least one processor; wherein,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the method of any one of claims 1-6 or to perform the method of claim 7.
16. A non-transitory computer readable storage medium having stored thereon computer instructions for causing a computer to perform the method of any one of claims 1-6 or the method of claim 7.
17. A computer program product comprising a computer program which, when executed by a processor, implements the method according to any one of claims 1-6, or implements the method according to claim 7.
CN202110518939.7A 2021-05-12 2021-05-12 Applet running method and device, electronic equipment and storage medium Pending CN113220367A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110518939.7A CN113220367A (en) 2021-05-12 2021-05-12 Applet running method and device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110518939.7A CN113220367A (en) 2021-05-12 2021-05-12 Applet running method and device, electronic equipment and storage medium

Publications (1)

Publication Number Publication Date
CN113220367A true CN113220367A (en) 2021-08-06

Family

ID=77095250

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110518939.7A Pending CN113220367A (en) 2021-05-12 2021-05-12 Applet running method and device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN113220367A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113805973A (en) * 2021-09-26 2021-12-17 工银科技有限公司 Application program control method and device and application program development method and device
CN114237769A (en) * 2021-12-14 2022-03-25 北京人大金仓信息技术股份有限公司 Program execution method, device, equipment and storage medium
CN115617420A (en) * 2022-11-03 2023-01-17 北京百度网讯科技有限公司 Application program generation method, device, equipment and storage medium

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7131122B1 (en) * 2000-08-24 2006-10-31 International Business Machines Corporation Apparatus, system and method for detecting old version of an applet in a client brower's JVM
CN101571809A (en) * 2009-05-14 2009-11-04 阿里巴巴集团控股有限公司 Implementation method of plug-in registration and device thereof
CN108595203A (en) * 2018-04-28 2018-09-28 努比亚技术有限公司 Application function executes method, mobile terminal and computer readable storage medium
CN110389935A (en) * 2019-07-25 2019-10-29 上海连尚网络科技有限公司 A kind of method, equipment and computer storage medium starting small routine
CN111767069A (en) * 2020-06-30 2020-10-13 北京百度网讯科技有限公司 Applet processing method, server, device and storage medium
CN112433788A (en) * 2020-11-23 2021-03-02 百度在线网络技术(北京)有限公司 Applet running method and device, electronic equipment and storage medium
KR20210038862A (en) * 2020-04-28 2021-04-08 바이두 온라인 네트웍 테크놀러지 (베이징) 캄파니 리미티드 Method, device, equipment and storage medium for obtaining mini program data

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7131122B1 (en) * 2000-08-24 2006-10-31 International Business Machines Corporation Apparatus, system and method for detecting old version of an applet in a client brower's JVM
CN101571809A (en) * 2009-05-14 2009-11-04 阿里巴巴集团控股有限公司 Implementation method of plug-in registration and device thereof
CN108595203A (en) * 2018-04-28 2018-09-28 努比亚技术有限公司 Application function executes method, mobile terminal and computer readable storage medium
CN110389935A (en) * 2019-07-25 2019-10-29 上海连尚网络科技有限公司 A kind of method, equipment and computer storage medium starting small routine
KR20210038862A (en) * 2020-04-28 2021-04-08 바이두 온라인 네트웍 테크놀러지 (베이징) 캄파니 리미티드 Method, device, equipment and storage medium for obtaining mini program data
CN111767069A (en) * 2020-06-30 2020-10-13 北京百度网讯科技有限公司 Applet processing method, server, device and storage medium
CN112433788A (en) * 2020-11-23 2021-03-02 百度在线网络技术(北京)有限公司 Applet running method and device, electronic equipment and storage medium

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
丰晋军;尹战文;: "智能客户端在Microsoft Word System系统中的集成实现", 计算机系统应用, no. 10 *

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113805973A (en) * 2021-09-26 2021-12-17 工银科技有限公司 Application program control method and device and application program development method and device
CN114237769A (en) * 2021-12-14 2022-03-25 北京人大金仓信息技术股份有限公司 Program execution method, device, equipment and storage medium
CN115617420A (en) * 2022-11-03 2023-01-17 北京百度网讯科技有限公司 Application program generation method, device, equipment and storage medium
CN115617420B (en) * 2022-11-03 2024-03-01 北京百度网讯科技有限公司 Application program generation method, device, equipment and storage medium

Similar Documents

Publication Publication Date Title
CN113220367A (en) Applet running method and device, electronic equipment and storage medium
CN113342345A (en) Operator fusion method and device of deep learning framework
CN112527281B (en) Operator upgrading method and device based on artificial intelligence, electronic equipment and medium
CN113766487B (en) Cloud mobile phone information acquisition method, device, equipment and medium
CN112966824A (en) Deployment method and device of inference library and electronic equipment
CN112559631A (en) Data processing method and device of distributed graph database and electronic equipment
EP3910528A2 (en) Method, apparatus, device, and storage medium for generating response
CN115840867A (en) Generation method and device of mathematical problem solving model, electronic equipment and storage medium
CN114417780A (en) State synchronization method and device, electronic equipment and storage medium
CN113377614A (en) Generation method and device of call chain information, electronic equipment and storage medium
CN113377381A (en) Method and device for distributing small program package, electronic equipment and medium
CN113452760A (en) Verification code synchronization method and device, electronic equipment and storage medium
CN114743586B (en) Mirror image storage implementation method and device of storage model and storage medium
CN114327802B (en) Method, apparatus, device and medium for block chain access to data outside chain
CN113935069B (en) Data verification method, device and equipment based on block chain and storage medium
CN115481594B (en) Scoreboard implementation method, scoreboard, electronic equipment and storage medium
CN113704256B (en) Data identification method, device, electronic equipment and storage medium
CN111859985B (en) AI customer service model test method and device, electronic equipment and storage medium
CN114997329A (en) Method, apparatus, device, medium and product for generating a model
CN114329164A (en) Method, apparatus, device, medium and product for processing data
CN113157281A (en) Development environment creation method and device, electronic equipment and storage medium
CN112817463A (en) Method, equipment and storage medium for acquiring audio data by input method
CN115130149B (en) Block chain processing method, device, equipment and storage medium
CN113239296B (en) Method, device, equipment and medium for displaying small program
CN113220282B (en) Development processing method, device and storage medium for applet

Legal Events

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