Canary release rules let you route a targeted subset of production traffic to a new application version based on request attributes—before rolling out the upgrade to all instances. This page explains how to create, edit, and delete canary release rules in SAE.
Prerequisites
Before you begin, make sure you have:
Activated MSE microservice administration Professional Edition
NoteMSE is billed separately from SAE. For pricing details, see Billing overview for microservice administration.
Limits
Canary release rules are only supported for microservice applications created after November 8, 2023.
Choose a rule type
SAE supports two rule types. Select the one that matches your application's traffic entry point:
| Rule type | When to use |
|---|---|
| Layer-7 Traffic Canary Release (K8s Ingress) | Your application receives layer-7 traffic through an ALB-based Kubernetes Ingress. Rules match on Cookie, Header, or source IP at the gateway level. |
| Microservice Traffic | Your application uses Spring Cloud or Dubbo for service-to-service calls. Rules match on framework-level parameters and route traffic at the microservice layer. |
Access canary release rules
Log on to the SAE console. In the left-side navigation pane, choose Applications > Applications.
In the top navigation bar, select a region. From the Namespace drop-down list, select a namespace, then click the application name.
In the left-side navigation pane, choose Microservice governance > Traffic Governance, and click the Canary Release Rule tab.
Create a canary release rule
On the Canary Release Rules page, click Create Canary Release Rule, configure the fields below, then click OK.
If this is your first time using this feature, click Enable Microservice Administration on the page and refresh before configuring rules.
Layer-7 Traffic Canary Release (K8s Ingress)
| Field | Description |
|---|---|
| Rule Type | Select Layer-7 Traffic Canary Release (K8s Ingress). |
| Rule Name | Enter a name for the rule. |
| Description | (Optional) Enter a description. |
| Canary Release Type | Canary release based on content. |
| Gateway Instance (ALB Ingress) | Select the ALB instance for your application. SAE implements Kubernetes Ingress routing through ALB, which routes traffic to different applications based on domain names and paths. Configure an ALB instance and create routing rules before setting up this field. For details, see Setting routing rules for applications (ALB). |
| Service For Canary Release | Select the application and its corresponding port. |
| Condition List | Click +Add Condition to add one or more conditions. For each condition, select a parameter type (Cookie, Header, or Source IP), then configure Parameter and Value. |
Microservice Traffic
| Field | Description |
|---|---|
| Rule Type | Select Microservice Traffic. |
| Rule Name | Enter a name for the rule. |
| Description | (Optional) Enter a description. |
| Canary Release Type | Canary release based on content. |
| Framework Type | Select the framework your application uses: Spring Cloud or Dubbo. |
| Condition Mode | Select Meet All Following Conditions (AND logic) or Meet One of Following Conditions (OR logic). |
| Condition List | Click +Add Condition to add conditions. Configure parameters based on the framework: - Spring Cloud: select parameter type (Cookie, Header, or Parameter), then set Parameter, Condition, and Value. - Dubbo: set Parameter, Parameter Value Expression, Condition, and Value. |
For Microservice Traffic rules, click +Add Canary Release Rule to add multiple entry traffic rules that take effect simultaneously.
Set path or service method
After selecting the framework type, configure the routing target:
Spring Cloud: set Path to match the request path.
Dubbo: select Service Method to target a specific service method.
Edit or delete a canary release rule
On the Canary Release Rules page, find the rule and click Edit or Delete in the Action column.
Billing when disabling rules or governance
After activating the MSE microservice administration feature, MSE will continue to bill you even if you have deleted the canary release rules.
To stop MSE billing, go to the application's Basic Information page, click More in the upper-right corner, and select Disable Microservice Governance. Follow the prompts to complete the process.
Disabling Microservice Governance affects graceful startup and shutdown, canary release rules, and throttling and degradation. An application restart is triggered. Evaluate business impact before proceeding.
What's next
After creating canary release rules, configure a phased release strategy to progressively shift traffic to the new version. For a step-by-step walkthrough using a Spring Cloud application, see Phased release of applications.