PHP layered cache implementation with variuous backends