Fix for concurrent cache test

Index out of bounds exeption problem was fixed.