An ApsaraDB MyBase for SQL Server Always On instance is built based on the Always On availability groups feature and decouples computing from storage. By default, an ApsaraDB MyBase for SQL Server Always On instance consists of one primary instance and one read-only instance. You can increase the number of read-only instances based on your business requirements. If you need to split read and write requests, you can enable read/write splitting and configure a read-only routing endpoint for an ApsaraDB MyBase for SQL Server Always On instance. This allows ApsaraDB MyBase to offload read requests from the primary instance to read-only instances. This way, the read performance of the ApsaraDB MyBase for SQL Server Always On instance is improved. This topic describes how to use an ApsaraDB MyBase for SQL Server Always On instance.
Benefits
- An ApsaraDB MyBase for SQL Server Always On instance can be scaled out to improve
the read performance.
You can increase the number of read-only instances. This helps improve the read performance of your ApsaraDB MyBase for SQL Server Always On instance in a linear manner. The specifications of the read-only instances can differ from those of the primary instance. Therefore, you can create read-only instances that have higher specifications than the primary instance. This helps improve the read performance of your ApsaraDB MyBase for SQL Server Always On instance.Note By default, a read-only instance does not provide high availability. To ensure high availability, create at least two read-only instances for an ApsaraDB MyBase for SQL Server Always On instance.
- Costs can be controlled in a flexible manner.
The read-only instances of an ApsaraDB MyBase for SQL Server Always On instance are cost-effective and belong to the general-purpose instance family. You can increase the number of read-only instances to offload read requests from the primary instance. This helps you optimize the configurations of your ApsaraDB MyBase for SQL Server Always On instance. The read-only instances can have lower specifications than the primary instance. You can use read-only instances of low specifications to process read requests from background applications such as intelligent analytics applications. This can reduce costs.
Scenarios
- Use read-only instances to offload read requests from the primary instance during
peak hours.
ApsaraDB MyBase for SQL Server Always On instances are suitable for new retail enterprises. During peak hours, you can increase the number of read-only instances of high specifications and enable read/write splitting and traffic throttling to handle traffic spikes. For example, you can use read-only instances to process read requests during Double 11. This way, the amount of network traffic that an ApsaraDB MyBase for SQL Server Always On instance can process increases by multiple times.
- Offload data analytics tasks from the primary instance to read-only instances.
Enterprises need to analyze data in an intelligent way. An ApsaraDB MyBase for SQL Server Always On instance can provide an independent read-only instance for data analytics. This reduces the probability of blocked requests on the primary instance, increases the concurrency of requests, and decreases interruptions to crucial workloads. This way, service stability is ensured.
Prerequisites
An ApsaraDB MyBase for SQL Server dedicated cluster is created. For more information, see Create an ApsaraDB MyBase for SQL Server dedicated cluster.
Hosts are created in the ApsaraDB MyBase for SQL Server dedicated cluster. For more information, see Create hosts in an ApsaraDB MyBase for SQL Server dedicated cluster.
Create an ApsaraDB MyBase for SQL Server dedicated cluster
Procedure
Create hosts in an ApsaraDB MyBase for SQL Server dedicated cluster
Before you create an ApsaraDB MyBase for SQL Server Always On instance, you must create at least two hosts that use the same storage type in an ApsaraDB MyBase for SQL Server dedicated cluster.
Procedure
Create an ApsaraDB MyBase for SQL Server Always On instance
Procedure