Remove union, update read and cache functions