Return-Path: X-Original-To: apmail-ignite-commits-archive@minotaur.apache.org Delivered-To: apmail-ignite-commits-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 976B718078 for ; Fri, 17 Jul 2015 12:52:39 +0000 (UTC) Received: (qmail 13674 invoked by uid 500); 17 Jul 2015 12:52:39 -0000 Delivered-To: apmail-ignite-commits-archive@ignite.apache.org Received: (qmail 13644 invoked by uid 500); 17 Jul 2015 12:52:39 -0000 Mailing-List: contact commits-help@ignite.incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@ignite.incubator.apache.org Delivered-To: mailing list commits@ignite.incubator.apache.org Received: (qmail 13635 invoked by uid 99); 17 Jul 2015 12:52:39 -0000 Received: from Unknown (HELO spamd1-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 17 Jul 2015 12:52:39 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd1-us-west.apache.org (ASF Mail Server at spamd1-us-west.apache.org) with ESMTP id E6F89D561B for ; Fri, 17 Jul 2015 12:52:38 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd1-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 0.554 X-Spam-Level: X-Spam-Status: No, score=0.554 tagged_above=-999 required=6.31 tests=[KAM_ASCII_DIVIDERS=0.8, KAM_LAZY_DOMAIN_SECURITY=1, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, RP_MATCHES_RCVD=-1.226] autolearn=disabled Received: from mx1-us-east.apache.org ([10.40.0.8]) by localhost (spamd1-us-west.apache.org [10.40.0.7]) (amavisd-new, port 10024) with ESMTP id XwB2Z2y327Ju for ; Fri, 17 Jul 2015 12:52:28 +0000 (UTC) Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by mx1-us-east.apache.org (ASF Mail Server at mx1-us-east.apache.org) with SMTP id D6A434E201 for ; Fri, 17 Jul 2015 12:52:25 +0000 (UTC) Received: (qmail 9869 invoked by uid 99); 17 Jul 2015 12:51:10 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 17 Jul 2015 12:51:10 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id 29893E35C7; Fri, 17 Jul 2015 12:51:10 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: av@apache.org To: commits@ignite.incubator.apache.org Date: Fri, 17 Jul 2015 12:51:13 -0000 Message-Id: <3de09f0f689c4668a2ab6778e8a8d976@git.apache.org> In-Reply-To: <782da1018494496198c1785b723ceab4@git.apache.org> References: <782da1018494496198c1785b723ceab4@git.apache.org> X-Mailer: ASF-Git Admin Mailer Subject: [04/50] [abbrv] incubator-ignite git commit: # ignite-648: Implemented. http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8218fe6f/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheAtomicPrimaryWrityOrderOffHeapMultiJvmFullApiSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheAtomicPrimaryWrityOrderOffHeapMultiJvmFullApiSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheAtomicPrimaryWrityOrderOffHeapMultiJvmFullApiSelfTest.java new file mode 100644 index 0000000..3732cd2 --- /dev/null +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheAtomicPrimaryWrityOrderOffHeapMultiJvmFullApiSelfTest.java @@ -0,0 +1,31 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.ignite.internal.processors.cache.multijvm; + +import org.apache.ignite.internal.processors.cache.distributed.near.*; + +/** + * Multi-JVM tests. + */ +public class GridCacheAtomicPrimaryWrityOrderOffHeapMultiJvmFullApiSelfTest extends + GridCacheAtomicPrimaryWrityOrderOffHeapMultiNodeFullApiSelfTest { + /** {@inheritDoc} */ + protected boolean isMultiJvm() { + return true; + } +} http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8218fe6f/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheAtomicPrimaryWrityOrderOffHeapTieredMultiJvmFullApiSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheAtomicPrimaryWrityOrderOffHeapTieredMultiJvmFullApiSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheAtomicPrimaryWrityOrderOffHeapTieredMultiJvmFullApiSelfTest.java new file mode 100644 index 0000000..02e6857 --- /dev/null +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheAtomicPrimaryWrityOrderOffHeapTieredMultiJvmFullApiSelfTest.java @@ -0,0 +1,36 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.ignite.internal.processors.cache.multijvm; + +import org.apache.ignite.internal.processors.cache.distributed.near.*; + +/** + * Multi-JVM tests. + */ +public class GridCacheAtomicPrimaryWrityOrderOffHeapTieredMultiJvmFullApiSelfTest + extends GridCacheAtomicPrimaryWrityOrderOffHeapTieredMultiNodeFullApiSelfTest { + /** {@inheritDoc} */ + protected boolean isMultiJvm() { + return true; + } + + /** {@inheritDoc} */ + @Override public void testLocalClearKeys() throws Exception { + fail("https://issues.apache.org/jira/browse/IGNITE-1107"); + } +} http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8218fe6f/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheNearOnlyFairAffinityMultiJvmFullApiSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheNearOnlyFairAffinityMultiJvmFullApiSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheNearOnlyFairAffinityMultiJvmFullApiSelfTest.java new file mode 100644 index 0000000..c8829a1 --- /dev/null +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheNearOnlyFairAffinityMultiJvmFullApiSelfTest.java @@ -0,0 +1,31 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.ignite.internal.processors.cache.multijvm; + +import org.apache.ignite.internal.processors.cache.distributed.near.*; + +/** + * Multi-JVM tests. + */ +public class GridCacheNearOnlyFairAffinityMultiJvmFullApiSelfTest extends + GridCacheNearOnlyFairAffinityMultiNodeFullApiSelfTest { + /** {@inheritDoc} */ + protected boolean isMultiJvm() { + return true; + } +} http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8218fe6f/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheNearOnlyMultiJvmFullApiSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheNearOnlyMultiJvmFullApiSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheNearOnlyMultiJvmFullApiSelfTest.java new file mode 100644 index 0000000..40504d8 --- /dev/null +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheNearOnlyMultiJvmFullApiSelfTest.java @@ -0,0 +1,30 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.ignite.internal.processors.cache.multijvm; + +import org.apache.ignite.internal.processors.cache.distributed.near.*; + +/** + * Multi-JVM tests. + */ +public class GridCacheNearOnlyMultiJvmFullApiSelfTest extends GridCacheNearOnlyMultiNodeFullApiSelfTest { + /** {@inheritDoc} */ + protected boolean isMultiJvm() { + return true; + } +} http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8218fe6f/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheNearOnlyMultiJvmP2PDisabledFullApiSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheNearOnlyMultiJvmP2PDisabledFullApiSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheNearOnlyMultiJvmP2PDisabledFullApiSelfTest.java new file mode 100644 index 0000000..5e48504 --- /dev/null +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheNearOnlyMultiJvmP2PDisabledFullApiSelfTest.java @@ -0,0 +1,31 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.ignite.internal.processors.cache.multijvm; + +import org.apache.ignite.internal.processors.cache.distributed.near.*; + +/** + * Multi-JVM tests. + */ +public class GridCacheNearOnlyMultiJvmP2PDisabledFullApiSelfTest extends + GridCacheNearOnlyMultiNodeP2PDisabledFullApiSelfTest { + /** {@inheritDoc} */ + protected boolean isMultiJvm() { + return true; + } +} http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8218fe6f/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedCopyOnReadDisabledMultiJvmFullApiSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedCopyOnReadDisabledMultiJvmFullApiSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedCopyOnReadDisabledMultiJvmFullApiSelfTest.java new file mode 100644 index 0000000..2aa8ed8 --- /dev/null +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedCopyOnReadDisabledMultiJvmFullApiSelfTest.java @@ -0,0 +1,31 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.ignite.internal.processors.cache.multijvm; + +import org.apache.ignite.internal.processors.cache.distributed.near.*; + +/** + * Multi-JVM tests. + */ +public class GridCachePartitionedCopyOnReadDisabledMultiJvmFullApiSelfTest extends + GridCachePartitionedCopyOnReadDisabledMultiNodeFullApiSelfTest { + /** {@inheritDoc} */ + protected boolean isMultiJvm() { + return true; + } +} http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8218fe6f/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedFairAffinityMultiJvmFullApiSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedFairAffinityMultiJvmFullApiSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedFairAffinityMultiJvmFullApiSelfTest.java new file mode 100644 index 0000000..7bd0043 --- /dev/null +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedFairAffinityMultiJvmFullApiSelfTest.java @@ -0,0 +1,31 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.ignite.internal.processors.cache.multijvm; + +import org.apache.ignite.internal.processors.cache.distributed.replicated.*; + +/** + * Multi-JVM tests. + */ +public class GridCachePartitionedFairAffinityMultiJvmFullApiSelfTest extends + GridCachePartitionedFairAffinityMultiNodeFullApiSelfTest { + /** {@inheritDoc} */ + protected boolean isMultiJvm() { + return true; + } +} http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8218fe6f/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedMultiJvmFullApiSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedMultiJvmFullApiSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedMultiJvmFullApiSelfTest.java new file mode 100644 index 0000000..c88f360 --- /dev/null +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedMultiJvmFullApiSelfTest.java @@ -0,0 +1,30 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.ignite.internal.processors.cache.multijvm; + +import org.apache.ignite.internal.processors.cache.distributed.near.*; + +/** + * Multi-JVM tests. + */ +public class GridCachePartitionedMultiJvmFullApiSelfTest extends GridCachePartitionedMultiNodeFullApiSelfTest { + /** {@inheritDoc} */ + protected boolean isMultiJvm() { + return true; + } +} http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8218fe6f/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedMultiJvmP2PDisabledFullApiSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedMultiJvmP2PDisabledFullApiSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedMultiJvmP2PDisabledFullApiSelfTest.java new file mode 100644 index 0000000..1e619eb --- /dev/null +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedMultiJvmP2PDisabledFullApiSelfTest.java @@ -0,0 +1,31 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.ignite.internal.processors.cache.multijvm; + +import org.apache.ignite.internal.processors.cache.distributed.near.*; + +/** + * Multi-JVM tests. + */ +public class GridCachePartitionedMultiJvmP2PDisabledFullApiSelfTest extends + GridCachePartitionedMultiNodeP2PDisabledFullApiSelfTest { + /** {@inheritDoc} */ + protected boolean isMultiJvm() { + return true; + } +} http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8218fe6f/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedNearDisabledAtomicOffHeapTieredMultiJvmFullApiSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedNearDisabledAtomicOffHeapTieredMultiJvmFullApiSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedNearDisabledAtomicOffHeapTieredMultiJvmFullApiSelfTest.java new file mode 100644 index 0000000..ff249a7 --- /dev/null +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedNearDisabledAtomicOffHeapTieredMultiJvmFullApiSelfTest.java @@ -0,0 +1,36 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.ignite.internal.processors.cache.multijvm; + +import org.apache.ignite.internal.processors.cache.distributed.dht.*; + +/** + * Multi-JVM tests. + */ +public class GridCachePartitionedNearDisabledAtomicOffHeapTieredMultiJvmFullApiSelfTest + extends GridCachePartitionedNearDisabledAtomicOffHeapTieredMultiNodeFullApiSelfTest { + /** {@inheritDoc} */ + protected boolean isMultiJvm() { + return true; + } + + /** {@inheritDoc} */ + @Override public void testLocalClearKeys() throws Exception { + fail("https://issues.apache.org/jira/browse/IGNITE-1107"); + } +} http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8218fe6f/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedNearDisabledFairAffinityMultiJvmFullApiSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedNearDisabledFairAffinityMultiJvmFullApiSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedNearDisabledFairAffinityMultiJvmFullApiSelfTest.java new file mode 100644 index 0000000..b3e45ad --- /dev/null +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedNearDisabledFairAffinityMultiJvmFullApiSelfTest.java @@ -0,0 +1,31 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.ignite.internal.processors.cache.multijvm; + +import org.apache.ignite.internal.processors.cache.distributed.dht.*; + +/** + * Multi-JVM tests. + */ +public class GridCachePartitionedNearDisabledFairAffinityMultiJvmFullApiSelfTest extends + GridCachePartitionedNearDisabledFairAffinityMultiNodeFullApiSelfTest { + /** {@inheritDoc} */ + protected boolean isMultiJvm() { + return true; + } +} http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8218fe6f/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedNearDisabledMultiJvmFullApiSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedNearDisabledMultiJvmFullApiSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedNearDisabledMultiJvmFullApiSelfTest.java new file mode 100644 index 0000000..6cdd3be --- /dev/null +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedNearDisabledMultiJvmFullApiSelfTest.java @@ -0,0 +1,31 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.ignite.internal.processors.cache.multijvm; + +import org.apache.ignite.internal.processors.cache.distributed.dht.*; + +/** + * Multi-JVM tests. + */ +public class GridCachePartitionedNearDisabledMultiJvmFullApiSelfTest extends + GridCachePartitionedNearDisabledMultiNodeFullApiSelfTest { + /** {@inheritDoc} */ + protected boolean isMultiJvm() { + return true; + } +} http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8218fe6f/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedNearDisabledMultiJvmP2PDisabledFullApiSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedNearDisabledMultiJvmP2PDisabledFullApiSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedNearDisabledMultiJvmP2PDisabledFullApiSelfTest.java new file mode 100644 index 0000000..c873b11 --- /dev/null +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedNearDisabledMultiJvmP2PDisabledFullApiSelfTest.java @@ -0,0 +1,31 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.ignite.internal.processors.cache.multijvm; + +import org.apache.ignite.internal.processors.cache.distributed.dht.*; + +/** + * Multi-JVM tests. + */ +public class GridCachePartitionedNearDisabledMultiJvmP2PDisabledFullApiSelfTest extends + GridCachePartitionedNearDisabledMultiNodeP2PDisabledFullApiSelfTest { + /** {@inheritDoc} */ + protected boolean isMultiJvm() { + return true; + } +} http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8218fe6f/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedNearDisabledOffHeapMultiJvmFullApiSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedNearDisabledOffHeapMultiJvmFullApiSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedNearDisabledOffHeapMultiJvmFullApiSelfTest.java new file mode 100644 index 0000000..8d0bc7f --- /dev/null +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedNearDisabledOffHeapMultiJvmFullApiSelfTest.java @@ -0,0 +1,31 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.ignite.internal.processors.cache.multijvm; + +import org.apache.ignite.internal.processors.cache.distributed.dht.*; + +/** + * Multi-JVM tests. + */ +public class GridCachePartitionedNearDisabledOffHeapMultiJvmFullApiSelfTest extends + GridCachePartitionedNearDisabledOffHeapMultiNodeFullApiSelfTest { + /** {@inheritDoc} */ + protected boolean isMultiJvm() { + return true; + } +} http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8218fe6f/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedNearDisabledOffHeapTieredMultiJvmFullApiSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedNearDisabledOffHeapTieredMultiJvmFullApiSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedNearDisabledOffHeapTieredMultiJvmFullApiSelfTest.java new file mode 100644 index 0000000..c797d5b --- /dev/null +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedNearDisabledOffHeapTieredMultiJvmFullApiSelfTest.java @@ -0,0 +1,36 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.ignite.internal.processors.cache.multijvm; + +import org.apache.ignite.internal.processors.cache.distributed.dht.*; + +/** + * Multi-JVM tests. + */ +public class GridCachePartitionedNearDisabledOffHeapTieredMultiJvmFullApiSelfTest + extends GridCachePartitionedNearDisabledOffHeapTieredMultiNodeFullApiSelfTest { + /** {@inheritDoc} */ + protected boolean isMultiJvm() { + return true; + } + + /** {@inheritDoc} */ + @Override public void testLocalClearKeys() throws Exception { + fail("https://issues.apache.org/jira/browse/IGNITE-1107"); + } +} http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8218fe6f/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedOffHeapMultiJvmFullApiSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedOffHeapMultiJvmFullApiSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedOffHeapMultiJvmFullApiSelfTest.java new file mode 100644 index 0000000..5cf5d8a --- /dev/null +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedOffHeapMultiJvmFullApiSelfTest.java @@ -0,0 +1,31 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.ignite.internal.processors.cache.multijvm; + +import org.apache.ignite.internal.processors.cache.distributed.near.*; + +/** + * Multi-JVM tests. + */ +public class GridCachePartitionedOffHeapMultiJvmFullApiSelfTest extends + GridCachePartitionedOffHeapMultiNodeFullApiSelfTest { + /** {@inheritDoc} */ + protected boolean isMultiJvm() { + return true; + } +} http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8218fe6f/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedOffHeapTieredMultiJvmFullApiSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedOffHeapTieredMultiJvmFullApiSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedOffHeapTieredMultiJvmFullApiSelfTest.java new file mode 100644 index 0000000..f843ae5 --- /dev/null +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCachePartitionedOffHeapTieredMultiJvmFullApiSelfTest.java @@ -0,0 +1,36 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.ignite.internal.processors.cache.multijvm; + +import org.apache.ignite.internal.processors.cache.distributed.near.*; + +/** + * Multi-JVM tests. + */ +public class GridCachePartitionedOffHeapTieredMultiJvmFullApiSelfTest + extends GridCachePartitionedOffHeapTieredMultiNodeFullApiSelfTest { + /** {@inheritDoc} */ + protected boolean isMultiJvm() { + return true; + } + + /** {@inheritDoc} */ + @Override public void testLocalClearKeys() throws Exception { + fail("https://issues.apache.org/jira/browse/IGNITE-1107"); + } +} http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8218fe6f/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheReplicatedAtomicMultiJvmFullApiSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheReplicatedAtomicMultiJvmFullApiSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheReplicatedAtomicMultiJvmFullApiSelfTest.java new file mode 100644 index 0000000..7f8bfa1 --- /dev/null +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheReplicatedAtomicMultiJvmFullApiSelfTest.java @@ -0,0 +1,31 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.ignite.internal.processors.cache.multijvm; + +import org.apache.ignite.internal.processors.cache.distributed.replicated.*; + +/** + * Multi-JVM tests. + */ +public class GridCacheReplicatedAtomicMultiJvmFullApiSelfTest extends + GridCacheReplicatedAtomicMultiNodeFullApiSelfTest { + /** {@inheritDoc} */ + protected boolean isMultiJvm() { + return true; + } +} http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8218fe6f/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheReplicatedAtomicPrimaryWriteOrderMultiJvmFullApiSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheReplicatedAtomicPrimaryWriteOrderMultiJvmFullApiSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheReplicatedAtomicPrimaryWriteOrderMultiJvmFullApiSelfTest.java new file mode 100644 index 0000000..fb87c9c --- /dev/null +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheReplicatedAtomicPrimaryWriteOrderMultiJvmFullApiSelfTest.java @@ -0,0 +1,31 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.ignite.internal.processors.cache.multijvm; + +import org.apache.ignite.internal.processors.cache.distributed.replicated.*; + +/** + * Multi-JVM tests. + */ +public class GridCacheReplicatedAtomicPrimaryWriteOrderMultiJvmFullApiSelfTest extends + GridCacheReplicatedAtomicPrimaryWriteOrderMultiNodeFullApiSelfTest { + /** {@inheritDoc} */ + protected boolean isMultiJvm() { + return true; + } +} http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8218fe6f/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheReplicatedMultiJvmFullApiSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheReplicatedMultiJvmFullApiSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheReplicatedMultiJvmFullApiSelfTest.java new file mode 100644 index 0000000..19a5abd --- /dev/null +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheReplicatedMultiJvmFullApiSelfTest.java @@ -0,0 +1,30 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.ignite.internal.processors.cache.multijvm; + +import org.apache.ignite.internal.processors.cache.distributed.replicated.*; + +/** + * Multi-JVM tests. + */ +public class GridCacheReplicatedMultiJvmFullApiSelfTest extends GridCacheReplicatedMultiNodeFullApiSelfTest { + /** {@inheritDoc} */ + protected boolean isMultiJvm() { + return true; + } +} http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8218fe6f/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheReplicatedMultiJvmP2PDisabledFullApiSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheReplicatedMultiJvmP2PDisabledFullApiSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheReplicatedMultiJvmP2PDisabledFullApiSelfTest.java new file mode 100644 index 0000000..7473bdc --- /dev/null +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheReplicatedMultiJvmP2PDisabledFullApiSelfTest.java @@ -0,0 +1,31 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.ignite.internal.processors.cache.multijvm; + +import org.apache.ignite.internal.processors.cache.distributed.replicated.*; + +/** + * Multi-JVM tests. + */ +public class GridCacheReplicatedMultiJvmP2PDisabledFullApiSelfTest extends + GridCacheReplicatedMultiNodeP2PDisabledFullApiSelfTest { + /** {@inheritDoc} */ + protected boolean isMultiJvm() { + return true; + } +} http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8218fe6f/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheReplicatedNearOnlyMultiJvmFullApiSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheReplicatedNearOnlyMultiJvmFullApiSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheReplicatedNearOnlyMultiJvmFullApiSelfTest.java new file mode 100644 index 0000000..9d7639c --- /dev/null +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheReplicatedNearOnlyMultiJvmFullApiSelfTest.java @@ -0,0 +1,37 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.ignite.internal.processors.cache.multijvm; + +import org.apache.ignite.internal.processors.cache.distributed.replicated.*; + +/** + * Multi-JVM tests. + */ +public class GridCacheReplicatedNearOnlyMultiJvmFullApiSelfTest extends + GridCacheReplicatedNearOnlyMultiNodeFullApiSelfTest { + /** {@inheritDoc} */ + protected boolean isMultiJvm() { + return true; + } + + /** {@inheritDoc} */ + @Override public void testNearDhtKeySize() throws Exception { + if (isMultiJvm()) + fail("https://issues.apache.org/jira/browse/IGNITE-648"); + } +} http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8218fe6f/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheReplicatedOffHeapMultiJvmFullApiSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheReplicatedOffHeapMultiJvmFullApiSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheReplicatedOffHeapMultiJvmFullApiSelfTest.java new file mode 100644 index 0000000..f054f4b --- /dev/null +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheReplicatedOffHeapMultiJvmFullApiSelfTest.java @@ -0,0 +1,31 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.ignite.internal.processors.cache.multijvm; + +import org.apache.ignite.internal.processors.cache.distributed.replicated.*; + +/** + * Multi-JVM tests. + */ +public class GridCacheReplicatedOffHeapMultiJvmFullApiSelfTest extends + GridCacheReplicatedOffHeapMultiNodeFullApiSelfTest { + /** {@inheritDoc} */ + protected boolean isMultiJvm() { + return true; + } +} http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8218fe6f/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheReplicatedOffHeapTieredMultiJvmFullApiSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheReplicatedOffHeapTieredMultiJvmFullApiSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheReplicatedOffHeapTieredMultiJvmFullApiSelfTest.java new file mode 100644 index 0000000..2006972 --- /dev/null +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/GridCacheReplicatedOffHeapTieredMultiJvmFullApiSelfTest.java @@ -0,0 +1,36 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.ignite.internal.processors.cache.multijvm; + +import org.apache.ignite.internal.processors.cache.distributed.replicated.*; + +/** + * Multi-JVM tests. + */ +public class GridCacheReplicatedOffHeapTieredMultiJvmFullApiSelfTest + extends GridCacheReplicatedOffHeapTieredMultiNodeFullApiSelfTest { + /** {@inheritDoc} */ + protected boolean isMultiJvm() { + return true; + } + + /** {@inheritDoc} */ + @Override public void testLocalClearKeys() throws Exception { + fail("https://issues.apache.org/jira/browse/IGNITE-1107"); + } +} http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8218fe6f/modules/core/src/test/java/org/apache/ignite/testframework/junits/GridAbstractTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/testframework/junits/GridAbstractTest.java b/modules/core/src/test/java/org/apache/ignite/testframework/junits/GridAbstractTest.java index 9a63b3a..06a1523 100644 --- a/modules/core/src/test/java/org/apache/ignite/testframework/junits/GridAbstractTest.java +++ b/modules/core/src/test/java/org/apache/ignite/testframework/junits/GridAbstractTest.java @@ -33,10 +33,13 @@ import org.apache.ignite.marshaller.jdk.*; import org.apache.ignite.spi.checkpoint.sharedfs.*; import org.apache.ignite.spi.communication.tcp.*; import org.apache.ignite.spi.discovery.tcp.*; +import org.apache.ignite.spi.discovery.tcp.ipfinder.*; import org.apache.ignite.spi.discovery.tcp.ipfinder.multicast.*; +import org.apache.ignite.spi.discovery.tcp.ipfinder.vm.*; import org.apache.ignite.testframework.*; import org.apache.ignite.testframework.config.*; import org.apache.ignite.testframework.junits.logger.*; +import org.apache.ignite.testframework.junits.multijvm.*; import org.apache.log4j.*; import org.jetbrains.annotations.*; import org.springframework.beans.*; @@ -72,6 +75,11 @@ public abstract class GridAbstractTest extends TestCase { /** Null name for execution map. */ private static final String NULL_NAME = UUID.randomUUID().toString(); + /** Ip finder for TCP discovery. */ + public static final TcpDiscoveryIpFinder LOCAL_IP_FINDER = new TcpDiscoveryVmIpFinder(false) {{ + setAddresses(Collections.singleton("127.0.0.1:47500..47509")); + }}; + /** */ private static final long DFLT_TEST_TIMEOUT = 5 * 60 * 1000; @@ -203,6 +211,9 @@ public abstract class GridAbstractTest extends TestCase { * @return logger. */ protected IgniteLogger log() { + if (isRemoteJvm()) + return IgniteNodeRunner.startedInstance().log(); + return log; } @@ -464,6 +475,11 @@ public abstract class GridAbstractTest extends TestCase { } try { + List jvmIds = IgniteNodeRunner.killAll(); + + if (!jvmIds.isEmpty()) + log.info("Next processes of IgniteNodeRunner were killed: " + jvmIds); + beforeTestsStarted(); } catch (Exception | Error t) { @@ -556,6 +572,9 @@ public abstract class GridAbstractTest extends TestCase { * @throws Exception If failed. */ protected final Ignite startGridsMultiThreaded(int init, int cnt) throws Exception { + if (isMultiJvm()) + fail("https://issues.apache.org/jira/browse/IGNITE-648"); + assert init >= 0; assert cnt > 0; @@ -657,14 +676,37 @@ public abstract class GridAbstractTest extends TestCase { * @throws Exception If failed. */ protected Ignite startGrid(String gridName, GridSpringResourceContext ctx) throws Exception { - startingGrid.set(gridName); + if (!isRemoteJvm(gridName)) { + startingGrid.set(gridName); - try { - return IgnitionEx.start(optimize(getConfiguration(gridName)), ctx); - } - finally { - startingGrid.set(null); + try { + return IgnitionEx.start(optimize(getConfiguration(gridName)), ctx); + } + finally { + startingGrid.set(null); + } } + else + return startRemoteGrid(gridName, null, ctx); + } + + /** + * Starts new grid at another JVM with given name. + * + * @param gridName Grid name. + * @param ctx Spring context. + * @return Started grid. + * @throws Exception If failed. + */ + protected Ignite startRemoteGrid(String gridName, IgniteConfiguration cfg, GridSpringResourceContext ctx) + throws Exception { + if (ctx != null) + throw new UnsupportedOperationException("Starting of grid at another jvm by context doesn't supported."); + + if (cfg == null) + cfg = optimize(getConfiguration(gridName)); + + return new IgniteProcessProxy(cfg, log, grid(0)); } /** @@ -707,13 +749,16 @@ public abstract class GridAbstractTest extends TestCase { @SuppressWarnings({"deprecation"}) protected void stopGrid(@Nullable String gridName, boolean cancel) { try { - Ignite ignite = G.ignite(gridName); + Ignite ignite = grid(gridName); assert ignite != null : "Ignite returned null grid for name: " + gridName; info(">>> Stopping grid [name=" + ignite.name() + ", id=" + ignite.cluster().localNode().id() + ']'); - G.stop(gridName, cancel); + if (!isRemoteJvm(gridName)) + G.stop(gridName, cancel); + else + IgniteProcessProxy.stop(gridName, cancel); } catch (IllegalStateException ignored) { // Ignore error if grid already stopped. @@ -736,23 +781,28 @@ public abstract class GridAbstractTest extends TestCase { * @param cancel Cancel flag. */ protected void stopAllGrids(boolean cancel) { - Collection clients = new ArrayList<>(); - Collection srvs = new ArrayList<>(); - - for (Ignite g : G.allGrids()) { - if (g.configuration().getDiscoverySpi().isClientMode()) - clients.add(g); - else - srvs.add(g); - } + try { + Collection clients = new ArrayList<>(); + Collection srvs = new ArrayList<>(); + + for (Ignite g : G.allGrids()) { + if (g.configuration().getDiscoverySpi().isClientMode()) + clients.add(g); + else + srvs.add(g); + } - for (Ignite g : clients) - stopGrid(g.name(), cancel); + for (Ignite g : clients) + stopGrid(g.name(), cancel); - for (Ignite g : srvs) - stopGrid(g.name(), cancel); + for (Ignite g : srvs) + stopGrid(g.name(), cancel); - assert G.allGrids().isEmpty(); + assert G.allGrids().isEmpty(); + } + finally { + IgniteProcessProxy.killAll(); // In multi-JVM case. + } } /** @@ -821,7 +871,14 @@ public abstract class GridAbstractTest extends TestCase { * @return Grid instance. */ protected IgniteEx grid(String name) { - return (IgniteEx)G.ignite(name); + if (!isRemoteJvm(name)) + return (IgniteEx)G.ignite(name); + else { + if (isRemoteJvm()) + return IgniteNodeRunner.startedInstance(); + else + return IgniteProcessProxy.ignite(name); + } } /** @@ -831,7 +888,7 @@ public abstract class GridAbstractTest extends TestCase { * @return Grid instance. */ protected IgniteEx grid(int idx) { - return (IgniteEx)G.ignite(getTestGridName(idx)); + return grid(getTestGridName(idx)); } /** @@ -839,7 +896,7 @@ public abstract class GridAbstractTest extends TestCase { * @return Ignite instance. */ protected Ignite ignite(int idx) { - return G.ignite(getTestGridName(idx)); + return grid(idx); } /** @@ -848,7 +905,10 @@ public abstract class GridAbstractTest extends TestCase { * @return Grid for given test. */ protected IgniteEx grid() { - return (IgniteEx)G.ignite(getTestGridName()); + if (!isMultiJvm()) + return (IgniteEx)G.ignite(getTestGridName()); + else + throw new UnsupportedOperationException("Operation doesn't supported yet."); } /** @@ -856,7 +916,17 @@ public abstract class GridAbstractTest extends TestCase { * @return Ignite instance with given local node. */ protected final Ignite grid(ClusterNode node) { - return G.ignite(node.id()); + if (!isMultiJvm()) + return G.ignite(node.id()); + else { + try { + return IgniteProcessProxy.ignite(node.id()); + } + catch (Exception ignore) { + // A hack if it is local grid. + return G.ignite(node.id()); + } + } } /** @@ -886,7 +956,10 @@ public abstract class GridAbstractTest extends TestCase { protected Ignite startGrid(String gridName, IgniteConfiguration cfg) throws Exception { cfg.setGridName(gridName); - return G.start(cfg); + if (!isRemoteJvm(gridName)) + return G.start(cfg); + else + return startRemoteGrid(gridName, cfg, null); } /** @@ -1015,6 +1088,9 @@ public abstract class GridAbstractTest extends TestCase { cfg.setNodeId(UUID.fromString(new String(chars))); } + if (isMultiJvm()) + ((TcpDiscoverySpi)cfg.getDiscoverySpi()).setIpFinder(LOCAL_IP_FINDER); + return cfg; } @@ -1286,6 +1362,183 @@ public abstract class GridAbstractTest extends TestCase { } /** + * Gets flag whether nodes will run in one JVM or in separate JVMs. + * + * @return True to run nodes in separate JVMs. + * @see IgniteNodeRunner + * @see IgniteProcessProxy + * @see #isRemoteJvm() + * @see #isRemoteJvm(int) + * @see #isRemoteJvm(String) + * @see #executeOnLocalOrRemoteJvm(int, TestIgniteIdxCallable) + * @see #executeOnLocalOrRemoteJvm(Ignite, TestIgniteCallable) + * @see #executeOnLocalOrRemoteJvm(IgniteCache, TestCacheCallable) + */ + protected boolean isMultiJvm() { + return false; + } + + /** + * @param gridName Grid name. + * @return True if test was run in multi-JVM mode and grid with this name was started at another JVM. + */ + protected boolean isRemoteJvm(String gridName) { + return isMultiJvm() && !"0".equals(gridName.substring(getTestGridName().length())); + } + + /** + * @param idx Grid index. + * @return True if test was run in multi-JVM mode and grid with this ID was started at another JVM. + */ + protected boolean isRemoteJvm(int idx) { + return isMultiJvm() && idx != 0; + } + + /** + * @return True if current JVM contains remote started node + * (It differs from JVM where tests executing). + */ + protected boolean isRemoteJvm() { + return IgniteNodeRunner.hasStartedInstance(); + } + + /** + * @param cache Cache. + * @return True if cache is an instance of {@link IgniteCacheProcessProxy} + */ + public static boolean isMultiJvmObject(IgniteCache cache) { + return cache instanceof IgniteCacheProcessProxy; + } + + /** + * @param ignite Ignite. + * @return True if cache is an instance of {@link IgniteProcessProxy} + */ + public static boolean isMultiJvmObject(Ignite ignite) { + return ignite instanceof IgniteProcessProxy; + } + + /** + * Calls job on local JVM or on remote JVM in multi-JVM case. + * + * @param idx Grid index. + * @param job Job. + */ + public R executeOnLocalOrRemoteJvm(final int idx, final TestIgniteIdxCallable job) { + IgniteEx ignite = grid(idx); + + if (!isMultiJvmObject(ignite)) + try { + return job.call(idx); + } + catch (Exception e) { + throw new IgniteException(e); + } + else + return executeRemotely(idx, job); + } + + /** + * Calls job on local JVM or on remote JVM in multi-JVM case. + * + * @param ignite Ignite. + * @param job Job. + */ + public static R executeOnLocalOrRemoteJvm(Ignite ignite, final TestIgniteCallable job) { + if (!isMultiJvmObject(ignite)) + try { + return job.call(ignite); + } + catch (Exception e) { + throw new IgniteException(e); + } + else + return executeRemotely((IgniteProcessProxy)ignite, job); + } + + /** + * Calls job on local JVM or on remote JVM in multi-JVM case. + * + * @param cache Cache. + * @param job Job. + */ + public static R executeOnLocalOrRemoteJvm(IgniteCache cache, TestCacheCallable job) { + Ignite ignite = cache.unwrap(Ignite.class); + + if (!isMultiJvmObject(ignite)) + try { + return job.call(ignite, cache); + } + catch (Exception e) { + throw new IgniteException(e); + } + else + return executeRemotely((IgniteCacheProcessProxy)cache, job); + } + + /** + * Calls job on remote JVM. + * + * @param idx Grid index. + * @param job Job. + */ + public R executeRemotely(final int idx, final TestIgniteIdxCallable job) { + IgniteEx ignite = grid(idx); + + if (!isMultiJvmObject(ignite)) + throw new IllegalArgumentException("Ignite have to be process proxy."); + + IgniteProcessProxy proxy = (IgniteProcessProxy)ignite; + + return proxy.remoteCompute().call(new IgniteCallable() { + @Override public R call() throws Exception { + return job.call(idx); + } + }); + } + + /** + * Calls job on remote JVM. + * + * @param proxy Ignite. + * @param job Job. + */ + public static R executeRemotely(IgniteProcessProxy proxy, final TestIgniteCallable job) { + final UUID id = proxy.getId(); + + return proxy.remoteCompute().call(new IgniteCallable() { + @Override public R call() throws Exception { + Ignite ignite = Ignition.ignite(id); + + return job.call(ignite); + } + }); + } + + /** + * Runs job on remote JVM. + * + * @param cache Cache. + * @param job Job. + */ + public static R executeRemotely(IgniteCacheProcessProxy cache, + final TestCacheCallable job) { + IgniteProcessProxy proxy = (IgniteProcessProxy)cache.unwrap(Ignite.class); + + final UUID id = proxy.getId(); + final String cacheName = cache.getName(); + + return proxy.remoteCompute().call(new IgniteCallable() { + @Override public R call() throws Exception { + Ignite ignite = Ignition.ignite(id); + IgniteCache cache = ignite.cache(cacheName); + + return job.call(ignite, cache); + } + }); + } + + /** * @return Test counters. */ protected synchronized TestCounters getTestCounters() throws IgniteCheckedException { @@ -1598,4 +1851,75 @@ public abstract class GridAbstractTest extends TestCase { return numOfTests; } } + + /** */ + public static interface TestIgniteCallable extends Serializable { + /** + * @param ignite Ignite. + */ + R call(Ignite ignite) throws Exception; + } + + /** */ + public abstract static class TestIgniteRunnable implements TestIgniteCallable { + /** {@inheritDoc} */ + @Override public Object call(Ignite ignite) throws Exception { + run(ignite); + + return null; + } + + /** + * @param ignite Ignite. + */ + public abstract void run(Ignite ignite) throws Exception; + } + + /** */ + public static interface TestIgniteIdxCallable extends Serializable { + /** + * @param idx Grid index. + */ + R call(int idx) throws Exception; + } + + /** */ + public abstract static class TestIgniteIdxRunnable implements TestIgniteIdxCallable { + /** {@inheritDoc} */ + @Override public Object call(int idx) throws Exception { + run(idx); + + return null; + } + + /** + * @param idx Index. + */ + public abstract void run(int idx) throws Exception; + } + + /** */ + public static interface TestCacheCallable extends Serializable { + /** + * @param ignite Ignite. + * @param cache Cache. + */ + R call(Ignite ignite, IgniteCache cache) throws Exception; + } + + /** */ + public abstract static class TestCacheRunnable implements TestCacheCallable { + /** {@inheritDoc} */ + @Override public Object call(Ignite ignite, IgniteCache cache) throws Exception { + run(ignite, cache); + + return null; + } + + /** + * @param ignite Ignite. + * @param cache Cache. + */ + public abstract void run(Ignite ignite, IgniteCache cache) throws Exception; + } } http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8218fe6f/modules/core/src/test/java/org/apache/ignite/testframework/junits/common/GridCommonAbstractTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/testframework/junits/common/GridCommonAbstractTest.java b/modules/core/src/test/java/org/apache/ignite/testframework/junits/common/GridCommonAbstractTest.java index 9941ca8..8698b4a 100644 --- a/modules/core/src/test/java/org/apache/ignite/testframework/junits/common/GridCommonAbstractTest.java +++ b/modules/core/src/test/java/org/apache/ignite/testframework/junits/common/GridCommonAbstractTest.java @@ -116,6 +116,10 @@ public abstract class GridCommonAbstractTest extends GridAbstractTest { * @return Cache. */ protected GridCacheAdapter internalCache(IgniteCache cache) { + if (isMultiJvmObject(cache)) + throw new UnsupportedOperationException("Oparetion can't be supported automatically for multi jvm " + + "(send closure instead)."); + return ((IgniteKernal)cache.unwrap(Ignite.class)).internalCache(cache.getName()); } @@ -201,9 +205,13 @@ public abstract class GridCommonAbstractTest extends GridAbstractTest { * @param cache Cache. * @return {@code True} if near cache is enabled. */ - protected static boolean nearEnabled(IgniteCache cache) { - CacheConfiguration cfg = ((IgniteKernal)cache.unwrap(Ignite.class)). - internalCache(cache.getName()).context().config(); + protected static boolean nearEnabled(final IgniteCache cache) { + CacheConfiguration cfg = GridAbstractTest.executeOnLocalOrRemoteJvm(cache, + new TestCacheCallable() { + @Override public CacheConfiguration call(Ignite ignite, IgniteCache cache) throws Exception { + return ((IgniteKernal)ignite).internalCache(cache.getName()).context().config(); + } + }); return isNearEnabled(cfg); } @@ -238,27 +246,33 @@ public abstract class GridCommonAbstractTest extends GridAbstractTest { * @param replaceExistingValues Replace existing values. * @throws Exception If failed. */ - protected static void loadAll(Cache cache, Set keys, boolean replaceExistingValues) throws Exception { - final AtomicReference ex = new AtomicReference<>(); + protected static void loadAll(Cache cache, final Set keys, final boolean replaceExistingValues) throws Exception { + IgniteCache cacheCp = (IgniteCache)cache; - final CountDownLatch latch = new CountDownLatch(1); + GridAbstractTest.executeOnLocalOrRemoteJvm(cacheCp, new TestCacheRunnable() { + @Override public void run(Ignite ignite, IgniteCache cache) throws Exception { + final AtomicReference ex = new AtomicReference<>(); - cache.loadAll(keys, replaceExistingValues, new CompletionListener() { - @Override public void onCompletion() { - latch.countDown(); - } + final CountDownLatch latch = new CountDownLatch(1); - @Override public void onException(Exception e) { - ex.set(e); + cache.loadAll(keys, replaceExistingValues, new CompletionListener() { + @Override public void onCompletion() { + latch.countDown(); + } - latch.countDown(); - } - }); + @Override public void onException(Exception e) { + ex.set(e); + + latch.countDown(); + } + }); - latch.await(); + latch.await(); - if (ex.get() != null) - throw ex.get(); + if (ex.get() != null) + throw ex.get(); + } + }); } /** http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8218fe6f/modules/core/src/test/java/org/apache/ignite/testframework/junits/multijvm/AffinityProcessProxy.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/testframework/junits/multijvm/AffinityProcessProxy.java b/modules/core/src/test/java/org/apache/ignite/testframework/junits/multijvm/AffinityProcessProxy.java new file mode 100644 index 0000000..e87895d --- /dev/null +++ b/modules/core/src/test/java/org/apache/ignite/testframework/junits/multijvm/AffinityProcessProxy.java @@ -0,0 +1,195 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.ignite.testframework.junits.multijvm; + +import org.apache.ignite.*; +import org.apache.ignite.cache.affinity.*; +import org.apache.ignite.cluster.*; +import org.apache.ignite.lang.*; +import org.jetbrains.annotations.*; + +import java.util.*; + +/** + * Proxy class for affinity at another JVM. + */ +@SuppressWarnings("TransientFieldInNonSerializableClass") +public class AffinityProcessProxy implements Affinity { + /** Compute. */ + private final transient IgniteCompute compute; + + /** Cache name. */ + private final String cacheName; + + /** Grid id. */ + private final UUID gridId; + + /** + * @param cacheName Cache name. + * @param proxy Ignite ptocess proxy. + */ + public AffinityProcessProxy(String cacheName, IgniteProcessProxy proxy) { + this.cacheName = cacheName; + gridId = proxy.getId(); + compute = proxy.remoteCompute(); + } + + /** + * Returns cache instance. Method to be called from closure at another JVM. + * + * @return Cache. + */ + private Affinity affinity() { + return Ignition.ignite(gridId).affinity(cacheName); + } + + /** {@inheritDoc} */ + @Override public int partitions() { + return (int)compute.call(new IgniteCallable() { + @Override public Object call() throws Exception { + return affinity().partitions(); + } + }); + } + + /** {@inheritDoc} */ + @Override public int partition(final K key) { + return (int)compute.call(new IgniteCallable() { + @Override public Object call() throws Exception { + return affinity().partition(key); + } + }); + } + + /** {@inheritDoc} */ + @Override public boolean isPrimary(final ClusterNode n, final K key) { + return (boolean)compute.call(new IgniteCallable() { + @Override public Object call() throws Exception { + return affinity().isPrimary(n, key); + } + }); + } + + /** {@inheritDoc} */ + @Override public boolean isBackup(final ClusterNode n, final K key) { + return (boolean)compute.call(new IgniteCallable() { + @Override public Object call() throws Exception { + return affinity().isBackup(n, key); + } + }); + } + + /** {@inheritDoc} */ + @Override public boolean isPrimaryOrBackup(final ClusterNode n, final K key) { + return (boolean)compute.call(new IgniteCallable() { + @Override public Object call() throws Exception { + return affinity().isPrimaryOrBackup(n, key); + } + }); + } + + /** {@inheritDoc} */ + @Override public int[] primaryPartitions(final ClusterNode n) { + return (int[])compute.call(new IgniteCallable() { + @Override public Object call() throws Exception { + return affinity().primaryPartitions(n); + } + }); + } + + /** {@inheritDoc} */ + @Override public int[] backupPartitions(final ClusterNode n) { + return (int[])compute.call(new IgniteCallable() { + @Override public Object call() throws Exception { + return affinity().backupPartitions(n); + } + }); + } + + /** {@inheritDoc} */ + @Override public int[] allPartitions(final ClusterNode n) { + return (int[])compute.call(new IgniteCallable() { + @Override public Object call() throws Exception { + return affinity().allPartitions(n); + } + }); + } + + /** {@inheritDoc} */ + @Override public Object affinityKey(final K key) { + return compute.call(new IgniteCallable() { + @Override public Object call() throws Exception { + return affinity().affinityKey(key); + } + }); + } + + /** {@inheritDoc} */ + @Override public Map> mapKeysToNodes(final Collection keys) { + return (Map>)compute.call(new IgniteCallable() { + @Override public Object call() throws Exception { + return affinity().mapKeysToNodes(keys); + } + }); + } + + /** {@inheritDoc} */ + @Nullable @Override public ClusterNode mapKeyToNode(final K key) { + return (ClusterNode)compute.call(new IgniteCallable() { + @Override public Object call() throws Exception { + return affinity().mapKeyToNode(key); + } + }); + } + + /** {@inheritDoc} */ + @Override public Collection mapKeyToPrimaryAndBackups(final K key) { + return (Collection)compute.call(new IgniteCallable() { + @Override public Object call() throws Exception { + return affinity().mapKeyToPrimaryAndBackups(key); + } + }); + } + + /** {@inheritDoc} */ + @Override public ClusterNode mapPartitionToNode(final int part) { + return (ClusterNode)compute.call(new IgniteCallable() { + @Override public Object call() throws Exception { + return affinity().mapPartitionToNode(part); + } + }); + } + + /** {@inheritDoc} */ + @Override public Map mapPartitionsToNodes(final Collection parts) { + return (Map)compute.call(new IgniteCallable() { + @Override public Object call() throws Exception { + return affinity().mapPartitionsToNodes(parts); + } + }); + } + + /** {@inheritDoc} */ + @Override public Collection mapPartitionToPrimaryAndBackups(final int part) { + return (Collection)compute.call(new IgniteCallable() { + @Override public Object call() throws Exception { + return affinity().mapPartitionToPrimaryAndBackups(part); + } + }); + } +}