Updated on 2024-10-14 GMT+08:00

Modifying Read/Write Splitting Parameters

Scenarios

After read/write splitting is enabled, you can modify proxy parameters, for example, multiStatementType.

Constraints

  • To modify read/write splitting parameters, you need to contact customer service to apply for required permissions.
  • To change the value of multiStatementType, the proxy version must be 2.22.11.000 or later.
  • All proxies of your DB instance must be in the Available state.

Procedure

  1. Log in to the management console.
  2. Click in the upper left corner and select a region.
  3. Click in the upper left corner of the page and choose Databases > Relational Database Service.
  4. On the Instances page, click the primary instance name.
  5. In the navigation pane on the left, choose Database Proxy.
  6. On the displayed page, click Modify Parameters in the proxy information area.
  7. Change the value of multiStatementType and click OK.

    multiStatementType is not available for read-only proxies.

    • Strict (default): After a multi-statement request is sent to the primary instance, the read/write splitting of the current connection becomes unavailable and all subsequent requests are routed to the primary instance.
    • Loose: After a multi-statement request is sent to the primary instance, the read/write splitting of the current connection still works.
    • Parse: After a multi-statement request is sent to the primary instance, the request is parsed to determine whether to split subsequent read and write requests.