Method, device, electronic device and storage medium for calling update function
By obtaining and parsing the function records of the software development toolkit and determining and calling the target function, the problem of the inability to call the update function caused by the application service not being synchronously upgraded after the SDK update is solved, and the reliability and user experience of the application system are improved.
Patent Information
- Application Number
- CN202311215565.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-09-19
- Publication Date
- 2025-05-16
- Estimated Expiration
- 2043-09-19
AI Technical Summary
After the SDK is updated and upgraded, the application service fails to be upgraded synchronously in time, resulting in the inability to call the update function, affecting the reliability and user experience of the application system.
By obtaining the function record matched by the updated software development toolkit, if an event trigger signal is received by the client, the trigger source information for the event trigger signal matching is determined in the function record, the target function and the target interface are determined, and the target function in the updated software development toolkit is called.
It solves the problem that the update function cannot be called in the scenario of not synchronous upgrade of the application service after SDK update and upgrade, improves the reliability of the application system and provides users with a good user experience.
Smart Images

Figure CN117193825B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of Internet technology, and in particular to a method, device, electronic device and storage medium for calling an update function. Background Art
[0002] A software development kit (SDK) is a collection of development tools for creating application software for a specific software package, software framework, hardware platform, and operating system. SDK facilitates the creation of applications through compilers, debuggers, and software frameworks, and can provide interfaces for application services to implement the calls of various functions in applications.
[0003] Currently, after the SDK is updated and upgraded, the application service needs to be manually upgraded synchronously so that when the client uses the application, the application service can correctly call the interface matching each function to complete the client task.
[0004] However, after the SDK is updated, the application service is not always able to be upgraded synchronously in time. Therefore, it is necessary to solve the problem of calling the update function in the scenario where the application service is not upgraded synchronously after the SDK is updated. Summary of the invention
[0005] The present invention provides a method, device, equipment and storage medium for calling an update function to solve the problem that the update function cannot be called when the application service is not upgraded synchronously after the SDK is updated and upgraded. While realizing the call of the update function, the reliability of the application system can be improved to bring a good user experience to the user.
[0006] According to one aspect of the present invention, a method for calling an update function is provided, the method comprising:
[0007] Get updated SDK matching feature records;
[0008] If an event trigger signal sent by the client is received, determining trigger source information matching the event trigger signal in the function record;
[0009] Determine a target function and a target interface matching the target function according to the trigger source information;
[0010] The target function in the updated software development kit is called according to the target function and the target interface matched by the target function.
[0011] According to another aspect of the present invention, there is provided a device for calling an update function, the device comprising:
[0012] A function record acquisition module, used to acquire function records matching the updated software development kit;
[0013] A trigger source information determination module, configured to determine, in the function record, trigger source information matching the event trigger signal if an event trigger signal sent by the client is received;
[0014] A target interface determination module, used to determine a target function and a target interface matching the target function according to the trigger source information;
[0015] The target function calling module is used to call the target function in the updated software development kit according to the target function and the target interface matched by the target function.
[0016] According to another aspect of the present invention, an electronic device is provided, the electronic device comprising:
[0017] at least one processor; and
[0018] a memory communicatively connected to the at least one processor; wherein,
[0019] The memory stores a computer program executable by the at least one processor, and the computer program is executed by the at least one processor so that the at least one processor can execute the calling method of the update function described in any embodiment of the present invention.
[0020] According to another aspect of the present invention, a computer-readable storage medium is provided, wherein the computer-readable storage medium stores computer instructions, and the computer instructions are used to enable a processor to implement the calling method of the update function described in any embodiment of the present invention when executed.
[0021] The technical solution of the embodiment of the present invention obtains the function record matched by the updated software development kit, and when an event trigger signal sent by the client is received, the trigger source information matched by the event trigger signal is determined in the function record; then the target function and the target interface matched by the target function are determined according to the trigger source information; and then the target function in the updated software development kit is called according to the target function and the target interface matched by the target function. This technical solution solves the problem that the updated function cannot be called in the scenario where the application service is not upgraded synchronously after the SDK is updated and upgraded, and can improve the reliability of the application system while realizing the call of the updated function, bringing a good user experience to users.
[0022] It should be understood that the contents described in this section are not intended to identify the key or important features of the embodiments of the present invention, nor are they intended to limit the scope of the present invention. Other features of the present invention will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS
[0023] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the accompanying drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings in the following description are only some embodiments of the present invention. For ordinary technicians in this field, other accompanying drawings can be obtained based on these accompanying drawings without paying creative work.
[0024] Figure 1 is a flowchart of a method for calling an update function provided according to Embodiment 1 of the present invention;
[0025] Figure 2A is a flowchart of a method for calling an update function provided in Embodiment 2 of the present invention;
[0026] Figure 2B is a schematic diagram of function calling provided according to Embodiment 2 of the present invention;
[0027] Figure 3 is a schematic diagram of the structure of a device for calling an update function provided in Embodiment 3 of the present invention;
[0028] Figure 4 It is a structural diagram of an electronic device for implementing a method for calling an update function according to an embodiment of the present invention. DETAILED DESCRIPTION
[0029] In order to enable those skilled in the art to better understand the scheme of the present invention, the technical scheme in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present invention.
[0030] It should be noted that the terms "first", "second", etc. in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable where appropriate, so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units that are clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices. The acquisition, storage, use, processing, etc. of data in the technical solution of this application comply with the relevant provisions of national laws and regulations.
[0031] Embodiment 1
[0032] Figure 1 A flowchart of a method for calling an update function is provided for the first embodiment of the present invention. This embodiment is applicable to the calling of the update function in the scenario where the application service is not synchronously upgraded after the SDK is updated. The method can be executed by a device for calling the update function, which can be implemented in the form of hardware and / or software, and can be configured in an electronic device. Figure 1 As shown, the method includes:
[0033] S110: Acquire function records matching the updated software development kit.
[0034] This solution can be executed by an application service, and the application service can interact with the client to provide a method that can be called by the client application. For the updated software development kit, the application service is not synchronously updated. The application service can obtain the function record matching the updated software development kit, wherein the function record can be synchronously generated when the software development kit is updated, and can be pre-stored in the application service.
[0035] It is understandable that the function record may include function identification information, function matching trigger source information, and function matching interface information. The function identification information may be information such as function name and function number, the trigger source information may be event information that triggers the function, and the interface information may be application interface information corresponding to the function. In addition, the function record may also include a software development kit identifier, such as an SDK name.
[0036] S120: If an event trigger signal sent by the client is received, determine trigger source information matching the event trigger signal in the function record.
[0037] If an event trigger signal sent by the client is received, the application service can match the event trigger signal in the acquired function record to obtain trigger source information that matches the event trigger signal.
[0038] S130: Determine a target function and a target interface matching the target function according to the trigger source information.
[0039] According to the trigger source information, the application service can locate the target function and the target interface matching the target function in the function record, wherein the target interface can be an event-triggered interface.
[0040] S140: Call the target function in the updated software development kit according to the target function and the target interface that matches the target function.
[0041] The application service can determine the input parameters and / or return parameters of the target function, and pass the input parameters to the target function through the target interface matched by the target function, thereby implementing the call of the target function. The target function can output the function call result, and the application service can obtain the function call result and provide event triggering feedback to the client.
[0042] The technical solution of the embodiment of the present invention obtains the function record matched by the updated software development kit, and when an event trigger signal sent by the client is received, the trigger source information matched by the event trigger signal is determined in the function record; then the target function and the target interface matched by the target function are determined according to the trigger source information; and then the target function in the updated software development kit is called according to the target function and the target interface matched by the target function. This technical solution solves the problem that the updated function cannot be called in the scenario where the application service is not upgraded synchronously after the SDK is updated and upgraded, and can improve the reliability of the application system while realizing the call of the updated function, bringing a good user experience to users.
[0043] Embodiment 2
[0044] Figure 2A This is a flow chart of a method for calling an update function provided in Embodiment 2 of the present invention. This embodiment is based on the above embodiment and is refined. Figure 2A As shown, the method includes:
[0045] S210: Acquire function records matching the updated software development kit through a preset record acquisition method.
[0046] In this solution, the record acquisition method may include a protocol notification method or a startup reading method. The protocol notification method may be a method of sending a notification message to an application service after the function record is generated so that the application service obtains the function record. The startup reading method may be a method of reading the function record in a preset storage space when the application service is started.
[0047] It is easy to understand that, based on the above embodiment, the function record may also include parameter information of function matching, wherein the parameter information may include input parameter information and / or return parameter information. The implementation of a function may require input parameters, and there may also be return parameters, i.e., the result parameters output by the program running corresponding to the function. Different functions require different parameters, and the parameter types are also different. The function record can determine the parameter information matched by each function.
[0048] S220: If an event trigger signal sent by the client is received, determine trigger source information matching the event trigger signal in the function record.
[0049] S230: Determine a target function and a target interface matching the target function according to the trigger source information.
[0050] S240: Determine the target function identifier and input parameters matching the target function according to the target function.
[0051] It can be understood that, according to the target function, the application service can determine the target function identifier and the input parameters required by the target function.
[0052] S250 , passing in the target function identifier and the input parameters of the target function match through the target interface of the target function match, and calling the target function in the updated software development kit.
[0053] Figure 2B is a schematic diagram of function calling according to the second embodiment of the present invention, such as Figure 2B As shown, the function record generated by the software development kit after the update can be stored in the database, and the application service can obtain the function record in the database through protocol notification or start reading. Specifically, the function record may include the SDK name and the function information contained in the SDK, and the function information may include the trigger source, function name, function ID, input parameters, return parameters, and application interface matching the function.
[0054] After the application service receives the event trigger signal sent by the client, the application service can pass the target function identifier and the input parameters matching the target function through the target interface to call the target function in the SDK. The SDK can feed back the target function call result to the application service so that the application service can convey the target function call result to the client. If the target function has return parameters, the SDK can also feed back the return parameters to the application service, and the application service can process the return parameters accordingly.
[0055] The technical solution of the embodiment of the present invention obtains the function record matched by the updated software development kit, and when an event trigger signal sent by the client is received, the trigger source information matched by the event trigger signal is determined in the function record; then the target function and the target interface matched by the target function are determined according to the trigger source information; and then the target function in the updated software development kit is called according to the target function and the target interface matched by the target function. This technical solution solves the problem that the updated function cannot be called in the scenario where the application service is not upgraded synchronously after the SDK is updated and upgraded, and can improve the reliability of the application system while realizing the call of the updated function, bringing a good user experience to users.
[0056] Embodiment 3
[0057] Figure 3This is a schematic diagram of a structure of a device for calling an update function provided in Embodiment 3 of the present invention. Figure 3 As shown, the device comprises:
[0058] A function record acquisition module 310 is used to acquire function records matching the updated software development kit;
[0059] The trigger source information determination module 320 is used to determine the trigger source information matching the event trigger signal in the function record if an event trigger signal sent by the client is received;
[0060] A target interface determination module 330, configured to determine a target function and a target interface matching the target function according to the trigger source information;
[0061] The target function calling module 340 is used to call the target function in the updated software development kit according to the target function and the target interface matched by the target function.
[0062] In this solution, optionally, the function record acquisition module 310 is specifically used to:
[0063] The function record matching the updated software development kit is obtained through a preset record obtaining method, wherein the record obtaining method includes a protocol notification method or a start reading method.
[0064] In a feasible solution, the function record is generated synchronously when the software development kit performs function update.
[0065] In this embodiment, optionally, the function record includes function identification information, function matching trigger source information, and function matching interface information.
[0066] In a preferred solution, the target interface is an event-triggered interface.
[0067] Based on the above solution, optionally, the function record also includes parameter information of function matching; the parameter information includes input parameter information and / or return parameter information.
[0068] In this embodiment, optionally, the target function calling module is specifically used to:
[0069] According to the target function, determine the target function identifier and the input parameters matching the target function;
[0070] The target function identifier and the input parameters of the target function match are passed in through the target interface of the target function match, and the target function in the updated software development kit is called.
[0071] The updating function calling device provided in the embodiment of the present invention can execute the updating function calling method provided in any embodiment of the present invention, and has the corresponding functional modules and beneficial effects of the execution method.
[0072] Embodiment 4
[0073] Figure 4 A schematic diagram of an electronic device 410 that can be used to implement an embodiment of the present invention is shown. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device may also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices (such as helmets, glasses, watches, etc.) and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely examples and are not intended to limit the implementation of the present invention described and / or required herein.
[0074] like Figure 4 As shown, the electronic device 410 includes at least one processor 411, and a memory connected to the at least one processor 411 in communication, such as a read-only memory (ROM) 412, a random access memory (RAM) 413, etc., wherein the memory stores a computer program that can be executed by at least one processor, and the processor 411 can perform various appropriate actions and processes according to the computer program stored in the read-only memory (ROM) 412 or the computer program loaded from the storage unit 418 to the random access memory (RAM) 413. In the RAM 413, various programs and data required for the operation of the electronic device 410 can also be stored. The processor 411, the ROM 412, and the RAM 413 are connected to each other via a bus 414. An input / output (I / O) interface 415 is also connected to the bus 414.
[0075] Multiple components in the electronic device 410 are connected to the I / O interface 415, including: an input unit 416, such as a keyboard, a mouse, etc.; an output unit 417, such as various types of displays, speakers, etc.; a storage unit 418, such as a disk, an optical disk, etc.; and a communication unit 419, such as a network card, a modem, a wireless communication transceiver, etc. The communication unit 419 allows the electronic device 410 to exchange information / data with other devices through a computer network such as the Internet and / or various telecommunication networks.
[0076] The processor 411 may be a variety of general and / or special processing components with processing and computing capabilities. Some examples of the processor 411 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various dedicated artificial intelligence (AI) computing chips, various processors running machine learning model algorithms, a digital signal processor (DSP), and any appropriate processor, controller, microcontroller, etc. The processor 411 executes the various methods and processes described above, such as the calling method of the update function.
[0077] In some embodiments, the calling method of the update function may be implemented as a computer program, which is tangibly contained in a computer-readable storage medium, such as a storage unit 418. In some embodiments, part or all of the computer program may be loaded and / or installed on the electronic device 410 via the ROM 412 and / or the communication unit 419. When the computer program is loaded into the RAM 413 and executed by the processor 411, one or more steps of the calling method of the update function described above may be performed. Alternatively, in other embodiments, the processor 411 may be configured to execute the calling method of the update function by any other appropriate means (e.g., by means of firmware).
[0078] Various implementations of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips (SOCs), complex programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various implementations can include: being implemented in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which can be a special purpose or general purpose programmable processor that can receive data and instructions from a storage system, at least one input device, and at least one output device, and transmit data and instructions to the storage system, the at least one input device, and the at least one output device.
[0079] The computer programs for implementing the methods of the present invention may be written in any combination of one or more programming languages. These computer programs may be provided to a processor of a general-purpose computer, a special-purpose computer or other programmable update function invoking device, so that when the computer program is executed by the processor, the functions / operations specified in the flow chart and / or block diagram are implemented. The computer program may be executed entirely on the machine, partially on the machine, partially on the machine and partially on a remote machine as a stand-alone software package, or entirely on a remote machine or server.
[0080] In the context of the present invention, a computer-readable storage medium may be a tangible medium that may contain or store a computer program for use by or in conjunction with an instruction execution system, device, or equipment. A computer-readable storage medium may include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices, or equipment, or any suitable combination of the foregoing. Alternatively, a computer-readable storage medium may be a machine-readable signal medium. A more specific example of a machine-readable storage medium may include an electrical connection based on one or more lines, a portable computer disk, 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 disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
[0081] To provide interaction with a user, the systems and techniques described herein may be implemented on an electronic device having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and a pointing device (e.g., a mouse or trackball) through which the user can provide input to the electronic device. Other types of devices may also be used to provide interaction with the user; for example, the feedback provided to the user may 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 input, voice input, or tactile input).
[0082] The systems and techniques described herein may be implemented in a computing system that includes backend components (e.g., as a data server), or a computing system that includes middleware components (e.g., an application service), or a computing system that includes frontend components (e.g., a user computer with a graphical user interface or a web browser through which a user can interact with implementations of the systems and techniques described herein), or a computing system that includes any combination of such backend components, middleware components, or frontend components. The components of the system may be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: a local area network (LAN), a wide area network (WAN), a blockchain network, and the Internet.
[0083] A computing system may include a client and a server. The client and the server are generally remote from each other and usually interact through a communication network. The client and server relationship is generated by computer programs running on the corresponding computers and having a client-server relationship with each other. The server may be a cloud server, also known as a cloud computing server or cloud host, which is a host product in the cloud computing service system to solve the defects of difficult management and weak business scalability in traditional physical hosts and VPS services.
[0084] It should be understood that the various forms of processes shown above can be used to reorder, add or delete steps. For example, the steps described in the present invention can be executed in parallel, sequentially or in different orders, as long as the desired results of the technical solution of the present invention can be achieved, and this document does not limit this.
[0085] The above specific implementations do not constitute a limitation on the protection scope of the present invention. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions can be made according to design requirements and other factors. Any modification, equivalent substitution and improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention.
Claims
1. A method for calling an update function, executed by an application service, is applied to a scenario where the application service is not upgraded synchronously after the SDK is updated, and is characterized in that: The method comprises: Get updated SDK matching feature records; If an event trigger signal sent by the client is received, determining trigger source information matching the event trigger signal in the function record; Determine a target function and a target interface matching the target function according to the trigger source information; Calling the target function in the updated software development kit according to the target function and the target interface matched by the target function; wherein the target function is used to output the function calling result; The obtaining of the function record matching the updated software development kit includes: The function record matching the updated software development kit is obtained through a preset record acquisition method, wherein the record acquisition method includes a protocol notification method or a startup reading method; wherein the function record includes function identification information, function matching trigger source information and function matching interface information, and the trigger source information is event information that triggers the function.
2. The method according to claim 1, characterized in that: The function record is generated synchronously when the software development kit performs function update.
3. The method according to claim 1, characterized in that The target interface is an event-triggered interface.
4. The method according to claim 1, characterized in that: The function record also includes parameter information of function matching; the parameter information includes input parameter information and / or return parameter information.
5. The method according to claim 4, characterized in that The calling of the target function in the updated software development kit according to the target function and the target interface matched by the target function includes: According to the target function, determine the target function identifier and the input parameters matching the target function; The target function identifier and the input parameters of the target function match are passed in through the target interface of the target function match, and the target function in the updated software development kit is called.
6. A device for calling an update function, applied to a scenario where an application service is not synchronously upgraded after an SDK is updated, characterized in that: include: A function record acquisition module is used for the application service to acquire function records matching the updated software development kit; A trigger source information determination module, used for determining the trigger source information matching the event trigger signal in the function record if the application service receives the event trigger signal sent by the client; A target interface determination module, used for the application service to determine the target function and the target interface matching the target function according to the trigger source information; A target function calling module, used for the application service to call the target function in the updated software development kit according to the target function and the target interface matched by the target function; wherein the target function is used to output the function calling result; The function record acquisition module is specifically used to obtain the function record matching the updated software development kit through a preset record acquisition method, wherein the record acquisition method includes a protocol notification method or a startup reading method; wherein the function record includes function identification information, function matching trigger source information and function matching interface information, and the trigger source information is event information that triggers the function.
7. An electronic device, characterized in that: The electronic device comprises: at least one processor; and a memory communicatively connected to the at least one processor; wherein, The memory stores a computer program executable by the at least one processor, and the computer program is executed by the at least one processor so that the at least one processor can execute the calling method of the update function according to any one of claims 1 to 5.
8. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer instructions, and the computer instructions are used to enable a processor to implement the calling method of the update function according to any one of claims 1 to 5 when executed.
Citation Information
Patent Citations
Business page updating method and device, electronic equipment and storage medium
CN114706600A