Easy solution for storing and querying images from persistence