feat: import services and standardize Go 1.26.5
This commit is contained in:
11
apps/base/ads/test/lint/gosec
Normal file
11
apps/base/ads/test/lint/gosec
Normal file
@@ -0,0 +1,11 @@
|
||||
{
|
||||
"Golang errors": {},
|
||||
"Issues": [],
|
||||
"Stats": {
|
||||
"files": 24,
|
||||
"lines": 2377,
|
||||
"nosec": 0,
|
||||
"found": 0
|
||||
},
|
||||
"GosecVersion": "dev"
|
||||
}
|
||||
23
apps/base/ads/test/rpc/rpc.go
Normal file
23
apps/base/ads/test/rpc/rpc.go
Normal file
@@ -0,0 +1,23 @@
|
||||
package main
|
||||
|
||||
func main() {
|
||||
/*
|
||||
md := metadata.New(map[string]string{"request_id": utils.UUID(), "workspace": "scf"})
|
||||
ctx := metadata.NewOutgoingContext(context.Background(), md)
|
||||
|
||||
// 建立GRPC连接
|
||||
conn, err := grpc.Dial("127.0.0.1:12201", grpc.WithTransportCredentials(insecure.NewCredentials()))
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
defer conn.Close()
|
||||
c := pb.NewMethodClient(conn)
|
||||
r, err := c.List()(ctx, &pb.Crc{
|
||||
Code: "david",
|
||||
})
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
fmt.Printf("返回的消息: %s", r.Message)
|
||||
*/
|
||||
}
|
||||
Reference in New Issue
Block a user