CN104270472B - A kind of remote service calling method, apparatus and system - Google Patents

A kind of remote service calling method, apparatus and system Download PDF

Info

Publication number
CN104270472B
CN104270472B CN201410579012.4A CN201410579012A CN104270472B CN 104270472 B CN104270472 B CN 104270472B CN 201410579012 A CN201410579012 A CN 201410579012A CN 104270472 B CN104270472 B CN 104270472B
Authority
CN
China
Prior art keywords
service
destination server
server
call
idle
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
CN201410579012.4A
Other languages
Chinese (zh)
Other versions
CN104270472A (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.)
HANGZHOU GOLDENSOFT SYSTEM Co Ltd
Original Assignee
HANGZHOU GOLDENSOFT SYSTEM 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 HANGZHOU GOLDENSOFT SYSTEM Co Ltd filed Critical HANGZHOU GOLDENSOFT SYSTEM Co Ltd
Priority to CN201410579012.4A priority Critical patent/CN104270472B/en
Publication of CN104270472A publication Critical patent/CN104270472A/en
Application granted granted Critical
Publication of CN104270472B publication Critical patent/CN104270472B/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/50Network services
    • H04L67/51Discovery or management thereof, e.g. service location protocol [SLP] or web services
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/54Interprogram communication
    • G06F9/547Remote procedure calls [RPC]; Web services

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computer And Data Communications (AREA)

Abstract

This application provides remote service calling method, apparatus and system, method and device can be applicable to client and server, client configures multiple connection pools, each connection pool is each corresponding with a server, when receiving the service invocation request of service calling module transmission, in multiple servers, it is determined that idle destination server, in the corresponding connection pool of destination server, obtain idle target length connection, when target length is connected as effective status, connected using target length, by service invocation request send to destination server, triggering destination server calls service corresponding with service invocation request, to obtain call result, and trigger destination server return call result, and send call result to service calling module.Compared with prior art, in the present invention, service calling module sends service invocation request to remote server, and any one server can be selected as request object, improves the stability and security of service call.

Description

A kind of remote service calling method, apparatus and system
Technical field
The present invention relates to software technology field, especially a kind of remote service calling method, apparatus and system.
Background technology
In software field, the development mode of application program is usually single operation pack mode, i.e., application development is given birth to Into code wrap at least one engineering source code bag, and all engineering source code bags must be transported in same running environment OK, same Database Systems and are used.
However, the above-mentioned unicity requirement to running environment and Database Systems so that a service of application program is adjusted With module when realizing function, local service implementation can only be called.That is, service calling module is realized with service Module must be integrated in same computer system, after the computer system goes wrong, to service calling module and clothes Pragmatic existing module produces influence, therefore, the less stable of service call and security is relatively low.
The content of the invention
In view of this, the invention provides a kind of remote service calling method, apparatus and system, to solve prior art The relatively low technical problem of the less stable and security of middle service call.To realize the purpose, the technology that the present invention is provided Scheme is as follows:
A kind of remote service calling method, applied to client, the client is configured with multiple connection pools, each described Connection pool is each corresponding with a server, and methods described includes:
When receiving the service invocation request of service calling module transmission, in multiple servers, it is determined that idle Destination server;
In the corresponding connection pool of the destination server, idle target length connection is obtained;
When the target length is connected as effective status, is connected using the target length, the service invocation request is sent out Deliver to the destination server, trigger the destination server and call service corresponding with the service invocation request, to obtain Call result is obtained, and triggers the destination server and returns to the call result;
The call result is sent to the service calling module.
Above-mentioned remote service calling method, it is preferable that described in multiple servers, it is determined that idle target clothes Business device, including:
Using polling algorithm, in multiple servers, it is determined that idle destination server.
Above-mentioned remote service calling method, it is preferable that described in multiple servers, it is determined that idle target clothes Business device, including:
In the first storehouse pre-set, it is determined that idle destination server;Wherein, include in first storehouse Multiple destination servers.
Above-mentioned remote service calling method, it is preferable that in the corresponding connection pool of the destination server, obtains idle Target length connection after, methods described also includes:
When the target length is connected as abnormality, the destination server is moved to what is pre-set from the first storehouse In second storehouse;
When any one length in destination server correspondence connection pool is connected as effective status, by the destination service Device moves to first storehouse from second storehouse.
Above-mentioned remote service calling method, it is preferable that described in the corresponding connection pool of the destination server, is obtained Idle target length connection, including:
Using polling algorithm, in the corresponding connection pool of the destination server, idle target length connection is obtained.
Above-mentioned remote service calling method, it is preferable that send the call result to the application program described Before, in addition to:
When receiving the call result that the destination server is returned, the long Connection Release of the target is gone back into corresponding company Connect pond.
Present invention also offers a kind of remote service calling method, applied to server, methods described includes:
When receiving the service invocation request of client transmission, extract service name in the service invocation request and Call parameters;
According to the service name and call parameters, the corresponding service of the service request is called, to obtain call result.
Present invention also offers a kind of remote service calling device, applied to client, the client is configured with multiple Connection pool, each connection pool is each corresponding with a server, and described device includes:
Destination server determining unit, for when receiving the service invocation request of service calling module transmission, many In the individual server, it is determined that idle destination server;
Target length connects acquiring unit, in the corresponding connection pool of the destination server, obtaining idle target Long connection;
Destination service call unit, for when the target length is connected as effective status, being connected using the target length, By the service invocation request send to the destination server, trigger the destination server and call and the service call The corresponding service of request, the call result is returned to obtain call result, and trigger the destination server;
Call result returning unit, for the call result to be sent to the service calling module.
Present invention also offers a kind of remote service calling device, applied to server, methods described includes:
Name parameter extraction unit, for when receiving the service invocation request of client transmission, extracting the service Service name and call parameters in call request;
Destination service call unit, for according to the service name and call parameters, calling the service request correspondence Service, to obtain call result.
Present invention also offers a kind of remote service calling system, including above-mentioned the remote service in client is applied to call Device and apply in Server remote service call device.
Remote service calling method, the apparatus and system provided from above technical scheme, the present invention, method and device It can apply respectively in client and server, client is configured with multiple connection pools, each connection pool each takes with one Business device correspondence, when receiving the service invocation request of service calling module transmission, in multiple servers, it is determined that idle mesh Server is marked, in the corresponding connection pool of destination server, idle target length connection is obtained, when target length is connected as effective shape During state, using target length connect, by service invocation request send to destination server, triggering destination server call and service The corresponding service of call request, returns to call result, and call result is sent out to obtain call result, and trigger destination server Deliver to service calling module.Compared with prior art, in the present invention, service calling module sends service call to remote server Request, and any one server can be selected as request object, improve the stability and security of service call.
Brief description of the drawings
In order to illustrate more clearly about the embodiment of the present invention or technical scheme of the prior art, below will be to embodiment or existing There is the accompanying drawing used required in technology description to be briefly described, it should be apparent that, drawings in the following description are only this The embodiment of invention, for those of ordinary skill in the art, on the premise of not paying creative work, can also basis The accompanying drawing of offer obtains other accompanying drawings.
Fig. 1 is the flow chart provided in an embodiment of the present invention applied in the remote service calling method of client;
Fig. 2 is another flow chart provided in an embodiment of the present invention applied in the remote service calling method of client;
Fig. 3 is the another flow chart provided in an embodiment of the present invention applied in the remote service calling method of client;
Fig. 4 is the another flow chart provided in an embodiment of the present invention applied in the remote service calling method of server;
Fig. 5 is the structured flowchart provided in an embodiment of the present invention applied in the remote service calling device of client;
Fig. 6 is the structured flowchart provided in an embodiment of the present invention applied in the remote service calling device of server.
Embodiment
Below in conjunction with the accompanying drawing in the embodiment of the present invention, the technical scheme in the embodiment of the present invention is carried out clear, complete Site preparation is described, it is clear that described embodiment is only a part of embodiment of the invention, rather than whole embodiments.It is based on Embodiment in the present invention, it is every other that those of ordinary skill in the art are obtained under the premise of creative work is not made Embodiment, belongs to the scope of protection of the invention.
The remote service calling method that the present invention is provided is applied in client, and client is configured with multiple connection pools, each Connection pool is each corresponding with a server.It is to be appreciated that the present invention is provided with multiple servers, each server can be achieved The call request of service calling module.That is, being backuped each other between multiple servers, the negative of service invocation request is realized Carry balanced.Compared to the call request of application program is realized into module is integrated in for a computer in the prior art, this reality The stability and security of service call can be improved by applying example.
The system architecture of client and multiple servers based on above-mentioned offer, the embodiments of the invention provide a kind of long-range Service calling method.Referring to Fig. 1, it illustrates the flow of this method, the flow is specifically included:
Step S101:When receiving the service invocation request of service calling module transmission, in multiple servers, It is determined that idle destination server.
Wherein, service calling module is a module in client application, when the module needs to call long-range clothes During module of being engaged in, service invocation request is generated, wherein, the title and ginseng of the service in need called are included in service invocation request Number.Service invocation request is sent to the executive agent of this method, asked when the executive agent of this method receives the service call , it is necessary in multiple servers of setting, search a server for being currently at idle condition, be defined as destination service when asking Device.
Step S102:In the corresponding connection pool of the destination server, idle target length connection is obtained.
Wherein, client is provided with multiple connection pools, each server is corresponding with a connection pool.And each connection Initialization has multiple long connections in pond.It is determined that the corresponding connection pool of destination server in, search one be currently at sky The long connection of not busy state, for sending service invocation request to the destination server.It is to be appreciated that idle long connection, refers to It is that length connection does not take transmission service invocation request by other arbitrary service calling modules.
Step S103:When the target length is connected as effective status, connected using the target length, the service is adjusted With request send to the destination server, trigger the destination server and call clothes corresponding with the service invocation request Business, the call result is returned to obtain call result, and trigger the destination server.
Wherein, if network or server break down, target length can be caused to be connected to become down state.In order to improve The success rate of service invocation request, before service invocation request is sent, it is thus necessary to determine that whether long connection is in effective status.When When the connection of target length is in effective status, connected using the target length, send service invocation request.Specifically, detection target is long Whether the method in effective status can be for connection, connected using the target length to destination server and send detection packet, Assuming that receiving the reply of destination server, determine that target length connection is in effective status.
In the present embodiment, exist before service invocation request is sent, it is necessary to which service invocation request is carried out into serializing post package In packet, then using the connection of target length, the packet is sent to destination server.Service is provided with destination server Component is held, after the service end component of destination server receives service invocation request, service invocation procedure is realized, is serviced Call result.
Specifically, the packet after above-mentioned serializing is carried out unserializing processing by destination server, is obtained needs and is called Service title and parameter, find corresponding service execution module according to the service name, trigger the service execution module Service call is performed, call result is obtained, the present embodiment is back to by long connection after the call result is serialized Executive agent.
Step S104:The call result is sent to the service calling module.
Wherein, the executive agent of the present embodiment is received after the call result, and call result is carried out after unserializing, hair The service calling module for sending service invocation request is delivered to, service invocation procedure is completed.
Technical scheme more than, the remote service calling method that this implementation is provided, is applied in client, client Multiple connection pools are provided with, each connection pool is corresponding with a server, multiple servers of setting can complete service and adjust With process, therefore, before service invocation request is sent, an idle server can be determined in multiple servers of setting. Compared with only a mode to realize service call is set in the prior art, the set-up mode enhancing of multiple server backups The stability and security of service call.
Meanwhile, initialization has multiple long connections in connection pool, is sent service invocation request to determining using long connection Destination server.However, in the prior art, the connection with destination server is realized using short connection.If using short connection, Client is needed to send before service invocation request to server every time, is required to create short connection, and service call is completed every time Afterwards, it is necessary to close short connection.So, short connection is created every time to be both needed to expend system resource, overhead is larger, also, can make Into the delay of service call.The present embodiment client carries out data interaction using long connection and server, because long connection is to begin The connection communicated is kept with server eventually, unless server end disconnects the connection for various reasons, therefore, client passes through wound Build vice-minister connection, you can repeatedly send service invocation request using length connection, overhead is smaller, and service call efficiency It is higher.
In the prior art, client have services cache function, i.e. client can by service execution module (or be referred to as Service implementation) memory address to be buffered in client local, when client receives the service call of service calling module After request, first in the local memory address for searching service, and the memory address found is included in the service call generated In request, server is sent to, the server direct basis memory address determines position of the service execution module in internal memory, entered And trigger service execution module and realize service invocation procedure.However, services cache method of the prior art, in the clothes of server After the memory address of business performing module is changed, the invalid of service invocation request can be caused, and then cause the mistake of service call Lose.
Unlike, in the present embodiment, service name and service parameter are only included in the service invocation request received, Do not include the memory address of service execution module, but the service invocation request is sent to server, server foundation The service name and the corresponding relation of the memory address of service execution module pre-set, it is determined that needing the service name pair called The memory address for the service execution module answered.After being changed due to the memory address of service execution module, server can be therewith Change the corresponding relation of memory address and service name, therefore, the remote service calling method that the present embodiment is provided be it is dynamic, That is, being not rely on the memory address for being stored in advance in local service execution module, and then existing skill can be avoided Service call failure scenario caused by the memory address of service execution module is prestored in art.
It is to be appreciated that in the above-described embodiments, the concrete mode that client configures multiple servers, which is that record is each, to be serviced The port numbers of the IP address of device and each server process service invocation request.In addition, server is provided with service execution module, Server calls service execution module obtains service call result to realize service invocation request.Service execution module is in service Address in device internal memory needs to be registered in server operating component, and registration process is by the title of service and service execution mould The memory address of block sets up corresponding relation, so, and server is received after service invocation request, according in service invocation request Service name and the corresponding relation of foundation, it may be determined that the memory address of service execution module, and then find service execution mould The core position of block, realizes service invocation procedure.
Alternatively, the step S101 in above-described embodiment is in multiple servers, it is determined that idle destination server Specific implementation can be:Using polling algorithm, in multiple servers, it is determined that idle destination server.
Specifically, polling algorithm refers to judging whether each destination server is in idle condition successively.Assuming that multiple The mark of server is stored in queue, is obtained first server identification from row are first, is judged the corresponding service of the server identification Whether device is in idle condition, if so, the corresponding server of server identification that this gets then is defined as destination server, Otherwise, the server identification got is put into the tail of the queue of queue, next server identification is obtained from head of the queue successively, repetition is obtained The step of taking, until getting the server of free time.If the corresponding server of whole server identifications preserved in queue is not In idle condition, the service invocation request is set to wait for whether leisure service occur in state, and real-time judge queue Device, when occur in queue free time server after, will the idle server be defined as destination server.
Certainly, the mode that the present invention does not limit determination idle server is to utilize polling algorithm, can also utilize weight Algorithm, that is, pre-set the weighted value of each server, will be currently at the maximum clothes of weighted value in the server of idle condition Business device is defined as destination server.
Fig. 2 is referred to, it illustrates another flow of remote service calling method provided in an embodiment of the present invention.It is optional Ground, the mark of destination server device can be stored in storehouse, therefore, and step S101 is in multiple servers, it is determined that empty The specific implementation of not busy destination server can be step S201:When the service call for receiving service calling module transmission During request, in the first storehouse pre-set, it is determined that idle destination server;Wherein, include in first storehouse Multiple destination servers.
In addition, understanding in the above description, the connection of target length is likely to occur abnormality, now shows that client can not It is normally carried out communicating with destination server, therefore, sees Fig. 2, on the basis of the remote service calling method that above-described embodiment is provided, It can also include:
Step S205:When the target length is connected as abnormality, the destination server is moved to from the first storehouse In the second storehouse pre-set.
In the present embodiment, two storehouses are previously provided with, the first storehouse is used to store the normal server of connection, the second heap Stack is used to store the abnormal server of connection.Therefore, when target length is connected as abnormality, it is necessary to which target length is connected into correspondence Server be that destination server is moved to from the first storehouse in the second storehouse, thereby may be ensured that determined in the first storehouse it is empty During not busy server, it is ensured that the idle server determined is the normal idle server of connection, and then improves service call mistake The accuracy of journey.
Step S206:When any one length in destination server correspondence connection pool is connected as effective status, by institute State destination server and move to first storehouse from second storehouse.
Wherein, when the state for occurring any one long connection in destination server correspondence connection pool is effective status, show The connection of client and destination server is changed into normal condition again, therefore, and the mesh server is placed back in the first storehouse In, it is ensured that it can be by normal call.
It is to be appreciated that when the target length is connected as abnormality, the connection for showing the destination server it is abnormal, it is necessary to New destination server is determined for service invocation request, i.e., after step S205, can also be included:Return to step S201 In the first storehouse pre-set, it is determined that idle destination server.As can be seen that being mutual between the multiple servers set For redundancy, the server of failure can't influence the realization of client service call request.
Alternatively, in each above-mentioned embodiment of the method in the corresponding connection pool of the destination server, the free time is obtained What target length was connected, which implements process, to be:Using polling algorithm, in the corresponding connection pool of the destination server, obtain Take the target length connection of free time.
Specifically, the process of polling algorithm is to judge whether multiple long connections in connection pool are in idle condition successively. An alternative long connection in connection pool is obtained, judges whether the alternative long connection is in idle condition, if so, then that this is standby Select long connection to be defined as the connection of target length, otherwise, obtain next alternative long connection in connection pool, repeat above-mentioned deterministic process, Until determining that target length is connected.And then, obtain the transmission that the target length connection determined carries out service invocation request.
Certainly, obtain the mode of target length connection, can also any one mode in the prior art, the present invention do not limit It is fixed.
, it is necessary to initialize connection pool in each above-mentioned inventive embodiments.Connection pool is initialized, is to be set up in connection pool Long connection.Wherein, initializing the quantity of long connection can pre-set.When all long connections in connection pool are in using shape During state, new long connection can be created at any time, the new length connection of establishment is defined as the connection of target length.
Referring to Fig. 3, it illustrates the another flow of remote service calling method provided in an embodiment of the present invention, in above-mentioned side Before the step S104 (the step S305 i.e. in this implementation) of method embodiment, it can also include:
Step S304:When receiving the call result that the destination server is returned, by the long Connection Release of the target Return corresponding connection pool.
Wherein, destination server is returned to call result using the connection of target length, therefore, is returned when receiving destination server During the call result returned, illustrate that target length connection is changed into idle condition.And then, the long Connection Release of the target is gone back into corresponding company Connect pond, will the target length be connected to correspondence connection pool in state be set to the free time, so that other service invocation requests make With.
Above-mentioned each of correspondence applies remote service calling method in client, and referring to Fig. 4, the invention provides a kind of remote Journey service calling method, is applied in server, this method includes:
Step S401:When receiving the service invocation request of client transmission, extract in the service invocation request Service name and call parameters.
In the present embodiment, using remote service calling method on the server, and service need not be returned to client Memory address, be the memory address of service execution module more particularly.Therefore, client and buffer service is not needed Memory address, sends before service invocation request, is also not required to know in advance the memory address of service, therefore, in service invocation request The memory address of service execution module is not included.
Step S402:According to the service name and call parameters, the corresponding service of the service request is called, to obtain Call result.
Wherein, the executive agent of the present embodiment sends call request to service execution module, to call the service execution mould Block, makes the service calling module realize service call, obtains service call result.
Compared with prior art, the present embodiment and need not to client send service execution module memory address, when Receive after service invocation request, the memory address of direct basis service execution module and the corresponding relation of service name, it is determined that Service execution module is called, and call parameters are sent to the service calling module triggering service call can be achieved.The service The situation that the service call that call method can avoid address of service from occurring after changing fails.
The embodiment of the method that the above-mentioned Fig. 1 of correspondence is provided, dress is called the invention provides the remote service in client is applied Put.The explanation that may refer to above method embodiment is illustrated, is not repeated hereafter.Referring to Fig. 5, the remote service calls dress Put and specifically include:
Destination server determining unit 101, for when receive service calling module transmission service invocation request when, In multiple servers, it is determined that idle destination server;
Target length connects acquiring unit 102, in the corresponding connection pool of the destination server, obtaining idle mesh The long connection of mark;
Destination service call unit 103, for when the target length is connected as effective status, being connected using the target length Connect, by the service invocation request send to the destination server, trigger the destination server and call and the service The corresponding service of call request, the call result is returned to obtain call result, and trigger the destination server;
Call result returning unit 104, for the call result to be sent to the service calling module.
It is to be appreciated that the service call device is arranged on client, it is believed that be client component.The client component Service invocation request can be sent in any one idle server in multiple servers, realize the load of service call It is balanced.Meanwhile, service invocation request is sent using long interconnection technique, the next overhead of short connect band can be saved and the time prolongs Late.
The embodiment of the method that the above-mentioned Fig. 4 of correspondence is provided, dress is called the invention provides the remote service in server is applied Put.The explanation that may refer to above method embodiment is illustrated, is not repeated hereafter.Referring to Fig. 6, the remote service calls dress Put and specifically include:
Name parameter extraction unit 201, for when receiving the service invocation request of client transmission, extracting the clothes Service name and call parameters in call request of being engaged in;
Destination service call unit 202, for according to the service name and call parameters, calling the service request pair The service answered, to obtain call result.
It is to be appreciated that the service call device is arranged on server, it is believed that be service end component.
Present invention also offers a kind of remote service calling system, including the remote service calling device that above-mentioned Fig. 5 is provided And the remote service calling device that Fig. 6 is provided.The system can be realized is sent to server by the service invocation request of client, Call result is back to client after server calls service, remote service invoked procedure is realized.
It should be noted that each embodiment in this specification is described by the way of progressive, each embodiment weight Point explanation be all between difference with other embodiment, each embodiment identical similar part mutually referring to.
The foregoing description of the disclosed embodiments, enables professional and technical personnel in the field to realize or using the present invention. A variety of modifications to these embodiments will be apparent for those skilled in the art, as defined herein General Principle can be realized in other embodiments without departing from the spirit or scope of the present invention.Therefore, it is of the invention The embodiments shown herein is not intended to be limited to, and is to fit to and principles disclosed herein and features of novelty phase one The most wide scope caused.

Claims (8)

1. a kind of remote service calling method, it is characterised in that applied to client, the client is configured with multiple connections Pond, each connection pool is each corresponding with a server, and methods described includes:
When receiving the service invocation request of service calling module transmission, in multiple servers, it is determined that idle mesh Mark server;
In the corresponding connection pool of the destination server, idle target length connection is obtained;
When the target length is connected as effective status, using the target length connect, by the service invocation request send to With the destination server, trigger the destination server and call service corresponding with the service invocation request, to be adjusted With result, and trigger the destination server and return to the call result;
The call result is sent to the service calling module.
2. remote service calling method according to claim 1, it is characterised in that described in multiple servers, It is determined that idle destination server, including:
Using polling algorithm, in multiple servers, it is determined that idle destination server.
3. remote service calling method according to claim 1, it is characterised in that described in multiple servers, It is determined that idle destination server, including:
In the first storehouse pre-set, it is determined that idle destination server;Wherein, include multiple in first storehouse Destination server.
4. remote service calling method according to claim 3, it is characterised in that in the corresponding company of the destination server Connect in pond, obtain after idle target length connection, methods described also includes:
When the target length is connected as abnormality, the destination server is moved to second pre-set from the first storehouse In storehouse;
When the destination server correspondence connection pool in any one length be connected as effective status when, by the destination server from Second storehouse moves to first storehouse.
5. remote service calling method according to claim 1, it is characterised in that described in destination server correspondence Connection pool in, obtain idle target length connection, including:
Using polling algorithm, in the corresponding connection pool of the destination server, idle target length connection is obtained.
6. the remote service calling method according to claim 1 or 4, it is characterised in that described by the call result Send to before the application program, in addition to:
When receiving the call result that the destination server is returned, the long Connection Release of the target is returned into corresponding connection Pond.
7. a kind of remote service calling device, it is characterised in that applied to client, the client is configured with multiple connections Pond, each connection pool is each corresponding with a server, and described device includes:
Destination server determining unit, for when receiving the service invocation request of service calling module transmission, in multiple institutes State in server, it is determined that idle destination server;
Target length connects acquiring unit, connects in the corresponding connection pool of the destination server, obtaining idle target length Connect;
Destination service call unit, for when the target length is connected as effective status, being connected using the target length, by institute State service invocation request send to the destination server, trigger the destination server and call and the service invocation request Corresponding service, the call result is returned to obtain call result, and trigger the destination server;
Call result returning unit, for the call result to be sent to the service calling module.
8. a kind of remote service calling system, it is characterised in that including remote service calling device as claimed in claim 7.
CN201410579012.4A 2014-10-24 2014-10-24 A kind of remote service calling method, apparatus and system Active CN104270472B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201410579012.4A CN104270472B (en) 2014-10-24 2014-10-24 A kind of remote service calling method, apparatus and system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410579012.4A CN104270472B (en) 2014-10-24 2014-10-24 A kind of remote service calling method, apparatus and system

Publications (2)

Publication Number Publication Date
CN104270472A CN104270472A (en) 2015-01-07
CN104270472B true CN104270472B (en) 2017-11-07

Family

ID=52161961

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410579012.4A Active CN104270472B (en) 2014-10-24 2014-10-24 A kind of remote service calling method, apparatus and system

Country Status (1)

Country Link
CN (1) CN104270472B (en)

Families Citing this family (17)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106034138B (en) * 2015-03-09 2019-08-09 阿里巴巴集团控股有限公司 A kind of remote service calling method and device
CN104780224A (en) * 2015-04-30 2015-07-15 北京奇艺世纪科技有限公司 Remote service calling method and device
CN105391683A (en) * 2015-09-30 2016-03-09 小米科技有限责任公司 Remote method invocation method, device and system
CN105915575A (en) * 2015-12-15 2016-08-31 乐视网信息技术(北京)股份有限公司 Service calling method and equipment
CN106998343B (en) * 2016-01-26 2020-11-03 创新先进技术有限公司 Remote procedure call processing method, device and system
CN107104999B (en) * 2016-02-23 2021-05-25 北京京东尚科信息技术有限公司 Method and device for processing service interface call request
CN106254464A (en) * 2016-08-07 2016-12-21 深圳市小马立行科技有限公司 A kind of vehicle intelligent terminal and network communication method thereof
CN108111431B (en) * 2016-11-24 2021-09-24 腾讯科技(北京)有限公司 Service data sending method, device, computing equipment and computer readable storage medium
CN108234304A (en) * 2017-12-29 2018-06-29 生迪智慧科技有限公司 Data transmission method, apparatus and system
CN109753370A (en) * 2018-12-28 2019-05-14 北京东方国信科技股份有限公司 A kind of low time delay, the high remote procedure calling (PRC) method handled up
CN110119314B (en) * 2019-05-14 2024-06-07 腾讯科技(深圳)有限公司 Server calling method and device, server and storage medium
CN110401659B (en) * 2019-07-25 2021-11-05 高新兴科技集团股份有限公司 Equipment access method, equipment access device and system of service system
CN110535959B (en) * 2019-08-30 2023-02-24 北京云中融信网络科技有限公司 Method and device for transmitting data and computer readable storage medium
CN111225242A (en) * 2020-01-17 2020-06-02 广州酷狗计算机科技有限公司 Video playing disaster tolerance method and device and computer storage medium
CN111770157B (en) * 2020-06-24 2023-04-18 广东浪潮大数据研究有限公司 Business processing method and device, electronic equipment and storage medium
CN112698970B (en) * 2020-12-31 2024-07-12 北京千方科技股份有限公司 Service calling method and device for micro-service architecture and computer storage medium
CN113489803A (en) * 2021-07-15 2021-10-08 深圳竹云科技有限公司 Load balancing method, terminal and gateway server

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2001093038A2 (en) * 2000-05-30 2001-12-06 Compaq Computer Corporation Scalable java servers for network server applications
CN1968283A (en) * 2006-05-12 2007-05-23 华为技术有限公司 Network management system and method
CN101127655A (en) * 2006-08-18 2008-02-20 国际商业机器公司 Method and system for integrating existing www systems
CN101645785A (en) * 2009-04-30 2010-02-10 中国科学院声学研究所 Data-intensive multimedia service calling method based on extended SOAP
CN101719097A (en) * 2009-12-24 2010-06-02 深圳市金蝶移动互联技术有限公司 Debug method and system of automation test script and automation application server
CN101923485A (en) * 2009-06-17 2010-12-22 大唐软件技术股份有限公司 JACA remote invocation method in CORBA (Common Object Request Breaker Architecture) system
CN103634298A (en) * 2013-11-14 2014-03-12 北京奇虎科技有限公司 Database connection processing method and device

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2001093038A2 (en) * 2000-05-30 2001-12-06 Compaq Computer Corporation Scalable java servers for network server applications
CN1968283A (en) * 2006-05-12 2007-05-23 华为技术有限公司 Network management system and method
CN101127655A (en) * 2006-08-18 2008-02-20 国际商业机器公司 Method and system for integrating existing www systems
CN101645785A (en) * 2009-04-30 2010-02-10 中国科学院声学研究所 Data-intensive multimedia service calling method based on extended SOAP
CN101923485A (en) * 2009-06-17 2010-12-22 大唐软件技术股份有限公司 JACA remote invocation method in CORBA (Common Object Request Breaker Architecture) system
CN101719097A (en) * 2009-12-24 2010-06-02 深圳市金蝶移动互联技术有限公司 Debug method and system of automation test script and automation application server
CN103634298A (en) * 2013-11-14 2014-03-12 北京奇虎科技有限公司 Database connection processing method and device

Also Published As

Publication number Publication date
CN104270472A (en) 2015-01-07

Similar Documents

Publication Publication Date Title
CN104270472B (en) A kind of remote service calling method, apparatus and system
CN110046896B (en) Block processing method, node and system
CN105553993B (en) A kind of remote service calling method, device and server
CN103716356B (en) Storing process operating method, device and system based on web
CN111490963B (en) Data processing method, system, equipment and storage medium based on QUIC protocol stack
CN105635083A (en) Service processing method and service processing system based on server and client architecture
CN105282128A (en) Bidirectional calling method and system based on long connection
US9781168B2 (en) Systems and methods of distributed silo signaling
CN112152872B (en) Network sub-health detection method and device
CN109491895A (en) Server stress test method and device
TWI429232B (en) Backup server, system and method for recovering client devices register at primary server
CN109040255A (en) Internet of things equipment cut-in method, device, equipment and storage medium
CN101873235A (en) Detection method of equipment network link, network management system and network system
CN101459694A (en) Highly available message transmission frame and method oriented to distributed file system
EP2445171B1 (en) File transfer protocol client and implementing method thereof
CN111835797A (en) Data processing method, device and equipment
CN108718398A (en) Code stream transmission method, device and the conference facility of video conferencing system
CN112448978B (en) Data management method and system
CN101895528A (en) System and method for realizing graphical user interface
CN103441894A (en) Method and system for L2TP concurrent connection performance test
CN109218371B (en) Method and equipment for calling data
CN103560901B (en) A kind of mobile terminal management system and management method
US20180183861A1 (en) Internet-of-things transaction resoruce with finite state automata
CN103944875A (en) Data exchanging method and data exchanging system
CN113010337A (en) Fault detection method, master control node, working node and distributed system

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