code: func (mc MongoClient) EventCountByDeviceId(id string) (int, error) {
  	s := mc.getSessionCopy()
  	defer s.Close()
  
  	query := bson.M{"device": id}
  	count, err := s.DB(mc.database.Name).C(db.EventsCollection).Find(query).Count()
  	if err != nil {
  		return 0, errorMap(err)
  	}
  	return count, nil
  }
docs: // Get the number of events in Mongo for the device