diff --git a/pfcpiface/bess.go b/pfcpiface/bess.go index bce0c8c3e..191f4304c 100644 --- a/pfcpiface/bess.go +++ b/pfcpiface/bess.go @@ -778,7 +778,7 @@ func (b *bess) SetUpfInfo(u *upf, conf *Conf) { b.endMarkerChan = make(chan []byte, 1024) - b.conn, err = grpc.Dial(*bessIP, grpc.WithTransportCredentials(insecure.NewCredentials())) + b.conn, err = grpc.NewClient(*bessIP, grpc.WithTransportCredentials(insecure.NewCredentials())) if err != nil { logger.BessLog.Fatalln("did not connect:", err) } diff --git a/pfcpiface/p4rtc.go b/pfcpiface/p4rtc.go index b4856c774..1112adb87 100644 --- a/pfcpiface/p4rtc.go +++ b/pfcpiface/p4rtc.go @@ -521,7 +521,7 @@ func GetConnection(host string) (conn *grpc.ClientConn, err error) { /* get connection */ logger.P4Log.Infoln("get connection") - conn, err = grpc.Dial(host, grpc.WithTransportCredentials(insecure.NewCredentials())) + conn, err = grpc.NewClient(host, grpc.WithTransportCredentials(insecure.NewCredentials())) if err != nil { logger.P4Log.Errorln("grpc dial err:", err) return nil, err