From dev-return-42637-archive-asf-public=cust-asf.ponee.io@ignite.apache.org Thu Nov 29 16:26:04 2018 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by mx-eu-01.ponee.io (Postfix) with SMTP id C305018066C for ; Thu, 29 Nov 2018 16:26:03 +0100 (CET) Received: (qmail 78553 invoked by uid 500); 29 Nov 2018 15:26:02 -0000 Mailing-List: contact dev-help@ignite.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@ignite.apache.org Delivered-To: mailing list dev@ignite.apache.org Received: (qmail 78542 invoked by uid 99); 29 Nov 2018 15:26:02 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd3-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 29 Nov 2018 15:26:02 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd3-us-west.apache.org (ASF Mail Server at spamd3-us-west.apache.org) with ESMTP id 4FBE81805C7 for ; Thu, 29 Nov 2018 15:26:02 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd3-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -110.301 X-Spam-Level: X-Spam-Status: No, score=-110.301 tagged_above=-999 required=6.31 tests=[ENV_AND_HDR_SPF_MATCH=-0.5, RCVD_IN_DNSWL_MED=-2.3, SPF_PASS=-0.001, USER_IN_DEF_SPF_WL=-7.5, USER_IN_WHITELIST=-100] autolearn=disabled Received: from mx1-lw-us.apache.org ([10.40.0.8]) by localhost (spamd3-us-west.apache.org [10.40.0.10]) (amavisd-new, port 10024) with ESMTP id 4fYhnmHGsAHA for ; Thu, 29 Nov 2018 15:26:00 +0000 (UTC) Received: from mailrelay1-us-west.apache.org (mailrelay1-us-west.apache.org [209.188.14.139]) by mx1-lw-us.apache.org (ASF Mail Server at mx1-lw-us.apache.org) with ESMTP id B6D6D5F5C5 for ; Thu, 29 Nov 2018 15:26:00 +0000 (UTC) Received: from jira-lw-us.apache.org (unknown [207.244.88.139]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id 4246BE00D4 for ; Thu, 29 Nov 2018 15:26:00 +0000 (UTC) Received: from jira-lw-us.apache.org (localhost [127.0.0.1]) by jira-lw-us.apache.org (ASF Mail Server at jira-lw-us.apache.org) with ESMTP id 06D0821096 for ; Thu, 29 Nov 2018 15:26:00 +0000 (UTC) Date: Thu, 29 Nov 2018 15:26:00 +0000 (UTC) From: "Eduard Shangareev (JIRA)" To: dev@ignite.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Created] (IGNITE-10478) SQL index creation fails if cache, which query method was called, was statically configured MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 Eduard Shangareev created IGNITE-10478: ------------------------------------------ Summary: SQL index creation fails if cache, which query method was called, was statically configured Key: IGNITE-10478 URL: https://issues.apache.org/jira/browse/IGNITE-10478 Project: Ignite Issue Type: Improvement Components: sql Reporter: Eduard Shangareev {code} javax.cache.CacheException: Cache doesn't exist: cache2 at org.apache.ignite.internal.processors.cache.IgniteCacheProxyImpl.query(IgniteCacheProxyImpl.java:698) at org.apache.ignite.internal.processors.cache.IgniteCacheProxyImpl.query(IgniteCacheProxyImpl.java:637) at org.apache.ignite.internal.processors.cache.GatewayProtectedCacheProxy.query(GatewayProtectedCacheProxy.java:455) at org.gridgain.grid.internal.processors.cache.database.IgniteDbSnapshotSameTopologyTest.testDynamicIndexForStaticCacheRestoredWithRebuild(IgniteDbSnapshotSameTopologyTest.java:1469) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at junit.framework.TestCase.runTest(TestCase.java:176) at org.apache.ignite.testframework.junits.GridAbstractTest.runTestInternal(GridAbstractTest.java:2166) at org.apache.ignite.testframework.junits.GridAbstractTest.access$000(GridAbstractTest.java:144) at org.apache.ignite.testframework.junits.GridAbstractTest$5.run(GridAbstractTest.java:2082) at java.lang.Thread.run(Thread.java:745) Caused by: class org.apache.ignite.internal.processors.query.IgniteSQLException: Cache doesn't exist: cache2 at org.apache.ignite.internal.processors.query.h2.ddl.DdlStatementsProcessor.convert(DdlStatementsProcessor.java:642) at org.apache.ignite.internal.processors.query.h2.ddl.DdlStatementsProcessor.runDdlStatement(DdlStatementsProcessor.java:242) at org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.queryDistributedSqlFieldsNative(IgniteH2Indexing.java:1661) at org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.querySqlFields(IgniteH2Indexing.java:1823) at org.apache.ignite.internal.processors.query.GridQueryProcessor$4.applyx(GridQueryProcessor.java:2175) at org.apache.ignite.internal.processors.query.GridQueryProcessor$4.applyx(GridQueryProcessor.java:2170) at org.apache.ignite.internal.util.lang.IgniteOutClosureX.apply(IgniteOutClosureX.java:36) at org.apache.ignite.internal.processors.query.GridQueryProcessor.executeQuery(GridQueryProcessor.java:2678) at org.apache.ignite.internal.processors.query.GridQueryProcessor.lambda$querySqlFields$0(GridQueryProcessor.java:2184) at org.apache.ignite.internal.processors.query.GridQueryProcessor.executeQuerySafe(GridQueryProcessor.java:2204) at org.apache.ignite.internal.processors.query.GridQueryProcessor.querySqlFields(GridQueryProcessor.java:2165) at org.apache.ignite.internal.processors.query.GridQueryProcessor.querySqlFields(GridQueryProcessor.java:2126) at org.apache.ignite.internal.processors.cache.IgniteCacheProxyImpl.query(IgniteCacheProxyImpl.java:686) ... 12 more {code} As I see it is thrown from {code} if (cache == null || !F.eq(depId, cache.context().dynamicDeploymentId())) throw new SchemaOperationException(SchemaOperationException.CODE_CACHE_NOT_FOUND, cacheName); {code} at org.apache.ignite.internal.processors.query.GridQueryProcessor#processSchemaOperationLocal. And the second check fails. It looks strange from my point of view why we throw CODE_CACHE_NOT_FOUND in this case. -- This message was sent by Atlassian JIRA (v7.6.3#76005)