Browse Source

debug

master v0.7.4
guzeng 2 years ago
parent
commit
41be6a2de4
1 changed files with 5 additions and 0 deletions
  1. +5
    -0
      conn.go

+ 5
- 0
conn.go View File

@ -1,6 +1,7 @@
package redisrpc
import (
"log"
"net/rpc"
"git.tetele.net/tgo/conf"
@ -8,6 +9,8 @@ import (
func Conn(url ...string) (*RedisServiceClient, *rpc.Client, error) {
log.Println("conn redis rpc server========", url)
var rpc_url string
if len(url) > 0 && url[0] != "" {
rpc_url = url[0]
@ -17,6 +20,8 @@ func Conn(url ...string) (*RedisServiceClient, *rpc.Client, error) {
rpc_url = "127.0.0.1:" + conf.REDIS_RPC_PORT
}
log.Println("rpc_url", rpc_url)
return DialRedisService("tcp", rpc_url)
}

Loading…
Cancel
Save