You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mnemonic.apache.org by ga...@apache.org on 2017/03/20 17:17:57 UTC
incubator-mnemonic git commit: MNEMONIC-224: Create a
Mnemonic-sessions module MNEMONIC-223: Abstract MneSessions from
Mnemonic-hadoop module
Repository: incubator-mnemonic
Updated Branches:
refs/heads/master 224ef2fec -> f56caa877
MNEMONIC-224: Create a Mnemonic-sessions module
MNEMONIC-223: Abstract MneSessions from Mnemonic-hadoop module
Project: http://git-wip-us.apache.org/repos/asf/incubator-mnemonic/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-mnemonic/commit/f56caa87
Tree: http://git-wip-us.apache.org/repos/asf/incubator-mnemonic/tree/f56caa87
Diff: http://git-wip-us.apache.org/repos/asf/incubator-mnemonic/diff/f56caa87
Branch: refs/heads/master
Commit: f56caa87730d5d528705481759cdbb71116deee0
Parents: 224ef2f
Author: Wang, Gang(Gary) <ga...@intel.com>
Authored: Mon Mar 20 09:24:15 2017 -0700
Committer: Wang, Gang(Gary) <ga...@intel.com>
Committed: Mon Mar 20 10:07:02 2017 -0700
----------------------------------------------------------------------
build-tools/source-assembly.xml | 1 +
.../mnemonic/hadoop/MneDurableComputable.java | 28 ---
.../mnemonic/hadoop/MneDurableInputSession.java | 77 +-----
.../hadoop/MneDurableOutputSession.java | 221 +----------------
.../apache/mnemonic/hadoop/MneInputSession.java | 32 ---
.../mnemonic/hadoop/MneOutputSession.java | 29 ---
mnemonic-hadoop/pom.xml | 6 +
mnemonic-sessions/pom.xml | 201 +++++++++++++++
.../mnemonic/sessions/DurableComputable.java | 28 +++
.../mnemonic/sessions/DurableInputSession.java | 97 ++++++++
.../mnemonic/sessions/DurableOutputSession.java | 248 +++++++++++++++++++
.../apache/mnemonic/sessions/InputSession.java | 28 +++
.../apache/mnemonic/sessions/OutputSession.java | 35 +++
.../src/main/resources/log4j.properties | 33 +++
mnemonic-sessions/src/test/resources/testng.xml | 37 +++
pom.xml | 1 +
16 files changed, 722 insertions(+), 380 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-mnemonic/blob/f56caa87/build-tools/source-assembly.xml
----------------------------------------------------------------------
diff --git a/build-tools/source-assembly.xml b/build-tools/source-assembly.xml
index 33c8d49..6608e05 100644
--- a/build-tools/source-assembly.xml
+++ b/build-tools/source-assembly.xml
@@ -35,6 +35,7 @@
<includes>
<include>org.apache.mnemonic:mnemonic-core</include>
<include>org.apache.mnemonic:mnemonic-collections</include>
+ <include>org.apache.mnemonic:mnemonic-sessions</include>
<include>org.apache.mnemonic:mnemonic-examples</include>
</includes>
<sources>
http://git-wip-us.apache.org/repos/asf/incubator-mnemonic/blob/f56caa87/mnemonic-hadoop/mnemonic-hadoop-mapreduce/src/main/java/org/apache/mnemonic/hadoop/MneDurableComputable.java
----------------------------------------------------------------------
diff --git a/mnemonic-hadoop/mnemonic-hadoop-mapreduce/src/main/java/org/apache/mnemonic/hadoop/MneDurableComputable.java b/mnemonic-hadoop/mnemonic-hadoop-mapreduce/src/main/java/org/apache/mnemonic/hadoop/MneDurableComputable.java
deleted file mode 100644
index eb23e65..0000000
--- a/mnemonic-hadoop/mnemonic-hadoop-mapreduce/src/main/java/org/apache/mnemonic/hadoop/MneDurableComputable.java
+++ /dev/null
@@ -1,28 +0,0 @@
-/**
- * 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.mnemonic.hadoop;
-
-import org.apache.mnemonic.CommonAllocator;
-
-public interface MneDurableComputable<A extends CommonAllocator<A>> {
-
- A getAllocator();
-
- long getHandler();
-}
http://git-wip-us.apache.org/repos/asf/incubator-mnemonic/blob/f56caa87/mnemonic-hadoop/mnemonic-hadoop-mapreduce/src/main/java/org/apache/mnemonic/hadoop/MneDurableInputSession.java
----------------------------------------------------------------------
diff --git a/mnemonic-hadoop/mnemonic-hadoop-mapreduce/src/main/java/org/apache/mnemonic/hadoop/MneDurableInputSession.java b/mnemonic-hadoop/mnemonic-hadoop-mapreduce/src/main/java/org/apache/mnemonic/hadoop/MneDurableInputSession.java
index 469dc7a..028b156 100644
--- a/mnemonic-hadoop/mnemonic-hadoop-mapreduce/src/main/java/org/apache/mnemonic/hadoop/MneDurableInputSession.java
+++ b/mnemonic-hadoop/mnemonic-hadoop-mapreduce/src/main/java/org/apache/mnemonic/hadoop/MneDurableInputSession.java
@@ -18,32 +18,20 @@
package org.apache.mnemonic.hadoop;
-import java.util.Iterator;
-
import org.apache.hadoop.conf.Configuration;
import org.apache.hadoop.fs.Path;
import org.apache.hadoop.mapreduce.TaskAttemptContext;
import org.apache.mnemonic.ConfigurationException;
import org.apache.mnemonic.DurableType;
-import org.apache.mnemonic.EntityFactoryProxy;
import org.apache.mnemonic.NonVolatileMemAllocator;
import org.apache.mnemonic.Utils;
-import org.apache.mnemonic.collections.DurableSinglyLinkedList;
-import org.apache.mnemonic.collections.DurableSinglyLinkedListFactory;
+import org.apache.mnemonic.sessions.DurableInputSession;
public class MneDurableInputSession<V>
- implements MneInputSession<V>, MneDurableComputable<NonVolatileMemAllocator> {
+ extends DurableInputSession<V, NonVolatileMemAllocator> {
private TaskAttemptContext taskAttemptContext;
private Configuration configuration;
- private String serviceName;
- private DurableType[] durableTypes;
- private EntityFactoryProxy[] entityFactoryProxies;
- private long slotKeyId;
-
- protected long m_handler;
- protected NonVolatileMemAllocator m_act;
-
public MneDurableInputSession(TaskAttemptContext taskAttemptContext) {
this(taskAttemptContext.getConfiguration());
@@ -59,13 +47,12 @@ public class MneDurableInputSession<V>
throw new ConfigurationException("The durable type of record parameters does not exist");
} else {
if (DurableType.DURABLE == getDurableTypes()[0]
- && getEntityFactoryProxies().length < 1) { /* T.B.D. BUFFER & CHUNK */
+ && getEntityFactoryProxies().length < 1) {
throw new ConfigurationException("The durable entity proxy of record parameters does not exist");
}
}
}
- @Override
public void readConfig(String prefix) {
Configuration conf = getConfiguration();
if (conf == null) {
@@ -79,28 +66,12 @@ public class MneDurableInputSession<V>
validateConfig();
}
- @Override
public void initialize(Path path) {
m_act = new NonVolatileMemAllocator(Utils.getNonVolatileMemoryAllocatorService(getServiceName()), 1024000L,
path.toString(), true);
m_handler = m_act.getHandler(getSlotKeyId());
}
- @Override
- public Iterator<V> iterator() {
- Iterator<V> iter;
- DurableSinglyLinkedList<V> dsllist;
- dsllist = DurableSinglyLinkedListFactory.restore(m_act, getEntityFactoryProxies(), getDurableTypes(), m_handler,
- false);
- iter = dsllist.iterator();
- return iter;
- }
-
- @Override
- public void close() {
- m_act.close();
- }
-
public TaskAttemptContext getTaskAttemptContext() {
return taskAttemptContext;
}
@@ -109,48 +80,6 @@ public class MneDurableInputSession<V>
this.taskAttemptContext = taskAttemptContext;
}
- public String getServiceName() {
- return serviceName;
- }
-
- public void setServiceName(String serviceName) {
- this.serviceName = serviceName;
- }
-
- public DurableType[] getDurableTypes() {
- return durableTypes;
- }
-
- public void setDurableTypes(DurableType[] durableTypes) {
- this.durableTypes = durableTypes;
- }
-
- public EntityFactoryProxy[] getEntityFactoryProxies() {
- return entityFactoryProxies;
- }
-
- public void setEntityFactoryProxies(EntityFactoryProxy[] entityFactoryProxies) {
- this.entityFactoryProxies = entityFactoryProxies;
- }
-
- public long getSlotKeyId() {
- return slotKeyId;
- }
-
- public void setSlotKeyId(long slotKeyId) {
- this.slotKeyId = slotKeyId;
- }
-
- @Override
- public NonVolatileMemAllocator getAllocator() {
- return m_act;
- }
-
- @Override
- public long getHandler() {
- return m_handler;
- }
-
public Configuration getConfiguration() {
return configuration;
}
http://git-wip-us.apache.org/repos/asf/incubator-mnemonic/blob/f56caa87/mnemonic-hadoop/mnemonic-hadoop-mapreduce/src/main/java/org/apache/mnemonic/hadoop/MneDurableOutputSession.java
----------------------------------------------------------------------
diff --git a/mnemonic-hadoop/mnemonic-hadoop-mapreduce/src/main/java/org/apache/mnemonic/hadoop/MneDurableOutputSession.java b/mnemonic-hadoop/mnemonic-hadoop-mapreduce/src/main/java/org/apache/mnemonic/hadoop/MneDurableOutputSession.java
index 71bc861..37e42e1 100644
--- a/mnemonic-hadoop/mnemonic-hadoop-mapreduce/src/main/java/org/apache/mnemonic/hadoop/MneDurableOutputSession.java
+++ b/mnemonic-hadoop/mnemonic-hadoop-mapreduce/src/main/java/org/apache/mnemonic/hadoop/MneDurableOutputSession.java
@@ -19,21 +19,15 @@
package org.apache.mnemonic.hadoop;
import org.apache.mnemonic.ConfigurationException;
-import org.apache.mnemonic.Durable;
import org.apache.mnemonic.DurableType;
-import org.apache.mnemonic.EntityFactoryProxy;
import org.apache.mnemonic.NonVolatileMemAllocator;
-import org.apache.mnemonic.OutOfHybridMemory;
import org.apache.mnemonic.Utils;
import org.apache.mnemonic.collections.DurableSinglyLinkedList;
-import org.apache.mnemonic.collections.DurableSinglyLinkedListFactory;
+import org.apache.mnemonic.sessions.DurableOutputSession;
import java.text.NumberFormat;
import java.util.HashMap;
-import java.util.Iterator;
-import java.util.Map;
-import org.apache.commons.lang3.tuple.Pair;
import org.apache.hadoop.conf.Configuration;
import org.apache.hadoop.fs.Path;
import org.apache.hadoop.mapreduce.JobContext;
@@ -41,25 +35,12 @@ import org.apache.hadoop.mapreduce.TaskAttemptContext;
import org.apache.hadoop.mapreduce.TaskID;
public class MneDurableOutputSession<V>
- implements MneOutputSession<V>, MneDurableComputable<NonVolatileMemAllocator> {
+ extends DurableOutputSession<V, NonVolatileMemAllocator> {
- private long poolSize;
- private TaskAttemptContext taskAttemptContext;
- private Configuration configuration;
- private String serviceName;
- private DurableType[] durableTypes;
- private EntityFactoryProxy[] entityFactoryProxies;
- private long slotKeyId;
private String baseOutputName;
private Path outputPath;
-
- protected Map<V, DurableSinglyLinkedList<V>> m_recordmap;
- protected boolean m_newpool;
- protected long m_poolidx = 0L;
- protected Pair<DurableType[], EntityFactoryProxy[]> m_recparmpair;
- protected DurableSinglyLinkedList<V> m_listnode;
- protected NonVolatileMemAllocator m_act;
- protected Iterator<V> m_iter;
+ private TaskAttemptContext taskAttemptContext;
+ private Configuration configuration;
public MneDurableOutputSession(TaskAttemptContext taskAttemptContext) {
this(taskAttemptContext.getConfiguration());
@@ -82,7 +63,6 @@ public class MneDurableOutputSession<V>
}
}
- @Override
public void readConfig(String prefix) {
Configuration conf = getConfiguration();
if (conf == null) {
@@ -152,195 +132,6 @@ public class MneDurableOutputSession<V>
m_newpool = true;
}
- @Override
- public NonVolatileMemAllocator getAllocator() {
- return m_act;
- }
-
- @Override
- public long getHandler() {
- long ret = 0L;
- if (null != m_listnode) {
- m_listnode.getHandler();
- }
- return ret;
- }
-
- @SuppressWarnings("unchecked")
- protected V createDurableObjectRecord(long size) {
- V ret = null;
- switch (getDurableTypes()[0]) {
- case DURABLE:
- ret = (V) getEntityFactoryProxies()[0].create(m_act,
- m_recparmpair.getRight(), m_recparmpair.getLeft(), false);
- case BUFFER:
- if (size > 0) {
- ret = (V)m_act.createBuffer(size);
- if (null == ret) {
- throw new OutOfHybridMemory("Allocate a buffer failed");
- }
- }
- break;
- case CHUNK:
- if (size > 0) {
- ret = (V)m_act.createChunk(size);
- if (null == ret) {
- throw new OutOfHybridMemory("Allocate a chunk failed");
- }
- }
- break;
- default:
- break;
- }
- return ret;
- }
-
- public V newDurableObjectRecord() {
- return newDurableObjectRecord(-1L);
- }
-
- /**
- * create a durable object record
- *
- * @param size
- * size of buffer or chunk
- *
- * @return null if size not greater than 0 for buffer/chunk type
- * throw OutOfHybridMemory if out of memory
- */
- public V newDurableObjectRecord(long size) {
- V ret = null;
- DurableSinglyLinkedList<V> nv = null;
- try {
- nv = createDurableNode();
- ret = createDurableObjectRecord(size);
- } catch (OutOfHybridMemory e) {
- if (nv != null) {
- nv.destroy();
- }
- if (ret != null) {
- ((Durable) ret).destroy();
- }
- initNextPool();
- try { /* retry */
- nv = createDurableNode();
- ret = createDurableObjectRecord(size);
- } catch (OutOfHybridMemory ee) {
- if (nv != null) {
- nv.destroy();
- }
- if (ret != null) {
- ((Durable) ret).destroy();
- }
- }
- }
- if (null != ret) {
- m_recordmap.put(ret, nv);
- } else {
- if (null != nv) {
- nv.destroy();
- }
- }
- return ret;
- }
-
- protected DurableSinglyLinkedList<V> createDurableNode() {
- DurableSinglyLinkedList<V> ret = null;
- ret = DurableSinglyLinkedListFactory.create(m_act, getEntityFactoryProxies(), getDurableTypes(), false);
- return ret;
- }
-
- @Override
- public void post(V v) {
- DurableSinglyLinkedList<V> nv = null;
- if (null == v) {
- return;
- }
- switch (getDurableTypes()[0]) {
- case DURABLE:
- case BUFFER:
- case CHUNK:
- if (m_recordmap.containsKey(v)) {
- nv = m_recordmap.remove(v);
- } else {
- throw new RuntimeException("The record hasn't been created by newDurableObjectRecord()");
- }
- break;
- default:
- try {
- nv = createDurableNode();
- } catch (OutOfHybridMemory e) {
- initNextPool();
- nv = createDurableNode();
- }
- break;
- }
- assert null != nv;
- nv.setItem(v, false);
- if (m_newpool) {
- m_act.setHandler(getSlotKeyId(), nv.getHandler());
- m_newpool = false;
- } else {
- m_listnode.setNext(nv, false);
- }
- m_listnode = nv;
- }
-
- public void destroyPendingRecord(V k) {
- if (m_recordmap.containsKey(k)) {
- m_recordmap.get(k).destroy();
- ((Durable) k).destroy();
- }
- }
-
- public void destroyAllPendingRecords() {
- for (V k : m_recordmap.keySet()) {
- destroyPendingRecord(k);
- }
- }
-
- @Override
- public void close() {
- destroyAllPendingRecords();
- m_act.close();
- }
-
- public long getSlotKeyId() {
- return slotKeyId;
- }
-
- public void setSlotKeyId(long slotKeyId) {
- this.slotKeyId = slotKeyId;
- }
-
- public EntityFactoryProxy[] getEntityFactoryProxies() {
- return entityFactoryProxies;
- }
-
- public void setEntityFactoryProxies(EntityFactoryProxy[] entityFactoryProxies) {
- this.entityFactoryProxies = entityFactoryProxies;
- }
-
- public DurableType[] getDurableTypes() {
- return durableTypes;
- }
-
- public void setDurableTypes(DurableType[] durableTypes) {
- this.durableTypes = durableTypes;
- }
-
- public String getServiceName() {
- return serviceName;
- }
-
- public void setServiceName(String serviceName) {
- this.serviceName = serviceName;
- }
-
- public long getPoolSize() {
- return poolSize;
- }
-
public Path getOutputPath() {
return outputPath;
}
@@ -349,10 +140,6 @@ public class MneDurableOutputSession<V>
this.outputPath = outputPath;
}
- public void setPoolSize(long poolSize) {
- this.poolSize = poolSize;
- }
-
public TaskAttemptContext getTaskAttemptContext() {
return taskAttemptContext;
}
http://git-wip-us.apache.org/repos/asf/incubator-mnemonic/blob/f56caa87/mnemonic-hadoop/mnemonic-hadoop-mapreduce/src/main/java/org/apache/mnemonic/hadoop/MneInputSession.java
----------------------------------------------------------------------
diff --git a/mnemonic-hadoop/mnemonic-hadoop-mapreduce/src/main/java/org/apache/mnemonic/hadoop/MneInputSession.java b/mnemonic-hadoop/mnemonic-hadoop-mapreduce/src/main/java/org/apache/mnemonic/hadoop/MneInputSession.java
deleted file mode 100644
index cb0d42d..0000000
--- a/mnemonic-hadoop/mnemonic-hadoop-mapreduce/src/main/java/org/apache/mnemonic/hadoop/MneInputSession.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/**
- * 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.mnemonic.hadoop;
-
-import java.io.Closeable;
-import java.util.Iterator;
-
-import org.apache.hadoop.fs.Path;
-
-public interface MneInputSession<V> extends Closeable {
-
- void readConfig(String prefix);
- void initialize(Path path);
- Iterator<V> iterator();
-
-}
http://git-wip-us.apache.org/repos/asf/incubator-mnemonic/blob/f56caa87/mnemonic-hadoop/mnemonic-hadoop-mapreduce/src/main/java/org/apache/mnemonic/hadoop/MneOutputSession.java
----------------------------------------------------------------------
diff --git a/mnemonic-hadoop/mnemonic-hadoop-mapreduce/src/main/java/org/apache/mnemonic/hadoop/MneOutputSession.java b/mnemonic-hadoop/mnemonic-hadoop-mapreduce/src/main/java/org/apache/mnemonic/hadoop/MneOutputSession.java
deleted file mode 100644
index b55fdee..0000000
--- a/mnemonic-hadoop/mnemonic-hadoop-mapreduce/src/main/java/org/apache/mnemonic/hadoop/MneOutputSession.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/**
- * 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.mnemonic.hadoop;
-
-import java.io.Closeable;
-
-public interface MneOutputSession<V> extends Closeable {
-
- void readConfig(String prefix);
- void initNextPool();
- void post(V v);
-
-}
http://git-wip-us.apache.org/repos/asf/incubator-mnemonic/blob/f56caa87/mnemonic-hadoop/pom.xml
----------------------------------------------------------------------
diff --git a/mnemonic-hadoop/pom.xml b/mnemonic-hadoop/pom.xml
index 8b72c34..4e67e51 100644
--- a/mnemonic-hadoop/pom.xml
+++ b/mnemonic-hadoop/pom.xml
@@ -56,6 +56,12 @@
<scope>compile</scope>
</dependency>
<dependency>
+ <groupId>org.apache.mnemonic</groupId>
+ <artifactId>mnemonic-sessions</artifactId>
+ <version>${project.version}</version>
+ <scope>compile</scope>
+ </dependency>
+ <dependency>
<groupId>org.flowcomputing.commons</groupId>
<artifactId>commons-primitives</artifactId>
</dependency>
http://git-wip-us.apache.org/repos/asf/incubator-mnemonic/blob/f56caa87/mnemonic-sessions/pom.xml
----------------------------------------------------------------------
diff --git a/mnemonic-sessions/pom.xml b/mnemonic-sessions/pom.xml
new file mode 100644
index 0000000..1d8a685
--- /dev/null
+++ b/mnemonic-sessions/pom.xml
@@ -0,0 +1,201 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!--
+ 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.
+-->
+
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+ <modelVersion>4.0.0</modelVersion>
+ <parent>
+ <groupId>org.apache.mnemonic</groupId>
+ <artifactId>mnemonic-parent</artifactId>
+ <version>0.5.0-incubating-SNAPSHOT</version>
+ <relativePath>../pom.xml</relativePath>
+ </parent>
+
+ <artifactId>mnemonic-sessions</artifactId>
+ <name>mnemonic-sessions</name>
+ <packaging>jar</packaging>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.mnemonic</groupId>
+ <artifactId>mnemonic-core</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.mnemonic</groupId>
+ <artifactId>mnemonic-collections</artifactId>
+ <version>${project.version}</version>
+ <scope>compile</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.commons</groupId>
+ <artifactId>commons-lang3</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.testng</groupId>
+ <artifactId>testng</artifactId>
+ </dependency>
+ <!-- logging dependencies -->
+ <!-- assume all APIs will be used -->
+ <dependency>
+ <groupId>org.slf4j</groupId>
+ <artifactId>slf4j-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.slf4j</groupId>
+ <artifactId>jul-to-slf4j</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.slf4j</groupId>
+ <artifactId>jcl-over-slf4j</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>log4j</groupId>
+ <artifactId>log4j</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.slf4j</groupId>
+ <artifactId>slf4j-log4j12</artifactId>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-compiler-plugin</artifactId>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-jar-plugin</artifactId>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-shade-plugin</artifactId>
+ <executions>
+ <execution>
+ <phase>package</phase>
+ <goals>
+ <goal>shade</goal>
+ </goals>
+ </execution>
+ </executions>
+ <configuration>
+ <minimizeJar>true</minimizeJar>
+ </configuration>
+ </plugin>
+ <plugin>
+ <groupId>org.bsc.maven</groupId>
+ <artifactId>maven-processor-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>process-test</id>
+ <goals><goal>process-test</goal></goals>
+ <phase>generate-test-sources</phase>
+ <configuration>
+ <compilerArguments>-XDenableSunApiLintControl</compilerArguments>
+ <processors>
+ <processor>${project.parent.groupId}.DurableEntityProcessor</processor>
+ </processors>
+ </configuration>
+ </execution>
+ <execution>
+ <id>process</id>
+ <goals><goal>process</goal></goals>
+ <phase>generate-sources</phase>
+ <configuration>
+ <compilerArguments>-XDenableSunApiLintControl</compilerArguments>
+ <processors>
+ <processor>${project.parent.groupId}.DurableEntityProcessor</processor>
+ </processors>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+
+ <profiles>
+ <profile>
+ <id>proguard</id>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>com.github.wvengen</groupId>
+ <artifactId>proguard-maven-plugin</artifactId>
+ <executions>
+ <execution>
+ <phase>package</phase>
+ <goals><goal>proguard</goal></goals>
+ </execution>
+ </executions>
+ <configuration>
+ <maxMemory>4096m</maxMemory>
+ <proguardInclude>${basedir}/proguard.conf</proguardInclude>
+ <libs>
+ <lib>${java.home}/lib/rt.jar</lib>
+ </libs>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+ </profile>
+ <profile>
+ <id>doc</id>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-javadoc-plugin</artifactId>
+ <configuration>
+ <additionalparam>-Xdoclint:all -Xdoclint:-missing</additionalparam>
+ </configuration>
+ <executions>
+ <execution>
+ <id>attach-javadocs</id>
+ <goals>
+ <goal>jar</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+ </profile>
+ <profile>
+ <id>test</id>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-surefire-plugin</artifactId>
+ <configuration>
+ <argLine>-Xmx2g -XX:MaxPermSize=1g</argLine>
+ <suiteXmlFiles>
+ <suiteXmlFile>src/test/resources/testng.xml</suiteXmlFile>
+ </suiteXmlFiles>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+ </profile>
+ </profiles>
+
+</project>
http://git-wip-us.apache.org/repos/asf/incubator-mnemonic/blob/f56caa87/mnemonic-sessions/src/main/java/org/apache/mnemonic/sessions/DurableComputable.java
----------------------------------------------------------------------
diff --git a/mnemonic-sessions/src/main/java/org/apache/mnemonic/sessions/DurableComputable.java b/mnemonic-sessions/src/main/java/org/apache/mnemonic/sessions/DurableComputable.java
new file mode 100644
index 0000000..9e699ad
--- /dev/null
+++ b/mnemonic-sessions/src/main/java/org/apache/mnemonic/sessions/DurableComputable.java
@@ -0,0 +1,28 @@
+/**
+ * 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.mnemonic.sessions;
+
+import org.apache.mnemonic.RestorableAllocator;
+
+public interface DurableComputable<A extends RestorableAllocator<A>> {
+
+ A getAllocator();
+
+ long getHandler();
+}
http://git-wip-us.apache.org/repos/asf/incubator-mnemonic/blob/f56caa87/mnemonic-sessions/src/main/java/org/apache/mnemonic/sessions/DurableInputSession.java
----------------------------------------------------------------------
diff --git a/mnemonic-sessions/src/main/java/org/apache/mnemonic/sessions/DurableInputSession.java b/mnemonic-sessions/src/main/java/org/apache/mnemonic/sessions/DurableInputSession.java
new file mode 100644
index 0000000..e565e17
--- /dev/null
+++ b/mnemonic-sessions/src/main/java/org/apache/mnemonic/sessions/DurableInputSession.java
@@ -0,0 +1,97 @@
+/**
+ * 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.mnemonic.sessions;
+
+import java.util.Iterator;
+
+import org.apache.mnemonic.DurableType;
+import org.apache.mnemonic.EntityFactoryProxy;
+import org.apache.mnemonic.RestorableAllocator;
+import org.apache.mnemonic.collections.DurableSinglyLinkedList;
+import org.apache.mnemonic.collections.DurableSinglyLinkedListFactory;
+
+public abstract class DurableInputSession<V, A extends RestorableAllocator<A>>
+ implements InputSession<V>, DurableComputable<A> {
+
+ private String serviceName;
+ private DurableType[] durableTypes;
+ private EntityFactoryProxy[] entityFactoryProxies;
+ private long slotKeyId;
+
+ protected long m_handler;
+ protected A m_act;
+
+ @Override
+ public Iterator<V> iterator() {
+ Iterator<V> iter;
+ DurableSinglyLinkedList<V> dsllist;
+ dsllist = DurableSinglyLinkedListFactory.restore(m_act, getEntityFactoryProxies(), getDurableTypes(), m_handler,
+ false);
+ iter = dsllist.iterator();
+ return iter;
+ }
+
+ @Override
+ public void close() {
+ m_act.close();
+ }
+
+ public String getServiceName() {
+ return serviceName;
+ }
+
+ public void setServiceName(String serviceName) {
+ this.serviceName = serviceName;
+ }
+
+ public DurableType[] getDurableTypes() {
+ return durableTypes;
+ }
+
+ public void setDurableTypes(DurableType[] durableTypes) {
+ this.durableTypes = durableTypes;
+ }
+
+ public EntityFactoryProxy[] getEntityFactoryProxies() {
+ return entityFactoryProxies;
+ }
+
+ public void setEntityFactoryProxies(EntityFactoryProxy[] entityFactoryProxies) {
+ this.entityFactoryProxies = entityFactoryProxies;
+ }
+
+ public long getSlotKeyId() {
+ return slotKeyId;
+ }
+
+ public void setSlotKeyId(long slotKeyId) {
+ this.slotKeyId = slotKeyId;
+ }
+
+ @Override
+ public A getAllocator() {
+ return m_act;
+ }
+
+ @Override
+ public long getHandler() {
+ return m_handler;
+ }
+
+}
http://git-wip-us.apache.org/repos/asf/incubator-mnemonic/blob/f56caa87/mnemonic-sessions/src/main/java/org/apache/mnemonic/sessions/DurableOutputSession.java
----------------------------------------------------------------------
diff --git a/mnemonic-sessions/src/main/java/org/apache/mnemonic/sessions/DurableOutputSession.java b/mnemonic-sessions/src/main/java/org/apache/mnemonic/sessions/DurableOutputSession.java
new file mode 100644
index 0000000..7289162
--- /dev/null
+++ b/mnemonic-sessions/src/main/java/org/apache/mnemonic/sessions/DurableOutputSession.java
@@ -0,0 +1,248 @@
+/**
+ * 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.mnemonic.sessions;
+
+import org.apache.mnemonic.Durable;
+import org.apache.mnemonic.DurableType;
+import org.apache.mnemonic.EntityFactoryProxy;
+import org.apache.mnemonic.OutOfHybridMemory;
+import org.apache.mnemonic.RestorableAllocator;
+import org.apache.mnemonic.collections.DurableSinglyLinkedList;
+import org.apache.mnemonic.collections.DurableSinglyLinkedListFactory;
+
+import java.util.Map;
+
+import org.apache.commons.lang3.tuple.Pair;
+
+public abstract class DurableOutputSession<V, A extends RestorableAllocator<A>>
+ implements OutputSession<V>, DurableComputable<A> {
+
+ private long poolSize;
+ private String serviceName;
+ private DurableType[] durableTypes;
+ private EntityFactoryProxy[] entityFactoryProxies;
+ private long slotKeyId;
+
+ protected Map<V, DurableSinglyLinkedList<V>> m_recordmap;
+ protected boolean m_newpool;
+ protected long m_poolidx = 0L;
+ protected Pair<DurableType[], EntityFactoryProxy[]> m_recparmpair;
+ protected DurableSinglyLinkedList<V> m_listnode;
+ protected A m_act;
+
+ protected abstract void initNextPool();
+
+ @Override
+ public A getAllocator() {
+ return m_act;
+ }
+
+ @Override
+ public long getHandler() {
+ long ret = 0L;
+ if (null != m_listnode) {
+ m_listnode.getHandler();
+ }
+ return ret;
+ }
+
+ @SuppressWarnings("unchecked")
+ protected V createDurableObjectRecord(long size) {
+ V ret = null;
+ switch (getDurableTypes()[0]) {
+ case DURABLE:
+ ret = (V) getEntityFactoryProxies()[0].create(m_act,
+ m_recparmpair.getRight(), m_recparmpair.getLeft(), false);
+ case BUFFER:
+ if (size > 0) {
+ ret = (V)m_act.createBuffer(size);
+ if (null == ret) {
+ throw new OutOfHybridMemory("Allocate a buffer failed");
+ }
+ }
+ break;
+ case CHUNK:
+ if (size > 0) {
+ ret = (V)m_act.createChunk(size);
+ if (null == ret) {
+ throw new OutOfHybridMemory("Allocate a chunk failed");
+ }
+ }
+ break;
+ default:
+ break;
+ }
+ return ret;
+ }
+
+ @Override
+ public V newDurableObjectRecord() {
+ return newDurableObjectRecord(-1L);
+ }
+
+ /**
+ * create a durable object record
+ *
+ * @param size
+ * size of buffer or chunk
+ *
+ * @return null if size not greater than 0 for buffer/chunk type
+ * throw OutOfHybridMemory if out of memory
+ */
+ @Override
+ public V newDurableObjectRecord(long size) {
+ V ret = null;
+ DurableSinglyLinkedList<V> nv = null;
+ try {
+ nv = createDurableNode();
+ ret = createDurableObjectRecord(size);
+ } catch (OutOfHybridMemory e) {
+ if (nv != null) {
+ nv.destroy();
+ }
+ if (ret != null) {
+ ((Durable) ret).destroy();
+ }
+ initNextPool();
+ try { /* retry */
+ nv = createDurableNode();
+ ret = createDurableObjectRecord(size);
+ } catch (OutOfHybridMemory ee) {
+ if (nv != null) {
+ nv.destroy();
+ }
+ if (ret != null) {
+ ((Durable) ret).destroy();
+ }
+ }
+ }
+ if (null != ret) {
+ m_recordmap.put(ret, nv);
+ } else {
+ if (null != nv) {
+ nv.destroy();
+ }
+ }
+ return ret;
+ }
+
+ protected DurableSinglyLinkedList<V> createDurableNode() {
+ DurableSinglyLinkedList<V> ret = null;
+ ret = DurableSinglyLinkedListFactory.create(m_act, getEntityFactoryProxies(), getDurableTypes(), false);
+ return ret;
+ }
+
+ @Override
+ public void post(V v) {
+ DurableSinglyLinkedList<V> nv = null;
+ if (null == v) {
+ return;
+ }
+ switch (getDurableTypes()[0]) {
+ case DURABLE:
+ case BUFFER:
+ case CHUNK:
+ if (m_recordmap.containsKey(v)) {
+ nv = m_recordmap.remove(v);
+ } else {
+ throw new RuntimeException("The record hasn't been created by newDurableObjectRecord()");
+ }
+ break;
+ default:
+ try {
+ nv = createDurableNode();
+ } catch (OutOfHybridMemory e) {
+ initNextPool();
+ nv = createDurableNode();
+ }
+ break;
+ }
+ assert null != nv;
+ nv.setItem(v, false);
+ if (m_newpool) {
+ m_act.setHandler(getSlotKeyId(), nv.getHandler());
+ m_newpool = false;
+ } else {
+ m_listnode.setNext(nv, false);
+ }
+ m_listnode = nv;
+ }
+
+ @Override
+ public void destroyPendingRecord(V k) {
+ if (m_recordmap.containsKey(k)) {
+ m_recordmap.get(k).destroy();
+ ((Durable) k).destroy();
+ }
+ }
+
+ @Override
+ public void destroyAllPendingRecords() {
+ for (V k : m_recordmap.keySet()) {
+ destroyPendingRecord(k);
+ }
+ }
+
+ @Override
+ public void close() {
+ destroyAllPendingRecords();
+ m_act.close();
+ }
+
+ public long getSlotKeyId() {
+ return slotKeyId;
+ }
+
+ public void setSlotKeyId(long slotKeyId) {
+ this.slotKeyId = slotKeyId;
+ }
+
+ public EntityFactoryProxy[] getEntityFactoryProxies() {
+ return entityFactoryProxies;
+ }
+
+ public void setEntityFactoryProxies(EntityFactoryProxy[] entityFactoryProxies) {
+ this.entityFactoryProxies = entityFactoryProxies;
+ }
+
+ public DurableType[] getDurableTypes() {
+ return durableTypes;
+ }
+
+ public void setDurableTypes(DurableType[] durableTypes) {
+ this.durableTypes = durableTypes;
+ }
+
+ public String getServiceName() {
+ return serviceName;
+ }
+
+ public void setServiceName(String serviceName) {
+ this.serviceName = serviceName;
+ }
+
+ public long getPoolSize() {
+ return poolSize;
+ }
+
+ public void setPoolSize(long poolSize) {
+ this.poolSize = poolSize;
+ }
+
+}
http://git-wip-us.apache.org/repos/asf/incubator-mnemonic/blob/f56caa87/mnemonic-sessions/src/main/java/org/apache/mnemonic/sessions/InputSession.java
----------------------------------------------------------------------
diff --git a/mnemonic-sessions/src/main/java/org/apache/mnemonic/sessions/InputSession.java b/mnemonic-sessions/src/main/java/org/apache/mnemonic/sessions/InputSession.java
new file mode 100644
index 0000000..e2cfde1
--- /dev/null
+++ b/mnemonic-sessions/src/main/java/org/apache/mnemonic/sessions/InputSession.java
@@ -0,0 +1,28 @@
+/**
+ * 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.mnemonic.sessions;
+
+import java.io.Closeable;
+import java.util.Iterator;
+
+public interface InputSession<V> extends Closeable {
+
+ Iterator<V> iterator();
+
+}
http://git-wip-us.apache.org/repos/asf/incubator-mnemonic/blob/f56caa87/mnemonic-sessions/src/main/java/org/apache/mnemonic/sessions/OutputSession.java
----------------------------------------------------------------------
diff --git a/mnemonic-sessions/src/main/java/org/apache/mnemonic/sessions/OutputSession.java b/mnemonic-sessions/src/main/java/org/apache/mnemonic/sessions/OutputSession.java
new file mode 100644
index 0000000..598becc
--- /dev/null
+++ b/mnemonic-sessions/src/main/java/org/apache/mnemonic/sessions/OutputSession.java
@@ -0,0 +1,35 @@
+/**
+ * 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.mnemonic.sessions;
+
+import java.io.Closeable;
+
+public interface OutputSession<V> extends Closeable {
+
+ V newDurableObjectRecord();
+
+ V newDurableObjectRecord(long size);
+
+ void post(V v);
+
+ void destroyPendingRecord(V k);
+
+ void destroyAllPendingRecords();
+
+}
http://git-wip-us.apache.org/repos/asf/incubator-mnemonic/blob/f56caa87/mnemonic-sessions/src/main/resources/log4j.properties
----------------------------------------------------------------------
diff --git a/mnemonic-sessions/src/main/resources/log4j.properties b/mnemonic-sessions/src/main/resources/log4j.properties
new file mode 100644
index 0000000..24b0e3c
--- /dev/null
+++ b/mnemonic-sessions/src/main/resources/log4j.properties
@@ -0,0 +1,33 @@
+#
+# 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.
+#
+
+# Root logger option
+log4j.rootLogger=INFO, file, stdout
+
+#to stdout
+log4j.appender.stdout=org.apache.log4j.ConsoleAppender
+log4j.appender.stdout.Target=System.out
+log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
+log4j.appender.stdout.layout.ConversionPattern=%d{yy/MM/dd HH:mm:ss} %p %c{1}: %m%n
+
+#to log.log file
+log4j.appender.file=org.apache.log4j.RollingFileAppender
+log4j.appender.file.File=log.log
+log4j.appender.file.MaxFileSize=10MB
+log4j.appender.file.MaxBackupIndex=10
+log4j.appender.file.layout=org.apache.log4j.PatternLayout
+log4j.appender.file.layout.ConversionPattern=%d{yy/MM/dd HH:mm:ss} %p %c{1}: %m%n
http://git-wip-us.apache.org/repos/asf/incubator-mnemonic/blob/f56caa87/mnemonic-sessions/src/test/resources/testng.xml
----------------------------------------------------------------------
diff --git a/mnemonic-sessions/src/test/resources/testng.xml b/mnemonic-sessions/src/test/resources/testng.xml
new file mode 100644
index 0000000..7e00577
--- /dev/null
+++ b/mnemonic-sessions/src/test/resources/testng.xml
@@ -0,0 +1,37 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!--
+ 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.
+-->
+
+<!DOCTYPE suite SYSTEM "http://testng.org/testng-1.0.dtd">
+<suite name="Suite" verbose="1" parallel="tests" thread-count="1">
+ <test name="Test">
+ <classes>
+ <class name="org.apache.mnemonic.collections.DurableSinglyLinkedListNGTest"/>
+ </classes>
+ </test> <!-- Test -->
+</suite> <!-- Suite -->
+
+
+<!--
+ <class name="org.apache.mnemonic.collections.Person"/>
+ <class name="org.apache.mnemonic.collections.DurablePersonNGTest"/>
+ <class name="org.apache.mnemonic.collections.DurableListNGTest"/>
+ <class name="org.apache.mnemonic.collections.DurableSinglyLinkedListNGTest"/>
+ -->
http://git-wip-us.apache.org/repos/asf/incubator-mnemonic/blob/f56caa87/pom.xml
----------------------------------------------------------------------
diff --git a/pom.xml b/pom.xml
index a426d9e..6232a69 100644
--- a/pom.xml
+++ b/pom.xml
@@ -93,6 +93,7 @@
<module>mnemonic-memory-services</module>
<module>mnemonic-computing-services</module>
<module>mnemonic-benches</module>
+ <module>mnemonic-sessions</module>
<module>mnemonic-hadoop</module>
</modules>