Skip to content

Commit

Permalink
populate service struct
Browse files Browse the repository at this point in the history
  • Loading branch information
shalper2 committed Nov 7, 2024
1 parent ff116f9 commit 731526c
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions receiver/windowsservicereceiver/windowsservice.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,15 @@ func GetService(sname string) (*Service, error) {
service: service,
}

// populate metric fields
if err = s.getStatus(); err != nil {
return nil, err
}

if err = s.getConfig(); err != nil {
return nil, err
}

return &s, nil
}

Expand Down

0 comments on commit 731526c

Please sign in to comment.