Fix cache file error with long collection path