Back to Shardingsphere

Rules.En

docs/document/content/user-manual/shardingsphere-proxy/yaml-config/rules.en.md

5.5.31.3 KB
Original Source

+++ title = "Rules" weight = 3 +++

Background

This section explains how to configure the ShardingSphere-Proxy rules.

Parameters Explained

Rules configuration for ShardingSphere-Proxy is the same as ShardingSphere-JDBC. For details, please refer to ShardingSphere-JDBC Rules Configuration.

Notice

Unlike ShardingSphere-JDBC, the following rules need to be configured in ShardingSphere-Proxy's global.yaml:

yaml
sqlParser:
  sqlStatementCache:
    initialCapacity: 2000
    maximumSize: 65535
  parseTreeCache:
    initialCapacity: 128
    maximumSize: 1024
yaml
transaction:
  defaultType: XA
  providerType: Atomikos
yaml
sqlTranslator:
  type:
  useOriginalSQLWhenTranslatingFailed:
yaml
sqlFederation:
  sqlFederationEnabled: true
  allQueryUseSQLFederation: false
  executionPlanCache:
    initialCapacity: 2000
    maximumSize: 65535