Skip to content

Commit

Permalink
fix(hatchery/local): groupName in SpawnInfo
Browse files Browse the repository at this point in the history
Signed-off-by: Yvonnick Esnault <yvonnick.esnault@corp.ovh.com>
  • Loading branch information
yesnault committed Jun 3, 2019
1 parent d618ac0 commit edb82bb
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion sdk/hatchery/starter.go
Original file line number Diff line number Diff line change
Expand Up @@ -157,12 +157,16 @@ func spawnWorkerForJob(h Interface, j workerStarterRequest) (bool, error) {

ctxSendSpawnInfo, next := observability.Span(ctx, "hatchery.SendSpawnInfo", observability.Tag("msg", sdk.MsgSpawnInfoHatcheryStarts.ID))
start := time.Now()
var groupName = h.ServiceName()
if j.model.Group != nil {
groupName = j.model.Group.Name
}
SendSpawnInfo(ctxSendSpawnInfo, h, j.id, sdk.SpawnMsg{
ID: sdk.MsgSpawnInfoHatcheryStarts.ID,
Args: []interface{}{
h.Service().Name,
fmt.Sprintf("%d", h.ID()),
fmt.Sprintf("%s/%s", j.model.Group.Name, j.model.Name),
fmt.Sprintf("%s/%s", groupName, j.model.Name),
},
})
next()
Expand Down

0 comments on commit edb82bb

Please sign in to comment.