Communication method and apparatus

By obtaining the processing latency of API instances and the transmission latency of topology combinations, the problem of service callers being unable to ensure API performance in advance is solved, and API services that meet latency requirements before invocation are realized.

WO2026067381A1PCT designated stage Publication Date: 2026-04-02HUAWEI TECH CO LTD
View PDF 5 Cites 0 Cited by

Patent Information

Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
Filing Date
2025-09-23
Publication Date
2026-04-02

AI Technical Summary

Technical Problem

Service consumers can only perceive the performance of an API after calling it, making it impossible to ensure in advance that the API meets performance requirements, which leads to service delivery not meeting expectations.

Method used

By obtaining the instance processing latency and topology combination transmission latency of the first API and the second API, the latency performance of the first API is determined to ensure that the needs of the service caller are met before the call.

Benefits of technology

It enables accurate determination of API latency performance before invocation, ensuring that the API can meet the latency requirements of service callers and provide services that meet performance requirements.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN2025123228_02042026_PF_FP_ABST
    Figure CN2025123228_02042026_PF_FP_ABST
Patent Text Reader

Abstract

A communication method and apparatus. In the method, a first apparatus obtains first information, and the first information indicates that a second API is called during a process in which a first API provides a first service. On the basis of the first information, the first apparatus obtains a processing delay of an instance of the first API and a processing delay of one or more instances corresponding to the second API, and obtains transmission delays respectively corresponding to at least one topology combination. The first apparatus determines delay performance of the first API on the basis of the processing delay of the instance of the first API, the processing delay of the one or more instances corresponding to the second API, and the transmission delays respectively corresponding to the at least one topology combination. According to the above method, the first apparatus can accurately determine the delay performance of the first API, and the first API can provide a variety of delay performance options for a device requesting the first service.
Need to check novelty before this filing date? Find Prior Art

Description

Communication method and apparatus

[0001] Cross-reference to related applications

[0002] This application claims priority to the Chinese Patent Application No. 202411359078.2, filed on September 26, 2024, and entitled "A communication method and apparatus", the content of which is incorporated herein by reference in its entirety. TECHNICAL FIELD

[0003] The present application relates to the field of communication, and in particular, to a communication method and apparatus. BACKGROUND

[0004] Currently, after a service invoker invokes an application programming interface (API), the service invoker can count a plurality of parameters of performance of the API, such as a request response time, a throughput, a transaction per second, a query per second, and a concurrency, and the like. The service invoker can know the performance of the API based on the above parameters. That is, the service invoker does not know the performance of the API before invoking the API, and can only know the performance of the API after invoking the API. Therefore, the invoked API can provide a corresponding service, but may not meet the performance requirement of the service invoker for the service, and is only a best-effort service without any service level agreement (SLA) guarantee. For example, assuming that the service invoker expects a latency of service A to be less than 50 ms, but after the service invoker invokes an API providing the service A, the service invoker can determine that the API provides the service A with a latency greater than 50 ms.

[0005] In summary, how to enable the service invoker to invoke an API meeting the performance requirement to provide a service for the service invoker, instead of being able to perceive the performance of the API after invoking the API, is a problem worth attention. SUMMARY

[0006] Embodiments of the present application provide a communication method and apparatus to enable a service invoker to invoke an API meeting a performance requirement to provide a service for the service invoker.

[0007] In a first aspect, a method for communication is provided. The method can be applied to a first device, such as a core function network element, or a capability exposure gateway, or an external API instance. In an example where the method is applied to the first device, the method includes: obtaining, by the first device, first information indicating that a first API invokes a second API in a process of providing a first service; obtaining, by the first device, a processing delay of an instance of the first API and processing delays of one or more instances of the second API corresponding to the second API according to the first information; obtaining, by the first device, transmission delays corresponding to at least one topology combination respectively, wherein each topology combination includes the instance of the first API and one of the one or more instances of the second API corresponding to the second API; and determining, by the first device, a latency performance of the first API according to the processing delay of the instance of the first API, the processing delays of the one or more instances of the second API corresponding to the second API, and the transmission delays corresponding to the at least one topology combination respectively.

[0008] With the above method, the first device can accurately determine the latency performance of the first API according to the processing delay of the instance of the first API, the processing delays of the one or more instances of the second API corresponding to the second API, and the transmission delays corresponding to the at least one topology combination respectively, where the latency performance of the first API can be at least one, i.e., the first API can guarantee at least one latency. Therefore, before a device requesting the first service invokes the first API, at least one latency that the first API can guarantee has been determined, i.e., the first API can provide multiple selectable latency performances for the device requesting the first service, so that the device requesting the first service can invoke an API satisfying the latency requirement to provide a service.

[0009] In a possible design, in determining the latency performance of the first API according to the processing delay of the instance of the first API, the processing delays of the one or more instances of the second API corresponding to the second API, and the transmission delays corresponding to the at least one topology combination respectively, the latency performance of the first API is determined according to the processing delay of the instance of the first API, the processing delays of the one or more instances of the second API corresponding to the second API, the transmission delays corresponding to the at least one topology combination respectively, and a transmission delay between the instance of the first API and a first capability exposure gateway, where the first capability exposure gateway is a first hop node invoking the instance of the first API.

[0010] With the above design, the latency performance of the first API can be determined in combination with the transmission delay between the instance of the first API and the first capability exposure gateway, so as to more accurately reflect the latency performance of the first API.

[0011] In a possible design, when the first device is a core function network element, the first device acquires a topological relationship between at least one capability exposure gateway and the instance of the first API; and selects the first capability exposure gateway from the at least one capability exposure gateway according to the topological relationship.

[0012] With the above design, the capability exposure gateway can be selected for the instance of the first API.

[0013] In a possible design, when the first device is a core function network element or the instance of the first API, the first device sends a first notification message to the first capability exposure gateway, where the first notification message includes an identifier of the instance of the first API, or the first notification message indicates a latency performance of the first API.

[0014] In a possible design, when the first device is the first capability exposure gateway or the instance of the first API, the first device sends a second notification message to a core function network element, where the second notification message indicates a latency performance of the first API. Correspondingly, the core function network element receives the second notification message from the first device.

[0015] In a possible design, when the first device is a core function network element or the first capability exposure gateway, the first device sends configuration information of the instance of the first API to the instance of the first API, where the configuration information of the instance of the first API indicates a latency performance of the first API.

[0016] With the above design, the instance of the first API can learn the latency performance of the first API.

[0017] In a possible design, the first information further indicates that the first API invokes a third API in providing the first service, and a calling sequence of the first API, the second API and the third API; each topological combination includes the instance of the first API, one of one or more instances corresponding to the second API, and one of one or more instances corresponding to the third API; and a transmission latency corresponding to each topological combination is determined according to the calling sequence and transmission latencies between instances in the topological combination.

[0018] With the above design, the calling sequence of the first API, the second API and the third API can be notified, and the transmission latency corresponding to each topological combination can be accurately determined based on the calling sequence.

[0019] In a possible design, when determining the latency performance of the first API according to the processing latency of the instance of the first API, the processing latency of one or more instances corresponding to the second API, and the transmission latency corresponding to the at least one topology combination respectively, the processing latency of one or more instances corresponding to the third API is obtained according to the first information; and the latency performance of the first API is determined according to the processing latency of the instance of the first API, the processing latency of one or more instances corresponding to the second API, the processing latency of one or more instances corresponding to the third API, and the transmission latency corresponding to the at least one topology combination respectively.

[0020] In a possible design, when determining the latency performance of the first API according to the processing latency of the instance of the first API, the processing latency of one or more instances corresponding to the second API, and the transmission latency corresponding to the at least one topology combination respectively, the latency performance of the at least one topology combination is determined according to the processing latency of the instance of the first API, the processing latency of one or more instances corresponding to the second API respectively, and the transmission latency corresponding to the at least one topology combination respectively; wherein the latency performance corresponding to each topology combination is determined according to the transmission latency corresponding to the topology combination and the processing latency corresponding to the topology combination, and the processing latency corresponding to the topology combination is determined according to the processing latency corresponding to each instance included in the topology combination respectively; and the latency performance of the first API is determined according to the latency performance of the at least one topology combination.

[0021] The above design can be used to accurately determine the latency performance corresponding to each topology combination, and the latency performance of the first API can include one or more of the latency performance of the at least one topology combination.

[0022] In a possible design, a first request message is received, the first request message is used to request to discover a capability discovery gateway corresponding to the first API, and the first request message includes first indication information, where the first indication information indicates a latency requirement for the first API; a first capability exposure gateway is determined according to the first request message and the latency performance of the first API, the first capability exposure gateway is a first-hop function node of an instance of the first API, and the latency performance of the instance of the first API meets the latency requirement indicated by the first indication information; and a first response message is sent, where the first response message includes an address of the first capability exposure gateway.

[0023] The above design can be used to enable a device requesting a first service to discover a capability discovery gateway.

[0024] In a possible design, a second request message is received, where the second request message is used to request invoking the first API, and the second request message includes second indication information, where the second indication information indicates a latency requirement for the first API; an instance of the first API is determined according to the second request message; and a call request is sent to the instance of the first API, where the call request includes third indication information, and the third indication information is used to determine one of the at least one topology combination, and the third indication information is determined according to the second indication information.

[0025] The above design can be used to enable a device requesting a first service to accept, process, and / or forward a call request.

[0026] In a possible design, when the first information is acquired, the first information is acquired from a first network element, and the first network element is any one of the following: an instance of the first API, an API publishing function network element, a network storage function network element, and an API storage function network element.

[0027] In a possible design, a processing latency of the instance of the first API is acquired from the first network element.

[0028] In a possible design, a processing latency of one or more instances corresponding to the second API is acquired from a second network element, and the second network element is any one of the following: a network storage function network element, a network function (NF) management system, and an API management system.

[0029] In a possible design, the processing latency of the instance of the first API is a latency between a received request for invoking the instance of the first API and sending a corresponding call request to a next-hop instance of a second API, or a latency between the received request for invoking the instance of the first API and giving a response or result of the request; and the processing latency of the instance of the second API is a latency between a received call request of the instance of the second API and sending a corresponding call request to a next-hop instance, or a latency between the received request for invoking the instance of the second API and giving a response or result of the request.

[0030] In a second aspect, a communication method is provided, including: acquiring a topology relationship between at least one capability exposure gateway and an instance of a first API; selecting a first capability exposure gateway from the at least one capability exposure gateway according to the topology relationship, where the first capability exposure gateway is a first-hop node for invoking the instance of the first API; acquiring a processing latency of the instance of the first API; and determining a latency performance of the instance of the first API according to the processing latency of the instance of the first API and a transmission latency between the instance of the first API and the first capability exposure gateway.

[0031] By using the method, the first device can accurately determine the latency performance of the instance of the first API according to the processing latency of the instance of the first API and the transmission latency between the instance of the first API and the first capability exposure gateway, where the latency performance of the first API can be at least one, that is, the first API can guarantee at least one latency. Therefore, before the device requesting the first service invokes the first API, at least one latency that can be guaranteed by the first API is determined, that is, the first API can provide multiple optional latency performances for the device requesting the first service, so that the device requesting the first service can invoke an API meeting the latency requirement to provide a service. The method can be generally applicable to a scenario where the first API does not depend on other APIs.

[0032] In a possible design, the notification message includes an identifier of the instance of the first API, or the notification message indicates the latency performance of the instance of the first API.

[0033] In a possible design, when the processing latency of the instance of the first API is acquired, the processing latency of the instance of the first API is acquired from a first network element, where the first network element is any one of the instance of the first API, an API publishing function network element, a network storage function network element, and an API storage function network element.

[0034] In a possible design, the processing latency of the instance of the first API is a latency from receiving a request of invoking the instance of the first API to giving a response or a result of the request.

[0035] In a third aspect, the present application provides a communication device, which can be the first device, or a module or unit (for example, a chip, or a chip system, or a circuit) corresponding to the method / operation / step / action described in any one of the first aspect or the second aspect, or can be matched with the first device.

[0036] In a fourth aspect, the present application provides a communication device, including at least one processing element, and at least one storage element for storing programs and data, where the at least one processing element is configured to read and execute the programs and data stored in the storage element, so that the method described in any one of the aspects of the present application is implemented.

[0037] In a possible design, the communication device further includes the at least one storage element.

[0038] In a fifth aspect, the present application further provides a computer program, when the computer program is executed on a computer, so that the computer executes the method described in any one of the aspects.

[0039] In a sixth aspect, the present application provides a communication apparatus, comprising: an interface circuit and at least one processor; the interface circuit is configured to provide input and / or output of a program or instruction for the at least one processor; the at least one processor is configured to execute the program or instruction so that the communication apparatus can implement the method in any one of the above aspects.

[0040] In a possible way, the communication apparatus comprises the at least one memory, and the at least one memory is configured to store the program or instruction.

[0041] In a seventh aspect, the present application provides a computer storage medium, wherein the computer storage medium stores a software program, and the software program, when read and executed by one or more processors, can implement the method in any one of the above aspects.

[0042] In an eighth aspect, the present application provides a computer program product comprising instructions which, when executed on a computer, cause the computer to perform the method in any one of the above aspects.

[0043] In a ninth aspect, the present application provides a chip system, comprising at least one chip and a memory, and the at least one chip is configured to read and execute a program stored in the memory to implement the method in any one of the above aspects.

[0044] On the basis of the implementation provided in the above aspects, the present application can be further combined to provide more implementations. BRIEF DESCRIPTION OF DRAWINGS

[0045] FIG. 1 shows a schematic diagram of a 5G network architecture based on a service-oriented architecture;

[0046] FIG. 2A shows a schematic diagram of the dependency relationship between an external API and a plurality of internal APIs;

[0047] FIG. 2B shows a schematic diagram of the calling sequence of an external API and a plurality of internal APIs;

[0048] FIG. 3 shows a schematic diagram of an instance of an external API and an instance of an internal API;

[0049] FIG. 4A and FIG. 4B show a schematic diagram of an API system architecture;

[0050] FIG. 5 shows a schematic diagram of a CAPIF architecture;

[0051] FIG. 6 shows an overview flowchart of a communication method;

[0052] FIG. 7 shows an overview flowchart of a communication method;

[0053] FIG. 8 shows an overview flowchart of a communication method;

[0054] FIG. 9 shows an overview flowchart of a communication method;

[0055] FIG. 10 shows an overview flowchart of another communication method;

[0056] FIG. 11 shows a structural schematic diagram of a communication apparatus;

[0057] FIG. 12 shows a structural schematic diagram of another communication apparatus. DETAILED DESCRIPTION

[0058] The specific implementation manners of the present application will be described below in conjunction with the drawings in the embodiments of the present application. However, the implementation manners of the present application can also include combining the embodiments without departing from the scope of the present application, such as adopting other embodiments and making structural changes. Therefore, the detailed description of the following embodiments should not be understood in a limiting sense. The terms used in the embodiment part of the present application are only used to explain the specific embodiments of the present application, and are not intended to limit the present application.

[0059] The embodiments of the present application can be applied to various communication systems, such as a global system for mobile communications (GSM) system, a code division multiple access (CDMA) system, a wideband code division multiple access (WCDMA) system, a general packet radio service (GPRS), a long term evolution (LTE) system, an LTE frequency division duplex (FDD) system, an LTE time division duplex (TDD), a universal mobile telecommunication system (UMTS), a worldwide interoperability for microwave access (WIMAX) communication system, a 5th generation (5G) system or a new radio (NR), or a future communication system or other similar communication system, etc.

[0060] FIG. 1 is a schematic diagram of a 5G network architecture based on a service-based architecture. The 5G network architecture shown in FIG. 1 can include terminals, access network devices, and core network devices. The terminals access a data network (DN) through the access network devices and the core network devices. The core network devices include various network functions (NFs) or network elements, such as some or all of the following network elements: a unified data management (UDM) network element, a unified data repository (UDR) network element, an application function (AF) network element, a policy control function (PCF) network element, an access and mobility management function (AMF) network element, a session management function (SMF) network element, a user plane function (UPF) network element, a network repository function (NRF) network element, a network data analytics function (NWDAF) network element, and the like.

[0061] The access network device can be a radio access network (RAN) device. For example, a base station, an evolved NodeB (eNodeB), a transmission reception point (TRP), a next generation NodeB (gNB) in a 5G mobile communication system, a next generation base station in a future mobile communication system, or an access node in a wireless fidelity (WiFi) system, and the like; or a module or unit that implements part of the functions of the access network device, such as a central unit (CU) or a distributed unit (DU). The access network device can be a macro base station, a micro base station or an indoor station, or a relay node or a donor node, and the like. Embodiments of the present application do not limit the specific technology and specific device form of the access network device.

[0062] The terminal can be a user equipment (UE), a mobile station, a mobile terminal, etc. The terminal can be widely applied to various scenarios, such as device-to-device (D2D), vehicle to everything (V2X) communication, machine-type communication (MTC), internet of things (IOT), virtual reality, augmented reality, industrial control, automatic driving, remote medical treatment, smart power grid, smart furniture, smart office, smart wear, smart transportation, smart city, etc. The terminal can be a mobile phone, a tablet computer, a computer with wireless transceiver function, a wearable device, a vehicle, a city air vehicle (such as a pilotless plane, a helicopter, etc.), a ship, a robot, a mechanical arm, a smart home device, etc.

[0063] The access network device and the terminal can be fixed in position or movable. The access network device and the terminal can be deployed on land, including indoors or outdoors, handheld or vehicle-mounted; can be deployed on the water surface; and can also be deployed on an airplane, a balloon, and a man-made satellite in the air. Embodiments of the present application do not limit the application scenarios of the access network device and the terminal.

[0064] Some core network devices are briefly introduced as follows:

[0065] The AMF network element, referred to as AMF, contains functions of performing mobility management, access authentication / authorization, etc. In addition, it is also responsible for delivering user policies between the terminal and the PCF.

[0066] The SMF network element, referred to as SMF, contains functions of performing session management, execution of control policies issued by the PCF, selection of the UPF, allocation of an internet protocol (IP) address of the terminal, etc.

[0067] The UPF network element, referred to as UPF, as an interface with a data network, contains functions of completing user plane data forwarding, session / stream level-based charging statistics, bandwidth limitation, etc.

[0068] The UDM network element, referred to as UDM, contains functions of performing management of subscription data, user access authorization, etc.

[0069] The UDR network element, referred to as UDR, contains functions of accessing data of types such as subscription data, policy data, and application data.

[0070] The NEF network element, referred to as NEF, is used to support opening of capabilities and events.

[0071] AF network element, referred to as AF, conveys application-side requirements for network-side, such as quality of service (QoS) requirements or user state event subscription, etc. The AF can be a third-party functional entity or an application server deployed by an operator.

[0072] PCF network element, referred to as PCF, contains policy control functions responsible for charging, QoS bandwidth guarantee and mobility management at the session and service flow level, terminal policy decision, etc.

[0073] NRF network element, referred to as NRF, can be used to provide network element discovery functions, and provide network element information corresponding to the network element type based on the request of other network elements. The NRF network element also provides network element management services, such as network element registration, update, deregistration, and network element state subscription and push, etc.

[0074] It can be understood that the above network elements are examples of an implementation manner, and the application does not exclude that network elements or devices with the above network element functions exist in future communication systems or other similar communication systems, have other names, or have other forms. In addition, the above network elements or functions can be network elements in a hardware device, or software functions running on a dedicated hardware, or virtualized functions instantiated on a platform (such as a cloud platform). As a possible implementation method, the above network elements or functions can be implemented by one device, or can be implemented by multiple devices together, or can be a functional module in a device, and the embodiments of the application do not make specific limitations.

[0075] The following mainly takes the performance indicators about latency performance provided by the API as an example for introduction, in addition, the NF or API can also provide performance indicators about other performances, and the application does not make limitations.

[0076] The application mainly relates to two types of APIs, external API and internal API. The external API, also referred to as service API, refers to the API provided by the operator network to the application, for example, the external API can be an extended reality (XR) transmission API, an industrial high-reliability data transmission API, etc. The internal API, also referred to as network API, refers to the API provided by the network entity or network element in the operator network or controllable by the operator, which can be an access network device, a core network element, or an operator application server, etc. For example, the internal API can be a quality of service (QoS) request API, a network transmission quality analysis API, etc.

[0077] In the process of providing the corresponding service, one external API can need to call one or more internal APIs. Or, one external API can have a dependency relationship with one or more internal APIs; or, one external API has a mapping relationship with one or more internal APIs.

[0078] For example, the external API is a service API of XR transmission, and the external API needs to call multiple internal APIs, such as a QoS request API, a network transmission quality analysis API, etc., in the process of providing the service of XR transmission.

[0079] For example, as shown in FIG. 2A, the external API_a depends on the internal API_1, the internal API_2, and the internal API_4. It should be noted that FIG. 2A does not indicate the calling order of the external API_a, the internal API_1, the internal API_2, and the internal API_4.

[0080] For example, as shown in FIG. 2A, the external API_a depends on the internal API_1, the internal API_2, and the internal API_4. It should be noted that FIG. 2A does not indicate the calling order of the external API_a, the internal API_1, the internal API_2, and the internal API_4.

[0081] For example, the external API_a depends on the internal API_1 and the internal API_2. The calling order can be external API_a->internal API_1->internal API_2, as shown in (1) of FIG. 2B. Or, the calling order can be external API_a->internal API_1->internal API_2->external API_a, as shown in (2) of FIG. 2B. Or, the calling order can be external API_a->internal API_1->internal API_2->internal API_1->external API_a, as shown in (3) of FIG. 2B. Or, the calling order can be external API_a->internal API_1 and internal API_2 (i.e., internal API_1 and internal API_2 are in parallel)->external API_a, as shown in (4) of FIG. 2B, wherein the time sequence represented by the straight line is prior to the time sequence represented by the dashed line.

[0082] It can be understood that one API can correspond to one or more instances, each instance can have the same function and API name, but the performance of each instance can be different. For example, one external API can correspond to one or more instances of the external API, and one internal API can correspond to one or more instances of the internal API. For example, as shown in FIG. 3, the external API_a can correspond to multiple instances of the external API_a, and the internal API_1 can correspond to multiple instances of the internal API_1.

[0083] The system architecture that can be used in the present application is described below:

[0084] I. API system architecture.

[0085] The API system architecture can include the following functional entities: an API management system, external API instances, a capability exposure gateway, a core function network element, and an API invoker.

[0086] The number of external API instances can be one or more. The following FIG. 4A and FIG. 4B only take one external API instance as an example for illustration.

[0087] I) Capability exposure gateway: The capability exposure gateway refers to an entry point of external API invocation, and can implement functions such as topology hiding and dynamic routing to the outside. The capability exposure gateway can select a suitable external API instance from one or more external API instances after receiving the invocation request of the API invoker, and forward or route the invocation request to the selected external API instance. The capability exposure gateway can also perform a check of resource owner consent. The capability exposure gateway can also be an API gateway (gateway), NEF, or application programming interface exposure function (AEF) network element. The capability exposure gateway can be divided into two types: local capability exposure gateway and central capability exposure gateway, which have different deployment locations. The coverage area of the local capability exposure gateway is smaller than that of the central capability exposure gateway. Generally, the local capability exposure gateway is deployed closer to the terminal and access network equipment, and the number is larger and the distribution is more intensive. The central capability exposure gateway is generally deployed on the aggregation and backbone network, and the number is smaller and the distribution is more sparse.

[0088] The external API instance can be deployed into the same network element or device as the capability exposure gateway. In this case, the transmission delay between the external API instance and the capability exposure gateway can be ignored. Alternatively, the external API instance can also be deployed into a different network element or device from the capability exposure gateway, which is not limited in the present application. The following FIG. 4A and FIG. 4B only take the external API instance and the capability exposure gateway deployed in different network elements or devices as an example for illustration.

[0089] II) Core function network element: It can be a common application programming interface framework core function (CCF) or other network elements with similar functions, and the name thereof is not limited in the present application. The following only takes the CCF as an example for illustration. The functions of the CCF can refer to the related description of the CCF in the following FIG. 5.

[0090] Three), API calling entity, generally a third-party application function entity software program signed a service agreement with a public land mobile network (PLMN) operator. The third-party application can be, for example, a machine to machine (M2M) application, an internet of things (IoT) application, a vehicle to everything (V2X) application, etc. These applications can run in a terminal or in an access network device. In addition, the API calling entity can also refer to an AF network element. The API calling entity can be in the same trust domain as the API provider (such as a PLMN operator) that provides the API, or can belong to different trust domains. The API calling entity supports the following capabilities: triggering the online or offline of the API calling entity; supporting the authentication of the API calling entity by providing the identification and other information of the API calling entity; supporting mutual authentication with the common API framework (CAPIF); obtaining authorization between access / API; requesting to discover API; requesting to discover gateway; requesting to call API.

[0091] Four), API management system: responsible for managing the resources required and used by the API, such as scheduling container resources for the API, fetching API code packages, installing API code packages, etc.

[0092] Among them, the API management system can be an independent function entity.

[0093] Five), external API instance: an external API instance is a function entity that provides specific API functions open to third-party (such as application) calls, which can be deployed in a physical server, a virtual machine, or a container.

[0094] The architecture can include but is not limited to the following functions:

[0095] 1. External API repository function: responsible for storing information of external APIs.

[0096] Among them, this function can be an independent function entity, or can also be part of the core function network element, NRF or capability exposure gateway.

[0097] 2. External API discovery function: responsible for discovering available APIs.

[0098] Among them, this function can be an independent function entity, or can also be part of the CCF or capability exposure gateway.

[0099] In particular, the function is responsible for processing the external API discovery request of the API calling entity, and can also authorize and authenticate the external API discovery, and return the information of the external API to the API calling entity.

[0100] 3. External API account management function: responsible for registration, billing, security token acquisition and update, and also responsible for managing the account of the third party, including the historical record of user ordering service, billing record, API usage statistics, etc.

[0101] The function can be a separate function entity, or can also be part of the CCF.

[0102] 4. Gateway discovery function: responsible for discovering available capability exposure gateway.

[0103] 5. External API publishing function: responsible for registering the instance of the external API to the external API repository. The external API publishing function can be part of the API management system, the instance of the external API, or the capability exposure gateway.

[0104] It should be noted that the NRF can be responsible for managing the network element profile registered to the NRF, i.e., implementing the network element granularity management. In addition, the NRF can also be responsible for managing the service function, such as the IMS AS function entity, and the service function (such as AI model) deployed by the third party inside the operator network and wishing to expose the capability. In addition, the NRF can also be responsible for managing the service information, i.e., the NRF can maintain the information based on the service granularity, i.e., the information of the saved NF service, business service, etc. API service.

[0105] II. Common API framework (CAPIF) architecture

[0106] Referring to FIG. 5, it is a schematic diagram of the CAPIF architecture.

[0107] The CAPIF architecture includes the API calling entity, the CCF network element, and the application programming interface publishing function (APF) network element, and can also include the AEF network element, and can also include the application programming interface management function (API management function) network element.

[0108] The API calling entity can refer to the related content described above.

[0109] The CCF network element supports the following functions: based on the identity and other information of the API calling entity, performing authentication of the API calling entity; supporting mutual authentication between API calling entities; providing authorization of the API calling entity before the API calling entity accesses / accesses the API; supporting API publishing, storage, and discovery functions; performing control of API access based on the policy configured by the operator PLMN; storing API calling log information and providing the API calling log to other authorized entities; performing charging based on the API calling log information; monitoring API calling; performing online or offline functions of the API calling entity; storing CAPIF or API related configuration policy information; supporting access / access API logs to implement audit functions; supporting interconnection with another CCF to implement API publishing and discovery functions.

[0110] The AEF network element is an API exposure function entity that is a provider of the API and is also an entry point for the API calling entity to call the API. The AEF network element supports the following functions: based on the identity and other information of the API calling entity, performing authentication of the API calling entity; confirming authorization provided by the CCF; synchronizing API calling logs to the CCF.

[0111] The APF network element is an API publishing function that is an API provider that publishes API information, thereby supporting the API calling entity to discover API information. The APF network element supports the following functions: publishing API information of the API providing entity to the CCF; providing API publishing functions so that the API calling entity can discover the API.

[0112] The application programming interface management function network element is an API management function that is an API provider that manages the API. The application programming interface management function network element has the following functions: supporting auditing of API calling log information received from the CCF; monitoring related events reported by the CCF; configuring policy information of the API provider to the CCF; monitoring the status of the API; supporting online or offline of the API calling entity; supporting registration and registration maintenance information of the API provider domain function

[0113] The CAPIF architecture involves a plurality of interfaces, which can be generally divided into two categories: a trusted domain communication interface and a non-trusted domain communication interface, as shown in FIG. 5. The former includes a CAPIF-1 interface, a CAPIF-2 interface, a CAPIF-3 interface, a CAPIF-4 interface, and a CAPIF-5 interface. The latter includes a CAPIF-1e interface and a CAPIF-2e interface. The CAPIF-1 interface is an interface between an API calling entity in the trusted domain and the CCF. The CAPIF-2 interface is an interface between the API calling entity in the trusted domain and the AEF network element. The CAPIF-3 interface is an interface between the AEF network element and the CCF. The CAPIF-4 interface is an interface between the APF network element and the CCF. The CAPIF-5 interface is an interface between an application programming interface management function network element and the CCF. The CAPIF-1e interface is an interface between an API calling entity in the non-trusted domain and the CCF. The CAPIF-2e interface is an interface between the API calling entity in the non-trusted domain and the AEF network element. It can be understood that the above interfaces are only examples and are not limiting.

[0114] Based on the above, the present application provides a communication method to enable a service invoker to call an API meeting performance requirements to provide services. In an embodiment as shown in FIG. 6, a first device is taken as an execution subject for example. In combination with FIG. 4A or FIG. 4B, the first device can be a core function network element (e.g., a CCF), or a capability exposure gateway, or an external API instance. It can be understood that the above execution subject can also be replaced by a device having a corresponding device function, or a chip, unit or module inside a communication device having a corresponding function.

[0115] Step 600: The first device acquires first information.

[0116] The first information indicates that the first API calls the second API in the process of providing the first service. For example, the first API is an external API, and the second API is an internal API. The first API is used to provide the first service. In the process of providing the first service by the first API, the first API needs to call the second API, that is, the first API has a mapping relationship with the second API, or the first API depends on the second API.

[0117] Exemplarily, the first information comprises information of the first API and information of the second API, wherein the information of the first API comprises an identity of the first API and / or a name of the first API, and the information of the second API comprises an identity of the second API and / or a name of the second API. The identity of the API is a combination of letters, numbers and / or special characters for identifying a specific API, and the name of the API refers to a uniform resource locator (URL) or a uniform resource identifier (URI).

[0118] In a possible implementation, the first information can further indicate that the first API invokes a third API in the process of providing the first service, and a calling sequence of the first API, the second API and the third API. For related content about the calling sequence, refer to the example of FIG. 2B described above.

[0119] The third API is different from the second API, and the third API is also an internal API. That is, the first API can invoke one or more APIs in the process of providing the first service, and when the first API invokes multiple APIs in the process of providing the first service, the first information further indicates a calling sequence of the first API and the multiple APIs, for example, serial, parallel, etc.

[0120] In step 610, the first device obtains a processing delay of the instance of the first API and a processing delay of one or more instances corresponding to the second API according to the first information.

[0121] Exemplarily, the processing delay of the instance of the first API can also be referred to as a response delay or response time of the instance of the first API, wherein the processing delay of the instance of the first API is a delay between receiving a request for invoking the instance of the first API and sending a corresponding request for invoking the instance of the next-hop second API, or a delay between receiving the request for invoking the instance of the first API and giving a response or result of the request. Exemplarily, the processing delay of the instance of the first API can be determined according to a processing time of the instance of the first API for a unit data amount or a data amount processed by the instance of the first API in a unit time. That is, the first device can obtain the processing time of the instance of the first API for a unit data amount or the data amount processed by the instance of the first API in a unit time, and further estimate the processing delay of the instance of the first API according to the processing time or the data amount.

[0122] For example, the unit data amount can be one bite, one byte or 1 MB, and the unit time can be 1 millisecond or 1 second.

[0123] Similarly, the processing latency of the instance of the second API, which can also be referred to as the response latency or response time of the instance of the second API, is the latency between the received invocation request of the instance of the second API and the sending of the corresponding invocation request to the next-hop instance, or the latency between the received request to invoke the instance of the second API and the giving of the response or result of the request.

[0124] For example, the processing latency of the instance of the second API can be determined according to the processing time of the instance of the second API for a unit data amount or the data amount processed by the instance of the second API per unit time. That is, the first device can obtain the processing time of the instance of the second API for a unit data amount or the data amount processed by the instance of the second API per unit time, and further estimate the processing latency of the instance of the second API based on the same.

[0125] For example, the above processing latency can be a specific numerical value, such as 20 ms. Alternatively, the above processing latency can also be a latency range, such as 25 ms-50 ms, etc. Alternatively, the above processing latency can also be latency indication information, such as a number 1 indicating a latency range of 20 ms-30 ms, a number 2 indicating a latency range of 30 ms-40 ms, a letter a indicating a latency range of 20 ms-30 ms, a letter b indicating a latency range of 30 ms-40 ms, etc.

[0126] It can be understood that the first API can correspond to one or more instances, and the second API can correspond to one or more instances. The following will be described by taking the first API corresponding to one instance as an example. When the first API corresponds to multiple instances, the first device can perform the following steps for each instance of the first API, and specific details can be further referred to the related content in the embodiment shown in FIG. 7.

[0127] The following will describe the first device obtaining the processing latency of the instance of the first API and obtaining the processing latency of one or more instances of the second API respectively.

[0128] I. The first device obtains the processing latency of the instance of the first API

[0129] For example, the processing latency of the instance of the first API can be a fixed value. Alternatively, the processing latency of the instance of the first API is a variable value, such as the processing latency of the instance of the first API being the processing latency of the instance of the first API at the last time, or the processing latency of the instance of the first API being the average value of the processing latency of the instance of the first API at the last K times, K being a positive integer.

[0130] In one example, the first device can obtain the first information and the processing delay of the instance of the first API at the same time, without the need to obtain the processing delay of the instance of the first API according to the first information after obtaining the first information. The above example is generally applicable to a scenario where the processing delay of the instance of the first API is a fixed value.

[0131] In another example, the first device can obtain the processing delay of the instance of the first API according to the first information after obtaining the first information. The above example is generally applicable to a scenario where the processing delay of the instance of the first API is a variable value.

[0132] In a possible implementation, the first device can obtain the first information and the processing delay of the instance of the first API from a first network element. The first information and the processing delay of the instance of the first API can be carried in one message or in two different messages, which is not limited in the present application. Exemplarily, the first network element is any one of the instance of the first API, an API publishing function network element, a network storage function network element, and an API storage function network element.

[0133] For example, the instance of the first API can send its processing delay and the first information to the first device.

[0134] For example, the instance of the first API or the independent API publishing function network element sends its processing delay and the first information to the network storage function network element or the API storage function network element. The instance of the first API can read the processing delay that the instance of the first API can guarantee according to the configuration information of the instance (generally, the information in the configuration file provided by the API management system when instantiating the instance of the first API). The API management system can provide one or more instances of the first API with different processing delays according to experience values or statistical values. The API management system can also determine the instances of the first API with different processing delays according to the network status (for example, average network delay, statistical network delay, 99% delay range value) corresponding to the topology position where the instance of the first API is to be deployed, so that the finally determined processing delay performance of the first API meets the end-to-end delay requirement of the service. The independent API publishing function can belong to a part of the API management system. The independent API publishing function has the information of one or more processing delays supported by all instances of the first API, and the independent API publishing function can obtain the information from the API management system or the system administrator preconfigures the information of one or more processing delays to the independent API publishing function in a remote or local manner. The network storage function network element or the API storage function network element stores the first information and the processing delay of the instance of the first API, and can send the first information and the processing delay of the instance of the first API to the first device. In addition, the network storage function network element or the API storage function network element can also store the mapping relationship between other external APIs and internal APIs, and the processing delays of multiple API instances.

[0135] In another possible implementation, the first device can obtain the first information from the first network element, and then obtain the processing delay of the instance of the first API from other network elements. That is, the first device can obtain the first information and the processing delay of the instance of the first API from different network elements respectively.

[0136] For example, the instance of the first API or the API publishing function network element can send the first information to the network storage function network element or the API storage function network element. The network storage function network element or the API storage function network element stores the first information, and can send the first information to the first device, and then the first device obtains the processing delay of the instance of the first API from the instance of the first API according to the first information.

[0137] In a possible design, the processing delay of an instance can be understood as an upper limit of the processing delay of the instance, or in other words, the maximum processing delay of the instance. If the instance cannot guarantee the processing delay, the API management system can be triggered to create a new instance, or the API management system can be triggered to expand the current instance.

[0138] For example, the processing delay of an instance can be determined according to the capability of the instance itself. For example, the instance can determine its processing delay according to the processing time for a unit data amount and the maximum data amount that can be processed, or according to the data amount processed in a unit time and the maximum data amount that can be processed.

[0139] In another possible design, the first device obtains the processing time for a unit data amount or the data amount processed in a unit time of each instance. The first device can estimate the processing delay of each instance according to the estimated data amount provided by the device invoking the first API.

[0140] For example, an instance of the first API can send its processing time for a unit data amount or its data amount processed in a unit time to the first device. An instance of the second API can provide its processing time for a unit data amount or its data amount processed in a unit time when registering with the NRF, and then the NRF can send the processing time for a unit data amount or the data amount processed in a unit time of the instance of the second API to the first device.

[0141] For example, the first device can calculate the processing delay of each instance according to the estimated data amount provided by the device invoking the first API, and the processing time for a unit data amount (or the data amount processed in a unit time) of each instance.

[0142] For example, the processing time for a unit data amount of each instance can be understood as the maximum processing time for a unit data amount of the instance, or the data amount processed in a unit time of each instance can be understood as the minimum data amount processed in a unit time of the instance.

[0143] II. The first device obtains the processing delay of one or more instances of the second API

[0144] For example, the first device can obtain the processing delay of one or more instances of the second API from a second network element according to the first information, where the second network element is a network storage function network element, or an NF management system, or an API management system.

[0145] For example, the first device sends the information of the second API to the second network element according to the first information. For example, the information of the second API includes the identifier of the second API and / or the name of the second API. The second network element queries the processing delay of one or more instances of the second API according to the information of the second API, and sends the processing delay of one or more instances of the second API to the first device. In addition, the second network element can also send other information to the first device, which is not limited in the present application.

[0146] Exemplarily, in the registration process of the instance of the second API, the instance of the second API provides the processing delay of the instance of the second API to the network storage function network element. For example, the instance of the second API can send a registration message to the network storage function network element, and the registration message can include the processing delay of the instance of the second API, and in addition, the registration message can also include the identity of the second API, the name of the second API, the version number of the second API, the communication address of the instance of the second API (for example, the IP address and port number of the instance of the second API), the type of the instance of the second API. The type of the instance of the second API can be a network function instance, a service service instance, a third-party deployed service instance, etc. For example, the network function instance can be denoted as NFx, the service service instance can be denoted as ANFy, and the third-party deployed service instance can be denoted as AFz. Optionally, the registration message can also indicate the service area of the instance of the second API, etc.

[0147] It can be understood that if the first API calls the second API and the third API in the process of providing the first service, the first device also needs to obtain the processing delay of one or more instances corresponding to the third API, which is similar to the above-mentioned first device obtaining the processing delay of one or more instances corresponding to the second API, and will not be described here.

[0148] Step 620: The first device obtains a transmission delay corresponding to each of at least one topology combination, wherein each topology combination includes the instance of the first API and one of the one or more instances corresponding to the second API.

[0149] Exemplarily, the first device can obtain the topology relationship between the instance of the first API and the one or more instances corresponding to the second API, and determine at least one topology combination according to the topology relationship between the instance of the first API and the one or more instances corresponding to the second API. For example, assuming that there is 1 instance of the first API and M instances of the second API, M is a positive integer, then the first device can determine M topology combinations. Each topology combination includes the instance of the first API, but the instances of the second API in different topology combinations are different. Further, the transmission delay corresponding to each topology combination can be determined according to the transmission delay between the instance of the first API and the instance of the second API in the topology combination.

[0150] Example 1, assuming that the first API calls the second API in the process of providing the first service, the instances of the second API include NFx1 and NFx2, and the instance of the first API is denoted as external API instance a, at this time, the following two topology combinations can be formed:

[0151] Topology combination (1) includes: external API instance a, NFx1;

[0152] Examples of the topology combination (2) include: external API instance a, NFx2;

[0153] If the external API instance a and the NFx1 are invoked once respectively, that is, the invocation order of the instances in the topology combination (1) is external API instance a->NFx1, the transmission delay corresponding to the topology combination (1) is the transmission delay between the external API instance a and the NFx1.

[0154] If the invocation order of the instances in the topology combination (1) is external API instance a->NFx1->external API instance a, the transmission delay corresponding to the topology combination (1) is twice the transmission delay between the external API instance a and the NFx1.

[0155] The invocation order of the first API and the second API (or the invocation order of the instances in each topology combination) can be indicated by the first information or configured in advance, which is not limited in the application.

[0156] In addition, in a possible implementation, if the first API invokes the second API and the third API in the process of providing the first service, each topology combination includes an instance of the first API, one of one or more instances corresponding to the second API, and one of one or more instances corresponding to the third API.

[0157] Example 2, assuming that the first API invokes the second API and the third API in the process of providing the first service, the instances of the second API include the NFx1 and the NFx2, the instances of the third API include the ANFy1 and the ANFy2, and the instance of the first API is denoted as external API instance b, at this time, the following four topology combinations can be formed:

[0158] The topology combination (1) includes: external API instance b, NFx1, ANFy1;

[0159] The topology combination (2) includes: external API instance b, NFx1, ANFy2;

[0160] The topology combination (3) includes: external API instance b, NFx2, ANFy1;

[0161] The topology combination (4) includes: external API instance b, NFx2, ANFy2.

[0162] It can be understood that the above four topology combinations are all possible topology combinations, and if the first device can also obtain other parameters about each instance, it can make the number of finally obtained topology combinations less than the number of all possible topology combinations. For example, the service area of ANFy2 is different from the service area of other instances, and the service areas of other instances are the same, then the topology combination including ANFy2 is invalid, that is, topology combination (2) and topology combination (4) are invalid, at this time, the number of finally obtained topology combinations is 2, that is, only topology combination (1) and topology combination (3) are valid. Or the distance between ANFy2 and NFx2 is greater than a preset distance threshold, or the transmission delay between ANFy2 and NFx2 is greater than a preset delay threshold, then topology combination (4) is invalid, at this time, the number of finally obtained topology combinations is 3.

[0163] Further, if the first API calls the second API and the third API in the process of providing the first service, the transmission delay corresponding to each topology combination is not only related to the transmission delay between each instance in the topology combination, but also related to the calling sequence of the first API, the second API and the third API. Or, if the first API calls multiple APIs in the process of providing the first service, the transmission delay corresponding to each topology combination is not only related to the transmission delay between each instance in the topology combination, but also related to the calling sequence of the first API and the multiple APIs.

[0164] For example, if the calling sequence is first API->second API->third API, that is, the first API, the second API and the third API are called in turn, then the transmission delay corresponding to each topology combination can be determined according to the transmission delay between the instance of the first API and the instance of the second API, and the transmission delay between the instance of the second API and the instance of the third API in the topology combination.

[0165] In combination with example 2, if the calling sequence of the instances in topology combination (1) is external API instance b->NFx1->ANFy1, the transmission delay of topology combination (1) is the sum of the transmission delay between external API instance b and NFx1, and the transmission delay between NFx1 and ANFy1.

[0166] For example, if the calling sequence is first API->second API->third API->first API, that is, the first API, the second API, the third API and the first API are called in turn, then the transmission delay corresponding to each topology combination can be determined according to the transmission delay between the instance of the first API and the instance of the second API, the transmission delay between the instance of the second API and the instance of the third API, and the transmission delay between the instance of the third API and the instance of the first API in the topology combination.

[0167] In combination with example 2, if the calling sequence of instances in topology combination (1) is external API instance b -> NFx1 -> ANFy1 -> external API instance b, the transmission delay of topology combination (1) is the sum of the transmission delay between external API instance b and NFx1, the transmission delay between NFx1 and ANFy1, and the transmission delay between external API instance b and ANFy1.

[0168] For example, if the calling sequence is that the first API is called at the same time as the second API and the third API, that is, the second API and the third API are parallel, the transmission delay corresponding to each topology combination can be determined according to the maximum value of the transmission delay between the instance of the first API and the instance of the second API and the transmission delay between the instance of the first API and the instance of the third API in the topology combination.

[0169] In combination with example 2, if the transmission delay between external API instance b and NFx1 is greater than or equal to the transmission delay between external API instance b and ANFy1, the transmission delay of topology combination (1) is the transmission delay between external API instance b and NFx1. If the transmission delay between external API instance b and NFx1 is less than the transmission delay between external API instance b and ANFy1, the transmission delay of topology combination (1) is the transmission delay between external API instance b and ANFy1.

[0170] It should be noted that the transmission delay between any two instances in each topology combination can be understood as the time required for a message to be sent from one instance to be received by another instance. The transmission delay between any two instances can be estimated according to the specific network deployment and / or the transmission medium used between nodes in the network. For example, if instances A and B pass through several hop switches or routers, the transmission delay between instances A and B can be estimated according to prior knowledge or fixed algorithms. For another example, instances A and B are directly connected, and the transmission medium used between instances A and B is an optical fiber, and the transmission delay between instances A and B can be estimated according to the length of the optical fiber.

[0171] In addition, in combination with the load condition of the current network, the transmission delay between instances can also be dynamically updated, for example, when the load increases by X%, the transmission delay between instances increases by Y%, where X and Y are positive numbers.

[0172] The transmission delay between any two instances in each of the above topology combinations can be sent to the first device by a network management device or other device, or configured into the first device by manual means.

[0173] Step 630: The first device determines the latency performance of the first API according to the processing latency of the instance of the first API, the processing latency of one or more instances corresponding to the second API, and the transmission latency corresponding to each of the at least one topology combination.

[0174] In a possible implementation, if the first API invokes the second API in the process of providing the first service, the first device can determine the latency performance of the at least one topology combination according to the processing latency of the instance of the first API, the processing latency of one or more instances corresponding to the second API, and the transmission latency corresponding to each of the at least one topology combination. The latency performance corresponding to each topology combination is determined according to the transmission latency corresponding to the topology combination and the processing latency corresponding to the topology combination, and the processing latency corresponding to the topology combination is determined according to the processing latency corresponding to each instance included in the topology combination.

[0175] For example, if the first API invokes the second API in the process of providing the first service, the transmission latency corresponding to each topology combination can be the transmission latency between the instance of the first API and the instance of the second API in the topology combination. The processing latency corresponding to each topology combination can be the sum of the processing latency of the instance of the first API and the processing latency of the instance of the second API in the topology combination. The latency performance corresponding to each topology combination can be represented by the sum of the transmission latency and the processing latency corresponding to the topology combination. Alternatively, a plurality of latency ranges can be preset in advance, the first device determines the latency range in which the sum of the transmission latency and the processing latency corresponding to each topology combination is located according to the sum of the transmission latency and the processing latency corresponding to each topology combination, and the latency performance corresponding to each topology combination is represented by the latency range in which the sum of the transmission latency and the processing latency corresponding to the topology combination is located. In addition, the latency performance corresponding to each topology combination can also be represented by other manners, which are not limited in the present application.

[0176] Further, when the first device determines the latency performance of the first API according to the latency performance of the at least one topology combination, the latency performance of the first API can indicate part or all of the latency performance of the at least one topology combination.

[0177] For example, assuming that the instance of the first API is 1, and the second API corresponds to M instances, where M is a positive integer, the first device can determine the latency performance corresponding to M topology combinations respectively, where the latency performance corresponding to each topology combination can be represented by the sum of the transmission latency and the processing latency corresponding to the topology combination, and the first device can determine the sum of the transmission latency and the processing latency corresponding to M topology combinations respectively. For convenience of description, the sum of the transmission latency and the processing latency corresponding to M topology combinations is denoted as M latency values respectively in the following. If there are m latency values in the M latency values that do not satisfy the preset condition, for example, there are m latency values in the M latency values that are greater than or equal to the preset threshold, the latency performance of the first API can include M-m latency values, and does not include the m latency values greater than or equal to the preset threshold, where m is a positive integer, and m is less than M. That is, the first device can filter according to the latency performance of at least one topology combination, and exclude the topology combination with larger latency.

[0178] In combination with Example 1, if the calling order of the instances in the topology combination (1) is external API instance a->NFx1, the transmission latency corresponding to the topology combination (1) is the transmission latency between the external API instance a and the NFx1, and the processing latency corresponding to the topology combination (1) is the sum of the processing latency of the external API instance a and the processing latency of the NFx1. The latency performance corresponding to the topology combination (1) can be represented by the sum of the transmission latency and the processing latency corresponding to the topology combination (1). Similarly, the latency performance corresponding to the topology combination (2) can be represented by the sum of the transmission latency and the processing latency corresponding to the topology combination (2). The latency performance of the external API instance a can be two, which are the latency performance corresponding to the topology combination (1) and the latency performance corresponding to the topology combination (2) respectively.

[0179] In addition, if the first API calls the second API and the third API in the process of providing the first service, the first device can obtain the processing latency of one or more instances corresponding to the third API according to the first information, and determine the latency performance of the first API according to the processing latency of the instance of the first API, the processing latency of one or more instances corresponding to the second API, the processing latency of one or more instances corresponding to the third API, and the transmission latency corresponding to at least one topology combination respectively.

[0180] For example, if the first API calls the second API and the third API in the process of providing the first service, the first device can obtain the processing latency of one or more instances corresponding to the third API according to the first information, and then determine the latency performance of the first API according to the processing latency of the instance of the first API, the processing latency of one or more instances corresponding to the second API, the processing latency of one or more instances corresponding to the third API, and the transmission latency corresponding to at least one topology combination respectively.

[0181] In combination with Example 2, if the calling sequence of instances in the topology combination (1) is external API instance b -> NFx1 -> ANFy1, the transmission delay of the topology combination (1) is the sum of the transmission delay between the external API instance b and NFx1, and the transmission delay between NFx1 and ANFy1. The processing delay of the topology combination (1) is the sum of the processing delay of the external API instance b, the processing delay of NFx1, and the processing delay of ANFy1. The delay performance corresponding to the topology combination (1) can be represented by the sum of the transmission delay and the processing delay corresponding to the topology combination (1).

[0182] The delay performance of the external API instance b can be four kinds, which can be represented by the delay performance corresponding to the topology combination (1), the delay performance corresponding to the topology combination (2), the delay performance corresponding to the topology combination (3), and the delay performance corresponding to the topology combination (4). Alternatively, if the delay performance corresponding to the topology combination (2) does not meet the preset condition, for example, the sum of the transmission delay and the processing delay corresponding to the topology combination (2) is greater than or equal to a preset threshold, at this time, the delay performance of the external API instance b can be three kinds, which are the delay performance corresponding to the topology combination (1), the delay performance corresponding to the topology combination (3), and the delay performance corresponding to the topology combination (4).

[0183] Exemplarily, in determining the delay performance of the first API according to the processing delay of the instance of the first API, the processing delay of one or more instances corresponding to the second API, and the transmission delay corresponding to each of the at least one topology combination, the first device can determine the delay performance of the first API according to the processing delay of the instance of the first API, the processing delay of one or more instances corresponding to the second API, the transmission delay corresponding to each of the at least one topology combination, and the transmission delay between the instance of the first API and the first capability exposure gateway, wherein the first capability exposure gateway is the first hop node calling the instance of the first API.

[0184] Alternatively, it can be understood that in addition to the transmission delay corresponding to each of the at least one topology combination and the processing delay of the instances in each topology combination, the first device can also combine the transmission delay between the instance of the first API and the first capability exposure gateway when determining the delay performance of the first API.

[0185] Therefore, before determining the latency performance of the first API, the first device can first determine a capability exposure gateway corresponding to the instance of the first API, i.e., the first capability exposure gateway. Illustratively, the first device can obtain a topological relationship between the at least one capability exposure gateway and the instance of the first API, and select the first capability exposure gateway from the at least one capability exposure gateway according to the topological relationship. In addition, the first device can also jointly determine the first capability gateway in combination with parameters such as a service area of the at least one capability exposure gateway, a service area of the instance of the first API, a service area of one or more instances corresponding to the second API, and the like.

[0186] In combination with Example 1, it is assumed that the capability exposure gateway corresponding to the external API instance a is the capability exposure gateway 1. If the calling order of the instances in the topological combination (1) is external API instance a -> NFx1, the transmission latency corresponding to the topological combination (1) is the transmission latency between the external API instance a and NFx1, and the processing latency corresponding to the topological combination (1) is the sum of the processing latency of the external API instance a and the processing latency of NFx1.

[0187] The latency performance corresponding to the topological combination (1) can be determined based on sequence 1, where sequence 1 is capability exposure gateway 1 -> external API instance a -> NFx1. The latency performance corresponding to the topological combination (1) can be represented as the sum of the transmission latency corresponding to the topological combination (1), the processing latency corresponding to the topological combination (1), and the transmission latency between the external API instance a and the capability exposure gateway 1.

[0188] Alternatively, the latency performance corresponding to the topological combination (1) can be determined based on sequence 2, where sequence 2 is capability exposure gateway 1 -> external API instance a -> NFx1 -> capability exposure gateway 1. The latency performance corresponding to the topological combination (1) can be represented as the sum of the transmission latency corresponding to the topological combination (1), the processing latency corresponding to the topological combination (1), the transmission latency between the external API instance a and the capability exposure gateway 1, and the transmission latency between NFx1 and the capability exposure gateway 1. That is, in a possible implementation, when determining the latency performance of the first API, the first device can also determine the latency performance of a topological combination in combination with the transmission latency between the last called instance in the topological combination and the first capability exposure gateway.

[0189] In combination with example 2, if the capability exposure gateway corresponding to the external API instance b is capability exposure gateway 2, if the calling sequence of the instances in topology combination (1) is external API instance b -> NFx1 -> ANFy1, the transmission delay of topology combination (1) is the sum of the transmission delay between external API instance b and NFx1, and the transmission delay between NFx1 and ANFy1. The processing delay of topology combination (1) is the sum of the processing delay of external API instance b, the processing delay of NFx1, and the processing delay of ANFy1.

[0190] The delay performance corresponding to topology combination (1) can be determined based on sequence 1, where sequence 1 is capability exposure gateway 2 -> external API instance b -> NFx1 -> ANFy1. The delay performance corresponding to topology combination (1) can be represented as the sum of the transmission delay corresponding to topology combination (1), the processing delay corresponding to topology combination (1), and the transmission delay between external API instance b and capability exposure gateway 2.

[0191] Alternatively, the delay performance corresponding to topology combination (1) can be determined based on sequence 2, where sequence 2 is capability exposure gateway 2 -> external API instance b -> NFx1 -> ANFy1 -> capability exposure gateway 2. The delay performance corresponding to topology combination (1) can be represented as the sum of the transmission delay corresponding to topology combination (1), the processing delay corresponding to topology combination (1), the transmission delay between external API instance b and capability exposure gateway 2, and the transmission delay between ANFy1 and capability exposure gateway 2.

[0192] Further, if the first device is a core function network element, the first device can further send a first notification message to the first capability exposure gateway, where the first notification message includes the identifier of the instance of the first API. Alternatively, if the first device is a core function network element or the instance of the first API, after the first device determines the delay performance of the first API, the first device can further send a first notification message to the first capability exposure gateway to indicate the delay performance of the first API. Illustratively, the first notification message can indicate part or all of the delay performance of at least one topology combination corresponding to the delay performance of the first API.

[0193] For example, in combination with example 1, the first notification message indicates one or more of topology combination (1) and the delay performance of topology combination (1), and topology combination (2) and the delay performance of topology combination (2).

[0194] For example, in combination with example 2, the first notification message indicates one or more of topology combination (1) and the delay performance of topology combination (1), topology combination (2) and the delay performance of topology combination (2), topology combination (3) and the delay performance of topology combination (3), and topology combination (4) and the delay performance of topology combination (4).

[0195] If the first device is the first capability exposure gateway or the instance of the first API, the first device can further send a second notification message to the core function network element, the second notification message indicating the latency performance of the first API. Illustratively, the second notification message can indicate part or all of the latency performance of the at least one topology combination corresponding to the latency performance of the first API.

[0196] In a possible implementation, if the first device is the core function network element or the first capability exposure gateway, after determining the latency performance of the instance of the first API, the first device can send configuration information of the instance of the first API to the instance of the first API, the configuration information of the instance of the first API indicating the latency performance of the first API.

[0197] For example, in combination with Example 1, the configuration information of the instance of the first API indicates one or more of the topology combination (1) and the latency performance of the topology combination (1), and the topology combination (2) and the latency performance of the topology combination (2).

[0198] For example, in combination with Example 2, the configuration information of the instance of the first API indicates one or more of the topology combination (1) and the latency performance of the topology combination (1), the topology combination (2) and the latency performance of the topology combination (2), the topology combination (3) and the latency performance of the topology combination (3), and the topology combination (4) and the latency performance of the topology combination (4).

[0199] With the above method, the first device can accurately determine the latency performance of the first API according to the processing latency of the instance of the first API, the processing latency of one or more instances corresponding to the second API, and the transmission latency of the at least one topology combination, wherein the latency performance of the first API can be at least one, i.e., the latency that the first API can guarantee is at least one. Therefore, before the device requesting the first service invokes the first API, the at least one latency that the first API can guarantee has been determined, i.e., the first API can provide multiple optional latency performances for the device requesting the first service, so that the device requesting the first service can invoke the API that meets the latency requirement to provide services for it.

[0200] In a possible scenario, the first device is a core function network element. The first device can discover a capability discovery gateway for a device requesting a first service. The capability discovery gateway can invoke an instance of an API that meets the latency requirement.

[0201] Illustratively, the first device can receive a first request message from a device requesting a first service (e.g., an API invocation entity). The device requesting the first service can also be referred to as a device requesting the first API.

[0202] The first request message is used to request to discover the capability discovery gateway corresponding to the first API. The first request message includes first indication information, and the first indication information indicates a latency requirement for the first API. The latency requirement for the first API can also be understood as an end-to-end latency requirement for the first API, or a latency requirement for the first service. The first indication information indicating the latency requirement for the first API can also be replaced by the first indication information indicating that a device requesting the first API has a latency requirement for the first API, or the first indication information indicating that the device requesting the first API expects a latency performance of the first API, or the first indication information indicating that the device requesting the first API requests a latency performance provided by the first API.

[0203] For example, the first request message includes a name or an identifier of the first API, and the latency requirement for the first API can be a specific value or a latency range, or indication information of the specific value or the latency range. The indication information is agreed by a caller of the first API (i.e., the device requesting the first API) and an operator and / or a provider of the first API before the first API is invoked. For example, the latency requirement of the first service is 50 ms, i.e., the device requesting the first service expects that a maximum latency of the first service is not greater than 50 ms. For another example, the latency requirement of the first service is 30 ms to 50 ms, i.e., the device requesting the first service expects that the latency of the first service is between 30 ms and 50 ms.

[0204] Further, the first device determines the first capability exposure gateway according to the first request message and the latency performance of the first API.

[0205] For example, the first device queries the latency performance of the first API according to the name or the identifier of the first API, and determines whether the latency performance of the first API meets the latency requirement indicated by the first indication information, i.e., determines whether the latency performance of the first API meets the latency requirement of the device requesting the first API for the first API (or the first service), or determines whether the latency performance of the first API meets the latency performance requested by the device requesting the first API for the first API. For example, the first device can determine whether there is a topology combination that meets the latency requirement indicated by the first indication information. If there is a topology combination that meets the latency requirement indicated by the first indication information, the first device determines that a capability exposure gateway corresponding to an instance of the first API in the topology combination is the discovered capability discovery gateway.

[0206] The latency performance of the first API satisfies the latency requirement indicated by the first indication information, that is, the latency performance of the instance of the first API satisfies the latency requirement indicated by the first indication information, or it can also be understood that the latency performance of at least one topology combination satisfies the latency requirement indicated by the first indication information.

[0207] For example, in combination with Example 1 described above, the first device can query the latency performance of the first API according to the name or identifier of the first API, and determine whether there is a topology combination that satisfies the latency requirement indicated by the first indication information, that is, determine whether the latency performance corresponding to the topology combination (1) or the latency performance corresponding to the topology combination (2) satisfies the latency requirement indicated by the first indication information.

[0208] For another example, if the first API corresponds to at least two instances, and the capability exposure gateways corresponding to the at least two instances are different, the first device determines an instance of the at least two instances that satisfies the latency requirement indicated by the first indication information, and takes the capability exposure gateway corresponding to the instance as the discovered capability exposure gateway. For details, refer to the embodiment shown in FIG. 7 described below. At this time, the latency performance of the first API includes the latency performance corresponding to the at least two instances respectively.

[0209] After determining the first capability gateway, the first device can send a first response message to the device requesting the first service. The first response message includes the address of the first capability exposure gateway. The first response message can indicate that the first capability exposure gateway can call the instance of the first API that satisfies the latency requirement indicated by the first indication information.

[0210] In another possible scenario, the first device is the first capability exposure gateway. The first device can accept, process, and / or forward the call request for the device requesting the first API.

[0211] For example, the first device can receive a second request message from the device requesting the first service. The second request message can also be understood as a call request.

[0212] The second request message is used to request to call the first API, or request the first API to provide the first service (or it can be understood as that the second request message is a call message of the first API, or an access message of the first API), and the second request message includes second indication information indicating a latency requirement for the first API. The second indication information is similar to the first indication information, which will not be described herein. For example, the second request message can include the name or identifier of the first API.

[0213] Further, the first capability exposure gateway determines an instance of the first API according to the second request message. For example, the first capability exposure gateway determines the instance of the first API according to the name or identifier of the first API. After determining the instance of the first API, the first capability exposure gateway sends a call request to the instance of the first API. The call request can include third indication information, which is used to determine one or more topology combinations. The third indication information is determined according to the second indication information. Further, the instance of the first API provides the device requesting the first service with the first service.

[0214] For example, if the first capability exposure gateway only knows the identifier of the instance of the first API, but does not know the latency performance of the instance of the first API, the third indication information can indicate the latency requirement for the first API. The third indication information can be the same as the second indication information. Further, the instance of the first API can select a topology combination that meets the latency requirement according to the latency requirement indicated by the third indication information and the configuration information of the instance of the first API, and call according to the instances in the topology combination.

[0215] If the first capability exposure gateway knows the latency performance of the instance of the first API, the first capability exposure gateway can determine a topology combination that meets the latency requirement indicated by the second indication information according to the latency performance of the instance of the first API and the latency requirement indicated by the second indication information. The third indication information can indicate the determined one or more topology combinations, and the latency performance of the one or more topology combinations meets the latency requirement indicated by the second indication information. Further, the instance of the first API calls according to the instances in one of the topology combinations indicated by the third indication information.

[0216] FIGS. 7-9 below are specific flowcharts for determining the latency performance of the first API, which are used to further illustrate the embodiment shown in FIG. 6. In the embodiments shown in FIGS. 7-9, the CCF, the capability exposure gateway, the NRF, and the instance of the first API are taken as examples of the execution subject of the interaction schematic.

[0217] In the embodiment shown in FIG. 7, the CCF corresponds to the first device in the embodiment shown in FIG. 6.

[0218] S701: The instance 1 of the first API sends first information and the processing latency of the instance 1 of the first API to the CCF.

[0219] For example, when the instance 1 of the first API is activated and starts to provide the first service externally, the instance 1 of the first API sends the first information and the processing latency of the instance 1 of the first API to the CCF.

[0220] In addition, S701 can be replaced by that the API publishing function network element can send the first information and processing delays of at least one instance of the first API to the CCF. For example, if instance 1 of the first API and instance 2 of the first API are online at the same time, the API publishing function network element can send the first information, the processing delay of instance 1 of the first API, and the processing delay of instance 2 of the first API to the CCF.

[0221] The first information indicates that the first API calls the second API in the process of providing the first service. For example, the first information includes the name and / or identifier of the first API, and the name and / or identifier of the second API.

[0222] S702: The CCF sends the information of the second API to the NRF.

[0223] Exemplarily, the CCF sends the information of the second API to the NRF according to the first information.

[0224] S703: The NRF sends the processing delay of one or more instances corresponding to the second API to the CCF.

[0225] Exemplarily, the NRF can query the instances of the second API registered to the NRF according to the information of the second API, and send the processing delay of the instances of the second API to the CCF, wherein the instances of the second API provide their own processing delays to the NRF in the registration process. For details, refer to the related content of the first device obtaining the processing delay of one or more instances corresponding to the second API, which will not be described here.

[0226] In addition, the CCF can also send a subscription message to the NRF, and the subscription message is used to subscribe to the information of the instances of the second API, so as to realize that the CCF obtains the latest information of the instances of the second API in time. For example, if the processing delay of a certain instance of the second API is updated, the NRF can send the updated processing delay of the instance of the second API to the CCF. For another example, if the service area of a certain instance of the second API is changed, the NRF can send the updated service area of the instance of the second API to the CCF. For another example, if a new instance of the second API is registered to the NRF, the NRF can send the processing delay of the newly registered instance of the second API to the CCF.

[0227] S704: The CCF selects a first capability exposure gateway for instance 1 of the first API.

[0228] Exemplarily, the CCF selects a first capability exposure gateway from the at least one capability exposure gateway according to a topological relationship between the first API instance 1 and the at least one capability exposure gateway. For example, the CCF can acquire the topological relationship between the first API instance 1 and the at least one capability exposure gateway, and select a capability exposure gateway closest to the first API instance 1 according to the topological relationship, or select a capability exposure gateway with the shortest transmission delay to the first API instance 1 according to the topological relationship. In addition, the CCF can also acquire a service area of the first API instance 1, and service areas respectively corresponding to the at least one capability exposure gateway, to ensure that the service area of the selected capability exposure gateway includes the service area of the first API instance 1. The topological relationship between the first API instance 1 and the at least one capability exposure gateway, the service area of the first API instance 1, and the service areas respectively corresponding to the at least one capability exposure gateway can be acquired from the NRF or other network elements, which are not limited in the present application.

[0229] In addition, if the first API instance 1 and the first API instance 2 are online at the same time, the API publishing function network element sends the first information, the processing delay of the first API instance 1, and the processing delay of the first API instance 2 to the CCF. Similar to the selection of the first capability exposure gateway for the first API instance 1 by the CCF, the CCF can also select a second capability exposure gateway for the first API instance 2. The first capability exposure gateway and the second capability exposure gateway can be the same or different.

[0230] S705: The CCF determines the delay performance of the first API.

[0231] Exemplarily, the CCF determines the delay performance of the first API instance 1 according to the processing delay of the first API instance 1, the processing delay of one or more instances corresponding to the second API, and the transmission delay respectively corresponding to at least one topological combination including the first API instance 1. Or the CCF determines the delay performance of the first API instance 1 according to the processing delay of the first API instance 1, the processing delay of one or more instances corresponding to the second API, the transmission delay respectively corresponding to at least one topological combination including the first API instance 1, and the transmission delay between the first API instance 1 and the first capability exposure gateway, and the delay performance of the first API instance 1 represents part or all of the delay performance respectively corresponding to at least one topological combination including the first API instance 1.

[0232] For details, reference can be made to the above step 630, which will not be described here. The at least one topological combination including the first API instance 1, and the transmission delay respectively corresponding to the at least one topological combination including the first API instance 1 can be acquired from the NRF or other network elements, which are not limited in the present application.

[0233] If the instances of the first API only include the instance 1 of the first API, the latency performance of the instance 1 of the first API is the latency performance of the first API.

[0234] Similarly, if the instances of the first API further include the instance 2 of the first API, the CCF determines the latency performance of the instance 2 of the first API according to the processing latency of the instance 2 of the first API, the processing latencies of one or more instances corresponding to the second API, and the transmission latencies respectively corresponding to at least one topology combination including the instance 2 of the first API. Alternatively, the CCF determines the latency performance of the instance 2 of the first API according to the processing latency of the instance 2 of the first API, the processing latencies of one or more instances corresponding to the second API, the transmission latencies respectively corresponding to at least one topology combination including the instance 2 of the first API, and the transmission latency between the instance 2 of the first API and the second capability exposure gateway. The latency performance of the instance 2 of the first API is used to represent part or all of the latency performance respectively corresponding to at least one topology combination including the instance 2 of the first API.

[0235] At this time, the latency performance of the first API can be two, including the latency performance of the instance 1 of the first API and the latency performance of the instance 2 of the first API.

[0236] S706: The CCF sends a first notification message to the first capability exposure gateway.

[0237] Exemplarily, the first notification message includes the identification of the instance 1 of the first API. Alternatively, the first notification message indicates the latency performance of the instance 1 of the first API.

[0238] Optionally, the CCF sends a second notification message to the second capability gateway, and the second notification message includes the identification of the instance 2 of the first API. Alternatively, the second notification message indicates the latency performance of the instance 2 of the first API.

[0239] S707: The CCF sends the configuration information of the instance 1 of the first API to the instance 1 of the first API.

[0240] Exemplarily, the configuration information of the instance 1 of the first API indicates the latency performance of the instance 1 of the first API.

[0241] Optionally, the CCF sends the configuration information of the instance 2 of the first API to the instance 2 of the first API. The configuration information of the instance 2 of the first API indicates the latency performance of the instance 2 of the first API.

[0242] S708: The AF sends a first request message to the CCF.

[0243] The first request message is used to request the first API to provide the first service, and the first request message includes first indication information indicating a time delay requirement for the first API. For example, the first request message includes a name or an identifier of the first API.

[0244] S709: The CCF determines the first capability exposure gateway according to the first request message.

[0245] For example, the CCF queries the time delay performance of the first API according to the name or the identifier of the first API, determines whether the time delay performance of the first API meets the time delay requirement indicated by the first indication information according to the first indication information, that is, determines whether there is a topology combination meeting the time delay requirement indicated by the first indication information, and if there is a topology combination meeting the time delay requirement indicated by the first indication information, determines that the instance of the first API in the topology combination corresponds to the capability exposure gateway.

[0246] For example, in combination with the above content, the CCF can query the time delay performance of the first API according to the name or the identifier of the first API, and determine whether there is a topology combination meeting the time delay requirement indicated by the first indication information according to the first indication information. Assuming that a topology combination including an instance 1 of the first API meets the topology combination meeting the time delay requirement indicated by the first indication information, the first capability exposure gateway is determined. Assuming that a topology combination including an instance 1 of the second API meets the topology combination meeting the time delay requirement indicated by the first indication information, the second capability exposure gateway is determined. The following only takes the CCF determining the first capability exposure gateway as an example for description.

[0247] S710: The CCF sends a first response message to the AF.

[0248] The first response message includes an address of the first capability exposure gateway.

[0249] S711: The AF sends a second request message to the first capability exposure gateway.

[0250] The second request message is used to request the first API to provide the first service, and the second request message includes second indication information indicating a time delay requirement for the first API. For example, the second request message can include a name or an identifier of the first API.

[0251] S712: The first capability exposure gateway determines an instance 1 of the first API according to the second request message.

[0252] For example, the first capability exposure gateway determines the instance 1 of the first API according to the name or the identifier of the first API.

[0253] S713: The first capability exposure gateway sends a calling request to the instance 1 of the first API, the calling request comprising third indication information, the third indication information being used to determine one or more topology combinations.

[0254] S714: The instance 1 of the first API provides the first service for the AF.

[0255] Exemplarily, if the first notification message in S706 only comprises the identification of the instance of the first API and does not indicate the latency performance of the instance of the first API, the second indication information can indicate the latency requirement for the first API. Further, the instance 1 of the first API can select a topology combination according to the latency requirement indicated by the second indication information and the configuration information of the instance 1 of the first API, and perform calling according to the instances in the topology combination.

[0256] If the first notification message in S706 indicates the latency performance of the instance 1 of the first API, the first capability exposure gateway can determine a topology combination satisfying the latency requirement indicated by the second indication information according to the latency performance of the instance 1 of the first API and the latency requirement indicated by the second indication information. Then, the third indication information can indicate the determined one or more topology combinations, the latency performance of the one or more topology combinations satisfying the latency requirement indicated by the second indication information. Further, the instance 1 of the first API performs calling according to the instances in the topology combination indicated by the third indication information.

[0257] By using the above method, the CCF can accurately determine the latency performance of the first API, and thus, when the AF calls the first API, the CCF can notify the AF of the address of the capability exposure gateway capable of calling the instance of the first API satisfying the latency requirement based on the latency performance of the first API, so that the AF can send a second request message to the capability exposure gateway, and further, the instance of the first API satisfying the latency requirement is called.

[0258] In the embodiment shown in FIG. 8, the first capability gateway corresponds to the first device in the embodiment shown in FIG. 6.

[0259] S801: The instance 1 of the first API sends first information and the processing latency of the instance 1 of the first API to the CCF.

[0260] For details, reference can be made to S701 described above.

[0261] S802: The CCF sends the information of the second API to the NRF.

[0262] Exemplarily, the CCF sends the information of the second API to the NRF according to the first information.

[0263] S803: The NRF sends the processing latency of one or more instances corresponding to the second API to the CCF.

[0264] S703 can be referred to as above.

[0265] S802 and S803 are optional steps.

[0266] S804: The CCF selects a first capability exposure gateway for the instance 1 of the first API.

[0267] S804 can be referred to as above.

[0268] S805: The CCF sends a first notification message to the first capability exposure gateway.

[0269] Exemplarily, the first notification message includes an identifier of the instance 1 of the first API, and in addition, the first notification message further includes the first information, the processing time delay of the instance 1 of the first API, and the processing time delay of one or more instances corresponding to the second API. Alternatively, the first notification message further includes the first information, the first capability exposure gateway can obtain the processing time delay of one or more instances corresponding to the second API from the NRF according to the first information, and the first capability exposure gateway can further obtain the processing time delay of the instance 1 of the first API from the instance 1 of the first API according to the first information.

[0270] Alternatively, S801 to S805 above can be replaced by: the instance 1 of the first API sends the first information and the processing time delay of the instance 1 of the first API to the first capability exposure gateway. The first capability exposure gateway can obtain the processing time delay of one or more instances corresponding to the second API from the NRF according to the first information.

[0271] S806: The first capability exposure gateway determines the time delay performance of the instance 1 of the first API.

[0272] Exemplarily, the first capability exposure gateway determines the time delay performance of the instance 1 of the first API according to the processing time delay of the instance 1 of the first API, the processing time delay of one or more instances corresponding to the second API, and the transmission time delay corresponding to at least one topology combination including the instance 1 of the first API respectively. Alternatively, the first capability exposure gateway determines the time delay performance of the instance 1 of the first API according to the processing time delay of the instance 1 of the first API, the processing time delay of one or more instances corresponding to the second API, the transmission time delay corresponding to at least one topology combination including the instance 1 of the first API respectively, and the transmission time delay between the instance 1 of the first API and the first capability exposure gateway, wherein the time delay performance of the instance 1 of the first API is represented by the time delay performance corresponding to at least one topology combination including the instance 1 of the first API respectively.

[0273] The step 630 can be referred to specifically, and details are not described herein. The at least one topology combination of the instance 1 of the first API and the transmission delay corresponding to the at least one topology combination of the instance 1 of the first API can be obtained from the NRF or other network element, which is not limited in the application.

[0274] S807: The first capability exposure gateway sends the configuration information of the instance 1 of the first API to the instance 1 of the first API.

[0275] For example, the configuration information of the instance 1 of the first API indicates the latency performance of the instance 1 of the first API.

[0276] Optionally, S808: The first capability exposure gateway can also send a second notification message to the CCF, and the second notification message indicates the latency performance of the instance 1 of the first API.

[0277] The application does not limit the order of S807 and S808.

[0278] S809: The AF sends a first request message to the CCF.

[0279] The first request message is used to request the first API to provide the first service, and the first request message includes first indication information, and the first indication information indicates the latency requirement for the first API.

[0280] S810: The CCF determines the first capability exposure gateway according to the first request message.

[0281] If the CCF learns the latency performance of the instance 1 of the first API through S808, the above S709 can be referred to specifically.

[0282] If the CCF does not learn the latency performance of the instance 1 of the first API, the CCF can randomly select a capability exposure gateway.

[0283] S811: The CCF sends a first response message to the AF.

[0284] The first response message includes the address of the first capability exposure gateway.

[0285] S812: The AF sends a second request message to the first capability exposure gateway.

[0286] The second request message is used to request the first API to provide the first service, and the second request message includes second indication information, and the second indication information indicates the latency requirement for the first API. For example, the second request message can include the name or identifier of the first API.

[0287] S813: The first capability exposure gateway determines the instance 1 of the first API according to the second request message.

[0288] If the latency performance of the instance 1 of the first API meets the latency requirement indicated by the second indication information, the method proceeds to S814, otherwise the first capability exposure gateway can notify the AF that the latency performance of the instance 1 of the first API does not meet the latency requirement indicated by the second indication information, and then the AF can request the CCF to find a capability discovery gateway for it again.

[0289] S814: The first capability exposure gateway sends a calling request to the instance 1 of the first API, and the calling request includes third indication information, the third indication information being used to determine one of the at least one topology combination.

[0290] Exemplarily, the first capability exposure gateway can determine the topology combination meeting the latency requirement indicated by the second indication information according to the latency performance of the instance 1 of the first API and the latency requirement indicated by the second indication information, and then the third indication information can indicate one or more topology combinations, and the latency performance of the one or more topology combinations meets the latency requirement indicated by the second indication information. Or the third indication information can be the same as the second indication information.

[0291] S815: The instance 1 of the first API provides the first service for the AF.

[0292] If the third indication information indicates one or more topology combinations, the instance 1 of the first API determines one of the topology combinations, and calls according to the instances in the topology combination.

[0293] Or the third indication information is the same as the second indication information, and indicates the latency requirement for the first API. Then the instance 1 of the first API can select the topology combination meeting the latency requirement indicated by the third indication information according to the latency requirement indicated by the third indication information and the configuration information of the instance 1 of the first API, and call according to the instances in the topology combination.

[0294] By using the above method, the first capability exposure gateway can accurately determine the latency performance of the instance 1 of the first API, and thus the first capability exposure gateway can determine whether the instance 1 of the first API meets the latency requirement, and if so, the first capability exposure gateway sends a calling request to the instance 1 of the first API, and thus the AF can call the instance of the first API meeting the latency requirement.

[0295] In the embodiment shown in FIG. 9, the instance 1 of the first API corresponds to the first device in the embodiment shown in FIG. 6.

[0296] S901: The instance 1 of the first API sends first information to the CCF.

[0297] For details, refer to S701 described above.

[0298] S902: The CCF selects a first capability exposure gateway for the instance 1 of the first API.

[0299] The above S704 can be referred to specifically.

[0300] S903: The CCF sends information of the first capability exposure gateway to the instance 1 of the first API.

[0301] Exemplarily, the information of the first capability exposure gateway includes an identifier or an address of the first capability exposure gateway.

[0302] S904: The instance 1 of the first API sends information of the second API to the NRF.

[0303] Exemplarily, the instance 1 of the first API sends the information of the second API to the NRF according to the first information.

[0304] S905: The NRF sends a processing delay of one or more instances corresponding to the second API to the instance 1 of the first API.

[0305] Exemplarily, the NRF can query the instances of the second API registered to the NRF according to the information of the second API, and send the processing delay of the instances of the second API to the instance 1 of the first API.

[0306] The present application does not limit the order of S901 and S904.

[0307] S906: The instance 1 of the first API determines the latency performance of the first API.

[0308] Exemplarily, the instance 1 of the first API determines the latency performance of the instance 1 of the first API according to the processing delay of the instance 1 of the first API, the processing delay of one or more instances corresponding to the second API, and the transmission delay corresponding to at least one kind of topology combination including the instance 1 of the first API respectively. Or the instance 1 of the first API determines the latency performance of the instance 1 of the first API according to the processing delay of the instance 1 of the first API, the processing delay of one or more instances corresponding to the second API, the transmission delay corresponding to at least one kind of topology combination including the instance 1 of the first API respectively, and the transmission delay between the instance 1 of the first API and the first capability exposure gateway, wherein the latency performance of the instance 1 of the first API is represented by the latency performance corresponding to at least one kind of topology combination including the instance 1 of the first API respectively. The above step 630 can be referred to specifically, and will not be described here. The at least one kind of topology combination including the instance 1 of the first API, and the transmission delay corresponding to at least one kind of topology combination including the instance 1 of the first API respectively can be obtained from the NRF or other network elements, which is not limited by the present application.

[0309] S907: The instance 1 of the first API sends a first notification message to the first capability gateway.

[0310] Exemplarily, the first notification message comprises an identity of the instance 1 of the first API. Alternatively, the first notification message indicates the latency performance of the instance 1 of the first API.

[0311] Optionally, S908: The instance 1 of the first API sends a second notification message to the CCF, the second notification message indicating the latency performance of the instance 1 of the first API.

[0312] The present application does not limit the order of S907 and S908.

[0313] S909: The AF sends a first request message to the CCF.

[0314] The first request message is used to request the first API to provide the first service, and the first request message comprises first indication information, the first indication information indicating the latency requirement for the first API.

[0315] S910: The CCF determines the first capability exposure gateway according to the first request message.

[0316] If the CCF learns the latency performance of the instance 1 of the first API through S908, refer to S709 above for details.

[0317] If the CCF does not learn the latency performance of the instance 1 of the first API, the CCF can randomly select a capability exposure gateway.

[0318] S911: The CCF sends a first response message to the AF.

[0319] The first response message comprises an address of the first capability exposure gateway.

[0320] S912: The AF sends a second request message to the first capability exposure gateway.

[0321] The second request message is used to request the first API to provide the first service, and the second request message comprises second indication information, the second indication information indicating the latency requirement for the first API. Exemplarily, the second request message can comprise a name or an identity of the first API.

[0322] S913: The first capability exposure gateway determines the instance 1 of the first API according to the second request message.

[0323] If the first capability exposure gateway only learns the identity of the instance 1 of the first API through S907, continue to perform S914. The invocation request in S914 comprises third indication information, which can be the same as the second indication information.

[0324] If the first capability exposure gateway learns the latency performance of the instance 1 of the first API through S907, it can determine whether the latency performance of the instance 1 of the first API meets the latency requirement indicated by the second indication information. If yes, it continues to perform S914. The invocation request in S914 includes the third indication information. The third indication information can indicate one or more topology combinations, and the latency performance of each topology combination meets the latency requirement indicated by the second indication information. Otherwise, the first capability exposure gateway can notify the AF that the latency performance of the instance 1 of the first API does not meet the latency requirement indicated by the second indication information, and then the AF can request the CCF to find a capability exposure gateway for it.

[0325] S914: The first capability exposure gateway sends an invocation request to the instance 1 of the first API. The invocation request includes the third indication information.

[0326] S915: The instance 1 of the first API provides the first service for the AF.

[0327] If the third indication information indicates one or more topology combinations, the instance 1 of the first API determines one of the topology combinations and invokes the instances in the topology combination.

[0328] Or the third indication information is the same as the second indication information, which indicates the latency requirement for the first API. Then, the instance 1 of the first API can select a topology combination that meets the latency requirement indicated by the third indication information according to the latency requirement indicated by the third indication information and the configuration information of the instance 1 of the first API, and invoke the instances in the topology combination.

[0329] By using the above method, the instance 1 of the first API can accurately determine the latency performance of itself. Therefore, the instance 1 of the first API can determine whether itself meets the latency requirement. If yes, it provides the first service for the AF, and then the AF can invoke the instance of the first API that meets the latency requirement.

[0330] The application further provides a communication method, which enables a service invoker to invoke an API that meets a performance requirement to provide a service for it. In an embodiment as shown in FIG. 10, a first device is taken as an execution subject for example. In combination with the above-mentioned FIG. 4A or FIG. 4B, the first device can be a core function network element (for example, a CCF) or a chip in the core function network element. It can be understood that the above-mentioned execution subject can also be replaced by a device with corresponding device functions, or a chip, unit or module in a communication device with corresponding functions.

[0331] Step 1000: The first device acquires a topology relationship between at least one capability exposure gateway and an instance of a first API.

[0332] The topology relationship between the instance of the first API and the at least one capability exposure gateway can be obtained from the NRF or other network element, which is not limited in the application.

[0333] Step 1010: The first device selects a first capability exposure gateway from the at least one capability exposure gateway according to the topology relationship, wherein the first capability exposure gateway is a first hop node of the instance of the first API.

[0334] For example, the first device can select the capability exposure gateway closest to the instance of the first API according to the topology relationship, or select the capability exposure gateway with the shortest transmission delay to the instance of the first API according to the topology relationship. In addition, the first device can also obtain the service area of the instance of the first API and the service area corresponding to each of the at least one capability exposure gateway, so as to ensure that the service area of the selected capability exposure gateway includes the service area of the instance of the first API. The service area of the instance of the first API and the service area corresponding to each of the at least one capability exposure gateway can be obtained from the NRF or other network element, which is not limited in the application.

[0335] Step 1020: The first device obtains the processing delay of the instance of the first API.

[0336] The processing delay of the instance of the first API is the delay from receiving the request for invoking the instance of the first API to giving the response or result of the request.

[0337] For example, the first device can obtain the processing delay of the instance of the first API from the first network element, which is any one of the instance of the first API, the API publishing function network element, the network storage function network element, and the API storage function network element.

[0338] In addition, how the first device obtains the processing delay of the instance of the first API can refer to the related content in the above step 610, which will not be repeated here.

[0339] Step 1030: The first device determines the delay performance of the instance of the first API according to the processing delay of the instance of the first API and the transmission delay between the instance of the first API and the first capability exposure gateway.

[0340] For example, the delay performance of the instance of the first API can be represented as the sum of the processing delay of the instance of the first API and the transmission delay between the instance of the first API and the first capability exposure gateway, or the sum of the processing delay of the instance of the first API and twice the transmission delay between the instance of the first API and the first capability exposure gateway.

[0341] Exemplarily, the first device can further send a notification message to the first capability exposure gateway, the notification message comprising an identifier of the instance of the first API, or the notification message indicating the latency performance of the instance of the first API.

[0342] The subsequent discovery of the capability exposure gateway and the process of invoking the first API are similar to the embodiment shown in FIG. 6, and will not be described herein.

[0343] By using the above method, the first device can accurately determine the latency performance of the first API according to the processing latency of the instance of the first API and the transmission latency between the instance of the first API and the first capability exposure gateway, wherein the latency performance of the first API can be at least one, that is, the first API can guarantee at least one latency. Therefore, before the device requesting the first service invokes the first API, at least one latency that can be guaranteed by the first API has been determined, that is, the first API can provide multiple optional latency performances for the device requesting the first service, so that the device requesting the first service can invoke the API meeting the latency requirement to provide services. The method can be generally applicable to the scenario where the first API does not depend on other APIs.

[0344] It can be understood that, in order to implement the functions in the above embodiments, each communication device comprises a hardware structure and / or a software module for performing each function. Those skilled in the art should easily realize that, in combination with the units and method steps of each example described in the embodiments disclosed in the present application, the present application can be realized in the form of hardware or a combination of hardware and computer software. Whether a certain function is executed by hardware or computer software driven hardware depends on the specific application scenario and design constraints of the technical solution.

[0345] FIGS. 11 and 12 are structural schematic diagrams of possible communication devices provided by embodiments of the present application. These communication devices can be used to implement the functions of each communication device in the above method embodiments, and thus can also achieve the beneficial effects possessed by the above method embodiments.

[0346] As shown in FIG. 11, the communication device 1100 comprises a processing unit 1110 and a transceiver unit 1120.

[0347] When the communication device 1100 is used to implement the functions of the first device (for example, the CCF, the first capability exposure gateway, or the instance 1 of the first API) in the above embodiments shown in FIGS. 6 to 9, the processing unit 1110 is configured to:

[0348] The transceiver 1120 is configured to obtain first information, the first information indicating that a first API invokes a second API in a process of providing a first service; obtain a processing time delay of an instance of the first API and processing time delays of one or more instances corresponding to the second API according to the first information; and obtain transmission time delays respectively corresponding to at least one topology combination, where each topology combination includes one of the instance of the first API and the one or more instances corresponding to the second API.

[0349] The processing unit 1110 is configured to determine a time delay performance of the first API according to the processing time delay of the instance of the first API, the processing time delays of the one or more instances corresponding to the second API, and the transmission time delays respectively corresponding to the at least one topology combination.

[0350] In a possible design, the processing unit 1110 is configured to, when determining the time delay performance of the first API according to the processing time delay of the instance of the first API, the processing time delays of the one or more instances corresponding to the second API, and the transmission time delays respectively corresponding to the at least one topology combination, determine the time delay performance of the first API according to the processing time delay of the instance of the first API, the processing time delays of the one or more instances corresponding to the second API, the transmission time delays respectively corresponding to the at least one topology combination, and a transmission time delay between the instance of the first API and a first capability exposure gateway, where the first capability exposure gateway is a first hop node that invokes the instance of the first API.

[0351] In a possible design, the transceiver 1120 is further configured to obtain a topology relationship between at least one capability exposure gateway and the instance of the first API, and the processing unit 1110 is further configured to select the first capability exposure gateway from the at least one capability exposure gateway according to the topology relationship.

[0352] In a possible design, the transceiver 1120 is configured to send a first notification message to the first capability exposure gateway, where the first notification message includes an identifier of the instance of the first API, or the first notification message indicates the time delay performance of the first API.

[0353] In a possible design, the transceiver 1120 is configured to send a second notification message to a core function network element, where the second notification message indicates the time delay performance of the first API. Correspondingly, the core function network element receives the second notification message from the first device.

[0354] In a possible design, the transceiver 1120 is configured to send configuration information of the instance of the first API to the instance of the first API, where the configuration information of the instance of the first API indicates latency performance of the first API.

[0355] In a possible design, the first information further indicates that the first API invokes a third API in providing the first service, and a calling sequence of the first API, the second API, and the third API; each topology combination includes the instance of the first API, one of one or more instances corresponding to the second API, and one of one or more instances corresponding to the third API; and a transmission latency corresponding to each topology combination is determined according to the calling sequence and transmission latencies between instances in the topology combination.

[0356] In a possible design, the processing unit 1110 is further configured to, when determining the latency performance of the first API according to the processing latency of the instance of the first API, the processing latency of the one or more instances corresponding to the second API, and the transmission latency corresponding to the at least one topology combination, acquire, according to the first information, the processing latency of the one or more instances corresponding to the third API; and determine the latency performance of the first API according to the processing latency of the instance of the first API, the processing latency of the one or more instances corresponding to the second API, the processing latency of the one or more instances corresponding to the third API, and the transmission latency corresponding to the at least one topology combination.

[0357] In a possible design, the processing unit 1110 is further configured to, when determining the latency performance of the first API according to the processing latency of the instance of the first API, the processing latency of the one or more instances corresponding to the second API, and the transmission latency corresponding to the at least one topology combination, determine latency performance of the at least one topology combination according to the processing latency of the instance of the first API, the processing latency of the one or more instances corresponding to the second API, and the transmission latency corresponding to the at least one topology combination; where the latency performance corresponding to each topology combination is determined according to the transmission latency corresponding to the topology combination and processing latency corresponding to the topology combination, the processing latency corresponding to the topology combination is determined according to the processing latency corresponding to each instance included in the topology combination, and the latency performance of the first API is determined according to the latency performance of the at least one topology combination.

[0358] In a possible design, the transceiver 1120 is further configured to receive a first request message, where the first request message is used to request to discover a capability discovery gateway corresponding to the first API, and the first request message includes first indication information, where the first indication information indicates a latency requirement for the first API; the processor 1110 is further configured to determine a first capability exposure gateway according to the first request message and a latency performance of the first API, where the first capability exposure gateway is a first-hop function node of an instance of the first API, and the latency performance of the instance of the first API meets the latency requirement indicated by the first indication information; and the transceiver 1120 is further configured to send a first response message, where the first response message includes an address of the first capability exposure gateway.

[0359] In a possible design, the transceiver 1120 is further configured to receive a second request message, where the second request message is used to request to invoke the first API, and the second request message includes second indication information, where the second indication information indicates a latency requirement for the first API; the processor 1110 is further configured to determine the instance of the first API according to the second request message; and the transceiver 1120 is further configured to send an invocation request to the instance of the first API, where the invocation request includes third indication information, and the third indication information is used to determine one of the at least one topology combination, and the third indication information is determined according to the second indication information.

[0360] In a possible design, the transceiver 1120 is configured to acquire the first information from a first network element when the first information is acquired, and the first network element is any one of the following: the instance of the first API, an API publishing function network element, a network storage function network element, or an API storage function network element.

[0361] In a possible design, the transceiver 1120 is configured to acquire, from the first network element, a processing latency of the instance of the first API.

[0362] In a possible design, the transceiver 1120 is configured to acquire, from a second network element, a processing latency of one or more instances corresponding to the second API, and the second network element is any one of the following: a network storage function network element, a network function (NF) management system, or an API management system.

[0363] In a possible design, the processing latency of the instance of the first API is a latency between a received request for invoking the instance of the first API and sending of a corresponding invocation request to a next-hop instance of a second API, or a latency between the received request for invoking the instance of the first API and giving of a response or result of the request.

[0364] When the communication apparatus 1100 is used to implement functions of the first device in the embodiment shown in FIG. 10, the following processing is performed:

[0365] The transceiver 1120 is configured to: obtain a topology relationship between at least one capability exposure gateway and an instance of a first API; select a first capability exposure gateway from the at least one capability exposure gateway according to the topology relationship, where the first capability exposure gateway is a first-hop node for invoking the instance of the first API; and obtain a processing latency of the instance of the first API.

[0366] The processing unit 1110 is configured to determine a latency performance of the instance of the first API according to the processing latency of the instance of the first API and a transmission latency between the instance of the first API and the first capability exposure gateway.

[0367] In a possible design, the transceiver 1120 is configured to send a notification message to the first capability exposure gateway, where the notification message includes an identifier of the instance of the first API, or the notification message indicates the latency performance of the instance of the first API.

[0368] In a possible design, the transceiver 1120 is configured to obtain the processing latency of the instance of the first API from a first network element when obtaining the processing latency of the instance of the first API, where the first network element is any one of the instance of the first API, an API publishing function network element, a network storage function network element, or an API storage function network element.

[0369] In a possible design, the processing latency of the instance of the first API is a latency between a received request for invoking the instance of the first API and giving of a response or result of the request.

[0370] For more details of the processing unit 1110 and the transceiver 1120, refer to the related description in the method embodiments.

[0371] As shown in FIG. 12, the communication apparatus 1200 includes a processor 1210 and an interface circuit 1220. The processor 1210 and the interface circuit 1220 are coupled with each other. It can be understood that the interface circuit 1220 can be a transceiver or an input / output interface. Optionally, the communication apparatus 1200 can further include a memory 1230, used for storing instructions executed by the processor 1210 or storing input data required by the processor 1210 to execute instructions or storing data generated by the processor 1210 after executing instructions.

[0372] When the communication apparatus 1200 is used to implement the method embodiments described above, the processor 1210 is configured to implement the functions of the processing unit 1110 described above, and the interface circuit 1220 is configured to implement the functions of the transceiver unit 1120 described above.

[0373] It can be understood that the processor in the embodiments of the present application can be a central processing unit (CPU), and can also be other general-purpose processors, digital signal processors (DSP), application specific integrated circuits (ASIC), field programmable gate arrays (FPGA) or other programmable logic devices, transistor logic devices, hardware components or any combination thereof. The general-purpose processor can be a microprocessor or any conventional processor.

[0374] In the present application, another example of providing an apparatus is provided, the notification apparatus includes at least one processor and at least one memory, the at least one processor and the at least one memory are coupled, the at least one memory is used for storing instructions, when the instructions are executed by the at least one processor, the communication apparatus executes the method in the embodiments described above. Taking an example of a communication apparatus including one processor and one memory, as shown in FIG. 12, the communication apparatus 1200 includes one processor 1210 and one memory 1230. The processor 1210 and the memory 1230 are coupled, and the memory 1230 stores instructions, when the instructions stored in the memory 1230 are executed by the processor 1210, the communication apparatus 1200 executes the method executed by each communication apparatus in the embodiments described above.

[0375] The method steps in the embodiments of the present application can be implemented in hardware or in software instructions executable by a processor. The software instructions can be composed of corresponding software modules, which can be stored in a random access memory, a flash memory, a read-only memory, a programmable read-only memory, an erasable programmable read-only memory, an electrically erasable programmable read-only memory, a register, a hard disk, a mobile hard disk, a CD-ROM, or any other form of storage medium well known in the art. An exemplary storage medium is coupled to the processor, so that the processor can read information from and write information to the storage medium. The storage medium can also be an integral part of the processor. The processor and the storage medium can be located in an ASIC. In addition, the ASIC can be located in the terminal or the access network device described above. The processor and the storage medium can also exist as discrete components in the terminal or the access network device.

[0376] In the above embodiments, the implementation can be entirely or partially achieved by software, hardware, firmware, or any combination thereof. When implemented by software, the implementation can be entirely or partially in the form of a computer program product. The computer program product includes one or more computer programs or instructions. When the computer programs or instructions are loaded and executed on a computer, the processes or functions described in the embodiments of the present application are entirely or partially performed. The computer can be a general-purpose computer, a special-purpose computer, a computer network, a network device, a user equipment, or other programmable devices. The computer programs or instructions can be stored in a computer-readable storage medium or transferred from one computer-readable storage medium to another, for example, the computer programs or instructions can be transferred from one website, computer, server, or data center to another by wire or wirelessly. The computer-readable storage medium can be any available medium accessible by a computer or a data storage device such as a server, data center, etc. integrated with one or more available media. The available media can be a magnetic medium, such as a floppy disk, a hard disk, a magnetic tape; an optical medium, such as a digital video disc; and a semiconductor medium, such as a solid-state disk. The computer-readable storage medium can be a volatile or non-volatile storage medium, or can include both volatile and non-volatile storage media.

[0377] In various embodiments of the present application, the terms and / or descriptions of different embodiments are consistent and can be mutually referred to if there is no special description and no logical conflict. The technical features in different embodiments can be combined to form new embodiments according to their inherent logical relationship.

[0378] In the present application, "at least one" means one or more, "multiple" means two or more. The "and / or" describes the relationship between the associated objects, which means that there can be three kinds of relationships, for example, A and / or B, which can represent: A exists alone, A and B exist together, B exists alone, where A, B can be singular or plural. In the text description of the present application, the character " / ", generally indicates that the associated objects before and after are in an "or" relationship; in the formula of the present application, the character " / ", indicates that the associated objects before and after are in a "division" relationship. "Including at least one of A, B and C" can mean: including A; including B; including C; including A and B; including A and C; including B and C; including A, B and C.

[0379] It can be understood that various numerical numbers involved in the embodiments of the present application are only distinguished for convenience of description, and are not used to limit the scope of the embodiments of the present application. The size of the serial number of the above processes does not mean the order of execution, and the execution order of the processes should be determined according to its function and inherent logic.

Claims

1. A communication method characterized by comprising: The method is applied to a first device, and the method comprises: obtaining first information, the first information indicating that a first application programming interface (API) calls a second API in a process of providing a first service; obtaining a processing time delay of an instance of the first API and processing time delays of one or more instances corresponding to the second API according to the first information; obtaining transmission time delays respectively corresponding to at least one topology combination, wherein each topology combination comprises one of the instance of the first API and one of the one or more instances corresponding to the second API; determining a time delay performance of the first API according to the processing time delay of the instance of the first API, the processing time delays of the one or more instances corresponding to the second API, and the transmission time delays respectively corresponding to the at least one topology combination.

2. The method of claim 1, wherein, The determining of the time delay performance of the first API according to the processing time delay of the instance of the first API, the processing time delays of the one or more instances corresponding to the second API, and the transmission time delays respectively corresponding to the at least one topology combination comprises: determining the time delay performance of the first API according to the processing time delay of the instance of the first API, the processing time delays of the one or more instances corresponding to the second API, the transmission time delays respectively corresponding to the at least one topology combination, and a transmission time delay between the instance of the first API and a first capability exposure gateway, wherein the first capability exposure gateway is a first hop node calling the instance of the first API.

3. The method of claim 2, wherein, The first device is a core function network element, and the method further comprises: obtaining a topology relationship between at least one capability exposure gateway and the instance of the first API; selecting the first capability exposure gateway from the at least one capability exposure gateway according to the topology relationship.

4. The method of claim 3, wherein, The method further comprises: sending a first notification message to the first capability exposure gateway, the first notification message comprising an identifier of the instance of the first API, or the first notification message indicating the time delay performance of the first API.

5. The method of claim 2, wherein, The first device is the first capability exposure gateway, and the method further comprises: sending a second notification message to a core function network element, the second notification message indicating the time delay performance of the first API.

6. The method according to any one of claims 2 to 5, wherein, The first device is the core function network element or the first capability exposure gateway, and the method further comprises: sending configuration information of the instance of the first API to the instance of the first API, the configuration information of the instance of the first API indicating the time delay performance of the first API.

7. The method according to any one of claims 1 to 6, wherein The first information further indicates that the first API calls a third API in the process of providing the first service, and a calling sequence of the first API, the second API and the third API; each topology combination comprises one of the instance of the first API, one of the one or more instances corresponding to the second API, and one of one or more instances corresponding to the third API; the transmission time delay corresponding to each topology combination is determined according to the calling sequence and transmission time delays between the instances in the topology combination.

8. The method of claim 7, wherein, determining the latency performance of the first API according to the processing latency of the instance of the first API, the processing latency of one or more instances corresponding to the second API, and the transmission latency corresponding to the at least one topology combination respectively, comprises: obtaining the processing latency of one or more instances corresponding to the third API according to the first information; determining the latency performance of the first API according to the processing latency of the instance of the first API, the processing latency of one or more instances corresponding to the second API, the processing latency of one or more instances corresponding to the third API, and the transmission latency corresponding to the at least one topology combination respectively.

9. The method according to any one of claims 1 to 8, wherein, determining the latency performance of the first API according to the processing latency of the instance of the first API, the processing latency of one or more instances corresponding to the second API, and the transmission latency corresponding to the at least one topology combination respectively, comprises: determining the latency performance of the at least one topology combination according to the processing latency of the instance of the first API, the processing latency of one or more instances corresponding to the second API respectively, and the transmission latency corresponding to the at least one topology combination respectively; wherein the latency performance corresponding to each topology combination is determined according to the transmission latency corresponding to the topology combination and the processing latency corresponding to the topology combination, and the processing latency corresponding to the topology combination is determined according to the processing latency corresponding to each instance included in the topology combination respectively; determining the latency performance of the first API according to the latency performance of the at least one topology combination.

10. The method of any one of claims 1-4, 6-9, wherein, The first device is a core function network element, and the method further comprises: receiving a first request message, the first request message being used to request to discover a capability exposure gateway corresponding to the first API, the first request message comprising first indication information, the first indication information indicating a latency requirement for the first API; determining a first capability exposure gateway according to the first request message and the latency performance of the first API, the first capability exposure gateway being a first-hop function node of an instance of the first API, and the latency performance of the instance of the first API meeting the latency requirement indicated by the first indication information; sending a first response message, the first response message comprising an address of the first capability exposure gateway.

11. The method of any one of claims 1-2, 5-9, wherein, The first device is the first capability exposure gateway, and the method further comprises: receiving a second request message, the second request message being used to request to invoke the first API, the second request message comprising second indication information, the second indication information indicating a latency requirement for the first API; determining an instance of the first API according to the second request message; sending an invocation request to the instance of the first API, the invocation request comprising third indication information, the third indication information being used to determine one of the at least one topology combination, and the third indication information being determined according to the second indication information.

12. The method of any one of claims 1-11, wherein, obtaining first information, comprising: The first information is obtained from a first network element, and the first network element is any one of an instance of the first API, an API publishing function network element, a network storage function network element, or an API storage function network element.

13. The method of claim 12, wherein, The method further includes: The processing delay of the instance of the first API is obtained from the first network element.

14. The method of any one of claims 1-13, wherein, The method further includes: The processing delay of one or more instances of the second API is obtained from a second network element, and the second network element is a network storage function network element, or a network function (NF) management system, or an API management system.

15. The method of any one of claims 1-14, wherein, The processing delay of the instance of the first API is a delay between a received request for invoking the instance of the first API and sending of a corresponding invocation request to a next-hop instance of a second API, or a delay between the received request for invoking the instance of the first API and giving of a response or result of the request. The processing delay of the instance of the second API is a delay between a received invocation request of the instance of the second API and sending of a corresponding invocation request to a next-hop instance, or a delay between the received request for invoking the instance of the second API and giving of a response or result of the request.

16. A method of communication, comprising: The method includes: Obtaining a topology relationship between at least one capability exposure gateway and an instance of a first API; Selecting a first capability exposure gateway from the at least one capability exposure gateway according to the topology relationship, wherein the first capability exposure gateway is a first-hop node for invoking the instance of the first API; Obtaining a processing delay of the instance of the first API; Determining a delay performance of the instance of the first API according to the processing delay of the instance of the first API and a transmission delay between the instance of the first API and the first capability exposure gateway.

17. The method of claim 16, wherein, The method further includes: Sending a notification message to the first capability exposure gateway, and the notification message includes an identifier of the instance of the first API, or the notification message indicates the delay performance of the instance of the first API.

18. The method of claim 16 or 17, wherein, The processing delay of the instance of the first API is obtained from a first network element, and the first network element is any one of the instance of the first API, an API publishing function network element, a network storage function network element, or an API storage function network element. The processing delay of the instance of the first API is a delay between a received request for invoking the instance of the first API and giving of a response or result of the request.

19. The method of any one of claims 16-18, wherein, The apparatus includes a unit or module for performing the method of any one of claims 1 to 19.

20. A communications device, characterized by The communication apparatus includes at least one processor, and the at least one processor is configured to perform the method of any one of claims 1 to 19.

21. A communications device, characterized by The computer readable storage medium includes a program, and when the program is executed on the apparatus, the apparatus is caused to perform the method of any one of claims 1 to 19.

22. A computer-readable storage medium, characterized in that, The computer program product includes a program or instructions, and when the program or instructions are executed by the apparatus, the apparatus is caused to perform the method of any one of claims 1 to 19.

23. A computer program product, characterised in that, ​

Citation Information

Patent Citations

  • Method and device for calling application program interface

    CN111435924A

  • Wireless data packet aggregation sending method, electronic equipment thereof and medium

    CN114641035A

  • Calling request processing method and device, computer equipment and storage medium

    CN116860480A

  • Intelligent API consumption

    US20230185645A1

  • Using an application programming interface (API) gateway to manage communications in a distributed system

    US20230344707A1