Skip to content

Commit

Permalink
fix: default values for nvidia_smi query timeout (#822)
Browse files Browse the repository at this point in the history
  • Loading branch information
kongfei605 authored Mar 8, 2024
1 parent aa21b82 commit ca97095
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions inputs/nvidia_smi/nvidia_smi.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,9 @@ func (s *GPUStats) Init() error {
if s.NvidiaSmiCommand == "" {
return types.ErrInstancesEmpty
}
if s.QueryTimeOut == 0 {
s.QueryTimeOut = config.Duration(5 * time.Second)
}

qFieldsOrdered, qFieldToRFieldMap, err := s.buildQFieldToRFieldMap()
if err != nil {
Expand Down

0 comments on commit ca97095

Please sign in to comment.