服务之间相互调用

This commit is contained in:
2026-08-24 10:06:52 +08:00
parent c33fbdb422
commit 80f428c032
49 changed files with 1756 additions and 35 deletions
@@ -0,0 +1,34 @@
// Code generated by goctl. DO NOT EDIT.
// goctl 1.10.2
// Source: express.proto
package server
import (
"context"
"lone-services/rpc/express/pb"
"lone-services/services/express/internal/logic"
"lone-services/services/express/internal/svc"
)
type ExpressServer struct {
svcCtx *svc.ServiceContext
express.UnimplementedExpressServer
}
func NewExpressServer(svcCtx *svc.ServiceContext) *ExpressServer {
return &ExpressServer{
svcCtx: svcCtx,
}
}
func (s *ExpressServer) Ping(ctx context.Context, in *express.Request) (*express.Response, error) {
l := logic.NewPingLogic(ctx, s.svcCtx)
return l.Ping(in)
}
func (s *ExpressServer) Items(ctx context.Context, in *express.EmtpyRequest) (*express.Response, error) {
l := logic.NewItemsLogic(ctx, s.svcCtx)
return l.Items(in)
}