Moved cache out to a service