CN110247944B - Cross-regional service calling method, device and system and electronic equipment - Google Patents

Cross-regional service calling method, device and system and electronic equipment Download PDF

Info

Publication number
CN110247944B
CN110247944B CN201810195626.0A CN201810195626A CN110247944B CN 110247944 B CN110247944 B CN 110247944B CN 201810195626 A CN201810195626 A CN 201810195626A CN 110247944 B CN110247944 B CN 110247944B
Authority
CN
China
Prior art keywords
service
cross
regional
metadata
region
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
CN201810195626.0A
Other languages
Chinese (zh)
Other versions
CN110247944A (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.)
Alibaba Group Holding Ltd
Original Assignee
Alibaba Group Holding 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 Alibaba Group Holding Ltd filed Critical Alibaba Group Holding Ltd
Priority to CN201810195626.0A priority Critical patent/CN110247944B/en
Publication of CN110247944A publication Critical patent/CN110247944A/en
Application granted granted Critical
Publication of CN110247944B publication Critical patent/CN110247944B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

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/01Protocols
    • H04L67/06Protocols specially adapted for file transfer, e.g. file transfer protocol [FTP]
    • 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
    • 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/60Scheduling or organising the servicing of application requests, e.g. requests for application data transmissions using the analysis and optimisation of the required network resources
    • 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/60Scheduling or organising the servicing of application requests, e.g. requests for application data transmissions using the analysis and optimisation of the required network resources
    • H04L67/63Routing a service request depending on the request content or context

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

The embodiment of the invention provides a cross-regional service calling method, a device, a system and electronic equipment, wherein the system comprises a cross-regional proxy module and a registration center, the registration center is used for storing first service metadata of a service provider in a region and second service metadata of the cross-regional proxy module, receiving a cross-regional service calling inquiry request of a service consumer in the region and providing the second service metadata of the cross-regional proxy module; the cross-region agent module is used for receiving a cross-region service call request of a service consumer in the region and initiating service call to service providers in other regions. According to the embodiment of the invention, the cross-regional agent module is added in the region, so that the service consumer in the region transfers the cross-regional service call request to the cross-regional agent module for uniform processing, thereby reducing the cross-regional connection quantity between the service consumer and the service provider in other regions and reducing the metadata storage pressure of the registration center.

Description

Cross-regional service calling method, device and system and electronic equipment
Technical Field
The present invention relates to a method, an apparatus, a system and an electronic device for service invocation, and in particular, to a method, an apparatus, a system and an electronic device for cross-region service invocation.
Background
In order to realize service calling among different regions of the world, the different regions synchronize and store service metadata of all service providers of each region through the registration centers of the different regions, when one region needs to call services provided by other regions, service consumers of the region need to acquire the service metadata of the service providers in the other regions from the registration centers of the region, and then the service consumers of the region directly realize cross-region connection with the service providers of the other regions so as to realize service calling.
In the process of implementing the invention, the inventor finds that the prior art has the following defects:
when the number of service providers increases and the number of areas increases, each service consumer and each service provider in different areas need cross-area connection, the dispersed point-to-point cross-area connection is very dependent on high-quality network conditions, and when the network conditions are poor, the service invocation quality is affected, and especially when the number of cross-area connections between the service consumers and the service providers increases, the network conditions are more unstable, and the service invocation quality is seriously affected. In addition, the registry needs to synchronize and store the service metadata of the service providers in each region, and as the number of regions increases and the service metadata of the service providers in each region increases, the storage pressure of the registry also increases.
Disclosure of Invention
Embodiments of the present invention provide a method, an apparatus, a system, and an electronic device for cross-regional service invocation, which reduce the number of cross-regional connections between service consumers and service providers in different regions, and can reduce the storage pressure of a registry.
The embodiment of the invention provides a cross-regional service calling system, which comprises a cross-regional agent module and a registration center:
the registration center is used for storing first service metadata of a service provider in the local area and storing second service metadata of the cross-area proxy module, receiving a cross-area service calling inquiry request of a service consumer needing cross-area service calling in the local area and providing the second service metadata of the cross-area proxy module for the service consumer, wherein the second service metadata comprises address information of the cross-area proxy module and fourth service metadata except the address information in third service metadata of the service provider in other areas;
the cross-regional proxy module is configured to receive a cross-regional service invocation request of a service consumer in the local region, and initiate service invocation to a service provider in another region according to the fourth service metadata included in the cross-regional service invocation request and address information of the service provider in the other region stored by the cross-regional proxy module.
The embodiment of the invention also provides a cross-regional service calling method, which comprises the following steps:
the method comprises the steps that a registry receives a cross-regional service calling inquiry request of a service consumer needing cross-regional service calling in a region, and returns second service metadata of a cross-regional proxy module to the service consumer, wherein the second service metadata comprises address information of the cross-regional proxy module and fourth service metadata except the address information in third service metadata of service providers in other regions;
the cross-regional agent module receives a cross-regional service call request of a service consumer in the region, and initiates service call to the service provider in the other region according to the fourth service metadata contained in the cross-regional service call request and address information of the service provider in the other region stored by the cross-regional agent module.
The embodiment of the invention also provides a cross-regional service calling method, which comprises the following steps:
receiving a cross-regional service calling request of a service consumer in the region;
and initiating service calling to the service providers of other areas according to the fourth service metadata contained in the cross-area service calling request and the stored address information of the service providers of other areas, wherein the fourth service metadata is service metadata except address information in the third service metadata of the service providers of other areas except the local area.
The embodiment of the invention also provides a cross-regional service calling device, which comprises:
the request receiving module is used for receiving a cross-regional service calling request of a service consumer in the region;
and a service calling module, configured to initiate service calling to the service providers in other areas according to the fourth service metadata included in the cross-area service calling request and address information of the service providers in other areas that are already stored, where the fourth service metadata is service metadata of the service providers in other areas except the local area except the address information.
The embodiment of the invention also provides a cross-regional service calling method, which comprises the following steps:
acquiring a service calling request uploaded by a client through a cloud service bus;
acquiring service provider information of a target area corresponding to the service calling request through the cloud service bus;
and sending the service calling request to a service provider in the target area through the cloud service bus according to the service provider information.
The embodiment of the invention also provides a cross-regional service calling device, which comprises:
the acquisition module is used for acquiring service provider information of a target area corresponding to the service calling request through a cloud service bus;
and the sending module is used for sending a service calling request to the service provider in the target area through the cloud service bus according to the service provider information.
The embodiment of the invention also provides a cross-regional service calling system, which comprises:
the cloud service bus is used for acquiring service provider information of at least one target area;
the registration center is used for storing service provider information in a region governed by the cloud service bus;
when any client side uploads a service calling request in an area where a cloud service bus belongs, service provider information of a target area corresponding to the service calling request is obtained through the cloud service bus; and sending a service calling request to a service provider in the target area through a cloud service bus according to the service provider information.
An embodiment of the present invention further provides an electronic device, including:
a memory for storing a program;
a processor, coupled to the memory, for executing the program for:
receiving a cross-regional service calling request of a service consumer in the region;
and initiating service calling to the service providers of other areas according to the fourth service metadata contained in the cross-area service calling request and the stored address information of the service providers of other areas, wherein the fourth service metadata is service metadata except address information in the third service metadata of the service providers of other areas except the local area.
The embodiment of the invention provides a cross-regional service calling method, a device, a system and electronic equipment, wherein a cross-regional proxy module is added in a region, the cross-regional proxy module is used as a special service provider in the region, and the address information of the cross-regional proxy module and metadata of service providers in other regions except the address information are registered in a registration center, so that service consumers in the region transfer cross-regional service calling requests to the cross-regional proxy module and perform unified processing by the cross-regional proxy module, thereby reducing the number of cross-regional connections between the service consumers and the service providers in other regions and reducing the metadata storage pressure of the registration center.
The foregoing description is only an overview of the technical solutions of the present invention, and the embodiments of the present invention are described below in order to make the technical means of the present invention more clearly understood and to make the above and other objects, features, and advantages of the present invention more clearly understandable.
Drawings
Fig. 1 is a schematic structural diagram of a cross-regional service invocation system according to an embodiment of the present invention;
fig. 2 is a flowchart illustrating a cross-regional service invocation method according to a first embodiment of the present invention;
fig. 3 is a flowchart illustrating a cross-regional service invocation method according to a second embodiment of the present invention;
fig. 4 is a schematic structural diagram of a cross-domain service invocation device according to a third embodiment of the present invention;
fig. 5 is a flowchart illustrating a cross-regional service invocation method according to a fourth embodiment of the present invention;
fig. 6 is a schematic structural diagram of a cross-regional service invocation device according to a fifth embodiment of the present invention;
fig. 7 is a schematic structural diagram of an electronic device according to an embodiment of the present invention.
Detailed Description
Exemplary embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. While exemplary embodiments of the present disclosure are shown in the drawings, it should be understood that the present disclosure may be embodied in various forms and should not be limited to the embodiments set forth herein. Rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the scope of the disclosure to those skilled in the art.
Description of the terms:
CSB: all known as Cloud Service Bus, a Cloud Service Bus, developed by the company Alibara. The cloud service bus can provide bus capabilities between different regions so that service providers can provide services across regions.
The registration center: and a service metadata storage center, wherein each region is provided with a registry, and a service consumer can acquire service metadata of a service provider providing services through the registry.
Service metadata: mainly related information of the service provider, including information such as name, configuration parameters and IP address of the service provided by the service provider.
In addition, in order to facilitate the explanation of the technical solution of the embodiment of the present invention, the following names are defined in the description process:
first service metadata: service metadata of service providers in the local region.
Second service metadata: service metadata of the cross-regional proxy module.
Third service metadata: service metadata of service providers of other regions.
Fourth service metadata: service metadata other than the address information among the service metadata of the service providers of the other regions.
The technical principle of the embodiment of the invention is as follows: the cross-regional agent module serving as an exit node of service calling is added in each region, and the cross-regional agent module executes cross-regional service calling, so that the storage pressure of a registration center is reduced, the number of cross-regional connections is reduced, the defects of synchronization delay, high storage pressure and the like caused by the large number of cross-regional connections in the service calling process in the prior art are avoided, and the global cross-regional service calling efficiency is improved.
As shown in fig. 1, which is a schematic structural diagram of a cross-region service invocation system according to an embodiment of the present invention, as shown in the drawing, an exemplary scenario includes three regions: US (usa), EU (europe) and ASIA (ASIA). Each region is provided with a registry 1 and a cross-region proxy module 2, the registry 1 and the cross-region proxy module 2 form a cross-region service calling system of the region, each region is provided with one or more service consumers 3 and one or more service providers 4, wherein the cross-region proxy module 2 can also be provided with one or more cross-region proxy modules as required, for example, one cross-region proxy module 2 can be provided for each other region except the region, and a plurality of cross-region proxy modules 2 can also be correspondingly provided for different types of service providers 4 in one other region. In the figure, the service consumer 3 in the united states is shown as an example of making a cross-regional service call to the other two regions.
In each area there are a plurality of service consumers 3 and service providers 4. The registry 1 of the present area stores first service metadata of the service providers 4 in the present area, and also stores second service metadata of the cross-regional proxy module 2, when the service consumer 3 of the local region needs to make a cross-regional service call, a cross-regional service call query request is firstly initiated to the registry 1 of the region, after the registry 1 receives the cross-regional service call query request, second service metadata providing the cross-regional proxy module 2 is returned to the service consumer 3, to transfer the cross-regional service call to the cross-regional proxy module 2 for processing, therefore, all service consumers 3 in the region are external interfaces through the cross-region agent module 2, the cross-region service calling aiming at other region service providers 4 is realized uniformly, thereby reducing the number of direct connections established between the service consumers 3 in the local area and the service providers 4 in other areas in the prior art.
In the system according to the embodiment of the present invention, the cross-regional proxy module 2 may be regarded as a special service provider in the local region, and the cross-regional proxy module 2 registers its own metadata (second service metadata) in the registry 1 as with other local service providers 4 (the dotted line between the cross-regional proxy module 2 and the registry 1 in the local region in the united states of america in the figure represents the registration relationship therebetween). The second service metadata of the trans-regional proxy module 2 includes address information of the trans-regional proxy module 2 and fourth service metadata other than the address information among the third service metadata of the service providers 4 of other regions.
The cross-regional proxy module 2 may also communicate with the registry 1 in another region to obtain third service metadata of the service provider 4 in another region (in the figure, the dotted line between the cross-regional proxy module 2 in the united states region and the registry 1 in another region represents the communication relationship therebetween). The trans-regional proxy module 2 may store the third service metadata of the service providers 4 in other regions in the memory for temporary storage and dynamic update, or may construct a special storage space for long-time storage, and in practical applications, the trans-regional proxy module 2 may only save part of the available third service metadata of all the service providers 4 in other regions without acquiring the third service metadata of all the service providers 4 in other regions, and may dynamically update the third service metadata through communication with the registry 1 in other regions.
It can be seen that the cross-regional proxy module 2 effectively shares the storage pressure of the registry 1 on the third service metadata of the service providers 4 of other regions in the prior art.
In fact, the metadata other than the address information is substantially the same for the service providers 4 in the same area, i.e., the above-mentioned fourth service metadata is the same, such as the name and configuration parameters of the service, or in the same area, there are different types of service providers 4 to provide different kinds of services, but the fourth service metadata of these service providers 4 is also the same for the service providers 4 providing the same type. The address information contained in the fourth service metadata registered by the cross-regional proxy module 2 with the registry 1 is the address information of the cross-regional proxy module 2 itself, and the third service metadata contained in the fourth service metadata is data having commonality, so that only one or a very small number of third service metadata are stored for the service providers 4 providing the same type, therefore, the data volume of the fourth service metadata registered by the cross-regional proxy module 2 with the registry 1 is very small, and the number of the fourth service metadata is the same as that of the cross-regional proxy modules 2 in the local region, and the number of the cross-regional proxy modules 2 is much smaller than that of the service providers 4 in other regions, compared with the prior art, because the registry 1 in the prior art completely synchronizes the service metadata of the service providers 4 stored in the registry 1 in other regions, the service metadata is stored in an integrated form, and because the address information of each service provider 4 is different, the registry 1 stores a large amount of service metadata for a large number of service providers 4, which results in a huge storage amount of the registry 1, and the technical scheme of the embodiment of the invention greatly reduces the storage pressure of the service metadata of the registry 1.
After the service consumer 3 in the local area accesses the registry 1 and acquires the second service metadata of the cross-regional proxy module 2, the service consumer initiates a cross-regional service call request to the cross-regional proxy module 2. Correspondingly, the cross-region proxy module 2 is configured to receive a cross-region service invocation request of the service consumer 3 in the current region, and initiate a service invocation to the service provider 4 in another region according to the fourth service metadata included in the cross-region service invocation request and address information of the service provider 4 in another region stored by the cross-region proxy module 2 (a solid arrow in the figure represents an interaction relationship involved in initiating the cross-region service invocation from the service consumer 3). Therefore, cross-regional service call requests of service consumers 3 in the region are all concentrated to be processed by the cross-regional proxy module 2, and call is initiated to the outside by the cross-regional proxy module 2, so that point-to-point connection between the service consumers 3 and service providers 4 among cross-regions in the prior art is reduced, service call quality is improved remarkably, the cross-regional proxy module 2 can be used as a dispatching management and control center at the same time, and overall flow control for cross-regional service call can be realized.
In addition, it should be noted that, in the embodiment of the present invention, the cross-region proxy module 2 may adopt a proxy module constructed by using a Cloud Service Bus (CSB) technology, where the address information may be IP address information. In addition, since all the service providers 4 may not be able to provide the service call across regions among the plurality of service providers 4 in one region, the cross-region proxy module 2 may obtain only the third service metadata of the service provider 4 having the capability of providing the service call across regions, from the third service metadata of the service provider 4 obtained from the registry 1 of another region, without obtaining the service metadata of all the service providers 4 of another region.
Example one
As shown in fig. 2, which is a schematic flowchart of a cross-regional service invoking method according to a first embodiment of the present invention, the cross-regional service invoking method according to the present embodiment is based on the cross-regional service invoking system shown in fig. 1, and includes:
s201: the method comprises the steps that a registry receives a cross-regional service calling inquiry request of a service consumer needing cross-regional service calling in a region, and returns second service metadata of a cross-regional proxy module to the service consumer, wherein the second service metadata comprises address information of the cross-regional proxy module and fourth service metadata except the address information in third service metadata of service providers in other regions; wherein all or part of the service providers of the other regions have the same fourth service metadata, as explained earlier.
S202: and the cross-region agent module receives a cross-region service calling request of a service consumer in the region, and initiates service calling to the service provider in other regions according to the fourth service metadata contained in the cross-region service calling request and the address information of the service provider in other regions stored by the cross-region agent module.
Further, the method may further include:
s203: and the cross-regional agent module is communicated with the registration centers of other regions except the region to acquire third service metadata of the service providers of the other regions.
In addition, the method may further include:
s204: the cross-regional proxy module registers the second service metadata of the cross-regional proxy module with the registry.
It should be noted that steps S201 and S202 are the main cross-regional service call flow, while steps S203 and S204 are preparation work for the cross-regional service call, and should be performed before steps S201 and S202 in terms of timing relationship, but dynamic update in real time may also be performed, that is, in S203, the cross-regional proxy module may perform continuous communication with the registry of the other region other than the local region, and update the third service metadata of the service provider of the other region in real time or periodically, and accordingly, in S204, the cross-regional proxy module may also update the second service metadata registered with the registry in real time or periodically.
The cross-regional service calling method of the embodiment of the invention adds the cross-regional agent module in the region, the cross-regional agent module is used as a special service provider in the region, and the address information of the cross-regional agent module and the metadata of the service providers of other regions except the address information are registered in the registration center, so that the service consumer in the region transfers the cross-regional service calling request to the cross-regional agent module and performs unified processing by the cross-regional agent module, thereby reducing the cross-regional connection quantity between the service consumer and the service providers of other regions and also reducing the metadata storage pressure of the registration center.
Example two
As shown in fig. 3, which is a flowchart illustrating a cross-regional service invocation method according to a second embodiment of the present invention, the cross-regional service invocation method in this embodiment describes a processing flow executed by a cross-regional proxy module, and includes:
s301: receiving a cross-regional service calling request of a service consumer in the region;
s302: and initiating service calling to the service providers of other areas according to fourth service metadata contained in the cross-area service calling request and the stored address information of the service providers of other areas, wherein the fourth service metadata is service metadata except the address information in the third service metadata of the service providers of other areas except the area. Wherein all or part of the service providers of the other regions have the same fourth service metadata, as explained earlier.
Further, the method may further include:
s303: and communicating with the registration center of the other area except the local area to acquire third service metadata of the service provider of the other area.
In addition, the method may further include:
s304: and registering second service metadata of the cross-regional agent module with the registry, wherein the second service metadata comprises address information of the cross-regional agent module and fourth service metadata except the address information in the third service metadata of the service providers in other regions.
Similar to the case of the first embodiment, steps S301 and S302 are main procedures for calling the cross-regional service, and steps S303 and S304 are preparatory tasks for calling the cross-regional service, and should be performed before steps S301 and S302 in terms of timing relationship, but dynamic update in real time may also be performed, that is, in S303, the cross-regional proxy module may perform continuous communication with the registry of the other region except the local region, and update the third service metadata of the service provider of the other region in real time or periodically, and accordingly, in S304, the cross-regional proxy module may also update the second service metadata registered with the registry in real time or periodically.
The cross-regional service calling method of the embodiment of the invention adds the cross-regional agent module in the region, the cross-regional agent module is used as a special service provider in the region, and the address information of the cross-regional agent module and the metadata of the service providers of other regions except the address information are registered in the registration center, so that the service consumer in the region transfers the cross-regional service calling request to the cross-regional agent module and performs unified processing by the cross-regional agent module, thereby reducing the cross-regional connection quantity between the service consumer and the service providers of other regions and also reducing the metadata storage pressure of the registration center.
EXAMPLE III
Fig. 4 is a schematic structural diagram of a cross-regional service invocation device according to a third embodiment of the present invention. The apparatus may be provided in the cross-region proxy module in fig. 1, and includes:
a request receiving module 401, configured to receive a cross-region service invocation request of a service consumer in the local region;
a service invoking module 402, configured to initiate a service invocation to a service provider in another region according to the fourth service metadata included in the cross-region service invoking request and address information of a service provider in another region that is already stored, where the fourth service metadata is service metadata of a service provider in another region other than the local region, except for address information.
Further, the apparatus may further include:
and the service metadata acquisition module is used for communicating with the registration centers of other areas except the local area to acquire third service metadata of service providers of the other areas.
Further, the apparatus may further include:
a service metadata registration module, configured to register the second service metadata of the cross-regional proxy module with the registry, where the second service metadata includes address information of the cross-regional proxy module and fourth service metadata, excluding the address information, in third service metadata of the service provider in the other region.
The cross-regional service calling device of the embodiment of the invention adds the cross-regional agent module in the region, the cross-regional agent module is used as a special service provider in the region, and the address information of the cross-regional agent module and the metadata of the service providers of other regions except the address information are registered in the registration center, so that the service consumer in the region transfers the cross-regional service calling request to the cross-regional agent module and performs unified processing by the cross-regional agent module, thereby reducing the cross-regional connection quantity between the service consumer and the service providers of other regions and also reducing the metadata storage pressure of the registration center.
Example four
As shown in fig. 5, which is a schematic flowchart of a cross-regional service invoking method according to a fourth embodiment of the present invention, the cross-regional service invoking method in this embodiment describes a processing flow executed by a cloud service bus, and includes:
s501: acquiring a service calling request uploaded by a client through a cloud service bus; as described above, the cross-region agent module can be constructed by using the cloud service bus technology.
S502: acquiring service provider information of a target area corresponding to the service calling request through a cloud service bus; the object to be accessed by the service invocation request may be a service provider in the local area or a service provider in another area. When the area to be accessed by the service call request is a service provider of another area, the service provider information of the target area mainly includes the fourth service metadata and the stored address information of the service provider of the other area.
S503: and sending a service calling request to a service provider in the target area through a cloud service bus according to the service provider information.
Further, before executing the content of step S501, the following steps may also be executed:
s504: and acquiring the service provider information of at least one target area through the cloud service bus.
Further, before executing the content of the step S501 and after executing the content of the step S504, the following steps may be further executed:
s505: service provider information of at least one target area to be invoked is stored.
Further, the step S502 can be further detailed as the following steps:
s506: analyzing the service calling request, and judging whether the area to be accessed by the service calling request is a service provider in the area;
s507: determining the area to be accessed by the service calling request as a target area under the condition that the judgment result is that the area to be accessed by the service calling request is the service provider of other areas;
s508: service provider information of the target area is obtained.
In addition, the method may further include:
s509: and sending the service calling request to the service provider according to the acquired service provider information under the condition that the area to be accessed by the service calling request is the service provider in the area as a judgment result.
Further, the step S503 may be further detailed as the following steps:
s510: under the condition that the number of the target areas is one, sending a service calling request to a service provider in the target area through a cloud service bus;
s511: and when the number of the target areas is multiple, respectively sending the service calling requests to the service providers in the target areas through the cloud service bus.
Further, the method may further include:
s512: and storing the service provider information of the local cloud service bus through the registry. As described above, the registry may store second service metadata of the cloud service bus, where the second service metadata includes address information of the cloud service bus and fourth service metadata excluding the address information among third service metadata of service providers of other regions.
Further, the method may further include:
s513: the overall traffic across the region is controlled through a cloud service bus.
Further, the method may further include:
s514: and synchronizing the service provider information of the area to be called through a preset calling module.
According to the cross-regional service calling method, the cloud service bus is additionally arranged in the region, the cloud service bus is used as a special service provider in the region, the address information of the cloud service bus and the metadata of the service providers in other regions except the address information are registered in the registration center, so that the service consumer in the region transfers the cross-regional service calling request to the cloud service bus and performs unified processing on the cross-regional service calling request, the number of cross-regional connections between the service consumer and the service providers in other regions is reduced, and the metadata storage pressure of the registration center is relieved.
EXAMPLE five
Fig. 6 is a schematic structural diagram of a cross-regional service invocation device according to a fifth embodiment of the present invention. The apparatus may be provided in the cross-region proxy module in fig. 1, and includes:
the receiving module 601 is configured to obtain a service call request uploaded by a client through a cloud service bus;
an obtaining module 602, configured to obtain, through a cloud service bus, service provider information of a target area corresponding to a service invocation request;
the sending module 603 is configured to send a service invocation request to a service provider in the target area through the cloud service bus according to the service provider information.
According to the cross-regional service calling device provided by the embodiment of the invention, the cloud service bus is additionally arranged in the region, the cloud service bus is used as a special service provider in the region, and the address information of the cloud service bus and the metadata of the service providers in other regions except the address information are registered in the registration center, so that the service consumer in the region transfers the cross-regional service calling request to the cloud service bus and performs unified processing by the cloud service bus, the cross-regional connection quantity between the service consumer and the service providers in other regions is reduced, and the metadata storage pressure of the registration center is also relieved.
The embodiment of the invention also provides a cross-regional service calling system, which comprises:
the cloud service bus is used for acquiring service provider information of at least one target area;
the registration center is used for storing service provider information in a region governed by the cloud service bus;
when any client side uploads a service calling request in an area where a cloud service bus belongs, service provider information of a target area corresponding to the service calling request is obtained through the cloud service bus; and sending a service calling request to a service provider in the target area through a cloud service bus according to the service provider information.
Further, the cloud service bus is further configured to acquire service provider information of at least one target area, and store the service provider information of at least one target area to be called.
In addition, the cloud service bus is also used for controlling the overall flow of the cross-region.
EXAMPLE six
As shown in fig. 7, a schematic structural diagram of an electronic device according to an embodiment of the present invention is shown in fig. 7, and in practice, the cross-region service invocation device in the foregoing embodiment may be implemented as an electronic device, and may include: a memory 71 and a processor 72.
The memory 71 stores programs.
In addition to the above-described programs, the memory 71 may also be configured to store other various data to support operations on the electronic device. Examples of such data include instructions for any application or method operating on the electronic device, such as an online shopping platform, an online merchant platform, phonebook data, messages, pictures, videos, and so forth.
The memory 71 may be implemented by any type or combination of volatile or non-volatile memory devices, such as Static Random Access Memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic or optical disks.
A processor 72 coupled to the memory 71 for executing programs in the memory 71.
In an embodiment of the present invention, the processor 72 is specifically configured to:
receiving a cross-regional service calling request of a service consumer in the region;
and initiating service calling to the service providers of other areas according to fourth service metadata contained in the cross-area service calling request and the stored address information of the service providers of other areas, wherein the fourth service metadata is service metadata except the address information in the third service metadata of the service providers of other areas except the area.
The above specific processing operations have been described in detail in the foregoing embodiments, and are not described again here.
Further, as shown in fig. 7, the electronic device may further include: communication components 73, power components 74, audio components 75, a display 76, and the like. Only some of the components are schematically shown in fig. 7, and the electronic device is not meant to include only the components shown in fig. 7.
The communication component 73 is configured to facilitate wired or wireless communication between the electronic device and other devices. The electronic device may access a wireless network based on a communication standard, such as WiFi, 2G or 3G, or a combination thereof. In an exemplary embodiment, the communication component 73 receives a broadcast signal or broadcast related information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 73 further includes a Near Field Communication (NFC) module to facilitate short-range communication. For example, the NFC module may be implemented based on Radio Frequency Identification (RFID) technology, infrared data association (IrDA) technology, Ultra Wideband (UWB) technology, Bluetooth (BT) technology, and other technologies.
A power supply component 74 provides power to the various components of the electronic device. The power components 74 may include a power management system, one or more power sources, and other components associated with generating, managing, and distributing power for an electronic device.
The audio component 75 is configured to output and/or input audio signals. For example, the audio component 75 includes a Microphone (MIC) configured to receive external audio signals when the electronic device is in an operational mode, such as a call mode, a recording mode, and a voice recognition mode. The received audio signal may further be stored in a memory 71 or transmitted via a communication component 73. In some embodiments, audio assembly 75 also includes a speaker for outputting audio signals.
The display 76 includes a screen, which may include a Liquid Crystal Display (LCD) and a Touch Panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive an input signal from a user. The touch panel includes one or more touch sensors to sense touch, slide, and gestures on the touch panel. The touch sensor may not only sense the boundary of a touch or slide action, but also detect the duration and pressure associated with the touch or slide operation.
Those of ordinary skill in the art will understand that: all or a portion of the steps of implementing the above-described method embodiments may be performed by hardware associated with program instructions. The program may be stored in a computer-readable storage medium. When executed, the program performs steps comprising the method embodiments described above; and the aforementioned storage medium includes: various media that can store program codes, such as ROM, RAM, magnetic or optical disks.
Finally, it should be noted that: the above embodiments are only used to illustrate the technical solution of the present invention, and not to limit the same; while the invention has been described in detail and with reference to the foregoing embodiments, it will be understood by those skilled in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some or all of the technical features may be equivalently replaced; and the modifications or the substitutions do not make the essence of the corresponding technical solutions depart from the scope of the technical solutions of the embodiments of the present invention.

Claims (13)

1. A cross-regional service calling system is characterized by comprising a cross-regional proxy module and a registry:
the registration center is used for storing first service metadata of a service provider in the region and storing second service metadata of the cross-region proxy module, receiving a cross-region service calling inquiry request of a service consumer needing cross-region service calling in the region, and providing the second service metadata of the cross-region proxy module for the service consumer, wherein the second service metadata comprises address information of the cross-region proxy module and fourth service metadata except the address information in third service metadata of the service provider in other regions;
the cross-regional proxy module is configured to receive a cross-regional service invocation request of a service consumer in the local region, and initiate a service invocation to a service provider in another region according to the fourth service metadata included in the cross-regional service invocation request and address information of the service provider in the other region stored by the cross-regional proxy module,
wherein all or a portion of the service providers of the other regions have the same fourth service metadata.
2. The system of claim 1,
the cross-regional agent module is also used for communicating with the registration centers of other regions except the region to acquire third service metadata of service providers of other regions.
3. The system of claim 1,
the cross-regional proxy module is also used for registering second service metadata of the cross-regional proxy module with the registry.
4. The system of claim 1, wherein the cross-regional proxy module is a proxy module constructed using cloud service bus technology.
5. A cross-regional service calling method is characterized by comprising the following steps:
the method comprises the steps that a registry receives a cross-regional service calling inquiry request of a service consumer needing cross-regional service calling in a region, and returns second service metadata of a cross-regional proxy module to the service consumer, wherein the second service metadata comprises address information of the cross-regional proxy module and fourth service metadata except the address information in third service metadata of service providers in other regions;
the cross-regional agent module receives a cross-regional service call request of a service consumer in the region, and initiates service call to the service provider of other region according to the fourth service metadata contained in the cross-regional service call request and the address information of the service provider of other region stored by the cross-regional agent module,
wherein all or a portion of the service providers of the other regions have the same fourth service metadata.
6. The method of claim 5, further comprising:
and the cross-regional agent module is communicated with the registration centers of other regions except the region to acquire third service metadata of service providers of the other regions.
7. The method of claim 5, further comprising:
the cross-regional proxy module registers the second service metadata of the cross-regional proxy module with the registry.
8. A cross-regional service calling method is characterized by comprising the following steps:
receiving a cross-regional service calling request of a service consumer in the region;
initiating service call to the service providers of other regions according to fourth service metadata contained in the cross-region service call request and address information of the service providers of other regions already stored, wherein the fourth service metadata is service metadata except address information in third service metadata of the service providers of other regions except the local region,
wherein all or a portion of the service providers of the other regions have the same fourth service metadata.
9. The method of claim 8, further comprising:
and communicating with the registration center of the other area except the local area to acquire third service metadata of the service provider of the other area.
10. The method of claim 8, further comprising:
and registering second service metadata of the cross-regional agent module with a registry, wherein the second service metadata comprises address information of the cross-regional agent module and fourth service metadata except the address information in the third service metadata of the service providers in other regions.
11. A device for cross-regional service invocation, comprising:
the request receiving module is used for receiving a cross-regional service calling request of a service consumer in the region;
a service calling module, configured to initiate a service call to a service provider in another region according to fourth service metadata included in the cross-region service call request and address information of the service provider in the other region that is already stored, where the fourth service metadata is service metadata of a service provider in another region other than the local region, except for the address information,
wherein all or a portion of the service providers of the other regions have the same fourth service metadata.
12. The apparatus of claim 11, further comprising:
and the service metadata acquisition module is used for communicating with the registration centers of other areas except the local area to acquire third service metadata of service providers of other areas.
13. The apparatus of claim 11, further comprising:
and the service metadata registration module is used for registering second service metadata of the cross-regional proxy module with the registry, wherein the second service metadata comprises address information of the cross-regional proxy module and fourth service metadata except the address information in the third service metadata of the service providers in other regions.
CN201810195626.0A 2018-03-09 2018-03-09 Cross-regional service calling method, device and system and electronic equipment Active CN110247944B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810195626.0A CN110247944B (en) 2018-03-09 2018-03-09 Cross-regional service calling method, device and system and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810195626.0A CN110247944B (en) 2018-03-09 2018-03-09 Cross-regional service calling method, device and system and electronic equipment

Publications (2)

Publication Number Publication Date
CN110247944A CN110247944A (en) 2019-09-17
CN110247944B true CN110247944B (en) 2022-06-24

Family

ID=67882788

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810195626.0A Active CN110247944B (en) 2018-03-09 2018-03-09 Cross-regional service calling method, device and system and electronic equipment

Country Status (1)

Country Link
CN (1) CN110247944B (en)

Families Citing this family (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109756481B (en) * 2018-11-30 2022-12-27 广州宏数科技有限公司 Method and system for realizing distributed docking of third-party system based on internet in different places
CN112688977B (en) * 2019-10-17 2023-06-16 浙江大搜车软件技术有限公司 Micro-service communication method, micro-service communication device, electronic equipment and machine-readable storage medium
CN111010380A (en) * 2019-12-06 2020-04-14 杭州视洞科技有限公司 Cross-regional service integration scheme
US11321324B2 (en) * 2019-12-31 2022-05-03 Huawei Technologies Co., Ltd. Systems and methods for cross-region data management in an active-active architecture
CN111598430A (en) * 2020-05-13 2020-08-28 国网山东省电力公司平邑县供电公司 Cross-region coordination information processing method and device for smart power grid
CN114221955B (en) * 2020-09-03 2023-01-20 浙江宇视科技有限公司 Device cross-region access method and device, electronic device and storage medium
CN114629953A (en) * 2020-12-14 2022-06-14 电科云(北京)科技有限公司 Service cross-domain calling method and system based on proxy
CN113127411B (en) * 2021-04-07 2023-06-16 华南理工大学 Cross-cloud service application distributed data access system and method

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103166934A (en) * 2011-12-15 2013-06-19 方正国际软件(北京)有限公司 Cooperative service system and cooperative service method
CN108600326A (en) * 2018-03-29 2018-09-28 阿里巴巴集团控股有限公司 Communication means, device and equipment
CN110233865A (en) * 2018-03-06 2019-09-13 阿里巴巴集团控股有限公司 Trans-regional service calling method, device and system

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN100558038C (en) * 2006-03-31 2009-11-04 国际商业机器公司 Service logger and related system and method
US7966383B2 (en) * 2009-03-27 2011-06-21 Business Objects Software Ltd. Client-server systems and methods for accessing metadata information across a network using proxies
CN107635022A (en) * 2016-07-18 2018-01-26 华为软件技术有限公司 Across intranet and extranet service access methods and device

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103166934A (en) * 2011-12-15 2013-06-19 方正国际软件(北京)有限公司 Cooperative service system and cooperative service method
CN110233865A (en) * 2018-03-06 2019-09-13 阿里巴巴集团控股有限公司 Trans-regional service calling method, device and system
CN108600326A (en) * 2018-03-29 2018-09-28 阿里巴巴集团控股有限公司 Communication means, device and equipment

Also Published As

Publication number Publication date
CN110247944A (en) 2019-09-17

Similar Documents

Publication Publication Date Title
CN110247944B (en) Cross-regional service calling method, device and system and electronic equipment
CN113300985B (en) Data processing method, device, equipment and storage medium
US10485034B2 (en) Method, device and system for accessing wireless network
US11172530B2 (en) Communication establishment method and terminal
US10194274B2 (en) Method and device for providing wireless access point
CN109150677B (en) Cross-domain access processing method and device and electronic equipment
US7844244B2 (en) Methods, apparatuses, and computer program products for providing dynamic assignment of slot cycle index for network nodes
CN109586929B (en) Conference content transmission method and device, electronic equipment and storage medium
CN104253742A (en) Virtual web real-time communications (WEBRTC) gateways, and related methods and systems
CN113709200B (en) Method and device for establishing communication connection
CN104756080A (en) Augmenting capabilities of a host device
CN108965413B (en) Information interaction method and device and storage medium
EP2974159B1 (en) Method, device and system for voice communication
CN110365587B (en) Inter-device communication method, device and storage medium
CN114666306B (en) WebRTC network connection establishment method, server, electronic device and computer readable storage medium
CN109787900B (en) Transmission method, device, equipment and machine readable medium
CN112947880A (en) Screen projection method and device and electronic equipment
US20150365133A1 (en) Touch and Talk Auto-Configuring of Video Conferences Using Near Field Communication (NFC)
CN114844744B (en) Virtual private cloud network configuration method and device, electronic equipment and computer readable storage medium
CN112448985B (en) Distributed system, network processing method and device and electronic equipment
CN111104575B (en) Data grabbing method and device and electronic equipment
US20180084589A1 (en) Wireless data sharing method and system
JP6296605B2 (en) Push notification transmission method and system, push notification apparatus and communication terminal
CN111314462A (en) Resource processing method, device and storage medium
WO2023221855A1 (en) Data channel application list processing method, apparatus, and device

Legal Events

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