CN111651146A - Function generation method, device, equipment and medium - Google Patents

Function generation method, device, equipment and medium Download PDF

Info

Publication number
CN111651146A
CN111651146A CN202010355345.4A CN202010355345A CN111651146A CN 111651146 A CN111651146 A CN 111651146A CN 202010355345 A CN202010355345 A CN 202010355345A CN 111651146 A CN111651146 A CN 111651146A
Authority
CN
China
Prior art keywords
function
server
node
operation data
client
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202010355345.4A
Other languages
Chinese (zh)
Other versions
CN111651146B (en
Inventor
刘凯
刘冬梅
何迪
孙通
刘韩影
戴军
张华斌
叶水根
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhejiang Geely Holding Group Co Ltd
Ningbo Geely Automobile Research and Development Co Ltd
Original Assignee
Zhejiang Geely Holding Group Co Ltd
Ningbo Geely Automobile Research and Development 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 Zhejiang Geely Holding Group Co Ltd, Ningbo Geely Automobile Research and Development Co Ltd filed Critical Zhejiang Geely Holding Group Co Ltd
Priority to CN202010355345.4A priority Critical patent/CN111651146B/en
Publication of CN111651146A publication Critical patent/CN111651146A/en
Application granted granted Critical
Publication of CN111651146B publication Critical patent/CN111651146B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/40Transformation of program code
    • G06F8/41Compilation
    • G06F8/44Encoding
    • G06F8/447Target code generation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/30Creation or generation of source code
    • G06F8/31Programming languages or programming paradigms

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computing Systems (AREA)
  • Stored Programmes (AREA)

Abstract

The invention discloses a function generation method, a device, equipment and a medium, wherein the method comprises the steps that a client responds to a function node creation instruction, a function node is created in the client, and operation data in the process of creating the function node is sent to a server, so that the server can create the function node with the same parameters in an address space. After the client acquires the function code edited by the user, the client assigns the function node in the client and sends operation data during function assignment to the server, so that the server can assign the function node in the address space to obtain an operable function with a logic function. The method of the embodiment of the invention can give the right of function creation to the user, can better meet flexible and changeable user requirements, and improves user experience. In the method, function codes can be managed through functions, namely platforms, so that a user can select a proper language to realize code logic and language independence is achieved.

Description

Function generation method, device, equipment and medium
Technical Field
The invention relates to the field of Internet of things, in particular to a function generation method, a function generation device, function generation equipment and a function generation medium.
Background
OPC UA is an important industrial Internet of things communication protocol of C/S architecture, has functions of communication and information modeling, and has new advantages compared with the traditional OPC DA communication protocol, wherein one of the advantages is a function. The function is the only way to provide algorithm service in the information model, and the OPC UA can improve the interoperability between the client and the server based on the function.
However, the function in the official protocol specification of OPC UA must be implemented in the background of the server, i.e., the function code can only be solidified in the background when developing the OPC UA server, and is completely oriented to the server background developer, and the user cannot implement the function modeling at the client according to the actual requirement. Therefore, flexible and changeable service requirements under practical conditions cannot be met in the using process, and user experience is poor.
Disclosure of Invention
The invention provides a function generation method, a function generation device, a function generation equipment and a function generation medium, which can meet flexible and changeable user requirements and improve user experience.
In one aspect, the present invention provides a method for generating a function, where the method includes:
responding to a function node creating instruction, creating a client function node, and acquiring operation data when the client function node is created;
sending the operation data generated by the function node to a server so that the server generates an address space function node in an address space of the server according to the operation data;
responding to a function code editing instruction, and acquiring function code data;
assigning the client function node according to the function code data, and acquiring operation data during function assignment;
and sending the operation data during the function assignment to the server so that the server assigns the address space function node corresponding to the client function node according to the operation data during the function assignment to obtain the function with the logic function.
Another aspect provides a function creation apparatus, including: the system comprises a client function node creating module, a first operation data sending module, a function code data acquiring module, a client function node assignment module and a second operation data sending module.
The client function node creating module is used for responding to a function node creating instruction, creating a client function node and acquiring operation data when the client function node is created;
the first operation data sending module is used for sending operation data generated by the function node to a server so that the server generates an address space function node in an address space of the server according to the operation data;
the function code data acquisition module is used for responding to a function code editing instruction and acquiring function code data;
the client function node assignment module is used for assigning the client function node according to the function code data and acquiring operation data during function assignment;
and the second operation data sending module is used for sending the operation data during function assignment to the server so that the server assigns the address space function node corresponding to the client function node according to the operation data during function assignment to obtain a function with a logic function.
Another aspect provides an apparatus comprising a processor and a memory, wherein the memory stores at least one instruction or at least one program, and the at least one instruction or the at least one program is loaded by the processor and executed to implement a function generation method as described above.
Another aspect provides a storage medium comprising a processor and a memory, wherein the memory stores at least one instruction or at least one program, and the at least one instruction or the at least one program is loaded by the processor and executed to implement a function generation method as described above.
The method comprises the steps that the client responds to a function node creating instruction, a function node is created in the client, and operation data when the function node is created is sent to the server, so that the server can create the function node with the same parameters in an address space. After the client acquires the function code edited by the user, the client assigns the function node in the client and sends operation data during function assignment to the server, so that the server can also assign the function node in the address space to obtain an executable function with a logic function. The method of the embodiment of the invention can give the right of function creation to the user, and the user can create the corresponding function according to the actual service requirement, thereby better meeting the flexible and changeable user requirement and improving the user experience.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the drawings without creative efforts.
Fig. 1 is a schematic view of an application scenario of a function generation method according to an embodiment of the present invention;
fig. 2 is a flowchart of a function generation method according to an embodiment of the present invention;
fig. 3 is a flowchart of a method for a client to send operation data when creating a function node in a function generating method according to an embodiment of the present invention;
fig. 4 is a flowchart of a method for generating an address space function node in a function generation method according to an embodiment of the present invention;
fig. 5 is a flowchart of a method for a client to send operation data when a function assignment is sent in a function generation method according to an embodiment of the present invention;
fig. 6 is a flowchart of a method for assigning values to nodes of an address space function in a function generation method according to an embodiment of the present invention;
fig. 7 is a flowchart of a method for pre-compiling function code data in a function generating method according to an embodiment of the present invention;
fig. 8 is a flowchart of a method for function code data invocation in a function generation method according to an embodiment of the present invention;
fig. 9 is a schematic structural diagram of a function creating apparatus according to an embodiment of the present invention;
fig. 10 is a schematic hardware structure diagram of an apparatus for implementing the method provided by the embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, the present invention will be described in further detail with reference to the accompanying drawings. It is to be understood that the described embodiments are merely a few embodiments of the invention, and not all embodiments. All other embodiments, which can be obtained by a person skilled in the art without any inventive step based on the embodiments of the present invention, are within the scope of the present invention.
In the description of the present invention, it is to be understood that the terms "first", "second" and the like are used for descriptive purposes only and are not to be construed as indicating or implying relative importance or implying any number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of that feature. Moreover, the terms "first," "second," and the like, are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used is interchangeable under appropriate circumstances such that the embodiments of the invention described herein are capable of operation in sequences other than those illustrated or described herein.
Referring to fig. 1, an application scenario of the function generation method according to the embodiment of the present invention is shown, where the application scenario includes a client 110, a server 120, and a function as a service platform 130, a client function node is created at the client 110, operation data when the client function node is created is transmitted to the server 120, and the server 120 creates an address space function node in an address space according to the operation data. The client 110 obtains a function code input by a user, assigns a function node of the client according to the function code, transmits operation data when assigning the function node of the client to the server 120, and assigns the function node of the address space according to the operation data by the server 120 to obtain a function with a logic function. In the process of creating the function, the function as the service platform 130 obtains the function code from the server 120 for pre-compiling. In the function call process, the function-as-a-service platform 130 obtains the parameter information of the target function from the server 120, and runs the corresponding function code according to the parameter information and feeds back the running result.
In the embodiment of the present invention, the client 110 includes a physical device of a smart phone, a desktop computer, a tablet computer, a notebook computer, a digital assistant, a smart wearable device, and the like, and may also include software running in the physical device, such as an application program. The operating system running on the network node in the embodiment of the present application may include, but is not limited to, an android system, an IOS system, linux, Unix, windows, and the like. The client 110 has an internet of things communication protocol based on which information can be transmitted with the server 120 and a code editor.
In the embodiment of the present invention, the server 120 may include a server running independently, or a distributed server, or a server cluster composed of a plurality of servers. The server 110 may include a network communication unit, a processor, a memory, and the like.
In the embodiment of the invention, a Function as a Service (FaaS) platform can take a Function as an online Service and a remote computing Service, is a cloud native technology capable of hosting user codes, realizes serverless implementation, and supports multiple programming languages.
Referring to fig. 2, a function generation method, which can be applied to a client side, is shown, and the method includes:
s210, the client responds to a function node creating instruction, creates a client function node and obtains operation data when the client function node is created;
s220, the client sends operation data generated by the function node to a server;
further, referring to fig. 3, the sending, by the client, the operation data generated by the function node to the server includes:
s310, the client encapsulates the operation data generated by the function node according to a preset node management service specification;
s320, the client sends the packaged operation data generated by the function node to the server.
Specifically, the server and the client may be an OPC Unified Architecture (OPC) server and a client, where OPC is an Object Linking and embedding for Process Control (Object Linking and embedding for Process Control), and OPC UA is an important industrial internet of things communication protocol of a C/S Architecture, and may provide an information model with semantics. In the client program of the OPC UA, the communication specification to the server specified by the OPC foundation is implemented and encapsulated.
The method comprises the steps that a user creates a client function node at a client, parameters of the client function node input by the user comprise a node ID of a target node needing to be hooked by the function, a node ID of the function node, a signature of the function and the like, and the client of the OPC UA encapsulates operation of the user when the client function node is created into OPC UA service data and sends the OPC UA service data to a server of the OPC UA. The client of the OPC UA may be encapsulated based on a node management service set (NodeManagement ServiceSet) in the communication specification so that the server can receive data using the same service specification.
S230, the server generates an address space function node in the address space of the server according to the operation data;
further, referring to fig. 4, the generating, by the server, the address space function node in the address space of the server according to the operation data includes:
s410, the client sends operation data generated by the function node to a server;
s420, the server calls a node editing interface with a node management service specification;
and S430, the server generates an address space function node in the address space of the server through the node editing interface according to the operation data generated by the function node.
Specifically, the server acquires operation data generated by the encapsulated function node sent by the client. And the server calls the corresponding interface to receive the operation data generated by the encapsulated function node. The client sends data encapsulated based on a node management Service specification (NodeManagement Service Set) in the communication specification, and the server calls a node editing interface with the node management Service specification to receive the data and generates an address space function node in an address space of the server according to operation data generated by the function node. The node editing interface may be an AddNodes interface.
S240, the client responds to the function code editing instruction to obtain function code data;
specifically, the user creates a function code script on the code editor and debugs the function code script. After debugging is successful, the function code script is transmitted to the OPC UA client in a character string format.
S250, the client assigns values to the client function nodes according to the function code data, and obtains operation data during function assignment;
s260, the client sends operation data in the function assignment to the server;
further, referring to fig. 5, the sending, by the client, the operation data of the function assignment to the server further includes:
s510, the client encapsulates the operation data generated by the function node according to a preset attribute data service specification;
s520, the client sends the packaged operation data generated by the function node to the server.
Specifically, a user assigns a character string of a function code to a node Attribute of a previously created function node at a client, encapsulates operation data during function assignment based on a preset Attribute data Service specification (Attribute Service Set), and transmits the encapsulated operation data during function assignment to a server.
And S270, the server assigns values to the address space function nodes corresponding to the client function nodes according to the operation data during function assignment to obtain functions with logic functions.
Further, referring to fig. 6, the server assigns, according to the operation data during function assignment, an address space function node corresponding to the client function node, and obtaining a function with a logic function includes:
s610, the client sends operation data in the function assignment to the server;
s620, the server calls a writing interface with attribute data service specifications;
and S630, the server assigns values to the address space function nodes corresponding to the client function nodes through the write-in interface according to the operation data of the function assignments.
Specifically, the OPC UA server calls a write interface of the attribute data service specification, assigns a character string of operation data at the time of function assignment to a node attribute of a function node of the address space, so that a function having a logical function can be generated in the server. And the server also receives the character string of the function code transmitted by the client and transmits the code to the FaaS platform through an Application Programming Interface (API). The method of transferring the character string of the function code to the function, i.e., the service platform, may be transmitted in a manner of a REpresentational State Transfer API (REST API) that represents a layer State transition.
By editing and assigning the function code at the client and sending the operation data during assignment to the server for the same operation, the right of function creation can be given to the user, the flexible and changeable user requirements can be better met, and the user experience is improved.
Further, referring to fig. 7, after sending the operation data during function assignment to the server to enable the server to assign an address space function node corresponding to the client function node according to the operation data during function assignment to obtain a function with a logic function, the method further includes:
s710, sending the function code data to the server;
s720, the server sends the function code data to a function service platform;
and S730, the function, namely the service platform, creates a corresponding function container running environment and performs pre-compiling on function code data.
Specifically, in the function creation phase, the client sends the function code to the server, and then sends the function code to the function, i.e., the service platform, through the server. A cloud computing service provides an operation platform and a solution stack as a service. The function, namely the service platform, deploys and creates the functions on the client, and a user does not need to manage and control the function codes. After an application programming interface of the function, namely the service platform, which is in butt joint with the server receives a function creating request and a function code transmitted by the server, a container environment for function operation is established, and the function code is pre-compiled.
The function code is managed through a function, namely a platform, so that a user can select a proper language to realize the code logic, and the language independence is realized.
Further, referring to fig. 8, the method further includes:
s810, the client calls a target function in the server;
s820, the server transmits parameter information corresponding to the target function to the function, namely the service platform;
s830, the function-as-a-service platform runs a function code corresponding to the target function;
s840, the server obtains the function, namely the operation result of the service platform;
and S850, the client receives the operation result sent by the server.
Specifically, in the function call phase, the client sends a function signature to the server, and calls a function code corresponding to the function signature. And the server determines the address space function node corresponding to the function signature according to the function signature and sends the parameters related to the address space function node to the function, namely the service platform. And the function, namely the service platform, acquires the corresponding function code according to the parameter information, and operates the function code to obtain an operating result. The function, namely the service platform feeds back the result obtained by operation to the server, and the server feeds back the result obtained by operation to the client.
In a specific embodiment, a user needs to create a function a for implementing the data acquisition function of the device a through a client of the OPC UA, the user may first enter a node for creating the function a with a parameter at the client of the OPC UA, and the input parameter is a function signature of the function a, an id of the node of the function a, and an id of a destination node related to the device a hooked by the function a, so as to create the node of the function a at the client of the OPC UA. The client of the OPC UA encapsulates the operation data when the user creates the function a node and sends the encapsulated operation data to the server of the OPC UA, the operation data when the user creates the function a node can be mapped into the server of the OPC UA, and the server of the OPC UA can obtain the parameters input by the user and the operation performed, thereby creating the corresponding function a node in the address space of the server of the OPC UA. The user can create a code script of the function a on the code editor according to the own needs, the data acquisition function of the device A is realized in the code script of the function a, the client of the OPC UA receives the code script of the function a transmitted by the code editor, and the code script of the function a is assigned to the attribute of the function a node in the client of the OPC UA, so that the function a node in the client of the OPC UA has an executable data acquisition function. The client of the OPC UA encapsulates the operation data when the user assigns the function a node and sends the encapsulated operation data to the server of the OPC UA, and the operation data when the user assigns the function a node can be mapped into the server of the OPC UA, and the server of the OPC UA can obtain the code script of the function a, so that the code script of the function a is assigned to the node attribute of the corresponding function a node in the address space of the server of the OPC UA, and therefore, the server of the OPC UA has the function a which is created by the user and can perform a data acquisition function. And then, the function a is precompiled through the function service platform, when the user calls the function a, the function a is operated through the function service platform, data acquisition is carried out on the equipment A, the operation result is fed back to the server of the OPC UA, and the server of the OPC UA sends the operation result to the client of the OPC UA to complete the operation of the function a established by the user at the client of the OPC UA, so that the corresponding function is called to acquire the equipment A according to the actual acquisition requirement when the data acquisition is actually carried out, the adaptability is better, and the user experience is improved.
The embodiment of the invention provides a function generation method, which comprises the steps that a client responds to a function node creation instruction, a function node is created in the client, and operation data during creation of the function node is sent to a server, so that the server can also create the function node with the same parameters in an address space. After the client acquires the function code edited by the user, the client assigns the function node in the client and sends operation data during function assignment to the server, so that the server can also assign the function node in the address space to obtain an executable function with a logic function. The method of the embodiment of the invention can give the right of function creation to the user, can better meet flexible and changeable user requirements, and improves user experience. In the method of the embodiment of the invention, the function code can be managed through the function, namely the platform, so that a user can select a proper language to realize the code logic and has language independence.
An embodiment of the present invention further provides a function creating apparatus, please refer to fig. 9, where the apparatus includes: a client function node creating module 910, a first operation data sending module 920, a function code data obtaining module 930, a client function node assigning module 940 and a second operation data sending module 950.
The client function node creating module 910 is configured to create a client function node in response to a function node creating instruction, and acquire operation data when the client function node is created;
the first operation data sending module 920 is configured to send operation data generated by the function node to a server, so that the server generates an address space function node in an address space of the server according to the operation data;
the function code data obtaining module 930 is configured to obtain function code data in response to a function code editing instruction;
the client function node assignment module 940 is configured to assign a value to the client function node according to the function code data, and acquire operation data during function assignment;
the second operation data sending module 950 is configured to send the operation data during function assignment to the server, so that the server assigns an address space function node corresponding to the client function node according to the operation data during function assignment, and obtains a function with a logic function.
The device provided in the above embodiments can execute the method provided in any embodiment of the present invention, and has corresponding functional modules and beneficial effects for executing the method. For technical details that are not described in detail in the above embodiments, reference may be made to a function generation method provided in any embodiment of the present invention.
The present embodiment also provides a computer-readable storage medium, in which computer-executable instructions are stored, and the computer-executable instructions are loaded by a processor and execute a function generation method of the present embodiment.
The present embodiment also provides an apparatus, which includes a processor and a memory, where the memory stores a computer program, and the computer program is adapted to be loaded by the processor and execute a function generation method described above in the present embodiment.
The device may be a computer terminal, a mobile terminal or a server, and the device may also participate in forming the apparatus or system provided by the embodiments of the present invention. As shown in fig. 10, the computer terminal 10 (or mobile terminal 10 or server 10) may include one or more (shown as 1002a, 1002b, … …, 1002 n) processors 1002 (the processors 1002 may include, but are not limited to, a processing device such as a microprocessor MCU or a programmable logic device FPGA), memory 1004 for storing data, and a transmission device 1006 for communication functions. Besides, the method can also comprise the following steps: a display, an input/output interface (I/O interface), a network interface, a power source, and/or a camera. It will be understood by those skilled in the art that the structure shown in fig. 10 is merely illustrative and is not intended to limit the structure of the electronic device. For example, the mobile device 10 may also include more or fewer components than shown in FIG. 10, or have a different configuration than shown in FIG. 10.
It should be noted that the one or more processors 1002 and/or other data processing circuitry described above may be referred to generally herein as "data processing circuitry". The data processing circuitry may be embodied in whole or in part in software, hardware, firmware, or any combination thereof. Further, the data processing circuitry may be a single, stand-alone processing module, or incorporated in whole or in part into any of the other elements in the mobile device 10 (or computer terminal). As referred to in the embodiments of the application, the data processing circuit acts as a processor control (e.g. selection of a variable resistance termination path connected to the interface).
The memory 1004 may be used for storing software programs and modules of application software, such as program instructions/data storage devices corresponding to the method described in the embodiment of the present invention, and the processor 1002 executes various functional applications and data processing by running the software programs and modules stored in the memory 1004, that is, implementing one of the above-described methods for generating a self-attention network-based time-series behavior capture block. The memory 1004 may include high-speed random access memory, and may also include non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some examples, the memory 1004 may further include memory located remotely from the processor 1002, which may be connected to the computer terminal 10 via a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
The transmission device 1006 is used for receiving or sending data via a network. Specific examples of the network described above may include a wireless network provided by a communication provider of the mobile terminal 10. In one example, the transmission device 1006 includes a Network adapter (NIC) that can be connected to other Network devices through a base station so as to communicate with the internet. In one example, the transmission device 1006 can be a Radio Frequency (RF) module, which is used for communicating with the internet in a wireless manner.
The display may be, for example, a touch screen type Liquid Crystal Display (LCD) that may enable a user to interact with a user interface of the computer terminal 10 (or mobile terminal).
The present specification provides method steps as described in the examples or flowcharts, but may include more or fewer steps based on routine or non-inventive labor. The steps and sequences recited in the embodiments are but one manner of performing the steps in a multitude of sequences and do not represent a unique order of performance. In the actual system or interrupted product execution, it may be performed sequentially or in parallel (e.g., in the context of parallel processors or multi-threaded processing) according to the embodiments or methods shown in the figures.
The configurations shown in the present embodiment are only partial configurations related to the present application, and do not constitute a limitation on the devices to which the present application is applied, and a specific device may include more or less components than those shown, or combine some components, or have an arrangement of different components. It should be understood that the methods, apparatuses, and the like disclosed in the embodiments may be implemented in other manners. For example, the above-described apparatus embodiments are merely illustrative, and for example, the division of the modules is merely a division of one logic function, and there may be other divisions when actually implemented, for example, a plurality of units or components may be combined or may be integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or unit modules.
Based on such understanding, the technical solution of the present invention may be embodied in the form of a software product, which is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: various media capable of storing program codes, such as a usb disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disk.
Those of skill would further appreciate that the various illustrative components and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware, computer software, or combinations of both, and that the various illustrative components and steps have been described above generally in terms of their functionality in order to clearly illustrate this interchangeability of hardware and software. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present invention.
The above-mentioned embodiments are only used for illustrating the technical solutions of the present invention, and not for limiting the same; although the present invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; and such modifications or substitutions do not depart from the spirit and scope of the corresponding technical solutions of the embodiments of the present invention.

Claims (10)

1. A method of function generation, the method comprising:
responding to a function node creating instruction, creating a client function node, and acquiring operation data when the client function node is created;
sending the operation data generated by the function node to a server so that the server generates an address space function node in an address space of the server according to the operation data;
responding to a function code editing instruction, and acquiring function code data;
assigning the client function node according to the function code data, and acquiring operation data during function assignment;
and sending the operation data during the function assignment to the server so that the server assigns the address space function node corresponding to the client function node according to the operation data during the function assignment to obtain the function with the logic function.
2. The method according to claim 1, wherein after sending the operation data when the function is assigned to the server to enable the server to assign a value to the address space function node corresponding to the client function node according to the operation data when the function is assigned to obtain a function with a logic function, the method further comprises:
and sending the function code data to the server so that the server sends the function code data to a function service platform, and the function service platform creates a function container operating environment corresponding to the function code data to perform precompilation of the function code data.
3. A method of generating a function according to claim 1, the method further comprising:
calling a target function in the server to enable the server to transmit parameter information corresponding to the target function to the function, namely a service platform, wherein the function, namely the service platform runs a function code corresponding to the target function, and the server obtains a running result of the function, namely the service platform;
and receiving the operation result sent by the server.
4. The method according to claim 1, wherein the sending the operation data generated by the function node to a server comprises:
packaging the operation data generated by the function node according to a preset node management service specification;
and sending the encapsulated operation data generated by the function node to a server.
5. The method according to claim 1, wherein the sending operation data generated by the function node to a server, so that the server generates an address space function node in an address space of the server according to the operation data comprises:
and sending the operation data generated by the function node to a server so that the server calls a node editing interface with a node management service specification, and generating an address space function node in an address space of the server by the server through the node editing interface according to the operation data generated by the function node.
6. A method as claimed in claim 1, wherein said sending operation data of said function assignment to said server further comprises:
packaging the operation data generated by the function node according to a preset attribute data service specification;
and sending the encapsulated operation data generated by the function node to a server.
7. The method according to claim 1, wherein the sending the operation data of the function assignment to the server so that the server assigns an address space function node corresponding to the client function node according to the operation data when the function is assigned to obtain a function with a logical function comprises:
and sending the operation data during function assignment to the server so that the server calls a write-in interface with attribute data service specifications, and assigning the address space function node corresponding to the client function node through the write-in interface by the server according to the operation data of the function assignment.
8. A function generation apparatus, characterized in that the apparatus comprises: the system comprises a client function node creating module, a first operation data sending module, a function code data acquiring module, a client function node assignment module and a second operation data sending module.
The client function node creating module is used for responding to a function node creating instruction, creating a client function node and acquiring operation data when the client function node is created;
the first operation data sending module is used for sending operation data generated by the function node to a server so that the server generates an address space function node in an address space of the server according to the operation data;
the function code data acquisition module is used for responding to a function code editing instruction and acquiring function code data;
the client function node assignment module is used for assigning the client function node according to the function code data and acquiring operation data during function assignment;
and the second operation data sending module is used for sending the operation data during function assignment to the server so that the server assigns the address space function node corresponding to the client function node according to the operation data during function assignment to obtain a function with a logic function.
9. An apparatus comprising a processor and a memory, wherein at least one instruction or at least one program is stored in the memory, and wherein the at least one instruction or the at least one program is loaded and executed by the processor to implement a function generation method according to any one of claims 1 to 7.
10. A storage medium comprising a processor and a memory, wherein at least one instruction or at least one program is stored in the memory, and the at least one instruction or the at least one program is loaded and executed by the processor to implement a function generation method according to any one of claims 1 to 7.
CN202010355345.4A 2020-04-29 2020-04-29 Function generation method, device, equipment and medium Active CN111651146B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010355345.4A CN111651146B (en) 2020-04-29 2020-04-29 Function generation method, device, equipment and medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010355345.4A CN111651146B (en) 2020-04-29 2020-04-29 Function generation method, device, equipment and medium

Publications (2)

Publication Number Publication Date
CN111651146A true CN111651146A (en) 2020-09-11
CN111651146B CN111651146B (en) 2024-04-16

Family

ID=72349175

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010355345.4A Active CN111651146B (en) 2020-04-29 2020-04-29 Function generation method, device, equipment and medium

Country Status (1)

Country Link
CN (1) CN111651146B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113296750A (en) * 2021-05-12 2021-08-24 阿里巴巴新加坡控股有限公司 Function creating method and system, and function calling method and system

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20180113693A1 (en) * 2016-10-24 2018-04-26 International Business Machines Corporation Optimized Entry Points and Local Function Call Tailoring for Function Pointers
US20180152427A1 (en) * 2016-11-28 2018-05-31 International Business Machines Corporation Protecting a web server against an unauthorized client application
CN109710426A (en) * 2018-12-24 2019-05-03 珠海豹趣科技有限公司 A kind of inter-process communication methods and relevant device
CN109766088A (en) * 2019-01-17 2019-05-17 宜创(北京)科技有限公司 Program creating method, device, data processing method and server
CN110287098A (en) * 2019-05-21 2019-09-27 深圳壹账通智能科技有限公司 Automatically create test script method, server and computer readable storage medium

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20180113693A1 (en) * 2016-10-24 2018-04-26 International Business Machines Corporation Optimized Entry Points and Local Function Call Tailoring for Function Pointers
US20180152427A1 (en) * 2016-11-28 2018-05-31 International Business Machines Corporation Protecting a web server against an unauthorized client application
CN109710426A (en) * 2018-12-24 2019-05-03 珠海豹趣科技有限公司 A kind of inter-process communication methods and relevant device
CN109766088A (en) * 2019-01-17 2019-05-17 宜创(北京)科技有限公司 Program creating method, device, data processing method and server
CN110287098A (en) * 2019-05-21 2019-09-27 深圳壹账通智能科技有限公司 Automatically create test script method, server and computer readable storage medium

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
唐和平;宋舜宏;黄曙光;田杰;: "可计算函数的程序理解方法", 小型微型计算机系统, no. 02 *

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113296750A (en) * 2021-05-12 2021-08-24 阿里巴巴新加坡控股有限公司 Function creating method and system, and function calling method and system
CN113296750B (en) * 2021-05-12 2023-12-08 阿里巴巴新加坡控股有限公司 Function creation method and system, function calling method and system

Also Published As

Publication number Publication date
CN111651146B (en) 2024-04-16

Similar Documents

Publication Publication Date Title
CN108205442B (en) Edge computing platform
CN108830720B (en) Intelligent contract running method, device, system and computer readable storage medium
CN109308224B (en) Cross-platform data communication and cross-platform data processing method, device and system
CN109976667B (en) Mirror image management method, device and system
CN110083455B (en) Graph calculation processing method, graph calculation processing device, graph calculation processing medium and electronic equipment
CN111930521A (en) Method and device for deploying application, electronic equipment and readable storage medium
CN111694617B (en) Processing method of network offline model, artificial intelligence processing device and related products
CN112199164A (en) Method for ensuring container mirror image consistency
CN111431730B (en) Service processing method, system, computer equipment and readable medium
CN114089974B (en) Cloud code development system, method, device, equipment and storage medium
CN114398191A (en) Remote service calling method, system, computer equipment and storage medium
CN111679811B (en) Web service construction method and device
CN112121411A (en) Vibration control method, device, electronic equipment and computer readable storage medium
CN108052377B (en) Cloud-based input processing method and device, server and storage medium
CN111427665A (en) Quantum application cloud platform and quantum computing task processing method
CN111651146B (en) Function generation method, device, equipment and medium
CN113312083B (en) Application generation method, device and equipment
CN113572822A (en) Cloud terminal simulation control method and device, storage medium and electronic equipment
CN112044061B (en) Game picture processing method and device, electronic equipment and storage medium
CN109388406A (en) Convert method and device, the storage medium, electronic device of java code
CN109840109B (en) Method and apparatus for generating software development toolkit
CN109840132A (en) Method of combination, device and the storage medium of container
CN110782040A (en) Method, device, equipment and medium for training tasks of pitorch
CN115525396A (en) Application management method and device based on cloud protogenesis
CN115437647A (en) Multi-frame-adaptive micro-service deployment method, device, terminal and storage medium

Legal Events

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