func (db *Database) GetNumInfos(poolName string) (int, error) {
	poolName = strings.ToLower(poolName)
	db.namedLock.RLock(poolName)
	defer db.namedLock.RUnlock(poolName)
	var pool Pool
	if err := db.db.Model(&Pool{}).Where("name = ?", poolName).First(&pool).Error; err != nil {
		return 0, err
	}
	return len(pool.Infos), nil
}
// GetNumInfos returns the number of infos recorded for a pool
GetNumInfos returns the number of infos recorded for a pool
// GetNumInfos returns the number of infos recorded for a pool
func (db *Database) GetNumInfos(poolName string) (int, error) {
	poolName = strings.ToLower(poolName)
	db.namedLock.RLock(poolName)
	defer db.namedLock.RUnlock(poolName)
	var pool Pool
	if err := db.db.Model(&Pool{}).Where("name = ?", poolName).First(&pool).Error; err != nil {
		return 0, err
	}
	return len(pool.Infos), nil
}
func ( db * Database ) GetNumInfos ( poolName string ) ( int , error ) { poolName = strings . ToLower ( poolName ) db . namedLock . RLock ( poolName ) defer db . namedLock . RUnlock ( poolName ) var pool Pool if err := db . db . Model ( & Pool { } ) . Where ( " " , poolName ) . First ( & pool ) . Error ; err != nil { return 0 , err } return len ( pool . Infos ) , nil }
GetNumInfos returns the number of infos recorded for a pool
GetNumInfos returns the number of infos recorded for a pool