Service Provider Interface (SPI) is a kind of API that aims to be implemented or extended by the third party. It can be used to realize framework extension or component replacement.
ShardingSphere uses SPI to load data to the registry center and disable instances and databases. Currently, ShardingSphere supports two kinds of frequently used registry centers, Zookeeper and Etcd. In addition, by injecting them to ShardingSphere with SPI, users can use other third-party registry centers to enable database orchestration.
Use SPI to realize relevant logic coding.