Yeah just be sure to use a different string when the representation of the object changes (i.e small, big) and it should work fine. It's about picking a unique cache key per unique representation of the same object.