Skip to content
Snippets Groups Projects
Commit 08e2e4ad authored by renovate_bot's avatar renovate_bot Committed by Fabian Seidl
Browse files

[renovate] Update module google.golang.org/grpc to v1.63.0


See merge request !821

Co-authored-by: default avatarFabian Seidl <fabian.seidl@h-da.de>
Co-authored-by: default avatarRenovate Bot <renovate@danet.fbi.h-da.de>
parent 99b4f9ce
No related branches found
No related tags found
1 merge request!821[renovate] Update module google.golang.org/grpc to v1.63.0
Pipeline #188784 passed
Showing
with 40 additions and 209 deletions
......@@ -11,7 +11,7 @@ import (
// Register registers a new app at the control plane.
func Register(ctx context.Context, gosdnAddress, name, token string) (string, error) {
conn, err := grpc.Dial(gosdnAddress, grpc.WithTransportCredentials(insecure.NewCredentials()))
conn, err := grpc.NewClient(gosdnAddress, grpc.WithTransportCredentials(insecure.NewCredentials()))
if err != nil {
return "", err
}
......
......@@ -40,7 +40,7 @@ func (a *Application) Run(controllerAddress string) {
})
a.eventServiceRoutes.SetupEventReciever(a.stopChannel)
conn, err := grpc.Dial(controllerAddress, grpc.WithTransportCredentials(insecure.NewCredentials()))
conn, err := grpc.NewClient(controllerAddress, grpc.WithTransportCredentials(insecure.NewCredentials()))
if err != nil {
panic(err)
}
......
......@@ -31,7 +31,7 @@ func (a *Application) Run(controllerAddress string) {
})
a.eventServiceNetworkElements.SetupEventReciever(a.stopChannel)
conn, err := grpc.Dial(controllerAddress, grpc.WithTransportCredentials(insecure.NewCredentials()))
conn, err := grpc.NewClient(controllerAddress, grpc.WithTransportCredentials(insecure.NewCredentials()))
if err != nil {
panic(err)
}
......
......@@ -35,7 +35,7 @@ func (a *Application) Run() {
})
a.eventService.SetupEventReciever(a.stopChannel)
conn, err := grpc.Dial("localhost:55055", grpc.WithTransportCredentials(insecure.NewCredentials()))
conn, err := grpc.NewClient("localhost:55055", grpc.WithTransportCredentials(insecure.NewCredentials()))
if err != nil {
panic(err)
}
......
......@@ -50,7 +50,7 @@ func NewVenvManager(dialConnectionURL string, dialOption grpc.DialOption, topolo
}
func (v *VenvManager) createConnection() (*grpc.ClientConn, error) {
conn, err := grpc.Dial(v.dialConnectionURL, v.dialOption, grpc.WithDefaultCallOptions(grpc.MaxCallRecvMsgSize(100*1024*1024)))
conn, err := grpc.NewClient(v.dialConnectionURL, v.dialOption, grpc.WithDefaultCallOptions(grpc.MaxCallRecvMsgSize(100*1024*1024)))
if err != nil {
return nil, err
}
......
......@@ -9,10 +9,13 @@ import (
"code.fbi.h-da.de/danet/gosdn/controller/store"
log "github.com/sirupsen/logrus"
"github.com/spf13/viper"
"google.golang.org/grpc/resolver"
)
func Test_Init(t *testing.T) {
viper.SetConfigFile("./api_test.toml")
resolver.SetDefaultScheme("passthrough")
if err := Init(context.TODO(), bufnet); err != nil {
t.Error(err)
}
......
......@@ -181,7 +181,7 @@ func initialize() error {
func setupOrchestratorClient() {
orchestrator := viper.GetString("csbi-orchestrator")
conn, err := grpc.Dial(orchestrator, grpc.WithTransportCredentials(insecure.NewCredentials()))
conn, err := grpc.NewClient(orchestrator, grpc.WithTransportCredentials(insecure.NewCredentials()))
if err != nil {
log.Fatal(err)
}
......@@ -190,7 +190,7 @@ func setupOrchestratorClient() {
func setupPluginRegistryClient() rpb.PluginRegistryServiceClient {
pluginRegistry := viper.GetString("plugin-registry")
conn, err := grpc.Dial(pluginRegistry, grpc.WithTransportCredentials(insecure.NewCredentials()))
conn, err := grpc.NewClient(pluginRegistry, grpc.WithTransportCredentials(insecure.NewCredentials()))
if err != nil {
log.Fatal(err)
}
......
......@@ -9,7 +9,7 @@ import (
// the address of the gRPC endpoint and optional grpc.DialOption
// as argument.
func AppClient(addr string, opts ...grpc.DialOption) (apb.AppServiceClient, error) {
conn, err := grpc.Dial(addr, opts...)
conn, err := grpc.NewClient(addr, opts...)
if err != nil {
return nil, err
}
......
......@@ -9,7 +9,7 @@ import (
// the address of the gRPC endpoint and optional grpc.DialOption
// as argument.
func ConfigurationManagementClient(addr string, opts ...grpc.DialOption) (cpb.ConfigurationManagementServiceClient, error) {
conn, err := grpc.Dial(addr, opts...)
conn, err := grpc.NewClient(addr, opts...)
if err != nil {
return nil, err
}
......
......@@ -9,7 +9,7 @@ import (
// the address of the gRPC endpoint and optional grpc.DialOption
// as argument.
func NetworkElementClient(addr string, opts ...grpc.DialOption) (mnepb.NetworkElementServiceClient, error) {
conn, err := grpc.Dial(addr, opts...)
conn, err := grpc.NewClient(addr, opts...)
if err != nil {
return nil, err
}
......
......@@ -6,7 +6,7 @@ import (
)
func PluginClient(addr string, opts ...grpc.DialOption) (pipb.PluginInternalServiceClient, error) {
conn, err := grpc.Dial(addr, opts...)
conn, err := grpc.NewClient(addr, opts...)
if err != nil {
return nil, err
}
......
......@@ -9,7 +9,7 @@ import (
// the address of the gRPC endpoint and optional grpc.DialOption
// as argument.
func PndClient(addr string, opts ...grpc.DialOption) (ppb.PndServiceClient, error) {
conn, err := grpc.Dial(addr, opts...)
conn, err := grpc.NewClient(addr, opts...)
if err != nil {
return nil, err
}
......
......@@ -9,7 +9,7 @@ import (
// the address of the gRPC endpoint and optional grpc.DialOption
// as argument.
func AuthClient(addr string, opts ...grpc.DialOption) (apb.AuthServiceClient, error) {
conn, err := grpc.Dial(addr, opts...)
conn, err := grpc.NewClient(addr, opts...)
if err != nil {
return nil, err
}
......@@ -20,7 +20,7 @@ func AuthClient(addr string, opts ...grpc.DialOption) (apb.AuthServiceClient, er
// the address of the gRPC endpoint and optional grpc.DialOption
// as argument.
func UserClient(addr string, opts ...grpc.DialOption) (apb.UserServiceClient, error) {
conn, err := grpc.Dial(addr, opts...)
conn, err := grpc.NewClient(addr, opts...)
if err != nil {
return nil, err
}
......@@ -31,7 +31,7 @@ func UserClient(addr string, opts ...grpc.DialOption) (apb.UserServiceClient, er
// the address of the gRPC endpoint and optional grpc.DialOption
// as argument.
func RoleClient(addr string, opts ...grpc.DialOption) (apb.RoleServiceClient, error) {
conn, err := grpc.Dial(addr, opts...)
conn, err := grpc.NewClient(addr, opts...)
if err != nil {
return nil, err
}
......
......@@ -9,7 +9,7 @@ import (
// the address of the gRPC endpoint and optional grpc.DialOption
// as argument.
func SbiClient(addr string, opts ...grpc.DialOption) (spb.SbiServiceClient, error) {
conn, err := grpc.Dial(addr, opts...)
conn, err := grpc.NewClient(addr, opts...)
if err != nil {
return nil, err
}
......
......@@ -18,6 +18,7 @@ import (
"google.golang.org/grpc/codes"
"google.golang.org/grpc/credentials/insecure"
"google.golang.org/grpc/metadata"
"google.golang.org/grpc/resolver"
"google.golang.org/grpc/status"
"google.golang.org/grpc/test/bufconn"
)
......@@ -68,6 +69,7 @@ func getTestAuthInterceptorServer(t *testing.T) (*AuthInterceptor, *UserServer,
}
func dialer(interceptorServer *AuthInterceptor, userServer *UserServer, roleServer *RoleServer, pluginServer *PluginInternalServer) func(context.Context, string) (net.Conn, error) {
resolver.SetDefaultScheme("passthrough")
listener := bufconn.Listen(1024 * 1024)
interceptor := interceptorServer
......@@ -99,16 +101,16 @@ func TestAuthInterceptor_Unary(t *testing.T) {
t.Fatal(err)
}
ctx := context.Background()
conn, err := grpc.DialContext(
ctx,
"",
dialerFunc := dialer(authServer, userServer, roleServer, pluginServer)
conn, err := grpc.NewClient("bufnet",
grpc.WithTransportCredentials(insecure.NewCredentials()),
grpc.WithContextDialer(dialer(authServer, userServer, roleServer, pluginServer)),
grpc.WithContextDialer(dialerFunc),
)
if err != nil {
t.Fatal(err)
}
defer func() {
if err := conn.Close(); err != nil {
log.Fatal(err)
......@@ -197,16 +199,16 @@ func TestAuthInterceptor_Stream(t *testing.T) {
t.Fatal(err)
}
ctx := context.Background()
conn, err := grpc.DialContext(
ctx,
"",
dialerFunc := dialer(authServer, userServer, roleServer, pluginServer)
conn, err := grpc.NewClient("bufnet",
grpc.WithTransportCredentials(insecure.NewCredentials()),
grpc.WithContextDialer(dialer(authServer, userServer, roleServer, pluginServer)),
grpc.WithContextDialer(dialerFunc),
)
if err != nil {
t.Fatal(err)
}
defer func() {
if err := conn.Close(); err != nil {
log.Fatal(err)
......
......@@ -24,8 +24,7 @@ require (
github.com/stretchr/testify v1.9.0
go.mongodb.org/mongo-driver v1.14.0
golang.org/x/sync v0.7.0
google.golang.org/genproto v0.0.0-20240213162025-012b6fc9bca9 // indirect
google.golang.org/grpc v1.62.1
google.golang.org/grpc v1.63.0
google.golang.org/protobuf v1.33.0
gopkg.in/yaml.v3 v3.0.1
)
......@@ -108,7 +107,6 @@ require (
github.com/hashicorp/yamux v0.1.1 // indirect
github.com/lesismal/llib v1.1.12 // indirect
github.com/lithammer/fuzzysearch v1.1.8 // indirect
github.com/matttproud/golang_protobuf_extensions/v2 v2.0.0 // indirect
github.com/mitchellh/go-testing-interface v1.14.1 // indirect
github.com/moby/patternmatcher v0.5.0 // indirect
github.com/moby/sys/sequential v0.5.0 // indirect
......
This diff is collapsed.
......@@ -50,7 +50,7 @@ func CreateSecureConnection() (*grpc.ClientConn, context.Context, error) {
sessionContext := CreateContextWithAuthorization(loginResp)
dialOption := grpc.WithTransportCredentials(insecure.NewCredentials())
conn, err := grpc.Dial(controllerUrl, dialOption, grpc.WithDefaultCallOptions(grpc.MaxCallRecvMsgSize(100*1024*1024)))
conn, err := grpc.NewClient(controllerUrl, dialOption, grpc.WithDefaultCallOptions(grpc.MaxCallRecvMsgSize(100*1024*1024)))
if err != nil {
return nil, nil, err
}
......@@ -65,7 +65,7 @@ func CreateConnection() (*grpc.ClientConn, context.Context, error) {
controllerUrl = controllerEnv
}
dialOption := grpc.WithTransportCredentials(insecure.NewCredentials())
conn, err := grpc.Dial(controllerUrl, dialOption, grpc.WithDefaultCallOptions(grpc.MaxCallRecvMsgSize(100*1024*1024)))
conn, err := grpc.NewClient(controllerUrl, dialOption, grpc.WithDefaultCallOptions(grpc.MaxCallRecvMsgSize(100*1024*1024)))
if err != nil {
return nil, nil, err
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment