mongodb: Remove superfluous ReplSet log message

closes #2248
This commit is contained in:
Cameron Sparr 2017-01-11 17:50:01 +00:00
parent 81f95e7a29
commit 31a4f03031
No known key found for this signature in database
GPG Key ID: 19E67263DCB25D0F
1 changed files with 3 additions and 4 deletions

View File

@ -40,15 +40,14 @@ func (s *Server) gatherData(acc telegraf.Accumulator, gatherDbStats bool) error
return err
}
result_repl := &ReplSetStatus{}
err = s.Session.DB("admin").Run(bson.D{
// ignore error because it simply indicates that the db is not a member
// in a replica set, which is fine.
_ = s.Session.DB("admin").Run(bson.D{
{
Name: "replSetGetStatus",
Value: 1,
},
}, result_repl)
if err != nil {
log.Println("E! Not gathering replica set status, member not in replica set (" + err.Error() + ")")
}
jumbo_chunks, _ := s.Session.DB("config").C("chunks").Find(bson.M{"jumbo": true}).Count()