You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Read-write-splitting is an important part of pisa-proxy traffic management, which can be improve query performance and reduce server load in practical scenarios.
The following is internal design diagram:
RuleMatch is used to match SQL statements by rules. Currently, only support regex and in the future, rego will be supported. TargetGroup is the backend target group after successful matching, and the target group corresponds to the role attribute, the role need to be defined in annotations field of DatabaseEndpoint crd. LoadBalance is used to select an instance in the target group by the LoadBalance algorithm. TargetInstace is executes the instance of the SQL statement.
mlycore
changed the title
Feature(strategy): WIP: support mysql read_write_splitting
Feature(strategy): support mysql read_write_splitting
Jun 23, 2022
Read-write-splitting is an important part of
pisa-proxy
traffic management, which can be improve query performance and reduce server load in practical scenarios.The following is internal design diagram:
RuleMatch
is used to matchSQL
statements by rules. Currently, only support regex and in the future,rego
will be supported.TargetGroup
is the backend target group after successful matching, and the target group corresponds to therole
attribute, therole
need to be defined inannotations
field ofDatabaseEndpoint
crd.LoadBalance
is used to select an instance in the target group by theLoadBalance
algorithm.TargetInstace
is executes the instance of the SQL statement.An complete config of
TrafficStrategy
as follows:An complete config of
DatabaseEndpoint
as follows:Development Task
pisa-proxy
read_write_splitting
.RuleMatch
engine.build_loadbalance
logic forRuleMatch
engine.RuleMatch
engine formysql server runtime
.LoadBalancer
toFSM
.pisa-controller
read_write_splitting
.DatabaseEndpoint
crd forrole
.integration test
pisa-proxy
andpisa-controller
integration test.The text was updated successfully, but these errors were encountered: