All Products
Search
Document Center

Microservices Engine:Update a Nacos version

Last Updated:Mar 19, 2024

Nacos engines provide Professional Edition and Developer Edition. Each Nacos engine edition has different versions. Basic Edition is discontinued, and features in Basic Edition are no longer updated. This topic describes how to upgrade Nacos versions in the Microservices Engine (MSE) console. You can upgrade a Nacos engine from Basic Edition to Professional Edition or Developer Edition. You can also upgrade the Nacos engine to a specified version.

Prerequisites

Background information

Microservices Registry has two editions: Professional Edition and Developer Edition. Each Nacos engine edition has different versions. Basic Edition is discontinued, and features in Basic Edition are no longer updated. Users that use Basic Edition cannot use the new features of Microservices Registry. For more information about the features that are supported by different editions of Nacos engines, see Edition features.

You can upgrade Nacos engines only in the following ways: upgrade from Basic Edition to Developer Edition or Professional Edition, upgrade between versions of Developer Edition, and upgrade between versions of Professional Edition.

Upgrade a Nacos engine from Basic Edition to Professional Edition or Developer Edition

Note
  • Only MSE engines that use Nacos 1.2.1.0 or later can be upgraded from Basic Edition to Professional Edition or Developer Edition. If your MSE engine uses Nacos 1.1.3.x, you must upgrade the version of the Nacos engine to 1.2.1 before you can upgrade the edition. For more information, see Upgrade the Nacos version from 1.1.3 to 1.2.1.

  • To ensure the consistency of data and the stability of the upgrade process, an MSE Nacos instance performs a doublewrite operation on the data of registered services during the upgrade. Before you upgrade the edition, you must make sure that the number of providers registered with the MSE Nacos instance is less than the maximum number of providers that are supported by the related specifications of Basic Edition. This way, the impacts of the doublewrite operation on your business are prevented during the upgrade. For more information, see Estimate the capabilities of Microservices Registry.

  • For more information about the comparison among Basic Edition, Professional Edition, and Developer Edition of Microservices Registry, see Select an edition.

  1. Log on to the MSE console and select a region in the top navigation bar.

  2. In the left-side navigation pane, choose Microservices Registry > Instances.

  3. On the Instances page, find the MSE instance whose specifications you want to change, and click Upgrade in the Actions column.

    • For a subscription instance, select Upgrade or Downgrade based on your business requirements.

    • For a pay-as-you-go instance, select Upgrade/Downgrade.

    Note

    If the instance is of the latest version, click Upgrade in the Actions column to go to the Upgrade/Downgrade page and scale out or scale in the instance.

  4. On the Upgrade/Downgrade page, select a product edition based on your business requirements, and specify Engine Specifications and Number of Cluster Nodes.

    A Professional Edition instance can have multiple nodes, and a Developer Edition instance can have a single node.

    When you select a product edition for specifications upgrade or downgrade, take note of the following limits:

    • You can upgrade a Basic Edition instance to a Developer Edition instance or a Professional Edition instance.

    • You can upgrade a Developer Edition instance of an earlier version to a Developer Edition instance of a later version. You cannot upgrade a Developer Edition instance to a Professional Edition instance.

    • You can upgrade a Professional Edition instance of an earlier version to a Professional Edition instance of a later version. You cannot downgrade a Professional Edition instance to a Developer Edition instance.

  5. Confirm the order.
    1. Click Buy Now.
    2. On the Confirm Order page, read the terms of service, select the check box to confirm that you have read the terms of service, and then click Pay.

Upgrade MSE Nacos versions

Note
  • The period of time that is required to upgrade the version of a Nacos engine is approximately 10 minutes. During the upgrade, you cannot perform operations on the Nacos engine in the MSE console. We recommend that you upgrade the version of the Nacos engine during off-peak hours to prevent business interruptions.

  • For an instance that contains three or more nodes, a rolling deployment is performed for each node, and data is automatically synchronized to these nodes. Your business is not affected during the upgrade. For an instance that contains one or two nodes, the instance cannot provide high availability, and business interruptions may occur during the upgrade.

  • The upgrade does not affect your business. However, the instance needs to disconnect from and re-connect to the network during the upgrade. In this case, the system generates logs for the reconnection, and jitters occur on the monitoring data of the instance.

  1. Log on to the MSE console and select a region in the top navigation bar.

  2. In the left-side navigation pane, choose Microservices Registry > Instances.

  3. On the Instances page, find the desired instance and click Upgradeable in the Engine version column.

    Note
    • If the instance is of the latest version, Upgradeable is not displayed in the Engine version column of the instance.

    • You can also click the instance that you want to upgrade on the Instances page. On the Basic Information page, click Manually Upgrade next to Engine version.

  4. In the Cluster Upgrade message, click OK.

Upgrade the Nacos version from 1.1.3 to 1.2.1

Important
  • Nacos 1.1.3 is discontinued. If your Nacos engine is of this version, we recommend that you upgrade the Nacos engine to 1.2.1 or later at the earliest opportunity.

  • If you want to upgrade the Nacos version to version 2.x of Developer Edition or Professional Edition, you must upgrade the Nacos version to 1.2.1 first.

  1. Log on to the MSE console and select a region in the top navigation bar.

  2. In the left-side navigation pane, choose Microservices Registry > Instances.

  3. On the Instances page, find the Nacos instance that you want to upgrade, click the 升级 icon in the Actions column, and then select Upgrade the Engine Version from the drop-down list.

  4. In the Cluster Upgrade message, click OK.

    On the Instances page, you can check that the Nacos version is upgraded from 1.1.3 to 1.2.1.

FAQ

  • Q: Is the Nacos client of a version earlier than 2.0.0 supported after the MSE Nacos instance is upgraded to version 2.0.0 of the Professional Edition?

    A: Yes, the Nacos client of a version earlier than 2.0.0 is supported. After the upgrade, the MSE Nacos instance supports Nacos clients of all versions later than 1.0.0. The service discovery feature is compatible with Nacos clients of all versions later than 1.2.0. However, Nacos clients of 1.x.x do not support persistent connections. Therefore, we recommend that you use a Nacos client of a version later than 2.0.0.

  • Q: How do I upgrade a Nacos client if the Spring Cloud Alibaba or Dubbo framework is used?

    A: If the Spring Cloud Alibaba framework is used, specify a Nacos client of a specific version. Sample configurations:

    <dependency>
        <groupId>com.alibaba.cloud</groupId>
        <artifactId>spring-cloud-starter-alibaba-nacos-discovery</artifactId>
        <version>${springcloudalibaba.version}</version>
        <exclusions>
            <exclusion>
            <groupId>com.alibaba.nacos</groupId>
            <artifactId>nacos-client</artifactId>
             </exclusion>
        </exclusions>
    </dependency>
    <dependency>
        <groupId>com.alibaba.cloud</groupId>
        <artifactId>spring-cloud-starter-alibaba-nacos-config</artifactId>
        <version>${springcloudalibaba.version}</version>
        <exclusions>
            <exclusion>
                <groupId>com.alibaba.nacos</groupId>
                <artifactId>nacos-client</artifactId>
            </exclusion>
        </exclusions>
    </dependency>
    <dependency>
        <groupId>com.alibaba.nacos</groupId>
        <artifactId>nacos-client</artifactId>
        <version>2.0.2</version>
    </dependency>

    If the Dubbo framework is used, specify a Nacos client of a specific version. Sample configurations:

    <dependency>
        <groupId>org.apache.dubbo</groupId>
        <artifactId>dubbo-registry-nacos</artifactId>
        <version>${dubbo.version}</version>
        <exclusions>
            <exclusion>
                <groupId>com.alibaba.nacos</groupId>
                <artifactId>nacos-client</artifactId>
            </exclusion>
        </exclusions>
    </dependency>
    <dependency>
        <groupId>com.alibaba.nacos</groupId>
        <artifactId>nacos-client</artifactId>
        <version>2.0.2</version>
    </dependency>
    Important

    If Dubbo 2.7.8 is used, a large number of instances are created on the Nacos client. As a result, the numbers of connections and threads surge. Therefore, before you upgrade the version of a Nacos client, you must upgrade the Dubbo version. For more information, see the details about this issue.

  • Q: After the edition of an MSE instance is upgraded to Professional Edition and the Nacos client is upgraded for your application, one of the following error messages appears when the Nacos client is started: Connection is unregistered and Client not connected,current status:STARTING. What do I do?

    A: The preceding error messages appear because the Nacos client cannot be connected to the Nacos server over Google Remote Procedure Call (gRPC). To resolve this issue, test the network connectivity between the Nacos client and the Nacos server by using telnet ${nacos.server.address}:9848 and check whether your applications reside in the same virtual private cloud (VPC) as the MSE instance. If the network type of the MSE instance is Internet, configure a public IP address whitelist for the instance. For more information, see Configure a public IP address whitelist.

    Port 8848 is used to access the applications from the Nacos client. You do not need to change the port number. The Nacos client automatically calculates the port number that is used for gRPC-based connection.

  • Q: After the edition of an MSE instance is upgraded to Professional Edition and the Nacos client is upgraded for your application, the following error message appears when the Nacos client is started: Nacos cluster is running with 1.X mode, can't accept gRPC request temporarily. What do I do?

    A: The preceding error message appears because the MSE Nacos instance is performing a data doublewrite operation and checking data consistency. This ensures that the data of the MSE instance before and after the upgrade is consistent. In this case, requests from Nacos clients of version 2.0.0 are denied before the consistency check is complete, but requests from Nacos clients of 1.x.x and requests to access the MSE console are not affected. After the data doublewrite and consistency check are complete, the MSE Professional Edition instance provides services. The time required for the data doublewrite and consistency check varies based on the capacity of the MSE instance. In most cases, the operations take 5 to 20 minutes. If the issue occurs, wait a few minutes and start the Nacos client again.