Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 36247200B85 for ; Thu, 1 Sep 2016 08:17:11 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id 2F390160ACE; Thu, 1 Sep 2016 06:16:51 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 278CA160ABA for ; Thu, 1 Sep 2016 08:16:50 +0200 (CEST) Received: (qmail 90995 invoked by uid 500); 1 Sep 2016 06:16:34 -0000 Mailing-List: contact user-help@ignite.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@ignite.apache.org Delivered-To: mailing list user@ignite.apache.org Received: (qmail 90985 invoked by uid 99); 1 Sep 2016 06:16:34 -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, 01 Sep 2016 06:16:34 +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 C11CA1858E4 for ; Thu, 1 Sep 2016 06:16:33 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd3-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 1.279 X-Spam-Level: * X-Spam-Status: No, score=1.279 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, HTML_MESSAGE=2, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_PASS=-0.001] autolearn=disabled Authentication-Results: spamd3-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=gridgain-com.20150623.gappssmtp.com Received: from mx2-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 Y4hQvTPjHYjt for ; Thu, 1 Sep 2016 06:16:31 +0000 (UTC) Received: from mail-lf0-f48.google.com (mail-lf0-f48.google.com [209.85.215.48]) by mx2-lw-us.apache.org (ASF Mail Server at mx2-lw-us.apache.org) with ESMTPS id E7FC95FAFE for ; Thu, 1 Sep 2016 06:16:30 +0000 (UTC) Received: by mail-lf0-f48.google.com with SMTP id b199so52908370lfe.0 for ; Wed, 31 Aug 2016 23:16:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gridgain-com.20150623.gappssmtp.com; s=20150623; h=mime-version:in-reply-to:references:from:date:message-id:subject:to; bh=Zl4JZFojZ/Q5n61SXf+NQ1OR87UAqmvUdivvuxtmeE8=; b=gg+1uJsy6GfyId5+B9oI2LslUEwayoxd94CtLJnVVUKNZB1arIj/55NLVGjPfkHs1W +vAy6CnxLuzV9kPXAitdaJ7RAbAsr/GMOs1Wmpn78Gcn6P/tMiP0cpvprWr3YMPv2H0R jDusE++vBwGKKDgrQTb9VkhmMTq/k5JldStutOodZd3i81/IMY8Xc7HVgNmge6i/EYtR WfW0pg3+eqxgbcQvO286NbFP1+0BXiuJeugrGOPZrQDZ2gsolnO2OEwVMkVCr3AIIl7u jfDotjlqp1Zg7YMypP/Ffj0QV642w/58VQKNpRtlJd4gJT/uOhvFx9Pc0P48T7OEiBfW 10FQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to; bh=Zl4JZFojZ/Q5n61SXf+NQ1OR87UAqmvUdivvuxtmeE8=; b=fjZoGlMToNTGRrsm+4vPPMO3aNB8tNJl+l0zwBgh6Yzw0fq6RlcK4YuX04u0waS3TY 3HmVtWvGtY2mdadhbqDYkbdQhjoVCms+ze3Y9BXp4miDG2ETYVFnWWmVrUpck8d8ydFR pFMJz2idoqOjRu5pmmX7UPmZmhcSsOAf4u+uwZmEFEtS8qbyKDNS2XbP3zU86Fcrhv8N uIucvBYT/zA1gkS4iKcUHAa6YkvRsHn8zHlDbijCqsldRB6A6Tihz9juPESlQIrjlGst kP20KwDvwm6eW4Vui4OSyBL5jWyAfaFzt//wXT3aYA8OVuBgRHXBjvJNSQQGqjkYOk72 XVYA== X-Gm-Message-State: AE9vXwOuSwpCy43LWQ+9Chlrh0nJGbqdB2HDppI+B7eK0ZVteNyZ+QVTLNjLXlsueR3LXdK+Lg0lOstciY72Dktt X-Received: by 10.25.37.18 with SMTP id l18mr4790496lfl.88.1472710589275; Wed, 31 Aug 2016 23:16:29 -0700 (PDT) MIME-Version: 1.0 Received: by 10.25.214.168 with HTTP; Wed, 31 Aug 2016 23:16:28 -0700 (PDT) In-Reply-To: References: <1472219904560-7350.post@n6.nabble.com> <1472406462888-7361.post@n6.nabble.com> <1472532723413-7396.post@n6.nabble.com> <1472536616650-7397.post@n6.nabble.com> <1472540302900-7398.post@n6.nabble.com> <1472545635705-7400.post@n6.nabble.com> <1472553743202-7404.post@n6.nabble.com> <1472556216338-7405.post@n6.nabble.com> <1472617361188-7425.post@n6.nabble.com> <1472622911443-7427.post@n6.nabble.com> <1472625062470-7430.post@n6.nabble.com> From: Alexey Kuznetsov Date: Thu, 1 Sep 2016 13:16:28 +0700 Message-ID: Subject: Re: javax.cache.CacheException: Failed to find mapping description To: user@ignite.apache.org Content-Type: multipart/alternative; boundary=001a114117e287f4d5053b6c27b3 archived-at: Thu, 01 Sep 2016 06:17:11 -0000 --001a114117e287f4d5053b6c27b3 Content-Type: text/plain; charset=UTF-8 @vikramT, I found the problem and created issue: https://issues.apache.org/jira/browse/IGNITE-3816 You may workaround by specifying all DB related names in uppercase. See your CacheConfig.java and change // Key fields for inventory_orders. Collection keys = new ArrayList<>(); keys.add(new JdbcTypeField(Types.INTEGER, "ITEM_ID", Integer.class, "itemId")); jdbcType.setKeyFields(keys.toArray(new JdbcTypeField[keys.size()])); // Value fields for inventory_orders. Collection vals = new ArrayList<>(); vals.add(new JdbcTypeField(Types.INTEGER, "MONTH_ID", Integer.class, "monthId")); vals.add(new JdbcTypeField(Types.INTEGER, "ITEM_ID", Integer.class, "itemId")); vals.add(new JdbcTypeField(Types.DOUBLE, "UNITS_RECEIVED", Double.class, "unitsReceived")); vals.add(new JdbcTypeField(Types.INTEGER, "MONTH_DURATION", Integer.class, "monthDuration")); jdbcType.setValueFields(vals.toArray(new JdbcTypeField[vals.size()])); On Wed, Aug 31, 2016 at 10:12 PM, Alexey Kuznetsov wrote: > @Val, @vikramT, @Vasiliy, > > FYI: I created issue: CacheJdbcPojoStore.loadCache() should check > arguments and fail with appropriate exception message [ > https://issues.apache.org/jira/browse/IGNITE-3815]. > That was exactly what could help @vikramT to resolve initial bug. > > On Wed, Aug 31, 2016 at 6:04 PM, Alexey Kuznetsov > wrote: > >> @vikramT, thanks for logs we will take a look. >> >> I see NPE in log, so we will try to reproduce. >> >> On Wed, Aug 31, 2016 at 1:31 PM, vikramT wrote: >> >>> hi Vasiliy, Alexey, >>> >>> I tried this code "cache.loadCache(null,Inventor >>> yOrdersKey.class.getName(), >>> "select * from inventory_orders");" and getting different error log >>> ignite-19d380e7.log >>> >> gnite-19d380e7.log> >>> >>> Also I have added constructors in "InventoryOrdersKey" as below: >>> public InventoryOrdersKey(){ >>> } >>> >>> public InventoryOrdersKey(Integer itemId){ >>> this.itemId = itemId; >>> } >>> >>> Error now is: "Caused by: javax.cache.integration.CacheLoaderException: >>> Failed to construct instance of class: >>> org.infocepts.ignite.hiveCache.InventoryOrdersKey" >>> >>> >>> >>> >>> >>> >>> -- >>> View this message in context: http://apache-ignite-users.705 >>> 18.x6.nabble.com/javax-cache-CacheException-Failed-to-find-m >>> apping-description-tp7350p7430.html >>> Sent from the Apache Ignite Users mailing list archive at Nabble.com. >>> >> >> >> >> -- >> Alexey Kuznetsov >> GridGain Systems >> www.gridgain.com >> > > > > -- > Alexey Kuznetsov > GridGain Systems > www.gridgain.com > -- Alexey Kuznetsov GridGain Systems www.gridgain.com --001a114117e287f4d5053b6c27b3 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
@vikra= mT,

=
I fou= nd the problem and created issue:=C2=A0https://issues.apache.org/jira/browse/IGNITE-3816=
<= br>
Yo= u may workaround by specifying all DB related names in=C2=A0uppercase.
See your C= acheConfig.java and change

=C2=A0 =C2=A0 =C2=A0 =C2=A0 // Key fields for inve= ntory_orders.
=C2=A0 =C2=A0 =C2=A0 =C2=A0 Collection<JdbcTypeField> keys = =3D new ArrayList<>();
=C2=A0 =C2=A0 =C2=A0 =C2=A0 keys.add(new JdbcTypeFie= ld(Types.INTEGER, "ITEM_ID", Integer.class, "itemId"));=
=C2= =A0 =C2=A0 =C2=A0 =C2=A0 jdbcType.setKeyFields(keys.toArray(new JdbcTypeFie= ld[keys.size()]));

=C2=A0 =C2=A0 =C2=A0 =C2=A0 // Value fields for inventory_order= s.
=C2= =A0 =C2=A0 =C2=A0 =C2=A0 Collection<JdbcTypeField> vals =3D new Array= List<>();
=C2=A0 =C2=A0 =C2=A0 =C2=A0 vals.add(new JdbcTypeField(Types.INTE= GER, "MONTH_ID", Integer.class, "monthId"));
=C2=A0 =C2=A0 = =C2=A0 =C2=A0 vals.add(new JdbcTypeField(Types.INTEGER, "ITEM_ID"= , Integer.class, "itemId"));
=C2=A0 =C2=A0 =C2=A0 =C2=A0 vals.add(new J= dbcTypeField(Types.DOUBLE, "UNITS_RECEIVED", Double.class, "= unitsReceived"));
=C2=A0 =C2=A0 =C2=A0 =C2=A0 vals.add(new JdbcTypeField(Typ= es.INTEGER, "MONTH_DURATION", Integer.class, "monthDuration&= quot;));
=C2=A0 =C2=A0 =C2=A0 =C2=A0 jdbcType.setValueFields(vals.toArray(new Jdb= cTypeField[vals.size()]));



On Wed, Aug 31, 2016 at 10:12 PM, Alexey Kuznetsov <akuznetsov@gridgain.com> wrote:
@Val,=C2=A0@vikramT, @Vasiliy,

FYI: I created issue:=C2=A0CacheJdbcPojoStore.load= Cache() should check arguments and fail with appropriate exception message = [https://issues.apache.org/jira/browse/IGNITE-3815].
That was exact= ly what could help=C2=A0@vikramT to resolve initial bug.

On Wed, Aug 31, 2016 at 6:04 PM, Alexey Kuznetsov = <akuznetsov= @gridgain.com> wrote:
@vikramT,= =C2=A0thanks=C2=A0for logs we will take a look.

I see NPE in log, so we will try t= o=C2=A0reproduce.
On Wed, Aug 31, 2016 at 1:31 PM, vikramT <vikram.taori@yahoo.com> wrote:
hi Vasiliy, Alexey,

I tried this code "cache.loadCache(null,InventoryOrdersKey.class.= getName(),
"select * from inventory_orders");" and getting different er= ror log
ignite-19d380e7.log
<http://apache-ignit= e-users.70518.x6.nabble.com/file/n7430/ignite-19d380e7.log>= ;

Also I have added constructors in "InventoryOrdersKey" as below:<= br> =C2=A0 =C2=A0public InventoryOrdersKey(){
=C2=A0 =C2=A0 }

=C2=A0 =C2=A0 public InventoryOrdersKey(Integer itemId){
=C2=A0 =C2=A0 =C2=A0 =C2=A0 this.itemId =3D itemId;
=C2=A0 =C2=A0 }

Error now is: "Caused by: javax.cache.integration.CacheLoaderExce= ption:
Failed to construct instance of class:
org.infocepts.ignite.hiveCache.InventoryOrdersKey"






--
View this message in context: http://apache-ignite= -users.70518.x6.nabble.com/javax-cache-CacheException-Failed-to-f= ind-mapping-description-tp7350p7430.html
Sent from the Apache Ignite Users mailing list archive at Nabble.= com.



<= /div>--
Alexey Kuznetsov<= div>GridGain Systems
www.gridgain.com



--
Alexey Kuznetsov
GridGain Systems
www.gridgain.com



--
=
Alexey Ku= znetsov
GridGain Systems
www.gridgain.com
--001a114117e287f4d5053b6c27b3--