Cloud-native API Gateway supports the following types of service sources: Container Service for Kubernetes (ACK) clusters, ACK Serverless (ASK) clusters, and Microservices Engine (MSE) Nacos instances. This topic describes how to add an ACK cluster in which backend services are deployed or an MSE Nacos instance with which backend services are registered as a service source. The service source can help Cloud-native API Gateway instances dynamically obtain your backend service list.
Configuration
If a service source that you configured becomes invalid, manually delete the service source. Otherwise, instability issues may occur. For example, synchronization of service information from other sources may be delayed.
You can add a Domain Name System (DNS) domain name or a fixed address as a service without the need to configure a service source. For more information, see Create a service.
If you add an ACK or ASK cluster as a service source for a Cloud-native API Gateway instance, the Cloud-native API Gateway instance monitors the services and endpoints of the ACK or ASK cluster to obtain the related information. If you configure HTTPS requests for a Cloud-native API Gateway instance based on Ingress resources in Kubernetes clusters, the Cloud-native API Gateway instance also needs to monitor cluster secrets to obtain information about HTTPS certificates.
Procedure
Log on to the Cloud-native API Gateway console.
In the left-side navigation pane, click Instance. In the top navigation bar, select a region.
On the Instance page, click the name of the gateway instance that you want to manage.
In the left-side navigation tree, click Service. Then, click the Source tab.
Click Create Source. In the Create Source panel, configure the parameters and click OK.
Add an ACK cluster as a service source
Parameter
Description
ACK/ACK Serverless Cluster
Select the cluster in which your backend service is deployed.
NoteWhen you create a gateway, you need to select the virtual private cloud (VPC) in which the cluster is deployed. This way, when you add a service source, the cluster in this VPC is automatically obtained.
Security Group Rules
Security groups are configured in the node pool of the ACK cluster. In most cases, if an external component wants to access a service in the cluster, you must expose all ports required by the service in the security groups.
You can modify security groups. For more information, see Configure security group rules.
Add an MSE Nacos instance as a service source
Parameter
Description
Nacos Instance
Select an instance.
NoteOnly MSE Nacos instances whose MCPEnabled is set to true are displayed. You can change the parameter settings on the Parameter Settings page for the MSE Nacos instances.
Verify the result
Return to the Source tab and view the information about service sources. If the information about the service source that you added is displayed, the service source is added.