All Products
Search
Document Center

Serverless App Engine:Configure graceful start of microservices

Last Updated:Sep 14, 2024

In a production environment, services may be unavailable for a short period of time and a large number of service monitoring errors may occur when the auto scaling feature and upgrade and rollback feature are used. To prevent the preceding issues, you can use the graceful start feature of Serverless App Engine (SAE) after you host a microservices application to SAE. SAE supports the graceful start feature of Spring Cloud applications. This topic describes how to configure the graceful start feature in the SAE console.

Configure graceful start of microservices when you create an application

  1. Log on to the SAE console.

  2. In the left-side navigation pane, click Applications. In the top navigation bar, select a region. Then, click Create Application.

  3. In the Basic Information step, configure the parameters and click Next: Application Deployment Configurations.

  4. In the Deployment Configurations step, configure the Technology Stack Programming Language and Application Deployment Method parameters and the corresponding settings.

  5. On the Graceful Start of Microservices tab of the Graceful Start and Shutdown of Microservices section, turn on Enable Graceful Start for Microservices, and then click Configuration Wizard of Graceful Start.

  6. In the Parameter Configuration for Graceful Start step, view the related parameter and click Configuration Preview.

    Parameter

    Description

    Port Occupied by SAE Graceful Start

    Default value: 54199. You cannot change the value.

  7. In the Configuration Preview step, check the configurations and click Confirm.

    If you configure graceful start of microservices in the Configuration Wizard of Graceful Start panel when you create an application, Enable Microservices Application Business Readiness Check is selected by default. If you select the check box, the system uses the default values of the Path and Port parameters to perform health checks. You cannot change the values.

    • Path: /health.

    • Port: 54199.

  8. Click Next: Confirm Specifications.

  9. In the Specification Confirmation step, view the details of the application and the fee for the selected specifications. Then, click Confirm.

    The Creation Completed step appears. You can click Application Details to go to the Basic Information page of the application.

Configure graceful start of microservices when you deploy an application

Warning

After you redeploy an application, the application is restarted. To prevent unpredictable errors such as business interruptions, we recommend that you deploy applications during off-peak hours.

The procedure that can be performed to update an application varies based on the number of instances in the application. This section provides an example on how to configure the required features for an application in which the number of instances is greater than or equal to 1. For information about how to update an application in which the number of instances is 0, see Update an application.

  1. Log on to the SAE console.

  2. In the left-side navigation pane, click Applications. In the top navigation bar, select a region. Then, click the name of an application.

  3. In the upper-right corner of the Basic Information page, click Deploy Application.

  4. In the Graceful Start and Shutdown of Microservices section of the Deploy Application page, click the Graceful Start of Microservices tab. On the tab that appears, turn on Enable Graceful Start for Microservices and click Configuration Wizard of Graceful Start.

  5. In the Parameter Configuration for Graceful Start step, view the related parameter and click Configuration Preview.

    Parameter

    Description

    Port Occupied by SAE Graceful Start

    Default value: 54199. You cannot change the value.

  6. In the Configuration Preview step, check the configurations and click Confirm.

    Note

    If you configured a health check for the application before you configure graceful start of microservices, the configurations vary based on the check method that you selected.

    • HTTP Request Check: By default, the Enable Microservices Application Business Readiness Check check box is selected.

    • TCP Port Check or Command Execution Check: The Enable Microservices Application Business Readiness Check check box is not displayed on the Application Business Readiness Check (Readiness Configuration) tab.

  7. After you configure the settings, click Confirm.