Readwrite-splitting

Configuration Item Explanation

Namespace: http://shardingsphere.apache.org/schema/shardingsphere/readwrite-splitting/readwrite-splitting-5.1.0.xsd

<readwrite-splitting:rule />

NameTypeDescription
idAttributeSpring Bean Id
data-source-rule (+)TagReadwrite-splitting data source rule configuration

<readwrite-splitting:data-source-rule />

NameTypeDescription
idAttributeReadwrite-splitting data source rule name
auto-aware-data-source-nameAttributeAuto aware data source name(Use with database discovery)
write-data-source-nameAttributeWrite data source name
read-data-source-namesAttributeRead data source names, multiple data source names separated with comma
load-balance-algorithm-refAttributeLoad balance algorithm name

<readwrite-splitting:load-balance-algorithm />

NameTypeDescription
idAttributeLoad balance algorithm name
typeAttributeLoad balance algorithm type
props (?)TagLoad balance algorithm properties

Please refer to Built-in Load Balance Algorithm List for more details about type of algorithm. Please refer to Use Norms for more details about query consistent routing.