updated createDeployInstance logics

Former-commit-id: 5b8465ca651503401f6fd00de93268e6e6ae8d41
This commit is contained in:
tzwang 2024-08-29 17:21:10 +08:00
parent 3ebe01f35d
commit ef72b1014f
1 changed files with 2 additions and 2 deletions

View File

@ -60,11 +60,11 @@ func (l *CreateDeployTaskLogic) CreateDeployTask(req *types.CreateDeployTaskReq)
func (l *CreateDeployTaskLogic) createDeployInstance(taskId int64, adapterId string, clusterId string, opt *option.InferOption) error {
cmap, found := l.svcCtx.Scheduler.AiService.InferenceAdapterMap[adapterId]
if !found {
return errors.New("adapterId not exist: " + adapterId)
}
iCluster, found := cmap[clusterId]
if !found {
return errors.New("clusterId not exist: " + clusterId)
}
insId, err := iCluster.CreateInferDeployInstance(l.ctx, opt)
if err != nil {