Added query caching to public layers.