CN103731427B - Conversation processing method, device and system - Google Patents

Conversation processing method, device and system Download PDF

Info

Publication number
CN103731427B
CN103731427B CN201310754454.3A CN201310754454A CN103731427B CN 103731427 B CN103731427 B CN 103731427B CN 201310754454 A CN201310754454 A CN 201310754454A CN 103731427 B CN103731427 B CN 103731427B
Authority
CN
China
Prior art keywords
api
agent
handling process
session
external transactions
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.)
Active
Application number
CN201310754454.3A
Other languages
Chinese (zh)
Other versions
CN103731427A (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.)
Huawei Technologies Co Ltd
Original Assignee
Huawei Technologies 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 Huawei Technologies Co Ltd filed Critical Huawei Technologies Co Ltd
Priority to CN201310754454.3A priority Critical patent/CN103731427B/en
Publication of CN103731427A publication Critical patent/CN103731427A/en
Priority to PCT/CN2014/093469 priority patent/WO2015101151A1/en
Application granted granted Critical
Publication of CN103731427B publication Critical patent/CN103731427B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/14Session management
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/56Provisioning of proxy services
    • H04L67/561Adding application-functional data or data for application control, e.g. adding metadata

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Library & Information Science (AREA)
  • Computer And Data Communications (AREA)

Abstract

The invention relates to the technical field of computers, in particular to a conversation processing method, device and system. The conversation processing method, device and system are used for realizing conversation correlation when multiple APIs on an API agent are called in sequence by an API calling device. According to the method, when the API agent executes the processing process of the first API, conversation data of a conversation corresponding to the first API are cached; when the API agent executes the processing process of the second API, the conversation data cached when the processing process of the first API is executed are obtained according to an external event ID which is used for identifying the conversation corresponding to the first API and is included in a request for calling the second API, and the conversation is processed according to the obtained conversation data. The API agent obtains the conversation data of the conversation corresponding to the first API according to the external event ID included in the request for calling the second API, and processes the conversation according to the obtained conversation data, and therefore conversation correlation between the first API and the second API is realized.

Description

A kind of method, apparatus and system of Dialog processing
Technical field
The present invention relates to field of computer technology, more particularly to a kind of method, apparatus and system of Dialog processing.
Background technology
With the fast development of Internet technology, increasing service can be provided by the Internet, such as:Order Meal, ticket booking, shopping etc..Under traditional approach, ISP provides the user clothes by the WEB doors oneself set up Business, when often changing due to customer demand Jing, needs ISP that the boundary of WEB doors is constantly updated according to customer demand Face, maintenance difficulties are larger.
Therefore, part ISP by provide service with application programming interface(Application Programming Interface, API)Mode open to the outside world, third party developer or Internet firm utilize these API Various applications are developed, to meet user individual, multifarious demand.
As shown in figure 1, the method for current a kind of conventional opening API is:In the client for calling API and real offer The API of Internet service(API Backend, API rear end)Between increase an API agent(API agent), terminal use(End User)The service provided using API rear ends by client, runs the local application of client(Native App)Or Web application(Web App), API rear ends, the service provided using API rear ends are accessed via API agent.
API agent in Fig. 1 is commonly referred to as API gateway(API Gateway), ability open platform(Capability Open Platform)Or API open platforms(API Open Platform), realize in API agent API Calls management, The functions such as control, charging, interface protocol normalization.
In Fig. 1, terminal use is in the local application run in client or during web application, local application Or web application needs to call the API of API rear ends.In order to be managed to the API Calls of API rear ends, control or interface lattice Formula normalization etc., API rear ends are not directly to application program opening API, but opening API is to API agent, then opened by API agent API is put to application program.
During current API is opened, the equipment that calls of the API in API agent is called, hereinafter referred to as " API Calls set It is standby "(Can be the client in Fig. 1 or API rear ends etc.)It is independent between the multiple API Calls initiated, session pass need not be set up Connection.But under for some special business scenarios, it is desirable to multiple API Calls conversate and associates but using current opening API Method cannot but realize.
Such as, during the API Calls shown in Fig. 2, interacting message main flow is as follows:
Client call API1;
API agent arranges session data and preserves;
API agent calls the API2 of API rear ends;
The data that API agent is arranged before obtaining;
API agent calls the API3 of API rear ends;
API agent arranges session data according to the data of the return of API3;
API agent synthesis API3 calls return information and the data fetched from session to carry out logical process;
API agent returns calling for API1 and returns to client.
In fig. 2 in shown flow process, the setting of the data that can only conversate in the API Calls flow process of a client And extraction, if client initiates API Calls twice, the session that cannot obtain the setting of first time API Calls is called for the second time Data.
To sum up, current API open technique cannot realize that API Calls equipment calls multiple API of API agent in priority When, the API for calling below obtains the session data arranged during above API Calls, to realize the session association of multiple API Calls.
The content of the invention
The embodiment of the present invention provides a kind of method, apparatus and system of Dialog processing, first to realize API Calls equipment Session association during the multiple API in API agent is called afterwards.
In a first aspect, the embodiment of the present invention provides a kind of method of Dialog processing, methods described includes:
API agent is received and calls an API's from what the API Calls equipment for calling the first application programming interface API sent Request;
The API agent performs the handling process of an API according to the request for calling an API, is performing an API's In handling process, the session data of the corresponding sessions of an API is cached;
The API agent is received from the request for calling the 2nd API for calling the API Calls equipment of the 2nd API to send;
The API agent performs the handling process of the 2nd API according to the request for calling the 2nd API, is performing the 2nd API's In handling process, according to the external transactions mark for identifying the corresponding sessions of an API that the request for calling the 2nd API includes Know ID, obtain the session data of the session cached in the handling process for performing an API, according to the session for obtaining Data are processed to the session.
With reference in a first aspect, in the first possible implementation, methods described also includes:
The API agent determines the external transactions of the corresponding sessions of an API in the handling process for performing an API ID, and external transactions ID of determination are notified to the API Calls equipment for calling the 2nd API;Or receive from calling the 2nd API's External transactions ID that API Calls equipment sends, and external transactions ID of reception are defined as the outside of the corresponding sessions of an API Affairs ID;
The API agent is cached in obtaining the handling process for performing an API in the handling process for performing the 2nd API The session session data before, judge the corresponding sessions of an API that determine in the handling process for performing an API External transactions ID it is consistent with external transactions ID for calling the request of the 2nd API to include.
With reference in a first aspect, in second possible implementation, methods described also includes:
The API agent determines the external transactions of the corresponding sessions of an API in the handling process for performing an API ID, and external transactions ID of determination are notified to the API Calls equipment for calling the 2nd API;Or receive from call the 2nd API should With external transactions ID for sending, and external transactions ID of reception are defined as external transactions ID of the corresponding sessions of an API;
The API agent perform an API handling process in, it is determined that the outside thing of the corresponding sessions of an API After business ID, the mark, the mark of the corresponding API rear ends of an API according to the corresponding API suppliers of an API, and determine External transactions ID, generate corresponding internal affairs ID, and record internal affairs ID of generation and the meeting of the session of caching The corresponding relation of words data;
The API agent is cached in obtaining the handling process for performing an API in the handling process for performing the 2nd API The session session data before, after the mark, the corresponding API of the 2nd API according to the corresponding API suppliers of the 2nd API The mark at end and external transactions ID that the request of the 2nd API includes are called, generate corresponding internal affairs ID, judgement is being held Internal affairs ID generated in the handling process of the 2nd API of row and the inside thing generated in the handling process for performing an API ID is consistent for business.
Second possible reality of the first possible implementation, first aspect with reference to first aspect, first aspect Existing mode, in the third possible implementation of first aspect,
The API agent performs the handling process of an API to be included:The API agent is based on for describing at an API The expandable mark language XML file of reason flow process performs the handling process of an API;
The API agent performs the handling process of the 2nd API to be included:The API agent is based on for describing at the 2nd API The XML file of reason flow process performs the handling process of the 2nd API.
Second aspect, the embodiment of the present invention additionally provide a kind of method of Dialog processing, and methods described includes:
In-service units interface API agent is performed in the handling process of an API, and API Calls equipment is from the API agent External transactions ID of the corresponding sessions of an API are obtained in the response of the API that place returns;Or API Calls equipment is to described API agent sends external transactions ID, so that external transactions ID for receiving are defined as API correspondences by the API agent Session external transactions ID.
The API Calls equipment sends the request for calling the 2nd API to the API agent, and the request includes described External transactions ID of the corresponding sessions of the first API, so that the API agent is obtained according to external transactions ID of the session The session data of the session that the API agent is cached in an API handling processes are performed is taken, and according to obtaining The session data of session is processed to the session.
The third aspect, the embodiment of the present invention additionally provide a kind of application programming interface API agent, the API agent Including:
First processing module, for receiving from calling that the API Calls equipment for calling the first application programming interface API sends The request of the first API;Request according to an API is called performs the handling process of an API, in the process for performing an API In flow process, the session data of the corresponding sessions of an API is cached;
Second processing module, for receiving from calling the 2nd API's to call the request for calling the 2nd API that equipment sends; Request according to the 2nd API is called performs the handling process of the 2nd API, in the handling process for performing the 2nd API, according to calling The external transactions mark ID for identifying the corresponding sessions of an API that the request of the 2nd API includes, obtains at described first The session data of the session that reason module is cached in the handling process for performing an API, according to the session number for obtaining According to processing to the session.
With reference to the third aspect, in the first possible implementation, the first processing module is additionally operable to:Performing the In the handling process of one API, determine external transactions ID of the corresponding sessions of an API, and external transactions ID for determining are notified To the API Calls equipment for calling the 2nd API;Or receive from external transactions ID for calling the API Calls equipment of the 2nd API to send, And external transactions ID of reception are defined as external transactions ID of the corresponding sessions of an API;
The Second processing module is additionally operable to:In the handling process for performing the 2nd API, the first processing module is obtained Before the session data of the session cached in the handling process for performing an API, judge in the processing stream for performing an API External transactions ID and external transactions ID for calling the request of the 2nd API to include of the corresponding sessions of an API determined in journey Unanimously.
With reference to the third aspect, in second possible implementation, the first processing module is additionally operable to:Performing the In the handling process of one API, determine external transactions ID of the corresponding sessions of an API, and external transactions ID for determining are notified To the API Calls equipment for calling the 2nd API;Or receive from external transactions ID that equipment sends of calling for calling the 2nd API, and will External transactions ID of reception are defined as external transactions ID of the corresponding sessions of an API;It is determined that an API corresponding sessions After external transactions ID, the mark, the mark of the corresponding API rear ends of an API according to the corresponding API suppliers of an API, with And external transactions ID for determining, corresponding internal affairs ID are generated, and records internal affairs ID of generation and the meeting of caching The corresponding relation of the session data of words;
The Second processing module is additionally operable to:In the handling process for performing the 2nd API, the first processing module is obtained Before the session data of the session cached in the handling process for performing an API, provided according to the corresponding API of the 2nd API The mark of person, the mark of the corresponding API rear ends of the 2nd API and external transactions ID that the request of the 2nd API includes are called, it is raw Into corresponding internal affairs ID, judge internal affairs ID generated in the handling process for performing the 2nd API with described first at Internal affairs ID that reason module is generated in the handling process for performing an API are consistent.
Second possible reality of the first possible implementation, the third aspect with reference to the third aspect, the third aspect Existing mode, in the third possible implementation of the third aspect,
The first processing module specifically for:Based on the extensible markup language for the first API handling processes of description XML file performs the handling process of an API;
The Second processing module specifically for:Second is performed based on the XML file for describing the 2nd API handling processes The handling process of API.
Fourth aspect, the embodiment of the present invention additionally provide a kind of API Calls equipment, and the equipment includes:
First processing module, performs in the handling process of an API, from described for in-service units interface API agent External transactions ID of the corresponding sessions of an API are obtained in the response of the API returned at API agent;Or to the API generations External transactions ID are sent in haircut, so that external transactions ID for receiving are defined as the corresponding sessions of an API by the API agent External transactions ID;
Second processing module, for the request for calling the 2nd API is sent to the API agent, the request includes institute External transactions ID of the corresponding sessions of an API are stated, so that external transactions ID of the API agent according to the session, The session data of the session that the API agent is cached in an API handling processes are performed is obtained, and according to the institute for obtaining The session data for stating session is processed to the session.
In terms of 5th, the embodiment of the present invention additionally provides a kind of system of Dialog processing, including application programming interface API agent and API Calls equipment,
The API agent is used for:The request for calling an API according to receiving performs the handling process of an API, is holding In the handling process of the first API of row, the session data of the corresponding sessions of an API is cached;According to from the API Calls equipment The request for calling the 2nd API for receiving performs the handling process of the 2nd API, in the handling process for performing the 2nd API, according to tune The external transactions mark ID for identifying the corresponding sessions of an API included with the request of the 2nd API, obtains and is performing the The session data of the session cached in the handling process of one API, enters to the session according to the session data for obtaining Row is processed;
The API Calls equipment is used for:The request for calling the 2nd API is sent to the API agent, the request includes External transactions ID of the corresponding sessions of the first API.
With reference in terms of the 5th, in the first the possible implementation in terms of the 5th, the API agent is additionally operable to: Perform in the handling process of an API, determine external transactions ID of the corresponding sessions of an API, and the external transactions that will be determined ID is notified to the API Calls equipment;The API Calls equipment is additionally operable to:The process of an API is performed in the API agent In flow process, external transactions ID of the session that the API agent is notified are received;Or
The API Calls equipment is additionally operable to:In the handling process that the API agent performs an API, by external transactions ID issues the API agent;The API agent is additionally operable to:External transactions ID that reception is sent from the API Calls equipment, and External transactions ID of reception are defined as into external transactions ID of the corresponding sessions of an API;
The API agent is additionally operable to:In the handling process for performing the 2nd API, the handling process for performing an API is obtained Before the session data of the session of middle caching, the API correspondences determined in the handling process for performing an API are judged Session external transactions ID it is consistent with external transactions ID for calling the request of the 2nd API to include.
With reference in terms of the 5th, in second in terms of the 5th possible implementation, the API agent is additionally operable to: Perform in the handling process of an API, determine external transactions ID of the corresponding sessions of an API, and the external transactions that will be determined ID is notified to the API Calls equipment;The API Calls equipment is additionally operable to:The process of an API is performed in the API agent In flow process, external transactions ID of the session that the API agent is notified are received;Or
The API Calls equipment is additionally operable to:In the handling process that the API agent performs an API, by external transactions ID issues the API agent;The API agent is additionally operable to:External transactions ID that reception is sent from the API Calls equipment, and External transactions ID of reception are defined as into external transactions ID of the corresponding sessions of an API;
The API agent is additionally operable to:In the handling process for performing an API, it is determined that an API corresponding sessions After external transactions ID, the mark, the mark of the corresponding API rear ends of an API according to the corresponding API suppliers of an API, with And external transactions ID for determining, corresponding internal affairs ID are generated, and records internal affairs ID of generation and the meeting of caching The corresponding relation of the session data of words;In the handling process for performing the 2nd API, obtain in the handling process for performing an API Before the session data of the session of caching, the mark, the 2nd API according to the corresponding API suppliers of the 2nd API is corresponding The mark of API rear ends and external transactions ID that the request of the 2nd API includes are called, generate corresponding internal affairs ID, sentence In being scheduled in the handling process for perform the 2nd API internal affairs ID that generate and generating in the handling process for performing an API Portion's affairs ID are consistent.
With reference to second possible reality in terms of the first the possible implementation in terms of the 5th, in terms of the 5th, the 5th Existing mode, in the third the possible implementation in terms of the 5th, the API agent specifically for:
The processing stream of the first API is performed based on the expandable mark language XML file for describing an API handling processes Journey;
The handling process of the 2nd API is performed based on the XML file for describing the 2nd API handling processes.
Using the method, apparatus and system of Dialog processing provided in an embodiment of the present invention, API Calls equipment is calling second During API, in the request for calling the 2nd API, external transactions ID for the corresponding sessions of the first API of mark are carried so that API agent can be obtained according to external transactions ID in the request for calling the 2nd API and perform what is cached in an API handling processes The session data of session, and session is processed according to the session data for obtaining, it is achieved thereby that an API and the 2nd API Session association.
Further, mark of the API agent according to API suppliers, the mark of API rear ends, and external transactions ID, generate Corresponding internal affairs ID, so as to realize that API agent provides API by multiple API suppliers, which can be with multiple API back end interfaces.
Further, API agent performs the handling process of API based on the XML file for describing API handling processes, when When the handling process of API needs modification, code compilation need not be carried out, is redeployed, need not stop the operation of API agent just can be with Realize the modification to API handling processes.
The embodiment of the present invention additionally provides another kind of API agent, API generation methods and API and performs method, existing to solve In some API generation methods, API is generated by the way of coding, method is complicated, it is not easy to the problem of realization.
In terms of 6th, a kind of application programming interface API agent, the API agent bag are embodiments provided Include:
API developers, for providing graphical API development interfaces, and receive in the development interface for providing and are used for The API for generating API generates instruction;The API according to receiving generates instruction generation for describing the handling process of the API API agent resource;The API agent resource for generating is issued into API agent engine;
API agent engine, for preserving the API agent resource that the API developers for receiving send, and is receiving After the request of API described in API Calls equipment calls, perform described in the API agent resource according to the request of the API is called The handling process of API;If there is the operation of caching session data in the handling process of the API, basis calls asking for the API Session data is sought survival into, and the session data of generation is cached in data buffer storage;If having acquisition in the handling process of the API The operation of session data, then according to calling the request of the API that session data is read from data buffer storage;
Data buffer storage, for caching the session data of API agent engine generation, and the meeting that API agent engine is read Words data is activation gives API agent engine.
In terms of 7th, the embodiment of the present invention provides a kind of method for generating application programming interface API, methods described bag Include:
API developers in API agent are received to generate for the API for generating API in graphical API development interfaces and are referred to Order;
The API developers generate instruction generation for describing the handling process of the API according to the API for receiving API agent resource;
The API developers are issued the API agent engine in the API agent by the API agent resource for generating, with The API agent engine is made after the request of API described in API Calls equipment calls is received, calls the API's according to what is received Request performs the handling process of API described in the API agent resource.
Eighth aspect, the embodiment of the present invention provide a kind of method for performing application programming interface API handling process, institute The method of stating includes:
API agent engine in API agent receives the request for calling API that API Calls equipment sends;
The API agent engine is performed for describing API generations of the API according to the request for calling the API for receiving The handling process of API described in reason resource, wherein the API resources are API developers in the API agent according to receiving API for generating the API generates instruction and generates and issue the API agent engine;
If there is the operation of caching session data in the handling process of the API, the API agent engine is according to calling The request for stating API generates session data, and the session data of generation is cached in the data buffer storage in the API agent;If Have in the handling process of the API obtain session data operation, then the API agent engine according to call the API ask Ask session data is read from the data buffer storage.
Method is performed using another kind of API agent provided in an embodiment of the present invention, API generation methods and API, by providing Graphic interface, receives API and generates instruction, generates instruction according to the API for receiving and generates API agent resource, and API agent engine exists Receive after calling the request of API, perform the handling process in API agent resource, so as to without the need for coding, easily generate API.
Description of the drawings
Fig. 1 is the schematic diagram of the method for current a kind of conventional opening API;
Fig. 2 is a kind of flow chart of current API Calls process;
Fig. 3 is the structural representation of session processing system provided in an embodiment of the present invention;
Fig. 4 is the structural representation of the first API agent provided in an embodiment of the present invention;
Fig. 5 is the structural representation of API developers provided in an embodiment of the present invention;
Fig. 6 is the structural representation of API agent engine provided in an embodiment of the present invention;
Fig. 7 is affairs ID mapping method schematic diagram provided in an embodiment of the present invention;
Fig. 8 is that API provided in an embodiment of the present invention creates the layout interface schematic diagram for paying;
Fig. 9 is the schematic diagram that session parameter provided in an embodiment of the present invention arranges interface;
Figure 10 is the interface schematic diagram for arranging external transactions ID create-rule provided in an embodiment of the present invention;
Figure 11 is the interface schematic diagram for arranging external transactions ID provided in an embodiment of the present invention;
Figure 12 is that the session data that arranges provided in an embodiment of the present invention preserves regular interface schematic diagram;
Figure 13 is the schematic diagram that API provided in an embodiment of the present invention creates the flow file for paying;
Figure 14 is the schematic diagram for arranging conversation strategy file provided in an embodiment of the present invention;
Figure 15 is the schematic diagram at the layout interface that embodiment of the present invention API confirms to pay;
Figure 16 is the interface schematic diagram for arranging and obtaining session parameter provided in an embodiment of the present invention;
Figure 17 is that external transactions ID that arrange provided in an embodiment of the present invention obtain regular interface schematic diagram;
Figure 18 confirms to pay the schematic diagram of the session association that payment is created with API for API in the embodiment of the present invention;
During Figure 19 is the embodiment of the present invention, API suppliers realize the method flow diagram of API session associations;
Method flow diagrams of the Figure 20 for the embodiment of the present invention one;
Method flow diagrams of the Figure 21 for the embodiment of the present invention two;
Figure 22 is the structural representation of second API agent provided in an embodiment of the present invention;
Figure 23 is the structural representation of the third API agent provided in an embodiment of the present invention;
Figure 24 is the procedure schematic diagram of the first Dialog processing provided in an embodiment of the present invention;
Figure 25 is the procedure schematic diagram of second Dialog processing provided in an embodiment of the present invention;
Figure 26 is the structural representation of the 4th kind of API agent provided in an embodiment of the present invention;
Figure 27 is the structural representation of API Calls equipment provided in an embodiment of the present invention;
Figure 28 is a kind of procedure schematic diagram of generation API provided in an embodiment of the present invention;
Figure 29 is a kind of procedure schematic diagram of execution API handling processes provided in an embodiment of the present invention.
Specific embodiment
The embodiment of the present invention provides a kind of method, apparatus and system of Dialog processing, first to realize API Calls equipment Session association during the multiple API in API agent is called afterwards.
In a kind of method of Dialog processing provided in an embodiment of the present invention, API agent is received from calling an API's What API Calls equipment sent calls the request of an API;API agent performs an API's according to the request for calling an API Handling process, in the handling process for performing an API, caches the session data of the corresponding sessions of an API;API agent connects Receive from the request for calling the 2nd API for calling the API Calls equipment of the 2nd API to send;API agent is according to calling the 2nd API's Request performs the handling process of the 2nd API, in the handling process for performing the 2nd API, wraps according to calling in the request of the 2nd API The external transactions mark ID for identifying the corresponding sessions of an API for including, obtains and delays in the handling process for performing an API The session data of the session deposited, is processed to session according to the session data for obtaining.
During the embodiment of the present invention passes through, that calls the 2nd API calls equipment when two API is called, and is calling the 2nd API Request in, carry for identifying external transactions ID of the corresponding sessions of an API so that API agent can be according to calling External transactions ID in the request of the 2nd API obtain the session data of the session cached in performing an API handling processes, and root Session is processed according to the session data for obtaining, it is achieved thereby that the session association of an API and the 2nd API.
The embodiment of the present invention additionally provides a kind of API agent, API generation methods and API and performs method, existing to solve API generation methods in, generate API by the way of coding, method is complicated, it is not easy to the problem of realization.
API agent provided in an embodiment of the present invention includes:API developers, for providing graphical API development interfaces, and Receive in the development interface for providing instruction is generated for the API for generating API;The API according to receiving generates instruction Generate for describing the API agent resource of the handling process of the API;The API agent resource for generating is issued into API agent Engine;API agent engine, for preserving the API agent resource that the API developers for receiving send, and is receiving API After calling the request of API described in equipment calls, API described in the API agent resource is performed according to the request of the API is called Handling process;If there is the operation of caching session data in the handling process of the API, according to the request for calling the API Session data is generated, and the session data of generation is cached in data buffer storage;If there is acquisition meeting in the handling process of the API The operation of data is talked about, then basis calls the request of the API that session data is read from data buffer storage;Data buffer storage, for delaying The session data of API agent engine generation is deposited, and the session data that API agent engine reads is sent to into API agent engine.
By providing graphic interface, receive API and generate instruction, instruction is generated according to the API for receiving and generates API agent money Source, API agent engine perform the handling process in API agent resource after the request for calling API is received, so as to encode, API is generated easily.
Below, the embodiment of the present invention is described in detail with reference to accompanying drawing.
Fig. 3 is the structural representation of session processing system provided in an embodiment of the present invention.As shown in figure 3, the system includes: API Calls equipment 301 and API agent 302, wherein
API agent 302 is used for:The request for calling an API according to receiving performs the handling process of an API, is holding In the handling process of the first API of row, the session data of the corresponding sessions of an API is cached;According to from API Calls equipment 301 The request for calling the 2nd API for receiving performs the handling process of the 2nd API, in the handling process for performing the 2nd API, according to tune The external transactions mark ID for identifying the corresponding sessions of an API included with the request of the 2nd API, obtains and is performing the The session data of the session cached in the handling process of one API, according to obtain the session data to session at Reason;
API Calls equipment 301 is used for:The request for calling the 2nd API is sent to API agent 302, request includes first External transactions ID of the corresponding sessions of API.
Session processing system provided in an embodiment of the present invention realizes the session association of an API and the 2nd API.Concrete When realizing, according to different application scenarios, realize that the mode of an API and the 2nd API session associations at least includes following two:
Mode one
API agent 302 determines the external transactions of the corresponding sessions of an API in the handling process for performing an API ID, and external transactions ID of determination are notified to API Calls equipment 301;
Mode two
External transactions ID are issued API in the handling process that API agent 302 performs an API by API Calls equipment 301 Agency 302, external transactions ID received from API Calls equipment 301 are defined as the corresponding sessions of an API by API agent 302 External transactions ID.
One specific embodiment of mode one can be found in latter embodiments one, a specific embodiment of mode two Can be found in latter embodiments two.
In above two mode, API agent 302 in the handling process for performing the 2nd API is obtained and performs an API Handling process in before the session data of the session that caches, in addition it is also necessary in the corresponding sessions of an API for judging to determine External transactions ID it is consistent with external transactions ID for calling the request of the 2nd API to include in the case of, according to calling the 2nd API External transactions ID that include of request obtain the session data cached in the handling process for performing an API.
Here, API Calls equipment 301 can be any API Calls equipment for calling the API in API agent 302, such as: Can be the client in Fig. 1 or API rear ends.
When API Calls equipment 301 is client, inside API Calls equipment 301, include local application and/or Web Application program, API Calls equipment 301 are realized to API agent by calling local application or web application in which 302 send the request for calling API.When API Calls equipment 301 is API rear ends, API Calls equipment 301 is by calling in which Application program, sends the request for calling API to API agent 302.
Typically, API agent 302 is only by an API supplier(API Provider)There is provided API, and its only with an API Back end interface, now can uniquely determine a session by external transactions ID of session, obtain the session data of the session.This In bright embodiment, there is provided a kind of optional scheme, using this alternative, it is capable of achieving API agent 302 and is provided by multiple API Person provide API, its can with multiple API back end interfaces,
When API agent 302 provides API by multiple API suppliers, can between external transactions ID of different API suppliers Can lead to a conflict because repeating;When API agent 302 docks multiple API rear ends, external transactions ID of different API rear ends also may be used Can lead to a conflict because repeating.To solve this problem, in the alternative of the embodiment of the present invention, in 302 inter-process of API agent When, need inside according to API agent 302 is generated with external transactions ID of the session used when interacting between API Calls equipment 301 Internal affairs ID for using(Inner Transaction ID), different API can be distinguished according to internal affairs ID for generating and carried Donor and different API rear ends.
Specifically, API agent 302 is in the processing procedure for performing an API, it is determined that an API corresponding sessions After external transactions ID, mark of the needs according to the corresponding API suppliers of an API, the mark of the corresponding API rear ends of an API Know, and external transactions ID for determining, corresponding internal affairs ID are generated, and records internal affairs ID of generation and the meeting of caching The corresponding relation of the session data of words;
API agent 302 is cached in obtaining the handling process for performing an API in the handling process for performing the 2nd API Before the session data of the session, mark, the corresponding API of the 2nd API according to the corresponding API suppliers of the 2nd API is needed The mark of rear end and external transactions ID that the request of the 2nd API includes are called, generate corresponding internal affairs ID;
Internal affairs ID and performing first that API agent 302 is generated in the handling process of the 2nd API of Predicated execution In the case that external transactions ID that generate in the handling process of API are consistent, could obtain and cache in the handling process of an API Session session data.
In the handling process that API agent 302 performs an API, generation session data can be cached, such as, API Calls set Standby 301 initiate delivery operation by calling the request of an API, and the note check code in payment process can be made by API agent 302 Cache for session data, subsequently to compare with the note check code of terminal use's input.API agent 302 caches session Data, and according to external transactions ID of session, generate internal affairs ID of session, record generate if internal affairs ID with it is slow The corresponding relation of the session data of the session deposited.
API agent 302 for different API, when internal affairs ID of session are generated according to external transactions ID of session, It is that, based on identical create-rule described later, and for the different API of same session, its API supplier is identical, API rear ends are also identical, and meeting in the API handling processes that API Calls equipment 301 is carried in the request for calling the 2nd API External transactions ID of words, therefore internal affairs ID and above-mentioned first generated in may be implemented in the handling process of above-mentioned 2nd API Internal affairs ID generated in the handling process of API are identical, thus can obtain at an API in the handling process of the 2nd API The session data of the session cached in reason flow process, so as to realize the session association of an API and the 2nd API.
The mode that internal affairs ID of session are generated according to external transactions ID of session has various, as long as difference can be distinguished API suppliers and different API rear ends.Such as:Can be by such as string-concatenation, i.e. internal affairs ID=API supplier ID+Transaction ID NameSpaces+external transactions ID;Or use physical database or memory database relation table to preserve Mapping relations etc..Here Transaction ID NameSpaces are used for distinguishing different API rear ends, i.e., after different API End is with different Transaction ID NameSpaces.
Here, the mark of API suppliers can be according to the title of API or the mark of API in the request for calling API come really It is fixed.Such as, in API agent 302, the API for arranging different API suppliers offers has different name prefixes, and records The corresponding relation that the prefix of API Name is identified with API suppliers.So when API agent 302 is after the request for calling API is received, The mark of API suppliers is determined according to the prefix of the title of API.Or in API agent 302, have recorded the mark of API with The corresponding relation of API suppliers mark, API Calls equipment 301 carry the mark of API, API agent 302 in calling the request of API After the request for calling certain API is received, the mark and API of the API for having been recorded according to the identifier lookup of the API carried in request The corresponding relation of supplier's mark, you can determine the mark of the corresponding API suppliers of the API.
Or, the mark of API suppliers can be according to the universal resource identifier of API(Uniform Resource Identifier, URI)To determine, the API name prefixs containing API suppliers in the URI of API by API name prefixs are Can determine that the mark of API suppliers.
The mark of API rear ends also dependent on the title or API of API mark determining, method is provided with API determined above The method of the mark of person is similar to, and repeats no more here.Further, it is also possible to adopt manner below:If API Calls equipment 301 is Client, then carry the information of API rear ends, such as IP address, API rear ends title or API rear ends mark in the request for call API Know etc., API agent 302 obtains above- mentioned information after the request that this calls API is received, after the above- mentioned information and API of record The corresponding relation of the mark at end, determines the mark of API rear ends.If API Calls equipment 301 is API rear ends, the request of API is called In need not carry the information of API rear ends, API agent 302 can determine corresponding API from the source address of request for calling API Rear end.
In mode one, in the handling process of an API, API agent 302 it needs to be determined that external transactions ID of session, and External transactions ID of determination are returned to into API Calls equipment 301.Here, API agent 302 determines external transactions ID of session Method may include but be not limited to following method:
Method one, automatically generate;
Method two, obtained by calling in the request of an API;
Method three, the acquisition from the response of API rear ends.
It should be noted that, although an API Calls equipment 301 in Fig. 3, is illustrate only, but actually API agent 302 can With while there is session between multiple API Calls equipment 301.I.e. API agent 302 may receive multiple API Calls equipment 301 requests for calling API, API agent 302 can safeguard different sessions, each session correspondence for different API Calls equipment 301 Different external transactions ID, to distinguish different sessions.So as to, API agent 302 is called receiving certain API Calls equipment 301 During the request of the 2nd API, the session data of the session is obtained according to external transactions ID carried in the request of the 2nd API, The differentiation of the session data of different sessions can be realized.
Below, the definition mode for an API and the 2nd API in API agent 302 is illustrated.
Generally, each API in API agent is developed by one or more API suppliers.In traditional development scheme Under, encode to develop each API by API suppliers, there is code compilation, redeploy process, it may be necessary to first stop API generations The operation of reason can just complete the loading for rewriting post code, cause impact to the use of API agent.
In preferred version provided in an embodiment of the present invention, based on for describing the extensible markup language of API (EXtensible Markup Language, XML)File performs the handling process of API.I.e. no longer by writing the side of code Formula defines the handling process of API, but is defined using XML file.Such benefit is exactly, when the handling process to API is entered During row modification, code compilation need not be carried out, is redeployed, the operation that need not stop API agent can just being realized to API processing streams The modification of journey.
Thus, alternatively, API agent 302 specifically for:
The handling process of the first API is performed based on the XML file for describing an API handling processes, based on for retouching The XML file for stating the 2nd API handling processes performs the handling process of the 2nd API.
Above, the operation principle of session processing system provided in an embodiment of the present invention is described.Below, to this By graphic interface, bright embodiment offer is a kind of to realize that the API agent of API is illustrated.Pass through graphic interface reality as this A kind of optional implementation of the API agent of existing API, the API agent are equally applicable to the session processing system shown in Fig. 3 In, realize the session association between multiple API.
In traditional API approach, API suppliers realize each API by coding.The mode of coding is to API suppliers Programming levels have higher requirements, and be readily incorporated mistake in an encoding process(Bug), develop and the cycle of test can all compare It is long.In view of this, embodiments provide the API agent that API is realized by graphic interface shown in Fig. 4.
Fig. 4 is the structural representation of the first API agent provided in an embodiment of the present invention, and the API agent is with graphical boundary Realize the exploitation of API in face.As shown in figure 4, the API agent side and one or more application terminal interfaces, another with one Or multiple API rear ends(The system that API active services are provided)Interface, externally also provides API development interfaces and gives one or more API Supplier.
Below, first the composition structure of the API agent in Fig. 4 is illustrated, then to developing boundary by graphical API Realize that the method for API is described in face.
First, as shown in figure 4, the API agent includes:
API agent logic development device, abbreviation API developers(API Builder)401, for providing figure to API suppliers Shape API development interface;
Pattern development interface can have various implementations, such as:The graphic interface of WEB online modes, or figure use Family interface(Graphical user interface, GUI)IDE(Integrated Development Environment, IDE), such as:The IDE interfaces of Eclipse;
API agent engine(API Proxy Engine)402, for the API agent money developed based on API developers 401 Source(I.e. be used for describe API handling process file), perform the handling process of API(Such as:The execution of session association logic, Create session, session data is saved in data buffer storage 403, from data buffer storage 403 read session data, to application terminal Offer API, and the API of API rear ends offer is provided etc.), the outside of session alternatively, is obtained from the API parameters of API rear ends Affairs ID, the mapping for generating internal affairs ID, completing internal affairs ID and external transactions ID;
Data buffer storage(Data Cache)403, for caching current each session(Meeting that is having created and being not over Words)Session data, alternatively, can support that memory cache mode is stored, and can pass through connect Fig. 4 in file system 405 or Data base 404 supports physics disk system storage of session data.
Specifically, API developers 401, for providing graphical API development interfaces, and in the development interface for providing Receive instruction is generated for the API for generating API;The API according to receiving generates instruction and generates the processing stream for being used to describing the API The API agent resource of journey;The API agent resource for generating is issued into API agent engine 402;
API agent engine 402, for preserving the above-mentioned API agent resource that the API developers 401 for receiving send, and is receiving To after the request of the API Calls equipment calls API, the API in the API agent resource is performed according to the request for calling the API Handling process;If there is the operation of caching session data in the handling process of the API, meeting is generated according to the request of the API is called Words data, and the session data of generation is cached in data buffer storage 403;If there is acquisition session number in the handling process of the API According to operation, then according to calling the request of the API to read session data from data buffer storage 403;
Data buffer storage 403, for caching the session data of the generation of API agent engine 402, and by API agent engine 402 The session data of reading is sent to API agent engine 402.
The exemplary message definition of session data buffer storage to data buffer storage 403 can be found in example two by API agent engine 402, API agent engine 402 obtains the exemplary message definition of session data from data buffer storage 403 and can be found in example three.
In API agent shown in Fig. 4, API developers 401, API agent engine 402, data buffer storage 403 can pass through Trunking mode scalability and capacity, while meeting the requirement of reliability.
Alternatively, the API agent also includes:Data base(Database)404 and/or file system(File)405,
Wherein, data base 404 is used for:The session data cached in data buffer storage 403 is preserved by data base, can Reliability is lifted in the case of equipment fault or buffer memory capacity, general relational database or non-relation number are expanded by physical store According to storehouse;
File system 405, the session data for data buffer storage 403 is cached carry out persistent storage with file mode, Reliability can be lifted in the case of equipment fault or buffer memory capacity is expanded by physical store.
With regard to the storage of session data, there can be various implementations, such as, as shown in figure 22, in API agent, not include number According to storehouse or file system, session data is stored in data buffer storage.Or in storage of session data, using the side shown in Figure 23 There is no independent data buffer storage in formula, i.e. API agent, directly by session data buffer storage in API agent engine.Additionally, Figure 22, In Figure 23, API agent can dock multiple API rear ends, and while provide API Calls interface for multiple client.
Below, API developers 401 are described in detail.As shown in figure 5, API developers 401 include:
Web graph shape interface(Web GUI Interface)4011, provide for providing graphical API to API suppliers Configuration interface;
API agent generation module(API Proxy Generating Module)4012, for according to Web graph Xing Hua circle The configuration information that the operation of API suppliers is produced in face 4011 generates API agent resource(API Proxy Resource), API Agent engine 402 performs API agent logic according to the API agent resource that API agent generation module 4012 is produced.
Alternatively, when implementing, the function of API agent generation module can be realized by API agent engine 402.
API agent engine 402 carries out logic control and place to API Calls by performing the logic in API agent resource Reason, parses including the argument structure body of the request to calling API, the response for calling API.To call API request and When calling the response of API to be parsed, language can be described using corresponding such as Web service according to different interface protocol types Speech(Web Services Description Language, WSDL), Web application description languages(Web Application Description Language, WADL), java script Object Notation(JavaScript Object Notation, JSON) The API description language general etc. industry or data form are parsed.
The logic of the API agent resource of generation is arranged by Web graph shape interface 4011 is concrete, is saved as API and is performed stream Journey file, flow file are in series by multiple API strategies, and alternatively, these files are preserved in XML modes.As it was previously stated, adopting Preserved with XML modes, can be avoided in traditional API approach, after the code revision to API, to amended code It is compiled, the process for redeploying.
Below, API agent engine 402 is illustrated.
As shown in fig. 6, API agent engine 402 includes:
API agent performing module(API Proxy Execute Module)4021, for according to API request loading correspondence API agent resource perform, in the process of implementation, if it find that exist in API handling processes arranging session or session data Strategy, then parse the API agent resource file of loading, to obtain or generate external transactions ID of session, realizes the outside of session The mapping of internal affairs ID of affairs ID and session, the storage or acquisition of session data;
Alternatively, API agent engine 402 also includes affairs ID mapping block(Transaction ID Mapping Module)4022, for realizing the mapping of external transactions ID and internal affairs ID.
Alternatively, API agent performing module 4021 is additionally operable to, and calls affairs ID mapping block 4022 to complete external transactions ID With the mapping of internal affairs ID.API agent performing module 4021 call affairs ID mapping block 4022 complete external transactions ID and The exemplary message of the mapping of internal affairs ID is as shown in example one.Alternatively, the function of affairs ID mapping block 4022 can be direct Completed by API agent performing module 4021, will affairs ID mapping block 4022 be incorporated in API agent performing module 4021.
The mapping method of external transactions ID and internal affairs ID is as shown in Figure 7.In Fig. 7, affairs ID NameSpace corresponding A PI Rear end, i.e., different API rear ends have different affairs ID NameSpaces.Affairs ID mapping block is according to external transactions ID, API The mark of supplier and affairs ID NameSpace generate internal affairs ID, and are stored in data buffer storage 403.Alternatively, data The key-value pair of the session data in caching 403(Key-Value)In value(Value)Can be independent character string, it is also possible to It is such as XML, the JSON of the data comprising complex format, can also be the binary data obtained after data object is serialized.
When realizing, the affairs ID NameSpace of same API suppliers can not repeat, and same API suppliers' is more Individual API rear ends can use same affairs ID NameSpace, it is also possible to using different affairs ID NameSpaces, depending on not Whether there is the conflict of external transactions ID NameSpace between same API rear ends, if there is conflict, then need using different Affairs ID NameSpace, if do not conflicted, can use identical affairs ID NameSpace, it is also possible to using different affairs ID NameSpaces.
The method that external transactions ID are mapped as internal affairs ID is had a lot, such as by affairs ID mapping block 4022, can be adopted With the mark+TransactionID NameSpaces+outside thing of the mode of string-concatenation, i.e. internal affairs ID=API supplier Business ID;Or use physical database or memory database relation table to preserve mapping relations etc..
Alternatively, shown in Fig. 4 API agent is capable of achieving different API conversates association.As shown in figure 19, API is carried Donor realizes API:Create and pay(createPayment)And API:Confirm to pay(ConfirmPayment)The step of session association It is rapid as follows:
S1901, API supplier enters the interface of API developers 401(As shown in figure 8, so that API is created and is paid as an example);
S1902, API supplier arranges API and creates payment, needs to arrange session and cache session in API is created and paid Data;
S1903, API supplier places in API request or responding process and " arranges session(SetSession)" API plans Icon slightly;
S1904, API supplier clicks on the icon of " setting session ", opens the parameter setting of setting session as shown in Figure 9 Interface, the edit session attribute in the interface, wherein, session attribute may include:External transactions ID(That is external transactions ID)Obtain Mode, external transactions ID create-rule(Such as:General unique identifier(Universally Unique Identifier, UUID)), external transactions ID NameSpace, session data preserve rule, external transactions ID and arrange rule etc.;
In step S1904, API suppliers can click on " external transactions ID generation at the parameter setting interface for arranging session After " editor " icon of rule ", interface as shown in Figure 10 is opened, the setting of external transactions ID create-rule is carried out;API is provided Person can open such as Figure 11 after " editor " icon that " external transactions ID arrange rule " is clicked at the parameter setting interface for arranging session Shown interface, carries out the setting of external transactions ID;API suppliers can click on " session at the parameter setting interface for arranging session After " editor " icon of data preservation rule ", interface as shown in figure 12 is opened, the data that conversate preserve the setting of rule.
By the setting of the 1st step to the 3rd step, the API of generation creates the flow file for paying as shown in figure 13, from Figure 13 As can be seen that for setting session(SetSession), it is by another file(269378FC-DF75-D94B-35AA- F3B7D98A373F)Definition.
By session, the setting session of generation are arranged in step S1904(Set Session)Strategy file 269378FC-DF75-D94B-35AA-F3B7D98A373F.xml as shown in figure 14.
S1905, API supplier in the interface of API developers 401 as shown in figure 15 arranges API and confirms to pay (confirmPayment), need to obtain session data in the API;
S1906, API supplier places the icon of " acquisition session " API strategies in API request or responding process;
S1907, API supplier clicks on the icon of " acquisition session ", arranges boundary in acquisition session parameter as shown in figure 16 In face, the attribute for obtaining session is filled in, wherein the attribute for obtaining session may include:External transactions ID acquisition modes, external transactions ID NameSpaces, external transactions ID obtain rule.
In step S1907, API suppliers can click on " external transactions ID acquisition at the parameter setting interface for arranging session After " editor " icon of rule ", interface as shown in figure 17 is opened, carry out the setting that external transactions ID obtain rule.
As can be seen that in API confirms to pay, external transactions ID are obtained from API request from Figure 16 and Figure 17, And from Figure 11 and Figure 14 as can be seen that when session is arranged, external transactions ID are created by API and is taken back in the response for paying Equipment is called to what API establishments paid(response.body.paymentinfo.paymentID), so propping up when API is created That what is paid calls equipment when calling API to confirm to pay, if external transactions ID obtained in being created the response for paying before from API It is placed in calling API to confirm the request for paying, then during the handling process for paying is confirmed in API, so that it may by external transactions ID The session data cached when API is created and paid is obtained, it is achieved thereby that API confirms to pay and API creates the meeting between paying Words association.
Figure 18 is to realize that API confirms to pay the schematic diagram that the session association for paying is created with API.As shown in figure 18, the 1st step " pay mark " in the middle response for paying API establishments is set to external transactions ID;API is confirmed into that what is paid asks in 2nd step " pay mark " in asking is assigned to external transactions ID;External transactions ID that the 2nd step is obtained are become into internal thing in the 3rd step Business ID;In 4th step, session data is obtained according to internal affairs ID that obtain are mapped in the 3rd step.
After Figure 19 conversates association, API agent provided in an embodiment of the present invention processes API and creates payment and process API confirms that the flow process for paying refers to embodiment one.
Below, the inside story definition for illustrating API agent provided in an embodiment of the present invention by three.
Example one
In API agent engine 402, API agent performing module 4021 calls affairs ID mapping block 4022 to complete outside thing The exemplary message definition of the mapping of business ID and internal affairs ID.
Obtain internal affairs ID(API agent performing module 4021->Affairs ID mapping block 4022)
1)Request message is defined(Such as table 1):
Table 1
2)Response message is defined(Such as table 2)
Table 2
Parameter name Value explanation Field type
Resultcode Result code, 0 represents successfully Integer
ResultDesc As a result describe Character string
InnerTransactionID Internal affairs ID Character string
Example two
The exemplary message of session data buffer storage to data buffer storage 403 is defined by API agent engine 402.
Session is set(API agent engine 402->Data buffer storage 403)
1)Request message is defined(Such as table 3):
Table 3
2)Response message is defined(Such as table 4):
Table 4
Parameter name Value explanation Field type
Resultcode Result code.0 represents successfully Integer
ResultDesc As a result describe Character string
Example three
API agent engine 402 obtains the exemplary message definition of session data from data buffer storage 403.
Obtain session(API agent engine 402<- data buffer storage 403)
1)Request message is defined(Such as table 5):
Table 5
2)Response message is defined(Such as table 6):
Table 6
Below, the present invention is illustrated by specific embodiment.
Embodiment one,
Embodiment one gives a kind of API agent and is processing the flow process that API establishments pay and process API confirmations pay.
The flow process of embodiment one is as shown in figure 20.In Figure 20, the application program in terminal use's operation client is calling API in API agent;API agent engine and data buffer storage are realized and application program and payment as a part for API agent The interaction at center, and caching session data, paying centre is API rear ends.As shown in figure 20, the flow process comprises the steps:
S2001, terminal use trigger billing operation during operation application program;
S2002, application program send to API agent engine and call API to create the request for paying;
S2003, API agent engine generate note check code using the rule for generating note check code;
S2004, API agent engine confirm that API has the strategy for arranging session in creating payment;
S2005, API agent engine create the external transactions ID acquisition modes for paying according to API, it is determined that needing to automatically generate External transactions ID;
S2006, API agent engine generate external transactions ID according to external transactions ID create-rule;
S2007, API agent engine create session, and according to data cached rule, by calling for sending from application program API creates the parameter that obtains in the request for paying, and the note check code for generating, and is assembled into session data, and by session number According to being stored in data buffer storage;
S2008, API agent engine arrange rule according to external transactions ID, external transactions ID are arranged to API establishments and is paid Response parameter in;
S2009, API agent engine API create pay response in returning to external affairs ID to application program;
S2010, application program represent interface, warning terminal user input note check code;
S2011, API agent engine send note check code to terminal use(By modes such as notes, note verification is sent The coding strategy of code is also single strategy, is not belonged in setting conversation strategy);
S2012, terminal use are input into note check code on the client;
S2013, application program send and call API to confirm the request for paying, and external transactions ID and note school are carried in request Test code;
S2014, API agent engine determine that API confirms to pay the strategy that there is acquisition session data;
The acquisition rule of S2015, API agent engine according to external transactions ID, confirms to obtain in the request for paying from API is called Take external transactions ID;
S2016, API agent engine obtain the session data of caching from data buffer storage according to external transactions ID for obtaining;
S2017, API agent engine get paid information and note check code from the session data of caching, to note school Test code to be verified;
If S2018, verifying successfully, session data tissue API Calls request of the API agent engine according to caching;
S2019, payment interface API for calling paying centre;
After S2020, payment interface API of paying centre complete actual operation of deducting fees, payment result is returned to into API generations Reason engine;
S2021, API agent engine return payment result to application program
S2022, application program represent payment result to terminal use.
In embodiment one, API agent is created in the handling process for paying in API, has cached session data, including note school Code is tested, and external transactions ID of session are returned to into client, client will be created from API and be propped up when calling API to confirm to pay In the response paid, external transactions ID that obtain and note check code issue API agent as call parameters, and API agent is according to receiving External transactions ID obtain the note check code of caching, by the note check code of caching and from the request for calling API confirmations to pay The note check code of acquisition compares, if identical, calls payment interface API of paying centre, completes to pay.In said process In, external transactions ID are returned to into client by creating in the handling process for paying in API, so that client is calling API Carry in confirming the request for paying, it is achieved thereby that the session association between API establishments payment and API confirm to pay.
Embodiment two
Embodiment two gives the handling process that a kind of API agent realizes that short message sending result is notified.As shown in figure 21, visitor The API in application call API agent on the end of family;API agent calls short message service center(That is API rear ends)On API realities Existing message sends, and the flow process comprises the steps:
S2101:The API that application call API agent is opened sends message;
S2102:API agent calls transmission message API of short message service center to send message.
S2103:The message for receiving is placed in message queue by short message service center;
S2104:Short message service center returns message id to API agent;
S2105:API agent creates session, using message id as external transactions ID, and sends answering for short message interface by calling Cached as session data with information such as the mark of program, message sender, message receiver, message contents;
S2106:API agent notifies that application program, message have been issued to short message service center;
S2107:Short message service center takes out message from message queue, is sent to message receiver;
S2108:The transmission result of message is informed API agent by short message service center, and which calls the API states in API agent Notify, message id is carried in the request for calling API state notifyings(The message id is identical with the message id in step S2104)With Status information;
S2109:API agent obtains the session data cached in S2105 steps according to the message id for receiving, from what is obtained The mark and message content of the program that is applied in session data, while finding returning for application program according to the mark of application program Adjust address.
S2110:The loopback address of application program of the API agent by finding, informs application program, the transmission knot of note Really.
In embodiment two, sent in the handling process of message in API by short message service center and message is sent to API agent Message id as external transactions ID of session, and is cached session data by ID, API agent, when API agent is called by short message service center API state notifyings when, the message id is carried in the request for call API so that before API agent can be obtained process When API sends message, the session data of caching, it is achieved thereby that the session that API is sent between message and API state notifyings is closed Connection.
By the method using embodiment two, compared with existing SMS sending method, it is capable of achieving notification message and sends Side, message send successfully.
The embodiment of the present invention additionally provides a kind of method of Dialog processing, API Calls equipment and second API agent, by There is provided in method provided in an embodiment of the present invention, the principle of API Calls equipment and API agent solve problem and the embodiment of the present invention Dialog processing system it is similar, its enforcement can refer to the enforcement of the system, repeats part and repeats no more.
Figure 24 is the procedure schematic diagram of the first Dialog processing provided in an embodiment of the present invention.As shown in figure 24, should Method includes:
S2401:API agent is received from the request for calling an API for calling the API Calls equipment of an API to send;
S2402:API agent performs the handling process of an API according to the request for calling an API, is performing an API Handling process in, cache the session data of the corresponding sessions of an API;
S2403:API agent is received from the request for calling the 2nd API for calling the API Calls equipment of the 2nd API to send;
S2404:API agent performs the handling process of the 2nd API according to the request for calling the 2nd API, is performing the 2nd API Handling process in, according to the external transactions for identifying the corresponding sessions of an API that the request for calling the 2nd API includes ID, obtains the session data of the session cached in the handling process for performing an API, according to the session data for obtaining to session Processed.
Alternatively, the method also includes:
API agent determines external transactions ID of the corresponding sessions of an API in the handling process for performing an API, and External transactions ID of determination are notified to the API Calls equipment for calling the 2nd API;Or receive from the API Calls for calling the 2nd API External transactions ID that equipment sends, and external transactions ID of reception are defined as external transactions ID of the corresponding sessions of an API;
API agent obtains the meeting that caches in the handling process for performing an API in the handling process for performing the 2nd API Before the session data of words, the outside thing of the corresponding sessions of an API that judgement is determined in the handling process for performing an API ID is consistent with external transactions ID for calling the request of the 2nd API to include for business.
Or, alternatively, the method also includes:
API agent determines external transactions ID of the corresponding sessions of an API in the handling process for performing an API, and External transactions ID of determination are notified to the API Calls equipment for calling the 2nd API;Or receive from the application for calling the 2nd API External transactions ID for going out, and external transactions ID of reception are defined as external transactions ID of the corresponding sessions of an API;
API agent perform an API handling process in, it is determined that external transactions ID of the corresponding sessions of an API Afterwards, according to the corresponding API suppliers of an API mark, the mark of the corresponding API rear ends of an API, and determine it is outer Portion's affairs ID, generate corresponding internal affairs ID, and record internal affairs ID and the session data of the session of caching of generation Corresponding relation;
API agent obtains the meeting that caches in the handling process for performing an API in the handling process for performing the 2nd API Mark, the mark of the corresponding API rear ends of the 2nd API before the session data of words, according to the corresponding API suppliers of the 2nd API And external transactions ID that the request of the 2nd API includes are called, corresponding internal affairs ID are generated, judges performing second Internal affairs ID generated in the handling process of API with perform an API handling process in generate internal affairs ID it is consistent.
Alternatively, the handling process of the first API of API agent execution includes:API agent is based on for describing at an API The expandable mark language XML file of reason flow process performs the handling process of an API;
Alternatively, the handling process of the 2nd API of API agent execution includes:API agent is based on for describing at the 2nd API The XML file of reason flow process performs the handling process of the 2nd API.
Figure 25 is the procedure schematic diagram of second Dialog processing provided in an embodiment of the present invention.As shown in figure 25, should Method includes:
S2501:In the handling process that API agent performs an API, API Calls equipment return from API agent the External transactions ID of the corresponding sessions of an API are obtained in the response of one API;Or API Calls equipment sends outside to API agent Affairs ID, so that external transactions ID for receiving to be defined as API agent external transactions ID of the corresponding sessions of an API;
S2502:API Calls equipment sends the request for calling the 2nd API to API agent, and request includes API correspondences Session external transactions ID so that external transactions ID of the API agent according to session, obtain API agent and performing at an API The session data of the session cached in reason flow process, and session is processed according to the session data of the session for obtaining.
Figure 26 is the structural representation of the 4th kind of API agent provided in an embodiment of the present invention.As shown in figure 26, the API generations Reason includes:
First processing module 2601, for receiving what is sent from the API Calls equipment for calling the first application programming interface API Call the request of an API;Request according to an API is called performs the handling process of an API, is performing an API's In handling process, the session data of the corresponding sessions of an API is cached;
Second processing module 2602, for receive from call the 2nd API call that equipment sends call the 2nd API please Ask;Request according to the 2nd API is called performs the handling process of the 2nd API, in the handling process for performing the 2nd API, according to The external transactions mark ID for identifying the corresponding sessions of an API for calling the request of the 2nd API to include, obtains at first The session data of the session that reason module 2601 is cached in the handling process for performing an API, according to the session data pair for obtaining Session is processed.
Alternatively, first processing module 2601 is additionally operable to:In the handling process for performing an API, the first API pair is determined External transactions ID of the session answered, and external transactions ID of determination are notified to the API Calls equipment for calling the 2nd API;Or connect Receive from external transactions ID for calling the API Calls equipment of the 2nd API to send, and external transactions ID of reception are defined as into first External transactions ID of the corresponding sessions of API;
Second processing module 2602 is additionally operable to:In the handling process for performing the 2nd API, first processing module 2601 is obtained Before the session data of the session cached in the handling process for performing an API, judge in the handling process for performing an API It is determined that the corresponding sessions of an API external transactions ID it is consistent with external transactions ID for calling the request of the 2nd API to include.
Or, alternatively, first processing module 2601 is additionally operable to:In the handling process for performing an API, first is determined External transactions ID of the corresponding sessions of API, and external transactions ID of determination are notified to the API Calls equipment for calling the 2nd API; Or receive from calling the 2nd API's to call external transactions ID that equipment sends, and external transactions ID of reception are defined as into first External transactions ID of the corresponding sessions of API;It is determined that after external transactions ID of the corresponding sessions of an API, according to an API The mark of corresponding API suppliers, the mark of the corresponding API rear ends of an API, and external transactions ID for determining, it is right to generate Internal affairs ID answered, and record internal affairs ID of generation and the corresponding relation of the session data of the session of caching;
Second processing module 2602 is additionally operable to:In the handling process for performing the 2nd API, first processing module 2601 is obtained Before the session data of the session cached in the handling process for performing an API, according to the corresponding API suppliers' of the 2nd API Mark, the mark of the corresponding API rear ends of the 2nd API and external transactions ID that the request of the 2nd API includes are called, it is right to generate Internal affairs ID answered, judge internal affairs ID and the first processing module generated in the handling process for performing the 2nd API 2601 internal affairs ID generated in the handling process for performing an API are consistent.
Alternatively, first processing module 2601 specifically for:Based on the expansible mark for the first API handling processes of description Note language XML document performs the handling process of an API;
Second processing module 2602 specifically for:Second is performed based on the XML file for describing the 2nd API handling processes The handling process of API.
Figure 27 is the structural representation of API Calls equipment provided in an embodiment of the present invention.As shown in figure 27, the API Calls Equipment includes:
First processing module 2701, for, in the handling process that API agent performs an API, returning from API agent An API response in obtain external transactions ID of the corresponding sessions of an API;Or external transactions ID are sent to API agent, So that external transactions ID for receiving to be defined as API agent external transactions ID of the corresponding sessions of an API;
Second processing module 2702, for the request for calling the 2nd API is sent to API agent, request includes an API External transactions ID of corresponding session, so that external transactions ID of the API agent according to session, obtain API agent and performing first The session data of the session cached in API handling processes, and session is processed according to the session data of the session for obtaining.
The embodiment of the present invention additionally provide a kind of method of generation API and perform API handling processes method, due to this two The method of kind is similar to the principle of the first API agent solve problem provided in an embodiment of the present invention, and its enforcement can refer to the first The enforcement of API agent, therefore repeat no more in place of repeating.
Figure 28 is a kind of procedure schematic diagram of generation API provided in an embodiment of the present invention.As shown in figure 28, the method Including:
S2801:API developers in API agent are received in graphical API development interfaces gives birth to for the API for generating API Into instruction;
S2802:API developers generate instruction generation for describing the handling process of the API according to the API for receiving API agent resource;
S2803:API developers are issued the API agent engine in API agent by the API agent resource for generating, so that , after the request for receiving the API Calls equipment calls API, being performed according to the request for calling the API for receiving should for API agent engine The handling process of the API in API agent resource.
Figure 29 is a kind of procedure schematic diagram of execution API handling processes provided in an embodiment of the present invention.Such as Figure 29 institutes Show, the method includes:
S2901:API agent engine in API agent receives the request for calling API that API Calls equipment sends;
S2902:API agent engine is performed and is provided for the API agent for describing the API according to the request for calling API for receiving The handling process of the API in source, wherein the API resources are API developers in API agent according to receiving for generating this The API of API generates instruction and generates and issue API agent engine;
S2903:Whether API agent engine has the operation of caching session data or obtains in judging the handling process of the API The operation of session data is taken, if having the operation of caching session data, execution step S2904, if there is the behaviour for obtaining session data Make, then execution step S2905;
S2904:API agent engine generates session data according to the request for calling the API, and the session data of generation is delayed It is stored in the data buffer storage in API agent;
S2905:API agent engine reads session data from data buffer storage according to the request for calling the API.In the art Technical staff it should be appreciated that embodiments of the invention can be provided as method, system or computer program.Therefore, the present invention Can using complete hardware embodiment, complete software embodiment or with reference to software and hardware in terms of embodiment in the form of.And, The present invention can be using the computer-usable storage medium for wherein including computer usable program code at one or more(Including But it is not limited to disk memory, CD-ROM, optical memory etc.)The form of the computer program of upper enforcement.
The present invention is with reference to method according to embodiments of the present invention, equipment(System), and computer program flow process Figure and/or block diagram are describing.It should be understood that can be by computer program instructions flowchart and/or each stream in block diagram The combination of journey and/or square frame and flow chart and/or flow process and/or square frame in block diagram.These computer programs can be provided The processor of general purpose computer, special-purpose computer, Embedded Processor or other programmable data processing devices is instructed to produce A raw machine so that produced for reality by the instruction of computer or the computing device of other programmable data processing devices The device of the function of specifying in present one flow process of flow chart or one square frame of multiple flow processs and/or block diagram or multiple square frames.
These computer program instructions may be alternatively stored in and can guide computer or other programmable data processing devices with spy Determine in the computer-readable memory that mode works so that the instruction being stored in the computer-readable memory is produced to be included referring to Make the manufacture of device, the command device realize in one flow process of flow chart or one square frame of multiple flow processs and/or block diagram or The function of specifying in multiple square frames.
These computer program instructions can be also loaded in computer or other programmable data processing devices so that in meter Series of operation steps is performed on calculation machine or other programmable devices to produce computer implemented process, so as in computer or The instruction performed on other programmable devices is provided for realizing in one flow process of flow chart or multiple flow processs and/or block diagram one The step of function of specifying in individual square frame or multiple square frames.
, but those skilled in the art once know basic creation although preferred embodiments of the present invention have been described Property concept, then can make other change and modification to these embodiments.So, claims are intended to be construed to include excellent Select embodiment and fall into the had altered of the scope of the invention and change.
Obviously, those skilled in the art can carry out the essence of various changes and modification without deviating from the present invention to the present invention God and scope.So, if these modifications of the present invention and modification belong to the scope of the claims in the present invention and its equivalent technologies Within, then the present invention is also intended to comprising these changes and modification.

Claims (17)

1. a kind of method of Dialog processing, it is characterised in that methods described includes:
API agent is received from the request for calling an API for calling the API Calls equipment of the first application programming interface API to send;
The API agent performs the handling process of an API according to the request for calling an API, in the process for performing an API In flow process, the session data of the corresponding sessions of an API is cached;
The API agent is received from the request for calling the 2nd API for calling the API Calls equipment of the 2nd API to send;
The API agent performs the handling process of the 2nd API according to the request for calling the 2nd API, in the process for performing the 2nd API In flow process, according to the external transactions mark for identifying the corresponding sessions of an API that the request for calling the 2nd API includes ID, obtains the session data of the session cached in the handling process for performing an API, according to the session number for obtaining According to processing to the session.
2. the method for claim 1, it is characterised in that methods described also includes:
The API agent determines external transactions ID of the corresponding sessions of an API in the handling process for performing an API, and External transactions ID of determination are notified to the API Calls equipment for calling the 2nd API;Or receive from the API Calls for calling the 2nd API External transactions ID that equipment sends, and external transactions ID of reception are defined as external transactions ID of the corresponding sessions of an API;
The API agent obtains the institute that caches in the handling process for performing an API in the handling process for performing the 2nd API Before stating the session data of session, outside the corresponding sessions of an API that judgement is determined in the handling process for performing an API Portion's affairs ID are consistent with external transactions ID for calling the request of the 2nd API to include.
3. the method for claim 1, it is characterised in that methods described also includes:
The API agent determines external transactions ID of the corresponding sessions of an API in the handling process for performing an API, and External transactions ID of determination are notified to the API Calls equipment for calling the 2nd API;Or receive from the application for calling the 2nd API External transactions ID for going out, and external transactions ID of reception are defined as external transactions ID of the corresponding sessions of an API;
The API agent perform an API handling process in, it is determined that external transactions ID of the corresponding sessions of an API Afterwards, according to the corresponding API suppliers of an API mark, the mark of the corresponding API rear ends of an API, and determine it is outer Portion's affairs ID, generate corresponding internal affairs ID, and record internal affairs ID of generation and the session number of the session of caching According to corresponding relation;
The API agent obtains the institute that caches in the handling process for performing an API in the handling process for performing the 2nd API Before stating the session data of session, the mark, the corresponding API rear ends of the 2nd API according to the corresponding API suppliers of the 2nd API Mark and external transactions ID that the request of the 2nd API includes are called, generate corresponding internal affairs ID, judge performing the Internal affairs ID generated in the handling process of two API and internal affairs ID generated in the handling process for performing an API Unanimously.
4. the method as described in any one of claims 1 to 3, it is characterised in that
The API agent performs the handling process of an API to be included:The API agent is based on for the first API processing streams of description The expandable mark language XML file of journey performs the handling process of an API;
The API agent performs the handling process of the 2nd API to be included:The API agent is based on for the 2nd API processing streams of description The XML file of journey performs the handling process of the 2nd API.
5. a kind of method of Dialog processing, it is characterised in that methods described includes:
In-service units interface API agent is performed in the handling process of an API, and API Calls equipment is returned from the API agent External transactions ID of the corresponding sessions of an API are obtained in the response of the API for returning;Or API Calls equipment is to the API generations External transactions ID are sent in haircut, so that external transactions ID for receiving are defined as the corresponding sessions of an API by the API agent External transactions ID;
The API Calls equipment sends the request for calling the 2nd API to the API agent, and the request includes described first External transactions ID of the corresponding sessions of API, so that external transactions ID of the API agent according to the session, obtain institute The session data of the session that API agent is cached in an API handling processes are performed is stated, and according to the session for obtaining Session data the session is processed.
6. a kind of Dialog processing device, it is characterised in that described device includes:
First processing module, calls first from what the API Calls equipment for calling the first application programming interface API sent for receiving The request of API;Request according to an API is called performs the handling process of an API, in the handling process for performing an API In, cache the session data of the corresponding sessions of an API;
Second processing module, for receiving from calling the 2nd API's to call the request for calling the 2nd API that equipment sends;According to The request of the 2nd API is called to perform the handling process of the 2nd API, in the handling process for performing the 2nd API, according to calling second The external transactions mark ID for identifying the corresponding sessions of an API that the request of API includes, obtains described first and processes mould The session data of the session that block is cached in the handling process for performing an API, according to the session data pair for obtaining The session is processed.
7. device as claimed in claim 6, it is characterised in that
The first processing module is additionally operable to:In the handling process for performing an API, the corresponding sessions of an API are determined External transactions ID, and external transactions ID of determination are notified to the API Calls equipment for calling the 2nd API;Or receive from calling the External transactions ID that the API Calls equipment of two API sends, and external transactions ID of reception are defined as into the corresponding meetings of an API External transactions ID of words;
The Second processing module is additionally operable to:In the handling process for performing the 2nd API, obtain the first processing module and perform Before the session data of the session cached in the handling process of the first API, judge in the handling process for performing an API It is determined that the corresponding sessions of an API external transactions ID it is consistent with external transactions ID for calling the request of the 2nd API to include.
8. device as claimed in claim 6, it is characterised in that
The first processing module is additionally operable to:In the handling process for performing an API, the corresponding sessions of an API are determined External transactions ID, and external transactions ID of determination are notified to the API Calls equipment for calling the 2nd API;Or receive from calling the External transactions ID that the API Calls equipment of two API sends, and external transactions ID of reception are defined as into the corresponding meetings of an API External transactions ID of words;It is determined that after external transactions ID of the corresponding sessions of an API, being carried according to the corresponding API of an API The mark of donor, the mark of the corresponding API rear ends of an API, and external transactions ID for determining, generate corresponding internal affairs ID, and record internal affairs ID of generation and the corresponding relation of the session data of the session of caching;
The Second processing module is additionally operable to:In the handling process for performing the 2nd API, obtain the first processing module and perform Before the session data of the session cached in the handling process of the first API, according to the corresponding API suppliers' of the 2nd API Mark, the mark of the corresponding API rear ends of the 2nd API and external transactions ID that the request of the 2nd API includes are called, it is right to generate Internal affairs ID answered, judge that internal affairs ID generated in the handling process for performing the 2nd API process mould with described first Internal affairs ID that block is generated in the handling process for performing an API are consistent.
9. the device as described in any one of claim 6~8, it is characterised in that
The first processing module specifically for:It is literary based on the expandable mark language XML for describing an API handling processes Part performs the handling process of an API;
The Second processing module specifically for:2nd API is performed based on the XML file for describing the 2nd API handling processes Handling process.
10. a kind of API Calls equipment, it is characterised in that the equipment includes:
First processing module, performs in the handling process of an API, from the API generations for in-service units interface API agent External transactions ID of the corresponding sessions of an API are obtained in the response of the API returned at reason;Or send out to the API agent External transactions ID are sent, so that external transactions ID for receiving are defined as the outer of the corresponding sessions of an API by the API agent Portion's affairs ID;
Second processing module, calls the request of the 2nd API for sending to the API agent, and the request includes described the External transactions ID of the corresponding sessions of one API, so that external transactions ID of the API agent according to the session, obtain The session data of the session that the API agent is cached in an API handling processes are performed, and according to the meeting for obtaining The session data of words is processed to the session.
11. a kind of system of Dialog processing, including application programming interface API agent and API Calls equipment, its feature exist In,
The API agent is used for:The request for calling an API according to receiving performs the handling process of an API, is performing the In the handling process of one API, the session data of the corresponding sessions of an API is cached;Receive according to from the API Calls equipment The request for calling the 2nd API perform the handling process of the 2nd API, in the handling process for performing the 2nd API, according to calling the The external transactions mark ID for identifying the corresponding sessions of an API that the request of two API includes, obtains and is performing first The session data of the session cached in the handling process of API, is carried out to the session according to the session data for obtaining Process;
The API Calls equipment is used for:The request for calling the 2nd API is sent to the API agent, the request includes first External transactions ID of the corresponding sessions of API.
12. systems as claimed in claim 11, it is characterised in that
The API agent is additionally operable to:In the handling process for performing an API, the outside thing of the corresponding sessions of an API is determined Business ID, and external transactions ID of determination are notified to the API Calls equipment;The API Calls equipment is additionally operable to:Described API agent is performed in the handling process of an API, receives external transactions ID of the session that the API agent is notified;Or
The API Calls equipment is additionally operable to:In the handling process that the API agent performs an API, external transactions ID are sent out To the API agent;The API agent is additionally operable to:External transactions ID that reception is sent from the API Calls equipment, and will connect External transactions ID of receipts are defined as external transactions ID of the corresponding sessions of an API;
The API agent is additionally operable to:In the handling process for performing the 2nd API, delay in obtaining the handling process for performing an API Before the session data of the session deposited, the corresponding meetings of an API determined in the handling process for performing an API are judged External transactions ID of words are consistent with external transactions ID for calling the request of the 2nd API to include.
13. systems as claimed in claim 11, it is characterised in that
The API agent is additionally operable to:In the handling process for performing an API, the outside thing of the corresponding sessions of an API is determined Business ID, and external transactions ID of determination are notified to the API Calls equipment;The API Calls equipment is additionally operable to:Described API agent is performed in the handling process of an API, receives external transactions ID of the session that the API agent is notified;Or
The API Calls equipment is additionally operable to:In the handling process that the API agent performs an API, external transactions ID are sent out To the API agent;The API agent is additionally operable to:External transactions ID that reception is sent from the API Calls equipment, and will connect External transactions ID of receipts are defined as external transactions ID of the corresponding sessions of an API;
The API agent is additionally operable to:In the handling process for performing an API, it is determined that the outside of the corresponding sessions of an API After affairs ID, the mark, the mark of the corresponding API rear ends of an API according to the corresponding API suppliers of an API, and really Fixed external transactions ID, generate corresponding internal affairs ID, and record internal affairs ID and the session of caching of generation The corresponding relation of session data;In the handling process for performing the 2nd API, cache in obtaining the handling process for performing an API The session session data before, after the mark, the corresponding API of the 2nd API according to the corresponding API suppliers of the 2nd API The mark at end and external transactions ID that the request of the 2nd API includes are called, generate corresponding internal affairs ID, judgement is being held Internal affairs ID generated in the handling process of the 2nd API of row and the inside thing generated in the handling process for performing an API ID is consistent for business.
14. systems as described in any one of claim 11~13, it is characterised in that the API agent specifically for:
The handling process of the first API is performed based on the expandable mark language XML file for describing an API handling processes;
The handling process of the 2nd API is performed based on the XML file for describing the 2nd API handling processes.
15. a kind of devices for generating application programming interface API, it is characterised in that described device includes:
API developers, for providing graphical API development interfaces, and receive for generating in the development interface for providing The API of API generates instruction;The API according to receiving generates the API that instruction generates the handling process for being used to describing the API Proxy resources;The API agent resource for generating is issued into API agent engine;
API agent engine, for preserving the API agent resource that the API developers for receiving send, and is receiving API After calling the request of API described in equipment calls, API described in the API agent resource is performed according to the request of the API is called Handling process;If there is the operation of caching session data in the handling process of the API, according to the request for calling the API Session data is generated, and the session data of generation is cached in data buffer storage;If there is acquisition meeting in the handling process of the API The operation of data is talked about, then basis calls the request of the API that session data is read from data buffer storage;
Data buffer storage, for caching the session data of API agent engine generation, and the session number that API agent engine is read According to being sent to API agent engine.
A kind of 16. methods for generating application programming interface API, it is characterised in that methods described includes:
API developers in API agent are received in graphical API development interfaces and generate instruction for the API for generating API;
The API developers generate the API that instruction generates the handling process for being used to describing the API according to the API for receiving Proxy resources;
The API developers are issued the API agent engine in the API agent by the API agent resource for generating, described API agent resource is used for:The API agent engine after the request of API described in API Calls equipment calls is received, according to reception The request for calling the API perform the handling process of API described in the API agent resource;Retouch in the API agent resource When having the operation of caching session data in the handling process of the API for stating, the API agent engine is according to calling the API Request generate session data, and the session data of generation is cached in the data buffer storage in the API agent;Described When having the operation of acquisition session data in the handling process of the API of API agent resource description, the API agent engine root Session data is read according to the request of the API is called from the data buffer storage.
A kind of 17. methods for performing application programming interface API handling process, it is characterised in that methods described includes:
API agent engine in API agent receives the request for calling API that API Calls equipment sends;
The API agent engine is performed and is provided for the API agent for describing the API according to the request for calling the API for receiving The handling process of API described in source, wherein the API resources are API developers being used for according to reception in the API agent The API generation instructions for generating the API are generated and issue the API agent engine;
If there is the operation of caching session data in the handling process of the API, the API agent engine is according to calling The request of API generates session data, and the session data of generation is cached in the data buffer storage in the API agent;If institute There is the operation for obtaining session data in the handling process for stating API, then the API agent engine is according to the request for calling the API Session data is read from the data buffer storage.
CN201310754454.3A 2013-12-31 2013-12-31 Conversation processing method, device and system Active CN103731427B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201310754454.3A CN103731427B (en) 2013-12-31 2013-12-31 Conversation processing method, device and system
PCT/CN2014/093469 WO2015101151A1 (en) 2013-12-31 2014-12-10 Session processing method, device and system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201310754454.3A CN103731427B (en) 2013-12-31 2013-12-31 Conversation processing method, device and system

Publications (2)

Publication Number Publication Date
CN103731427A CN103731427A (en) 2014-04-16
CN103731427B true CN103731427B (en) 2017-04-12

Family

ID=50455354

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201310754454.3A Active CN103731427B (en) 2013-12-31 2013-12-31 Conversation processing method, device and system

Country Status (2)

Country Link
CN (1) CN103731427B (en)
WO (1) WO2015101151A1 (en)

Families Citing this family (26)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103731427B (en) * 2013-12-31 2017-04-12 华为技术有限公司 Conversation processing method, device and system
CN104144221B (en) * 2014-08-19 2017-07-14 湖北盛天网络技术股份有限公司 file access method and device
US9146764B1 (en) 2014-09-30 2015-09-29 Amazon Technologies, Inc. Processing event messages for user requests to execute program code
US9678773B1 (en) 2014-09-30 2017-06-13 Amazon Technologies, Inc. Low latency computational capacity provisioning
US9600312B2 (en) 2014-09-30 2017-03-21 Amazon Technologies, Inc. Threading as a service
US9733967B2 (en) 2015-02-04 2017-08-15 Amazon Technologies, Inc. Security protocols for low latency execution of program code
US9588790B1 (en) 2015-02-04 2017-03-07 Amazon Technologies, Inc. Stateful virtual compute system
US9930103B2 (en) * 2015-04-08 2018-03-27 Amazon Technologies, Inc. Endpoint management system providing an application programming interface proxy service
CN106294452B (en) * 2015-05-28 2019-07-23 阿里巴巴集团控股有限公司 Data capture method and device
CN107231398A (en) * 2016-03-25 2017-10-03 阿里巴巴集团控股有限公司 Information interacting method and device
US10102040B2 (en) 2016-06-29 2018-10-16 Amazon Technologies, Inc Adjusting variable limit on concurrent code executions
KR102346620B1 (en) * 2017-07-11 2022-01-03 삼성전자 주식회사 Method and apparatus or discoverying network exposure function and configuring chaining
US10853115B2 (en) 2018-06-25 2020-12-01 Amazon Technologies, Inc. Execution of auxiliary functions in an on-demand network code execution system
US11099870B1 (en) 2018-07-25 2021-08-24 Amazon Technologies, Inc. Reducing execution times in an on-demand network code execution system using saved machine states
CN109582655B (en) * 2018-11-08 2021-01-08 深圳市云智融科技有限公司 Method and device for positioning system log and computer readable storage medium
US11943093B1 (en) 2018-11-20 2024-03-26 Amazon Technologies, Inc. Network connection recovery after virtual machine transition in an on-demand network code execution system
CN110209505B (en) * 2019-03-06 2024-06-25 腾讯科技(深圳)有限公司 Data request method and related equipment
US11861386B1 (en) 2019-03-22 2024-01-02 Amazon Technologies, Inc. Application gateways in an on-demand network code execution system
US11119809B1 (en) 2019-06-20 2021-09-14 Amazon Technologies, Inc. Virtualization-based transaction handling in an on-demand network code execution system
US11714682B1 (en) 2020-03-03 2023-08-01 Amazon Technologies, Inc. Reclaiming computing resources in an on-demand code execution system
US11593270B1 (en) 2020-11-25 2023-02-28 Amazon Technologies, Inc. Fast distributed caching using erasure coded object parts
US11550713B1 (en) 2020-11-25 2023-01-10 Amazon Technologies, Inc. Garbage collection in distributed systems using life cycled storage roots
CN113064987B (en) * 2021-04-30 2024-08-20 中国工商银行股份有限公司 Data processing method, apparatus, electronic device, medium, and program product
US11388210B1 (en) 2021-06-30 2022-07-12 Amazon Technologies, Inc. Streaming analytics using a serverless compute system
US11968280B1 (en) 2021-11-24 2024-04-23 Amazon Technologies, Inc. Controlling ingestion of streaming data to serverless function executions
US12015603B2 (en) 2021-12-10 2024-06-18 Amazon Technologies, Inc. Multi-tenant mode for serverless code execution

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101690073A (en) * 2007-07-04 2010-03-31 艾利森电话股份有限公司 Cross over the IP link establishment of data network
CN103475517A (en) * 2013-09-04 2013-12-25 青岛海信宽带多媒体技术有限公司 Optical network terminal equipment and hardware configuration parameter saving method thereof

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8203566B2 (en) * 2009-05-29 2012-06-19 Microsoft Corporation Fixed function pipeline application remoting through a shader pipeline conversion layer
CN103731427B (en) * 2013-12-31 2017-04-12 华为技术有限公司 Conversation processing method, device and system

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101690073A (en) * 2007-07-04 2010-03-31 艾利森电话股份有限公司 Cross over the IP link establishment of data network
CN103475517A (en) * 2013-09-04 2013-12-25 青岛海信宽带多媒体技术有限公司 Optical network terminal equipment and hardware configuration parameter saving method thereof

Also Published As

Publication number Publication date
WO2015101151A1 (en) 2015-07-09
CN103731427A (en) 2014-04-16

Similar Documents

Publication Publication Date Title
CN103731427B (en) Conversation processing method, device and system
CN112000348B (en) Control method, device and computer equipment for service gray level release
CN112771500B (en) Functional instant service gateway
US8516037B2 (en) Methods for dynamic partitioning of applications in client-server environments
CN108287839A (en) A kind of page loading method and equipment
US8078553B2 (en) Automatic translation of contracts to policies in policy-based networks
US8856800B2 (en) Service-level enterprise service bus load balancing
US20080271046A1 (en) Dynamically loading scripts
WO2017148278A1 (en) Service implementation method, apparatus and system based on fix protocol
US20220038367A1 (en) System and method of suppressing inbound payload to an integration flow of an orchestration based application integration
Boschi et al. RabbitMQ cookbook
CN114553960A (en) Data caching method, device, equipment and storage medium
Mohamed et al. Web services SOAP optimization techniques
US8224933B2 (en) Method and apparatus for case-based service composition
US20100153565A1 (en) Connection management in line-of-business
US20220198283A1 (en) Dynamic reconstruction of decision tree structures
CN113010561A (en) Data acquisition method and device based on super account book and computer system
CN115811481A (en) Interactive service testing method and device, computer equipment and storage medium
US20090199159A1 (en) Declarative execution context splitting
Banti et al. Specification and analysis of SOC systems using COWS: A finance case study
Benedictis et al. SLAs for cloud applications: agreement protocol and REST-based implementation
US20230088655A1 (en) Automatic non-code test suite generation from api specification
CN113626011B (en) PHP architecture-based data request processing method, device and equipment
Feuerlicht et al. Enterprise application management in cloud computing context
Brito et al. From a Desktop Application to a Web API A Code Conversion Approach

Legal Events

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