gora-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF GitHub Bot (Jira)" <j...@apache.org>
Subject [jira] [Commented] (GORA-656) Hazelcast IMap backed datastore
Date Fri, 14 May 2021 16:53:00 GMT

    [ https://issues.apache.org/jira/browse/GORA-656?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17344717#comment-17344717
] 

ASF GitHub Bot commented on GORA-656:
-------------------------------------

kamaci commented on a change in pull request #222:
URL: https://github.com/apache/gora/pull/222#discussion_r632664707



##########
File path: gora-hazelcast/src/test/java/org/apache/gora/hazelcast/mapreduce/HazelcastStoreMapReduceTest.java
##########
@@ -0,0 +1,63 @@
+/**
+ * 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.gora.hazelcast.mapreduce;
+
+import org.apache.gora.hazelcast.GoraHazelcastTestDriver;
+import org.apache.gora.mapreduce.DataStoreMapReduceTestBase;
+import org.apache.gora.examples.generated.WebPage;
+import org.apache.gora.store.DataStore;
+import org.apache.gora.store.DataStoreFactory;
+import org.apache.hadoop.conf.Configuration;
+import org.junit.After;
+import org.junit.Before;
+
+import java.io.IOException;
+
+public class HazelcastStoreMapReduceTest extends DataStoreMapReduceTestBase {
+
+  private GoraHazelcastTestDriver driver;
+
+  public HazelcastStoreMapReduceTest() throws IOException {
+    super();
+    driver = new GoraHazelcastTestDriver();
+  }
+
+  @Override
+  @Before
+  public void setUp() throws Exception {
+    driver.setUpClass();
+    super.setUp();
+  }
+
+  @Override
+  @After
+  public void tearDown() throws Exception {
+    super.tearDown();
+    driver.tearDownClass();
+  }
+
+  @Override
+  protected DataStore<String, WebPage> createWebPageDataStore() throws IOException
{
+    try {
+      return DataStoreFactory.getDataStore(String.class, WebPage.class, new Configuration(),
true);
+    } catch (Exception e) {
+      throw new RuntimeException(e);

Review comment:
       What is the purpose of catching the `Exception` and re-throwing it as `RuntimeException`?




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


> Hazelcast IMap backed datastore
> -------------------------------
>
>                 Key: GORA-656
>                 URL: https://issues.apache.org/jira/browse/GORA-656
>             Project: Apache Gora
>          Issue Type: Improvement
>            Reporter: Kevin Ratnasekera
>            Priority: Major
>              Labels: gsoc2020
>          Time Spent: 1h
>  Remaining Estimate: 0h
>
> Current implementation of JCache datastore is written in a way that it will work with
any JCache provider. Even though we have made explicitly available Hazelcast JCache provider
to the classpath. This implementation should be based on the native interfaces of IMap.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Mime
View raw message