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 BE115200C60 for ; Mon, 24 Apr 2017 23:03:02 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id BCB84160B99; Mon, 24 Apr 2017 21:03:02 +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 11E2D160B93 for ; Mon, 24 Apr 2017 23:03:01 +0200 (CEST) Received: (qmail 32474 invoked by uid 500); 24 Apr 2017 21:02:56 -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 32464 invoked by uid 99); 24 Apr 2017 21:02:56 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd4-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 24 Apr 2017 21:02:56 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd4-us-west.apache.org (ASF Mail Server at spamd4-us-west.apache.org) with ESMTP id DC0A7C06D2 for ; Mon, 24 Apr 2017 21:02:55 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 2.173 X-Spam-Level: ** X-Spam-Status: No, score=2.173 tagged_above=-999 required=6.31 tests=[DKIM_ADSP_CUSTOM_MED=0.001, NML_ADSP_CUSTOM_MED=1.2, RCVD_IN_DNSWL_NONE=-0.0001, SPF_SOFTFAIL=0.972] autolearn=disabled Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id VYtQe1-XQ1HJ for ; Mon, 24 Apr 2017 21:02:55 +0000 (UTC) Received: from mwork.nabble.com (mwork.nabble.com [162.253.133.43]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTP id 731A65FC4D for ; Mon, 24 Apr 2017 21:02:54 +0000 (UTC) Received: from static.162.255.23.37.macminivault.com (unknown [162.255.23.37]) by mwork.nabble.com (Postfix) with ESMTP id B6DD13C72E26F for ; Mon, 24 Apr 2017 14:02:53 -0700 (MST) Date: Mon, 24 Apr 2017 14:02:53 -0700 (MST) From: blasteralfred To: user@ignite.apache.org Message-ID: <1493067773743-12211.post@n6.nabble.com> Subject: How to create class affinity? MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit archived-at: Mon, 24 Apr 2017 21:03:02 -0000 Hi, I have 3 java classes ClassA, ClassB, ClassC. ClassA{ int idA; String stringA; public ClassA(){} public ClassA(int idA,String stringA){ this.idA=idA; this.stringA=stringA; } public int getidA(){ return idA; } public String getstringA(){ return stringA; } } ClassB{ int idB; String stringB; public ClassB(){} public ClassB(int idB,String stringB){ this.idB=idB; this.stringB=stringB; } public int getidB(){ return idB; } public String getstringB(){ return stringB; } } ClassC{ int idC,idB; String stringC; public ClassC(){} public ClassB(int idB,int idC,String stringC){ this.idC=idC; this.stringC=stringC; } public int getidC(){ return idC; } public String getstringC(){ return stringC; } } I want ClassA in replicated mode and B & C in partitioned mode. ClassC is related to ClassB. The id of ClassB is present in ClassC (acting like a foreign key). Say, I have 3 nodes, 30 ClassA objects, 30 ClassB objects and 30 ClassC objects. They are distributed in nodes like below; Node 1 => ClassA->30, ClassB->10,ClassC->8 Node 2 => ClassA->30, ClassB->5,ClassC->3 Node 3 => ClassA->30, ClassB->15,ClassC->19 Objects of ClassC related to ClassB should present in same node. I know that there is some mechanism AffinityKey, but I don't know how to implement this. Could somebody tell me how to do this? Thanks in advance.. -- View this message in context: http://apache-ignite-users.70518.x6.nabble.com/How-to-create-class-affinity-tp12211.html Sent from the Apache Ignite Users mailing list archive at Nabble.com.