/** @throws GridException If query is invalid. */ public void validate() throws GridException { if (type != SCAN && !cctx.config().isQueryIndexEnabled()) throw new GridException("Indexing is disabled for cache: " + cctx.cache().name()); }