Im using dtm-labs/client/workflow packaged to register gRPC workflow server in following way:
import (
"github.com/dtm-labs/client/dtmcli"
"github.com/dtm-labs/client/dtmgrpc/dtmgimp"
"github.com/dtm-labs/client/workflow"
...
)
...
func InitDtmGrpc(grpcDtm string, host string, port int) {
lis, err := net.Listen("tcp", fmt.Sprintf(":%d", port))
if err != nil {
log.Fatal(err)
}
server := grpc.NewServer(grpc.UnaryInterceptor(dtmgimp.GrpcServerLog))
workflow.InitGrpc(grpcDtm, fmt.Sprintf("%s:%d", host, port), server)
go func() {
if err := server.Serve(lis); err != nil {
log.Fatal(err)
}
}()
}
But the DTM which calls the workflow server can't find the service as if it was unregistered.
"log": "{\"level\":\"error\",\"ts\":\"2023-03-22T17:48:21.809Z\",\"caller\":\"dtmsvr/trans_process.go:63\",\"msg\":\"processInner got error: rpc error: code = Unimplemented desc = unknown service workflow.Workflow\",\"stacktrace\":\"github.com/dtm-labs/dtm/dtmsvr.(*TransGlobal).processInner.func1\\n\\t/app/dtm/dtmsvr/trans_process.go:63\\ngithub.com/dtm-labs/dtm/dtmsvr.(*TransGlobal).processInner\\n\\t/app/dtm/dtmsvr/trans_process.go:74\\ngithub.com/dtm-labs/dtm/dtmsvr.(*TransGlobal).process\\n\\t/app/dtm/dtmsvr/trans_process.go:45\\ngithub.com/dtm-labs/dtm/dtmsvr.(*TransGlobal).Process\\n\\t/app/dtm/dtmsvr/trans_process.go:22\\ngithub.com/dtm-labs/dtm/dtmsvr.CronTransOnce\\n\\t/app/dtm/dtmsvr/cron.go:37\\ngithub.com/dtm-labs/dtm/dtmsvr.CronExpiredTrans\\n\\t/app/dtm/dtmsvr/cron.go:45\"}\n",
"stream": "stderr",
"log_processed": {
"level": "error",
"ts": "2023-03-22T17:48:21.809Z",
"caller": "dtmsvr/trans_process.go:63",
"msg": "processInner got error: rpc error: code = Unimplemented desc = unknown service workflow.Workflow",
"stacktrace": "github.com/dtm-labs/dtm/dtmsvr.(*TransGlobal).processInner.func1\n\t/app/dtm/dtmsvr/trans_process.go:63\ngithub.com/dtm-labs/dtm/dtmsvr.(*TransGlobal).processInner\n\t/app/dtm/dtmsvr/trans_process.go:74\ngithub.com/dtm-labs/dtm/dtmsvr.(*TransGlobal).process\n\t/app/dtm/dtmsvr/trans_process.go:45\ngithub.com/dtm-labs/dtm/dtmsvr.(*TransGlobal).Process\n\t/app/dtm/dtmsvr/trans_process.go:22\ngithub.com/dtm-labs/dtm/dtmsvr.CronTransOnce\n\t/app/dtm/dtmsvr/cron.go:37\ngithub.com/dtm-labs/dtm/dtmsvr.CronExpiredTrans\n\t/app/dtm/dtmsvr/cron.go:45"
}
I've checked the ports and connection and it seems to be fine, it's just that workflow service doesn't seem to be registered for some reason
Im using dtm-labs/client/workflow packaged to register gRPC workflow server in following way:
But the DTM which calls the workflow server can't find the service as if it was unregistered.
I've checked the ports and connection and it seems to be fine, it's just that workflow service doesn't seem to be registered for some reason