Currently apply is not convenient for storage backends because it converts the whole array into memory. Modify it to become more memory efficient