How to get the property assignment of golang factory object?

simply implement redis factory, and dynamically obtain stand-alone instantiated objects or cluster instantiated objects according to configuration

< H1 > Golang sample code < / H1 >
//()
func demo() {
    instance := xxx.Factory()

    instance.Obj.Get("xx") //redis.Client.Get  redis.ClusterClient.Get
}
Dec.15,2021
Menu